jodit-pro 4.19.9 → 4.19.11
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 +11 -11
- package/es2015/jodit.js +699 -163
- package/es2015/jodit.min.js +41 -41
- 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/chart/chart.css +1 -1
- package/es2015/plugins/chart/chart.js +1 -1
- package/es2015/plugins/chart/chart.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/math/math.css +1 -1
- package/es2015/plugins/math/math.js +1 -1
- package/es2015/plugins/math/math.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 +11 -11
- package/es2018/jodit.min.js +14 -14
- 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/chart/chart.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/math/math.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 +15 -15
- package/es2021/jodit.js +699 -163
- package/es2021/jodit.min.js +33 -33
- 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/chart/chart.css +1 -1
- package/es2021/plugins/chart/chart.js +1 -1
- package/es2021/plugins/chart/chart.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/math/math.css +1 -1
- package/es2021/plugins/math/math.js +1 -1
- package/es2021/plugins/math/math.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 +13 -13
- package/es2021.en/jodit.js +699 -163
- package/es2021.en/jodit.min.js +14 -14
- 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/chart/chart.css +1 -1
- package/es2021.en/plugins/chart/chart.js +1 -1
- package/es2021.en/plugins/chart/chart.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/math/math.css +1 -1
- package/es2021.en/plugins/math/math.js +1 -1
- package/es2021.en/plugins/math/math.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 +771 -168
- 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/chart/chart.css +1 -1
- package/es5/plugins/chart/chart.js +1 -1
- package/es5/plugins/chart/chart.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/math/math.css +1 -1
- package/es5/plugins/math/math.js +1 -1
- package/es5/plugins/math/math.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.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.19.
|
|
4
|
+
* Version: v4.19.11
|
|
5
5
|
* Url: https://xdsoft.net/jodit/pro/
|
|
6
6
|
* License(s): SEE LICENSE IN LICENSE.md
|
|
7
7
|
*/
|
|
@@ -1768,7 +1768,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
1768
1768
|
* ```
|
|
1769
1769
|
* @packageDocumentation
|
|
1770
1770
|
* @module constants
|
|
1771
|
-
*/ const APP_VERSION = "4.19.
|
|
1771
|
+
*/ const APP_VERSION = "4.19.11";
|
|
1772
1772
|
// prettier-ignore
|
|
1773
1773
|
const ES = "es2021";
|
|
1774
1774
|
const IS_ES_MODERN = true;
|
|
@@ -2977,13 +2977,14 @@ function wait(condition) {
|
|
|
2977
2977
|
/* harmony import */ var _helpers_checker_is_set_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(42320);
|
|
2978
2978
|
/* harmony import */ var _helpers_checker_is_string_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(70799);
|
|
2979
2979
|
/* harmony import */ var _helpers_checker_is_void_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(86068);
|
|
2980
|
-
/* harmony import */ var
|
|
2981
|
-
/* harmony import */ var
|
|
2982
|
-
/* harmony import */ var
|
|
2983
|
-
/* harmony import */ var
|
|
2984
|
-
/* harmony import */ var
|
|
2985
|
-
/* harmony import */ var
|
|
2986
|
-
/* harmony import */ var
|
|
2980
|
+
/* harmony import */ var _helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(76241);
|
|
2981
|
+
/* harmony import */ var _helpers_string_trim_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(49055);
|
|
2982
|
+
/* harmony import */ var _helpers_utils_assert_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(38837);
|
|
2983
|
+
/* harmony import */ var _helpers_utils_attr_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(29960);
|
|
2984
|
+
/* harmony import */ var _helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(41180);
|
|
2985
|
+
/* harmony import */ var _helpers_utils_data_bind_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(86583);
|
|
2986
|
+
/* harmony import */ var _helpers_utils_error_index_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(89890);
|
|
2987
|
+
/* harmony import */ var _helpers_utils_utils_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(37790);
|
|
2987
2988
|
/*!
|
|
2988
2989
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
2989
2990
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -3004,7 +3005,7 @@ function wait(condition) {
|
|
|
3004
3005
|
|
|
3005
3006
|
|
|
3006
3007
|
|
|
3007
|
-
|
|
3008
|
+
|
|
3008
3009
|
/**
|
|
3009
3010
|
* Module for working with DOM
|
|
3010
3011
|
*/ class Dom {
|
|
@@ -3082,7 +3083,7 @@ const TEMP_ELEMENT_REG_EXP = new RegExp(`<([a-z]+)[^>]+${_constants_js__WEBPACK_
|
|
|
3082
3083
|
const wrapper = (0,_helpers_checker_is_string_js__WEBPACK_IMPORTED_MODULE_6__.isString)(tag) ? create.element(tag) : tag;
|
|
3083
3084
|
if (Dom.isNode(current)) {
|
|
3084
3085
|
if (!current.parentNode) {
|
|
3085
|
-
throw (0,
|
|
3086
|
+
throw (0,_helpers_utils_error_index_js__WEBPACK_IMPORTED_MODULE_14__.error)('Element should be in DOM');
|
|
3086
3087
|
}
|
|
3087
3088
|
current.parentNode.insertBefore(wrapper, current);
|
|
3088
3089
|
wrapper.appendChild(current);
|
|
@@ -3132,12 +3133,12 @@ const TEMP_ELEMENT_REG_EXP = new RegExp(`<([a-z]+)[^>]+${_constants_js__WEBPACK_
|
|
|
3132
3133
|
}
|
|
3133
3134
|
static replace(elm, newTagName, create, withAttributes = false, notMoveContent = false) {
|
|
3134
3135
|
if ((0,_helpers_checker_is_html_js__WEBPACK_IMPORTED_MODULE_4__.isHTML)(newTagName)) {
|
|
3135
|
-
(0,
|
|
3136
|
+
(0,_helpers_utils_assert_js__WEBPACK_IMPORTED_MODULE_10__.assert)(create, 'Need create instance for new tag');
|
|
3136
3137
|
newTagName = create.fromHTML(newTagName);
|
|
3137
3138
|
}
|
|
3138
3139
|
let tag;
|
|
3139
3140
|
if ((0,_helpers_checker_is_string_js__WEBPACK_IMPORTED_MODULE_6__.isString)(newTagName)) {
|
|
3140
|
-
(0,
|
|
3141
|
+
(0,_helpers_utils_assert_js__WEBPACK_IMPORTED_MODULE_10__.assert)(create, 'Need create instance for new tag');
|
|
3141
3142
|
tag = create.element(newTagName);
|
|
3142
3143
|
} else {
|
|
3143
3144
|
tag = newTagName;
|
|
@@ -3186,7 +3187,7 @@ const TEMP_ELEMENT_REG_EXP = new RegExp(`<([a-z]+)[^>]+${_constants_js__WEBPACK_
|
|
|
3186
3187
|
} else {
|
|
3187
3188
|
cond = condNoEmptyElement;
|
|
3188
3189
|
}
|
|
3189
|
-
const emptyText = (node)=>node.nodeValue == null || (0,
|
|
3190
|
+
const emptyText = (node)=>node.nodeValue == null || (0,_helpers_string_trim_js__WEBPACK_IMPORTED_MODULE_9__.trim)(node.nodeValue).length === 0;
|
|
3190
3191
|
if (Dom.isText(node)) {
|
|
3191
3192
|
return emptyText(node);
|
|
3192
3193
|
}
|
|
@@ -3277,7 +3278,7 @@ const TEMP_ELEMENT_REG_EXP = new RegExp(`<([a-z]+)[^>]+${_constants_js__WEBPACK_
|
|
|
3277
3278
|
return Dom.isElement(node) && !/^(BR|HR)$/i.test(node.tagName) && [
|
|
3278
3279
|
'inline',
|
|
3279
3280
|
'inline-block'
|
|
3280
|
-
].indexOf((0,
|
|
3281
|
+
].indexOf((0,_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_12__.css)(node, 'display').toString()) !== -1;
|
|
3281
3282
|
}
|
|
3282
3283
|
/**
|
|
3283
3284
|
* It's block and it can be split
|
|
@@ -3452,13 +3453,13 @@ const TEMP_ELEMENT_REG_EXP = new RegExp(`<([a-z]+)[^>]+${_constants_js__WEBPACK_
|
|
|
3452
3453
|
*/ static findNotEmptySibling(node, left) {
|
|
3453
3454
|
return Dom.findSibling(node, left, (n)=>{
|
|
3454
3455
|
var _a;
|
|
3455
|
-
return !Dom.isEmptyTextNode(n) && Boolean(!Dom.isText(n) || ((_a = n.nodeValue) === null || _a === void 0 ? void 0 : _a.length) && (0,
|
|
3456
|
+
return !Dom.isEmptyTextNode(n) && Boolean(!Dom.isText(n) || ((_a = n.nodeValue) === null || _a === void 0 ? void 0 : _a.length) && (0,_helpers_string_trim_js__WEBPACK_IMPORTED_MODULE_9__.trim)(n.nodeValue));
|
|
3456
3457
|
});
|
|
3457
3458
|
}
|
|
3458
3459
|
/**
|
|
3459
3460
|
* Returns the nearest non-empty neighbor
|
|
3460
3461
|
*/ static findNotEmptyNeighbor(node, left, root) {
|
|
3461
|
-
return (0,
|
|
3462
|
+
return (0,_helpers_utils_utils_js__WEBPACK_IMPORTED_MODULE_15__.call)(left ? Dom.prev : Dom.next, node, (n)=>Boolean(n && (!(Dom.isText(n) || Dom.isComment(n)) || (0,_helpers_string_trim_js__WEBPACK_IMPORTED_MODULE_9__.trim)((n === null || n === void 0 ? void 0 : n.nodeValue) || '').length)), root);
|
|
3462
3463
|
}
|
|
3463
3464
|
static sibling(node, left) {
|
|
3464
3465
|
return left ? node.previousSibling : node.nextSibling;
|
|
@@ -3605,7 +3606,7 @@ const TEMP_ELEMENT_REG_EXP = new RegExp(`<([a-z]+)[^>]+${_constants_js__WEBPACK_
|
|
|
3605
3606
|
if (!node) {
|
|
3606
3607
|
return;
|
|
3607
3608
|
}
|
|
3608
|
-
;(0,
|
|
3609
|
+
;(0,_helpers_utils_data_bind_js__WEBPACK_IMPORTED_MODULE_13__.dataBind)(node, '__old_display', node.style.getPropertyValue('display'));
|
|
3609
3610
|
node.style.setProperty('display', 'none');
|
|
3610
3611
|
}
|
|
3611
3612
|
/**
|
|
@@ -3614,7 +3615,7 @@ const TEMP_ELEMENT_REG_EXP = new RegExp(`<([a-z]+)[^>]+${_constants_js__WEBPACK_
|
|
|
3614
3615
|
if (!node) {
|
|
3615
3616
|
return;
|
|
3616
3617
|
}
|
|
3617
|
-
const display = (0,
|
|
3618
|
+
const display = (0,_helpers_utils_data_bind_js__WEBPACK_IMPORTED_MODULE_13__.dataBind)(node, '__old_display');
|
|
3618
3619
|
if (node.style.getPropertyValue('display') === 'none') {
|
|
3619
3620
|
node.style.setProperty('display', display || null);
|
|
3620
3621
|
}
|
|
@@ -3635,8 +3636,8 @@ const TEMP_ELEMENT_REG_EXP = new RegExp(`<([a-z]+)[^>]+${_constants_js__WEBPACK_
|
|
|
3635
3636
|
/**
|
|
3636
3637
|
* Marks an item as temporary
|
|
3637
3638
|
*/ static markTemporary(element, attributes) {
|
|
3638
|
-
attributes && (0,
|
|
3639
|
-
(0,
|
|
3639
|
+
attributes && (0,_helpers_utils_attr_js__WEBPACK_IMPORTED_MODULE_11__.attr)(element, attributes);
|
|
3640
|
+
(0,_helpers_utils_attr_js__WEBPACK_IMPORTED_MODULE_11__.attr)(element, _constants_js__WEBPACK_IMPORTED_MODULE_0__.TEMP_ATTR, true);
|
|
3640
3641
|
return element;
|
|
3641
3642
|
}
|
|
3642
3643
|
/**
|
|
@@ -3645,7 +3646,7 @@ const TEMP_ELEMENT_REG_EXP = new RegExp(`<([a-z]+)[^>]+${_constants_js__WEBPACK_
|
|
|
3645
3646
|
if (!Dom.isElement(element)) {
|
|
3646
3647
|
return false;
|
|
3647
3648
|
}
|
|
3648
|
-
return Dom.isMarker(element) || (0,
|
|
3649
|
+
return Dom.isMarker(element) || (0,_helpers_utils_attr_js__WEBPACK_IMPORTED_MODULE_11__.attr)(element, _constants_js__WEBPACK_IMPORTED_MODULE_0__.TEMP_ATTR) === 'true';
|
|
3649
3650
|
}
|
|
3650
3651
|
/**
|
|
3651
3652
|
* Define element is selection helper
|
|
@@ -3655,7 +3656,7 @@ const TEMP_ELEMENT_REG_EXP = new RegExp(`<([a-z]+)[^>]+${_constants_js__WEBPACK_
|
|
|
3655
3656
|
/**
|
|
3656
3657
|
* Unwrap temporary elements inside a HTML string (keeps their content)
|
|
3657
3658
|
*/ static replaceTemporaryFromString(value) {
|
|
3658
|
-
return
|
|
3659
|
+
return (0,_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_8__.unwrapMarkedTags)(value, null, _constants_js__WEBPACK_IMPORTED_MODULE_0__.TEMP_ATTR);
|
|
3659
3660
|
}
|
|
3660
3661
|
/**
|
|
3661
3662
|
* Collect the temporary elements (`data-jodit-temp`) inside the root.
|
|
@@ -5186,16 +5187,96 @@ function isFastEqual(a, b) {
|
|
|
5186
5187
|
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net
|
|
5187
5188
|
*/ /**
|
|
5188
5189
|
* @module helpers/checker
|
|
5189
|
-
*/
|
|
5190
|
+
*/ const SPACE = /\s/;
|
|
5191
|
+
const DIGIT = /\d/;
|
|
5192
|
+
const WORD_CHAR = /\w/;
|
|
5193
|
+
// `content="Microsoft Word 15"` — the name followed by a space and a version digit
|
|
5194
|
+
function hasGenerator(tag, name) {
|
|
5195
|
+
let index = tag.indexOf(name);
|
|
5196
|
+
while(index !== -1){
|
|
5197
|
+
const after = index + name.length;
|
|
5198
|
+
if (SPACE.test(tag.charAt(after)) && DIGIT.test(tag.charAt(after + 1))) {
|
|
5199
|
+
return true;
|
|
5200
|
+
}
|
|
5201
|
+
index = tag.indexOf(name, after);
|
|
5202
|
+
}
|
|
5203
|
+
return false;
|
|
5204
|
+
}
|
|
5205
|
+
// `<meta name=ProgId content=Word.Document>`, `<meta name=Generator content="LibreOffice 7.6">`
|
|
5206
|
+
function isOfficeMeta(tag) {
|
|
5207
|
+
if (hasGenerator(tag, 'Microsoft Word') || hasGenerator(tag, 'Microsoft Excel')) {
|
|
5208
|
+
return true;
|
|
5209
|
+
}
|
|
5210
|
+
const lower = tag.toLowerCase();
|
|
5211
|
+
const progId = lower.indexOf('progid');
|
|
5212
|
+
if (progId !== -1 && (lower.indexOf('word.', progId) !== -1 || lower.indexOf('excel.', progId) !== -1)) {
|
|
5213
|
+
return true;
|
|
5214
|
+
}
|
|
5215
|
+
return lower.includes('libreoffice') || lower.includes('openoffice');
|
|
5216
|
+
}
|
|
5217
|
+
// ` class=MsoNormal`, ` class="MsoListParagraph"` inside one tag
|
|
5218
|
+
function hasMsoClass(tag) {
|
|
5219
|
+
let index = tag.indexOf('class=');
|
|
5220
|
+
while(index !== -1){
|
|
5221
|
+
if (index > 0 && SPACE.test(tag.charAt(index - 1))) {
|
|
5222
|
+
let value = index + 'class='.length;
|
|
5223
|
+
const quote = tag.charAt(value);
|
|
5224
|
+
if (quote === '"' || quote === "'") {
|
|
5225
|
+
value += 1;
|
|
5226
|
+
}
|
|
5227
|
+
if (tag.startsWith('Mso', value)) {
|
|
5228
|
+
return true;
|
|
5229
|
+
}
|
|
5230
|
+
}
|
|
5231
|
+
index = tag.indexOf('class=', index + 'class='.length);
|
|
5232
|
+
}
|
|
5233
|
+
return false;
|
|
5234
|
+
}
|
|
5235
|
+
// `style='mso-list:l0 level1 lfo1'` — an `mso-` property inside a style attribute with the given quote
|
|
5236
|
+
function hasMsoStyle(data, quote) {
|
|
5237
|
+
const open = 'style=' + quote;
|
|
5238
|
+
let index = data.indexOf(open);
|
|
5239
|
+
while(index !== -1){
|
|
5240
|
+
const start = index + open.length;
|
|
5241
|
+
let end = data.indexOf(quote, start);
|
|
5242
|
+
if (end === -1) {
|
|
5243
|
+
end = data.length;
|
|
5244
|
+
}
|
|
5245
|
+
if (data.slice(start, end).includes('mso-')) {
|
|
5246
|
+
return true;
|
|
5247
|
+
}
|
|
5248
|
+
index = data.indexOf(open, end);
|
|
5249
|
+
}
|
|
5250
|
+
return false;
|
|
5251
|
+
}
|
|
5252
|
+
/**
|
|
5190
5253
|
* Detect if string is HTML from MS Word, Excel or LibreOffice/OpenOffice
|
|
5254
|
+
*
|
|
5255
|
+
* The clipboard text is attacker controlled, so every check walks the string
|
|
5256
|
+
* once with `indexOf`: a regex with an unbounded group before a required
|
|
5257
|
+
* literal was quadratic on a long run of `<meta` and froze the tab.
|
|
5191
5258
|
*/ function isHtmlFromWord(data) {
|
|
5192
|
-
|
|
5193
|
-
|
|
5194
|
-
|
|
5195
|
-
|
|
5196
|
-
|
|
5197
|
-
|
|
5198
|
-
|
|
5259
|
+
if (data.includes('urn:schemas-microsoft-com:office:word') || data.includes('urn:schemas-microsoft-com:office:excel')) {
|
|
5260
|
+
return true;
|
|
5261
|
+
}
|
|
5262
|
+
// Each tag is taken once, from its `<` to the next `>`, so the scan stays linear
|
|
5263
|
+
let index = data.indexOf('<');
|
|
5264
|
+
while(index !== -1){
|
|
5265
|
+
if (!WORD_CHAR.test(data.charAt(index + 1))) {
|
|
5266
|
+
index = data.indexOf('<', index + 1);
|
|
5267
|
+
continue;
|
|
5268
|
+
}
|
|
5269
|
+
let end = data.indexOf('>', index);
|
|
5270
|
+
if (end === -1) {
|
|
5271
|
+
end = data.length;
|
|
5272
|
+
}
|
|
5273
|
+
const tag = data.slice(index, end);
|
|
5274
|
+
if (tag.slice(0, 5).toLowerCase() === '<meta' && isOfficeMeta(tag) || hasMsoClass(tag)) {
|
|
5275
|
+
return true;
|
|
5276
|
+
}
|
|
5277
|
+
index = data.indexOf('<', end);
|
|
5278
|
+
}
|
|
5279
|
+
return hasMsoStyle(data, "'") || hasMsoStyle(data, '"') && data.includes('<font');
|
|
5199
5280
|
}
|
|
5200
5281
|
|
|
5201
5282
|
|
|
@@ -5212,9 +5293,62 @@ function isFastEqual(a, b) {
|
|
|
5212
5293
|
*/ /**
|
|
5213
5294
|
* @module helpers/checker
|
|
5214
5295
|
*/
|
|
5296
|
+
const NAME_START = /[A-Za-z]/;
|
|
5297
|
+
const NAME_CHAR = /[A-Za-z0-9]/;
|
|
5298
|
+
const WORD_CHAR = /\w/;
|
|
5299
|
+
// The tag name at `from`, or '' when there is none
|
|
5300
|
+
function readTagName(str, from) {
|
|
5301
|
+
if (!NAME_START.test(str.charAt(from))) {
|
|
5302
|
+
return '';
|
|
5303
|
+
}
|
|
5304
|
+
let end = from + 1;
|
|
5305
|
+
while(NAME_CHAR.test(str.charAt(end))){
|
|
5306
|
+
end += 1;
|
|
5307
|
+
}
|
|
5308
|
+
return str.slice(from, end);
|
|
5309
|
+
}
|
|
5310
|
+
// Is there an element `<name ...>` closed later by `</name>`? One pass for the closing tags, one for the opening ones
|
|
5311
|
+
function hasElement(str) {
|
|
5312
|
+
const lastClose = new Map();
|
|
5313
|
+
let index = str.indexOf('</');
|
|
5314
|
+
while(index !== -1){
|
|
5315
|
+
const name = readTagName(str, index + 2);
|
|
5316
|
+
if (name !== '' && str.charAt(index + 2 + name.length) === '>') {
|
|
5317
|
+
lastClose.set(name, index);
|
|
5318
|
+
}
|
|
5319
|
+
index = str.indexOf('</', index + 2);
|
|
5320
|
+
}
|
|
5321
|
+
if (lastClose.size === 0) {
|
|
5322
|
+
return false;
|
|
5323
|
+
}
|
|
5324
|
+
let gt = -1;
|
|
5325
|
+
index = str.indexOf('<');
|
|
5326
|
+
while(index !== -1){
|
|
5327
|
+
const name = readTagName(str, index + 1);
|
|
5328
|
+
const after = index + 1 + name.length;
|
|
5329
|
+
if (name !== '' && !WORD_CHAR.test(str.charAt(after))) {
|
|
5330
|
+
if (gt < after) {
|
|
5331
|
+
gt = str.indexOf('>', after);
|
|
5332
|
+
}
|
|
5333
|
+
if (gt === -1) {
|
|
5334
|
+
return false;
|
|
5335
|
+
}
|
|
5336
|
+
const close = lastClose.get(name);
|
|
5337
|
+
if (close !== undefined && close > gt) {
|
|
5338
|
+
return true;
|
|
5339
|
+
}
|
|
5340
|
+
}
|
|
5341
|
+
index = str.indexOf('<', index + 1);
|
|
5342
|
+
}
|
|
5343
|
+
return false;
|
|
5344
|
+
}
|
|
5215
5345
|
/**
|
|
5216
5346
|
* Check if a string is html or not
|
|
5217
|
-
|
|
5347
|
+
*
|
|
5348
|
+
* The pasted text is attacker controlled, so the check walks the string with
|
|
5349
|
+
* `indexOf`: the former regex `<(\w+)[^>]*>(.*?)<\/\1>` was quadratic on a
|
|
5350
|
+
* long run of `<a>` and froze the tab.
|
|
5351
|
+
*/ const isHTML = (str)=>(0,_is_string_js__WEBPACK_IMPORTED_MODULE_0__.isString)(str) && hasElement(str);
|
|
5218
5352
|
|
|
5219
5353
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, [
|
|
5220
5354
|
/* harmony export */ "isHTML", 0, /* binding */ isHTML
|
|
@@ -5704,11 +5838,12 @@ const isLicense = (license)=>(0,_is_string_js__WEBPACK_IMPORTED_MODULE_0__.isStr
|
|
|
5704
5838
|
/* harmony export */ });
|
|
5705
5839
|
/* harmony import */ var _constants_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(82758);
|
|
5706
5840
|
/* harmony import */ var _dom_dom_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2748);
|
|
5707
|
-
/* harmony import */ var
|
|
5708
|
-
/* harmony import */ var
|
|
5709
|
-
/* harmony import */ var
|
|
5710
|
-
/* harmony import */ var
|
|
5711
|
-
/* harmony import */ var
|
|
5841
|
+
/* harmony import */ var _tag_scan_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(76241);
|
|
5842
|
+
/* harmony import */ var _word_lists_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(90723);
|
|
5843
|
+
/* harmony import */ var _string_trim_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(49055);
|
|
5844
|
+
/* harmony import */ var _utils_attr_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(29960);
|
|
5845
|
+
/* harmony import */ var _utils_css_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(41180);
|
|
5846
|
+
/* harmony import */ var _utils_selector_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(76078);
|
|
5712
5847
|
/*!
|
|
5713
5848
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
5714
5849
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -5722,8 +5857,19 @@ const isLicense = (license)=>(0,_is_string_js__WEBPACK_IMPORTED_MODULE_0__.isStr
|
|
|
5722
5857
|
|
|
5723
5858
|
|
|
5724
5859
|
|
|
5860
|
+
|
|
5861
|
+
// Drop the `mso-*` and `border*` declarations and turn pt/cm into px; one declaration at a time, so a long value cannot make the regexes backtrack
|
|
5725
5862
|
function normalizeCSS(s) {
|
|
5726
|
-
|
|
5863
|
+
const declarations = s.split(';');
|
|
5864
|
+
const last = declarations.length - 1;
|
|
5865
|
+
return declarations.filter((declaration, index)=>{
|
|
5866
|
+
const match = /^\s*([a-z-]{1,64})\s*:/i.exec(declaration);
|
|
5867
|
+
if (!match) {
|
|
5868
|
+
return true;
|
|
5869
|
+
}
|
|
5870
|
+
const property = match[1].toLowerCase();
|
|
5871
|
+
return !(property.startsWith('mso-') || property.startsWith('border') && index !== last);
|
|
5872
|
+
}).join(';').replace(/([0-9.]{1,32})(pt|cm)/gi, (match, units, metrics)=>{
|
|
5727
5873
|
switch(metrics.toLowerCase()){
|
|
5728
5874
|
case 'pt':
|
|
5729
5875
|
return (parseFloat(units) * 1.328).toFixed(0) + 'px';
|
|
@@ -5745,17 +5891,17 @@ function normalizeCSS(s) {
|
|
|
5745
5891
|
// cell backgrounds/borders, e.g. `.xl31 { background:#FCE4D6 }`) were never
|
|
5746
5892
|
// inlined and all styling was lost once the `<style>` block got stripped.
|
|
5747
5893
|
// See https://github.com/xdan/jodit/issues/1362
|
|
5748
|
-
const
|
|
5749
|
-
if (
|
|
5894
|
+
const open = (0,_tag_scan_js__WEBPACK_IMPORTED_MODULE_2__.indexOfOpenTag)(html, 'html');
|
|
5895
|
+
if (open === -1) {
|
|
5750
5896
|
return html;
|
|
5751
5897
|
}
|
|
5752
|
-
html = html.substring(
|
|
5898
|
+
html = html.substring(open);
|
|
5753
5899
|
const closeIndex = html.toLowerCase().lastIndexOf('</html>');
|
|
5754
5900
|
if (closeIndex !== -1) {
|
|
5755
5901
|
html = html.substring(0, closeIndex + '</html>'.length);
|
|
5756
5902
|
}
|
|
5757
5903
|
const iframe = _constants_js__WEBPACK_IMPORTED_MODULE_0__.globalDocument.createElement('iframe');
|
|
5758
|
-
(0,
|
|
5904
|
+
(0,_utils_css_js__WEBPACK_IMPORTED_MODULE_6__.css)(iframe, 'display', 'none');
|
|
5759
5905
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.append(_constants_js__WEBPACK_IMPORTED_MODULE_0__.globalDocument.body, iframe);
|
|
5760
5906
|
let convertedString = '', collection;
|
|
5761
5907
|
try {
|
|
@@ -5764,14 +5910,14 @@ function normalizeCSS(s) {
|
|
|
5764
5910
|
iframeDoc.open();
|
|
5765
5911
|
iframeDoc.write(html);
|
|
5766
5912
|
iframeDoc.close();
|
|
5767
|
-
const listItems = (0,
|
|
5913
|
+
const listItems = (0,_word_lists_js__WEBPACK_IMPORTED_MODULE_3__.readWordListItems)(iframeDoc.body);
|
|
5768
5914
|
// Word marks its auto-generated list markers (the literal
|
|
5769
5915
|
// bullet/number, e.g. `1.` or `·`) with `mso-list:Ignore`.
|
|
5770
5916
|
// They are display-only and must not be imported, otherwise
|
|
5771
5917
|
// the marker text leaks into the content. Drop them before any
|
|
5772
5918
|
// style normalization strips the `mso-list` hint. See #948
|
|
5773
5919
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.each(iframeDoc.body, (node)=>{
|
|
5774
|
-
if (_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(node) && /mso-list:\s*ignore/i.test((0,
|
|
5920
|
+
if (_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(node) && /mso-list:\s*ignore/i.test((0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_5__.attr)(node, 'style') || '')) {
|
|
5775
5921
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(node);
|
|
5776
5922
|
}
|
|
5777
5923
|
});
|
|
@@ -5782,7 +5928,7 @@ function normalizeCSS(s) {
|
|
|
5782
5928
|
if (rules[idx].selectorText === '') {
|
|
5783
5929
|
continue;
|
|
5784
5930
|
}
|
|
5785
|
-
collection = (0,
|
|
5931
|
+
collection = (0,_utils_selector_js__WEBPACK_IMPORTED_MODULE_7__.$$)(rules[idx].selectorText, iframeDoc.body);
|
|
5786
5932
|
// `style.cssText` on purpose: the CSSOM parses the text,
|
|
5787
5933
|
// drops invalid declarations and re-serializes it. The raw
|
|
5788
5934
|
// `style` attribute would keep Word-only junk verbatim
|
|
@@ -5796,19 +5942,19 @@ function normalizeCSS(s) {
|
|
|
5796
5942
|
throw e;
|
|
5797
5943
|
}
|
|
5798
5944
|
}
|
|
5799
|
-
;(0,
|
|
5945
|
+
;(0,_word_lists_js__WEBPACK_IMPORTED_MODULE_3__.wrapWordListItems)(listItems);
|
|
5800
5946
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.each(iframeDoc.body, (node)=>{
|
|
5801
5947
|
if (_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(node)) {
|
|
5802
|
-
const cssText = (0,
|
|
5948
|
+
const cssText = (0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_5__.attr)(node, 'style');
|
|
5803
5949
|
if (cssText) {
|
|
5804
5950
|
node.style.cssText = normalizeCSS(cssText);
|
|
5805
5951
|
}
|
|
5806
|
-
if (!(0,
|
|
5807
|
-
(0,
|
|
5952
|
+
if (!(0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_5__.attr)(node, 'style')) {
|
|
5953
|
+
(0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_5__.attr)(node, 'style', null);
|
|
5808
5954
|
}
|
|
5809
5955
|
}
|
|
5810
5956
|
});
|
|
5811
|
-
convertedString = iframeDoc.firstChild ? (0,
|
|
5957
|
+
convertedString = iframeDoc.firstChild ? (0,_string_trim_js__WEBPACK_IMPORTED_MODULE_4__.trim)(iframeDoc.body.innerHTML) : '';
|
|
5812
5958
|
}
|
|
5813
5959
|
} catch (_a) {} finally{
|
|
5814
5960
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(iframe);
|
|
@@ -5816,7 +5962,7 @@ function normalizeCSS(s) {
|
|
|
5816
5962
|
if (convertedString) {
|
|
5817
5963
|
html = convertedString;
|
|
5818
5964
|
}
|
|
5819
|
-
return (0,
|
|
5965
|
+
return (0,_string_trim_js__WEBPACK_IMPORTED_MODULE_4__.trim)((0,_tag_scan_js__WEBPACK_IMPORTED_MODULE_2__.removeWordWrappers)(html));
|
|
5820
5966
|
}
|
|
5821
5967
|
|
|
5822
5968
|
|
|
@@ -5831,9 +5977,10 @@ function normalizeCSS(s) {
|
|
|
5831
5977
|
/* harmony import */ var _constants_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(82758);
|
|
5832
5978
|
/* harmony import */ var _dom_dom_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2748);
|
|
5833
5979
|
/* harmony import */ var _array_to_array_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4510);
|
|
5834
|
-
/* harmony import */ var
|
|
5835
|
-
/* harmony import */ var
|
|
5836
|
-
/* harmony import */ var
|
|
5980
|
+
/* harmony import */ var _tag_scan_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(76241);
|
|
5981
|
+
/* harmony import */ var _word_lists_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(90723);
|
|
5982
|
+
/* harmony import */ var _string_trim_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(49055);
|
|
5983
|
+
/* harmony import */ var _utils_attr_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(29960);
|
|
5837
5984
|
/*!
|
|
5838
5985
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
5839
5986
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -5846,6 +5993,7 @@ function normalizeCSS(s) {
|
|
|
5846
5993
|
|
|
5847
5994
|
|
|
5848
5995
|
|
|
5996
|
+
|
|
5849
5997
|
/**
|
|
5850
5998
|
* The method automatically cleans up content from Microsoft Word and other HTML sources to ensure clean, compliant
|
|
5851
5999
|
* content that matches the look and feel of the site.
|
|
@@ -5859,7 +6007,7 @@ function normalizeCSS(s) {
|
|
|
5859
6007
|
const div = _constants_js__WEBPACK_IMPORTED_MODULE_0__.globalDocument.createElement('div');
|
|
5860
6008
|
div.innerHTML = html;
|
|
5861
6009
|
const marks = [];
|
|
5862
|
-
const listItems = (0,
|
|
6010
|
+
const listItems = (0,_word_lists_js__WEBPACK_IMPORTED_MODULE_4__.readWordListItems)(div);
|
|
5863
6011
|
if (div.firstChild) {
|
|
5864
6012
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.each(div, (node)=>{
|
|
5865
6013
|
if (!node) {
|
|
@@ -5884,7 +6032,7 @@ function normalizeCSS(s) {
|
|
|
5884
6032
|
// with `mso-list:Ignore`. They are display-only
|
|
5885
6033
|
// and must not be imported, otherwise the marker
|
|
5886
6034
|
// text leaks into the content. See #948
|
|
5887
|
-
if (/mso-list:\s*ignore/i.test((0,
|
|
6035
|
+
if (/mso-list:\s*ignore/i.test((0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_6__.attr)(node, 'style') || '')) {
|
|
5888
6036
|
marks.push(node);
|
|
5889
6037
|
break;
|
|
5890
6038
|
}
|
|
@@ -5898,7 +6046,7 @@ function normalizeCSS(s) {
|
|
|
5898
6046
|
// `attrRaw`: SVG keeps camelCase names
|
|
5899
6047
|
// (`viewBox`), `attr()` would kebab-case
|
|
5900
6048
|
// them and silently skip the removal
|
|
5901
|
-
(0,
|
|
6049
|
+
(0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_6__.attrRaw)(node, attribute.name, null);
|
|
5902
6050
|
}
|
|
5903
6051
|
});
|
|
5904
6052
|
}
|
|
@@ -5911,14 +6059,14 @@ function normalizeCSS(s) {
|
|
|
5911
6059
|
});
|
|
5912
6060
|
}
|
|
5913
6061
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove.apply(null, marks);
|
|
5914
|
-
(0,
|
|
6062
|
+
(0,_word_lists_js__WEBPACK_IMPORTED_MODULE_4__.wrapWordListItems)(listItems);
|
|
5915
6063
|
convertedString = div.innerHTML;
|
|
5916
6064
|
} catch (e) {}
|
|
5917
6065
|
if (convertedString) {
|
|
5918
6066
|
html = convertedString;
|
|
5919
6067
|
}
|
|
5920
|
-
html = html.split(/(\n)/).filter(
|
|
5921
|
-
return
|
|
6068
|
+
html = html.split(/(\n)/).filter(_string_trim_js__WEBPACK_IMPORTED_MODULE_5__.trim).join('\n');
|
|
6069
|
+
return (0,_tag_scan_js__WEBPACK_IMPORTED_MODULE_3__.removeWordWrappers)(html);
|
|
5922
6070
|
}
|
|
5923
6071
|
|
|
5924
6072
|
|
|
@@ -5956,10 +6104,17 @@ function normalizeCSS(s) {
|
|
|
5956
6104
|
/* harmony export */ applyStyles: function() { return /* reexport safe */ _apply_styles_js__WEBPACK_IMPORTED_MODULE_0__.applyStyles; },
|
|
5957
6105
|
/* harmony export */ cleanFromWord: function() { return /* reexport safe */ _clean_from_word_js__WEBPACK_IMPORTED_MODULE_1__.cleanFromWord; },
|
|
5958
6106
|
/* harmony export */ htmlspecialchars: function() { return /* reexport safe */ _htmlspecialchars_js__WEBPACK_IMPORTED_MODULE_2__.htmlspecialchars; },
|
|
6107
|
+
/* harmony export */ indexOfClosingTag: function() { return /* reexport safe */ _tag_scan_js__WEBPACK_IMPORTED_MODULE_6__.indexOfClosingTag; },
|
|
6108
|
+
/* harmony export */ indexOfOpenTag: function() { return /* reexport safe */ _tag_scan_js__WEBPACK_IMPORTED_MODULE_6__.indexOfOpenTag; },
|
|
5959
6109
|
/* harmony export */ nl2br: function() { return /* reexport safe */ _nl2br_js__WEBPACK_IMPORTED_MODULE_3__.nl2br; },
|
|
6110
|
+
/* harmony export */ removeBetween: function() { return /* reexport safe */ _tag_scan_js__WEBPACK_IMPORTED_MODULE_6__.removeBetween; },
|
|
6111
|
+
/* harmony export */ removeEmptyMarkedTags: function() { return /* reexport safe */ _tag_scan_js__WEBPACK_IMPORTED_MODULE_6__.removeEmptyMarkedTags; },
|
|
6112
|
+
/* harmony export */ removeTagsByPrefix: function() { return /* reexport safe */ _tag_scan_js__WEBPACK_IMPORTED_MODULE_6__.removeTagsByPrefix; },
|
|
6113
|
+
/* harmony export */ removeWordWrappers: function() { return /* reexport safe */ _tag_scan_js__WEBPACK_IMPORTED_MODULE_6__.removeWordWrappers; },
|
|
5960
6114
|
/* harmony export */ safeHTML: function() { return /* reexport safe */ _safe_html_js__WEBPACK_IMPORTED_MODULE_4__.safeHTML; },
|
|
5961
6115
|
/* harmony export */ sanitizeHTMLElement: function() { return /* reexport safe */ _safe_html_js__WEBPACK_IMPORTED_MODULE_4__.sanitizeHTMLElement; },
|
|
5962
|
-
/* harmony export */ stripTags: function() { return /* reexport safe */ _strip_tags_js__WEBPACK_IMPORTED_MODULE_5__.stripTags; }
|
|
6116
|
+
/* harmony export */ stripTags: function() { return /* reexport safe */ _strip_tags_js__WEBPACK_IMPORTED_MODULE_5__.stripTags; },
|
|
6117
|
+
/* harmony export */ unwrapMarkedTags: function() { return /* reexport safe */ _tag_scan_js__WEBPACK_IMPORTED_MODULE_6__.unwrapMarkedTags; }
|
|
5963
6118
|
/* harmony export */ });
|
|
5964
6119
|
/* harmony import */ var _apply_styles_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(32574);
|
|
5965
6120
|
/* harmony import */ var _clean_from_word_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(53212);
|
|
@@ -5967,6 +6122,7 @@ function normalizeCSS(s) {
|
|
|
5967
6122
|
/* harmony import */ var _nl2br_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(45971);
|
|
5968
6123
|
/* harmony import */ var _safe_html_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(86518);
|
|
5969
6124
|
/* harmony import */ var _strip_tags_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(91003);
|
|
6125
|
+
/* harmony import */ var _tag_scan_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(76241);
|
|
5970
6126
|
/*!
|
|
5971
6127
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
5972
6128
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -5981,6 +6137,7 @@ function normalizeCSS(s) {
|
|
|
5981
6137
|
|
|
5982
6138
|
|
|
5983
6139
|
|
|
6140
|
+
|
|
5984
6141
|
/***/ }),
|
|
5985
6142
|
|
|
5986
6143
|
/***/ 45971:
|
|
@@ -6334,6 +6491,281 @@ function restoreTags(content) {
|
|
|
6334
6491
|
}
|
|
6335
6492
|
|
|
6336
6493
|
|
|
6494
|
+
/***/ }),
|
|
6495
|
+
|
|
6496
|
+
/***/ 76241:
|
|
6497
|
+
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
6498
|
+
|
|
6499
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
6500
|
+
/* harmony export */ indexOfClosingTag: function() { return /* binding */ indexOfClosingTag; },
|
|
6501
|
+
/* harmony export */ indexOfOpenTag: function() { return /* binding */ indexOfOpenTag; },
|
|
6502
|
+
/* harmony export */ removeBetween: function() { return /* binding */ removeBetween; },
|
|
6503
|
+
/* harmony export */ removeEmptyMarkedTags: function() { return /* binding */ removeEmptyMarkedTags; },
|
|
6504
|
+
/* harmony export */ removeTagsByPrefix: function() { return /* binding */ removeTagsByPrefix; },
|
|
6505
|
+
/* harmony export */ removeWordWrappers: function() { return /* binding */ removeWordWrappers; },
|
|
6506
|
+
/* harmony export */ unwrapMarkedTags: function() { return /* binding */ unwrapMarkedTags; }
|
|
6507
|
+
/* harmony export */ });
|
|
6508
|
+
/*!
|
|
6509
|
+
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
6510
|
+
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
6511
|
+
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net
|
|
6512
|
+
*/ /**
|
|
6513
|
+
* @module helpers/html
|
|
6514
|
+
*/ // Single passes over HTML that comes from the clipboard or the editor value.
|
|
6515
|
+
// A regex with `[^>]*` or `.*?` before a required literal backtracks
|
|
6516
|
+
// quadratically on a long run of tag openers, so these walk with `indexOf`.
|
|
6517
|
+
const TAG_NAME = /[a-z0-9:-]/i;
|
|
6518
|
+
// The tags the Word clean-up strips: `<html>`, `<colgroup>`, `<col>`, `<o:p>` and their closers
|
|
6519
|
+
const WORD_WRAPPER_TAGS = [
|
|
6520
|
+
'<html',
|
|
6521
|
+
'</html',
|
|
6522
|
+
'<col',
|
|
6523
|
+
'</col',
|
|
6524
|
+
'<o:p',
|
|
6525
|
+
'</o:p'
|
|
6526
|
+
];
|
|
6527
|
+
function startsWithIgnoreCase(html, index, prefix) {
|
|
6528
|
+
return html.substr(index, prefix.length).toLowerCase() === prefix;
|
|
6529
|
+
}
|
|
6530
|
+
// The first `<` at or after `from` that opens one of the prefixes (`<meta`, `</html`, `<!--`)
|
|
6531
|
+
function indexOfPrefix(html, prefixes, from) {
|
|
6532
|
+
let index = html.indexOf('<', from);
|
|
6533
|
+
while(index !== -1){
|
|
6534
|
+
for (const prefix of prefixes){
|
|
6535
|
+
if (startsWithIgnoreCase(html, index, prefix)) {
|
|
6536
|
+
return [
|
|
6537
|
+
index,
|
|
6538
|
+
prefix
|
|
6539
|
+
];
|
|
6540
|
+
}
|
|
6541
|
+
}
|
|
6542
|
+
index = html.indexOf('<', index + 1);
|
|
6543
|
+
}
|
|
6544
|
+
return [
|
|
6545
|
+
-1,
|
|
6546
|
+
''
|
|
6547
|
+
];
|
|
6548
|
+
}
|
|
6549
|
+
/**
|
|
6550
|
+
* The first `</name>` at or after `from`, case-insensitive, or -1
|
|
6551
|
+
*/ function indexOfClosingTag(html, name, from) {
|
|
6552
|
+
const closing = '</' + name + '>';
|
|
6553
|
+
let index = html.indexOf('</', from);
|
|
6554
|
+
while(index !== -1){
|
|
6555
|
+
if (startsWithIgnoreCase(html, index, closing)) {
|
|
6556
|
+
return index;
|
|
6557
|
+
}
|
|
6558
|
+
index = html.indexOf('</', index + 2);
|
|
6559
|
+
}
|
|
6560
|
+
return -1;
|
|
6561
|
+
}
|
|
6562
|
+
/**
|
|
6563
|
+
* Remove every tag that starts with one of the prefixes, up to its `>`:
|
|
6564
|
+
* `removeTagsByPrefix(html, ['<meta', '<!--'])`
|
|
6565
|
+
*/ function removeTagsByPrefix(html, prefixes) {
|
|
6566
|
+
const lower = prefixes.map((prefix)=>prefix.toLowerCase());
|
|
6567
|
+
let result = '';
|
|
6568
|
+
let cursor = 0;
|
|
6569
|
+
for(;;){
|
|
6570
|
+
const [start] = indexOfPrefix(html, lower, cursor);
|
|
6571
|
+
if (start === -1) {
|
|
6572
|
+
break;
|
|
6573
|
+
}
|
|
6574
|
+
const end = html.indexOf('>', start);
|
|
6575
|
+
if (end === -1) {
|
|
6576
|
+
break;
|
|
6577
|
+
}
|
|
6578
|
+
result += html.slice(cursor, start);
|
|
6579
|
+
cursor = end + 1;
|
|
6580
|
+
}
|
|
6581
|
+
return cursor === 0 ? html : result + html.slice(cursor);
|
|
6582
|
+
}
|
|
6583
|
+
/**
|
|
6584
|
+
* Strip the Word wrapper tags and then the comments, as the clean-up always did
|
|
6585
|
+
*/ function removeWordWrappers(html) {
|
|
6586
|
+
return removeTagsByPrefix(removeTagsByPrefix(html, WORD_WRAPPER_TAGS), [
|
|
6587
|
+
'<!--'
|
|
6588
|
+
]);
|
|
6589
|
+
}
|
|
6590
|
+
// Every `</name>` position by name, so the closer of an element is found by a binary search
|
|
6591
|
+
function closingTagPositions(html) {
|
|
6592
|
+
const positions = new Map();
|
|
6593
|
+
let index = html.indexOf('</');
|
|
6594
|
+
while(index !== -1){
|
|
6595
|
+
const name = readTagName(html, index + 2).toLowerCase();
|
|
6596
|
+
if (name !== '' && html.charAt(index + 2 + name.length) === '>') {
|
|
6597
|
+
const list = positions.get(name);
|
|
6598
|
+
if (list) {
|
|
6599
|
+
list.push(index);
|
|
6600
|
+
} else {
|
|
6601
|
+
positions.set(name, [
|
|
6602
|
+
index
|
|
6603
|
+
]);
|
|
6604
|
+
}
|
|
6605
|
+
}
|
|
6606
|
+
index = html.indexOf('</', index + 2);
|
|
6607
|
+
}
|
|
6608
|
+
return positions;
|
|
6609
|
+
}
|
|
6610
|
+
// The first position in the sorted list that is >= from, or -1
|
|
6611
|
+
function firstAfter(list, from) {
|
|
6612
|
+
if (!list) {
|
|
6613
|
+
return -1;
|
|
6614
|
+
}
|
|
6615
|
+
let low = 0;
|
|
6616
|
+
let high = list.length;
|
|
6617
|
+
while(low < high){
|
|
6618
|
+
const middle = low + high >> 1;
|
|
6619
|
+
if (list[middle] < from) {
|
|
6620
|
+
low = middle + 1;
|
|
6621
|
+
} else {
|
|
6622
|
+
high = middle;
|
|
6623
|
+
}
|
|
6624
|
+
}
|
|
6625
|
+
return low < list.length ? list[low] : -1;
|
|
6626
|
+
}
|
|
6627
|
+
/**
|
|
6628
|
+
* The index of the first `<name>` or `<name …>` tag, or -1
|
|
6629
|
+
*/ function indexOfOpenTag(html, name) {
|
|
6630
|
+
const prefix = '<' + name.toLowerCase();
|
|
6631
|
+
let cursor = 0;
|
|
6632
|
+
for(;;){
|
|
6633
|
+
const [start] = indexOfPrefix(html, [
|
|
6634
|
+
prefix
|
|
6635
|
+
], cursor);
|
|
6636
|
+
if (start === -1) {
|
|
6637
|
+
return -1;
|
|
6638
|
+
}
|
|
6639
|
+
const next = html.charAt(start + prefix.length);
|
|
6640
|
+
if (next === '>') {
|
|
6641
|
+
return start;
|
|
6642
|
+
}
|
|
6643
|
+
if (/\s/.test(next)) {
|
|
6644
|
+
if (html.indexOf('>', start) === -1) {
|
|
6645
|
+
return -1;
|
|
6646
|
+
}
|
|
6647
|
+
return start;
|
|
6648
|
+
}
|
|
6649
|
+
cursor = start + 1;
|
|
6650
|
+
}
|
|
6651
|
+
}
|
|
6652
|
+
function readTagName(html, from) {
|
|
6653
|
+
let end = from;
|
|
6654
|
+
while(TAG_NAME.test(html.charAt(end))){
|
|
6655
|
+
end += 1;
|
|
6656
|
+
}
|
|
6657
|
+
return html.slice(from, end);
|
|
6658
|
+
}
|
|
6659
|
+
/**
|
|
6660
|
+
* Replace every `<name … marker …>inner</name>` with `inner`.
|
|
6661
|
+
* `name` null takes any tag; `keep` can refuse an element by its inner HTML.
|
|
6662
|
+
*/ function unwrapMarkedTags(html, name, marker, keep) {
|
|
6663
|
+
const lowerMarker = marker.toLowerCase();
|
|
6664
|
+
const prefixes = [
|
|
6665
|
+
name == null ? '<' : '<' + name.toLowerCase()
|
|
6666
|
+
];
|
|
6667
|
+
const closings = closingTagPositions(html);
|
|
6668
|
+
let result = '';
|
|
6669
|
+
let cursor = 0;
|
|
6670
|
+
for(;;){
|
|
6671
|
+
const [start] = indexOfPrefix(html, prefixes, cursor);
|
|
6672
|
+
if (start === -1) {
|
|
6673
|
+
break;
|
|
6674
|
+
}
|
|
6675
|
+
const tagName = (name !== null && name !== void 0 ? name : readTagName(html, start + 1)).toLowerCase();
|
|
6676
|
+
const gt = html.indexOf('>', start);
|
|
6677
|
+
if (gt === -1) {
|
|
6678
|
+
break;
|
|
6679
|
+
}
|
|
6680
|
+
const close = tagName !== '' && html.slice(start, gt).toLowerCase().includes(lowerMarker) ? firstAfter(closings.get(tagName), gt + 1) : -1;
|
|
6681
|
+
// Not a marked element: the `<` is text, the next one may still open an element
|
|
6682
|
+
if (close === -1) {
|
|
6683
|
+
result += html.slice(cursor, start + 1);
|
|
6684
|
+
cursor = start + 1;
|
|
6685
|
+
continue;
|
|
6686
|
+
}
|
|
6687
|
+
const inner = html.slice(gt + 1, close);
|
|
6688
|
+
const after = close + tagName.length + 3;
|
|
6689
|
+
result += html.slice(cursor, start);
|
|
6690
|
+
result += inner !== '' && (!keep || keep(inner)) ? inner : html.slice(start, after);
|
|
6691
|
+
cursor = after;
|
|
6692
|
+
}
|
|
6693
|
+
return cursor === 0 ? html : result + html.slice(cursor);
|
|
6694
|
+
}
|
|
6695
|
+
// The first `literal` at or after `from`, case-insensitive, or -1
|
|
6696
|
+
function indexOfLiteral(html, literal, from) {
|
|
6697
|
+
const head = literal.charAt(0);
|
|
6698
|
+
let index = html.indexOf(head, from);
|
|
6699
|
+
while(index !== -1){
|
|
6700
|
+
if (startsWithIgnoreCase(html, index, literal)) {
|
|
6701
|
+
return index;
|
|
6702
|
+
}
|
|
6703
|
+
index = html.indexOf(head, index + 1);
|
|
6704
|
+
}
|
|
6705
|
+
return -1;
|
|
6706
|
+
}
|
|
6707
|
+
/**
|
|
6708
|
+
* Remove every `open … openEnd … close` block whose opener holds `marker` (any opener when it is ''):
|
|
6709
|
+
* `removeBetween(html, '<style', '>', '</style>', 'jodit-box')`
|
|
6710
|
+
*/ function removeBetween(html, open, openEnd, close, marker = '') {
|
|
6711
|
+
const lowerOpen = open.toLowerCase();
|
|
6712
|
+
const lowerMarker = marker.toLowerCase();
|
|
6713
|
+
let result = '';
|
|
6714
|
+
let cursor = 0;
|
|
6715
|
+
for(;;){
|
|
6716
|
+
const start = indexOfLiteral(html, lowerOpen, cursor);
|
|
6717
|
+
if (start === -1) {
|
|
6718
|
+
break;
|
|
6719
|
+
}
|
|
6720
|
+
const end = indexOfLiteral(html, openEnd, start + open.length);
|
|
6721
|
+
if (end === -1) {
|
|
6722
|
+
break;
|
|
6723
|
+
}
|
|
6724
|
+
if (lowerMarker !== '' && !html.slice(start, end).toLowerCase().includes(lowerMarker)) {
|
|
6725
|
+
result += html.slice(cursor, end + openEnd.length);
|
|
6726
|
+
cursor = end + openEnd.length;
|
|
6727
|
+
continue;
|
|
6728
|
+
}
|
|
6729
|
+
const closeIndex = indexOfLiteral(html, close, end + openEnd.length);
|
|
6730
|
+
if (closeIndex === -1) {
|
|
6731
|
+
break;
|
|
6732
|
+
}
|
|
6733
|
+
result += html.slice(cursor, start);
|
|
6734
|
+
cursor = closeIndex + close.length;
|
|
6735
|
+
}
|
|
6736
|
+
return cursor === 0 ? html : result + html.slice(cursor);
|
|
6737
|
+
}
|
|
6738
|
+
/**
|
|
6739
|
+
* Remove every empty `<name … marker …></name>` element
|
|
6740
|
+
*/ function removeEmptyMarkedTags(html, name, marker) {
|
|
6741
|
+
const lowerName = name.toLowerCase();
|
|
6742
|
+
const lowerMarker = marker.toLowerCase();
|
|
6743
|
+
const closing = '</' + lowerName + '>';
|
|
6744
|
+
let result = '';
|
|
6745
|
+
let cursor = 0;
|
|
6746
|
+
for(;;){
|
|
6747
|
+
const [start] = indexOfPrefix(html, [
|
|
6748
|
+
'<' + lowerName
|
|
6749
|
+
], cursor);
|
|
6750
|
+
if (start === -1) {
|
|
6751
|
+
break;
|
|
6752
|
+
}
|
|
6753
|
+
const gt = html.indexOf('>', start);
|
|
6754
|
+
if (gt === -1) {
|
|
6755
|
+
break;
|
|
6756
|
+
}
|
|
6757
|
+
if (html.slice(start, gt).toLowerCase().includes(lowerMarker) && startsWithIgnoreCase(html, gt + 1, closing)) {
|
|
6758
|
+
result += html.slice(cursor, start);
|
|
6759
|
+
cursor = gt + 1 + closing.length;
|
|
6760
|
+
continue;
|
|
6761
|
+
}
|
|
6762
|
+
result += html.slice(cursor, gt + 1);
|
|
6763
|
+
cursor = gt + 1;
|
|
6764
|
+
}
|
|
6765
|
+
return cursor === 0 ? html : result + html.slice(cursor);
|
|
6766
|
+
}
|
|
6767
|
+
|
|
6768
|
+
|
|
6337
6769
|
/***/ }),
|
|
6338
6770
|
|
|
6339
6771
|
/***/ 90723:
|
|
@@ -6586,6 +7018,8 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
6586
7018
|
/* harmony export */ humanSizeToBytes: function() { return /* reexport safe */ _utils_index_js__WEBPACK_IMPORTED_MODULE_8__.humanSizeToBytes; },
|
|
6587
7019
|
/* harmony export */ i18n: function() { return /* reexport safe */ _string_index_js__WEBPACK_IMPORTED_MODULE_7__.i18n; },
|
|
6588
7020
|
/* harmony export */ inView: function() { return /* reexport safe */ _utils_index_js__WEBPACK_IMPORTED_MODULE_8__.inView; },
|
|
7021
|
+
/* harmony export */ indexOfClosingTag: function() { return /* reexport safe */ _html_index_js__WEBPACK_IMPORTED_MODULE_4__.indexOfClosingTag; },
|
|
7022
|
+
/* harmony export */ indexOfOpenTag: function() { return /* reexport safe */ _html_index_js__WEBPACK_IMPORTED_MODULE_4__.indexOfOpenTag; },
|
|
6589
7023
|
/* harmony export */ innerWidth: function() { return /* reexport safe */ _size_index_js__WEBPACK_IMPORTED_MODULE_6__.innerWidth; },
|
|
6590
7024
|
/* harmony export */ isAbortError: function() { return /* reexport safe */ _checker_index_js__WEBPACK_IMPORTED_MODULE_2__.isAbortError; },
|
|
6591
7025
|
/* harmony export */ isArray: function() { return /* reexport safe */ _checker_index_js__WEBPACK_IMPORTED_MODULE_2__.isArray; },
|
|
@@ -6644,6 +7078,10 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
6644
7078
|
/* harmony export */ prepareMedia: function() { return /* reexport safe */ _utils_index_js__WEBPACK_IMPORTED_MODULE_8__.prepareMedia; },
|
|
6645
7079
|
/* harmony export */ previewBox: function() { return /* reexport safe */ _utils_index_js__WEBPACK_IMPORTED_MODULE_8__.previewBox; },
|
|
6646
7080
|
/* harmony export */ refs: function() { return /* reexport safe */ _utils_index_js__WEBPACK_IMPORTED_MODULE_8__.refs; },
|
|
7081
|
+
/* harmony export */ removeBetween: function() { return /* reexport safe */ _html_index_js__WEBPACK_IMPORTED_MODULE_4__.removeBetween; },
|
|
7082
|
+
/* harmony export */ removeEmptyMarkedTags: function() { return /* reexport safe */ _html_index_js__WEBPACK_IMPORTED_MODULE_4__.removeEmptyMarkedTags; },
|
|
7083
|
+
/* harmony export */ removeTagsByPrefix: function() { return /* reexport safe */ _html_index_js__WEBPACK_IMPORTED_MODULE_4__.removeTagsByPrefix; },
|
|
7084
|
+
/* harmony export */ removeWordWrappers: function() { return /* reexport safe */ _html_index_js__WEBPACK_IMPORTED_MODULE_4__.removeWordWrappers; },
|
|
6647
7085
|
/* harmony export */ reset: function() { return /* reexport safe */ _utils_index_js__WEBPACK_IMPORTED_MODULE_8__.reset; },
|
|
6648
7086
|
/* harmony export */ resolveElement: function() { return /* reexport safe */ _utils_index_js__WEBPACK_IMPORTED_MODULE_8__.resolveElement; },
|
|
6649
7087
|
/* harmony export */ safeHTML: function() { return /* reexport safe */ _html_index_js__WEBPACK_IMPORTED_MODULE_4__.safeHTML; },
|
|
@@ -6660,7 +7098,9 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
6660
7098
|
/* harmony export */ trim: function() { return /* reexport safe */ _string_index_js__WEBPACK_IMPORTED_MODULE_7__.trim; },
|
|
6661
7099
|
/* harmony export */ trimChars: function() { return /* reexport safe */ _string_index_js__WEBPACK_IMPORTED_MODULE_7__.trimChars; },
|
|
6662
7100
|
/* harmony export */ trimInv: function() { return /* reexport safe */ _string_index_js__WEBPACK_IMPORTED_MODULE_7__.trimInv; },
|
|
7101
|
+
/* harmony export */ trimInvEnd: function() { return /* reexport safe */ _string_index_js__WEBPACK_IMPORTED_MODULE_7__.trimInvEnd; },
|
|
6663
7102
|
/* harmony export */ ucfirst: function() { return /* reexport safe */ _string_index_js__WEBPACK_IMPORTED_MODULE_7__.ucfirst; },
|
|
7103
|
+
/* harmony export */ unwrapMarkedTags: function() { return /* reexport safe */ _html_index_js__WEBPACK_IMPORTED_MODULE_4__.unwrapMarkedTags; },
|
|
6664
7104
|
/* harmony export */ wrapMedia: function() { return /* reexport safe */ _utils_index_js__WEBPACK_IMPORTED_MODULE_8__.wrapMedia; }
|
|
6665
7105
|
/* harmony export */ });
|
|
6666
7106
|
/* harmony import */ var _array_index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(76855);
|
|
@@ -7530,6 +7970,7 @@ function size(subject) {
|
|
|
7530
7970
|
/* harmony export */ trim: function() { return /* reexport safe */ _trim_js__WEBPACK_IMPORTED_MODULE_5__.trim; },
|
|
7531
7971
|
/* harmony export */ trimChars: function() { return /* reexport safe */ _trim_js__WEBPACK_IMPORTED_MODULE_5__.trimChars; },
|
|
7532
7972
|
/* harmony export */ trimInv: function() { return /* reexport safe */ _trim_js__WEBPACK_IMPORTED_MODULE_5__.trimInv; },
|
|
7973
|
+
/* harmony export */ trimInvEnd: function() { return /* reexport safe */ _trim_js__WEBPACK_IMPORTED_MODULE_5__.trimInvEnd; },
|
|
7533
7974
|
/* harmony export */ ucfirst: function() { return /* reexport safe */ _ucfirst_js__WEBPACK_IMPORTED_MODULE_6__.ucfirst; }
|
|
7534
7975
|
/* harmony export */ });
|
|
7535
7976
|
/* harmony import */ var _camel_case_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(87058);
|
|
@@ -7622,29 +8063,51 @@ const CamelCaseToKebabCase = (key)=>{
|
|
|
7622
8063
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
7623
8064
|
/* harmony export */ trim: function() { return /* binding */ trim; },
|
|
7624
8065
|
/* harmony export */ trimChars: function() { return /* binding */ trimChars; },
|
|
7625
|
-
/* harmony export */ trimInv: function() { return /* binding */ trimInv; }
|
|
8066
|
+
/* harmony export */ trimInv: function() { return /* binding */ trimInv; },
|
|
8067
|
+
/* harmony export */ trimInvEnd: function() { return /* binding */ trimInvEnd; }
|
|
7626
8068
|
/* harmony export */ });
|
|
7627
|
-
/* harmony import */ var _constants_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(82758);
|
|
7628
8069
|
/*!
|
|
7629
8070
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
7630
8071
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
7631
8072
|
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net
|
|
7632
8073
|
*/ /**
|
|
7633
8074
|
* @module helpers/string
|
|
7634
|
-
*/
|
|
8075
|
+
*/ const SPACE = /[\s\u200b]/;
|
|
8076
|
+
const INVISIBLE = /\uFEFF/;
|
|
8077
|
+
// Cut the chars matching `char` from both ends; `[…]+$` backtracks on a long run that is not at the end
|
|
8078
|
+
function trimBy(value, char) {
|
|
8079
|
+
let start = 0;
|
|
8080
|
+
let end = value.length;
|
|
8081
|
+
while(start < end && char.test(value.charAt(start))){
|
|
8082
|
+
start += 1;
|
|
8083
|
+
}
|
|
8084
|
+
while(end > start && char.test(value.charAt(end - 1))){
|
|
8085
|
+
end -= 1;
|
|
8086
|
+
}
|
|
8087
|
+
return start === 0 && end === value.length ? value : value.slice(start, end);
|
|
8088
|
+
}
|
|
7635
8089
|
/**
|
|
7636
8090
|
* It clears the line of all auxiliary invisible characters , from the spaces and line breaks , tabs
|
|
7637
8091
|
* from the beginning and end of the line
|
|
7638
8092
|
*/ function trim(value) {
|
|
7639
|
-
return value
|
|
8093
|
+
return trimBy(value, SPACE);
|
|
7640
8094
|
}
|
|
7641
8095
|
function trimChars(value, chars) {
|
|
7642
|
-
return value
|
|
8096
|
+
return trimBy(value, RegExp(`[${chars}]`));
|
|
7643
8097
|
}
|
|
7644
8098
|
/**
|
|
7645
8099
|
* Trim only invisible chars
|
|
7646
8100
|
*/ function trimInv(value) {
|
|
7647
|
-
return value
|
|
8101
|
+
return trimBy(value, INVISIBLE);
|
|
8102
|
+
}
|
|
8103
|
+
/**
|
|
8104
|
+
* Without the invisible chars at the end
|
|
8105
|
+
*/ function trimInvEnd(value) {
|
|
8106
|
+
let end = value.length;
|
|
8107
|
+
while(end > 0 && INVISIBLE.test(value.charAt(end - 1))){
|
|
8108
|
+
end -= 1;
|
|
8109
|
+
}
|
|
8110
|
+
return end === value.length ? value : value.slice(0, end);
|
|
7648
8111
|
}
|
|
7649
8112
|
|
|
7650
8113
|
|
|
@@ -10913,18 +11376,19 @@ function usable(ranges, shadowRoot) {
|
|
|
10913
11376
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
10914
11377
|
|
|
10915
11378
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
10916
|
-
/* harmony export */ composedRanges: function() { return /* reexport safe */
|
|
11379
|
+
/* harmony export */ composedRanges: function() { return /* reexport safe */ _composed_ranges_js__WEBPACK_IMPORTED_MODULE_3__.composedRanges; },
|
|
10917
11380
|
/* harmony export */ cursorInTheEdgeOfString: function() { return /* binding */ cursorInTheEdgeOfString; },
|
|
10918
11381
|
/* harmony export */ findCorrectCurrentNode: function() { return /* binding */ findCorrectCurrentNode; },
|
|
10919
|
-
/* harmony export */ isMoved: function() { return /* reexport safe */
|
|
10920
|
-
/* harmony export */ moveNodeInsideStart: function() { return /* reexport safe */
|
|
11382
|
+
/* harmony export */ isMoved: function() { return /* reexport safe */ _is_moved_js__WEBPACK_IMPORTED_MODULE_4__.isMoved; },
|
|
11383
|
+
/* harmony export */ moveNodeInsideStart: function() { return /* reexport safe */ _move_node_inside_start_js__WEBPACK_IMPORTED_MODULE_5__.moveNodeInsideStart; }
|
|
10921
11384
|
/* harmony export */ });
|
|
10922
11385
|
/* harmony import */ var _constants_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(82758);
|
|
10923
11386
|
/* harmony import */ var _dom_dom_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2748);
|
|
10924
|
-
/* harmony import */ var
|
|
10925
|
-
/* harmony import */ var
|
|
10926
|
-
/* harmony import */ var
|
|
10927
|
-
/* harmony import */ var
|
|
11387
|
+
/* harmony import */ var _helpers_string_trim_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(49055);
|
|
11388
|
+
/* harmony import */ var _composed_ranges_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(79505);
|
|
11389
|
+
/* harmony import */ var _is_moved_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(12604);
|
|
11390
|
+
/* harmony import */ var _move_node_inside_start_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(26716);
|
|
11391
|
+
/* harmony import */ var _move_the_node_along_the_edge_outward_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(43463);
|
|
10928
11392
|
/*!
|
|
10929
11393
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
10930
11394
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -10937,6 +11401,7 @@ function usable(ranges, shadowRoot) {
|
|
|
10937
11401
|
|
|
10938
11402
|
|
|
10939
11403
|
|
|
11404
|
+
|
|
10940
11405
|
/**
|
|
10941
11406
|
* Despite the name, returns `true` when the cursor is NOT at the checked edge
|
|
10942
11407
|
* of the text node: there is significant (non invisible-space) text between
|
|
@@ -10945,7 +11410,7 @@ function usable(ranges, shadowRoot) {
|
|
|
10945
11410
|
*/ function cursorInTheEdgeOfString(container, offset, start, end) {
|
|
10946
11411
|
var _a;
|
|
10947
11412
|
const text = ((_a = container.nodeValue) === null || _a === void 0 ? void 0 : _a.length) ? container.nodeValue : '';
|
|
10948
|
-
if (end &&
|
|
11413
|
+
if (end && (0,_helpers_string_trim_js__WEBPACK_IMPORTED_MODULE_2__.trimInvEnd)(text).length > offset) {
|
|
10949
11414
|
return true;
|
|
10950
11415
|
}
|
|
10951
11416
|
const inv = (0,_constants_js__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE_REG_EXP_START)().exec(text);
|
|
@@ -18211,11 +18676,12 @@ class CommitMode {
|
|
|
18211
18676
|
/* harmony import */ var _core_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(65478);
|
|
18212
18677
|
/* harmony import */ var _core_global_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(580);
|
|
18213
18678
|
/* harmony import */ var _core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(21537);
|
|
18214
|
-
/* harmony import */ var
|
|
18215
|
-
/* harmony import */ var
|
|
18216
|
-
/* harmony import */ var
|
|
18217
|
-
/* harmony import */ var
|
|
18218
|
-
/* harmony import */ var
|
|
18679
|
+
/* harmony import */ var _core_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(76241);
|
|
18680
|
+
/* harmony import */ var _core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(41180);
|
|
18681
|
+
/* harmony import */ var _core_request_index_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(41601);
|
|
18682
|
+
/* harmony import */ var _core_traits_dlgs_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(70231);
|
|
18683
|
+
/* harmony import */ var _config_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(6441);
|
|
18684
|
+
/* harmony import */ var _modules_index_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(41409);
|
|
18219
18685
|
/*!
|
|
18220
18686
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
18221
18687
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -18237,6 +18703,7 @@ var Jodit_1;
|
|
|
18237
18703
|
|
|
18238
18704
|
|
|
18239
18705
|
|
|
18706
|
+
|
|
18240
18707
|
const FOCUS_EVENTS = new Set([
|
|
18241
18708
|
'focus',
|
|
18242
18709
|
'blur',
|
|
@@ -18267,7 +18734,7 @@ const NOEDIT = {
|
|
|
18267
18734
|
* `alignClasses.img` when that isn't set
|
|
18268
18735
|
*/ function makeOptions(options) {
|
|
18269
18736
|
var _a;
|
|
18270
|
-
const opt = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.ConfigProto)(options || {},
|
|
18737
|
+
const opt = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.ConfigProto)(options || {}, _config_js__WEBPACK_IMPORTED_MODULE_8__.Config.defaultOptions);
|
|
18271
18738
|
if (opt.imageAlignClasses && !((_a = opt.alignClasses) === null || _a === void 0 ? void 0 : _a.img)) {
|
|
18272
18739
|
opt.alignClasses = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.ConfigProto)({
|
|
18273
18740
|
img: opt.imageAlignClasses
|
|
@@ -18275,7 +18742,7 @@ const NOEDIT = {
|
|
|
18275
18742
|
}
|
|
18276
18743
|
return opt;
|
|
18277
18744
|
}
|
|
18278
|
-
let Jodit = Jodit_1 = class Jodit extends
|
|
18745
|
+
let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MODULE_9__.ViewWithToolbar {
|
|
18279
18746
|
/** @override */ className() {
|
|
18280
18747
|
return 'Jodit';
|
|
18281
18748
|
}
|
|
@@ -18318,7 +18785,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
18318
18785
|
* Return a default timeout period in milliseconds for some debounce or throttle functions.
|
|
18319
18786
|
* By default, `{history.timeout}` options
|
|
18320
18787
|
*/ get defaultTimeout() {
|
|
18321
|
-
return (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.isNumber)(this.o.defaultTimeout) ? this.o.defaultTimeout :
|
|
18788
|
+
return (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.isNumber)(this.o.defaultTimeout) ? this.o.defaultTimeout : _config_js__WEBPACK_IMPORTED_MODULE_8__.Config.defaultOptions.defaultTimeout;
|
|
18322
18789
|
}
|
|
18323
18790
|
/**
|
|
18324
18791
|
* Method wrap usual object in Object helper for prevent deep object merging in options*
|
|
@@ -18348,7 +18815,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
18348
18815
|
/**
|
|
18349
18816
|
* Default settings
|
|
18350
18817
|
*/ static get defaultOptions() {
|
|
18351
|
-
return
|
|
18818
|
+
return _config_js__WEBPACK_IMPORTED_MODULE_8__.Config.defaultOptions;
|
|
18352
18819
|
}
|
|
18353
18820
|
/**
|
|
18354
18821
|
* Deep-merges partial options into the global defaults without replacing
|
|
@@ -18396,7 +18863,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
18396
18863
|
;(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.ConfigMerge)(Jodit_1.defaultOptions, options);
|
|
18397
18864
|
}
|
|
18398
18865
|
get createInside() {
|
|
18399
|
-
return new
|
|
18866
|
+
return new _modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Create(()=>this.ed, this.o.createAttributes);
|
|
18400
18867
|
}
|
|
18401
18868
|
__setPlaceField(field, value) {
|
|
18402
18869
|
if (!this.currentPlace) {
|
|
@@ -18596,7 +19063,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
18596
19063
|
}
|
|
18597
19064
|
value = this.getNativeEditorValue().replace(_core_constants_js__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE_REG_EXP(), '');
|
|
18598
19065
|
if (removeSelectionMarkers) {
|
|
18599
|
-
value =
|
|
19066
|
+
value = (0,_core_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_4__.removeEmptyMarkedTags)(value, 'span', 'id="jodit-selection_marker_');
|
|
18600
19067
|
}
|
|
18601
19068
|
if (value === '<br>') {
|
|
18602
19069
|
value = '';
|
|
@@ -18910,7 +19377,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
18910
19377
|
return this.getMode();
|
|
18911
19378
|
}
|
|
18912
19379
|
const active = this.od.activeElement;
|
|
18913
|
-
if (active && (active === this.iframe ||
|
|
19380
|
+
if (active && (active === this.iframe || _modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.isOrContains(this.editor, active) || _modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.isOrContains(this.toolbar.container, active))) {
|
|
18914
19381
|
return _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.MODE_WYSIWYG;
|
|
18915
19382
|
}
|
|
18916
19383
|
return _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.MODE_SOURCE;
|
|
@@ -19063,7 +19530,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
19063
19530
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.toArray)(element.attributes).forEach((attr)=>{
|
|
19064
19531
|
const name = attr.name;
|
|
19065
19532
|
let value = attr.value;
|
|
19066
|
-
if (
|
|
19533
|
+
if (_config_js__WEBPACK_IMPORTED_MODULE_8__.Config.defaultOptions[name] !== undefined && (!options || options[name] === undefined)) {
|
|
19067
19534
|
if ([
|
|
19068
19535
|
'readonly',
|
|
19069
19536
|
'disabled'
|
|
@@ -19100,7 +19567,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
19100
19567
|
container = element;
|
|
19101
19568
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.attr)(element, __defaultClassesKey, element.className.toString());
|
|
19102
19569
|
buffer = container.innerHTML;
|
|
19103
|
-
|
|
19570
|
+
_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.detach(container);
|
|
19104
19571
|
}
|
|
19105
19572
|
container.classList.add('jodit_inline');
|
|
19106
19573
|
container.classList.add('jodit-container');
|
|
@@ -19108,7 +19575,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
19108
19575
|
// actual for inline mode
|
|
19109
19576
|
if (element !== container) {
|
|
19110
19577
|
// hide source element
|
|
19111
|
-
const display = (0,
|
|
19578
|
+
const display = (0,_core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_5__.cssInline)(element, 'display');
|
|
19112
19579
|
if (display) {
|
|
19113
19580
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.attr)(element, __defaultStyleDisplayKey, display);
|
|
19114
19581
|
}
|
|
@@ -19120,21 +19587,21 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
19120
19587
|
// the toolbar box below it when (re)attaching the toolbar container.
|
|
19121
19588
|
const aboveSlot = this.c.div(this.getFullElName(SLOT, 'above'), NOEDIT);
|
|
19122
19589
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.attr)(aboveSlot, 'data-jodit-above-toolbar', '');
|
|
19123
|
-
|
|
19590
|
+
_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.appendChildFirst(container, aboveSlot);
|
|
19124
19591
|
const topSlot = this.c.div(this.getFullElName(SLOT, 'top'), NOEDIT);
|
|
19125
|
-
|
|
19592
|
+
_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.append(container, topSlot);
|
|
19126
19593
|
const centerSlot = this.c.div(this.getFullElName(SLOT, 'center'), NOEDIT);
|
|
19127
19594
|
const workplace = this.c.div('jodit-workplace', NOEDIT);
|
|
19128
19595
|
const leftSlot = this.c.div(this.getFullElName(SLOT, 'left'), NOEDIT);
|
|
19129
19596
|
const rightSlot = this.c.div(this.getFullElName(SLOT, 'right'), NOEDIT);
|
|
19130
|
-
|
|
19131
|
-
|
|
19132
|
-
|
|
19133
|
-
|
|
19597
|
+
_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.append(centerSlot, leftSlot);
|
|
19598
|
+
_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.append(centerSlot, workplace);
|
|
19599
|
+
_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.append(centerSlot, rightSlot);
|
|
19600
|
+
_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.append(container, centerSlot);
|
|
19134
19601
|
const bottomPanel = this.c.div(this.getFullElName(SLOT, 'bottom'), NOEDIT);
|
|
19135
|
-
|
|
19602
|
+
_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.append(container, bottomPanel);
|
|
19136
19603
|
if (element.parentNode && element !== container) {
|
|
19137
|
-
|
|
19604
|
+
_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.before(element, container);
|
|
19138
19605
|
}
|
|
19139
19606
|
Object.defineProperty(element, 'component', {
|
|
19140
19607
|
enumerable: false,
|
|
@@ -19146,7 +19613,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
19146
19613
|
'aria-disabled': false,
|
|
19147
19614
|
tabindex: this.o.tabIndex
|
|
19148
19615
|
});
|
|
19149
|
-
|
|
19616
|
+
_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.append(workplace, editor);
|
|
19150
19617
|
const currentPlace = {
|
|
19151
19618
|
editor,
|
|
19152
19619
|
element,
|
|
@@ -19160,9 +19627,9 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
19160
19627
|
left: leftSlot,
|
|
19161
19628
|
right: rightSlot
|
|
19162
19629
|
},
|
|
19163
|
-
statusbar: new
|
|
19630
|
+
statusbar: new _modules_index_js__WEBPACK_IMPORTED_MODULE_9__.StatusBar(this, container),
|
|
19164
19631
|
options: this.isReady ? makeOptions(options) : this.options,
|
|
19165
|
-
history: new
|
|
19632
|
+
history: new _modules_index_js__WEBPACK_IMPORTED_MODULE_9__.History(this),
|
|
19166
19633
|
editorWindow: this.ow
|
|
19167
19634
|
};
|
|
19168
19635
|
this.__elementToPlace.set(editor, currentPlace);
|
|
@@ -19195,7 +19662,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
19195
19662
|
return (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.callPromise)(initResult, init);
|
|
19196
19663
|
}
|
|
19197
19664
|
addDisclaimer(elm) {
|
|
19198
|
-
|
|
19665
|
+
_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.append(this.workplace, elm);
|
|
19199
19666
|
}
|
|
19200
19667
|
/**
|
|
19201
19668
|
* Set current place object
|
|
@@ -19258,7 +19725,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
19258
19725
|
return;
|
|
19259
19726
|
}
|
|
19260
19727
|
if (stayDefault === false || (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.isPromise)(stayDefault)) {
|
|
19261
|
-
|
|
19728
|
+
_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.safeRemove(defaultEditorArea);
|
|
19262
19729
|
}
|
|
19263
19730
|
addClassNames(this.o.editorClassName, this.editor);
|
|
19264
19731
|
if (this.o.style) {
|
|
@@ -19307,7 +19774,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
19307
19774
|
// and such an element stays in the editor
|
|
19308
19775
|
if (FOCUS_EVENTS.has(type)) {
|
|
19309
19776
|
const inner = type === 'focusin' || type === 'focusout';
|
|
19310
|
-
if (inner === (event.target === editor) ||
|
|
19777
|
+
if (inner === (event.target === editor) || _modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.isOrContains(editor, event.relatedTarget)) {
|
|
19311
19778
|
return;
|
|
19312
19779
|
}
|
|
19313
19780
|
if (inner) {
|
|
@@ -19344,7 +19811,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
19344
19811
|
});
|
|
19345
19812
|
}
|
|
19346
19813
|
fetch(url, options) {
|
|
19347
|
-
const ajax = new
|
|
19814
|
+
const ajax = new _core_request_index_js__WEBPACK_IMPORTED_MODULE_6__.Ajax({
|
|
19348
19815
|
url,
|
|
19349
19816
|
...options
|
|
19350
19817
|
}, this.o.defaultAjaxOptions);
|
|
@@ -19366,7 +19833,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
19366
19833
|
if (this.isInDestruct) {
|
|
19367
19834
|
return;
|
|
19368
19835
|
}
|
|
19369
|
-
this.setStatus(
|
|
19836
|
+
this.setStatus(_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.STATUSES.beforeDestruct);
|
|
19370
19837
|
this.__elementToPlace.clear();
|
|
19371
19838
|
(_a = (0,_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__.cached)(this, 'storage')) === null || _a === void 0 ? void 0 : _a.clear();
|
|
19372
19839
|
(_b = (0,_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__.cached)(this, 'buffer')) === null || _b === void 0 ? void 0 : _b.clear();
|
|
@@ -19404,17 +19871,17 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
19404
19871
|
this.e.off(container);
|
|
19405
19872
|
this.e.off(element);
|
|
19406
19873
|
this.e.off(editor);
|
|
19407
|
-
|
|
19408
|
-
|
|
19874
|
+
_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.safeRemove(workplace);
|
|
19875
|
+
_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.safeRemove(editor);
|
|
19409
19876
|
if (container !== element) {
|
|
19410
|
-
|
|
19877
|
+
_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.safeRemove(container);
|
|
19411
19878
|
}
|
|
19412
19879
|
Object.defineProperty(element, 'component', {
|
|
19413
19880
|
enumerable: false,
|
|
19414
19881
|
configurable: true,
|
|
19415
19882
|
value: null
|
|
19416
19883
|
});
|
|
19417
|
-
|
|
19884
|
+
_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Dom.safeRemove(iframe);
|
|
19418
19885
|
// inline mode
|
|
19419
19886
|
if (container === element) {
|
|
19420
19887
|
element.innerHTML = tmpValue;
|
|
@@ -19466,7 +19933,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
19466
19933
|
this.destruct();
|
|
19467
19934
|
throw e;
|
|
19468
19935
|
}
|
|
19469
|
-
this.setStatus(
|
|
19936
|
+
this.setStatus(_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.STATUSES.beforeInit);
|
|
19470
19937
|
this.id = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.attr)((0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.resolveElement)(element, this.o.shadowRoot || this.od), 'id') || new Date().getTime().toString();
|
|
19471
19938
|
_core_global_js__WEBPACK_IMPORTED_MODULE_2__.instances[this.id] = this;
|
|
19472
19939
|
this.attachEvents(options);
|
|
@@ -19476,7 +19943,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
19476
19943
|
}
|
|
19477
19944
|
});
|
|
19478
19945
|
this.e.on('prepareWYSIWYGEditor', this.__prepareWYSIWYGEditor);
|
|
19479
|
-
this.selection = new
|
|
19946
|
+
this.selection = new _modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Selection(this);
|
|
19480
19947
|
const beforeInitHookResult = this.beforeInitHook();
|
|
19481
19948
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.callPromise)(beforeInitHookResult, ()=>{
|
|
19482
19949
|
if (this.isInDestruct) {
|
|
@@ -19500,7 +19967,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
19500
19967
|
this.e.fire('afterInit', this);
|
|
19501
19968
|
}
|
|
19502
19969
|
;(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.callPromise)(this.afterInitHook());
|
|
19503
|
-
this.setStatus(
|
|
19970
|
+
this.setStatus(_modules_index_js__WEBPACK_IMPORTED_MODULE_9__.STATUSES.ready);
|
|
19504
19971
|
this.e.fire('afterConstructor', this);
|
|
19505
19972
|
};
|
|
19506
19973
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.callPromise)(addPlaceResult, init);
|
|
@@ -19516,7 +19983,7 @@ Jodit.constants = _core_constants_js__WEBPACK_IMPORTED_MODULE_0__;
|
|
|
19516
19983
|
Jodit.instances = _core_global_js__WEBPACK_IMPORTED_MODULE_2__.instances;
|
|
19517
19984
|
Jodit.lang = _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.lang;
|
|
19518
19985
|
Jodit.core = {
|
|
19519
|
-
Plugin:
|
|
19986
|
+
Plugin: _modules_index_js__WEBPACK_IMPORTED_MODULE_9__.Plugin
|
|
19520
19987
|
};
|
|
19521
19988
|
__decorate([
|
|
19522
19989
|
_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__.cache
|
|
@@ -19543,7 +20010,7 @@ __decorate([
|
|
|
19543
20010
|
_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__.autobind
|
|
19544
20011
|
], Jodit.prototype, "__prepareWYSIWYGEditor", null);
|
|
19545
20012
|
Jodit = Jodit_1 = __decorate([
|
|
19546
|
-
(0,_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__.derive)(
|
|
20013
|
+
(0,_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__.derive)(_core_traits_dlgs_js__WEBPACK_IMPORTED_MODULE_7__.Dlgs)
|
|
19547
20014
|
], Jodit);
|
|
19548
20015
|
|
|
19549
20016
|
function addClassNames(className, elm) {
|
|
@@ -38981,7 +39448,18 @@ const KEEPS_SPACES = new Set([
|
|
|
38981
39448
|
/**
|
|
38982
39449
|
* A plain space beside this neighbor isn't shown: there is none, or it's a
|
|
38983
39450
|
* line break, a block or text starting (or ending) with a plain space
|
|
38984
|
-
*/
|
|
39451
|
+
*/ // The run of spaces at the end (or the start) of the text becomes nbsp; counted, as `/ +$/` backtracks on a long run
|
|
39452
|
+
function replaceEdgeSpaces(text, atEnd) {
|
|
39453
|
+
let count = 0;
|
|
39454
|
+
while(count < text.length && text.charAt(atEnd ? text.length - 1 - count : count) === ' '){
|
|
39455
|
+
count += 1;
|
|
39456
|
+
}
|
|
39457
|
+
if (count === 0) {
|
|
39458
|
+
return text;
|
|
39459
|
+
}
|
|
39460
|
+
return atEnd ? text.slice(0, text.length - count) + _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.NBSP_SPACE.repeat(count) : _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.NBSP_SPACE.repeat(count) + text.slice(count);
|
|
39461
|
+
}
|
|
39462
|
+
function hidesSpace(neighbor, edge) {
|
|
38985
39463
|
var _a;
|
|
38986
39464
|
return !neighbor || _core_dom_index_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(neighbor, 'br') || _core_dom_index_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isBlock(neighbor) || _core_dom_index_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(neighbor) && edge.test((_a = neighbor.nodeValue) !== null && _a !== void 0 ? _a : '');
|
|
38987
39465
|
}
|
|
@@ -39166,10 +39644,10 @@ class deleteCommand extends _core_plugin_index_js__WEBPACK_IMPORTED_MODULE_5__.P
|
|
|
39166
39644
|
const before = this.__findNeighbor(fake, true, block);
|
|
39167
39645
|
const after = this.__findNeighbor(fake, false, block);
|
|
39168
39646
|
if (_core_dom_index_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(before) && hidesSpace(after, /^ /)) {
|
|
39169
|
-
before.nodeValue = before.nodeValue
|
|
39647
|
+
before.nodeValue = replaceEdgeSpaces(before.nodeValue, true);
|
|
39170
39648
|
}
|
|
39171
39649
|
if (_core_dom_index_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(after) && hidesSpace(before, / $/)) {
|
|
39172
|
-
after.nodeValue = after.nodeValue
|
|
39650
|
+
after.nodeValue = replaceEdgeSpaces(after.nodeValue, false);
|
|
39173
39651
|
}
|
|
39174
39652
|
}
|
|
39175
39653
|
/**
|
|
@@ -42182,7 +42660,8 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.iframeSandbox = null;
|
|
|
42182
42660
|
/* harmony import */ var _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2748);
|
|
42183
42661
|
/* harmony import */ var _core_global_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(580);
|
|
42184
42662
|
/* harmony import */ var _core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(21537);
|
|
42185
|
-
/* harmony import */ var
|
|
42663
|
+
/* harmony import */ var _core_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(76241);
|
|
42664
|
+
/* harmony import */ var _config_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(50963);
|
|
42186
42665
|
/*!
|
|
42187
42666
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
42188
42667
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -42193,6 +42672,7 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.iframeSandbox = null;
|
|
|
42193
42672
|
|
|
42194
42673
|
|
|
42195
42674
|
|
|
42675
|
+
|
|
42196
42676
|
/**
|
|
42197
42677
|
* Iframe plugin - use `iframe` instead of DIV in editor. It can be need when you want to attach custom styles in editor
|
|
42198
42678
|
* in backend of you system
|
|
@@ -42251,13 +42731,66 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.iframeSandbox = null;
|
|
|
42251
42731
|
const toggleEditable = ()=>{
|
|
42252
42732
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.attr)(doc.body, 'contenteditable', editor.getMode() !== _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.MODE_SOURCE && !editor.getReadOnly() || null);
|
|
42253
42733
|
};
|
|
42734
|
+
// The start of the whitespace run that ends at `to`
|
|
42735
|
+
const skipBack = (text, to)=>{
|
|
42736
|
+
while(to > 0 && /\s/.test(text.charAt(to - 1))){
|
|
42737
|
+
to -= 1;
|
|
42738
|
+
}
|
|
42739
|
+
return to;
|
|
42740
|
+
};
|
|
42741
|
+
// The editor's own attributes on `<body>`: `min-height` and `contenteditable=true`
|
|
42742
|
+
const cleanBodyTag = (tag)=>{
|
|
42743
|
+
tag = tag.replace(/min-height["'\s]*:[\s"']*[0-9]+(px|%)/i, '');
|
|
42744
|
+
const skip = (from, chars)=>{
|
|
42745
|
+
while(chars.test(tag.charAt(from))){
|
|
42746
|
+
from += 1;
|
|
42747
|
+
}
|
|
42748
|
+
return from;
|
|
42749
|
+
};
|
|
42750
|
+
let index = tag.indexOf('contenteditable');
|
|
42751
|
+
while(index !== -1){
|
|
42752
|
+
let to = skip(index + 'contenteditable'.length, /["'\s]/);
|
|
42753
|
+
if (tag.charAt(to) === '=') {
|
|
42754
|
+
to = skip(to + 1, /[\s"']/);
|
|
42755
|
+
if (tag.startsWith('true', to)) {
|
|
42756
|
+
to = skip(to + 4, /["']/);
|
|
42757
|
+
let from = index;
|
|
42758
|
+
if (/["']/.test(tag.charAt(from - 1))) {
|
|
42759
|
+
from -= 1;
|
|
42760
|
+
}
|
|
42761
|
+
from = skipBack(tag, from);
|
|
42762
|
+
return tag.slice(0, from) + tag.slice(to);
|
|
42763
|
+
}
|
|
42764
|
+
}
|
|
42765
|
+
index = tag.indexOf('contenteditable', index + 1);
|
|
42766
|
+
}
|
|
42767
|
+
return tag;
|
|
42768
|
+
};
|
|
42254
42769
|
const clearMarkers = (html)=>{
|
|
42255
42770
|
// The plugins' own styles, from `getContainer`, aren't part of the value
|
|
42256
|
-
html =
|
|
42257
|
-
const
|
|
42258
|
-
|
|
42259
|
-
|
|
42260
|
-
|
|
42771
|
+
html = (0,_core_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_4__.removeBetween)(html, '<style', '>', '</style>', 'jodit-box');
|
|
42772
|
+
const bodyStart = (0,_core_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_4__.indexOfOpenTag)(html, 'body');
|
|
42773
|
+
let bodyEnd = -1;
|
|
42774
|
+
for(let index = (0,_core_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_4__.indexOfClosingTag)(html, 'body', bodyStart + 1); index !== -1; index = (0,_core_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_4__.indexOfClosingTag)(html, 'body', index + 1)){
|
|
42775
|
+
bodyEnd = index;
|
|
42776
|
+
}
|
|
42777
|
+
if (bodyStart !== -1 && bodyEnd !== -1) {
|
|
42778
|
+
const afterBody = bodyEnd + '</body>'.length;
|
|
42779
|
+
const gt = html.indexOf('>', bodyStart);
|
|
42780
|
+
let body = html.slice(bodyStart, afterBody);
|
|
42781
|
+
if (gt !== -1 && gt < bodyEnd) {
|
|
42782
|
+
body = cleanBodyTag(html.slice(bodyStart, gt)) + html.slice(gt, afterBody);
|
|
42783
|
+
}
|
|
42784
|
+
for (const tag of [
|
|
42785
|
+
'style',
|
|
42786
|
+
'script',
|
|
42787
|
+
'span'
|
|
42788
|
+
]){
|
|
42789
|
+
body = (0,_core_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_4__.removeBetween)(body, '<' + tag, '>', '</' + tag + '>', 'jodit');
|
|
42790
|
+
}
|
|
42791
|
+
// remove markers: the spans outside the body are the editor's own
|
|
42792
|
+
const stripSpans = (part)=>(0,_core_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_4__.removeBetween)((0,_core_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_4__.removeBetween)(part, '<span', '>', '</span>'), '<span', '>', '</span>');
|
|
42793
|
+
html = (stripSpans(html.slice(0, bodyStart)) + body + stripSpans(html.slice(afterBody))).replace(/(class\s*=\s*)(['"])([^"']*)(jodit-wysiwyg|jodit)([^"']*\2)/g, '$1$2$3$5').replace(/(<[^<]+?)\sclass="[\s]*"/gim, '$1').replace(/(<[^<]+?)\sstyle="[\s;]*"/gim, '$1').replace(/(<[^<]+?)\sdir="[\s]*"/gim, '$1');
|
|
42261
42794
|
}
|
|
42262
42795
|
return html;
|
|
42263
42796
|
};
|
|
@@ -48111,9 +48644,10 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.mediaWrappers = {};
|
|
|
48111
48644
|
/* harmony import */ var _core_constants_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(82758);
|
|
48112
48645
|
/* harmony import */ var _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2748);
|
|
48113
48646
|
/* harmony import */ var _core_global_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(580);
|
|
48114
|
-
/* harmony import */ var
|
|
48115
|
-
/* harmony import */ var
|
|
48116
|
-
/* harmony import */ var
|
|
48647
|
+
/* harmony import */ var _core_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(76241);
|
|
48648
|
+
/* harmony import */ var _core_helpers_utils_index_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(43555);
|
|
48649
|
+
/* harmony import */ var _core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(41180);
|
|
48650
|
+
/* harmony import */ var _config_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(757);
|
|
48117
48651
|
/*!
|
|
48118
48652
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
48119
48653
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -48124,6 +48658,7 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.mediaWrappers = {};
|
|
|
48124
48658
|
|
|
48125
48659
|
|
|
48126
48660
|
|
|
48661
|
+
|
|
48127
48662
|
/**
|
|
48128
48663
|
* Process `video` and `audio`
|
|
48129
48664
|
*/ function media(editor) {
|
|
@@ -48131,10 +48666,10 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.mediaWrappers = {};
|
|
|
48131
48666
|
const { mediaFakeTag, mediaBlocks, mediaInFakeBlock, mediaWrappers } = editor.options;
|
|
48132
48667
|
const wrap = (element)=>{
|
|
48133
48668
|
var _a;
|
|
48134
|
-
if (element.parentNode && (0,
|
|
48669
|
+
if (element.parentNode && (0,_core_helpers_utils_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(element.parentNode, 'data-jodit_iframe_wrapper')) {
|
|
48135
48670
|
element = element.parentNode;
|
|
48136
48671
|
} else if (mediaWrappers[element.nodeName.toLowerCase()]) {
|
|
48137
|
-
element = (_a = (0,
|
|
48672
|
+
element = (_a = (0,_core_helpers_utils_index_js__WEBPACK_IMPORTED_MODULE_4__.getMediaWrapper)(editor, element)) !== null && _a !== void 0 ? _a : (0,_core_helpers_utils_index_js__WEBPACK_IMPORTED_MODULE_4__.wrapMedia)(editor, element);
|
|
48138
48673
|
} else if (mediaInFakeBlock) {
|
|
48139
48674
|
const media = element;
|
|
48140
48675
|
const wrapper = editor.createInside.element(mediaFakeTag, {
|
|
@@ -48143,13 +48678,13 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.mediaWrappers = {};
|
|
|
48143
48678
|
draggable: true,
|
|
48144
48679
|
[`data-${keyFake}`]: 1
|
|
48145
48680
|
});
|
|
48146
|
-
(0,
|
|
48681
|
+
(0,_core_helpers_utils_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(wrapper, 'style', (0,_core_helpers_utils_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(element, 'style'));
|
|
48147
48682
|
// The wrapper fits the media, whose size changes as its metadata loads
|
|
48148
48683
|
// and as it's resized. A percentage width is of the line, so it takes that
|
|
48149
48684
|
const fit = ()=>{
|
|
48150
|
-
(0,
|
|
48151
|
-
display: (0,
|
|
48152
|
-
width: (0,
|
|
48685
|
+
(0,_core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_5__.css)(wrapper, {
|
|
48686
|
+
display: (0,_core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_5__.cssInline)(media, 'display') === 'inline-block' ? 'inline-block' : 'block',
|
|
48687
|
+
width: (0,_core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_5__.cssInline)(media, 'width').endsWith('%') ? '' : 'fit-content',
|
|
48153
48688
|
height: ''
|
|
48154
48689
|
});
|
|
48155
48690
|
};
|
|
@@ -48186,15 +48721,12 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.mediaWrappers = {};
|
|
|
48186
48721
|
}
|
|
48187
48722
|
if (mediaInFakeBlock || Object.keys(mediaWrappers).length) {
|
|
48188
48723
|
editor.e.on('afterGetValueFromEditor', (data)=>{
|
|
48189
|
-
|
|
48190
|
-
if (rxp.test(data.value)) {
|
|
48191
|
-
data.value = data.value.replace(rxp, '$1');
|
|
48192
|
-
}
|
|
48724
|
+
data.value = (0,_core_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_3__.unwrapMarkedTags)(data.value, mediaFakeTag, `data-${keyFake}`);
|
|
48193
48725
|
}).on('change afterInit afterSetMode changePlace', editor.async.debounce(()=>{
|
|
48194
48726
|
if (!editor.isDestructed && editor.getMode() !== _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.MODE_SOURCE) {
|
|
48195
|
-
(0,
|
|
48196
|
-
if (!(0,
|
|
48197
|
-
(0,
|
|
48727
|
+
(0,_core_helpers_utils_index_js__WEBPACK_IMPORTED_MODULE_4__.$$)(mediaBlocks.join(','), editor.editor).forEach((elm)=>{
|
|
48728
|
+
if (!(0,_core_helpers_utils_index_js__WEBPACK_IMPORTED_MODULE_4__.dataBind)(elm, keyFake)) {
|
|
48729
|
+
(0,_core_helpers_utils_index_js__WEBPACK_IMPORTED_MODULE_4__.dataBind)(elm, keyFake, true);
|
|
48198
48730
|
wrap(elm);
|
|
48199
48731
|
}
|
|
48200
48732
|
});
|
|
@@ -49176,7 +49708,8 @@ _config_js__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.controls.paste = {
|
|
|
49176
49708
|
/* harmony import */ var _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2748);
|
|
49177
49709
|
/* harmony import */ var _core_helpers_array_to_array_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4510);
|
|
49178
49710
|
/* harmony import */ var _core_helpers_checker_index_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(27613);
|
|
49179
|
-
/* harmony import */ var
|
|
49711
|
+
/* harmony import */ var _core_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(76241);
|
|
49712
|
+
/* harmony import */ var _core_ui_button_button_button_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(10830);
|
|
49180
49713
|
/*!
|
|
49181
49714
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
49182
49715
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -49186,11 +49719,14 @@ _config_js__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.controls.paste = {
|
|
|
49186
49719
|
|
|
49187
49720
|
|
|
49188
49721
|
|
|
49722
|
+
|
|
49189
49723
|
/**
|
|
49190
49724
|
* Remove special HTML comments
|
|
49191
49725
|
* @private
|
|
49192
49726
|
*/ function removeExtraFragments(html) {
|
|
49193
|
-
html =
|
|
49727
|
+
html = (0,_core_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_4__.removeTagsByPrefix)(html, [
|
|
49728
|
+
'<meta'
|
|
49729
|
+
]);
|
|
49194
49730
|
const start = html.search(/<!--StartFragment-->/i);
|
|
49195
49731
|
if (start !== -1) {
|
|
49196
49732
|
html = html.substring(start + 20);
|
|
@@ -49208,7 +49744,8 @@ _config_js__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.controls.paste = {
|
|
|
49208
49744
|
* paste bold
|
|
49209
49745
|
* @private
|
|
49210
49746
|
*/ function removeGoogleDocsWrapper(html) {
|
|
49211
|
-
|
|
49747
|
+
// A plain search: the wrapper check is left to the parsed document below
|
|
49748
|
+
if (!/docs-internal-guid-/i.test(html)) {
|
|
49212
49749
|
return html;
|
|
49213
49750
|
}
|
|
49214
49751
|
// An inert document: images don't load and handlers don't run
|
|
@@ -49263,7 +49800,7 @@ _config_js__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.controls.paste = {
|
|
|
49263
49800
|
return;
|
|
49264
49801
|
}
|
|
49265
49802
|
const dialog = jodit.confirm(`<div style="word-break: normal; white-space: normal">${jodit.i18n(msg)}</div>`, jodit.i18n(title));
|
|
49266
|
-
const buttons = buttonList.map(({ text, value })=>(0,
|
|
49803
|
+
const buttons = buttonList.map(({ text, value })=>(0,_core_ui_button_button_button_js__WEBPACK_IMPORTED_MODULE_5__.Button)(jodit, {
|
|
49267
49804
|
text,
|
|
49268
49805
|
name: text.toLowerCase(),
|
|
49269
49806
|
tabIndex: 0
|
|
@@ -49279,7 +49816,7 @@ _config_js__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.controls.paste = {
|
|
|
49279
49816
|
}
|
|
49280
49817
|
jodit.e.fire('afterClosePasteDialog', dialog);
|
|
49281
49818
|
});
|
|
49282
|
-
const cancel = (0,
|
|
49819
|
+
const cancel = (0,_core_ui_button_button_button_js__WEBPACK_IMPORTED_MODULE_5__.Button)(jodit, {
|
|
49283
49820
|
text: 'Cancel',
|
|
49284
49821
|
tabIndex: 0
|
|
49285
49822
|
}).onAction(()=>{
|
|
@@ -50795,12 +51332,13 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.resizer = {
|
|
|
50795
51332
|
/* harmony import */ var _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2748);
|
|
50796
51333
|
/* harmony import */ var _core_global_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(580);
|
|
50797
51334
|
/* harmony import */ var _core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(21537);
|
|
50798
|
-
/* harmony import */ var
|
|
50799
|
-
/* harmony import */ var
|
|
50800
|
-
/* harmony import */ var
|
|
50801
|
-
/* harmony import */ var
|
|
50802
|
-
/* harmony import */ var
|
|
50803
|
-
/* harmony import */ var
|
|
51335
|
+
/* harmony import */ var _core_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(76241);
|
|
51336
|
+
/* harmony import */ var _core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(41180);
|
|
51337
|
+
/* harmony import */ var _core_plugin_plugin_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(20356);
|
|
51338
|
+
/* harmony import */ var _core_selection_helpers_index_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(45124);
|
|
51339
|
+
/* harmony import */ var _core_ui_index_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(67510);
|
|
51340
|
+
/* harmony import */ var _core_ui_popup_index_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(61259);
|
|
51341
|
+
/* harmony import */ var _config_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(71675);
|
|
50804
51342
|
/*!
|
|
50805
51343
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
50806
51344
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -50823,6 +51361,7 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.resizer = {
|
|
|
50823
51361
|
|
|
50824
51362
|
|
|
50825
51363
|
|
|
51364
|
+
|
|
50826
51365
|
const keyBInd = '__jodit-resizer_binded';
|
|
50827
51366
|
/**
|
|
50828
51367
|
* Reads a plain pixel value out of a `width`/`height` attribute.
|
|
@@ -50840,7 +51379,7 @@ const keyBInd = '__jodit-resizer_binded';
|
|
|
50840
51379
|
* A video with no height of its own takes it from its width and its ratio,
|
|
50841
51380
|
* so resizing it keeps the ratio without setting a height.
|
|
50842
51381
|
*/ function heightFollowsWidth(element) {
|
|
50843
|
-
return _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_2__.Dom.isTag(element, 'video') && !(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(element, 'height') && !(0,
|
|
51382
|
+
return _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_2__.Dom.isTag(element, 'video') && !(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(element, 'height') && !(0,_core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_6__.cssInline)(element, 'height');
|
|
50844
51383
|
}
|
|
50845
51384
|
const IFRAME_WRAPPER = '[data-jodit_iframe_wrapper]';
|
|
50846
51385
|
/**
|
|
@@ -50850,7 +51389,7 @@ const IFRAME_WRAPPER = '[data-jodit_iframe_wrapper]';
|
|
|
50850
51389
|
*/ const EMBED_WRAPPER_STYLE = `${IFRAME_WRAPPER}{position:relative;display:block;user-select:none}` + `${IFRAME_WRAPPER} iframe{position:relative}` + `${IFRAME_WRAPPER}::after{position:absolute;z-index:1;display:block;background:transparent;content:'';cursor:pointer;inset:0}` + `${IFRAME_WRAPPER}[data-jodit-wrapper_active=true] iframe{z-index:2}` + `.jodit_lock ${IFRAME_WRAPPER}[data-jodit-wrapper_active=true] iframe{z-index:1}`;
|
|
50851
51390
|
/**
|
|
50852
51391
|
* The module creates a supporting frame for resizing of the elements img and table
|
|
50853
|
-
*/ class resizer extends
|
|
51392
|
+
*/ class resizer extends _core_plugin_plugin_js__WEBPACK_IMPORTED_MODULE_7__.Plugin {
|
|
50854
51393
|
/** @override */ afterInit(editor) {
|
|
50855
51394
|
// It goes in the editing document, so iframe mode has it whatever `iframeStyle` holds
|
|
50856
51395
|
(0,_core_global_js__WEBPACK_IMPORTED_MODULE_3__.getContainer)(editor, 'resizer', 'style', true).textContent = EMBED_WRAPPER_STYLE;
|
|
@@ -50867,10 +51406,7 @@ const IFRAME_WRAPPER = '[data-jodit_iframe_wrapper]';
|
|
|
50867
51406
|
.on('keydown', this.onEditorKeyDown, {
|
|
50868
51407
|
top: true
|
|
50869
51408
|
}).on('afterGetValueFromEditor.resizer', (data)=>{
|
|
50870
|
-
|
|
50871
|
-
if (rgx.test(data.value)) {
|
|
50872
|
-
data.value = data.value.replace(rgx, '$1');
|
|
50873
|
-
}
|
|
51409
|
+
data.value = (0,_core_helpers_html_tag_scan_js__WEBPACK_IMPORTED_MODULE_5__.unwrapMarkedTags)(data.value, 'jodit', 'data-jodit_iframe_wrapper', (inner)=>/<iframe/i.test(inner));
|
|
50874
51410
|
});
|
|
50875
51411
|
this.addEventListeners();
|
|
50876
51412
|
this.__onChangeEditor();
|
|
@@ -50907,7 +51443,7 @@ const IFRAME_WRAPPER = '[data-jodit_iframe_wrapper]';
|
|
|
50907
51443
|
return;
|
|
50908
51444
|
}
|
|
50909
51445
|
const width = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(image, 'width');
|
|
50910
|
-
if (width && !(0,
|
|
51446
|
+
if (width && !(0,_core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_6__.cssInline)(image, 'width')) {
|
|
50911
51447
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.css)(image, 'width', width);
|
|
50912
51448
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(image, 'width', null);
|
|
50913
51449
|
}
|
|
@@ -51031,7 +51567,7 @@ const IFRAME_WRAPPER = '[data-jodit_iframe_wrapper]';
|
|
|
51031
51567
|
__followCaret() {
|
|
51032
51568
|
const before = this.__keyDownRange;
|
|
51033
51569
|
this.__keyDownRange = null;
|
|
51034
|
-
if (!(0,
|
|
51570
|
+
if (!(0,_core_selection_helpers_index_js__WEBPACK_IMPORTED_MODULE_8__.isMoved)(this.j, before)) {
|
|
51035
51571
|
return;
|
|
51036
51572
|
}
|
|
51037
51573
|
if (this.isShown && this.element && !this.j.s.range.intersectsNode(this.element)) {
|
|
@@ -51066,7 +51602,7 @@ const IFRAME_WRAPPER = '[data-jodit_iframe_wrapper]';
|
|
|
51066
51602
|
if (!this.isResizeMode) {
|
|
51067
51603
|
// A click in the element's popup, or in a list it opens, works on
|
|
51068
51604
|
// the element, so it keeps its frame
|
|
51069
|
-
if ((e === null || e === void 0 ? void 0 : e.target) &&
|
|
51605
|
+
if ((e === null || e === void 0 ? void 0 : e.target) && _core_ui_index_js__WEBPACK_IMPORTED_MODULE_9__.UIElement.closestElement(e.target, _core_ui_popup_index_js__WEBPACK_IMPORTED_MODULE_10__.Popup)) {
|
|
51070
51606
|
return;
|
|
51071
51607
|
}
|
|
51072
51608
|
return this.hide();
|
|
@@ -51090,7 +51626,7 @@ const IFRAME_WRAPPER = '[data-jodit_iframe_wrapper]';
|
|
|
51090
51626
|
if (changeAttrs) {
|
|
51091
51627
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(element, key, value);
|
|
51092
51628
|
}
|
|
51093
|
-
if (!changeAttrs || (0,
|
|
51629
|
+
if (!changeAttrs || (0,_core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_6__.cssInline)(element, key)) {
|
|
51094
51630
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.css)(element, key, value);
|
|
51095
51631
|
}
|
|
51096
51632
|
}
|
|
@@ -51156,7 +51692,7 @@ const IFRAME_WRAPPER = '[data-jodit_iframe_wrapper]';
|
|
|
51156
51692
|
const width = element.offsetWidth || attrPixelSize(element, 'width');
|
|
51157
51693
|
const height = element.offsetHeight || attrPixelSize(element, 'height');
|
|
51158
51694
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.css)(wrapper, {
|
|
51159
|
-
display: (0,
|
|
51695
|
+
display: (0,_core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_6__.cssInline)(element, 'display') === 'inline-block' ? 'inline-block' : 'block'
|
|
51160
51696
|
});
|
|
51161
51697
|
if (width) {
|
|
51162
51698
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.css)(wrapper, 'width', width);
|
|
@@ -51293,7 +51829,7 @@ const IFRAME_WRAPPER = '[data-jodit_iframe_wrapper]';
|
|
|
51293
51829
|
}
|
|
51294
51830
|
if (this.element && this.rect) {
|
|
51295
51831
|
const workplacePosition = this.getWorkplacePosition();
|
|
51296
|
-
const pos = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.offset)(this.element, this.j, this.j.ed), left = parseInt((0,
|
|
51832
|
+
const pos = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.offset)(this.element, this.j, this.j.ed), left = parseInt((0,_core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_6__.cssInline)(this.rect, 'left') || '0', 10), top = parseInt((0,_core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_6__.cssInline)(this.rect, 'top') || '0', 10), w = this.rect.offsetWidth, h = this.rect.offsetHeight;
|
|
51297
51833
|
const newTop = pos.top - workplacePosition.top, newLeft = pos.left - workplacePosition.left;
|
|
51298
51834
|
if (top !== newTop || left !== newLeft || w !== this.element.offsetWidth || h !== this.element.offsetHeight) {
|
|
51299
51835
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.css)(this.rect, {
|