jodit-pro 4.18.8 → 4.18.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 +2 -2
- package/es2015/jodit.fat.min.css +1 -1
- package/es2015/jodit.fat.min.js +30 -30
- package/es2015/jodit.js +1242 -229
- package/es2015/jodit.min.css +1 -1
- package/es2015/jodit.min.js +13 -13
- package/es2015/plugins/ai-assistant-pro/ai-assistant-pro.css +1 -1
- package/es2015/plugins/ai-assistant-pro/ai-assistant-pro.js +19 -1
- package/es2015/plugins/ai-assistant-pro/ai-assistant-pro.min.js +3 -3
- 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 +14 -7
- package/es2015/plugins/backup/backup.min.js +2 -2
- package/es2015/plugins/button-generator/button-generator.css +1 -1
- package/es2015/plugins/button-generator/button-generator.js +26 -19
- package/es2015/plugins/button-generator/button-generator.min.js +3 -3
- 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.css +1 -1
- package/es2018/jodit.fat.min.js +19 -19
- package/es2018/jodit.min.css +1 -1
- package/es2018/jodit.min.js +21 -21
- package/es2018/plugins/ai-assistant-pro/ai-assistant-pro.min.js +3 -3
- package/es2018/plugins/autocomplete/autocomplete.min.js +1 -1
- package/es2018/plugins/backup/backup.min.js +2 -2
- package/es2018/plugins/button-generator/button-generator.min.js +3 -3
- 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 +2 -2
- package/es2021/jodit.fat.min.css +1 -1
- package/es2021/jodit.fat.min.js +24 -24
- package/es2021/jodit.js +1217 -229
- package/es2021/jodit.min.css +1 -1
- package/es2021/jodit.min.js +16 -16
- package/es2021/plugins/ai-assistant-pro/ai-assistant-pro.css +1 -1
- package/es2021/plugins/ai-assistant-pro/ai-assistant-pro.js +19 -1
- package/es2021/plugins/ai-assistant-pro/ai-assistant-pro.min.js +3 -3
- 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 +14 -7
- package/es2021/plugins/backup/backup.min.js +2 -2
- package/es2021/plugins/button-generator/button-generator.css +1 -1
- package/es2021/plugins/button-generator/button-generator.js +26 -19
- package/es2021/plugins/button-generator/button-generator.min.js +3 -3
- 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 +2 -2
- package/es2021.en/jodit.fat.min.css +1 -1
- package/es2021.en/jodit.fat.min.js +24 -24
- package/es2021.en/jodit.js +1217 -229
- package/es2021.en/jodit.min.css +1 -1
- package/es2021.en/jodit.min.js +30 -30
- package/es2021.en/plugins/ai-assistant-pro/ai-assistant-pro.css +1 -1
- package/es2021.en/plugins/ai-assistant-pro/ai-assistant-pro.js +19 -1
- package/es2021.en/plugins/ai-assistant-pro/ai-assistant-pro.min.js +26 -26
- 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 +14 -7
- package/es2021.en/plugins/backup/backup.min.js +2 -2
- package/es2021.en/plugins/button-generator/button-generator.css +1 -1
- package/es2021.en/plugins/button-generator/button-generator.js +26 -19
- package/es2021.en/plugins/button-generator/button-generator.min.js +3 -3
- 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 +3 -3
- package/es5/jodit.fat.min.css +1 -1
- package/es5/jodit.fat.min.js +2 -2
- package/es5/jodit.js +1383 -235
- package/es5/jodit.min.css +3 -3
- 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 +19 -1
- package/es5/plugins/ai-assistant-pro/ai-assistant-pro.min.js +2 -2
- 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 +14 -7
- package/es5/plugins/backup/backup.min.js +2 -2
- package/es5/plugins/button-generator/button-generator.css +1 -1
- package/es5/plugins/button-generator/button-generator.js +26 -19
- package/es5/plugins/button-generator/button-generator.min.js +2 -2
- 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/esm/plugins/ai-assistant-pro/ai-assistant-pro.js +2 -2
- package/esm/plugins/ai-assistant-pro/core/panel-resize.d.ts +4 -0
- package/esm/plugins/ai-assistant-pro/core/panel-resize.js +1 -1
- package/esm/plugins/backup/ui/item.js +1 -1
- package/esm/plugins/button-generator/ui/form/form.js +2 -2
- package/package.json +1 -1
- package/types/plugins/ai-assistant-pro/core/panel-resize.d.ts +4 -0
package/es2021.en/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.18.
|
|
4
|
+
* Version: v4.18.11
|
|
5
5
|
* Url: https://xdsoft.net/jodit/pro/
|
|
6
6
|
* License(s): SEE LICENSE IN LICENSE.md
|
|
7
7
|
*/
|
|
@@ -1766,7 +1766,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
1766
1766
|
* ```
|
|
1767
1767
|
* @packageDocumentation
|
|
1768
1768
|
* @module constants
|
|
1769
|
-
*/ const APP_VERSION = "4.18.
|
|
1769
|
+
*/ const APP_VERSION = "4.18.11";
|
|
1770
1770
|
// prettier-ignore
|
|
1771
1771
|
const ES = "es2021";
|
|
1772
1772
|
const IS_ES_MODERN = true;
|
|
@@ -2484,6 +2484,8 @@ function cacheHTML(target, _, descriptor) {
|
|
|
2484
2484
|
*/
|
|
2485
2485
|
|
|
2486
2486
|
const componentRegistry = new Map();
|
|
2487
|
+
const decoratedClasses = new WeakSet();
|
|
2488
|
+
const warnedClasses = new WeakSet();
|
|
2487
2489
|
/**
|
|
2488
2490
|
* Decorate components and set status isReady after constructor
|
|
2489
2491
|
* @param constructorFunction - Component constructor class
|
|
@@ -2500,9 +2502,16 @@ const componentRegistry = new Map();
|
|
|
2500
2502
|
Object.setPrototypeOf(this, newConstructorFunction.prototype);
|
|
2501
2503
|
}
|
|
2502
2504
|
this.setStatus('ready');
|
|
2505
|
+
} else if (!_constants_js__WEBPACK_IMPORTED_MODULE_0__.IS_PROD && !decoratedClasses.has(this.constructor) && !warnedClasses.has(this.constructor)) {
|
|
2506
|
+
// Only the outermost class's decorator sets `ready`, so a subclass
|
|
2507
|
+
// without its own decorator stays in `beforeInit`. See #1685
|
|
2508
|
+
warnedClasses.add(this.constructor);
|
|
2509
|
+
console.warn(`Component "${this.constructor.name || (0,_helpers_utils_get_class_name_js__WEBPACK_IMPORTED_MODULE_1__.getClassName)(this)}" extends a @component class without being decorated itself, so it never becomes ready and its @watch, @debounce, @throttle and @hook handlers never run`);
|
|
2503
2510
|
}
|
|
2504
2511
|
}
|
|
2505
2512
|
}
|
|
2513
|
+
decoratedClasses.add(constructorFunction);
|
|
2514
|
+
decoratedClasses.add(newConstructorFunction);
|
|
2506
2515
|
const name = (0,_helpers_utils_get_class_name_js__WEBPACK_IMPORTED_MODULE_1__.getClassName)(constructorFunction.prototype);
|
|
2507
2516
|
if (componentRegistry.has(name) && !_constants_js__WEBPACK_IMPORTED_MODULE_0__.IS_PROD) {
|
|
2508
2517
|
throw new Error(`Component with name "${name}" is already registered`);
|
|
@@ -5686,10 +5695,11 @@ const isLicense = (license)=>(0,_is_string_js__WEBPACK_IMPORTED_MODULE_0__.isStr
|
|
|
5686
5695
|
/* harmony export */ });
|
|
5687
5696
|
/* harmony import */ var _constants_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(82758);
|
|
5688
5697
|
/* harmony import */ var _dom_dom_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2748);
|
|
5689
|
-
/* harmony import */ var
|
|
5690
|
-
/* harmony import */ var
|
|
5691
|
-
/* harmony import */ var
|
|
5692
|
-
/* harmony import */ var
|
|
5698
|
+
/* harmony import */ var _word_lists_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(90723);
|
|
5699
|
+
/* harmony import */ var _string_trim_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(49055);
|
|
5700
|
+
/* harmony import */ var _utils_attr_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(29960);
|
|
5701
|
+
/* harmony import */ var _utils_css_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(41180);
|
|
5702
|
+
/* harmony import */ var _utils_selector_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(76078);
|
|
5693
5703
|
/*!
|
|
5694
5704
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
5695
5705
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -5702,6 +5712,7 @@ const isLicense = (license)=>(0,_is_string_js__WEBPACK_IMPORTED_MODULE_0__.isStr
|
|
|
5702
5712
|
|
|
5703
5713
|
|
|
5704
5714
|
|
|
5715
|
+
|
|
5705
5716
|
function normalizeCSS(s) {
|
|
5706
5717
|
return s.replace(/mso-[a-z-]+:[\s]*[^;]+;/gi, '').replace(/mso-[a-z-]+:[\s]*[^";']+$/gi, '').replace(/border[a-z-]*:[\s]*[^;]+;/gi, '').replace(/([0-9.]+)(pt|cm)/gi, (match, units, metrics)=>{
|
|
5707
5718
|
switch(metrics.toLowerCase()){
|
|
@@ -5735,7 +5746,7 @@ function normalizeCSS(s) {
|
|
|
5735
5746
|
html = html.substring(0, closeIndex + '</html>'.length);
|
|
5736
5747
|
}
|
|
5737
5748
|
const iframe = _constants_js__WEBPACK_IMPORTED_MODULE_0__.globalDocument.createElement('iframe');
|
|
5738
|
-
(0,
|
|
5749
|
+
(0,_utils_css_js__WEBPACK_IMPORTED_MODULE_5__.css)(iframe, 'display', 'none');
|
|
5739
5750
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.append(_constants_js__WEBPACK_IMPORTED_MODULE_0__.globalDocument.body, iframe);
|
|
5740
5751
|
let convertedString = '', collection;
|
|
5741
5752
|
try {
|
|
@@ -5744,13 +5755,14 @@ function normalizeCSS(s) {
|
|
|
5744
5755
|
iframeDoc.open();
|
|
5745
5756
|
iframeDoc.write(html);
|
|
5746
5757
|
iframeDoc.close();
|
|
5758
|
+
const listItems = (0,_word_lists_js__WEBPACK_IMPORTED_MODULE_2__.readWordListItems)(iframeDoc.body);
|
|
5747
5759
|
// Word marks its auto-generated list markers (the literal
|
|
5748
5760
|
// bullet/number, e.g. `1.` or `·`) with `mso-list:Ignore`.
|
|
5749
5761
|
// They are display-only and must not be imported, otherwise
|
|
5750
5762
|
// the marker text leaks into the content. Drop them before any
|
|
5751
5763
|
// style normalization strips the `mso-list` hint. See #948
|
|
5752
5764
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.each(iframeDoc.body, (node)=>{
|
|
5753
|
-
if (_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(node) && /mso-list:\s*ignore/i.test((0,
|
|
5765
|
+
if (_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(node) && /mso-list:\s*ignore/i.test((0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_4__.attr)(node, 'style') || '')) {
|
|
5754
5766
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(node);
|
|
5755
5767
|
}
|
|
5756
5768
|
});
|
|
@@ -5761,7 +5773,7 @@ function normalizeCSS(s) {
|
|
|
5761
5773
|
if (rules[idx].selectorText === '') {
|
|
5762
5774
|
continue;
|
|
5763
5775
|
}
|
|
5764
|
-
collection = (0,
|
|
5776
|
+
collection = (0,_utils_selector_js__WEBPACK_IMPORTED_MODULE_6__.$$)(rules[idx].selectorText, iframeDoc.body);
|
|
5765
5777
|
// `style.cssText` on purpose: the CSSOM parses the text,
|
|
5766
5778
|
// drops invalid declarations and re-serializes it. The raw
|
|
5767
5779
|
// `style` attribute would keep Word-only junk verbatim
|
|
@@ -5775,18 +5787,19 @@ function normalizeCSS(s) {
|
|
|
5775
5787
|
throw e;
|
|
5776
5788
|
}
|
|
5777
5789
|
}
|
|
5790
|
+
;(0,_word_lists_js__WEBPACK_IMPORTED_MODULE_2__.wrapWordListItems)(listItems);
|
|
5778
5791
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.each(iframeDoc.body, (node)=>{
|
|
5779
5792
|
if (_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(node)) {
|
|
5780
|
-
const cssText = (0,
|
|
5793
|
+
const cssText = (0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_4__.attr)(node, 'style');
|
|
5781
5794
|
if (cssText) {
|
|
5782
5795
|
node.style.cssText = normalizeCSS(cssText);
|
|
5783
5796
|
}
|
|
5784
|
-
if (!(0,
|
|
5785
|
-
(0,
|
|
5797
|
+
if (!(0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_4__.attr)(node, 'style')) {
|
|
5798
|
+
(0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_4__.attr)(node, 'style', null);
|
|
5786
5799
|
}
|
|
5787
5800
|
}
|
|
5788
5801
|
});
|
|
5789
|
-
convertedString = iframeDoc.firstChild ? (0,
|
|
5802
|
+
convertedString = iframeDoc.firstChild ? (0,_string_trim_js__WEBPACK_IMPORTED_MODULE_3__.trim)(iframeDoc.body.innerHTML) : '';
|
|
5790
5803
|
}
|
|
5791
5804
|
} catch (_a) {} finally{
|
|
5792
5805
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(iframe);
|
|
@@ -5794,7 +5807,7 @@ function normalizeCSS(s) {
|
|
|
5794
5807
|
if (convertedString) {
|
|
5795
5808
|
html = convertedString;
|
|
5796
5809
|
}
|
|
5797
|
-
return (0,
|
|
5810
|
+
return (0,_string_trim_js__WEBPACK_IMPORTED_MODULE_3__.trim)(html.replace(/<(\/)?(html|colgroup|col|o:p)[^>]*>/g, '').replace(/<!--[^>]*>/g, ''));
|
|
5798
5811
|
}
|
|
5799
5812
|
|
|
5800
5813
|
|
|
@@ -5809,8 +5822,9 @@ function normalizeCSS(s) {
|
|
|
5809
5822
|
/* harmony import */ var _constants_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(82758);
|
|
5810
5823
|
/* harmony import */ var _dom_dom_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2748);
|
|
5811
5824
|
/* harmony import */ var _array_to_array_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4510);
|
|
5812
|
-
/* harmony import */ var
|
|
5813
|
-
/* harmony import */ var
|
|
5825
|
+
/* harmony import */ var _word_lists_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(90723);
|
|
5826
|
+
/* harmony import */ var _string_trim_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(49055);
|
|
5827
|
+
/* harmony import */ var _utils_attr_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(29960);
|
|
5814
5828
|
/*!
|
|
5815
5829
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
5816
5830
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -5822,6 +5836,7 @@ function normalizeCSS(s) {
|
|
|
5822
5836
|
|
|
5823
5837
|
|
|
5824
5838
|
|
|
5839
|
+
|
|
5825
5840
|
/**
|
|
5826
5841
|
* The method automatically cleans up content from Microsoft Word and other HTML sources to ensure clean, compliant
|
|
5827
5842
|
* content that matches the look and feel of the site.
|
|
@@ -5835,6 +5850,7 @@ function normalizeCSS(s) {
|
|
|
5835
5850
|
const div = _constants_js__WEBPACK_IMPORTED_MODULE_0__.globalDocument.createElement('div');
|
|
5836
5851
|
div.innerHTML = html;
|
|
5837
5852
|
const marks = [];
|
|
5853
|
+
const listItems = (0,_word_lists_js__WEBPACK_IMPORTED_MODULE_3__.readWordListItems)(div);
|
|
5838
5854
|
if (div.firstChild) {
|
|
5839
5855
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.each(div, (node)=>{
|
|
5840
5856
|
if (!node) {
|
|
@@ -5859,7 +5875,7 @@ function normalizeCSS(s) {
|
|
|
5859
5875
|
// with `mso-list:Ignore`. They are display-only
|
|
5860
5876
|
// and must not be imported, otherwise the marker
|
|
5861
5877
|
// text leaks into the content. See #948
|
|
5862
|
-
if (/mso-list:\s*ignore/i.test((0,
|
|
5878
|
+
if (/mso-list:\s*ignore/i.test((0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_5__.attr)(node, 'style') || '')) {
|
|
5863
5879
|
marks.push(node);
|
|
5864
5880
|
break;
|
|
5865
5881
|
}
|
|
@@ -5873,7 +5889,7 @@ function normalizeCSS(s) {
|
|
|
5873
5889
|
// `attrRaw`: SVG keeps camelCase names
|
|
5874
5890
|
// (`viewBox`), `attr()` would kebab-case
|
|
5875
5891
|
// them and silently skip the removal
|
|
5876
|
-
(0,
|
|
5892
|
+
(0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_5__.attrRaw)(node, attribute.name, null);
|
|
5877
5893
|
}
|
|
5878
5894
|
});
|
|
5879
5895
|
}
|
|
@@ -5886,12 +5902,13 @@ function normalizeCSS(s) {
|
|
|
5886
5902
|
});
|
|
5887
5903
|
}
|
|
5888
5904
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove.apply(null, marks);
|
|
5905
|
+
(0,_word_lists_js__WEBPACK_IMPORTED_MODULE_3__.wrapWordListItems)(listItems);
|
|
5889
5906
|
convertedString = div.innerHTML;
|
|
5890
5907
|
} catch (e) {}
|
|
5891
5908
|
if (convertedString) {
|
|
5892
5909
|
html = convertedString;
|
|
5893
5910
|
}
|
|
5894
|
-
html = html.split(/(\n)/).filter(
|
|
5911
|
+
html = html.split(/(\n)/).filter(_string_trim_js__WEBPACK_IMPORTED_MODULE_4__.trim).join('\n');
|
|
5895
5912
|
return html.replace(/<(\/)?(html|colgroup|col|o:p)[^>]*>/g, '').replace(/<!--[^>]*>/g, '');
|
|
5896
5913
|
}
|
|
5897
5914
|
|
|
@@ -6226,7 +6243,14 @@ const NEW_LINE_TAGS = new Set([
|
|
|
6226
6243
|
'h4',
|
|
6227
6244
|
'h5',
|
|
6228
6245
|
'h6',
|
|
6229
|
-
'hr'
|
|
6246
|
+
'hr',
|
|
6247
|
+
'ul',
|
|
6248
|
+
'ol',
|
|
6249
|
+
'li'
|
|
6250
|
+
]);
|
|
6251
|
+
const LIST_TAGS = new Set([
|
|
6252
|
+
'ul',
|
|
6253
|
+
'ol'
|
|
6230
6254
|
]);
|
|
6231
6255
|
const INVISIBLE_TAGS = new Set([
|
|
6232
6256
|
'script',
|
|
@@ -6252,6 +6276,16 @@ const ALONE_TAGS = new Set([
|
|
|
6252
6276
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.each(tmp, (node)=>{
|
|
6253
6277
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(node) && all.push(node);
|
|
6254
6278
|
});
|
|
6279
|
+
// By default blocks are joined with a single space (single-line
|
|
6280
|
+
// plain text). When `blockBr` is set, separate them with a line
|
|
6281
|
+
// break instead, so paragraph structure survives — e.g. the
|
|
6282
|
+
// "Insert only Text" paste option. See #1232
|
|
6283
|
+
const separators = new Set();
|
|
6284
|
+
const separator = ()=>{
|
|
6285
|
+
const text = doc.createTextNode(blockBr ? '%%%jodit-single-br%%%' : ' ');
|
|
6286
|
+
separators.add(text);
|
|
6287
|
+
return text;
|
|
6288
|
+
};
|
|
6255
6289
|
all.forEach((p)=>{
|
|
6256
6290
|
const pr = p.parentNode;
|
|
6257
6291
|
if (!pr) {
|
|
@@ -6271,16 +6305,17 @@ const ALONE_TAGS = new Set([
|
|
|
6271
6305
|
if (!_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(p, NEW_LINE_TAGS)) {
|
|
6272
6306
|
return;
|
|
6273
6307
|
}
|
|
6308
|
+
const pv = p.previousSibling;
|
|
6309
|
+
// A nested list starts on a new line after its item's own text
|
|
6310
|
+
if (_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(p, LIST_TAGS) && pv && !separators.has(pv) && !(_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isText(pv) && /\s$/.test(pv.nodeValue || ''))) {
|
|
6311
|
+
_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.before(p, separator());
|
|
6312
|
+
}
|
|
6274
6313
|
const nx = p.nextSibling;
|
|
6275
6314
|
if (_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isText(nx) && /^\s/.test(nx.nodeValue || '')) {
|
|
6276
6315
|
return;
|
|
6277
6316
|
}
|
|
6278
6317
|
if (nx) {
|
|
6279
|
-
|
|
6280
|
-
// plain text). When `blockBr` is set, separate them with a line
|
|
6281
|
-
// break instead, so paragraph structure survives — e.g. the
|
|
6282
|
-
// "Insert only Text" paste option. See #1232
|
|
6283
|
-
_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.before(nx, doc.createTextNode(blockBr ? '%%%jodit-single-br%%%' : ' '));
|
|
6318
|
+
_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.before(nx, separator());
|
|
6284
6319
|
}
|
|
6285
6320
|
});
|
|
6286
6321
|
return restoreTags((0,_string_trim_js__WEBPACK_IMPORTED_MODULE_2__.trim)(tmp.innerText));
|
|
@@ -6290,6 +6325,180 @@ function restoreTags(content) {
|
|
|
6290
6325
|
}
|
|
6291
6326
|
|
|
6292
6327
|
|
|
6328
|
+
/***/ }),
|
|
6329
|
+
|
|
6330
|
+
/***/ 90723:
|
|
6331
|
+
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
6332
|
+
|
|
6333
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
6334
|
+
/* harmony export */ readWordListItems: function() { return /* binding */ readWordListItems; },
|
|
6335
|
+
/* harmony export */ wrapWordListItems: function() { return /* binding */ wrapWordListItems; }
|
|
6336
|
+
/* harmony export */ });
|
|
6337
|
+
/* harmony import */ var _dom_dom_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2748);
|
|
6338
|
+
/* harmony import */ var _array_to_array_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(4510);
|
|
6339
|
+
/* harmony import */ var _utils_attr_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(29960);
|
|
6340
|
+
/*!
|
|
6341
|
+
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
6342
|
+
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
6343
|
+
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net
|
|
6344
|
+
*/ /**
|
|
6345
|
+
* @module helpers/html
|
|
6346
|
+
*/
|
|
6347
|
+
|
|
6348
|
+
|
|
6349
|
+
const ROMAN = {
|
|
6350
|
+
i: 1,
|
|
6351
|
+
v: 5,
|
|
6352
|
+
x: 10,
|
|
6353
|
+
l: 50,
|
|
6354
|
+
c: 100,
|
|
6355
|
+
d: 500,
|
|
6356
|
+
m: 1000
|
|
6357
|
+
};
|
|
6358
|
+
function romanValue(roman) {
|
|
6359
|
+
let value = 0;
|
|
6360
|
+
for(let i = 0; i < roman.length; i += 1){
|
|
6361
|
+
const current = ROMAN[roman[i]], next = ROMAN[roman[i + 1]] || 0;
|
|
6362
|
+
value += current < next ? -current : current;
|
|
6363
|
+
}
|
|
6364
|
+
return value;
|
|
6365
|
+
}
|
|
6366
|
+
/**
|
|
6367
|
+
* Word's marker text (`1.`, `b)`, `iv.`, `·`, `o`, `§`) decides the list type
|
|
6368
|
+
*/ function parseMarker(marker) {
|
|
6369
|
+
const text = marker.replace(/\s+/g, '');
|
|
6370
|
+
const decimal = /^\(?(?:\d+\.)*(\d+)[.)]?$/.exec(text);
|
|
6371
|
+
if (decimal) {
|
|
6372
|
+
return {
|
|
6373
|
+
tag: 'ol',
|
|
6374
|
+
listStyleType: null,
|
|
6375
|
+
start: Number(decimal[1])
|
|
6376
|
+
};
|
|
6377
|
+
}
|
|
6378
|
+
const letters = /^\(?([a-z]+|[A-Z]+)[.)]$/.exec(text);
|
|
6379
|
+
if (letters) {
|
|
6380
|
+
const value = letters[1], lower = value.toLowerCase(), upper = value !== lower;
|
|
6381
|
+
if (/^[ivxlcdm]+$/.test(lower) && (lower.length > 1 || lower === 'i')) {
|
|
6382
|
+
return {
|
|
6383
|
+
tag: 'ol',
|
|
6384
|
+
listStyleType: upper ? 'upper-roman' : 'lower-roman',
|
|
6385
|
+
start: romanValue(lower)
|
|
6386
|
+
};
|
|
6387
|
+
}
|
|
6388
|
+
// Word continues a lettered list with aa, bb, ...
|
|
6389
|
+
if (/^([a-z])\1*$/.test(lower)) {
|
|
6390
|
+
return {
|
|
6391
|
+
tag: 'ol',
|
|
6392
|
+
listStyleType: upper ? 'upper-alpha' : 'lower-alpha',
|
|
6393
|
+
start: (lower.length - 1) * 26 + lower.charCodeAt(0) - 96
|
|
6394
|
+
};
|
|
6395
|
+
}
|
|
6396
|
+
}
|
|
6397
|
+
return {
|
|
6398
|
+
tag: 'ul',
|
|
6399
|
+
listStyleType: null,
|
|
6400
|
+
start: 1
|
|
6401
|
+
};
|
|
6402
|
+
}
|
|
6403
|
+
/**
|
|
6404
|
+
* Removes the marker and the wrappers it leaves empty
|
|
6405
|
+
*/ function removeMarker(marker, paragraph) {
|
|
6406
|
+
let parent = marker.parentNode;
|
|
6407
|
+
_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(marker);
|
|
6408
|
+
while(parent && parent !== paragraph && _dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isElement(parent) && _dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isEmpty(parent)){
|
|
6409
|
+
const next = parent.parentNode;
|
|
6410
|
+
_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(parent);
|
|
6411
|
+
parent = next;
|
|
6412
|
+
}
|
|
6413
|
+
}
|
|
6414
|
+
/**
|
|
6415
|
+
* Finds Word's list paragraphs (`<p style="mso-list:l0 level1 lfo1">`), reads
|
|
6416
|
+
* their list, level and type from the `mso-list:Ignore` marker, and removes the
|
|
6417
|
+
* marker. Call it before anything strips the `mso-list` styles, then pass the
|
|
6418
|
+
* result to {@link wrapWordListItems}
|
|
6419
|
+
*/ function readWordListItems(root) {
|
|
6420
|
+
const items = [];
|
|
6421
|
+
(0,_array_to_array_js__WEBPACK_IMPORTED_MODULE_1__.toArray)(root.querySelectorAll('p')).forEach((paragraph)=>{
|
|
6422
|
+
const match = /mso-list:\s*l(\d+)\s+level(\d+)(?:\s+lfo(\d+))?/i.exec((0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_2__.attr)(paragraph, 'style') || '');
|
|
6423
|
+
if (!match) {
|
|
6424
|
+
return;
|
|
6425
|
+
}
|
|
6426
|
+
const marker = (0,_array_to_array_js__WEBPACK_IMPORTED_MODULE_1__.toArray)(paragraph.querySelectorAll('[style]')).find((elm)=>/mso-list:\s*ignore/i.test((0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_2__.attr)(elm, 'style') || ''));
|
|
6427
|
+
items.push({
|
|
6428
|
+
paragraph,
|
|
6429
|
+
list: `${match[1]}:${match[3] || ''}`,
|
|
6430
|
+
level: Number(match[2]),
|
|
6431
|
+
...parseMarker((marker === null || marker === void 0 ? void 0 : marker.textContent) || '')
|
|
6432
|
+
});
|
|
6433
|
+
if (marker) {
|
|
6434
|
+
removeMarker(marker, paragraph);
|
|
6435
|
+
}
|
|
6436
|
+
});
|
|
6437
|
+
return items;
|
|
6438
|
+
}
|
|
6439
|
+
function isAdjacent(prev, item) {
|
|
6440
|
+
return _dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.findSibling(item.paragraph, true, (n)=>!_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isEmptyTextNode(n) && !_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isComment(n)) === prev.paragraph;
|
|
6441
|
+
}
|
|
6442
|
+
/**
|
|
6443
|
+
* Turns the paragraphs found by {@link readWordListItems} into `<ul>`/`<ol>`
|
|
6444
|
+
* lists, nesting them by level. Each paragraph becomes an `<li>` without Word's
|
|
6445
|
+
* hanging indent
|
|
6446
|
+
*/ function wrapWordListItems(items) {
|
|
6447
|
+
let stack = [];
|
|
6448
|
+
const continues = items.map((item, index)=>index > 0 && isAdjacent(items[index - 1], item));
|
|
6449
|
+
items.forEach((item, index)=>{
|
|
6450
|
+
const { paragraph } = item;
|
|
6451
|
+
if (!continues[index]) {
|
|
6452
|
+
stack = [];
|
|
6453
|
+
}
|
|
6454
|
+
while(stack.length && stack[stack.length - 1].level > item.level){
|
|
6455
|
+
stack.pop();
|
|
6456
|
+
}
|
|
6457
|
+
let top = stack[stack.length - 1];
|
|
6458
|
+
if (top && top.level === item.level && top.list !== item.list) {
|
|
6459
|
+
stack.pop();
|
|
6460
|
+
top = stack[stack.length - 1];
|
|
6461
|
+
}
|
|
6462
|
+
const doc = paragraph.ownerDocument;
|
|
6463
|
+
if (!top || top.level < item.level) {
|
|
6464
|
+
const element = doc.createElement(item.tag);
|
|
6465
|
+
if (item.listStyleType) {
|
|
6466
|
+
element.style.listStyleType = item.listStyleType;
|
|
6467
|
+
}
|
|
6468
|
+
if (item.tag === 'ol' && item.start !== 1) {
|
|
6469
|
+
(0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_2__.attr)(element, 'start', item.start);
|
|
6470
|
+
}
|
|
6471
|
+
if (top && top.li) {
|
|
6472
|
+
top.li.appendChild(element);
|
|
6473
|
+
} else {
|
|
6474
|
+
_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.before(paragraph, element);
|
|
6475
|
+
}
|
|
6476
|
+
top = {
|
|
6477
|
+
level: item.level,
|
|
6478
|
+
list: item.list,
|
|
6479
|
+
element
|
|
6480
|
+
};
|
|
6481
|
+
stack.push(top);
|
|
6482
|
+
}
|
|
6483
|
+
const li = doc.createElement('li');
|
|
6484
|
+
(0,_array_to_array_js__WEBPACK_IMPORTED_MODULE_1__.toArray)(paragraph.attributes).forEach((attribute)=>{
|
|
6485
|
+
if (attribute.name !== 'class') {
|
|
6486
|
+
li.setAttribute(attribute.name, attribute.value);
|
|
6487
|
+
}
|
|
6488
|
+
});
|
|
6489
|
+
li.style.removeProperty('margin-left');
|
|
6490
|
+
li.style.removeProperty('text-indent');
|
|
6491
|
+
if (!(0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_2__.attr)(li, 'style')) {
|
|
6492
|
+
(0,_utils_attr_js__WEBPACK_IMPORTED_MODULE_2__.attr)(li, 'style', null);
|
|
6493
|
+
}
|
|
6494
|
+
_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.moveContent(paragraph, li);
|
|
6495
|
+
_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(paragraph);
|
|
6496
|
+
top.element.appendChild(li);
|
|
6497
|
+
top.li = li;
|
|
6498
|
+
});
|
|
6499
|
+
}
|
|
6500
|
+
|
|
6501
|
+
|
|
6293
6502
|
/***/ }),
|
|
6294
6503
|
|
|
6295
6504
|
/***/ 21537:
|
|
@@ -10557,13 +10766,15 @@ function usable(ranges, shadowRoot) {
|
|
|
10557
10766
|
/* harmony export */ composedRanges: function() { return /* reexport safe */ _composed_ranges_js__WEBPACK_IMPORTED_MODULE_2__.composedRanges; },
|
|
10558
10767
|
/* harmony export */ cursorInTheEdgeOfString: function() { return /* binding */ cursorInTheEdgeOfString; },
|
|
10559
10768
|
/* harmony export */ findCorrectCurrentNode: function() { return /* binding */ findCorrectCurrentNode; },
|
|
10560
|
-
/* harmony export */
|
|
10769
|
+
/* harmony export */ isMoved: function() { return /* reexport safe */ _is_moved_js__WEBPACK_IMPORTED_MODULE_3__.isMoved; },
|
|
10770
|
+
/* harmony export */ moveNodeInsideStart: function() { return /* reexport safe */ _move_node_inside_start_js__WEBPACK_IMPORTED_MODULE_4__.moveNodeInsideStart; }
|
|
10561
10771
|
/* harmony export */ });
|
|
10562
10772
|
/* harmony import */ var _constants_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(82758);
|
|
10563
10773
|
/* harmony import */ var _dom_dom_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2748);
|
|
10564
10774
|
/* harmony import */ var _composed_ranges_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(79505);
|
|
10565
|
-
/* harmony import */ var
|
|
10566
|
-
/* harmony import */ var
|
|
10775
|
+
/* harmony import */ var _is_moved_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(12604);
|
|
10776
|
+
/* harmony import */ var _move_node_inside_start_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(26716);
|
|
10777
|
+
/* harmony import */ var _move_the_node_along_the_edge_outward_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(43463);
|
|
10567
10778
|
/*!
|
|
10568
10779
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
10569
10780
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -10575,6 +10786,7 @@ function usable(ranges, shadowRoot) {
|
|
|
10575
10786
|
|
|
10576
10787
|
|
|
10577
10788
|
|
|
10789
|
+
|
|
10578
10790
|
/**
|
|
10579
10791
|
* Despite the name, returns `true` when the cursor is NOT at the checked edge
|
|
10580
10792
|
* of the text node: there is significant (non invisible-space) text between
|
|
@@ -10630,6 +10842,33 @@ function findCorrectCurrentNode(node, range, rightMode, isCollapsed, checkChild,
|
|
|
10630
10842
|
}
|
|
10631
10843
|
|
|
10632
10844
|
|
|
10845
|
+
/***/ }),
|
|
10846
|
+
|
|
10847
|
+
/***/ 12604:
|
|
10848
|
+
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
10849
|
+
|
|
10850
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
10851
|
+
/* harmony export */ isMoved: function() { return /* binding */ isMoved; }
|
|
10852
|
+
/* harmony export */ });
|
|
10853
|
+
/*!
|
|
10854
|
+
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
10855
|
+
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
10856
|
+
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net
|
|
10857
|
+
*/ /**
|
|
10858
|
+
* Whether the selection, `before` as it was when a key went down, has since
|
|
10859
|
+
* moved to somewhere else in the editor
|
|
10860
|
+
* @private
|
|
10861
|
+
*/ function isMoved(jodit, before) {
|
|
10862
|
+
const { s } = jodit;
|
|
10863
|
+
// Selecting table cells, for one, removes the selection altogether
|
|
10864
|
+
if (!before || !s.isInsideArea) {
|
|
10865
|
+
return false;
|
|
10866
|
+
}
|
|
10867
|
+
const { range } = s;
|
|
10868
|
+
return range.startContainer !== before.startContainer || range.startOffset !== before.startOffset || range.endContainer !== before.endContainer || range.endOffset !== before.endOffset;
|
|
10869
|
+
}
|
|
10870
|
+
|
|
10871
|
+
|
|
10633
10872
|
/***/ }),
|
|
10634
10873
|
|
|
10635
10874
|
/***/ 26716:
|
|
@@ -12673,11 +12912,13 @@ function elementsEqualAttributes(elm1, elm2) {
|
|
|
12673
12912
|
/* harmony export */ toggleOrderedList: function() { return /* binding */ toggleOrderedList; }
|
|
12674
12913
|
/* harmony export */ });
|
|
12675
12914
|
/* harmony import */ var _dom_dom_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2748);
|
|
12676
|
-
/* harmony import */ var
|
|
12677
|
-
/* harmony import */ var
|
|
12678
|
-
/* harmony import */ var
|
|
12679
|
-
/* harmony import */ var
|
|
12680
|
-
/* harmony import */ var
|
|
12915
|
+
/* harmony import */ var _helpers_size_object_size_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(21496);
|
|
12916
|
+
/* harmony import */ var _helpers_utils_assert_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(38837);
|
|
12917
|
+
/* harmony import */ var _extract_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(32526);
|
|
12918
|
+
/* harmony import */ var _is_same_attributes_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(94466);
|
|
12919
|
+
/* harmony import */ var _toggle_attributes_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(44253);
|
|
12920
|
+
/* harmony import */ var _constants_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(77361);
|
|
12921
|
+
/* harmony import */ var _wrap_list_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(82515);
|
|
12681
12922
|
/*!
|
|
12682
12923
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
12683
12924
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -12688,6 +12929,8 @@ function elementsEqualAttributes(elm1, elm2) {
|
|
|
12688
12929
|
|
|
12689
12930
|
|
|
12690
12931
|
|
|
12932
|
+
|
|
12933
|
+
|
|
12691
12934
|
/**
|
|
12692
12935
|
* Replaces `ul->ol` or `ol->ul`, apply styles to the list, or remove a list item from it
|
|
12693
12936
|
* @private
|
|
@@ -12699,39 +12942,69 @@ function elementsEqualAttributes(elm1, elm2) {
|
|
|
12699
12942
|
if (!list) {
|
|
12700
12943
|
return mode;
|
|
12701
12944
|
}
|
|
12702
|
-
const result = jodit.e.fire(`${
|
|
12945
|
+
const result = jodit.e.fire(`${_constants_js__WEBPACK_IMPORTED_MODULE_6__._PREFIX}BeforeToggleList`, mode, commitStyle, list);
|
|
12703
12946
|
if (result !== undefined) {
|
|
12704
12947
|
return result;
|
|
12705
12948
|
}
|
|
12706
|
-
const hook = jodit.e.fire.bind(jodit.e, `${
|
|
12949
|
+
const hook = jodit.e.fire.bind(jodit.e, `${_constants_js__WEBPACK_IMPORTED_MODULE_6__._PREFIX}AfterToggleList`);
|
|
12707
12950
|
if (mode !== (/* inlined export .UNWRAP */"unwrap")) {
|
|
12708
|
-
const isChangeMode = (0,
|
|
12951
|
+
const isChangeMode = (0,_toggle_attributes_js__WEBPACK_IMPORTED_MODULE_5__.toggleAttributes)(commitStyle, li.parentElement, jodit, _constants_js__WEBPACK_IMPORTED_MODULE_6__.INITIAL, true) === (/* inlined export .CHANGE */"change");
|
|
12952
|
+
const isSameList = _dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(list, commitStyle.element);
|
|
12953
|
+
// ol => ol[style="list-style-type: lower-roman"]: a list's style
|
|
12954
|
+
// belongs to the whole list, so it is changed without splitting it
|
|
12955
|
+
if (isSameList && isChangeMode && mode !== _constants_js__WEBPACK_IMPORTED_MODULE_6__.REPLACE && changesStyleOnly(commitStyle)) {
|
|
12956
|
+
(0,_toggle_attributes_js__WEBPACK_IMPORTED_MODULE_5__.toggleAttributes)(commitStyle, list, jodit, (/* inlined export .CHANGE */"change"));
|
|
12957
|
+
hook((/* inlined export .CHANGE */"change"), joinPrevious(commitStyle, list, mode), commitStyle);
|
|
12958
|
+
return (/* inlined export .CHANGE */"change");
|
|
12959
|
+
}
|
|
12960
|
+
// Restyled already, for an earlier part of the selection
|
|
12961
|
+
if (isSameList && mode === (/* inlined export .CHANGE */"change")) {
|
|
12962
|
+
return (/* inlined export .CHANGE */"change");
|
|
12963
|
+
}
|
|
12709
12964
|
// ul => ol, ol => ul or ul => ul.class1
|
|
12710
|
-
if (mode ===
|
|
12711
|
-
const wrapper = unwrapList(
|
|
12712
|
-
const newList = (0,
|
|
12713
|
-
hook(
|
|
12714
|
-
return
|
|
12965
|
+
if (mode === _constants_js__WEBPACK_IMPORTED_MODULE_6__.REPLACE || isChangeMode || !isSameList) {
|
|
12966
|
+
const wrapper = unwrapList(_constants_js__WEBPACK_IMPORTED_MODULE_6__.REPLACE, list, li, jodit, commitStyle);
|
|
12967
|
+
const newList = (0,_wrap_list_js__WEBPACK_IMPORTED_MODULE_7__.wrapList)(commitStyle, wrapper, jodit);
|
|
12968
|
+
hook(_constants_js__WEBPACK_IMPORTED_MODULE_6__.REPLACE, newList, commitStyle);
|
|
12969
|
+
return _constants_js__WEBPACK_IMPORTED_MODULE_6__.REPLACE;
|
|
12715
12970
|
}
|
|
12716
12971
|
}
|
|
12717
12972
|
const wrapper = unwrapList((/* inlined export .UNWRAP */"unwrap"), list, li, jodit, commitStyle);
|
|
12718
12973
|
hook((/* inlined export .UNWRAP */"unwrap"), wrapper, commitStyle);
|
|
12719
12974
|
return (/* inlined export .UNWRAP */"unwrap");
|
|
12720
12975
|
}
|
|
12976
|
+
/**
|
|
12977
|
+
* Other attributes, such as a class, still move the items into a new list,
|
|
12978
|
+
* where the `beforeWrapList` hook can add markup to each of them
|
|
12979
|
+
*/ function changesStyleOnly({ options: { attributes } }) {
|
|
12980
|
+
return Boolean(attributes === null || attributes === void 0 ? void 0 : attributes.style) && (0,_helpers_size_object_size_js__WEBPACK_IMPORTED_MODULE_1__.size)(attributes) === 1;
|
|
12981
|
+
}
|
|
12982
|
+
/**
|
|
12983
|
+
* Joins a restyled list to the list before it, when the selection runs on
|
|
12984
|
+
* from that list and the two now match
|
|
12985
|
+
*/ function joinPrevious(commitStyle, list, mode) {
|
|
12986
|
+
const prev = _dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.findSibling(list, true);
|
|
12987
|
+
if (mode !== (/* inlined export .CHANGE */"change") || !_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(prev, commitStyle.element) || !(0,_is_same_attributes_js__WEBPACK_IMPORTED_MODULE_4__.elementsEqualAttributes)(prev, list)) {
|
|
12988
|
+
return list;
|
|
12989
|
+
}
|
|
12990
|
+
_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.append(prev, Array.from(list.childNodes));
|
|
12991
|
+
_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(list);
|
|
12992
|
+
return prev;
|
|
12993
|
+
}
|
|
12721
12994
|
function unwrapList(mode, list, li, jodit, cs) {
|
|
12722
|
-
const result = jodit.e.fire(`${
|
|
12995
|
+
const result = jodit.e.fire(`${_constants_js__WEBPACK_IMPORTED_MODULE_6__._PREFIX}BeforeUnwrapList`, mode, list, cs);
|
|
12723
12996
|
if (result) {
|
|
12724
|
-
(0,
|
|
12997
|
+
(0,_helpers_utils_assert_js__WEBPACK_IMPORTED_MODULE_2__.assert)(_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isHTMLElement(result), `${_constants_js__WEBPACK_IMPORTED_MODULE_6__._PREFIX}BeforeUnwrapList hook must return HTMLElement`);
|
|
12725
12998
|
return result;
|
|
12726
12999
|
}
|
|
12727
|
-
;(0,
|
|
12728
|
-
(0,
|
|
13000
|
+
;(0,_extract_js__WEBPACK_IMPORTED_MODULE_3__.extractSelectedPart)(list, li, jodit);
|
|
13001
|
+
(0,_helpers_utils_assert_js__WEBPACK_IMPORTED_MODULE_2__.assert)(_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isHTMLElement(li.parentElement), 'Element should be inside the list');
|
|
12729
13002
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.unwrap(li.parentElement);
|
|
12730
13003
|
// In the REPLACE mode the content will be immediately wrapped in a `li`
|
|
12731
13004
|
// of the new list inside `wrapList`, so it should stay in the document.
|
|
12732
13005
|
// Replacing it with a fragment here would dissolve the content
|
|
12733
13006
|
// (with `enter: 'br'`) and the new list would never be inserted.
|
|
12734
|
-
if (mode ===
|
|
13007
|
+
if (mode === _constants_js__WEBPACK_IMPORTED_MODULE_6__.REPLACE) {
|
|
12735
13008
|
return li;
|
|
12736
13009
|
}
|
|
12737
13010
|
return _dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.replace(li, jodit.o.enter.toLowerCase() !== 'br' ? jodit.o.enter : jodit.createInside.fragment(), jodit.createInside);
|
|
@@ -13429,7 +13702,7 @@ const transactions = {
|
|
|
13429
13702
|
[states.LIST]: {
|
|
13430
13703
|
exec (value) {
|
|
13431
13704
|
const { element, jodit, mode } = value;
|
|
13432
|
-
if (mode !== _constants_js__WEBPACK_IMPORTED_MODULE_4__.INITIAL && mode !== (/* inlined export .UNWRAP */"unwrap") && mode !== _constants_js__WEBPACK_IMPORTED_MODULE_4__.REPLACE) {
|
|
13705
|
+
if (mode !== _constants_js__WEBPACK_IMPORTED_MODULE_4__.INITIAL && mode !== (/* inlined export .UNWRAP */"unwrap") && mode !== _constants_js__WEBPACK_IMPORTED_MODULE_4__.REPLACE && mode !== (/* inlined export .CHANGE */"change")) {
|
|
13433
13706
|
return {
|
|
13434
13707
|
...value,
|
|
13435
13708
|
next: states.END
|
|
@@ -16680,6 +16953,7 @@ Icon.__cache = new Map();
|
|
|
16680
16953
|
else for(var i = decorators.length - 1; i >= 0; i--)if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
16681
16954
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
16682
16955
|
};
|
|
16956
|
+
var Popup_1;
|
|
16683
16957
|
|
|
16684
16958
|
|
|
16685
16959
|
|
|
@@ -16696,7 +16970,7 @@ const EVENTS_FOR_AUTOCLOSE = [
|
|
|
16696
16970
|
'backSpaceAfterDelete',
|
|
16697
16971
|
'beforeCommandDelete'
|
|
16698
16972
|
];
|
|
16699
|
-
class Popup extends _group_group_js__WEBPACK_IMPORTED_MODULE_8__.UIGroup {
|
|
16973
|
+
let Popup = Popup_1 = class Popup extends _group_group_js__WEBPACK_IMPORTED_MODULE_8__.UIGroup {
|
|
16700
16974
|
className() {
|
|
16701
16975
|
return 'Popup';
|
|
16702
16976
|
}
|
|
@@ -16706,7 +16980,7 @@ class Popup extends _group_group_js__WEBPACK_IMPORTED_MODULE_8__.UIGroup {
|
|
|
16706
16980
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_2__.Dom.append(content, childContainer);
|
|
16707
16981
|
}
|
|
16708
16982
|
updateParentElement(target) {
|
|
16709
|
-
if (target !== this && _component_component_js__WEBPACK_IMPORTED_MODULE_0__.Component.isInstanceOf(target,
|
|
16983
|
+
if (target !== this && _component_component_js__WEBPACK_IMPORTED_MODULE_0__.Component.isInstanceOf(target, Popup_1)) {
|
|
16710
16984
|
this.__childrenPopups.forEach((popup)=>{
|
|
16711
16985
|
if (!target.closest(popup) && popup.isOpened) {
|
|
16712
16986
|
popup.close();
|
|
@@ -16748,7 +17022,7 @@ class Popup extends _group_group_js__WEBPACK_IMPORTED_MODULE_8__.UIGroup {
|
|
|
16748
17022
|
if (parentContainer) {
|
|
16749
17023
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_2__.Dom.append(parentContainer, this.container);
|
|
16750
17024
|
} else {
|
|
16751
|
-
const popupContainer = (0,_global_js__WEBPACK_IMPORTED_MODULE_3__.getContainer)(this.jodit,
|
|
17025
|
+
const popupContainer = (0,_global_js__WEBPACK_IMPORTED_MODULE_3__.getContainer)(this.jodit, Popup_1);
|
|
16752
17026
|
if (parentContainer !== this.container.parentElement) {
|
|
16753
17027
|
_dom_dom_js__WEBPACK_IMPORTED_MODULE_2__.Dom.append(popupContainer, this.container);
|
|
16754
17028
|
}
|
|
@@ -16861,11 +17135,11 @@ class Popup extends _group_group_js__WEBPACK_IMPORTED_MODULE_8__.UIGroup {
|
|
|
16861
17135
|
};
|
|
16862
17136
|
const getMatchStrategy = (inBox)=>{
|
|
16863
17137
|
let strategy;
|
|
16864
|
-
if (
|
|
17138
|
+
if (Popup_1.boxInView(getPointByStrategy(defaultStrategy), inBox)) {
|
|
16865
17139
|
strategy = defaultStrategy;
|
|
16866
17140
|
} else {
|
|
16867
17141
|
strategy = list.find((key)=>{
|
|
16868
|
-
if (
|
|
17142
|
+
if (Popup_1.boxInView(getPointByStrategy(key), inBox)) {
|
|
16869
17143
|
return key;
|
|
16870
17144
|
}
|
|
16871
17145
|
return;
|
|
@@ -16876,7 +17150,7 @@ class Popup extends _group_group_js__WEBPACK_IMPORTED_MODULE_8__.UIGroup {
|
|
|
16876
17150
|
// Try to find match position inside Jodit.container
|
|
16877
17151
|
let strategy = getMatchStrategy((0,_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.position)(this.j.container, this.j));
|
|
16878
17152
|
// If not found or is not inside window view
|
|
16879
|
-
if (!strategy || !
|
|
17153
|
+
if (!strategy || !Popup_1.boxInView(getPointByStrategy(strategy), view)) {
|
|
16880
17154
|
// Find match strategy inside window view
|
|
16881
17155
|
strategy = getMatchStrategy(view) || strategy || defaultStrategy;
|
|
16882
17156
|
}
|
|
@@ -16926,7 +17200,7 @@ class Popup extends _group_group_js__WEBPACK_IMPORTED_MODULE_8__.UIGroup {
|
|
|
16926
17200
|
if (!e.target) {
|
|
16927
17201
|
return false;
|
|
16928
17202
|
}
|
|
16929
|
-
const box = _element_js__WEBPACK_IMPORTED_MODULE_7__.UIElement.closestElement(e.target,
|
|
17203
|
+
const box = _element_js__WEBPACK_IMPORTED_MODULE_7__.UIElement.closestElement(e.target, Popup_1);
|
|
16930
17204
|
return Boolean(box && (this === box || box.closest(this)));
|
|
16931
17205
|
}
|
|
16932
17206
|
__addGlobalListeners() {
|
|
@@ -16981,7 +17255,7 @@ class Popup extends _group_group_js__WEBPACK_IMPORTED_MODULE_8__.UIGroup {
|
|
|
16981
17255
|
this.__childrenPopups = new Set();
|
|
16982
17256
|
(0,_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(this.container, 'role', 'popup');
|
|
16983
17257
|
}
|
|
16984
|
-
}
|
|
17258
|
+
};
|
|
16985
17259
|
__decorate([
|
|
16986
17260
|
_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__.autobind
|
|
16987
17261
|
], Popup.prototype, "updatePosition", null);
|
|
@@ -16995,6 +17269,10 @@ __decorate([
|
|
|
16995
17269
|
__decorate([
|
|
16996
17270
|
_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__.autobind
|
|
16997
17271
|
], Popup.prototype, "__closeOnOutsideClick", null);
|
|
17272
|
+
Popup = Popup_1 = __decorate([
|
|
17273
|
+
_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__.component
|
|
17274
|
+
], Popup);
|
|
17275
|
+
|
|
16998
17276
|
|
|
16999
17277
|
|
|
17000
17278
|
/***/ }),
|
|
@@ -18192,7 +18470,7 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
18192
18470
|
commands.push(command);
|
|
18193
18471
|
if (!(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.isFunction)(command)) {
|
|
18194
18472
|
const hotkeys = this.o.commandToHotkeys[commandName] || this.o.commandToHotkeys[commandNameOriginal] || command.hotkeys;
|
|
18195
|
-
if (hotkeys) {
|
|
18473
|
+
if (hotkeys && hotkeys.length) {
|
|
18196
18474
|
this.registerHotkeyToCommand(hotkeys, commandName, options === null || options === void 0 ? void 0 : options.stopPropagation);
|
|
18197
18475
|
}
|
|
18198
18476
|
}
|
|
@@ -18201,6 +18479,10 @@ let Jodit = Jodit_1 = class Jodit extends _modules_index_js__WEBPACK_IMPORTED_MO
|
|
|
18201
18479
|
/**
|
|
18202
18480
|
* Register hotkey for command
|
|
18203
18481
|
*/ registerHotkeyToCommand(hotkeys, commandName, shouldStop = true) {
|
|
18482
|
+
// An empty list (e.g. `commandToHotkeys: { cmd: [] }`) turns the key off
|
|
18483
|
+
if (!hotkeys || !hotkeys.length) {
|
|
18484
|
+
return;
|
|
18485
|
+
}
|
|
18204
18486
|
const shortcuts = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.asArray)(hotkeys).map(_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.normalizeKeyAliases).map((hotkey)=>hotkey + '.hotkey').join(' ');
|
|
18205
18487
|
this.e.off(shortcuts).on(shortcuts, (type, stop)=>{
|
|
18206
18488
|
if (stop) {
|
|
@@ -19212,7 +19494,10 @@ function addClassNames(className, elm) {
|
|
|
19212
19494
|
Autoplay: 'تشغيل تلقائي',
|
|
19213
19495
|
Loop: 'تكرار',
|
|
19214
19496
|
Muted: 'مكتوم الصوت',
|
|
19215
|
-
Controls: 'عناصر التحكم'
|
|
19497
|
+
Controls: 'عناصر التحكم',
|
|
19498
|
+
'Start at...': 'البدء من...',
|
|
19499
|
+
'Start numbering at': 'بدء الترقيم من',
|
|
19500
|
+
'Number for the first item': 'رقم العنصر الأول'
|
|
19216
19501
|
});
|
|
19217
19502
|
|
|
19218
19503
|
|
|
@@ -19453,7 +19738,10 @@ function addClassNames(className, elm) {
|
|
|
19453
19738
|
Autoplay: 'Avtomatik oynatma',
|
|
19454
19739
|
Loop: 'Təkrarla',
|
|
19455
19740
|
Muted: 'Səssiz',
|
|
19456
|
-
Controls: 'İdarəetmə elementləri'
|
|
19741
|
+
Controls: 'İdarəetmə elementləri',
|
|
19742
|
+
'Start at...': 'Başlanğıc nömrəsi...',
|
|
19743
|
+
'Start numbering at': 'Nömrələmənin başlanğıcı',
|
|
19744
|
+
'Number for the first item': 'Birinci bəndin nömrəsi'
|
|
19457
19745
|
});
|
|
19458
19746
|
|
|
19459
19747
|
|
|
@@ -19686,7 +19974,10 @@ function addClassNames(className, elm) {
|
|
|
19686
19974
|
Autoplay: 'Automatické přehrávání',
|
|
19687
19975
|
Loop: 'Opakovat',
|
|
19688
19976
|
Muted: 'Ztlumeno',
|
|
19689
|
-
Controls: 'Ovládací prvky'
|
|
19977
|
+
Controls: 'Ovládací prvky',
|
|
19978
|
+
'Start at...': 'Začít od...',
|
|
19979
|
+
'Start numbering at': 'Začít číslování od',
|
|
19980
|
+
'Number for the first item': 'Číslo první položky'
|
|
19690
19981
|
});
|
|
19691
19982
|
|
|
19692
19983
|
|
|
@@ -19923,7 +20214,10 @@ function addClassNames(className, elm) {
|
|
|
19923
20214
|
Autoplay: 'Automatische Wiedergabe',
|
|
19924
20215
|
Loop: 'Wiederholen',
|
|
19925
20216
|
Muted: 'Stumm',
|
|
19926
|
-
Controls: 'Steuerelemente'
|
|
20217
|
+
Controls: 'Steuerelemente',
|
|
20218
|
+
'Start at...': 'Beginnen bei...',
|
|
20219
|
+
'Start numbering at': 'Nummerierung beginnen bei',
|
|
20220
|
+
'Number for the first item': 'Nummer des ersten Eintrags'
|
|
19927
20221
|
});
|
|
19928
20222
|
|
|
19929
20223
|
|
|
@@ -20177,7 +20471,10 @@ function addClassNames(className, elm) {
|
|
|
20177
20471
|
Autoplay: 'Reproducción automática',
|
|
20178
20472
|
Loop: 'Repetir',
|
|
20179
20473
|
Muted: 'Silenciado',
|
|
20180
|
-
Controls: 'Controles'
|
|
20474
|
+
Controls: 'Controles',
|
|
20475
|
+
'Start at...': 'Empezar en...',
|
|
20476
|
+
'Start numbering at': 'Empezar la numeración en',
|
|
20477
|
+
'Number for the first item': 'Número del primer elemento'
|
|
20181
20478
|
});
|
|
20182
20479
|
|
|
20183
20480
|
|
|
@@ -20409,7 +20706,10 @@ function addClassNames(className, elm) {
|
|
|
20409
20706
|
Autoplay: 'پخش خودکار',
|
|
20410
20707
|
Loop: 'تکرار',
|
|
20411
20708
|
Muted: 'بیصدا',
|
|
20412
|
-
Controls: 'کنترلها'
|
|
20709
|
+
Controls: 'کنترلها',
|
|
20710
|
+
'Start at...': 'شروع از...',
|
|
20711
|
+
'Start numbering at': 'شروع شمارهگذاری از',
|
|
20712
|
+
'Number for the first item': 'شمارهی نخستین مورد'
|
|
20413
20713
|
});
|
|
20414
20714
|
|
|
20415
20715
|
|
|
@@ -20647,7 +20947,10 @@ function addClassNames(className, elm) {
|
|
|
20647
20947
|
Autoplay: 'Automaattinen toisto',
|
|
20648
20948
|
Loop: 'Toista uudelleen',
|
|
20649
20949
|
Muted: 'Mykistetty',
|
|
20650
|
-
Controls: 'Säätimet'
|
|
20950
|
+
Controls: 'Säätimet',
|
|
20951
|
+
'Start at...': 'Aloita numerosta...',
|
|
20952
|
+
'Start numbering at': 'Aloita numerointi numerosta',
|
|
20953
|
+
'Number for the first item': 'Ensimmäisen kohdan numero'
|
|
20651
20954
|
});
|
|
20652
20955
|
|
|
20653
20956
|
|
|
@@ -20879,7 +21182,10 @@ function addClassNames(className, elm) {
|
|
|
20879
21182
|
Autoplay: 'Lecture automatique',
|
|
20880
21183
|
Loop: 'Lecture en boucle',
|
|
20881
21184
|
Muted: 'Muet',
|
|
20882
|
-
Controls: 'Commandes'
|
|
21185
|
+
Controls: 'Commandes',
|
|
21186
|
+
'Start at...': 'Commencer à...',
|
|
21187
|
+
'Start numbering at': 'Commencer la numérotation à',
|
|
21188
|
+
'Number for the first item': 'Numéro du premier élément'
|
|
20883
21189
|
});
|
|
20884
21190
|
|
|
20885
21191
|
|
|
@@ -21111,7 +21417,10 @@ function addClassNames(className, elm) {
|
|
|
21111
21417
|
Autoplay: 'ניגון אוטומטי',
|
|
21112
21418
|
Loop: 'הפעלה חוזרת',
|
|
21113
21419
|
Muted: 'מושתק',
|
|
21114
|
-
Controls: 'פקדים'
|
|
21420
|
+
Controls: 'פקדים',
|
|
21421
|
+
'Start at...': 'התחל מ...',
|
|
21422
|
+
'Start numbering at': 'התחל מספור מ',
|
|
21423
|
+
'Number for the first item': 'מספר הפריט הראשון'
|
|
21115
21424
|
});
|
|
21116
21425
|
|
|
21117
21426
|
|
|
@@ -21345,7 +21654,10 @@ function addClassNames(className, elm) {
|
|
|
21345
21654
|
Autoplay: 'Automatikus lejátszás',
|
|
21346
21655
|
Loop: 'Ismétlés',
|
|
21347
21656
|
Muted: 'Némítva',
|
|
21348
|
-
Controls: 'Vezérlők'
|
|
21657
|
+
Controls: 'Vezérlők',
|
|
21658
|
+
'Start at...': 'Kezdőszám...',
|
|
21659
|
+
'Start numbering at': 'Számozás kezdőértéke',
|
|
21660
|
+
'Number for the first item': 'Az első elem száma'
|
|
21349
21661
|
});
|
|
21350
21662
|
|
|
21351
21663
|
|
|
@@ -21578,7 +21890,10 @@ function addClassNames(className, elm) {
|
|
|
21578
21890
|
Autoplay: 'Putar otomatis',
|
|
21579
21891
|
Loop: 'Ulangi',
|
|
21580
21892
|
Muted: 'Dibisukan',
|
|
21581
|
-
Controls: 'Kontrol'
|
|
21893
|
+
Controls: 'Kontrol',
|
|
21894
|
+
'Start at...': 'Mulai dari...',
|
|
21895
|
+
'Start numbering at': 'Mulai penomoran dari',
|
|
21896
|
+
'Number for the first item': 'Nomor untuk item pertama'
|
|
21582
21897
|
});
|
|
21583
21898
|
|
|
21584
21899
|
|
|
@@ -21815,7 +22130,10 @@ function addClassNames(className, elm) {
|
|
|
21815
22130
|
Autoplay: 'Riproduzione automatica',
|
|
21816
22131
|
Loop: 'Ripeti',
|
|
21817
22132
|
Muted: 'Muto',
|
|
21818
|
-
Controls: 'Controlli'
|
|
22133
|
+
Controls: 'Controlli',
|
|
22134
|
+
'Start at...': 'Inizia da...',
|
|
22135
|
+
'Start numbering at': 'Inizia la numerazione da',
|
|
22136
|
+
'Number for the first item': 'Numero del primo elemento'
|
|
21819
22137
|
});
|
|
21820
22138
|
|
|
21821
22139
|
|
|
@@ -22052,7 +22370,10 @@ function addClassNames(className, elm) {
|
|
|
22052
22370
|
Autoplay: '自動再生',
|
|
22053
22371
|
Loop: 'ループ再生',
|
|
22054
22372
|
Muted: 'ミュート',
|
|
22055
|
-
Controls: 'コントロール'
|
|
22373
|
+
Controls: 'コントロール',
|
|
22374
|
+
'Start at...': '開始番号...',
|
|
22375
|
+
'Start numbering at': '番号の開始値',
|
|
22376
|
+
'Number for the first item': '最初の項目の番号'
|
|
22056
22377
|
});
|
|
22057
22378
|
|
|
22058
22379
|
|
|
@@ -22295,7 +22616,10 @@ function addClassNames(className, elm) {
|
|
|
22295
22616
|
Autoplay: '자동 재생',
|
|
22296
22617
|
Loop: '반복 재생',
|
|
22297
22618
|
Muted: '음소거',
|
|
22298
|
-
Controls: '컨트롤'
|
|
22619
|
+
Controls: '컨트롤',
|
|
22620
|
+
'Start at...': '시작 번호...',
|
|
22621
|
+
'Start numbering at': '번호 매기기 시작 값',
|
|
22622
|
+
'Number for the first item': '첫 번째 항목의 번호'
|
|
22299
22623
|
});
|
|
22300
22624
|
|
|
22301
22625
|
|
|
@@ -22527,7 +22851,10 @@ function addClassNames(className, elm) {
|
|
|
22527
22851
|
Autoplay: 'Автоматаар тоглуулах',
|
|
22528
22852
|
Loop: 'Давтах',
|
|
22529
22853
|
Muted: 'Дуугүй',
|
|
22530
|
-
Controls: 'Удирдлага'
|
|
22854
|
+
Controls: 'Удирдлага',
|
|
22855
|
+
'Start at...': 'Эхлэх дугаар...',
|
|
22856
|
+
'Start numbering at': 'Дугаарлалт эхлэх',
|
|
22857
|
+
'Number for the first item': 'Эхний зүйлийн дугаар'
|
|
22531
22858
|
});
|
|
22532
22859
|
|
|
22533
22860
|
|
|
@@ -22760,7 +23087,10 @@ function addClassNames(className, elm) {
|
|
|
22760
23087
|
Autoplay: 'Automatisch afspelen',
|
|
22761
23088
|
Loop: 'Herhalen',
|
|
22762
23089
|
Muted: 'Gedempt',
|
|
22763
|
-
Controls: 'Bedieningselementen'
|
|
23090
|
+
Controls: 'Bedieningselementen',
|
|
23091
|
+
'Start at...': 'Beginnen bij...',
|
|
23092
|
+
'Start numbering at': 'Nummering beginnen bij',
|
|
23093
|
+
'Number for the first item': 'Nummer van het eerste item'
|
|
22764
23094
|
});
|
|
22765
23095
|
|
|
22766
23096
|
|
|
@@ -23001,7 +23331,10 @@ function addClassNames(className, elm) {
|
|
|
23001
23331
|
Autoplay: 'Automatisk avspilling',
|
|
23002
23332
|
Loop: 'Gjenta',
|
|
23003
23333
|
Muted: 'Dempet',
|
|
23004
|
-
Controls: 'Kontroller'
|
|
23334
|
+
Controls: 'Kontroller',
|
|
23335
|
+
'Start at...': 'Start på...',
|
|
23336
|
+
'Start numbering at': 'Start nummereringen på',
|
|
23337
|
+
'Number for the first item': 'Nummer for første punkt'
|
|
23005
23338
|
});
|
|
23006
23339
|
|
|
23007
23340
|
|
|
@@ -23233,7 +23566,10 @@ function addClassNames(className, elm) {
|
|
|
23233
23566
|
Autoplay: 'Autoodtwarzanie',
|
|
23234
23567
|
Loop: 'Zapętlenie',
|
|
23235
23568
|
Muted: 'Wyciszony',
|
|
23236
|
-
Controls: 'Elementy sterujące'
|
|
23569
|
+
Controls: 'Elementy sterujące',
|
|
23570
|
+
'Start at...': 'Zacznij od...',
|
|
23571
|
+
'Start numbering at': 'Rozpocznij numerowanie od',
|
|
23572
|
+
'Number for the first item': 'Numer pierwszego elementu'
|
|
23237
23573
|
});
|
|
23238
23574
|
|
|
23239
23575
|
|
|
@@ -23470,7 +23806,10 @@ function addClassNames(className, elm) {
|
|
|
23470
23806
|
Autoplay: 'Reprodução automática',
|
|
23471
23807
|
Loop: 'Repetir',
|
|
23472
23808
|
Muted: 'Sem som',
|
|
23473
|
-
Controls: 'Controles'
|
|
23809
|
+
Controls: 'Controles',
|
|
23810
|
+
'Start at...': 'Começar em...',
|
|
23811
|
+
'Start numbering at': 'Começar a numeração em',
|
|
23812
|
+
'Number for the first item': 'Número do primeiro item'
|
|
23474
23813
|
});
|
|
23475
23814
|
|
|
23476
23815
|
|
|
@@ -23701,7 +24040,10 @@ function addClassNames(className, elm) {
|
|
|
23701
24040
|
Autoplay: 'Автовоспроизведение',
|
|
23702
24041
|
Loop: 'Повтор',
|
|
23703
24042
|
Muted: 'Без звука',
|
|
23704
|
-
Controls: 'Элементы управления'
|
|
24043
|
+
Controls: 'Элементы управления',
|
|
24044
|
+
'Start at...': 'Начать с...',
|
|
24045
|
+
'Start numbering at': 'Начать нумерацию с',
|
|
24046
|
+
'Number for the first item': 'Номер первого пункта'
|
|
23705
24047
|
});
|
|
23706
24048
|
|
|
23707
24049
|
|
|
@@ -23940,7 +24282,10 @@ function addClassNames(className, elm) {
|
|
|
23940
24282
|
Autoplay: 'Automatické prehrávanie',
|
|
23941
24283
|
Loop: 'Opakovať',
|
|
23942
24284
|
Muted: 'Stlmené',
|
|
23943
|
-
Controls: 'Ovládacie prvky'
|
|
24285
|
+
Controls: 'Ovládacie prvky',
|
|
24286
|
+
'Start at...': 'Začať od...',
|
|
24287
|
+
'Start numbering at': 'Začať číslovanie od',
|
|
24288
|
+
'Number for the first item': 'Číslo prvej položky'
|
|
23944
24289
|
});
|
|
23945
24290
|
|
|
23946
24291
|
|
|
@@ -24180,7 +24525,10 @@ function addClassNames(className, elm) {
|
|
|
24180
24525
|
Autoplay: 'Automatisk uppspelning',
|
|
24181
24526
|
Loop: 'Upprepa',
|
|
24182
24527
|
Muted: 'Ljudlös',
|
|
24183
|
-
Controls: 'Kontroller'
|
|
24528
|
+
Controls: 'Kontroller',
|
|
24529
|
+
'Start at...': 'Börja på...',
|
|
24530
|
+
'Start numbering at': 'Börja numreringen på',
|
|
24531
|
+
'Number for the first item': 'Nummer för första punkten'
|
|
24184
24532
|
});
|
|
24185
24533
|
|
|
24186
24534
|
|
|
@@ -24412,7 +24760,10 @@ function addClassNames(className, elm) {
|
|
|
24412
24760
|
Autoplay: 'Otomatik oynat',
|
|
24413
24761
|
Loop: 'Döngü',
|
|
24414
24762
|
Muted: 'Sessiz',
|
|
24415
|
-
Controls: 'Kontroller'
|
|
24763
|
+
Controls: 'Kontroller',
|
|
24764
|
+
'Start at...': 'Başlangıç numarası...',
|
|
24765
|
+
'Start numbering at': 'Numaralandırma başlangıcı',
|
|
24766
|
+
'Number for the first item': 'İlk öğenin numarası'
|
|
24416
24767
|
});
|
|
24417
24768
|
|
|
24418
24769
|
|
|
@@ -24643,7 +24994,10 @@ function addClassNames(className, elm) {
|
|
|
24643
24994
|
Autoplay: 'Автовідтворення',
|
|
24644
24995
|
Loop: 'Повтор',
|
|
24645
24996
|
Muted: 'Без звуку',
|
|
24646
|
-
Controls: 'Елементи керування'
|
|
24997
|
+
Controls: 'Елементи керування',
|
|
24998
|
+
'Start at...': 'Почати з...',
|
|
24999
|
+
'Start numbering at': 'Почати нумерацію з',
|
|
25000
|
+
'Number for the first item': 'Номер першого пункту'
|
|
24647
25001
|
});
|
|
24648
25002
|
|
|
24649
25003
|
|
|
@@ -24876,7 +25230,10 @@ function addClassNames(className, elm) {
|
|
|
24876
25230
|
Autoplay: '自动播放',
|
|
24877
25231
|
Loop: '循环播放',
|
|
24878
25232
|
Muted: '静音',
|
|
24879
|
-
Controls: '播放控件'
|
|
25233
|
+
Controls: '播放控件',
|
|
25234
|
+
'Start at...': '起始于...',
|
|
25235
|
+
'Start numbering at': '编号起始值',
|
|
25236
|
+
'Number for the first item': '第一项的编号'
|
|
24880
25237
|
});
|
|
24881
25238
|
|
|
24882
25239
|
|
|
@@ -25108,7 +25465,10 @@ function addClassNames(className, elm) {
|
|
|
25108
25465
|
Autoplay: '自動播放',
|
|
25109
25466
|
Loop: '循環播放',
|
|
25110
25467
|
Muted: '靜音',
|
|
25111
|
-
Controls: '播放控制項'
|
|
25468
|
+
Controls: '播放控制項',
|
|
25469
|
+
'Start at...': '起始於...',
|
|
25470
|
+
'Start numbering at': '編號起始值',
|
|
25471
|
+
'Number for the first item': '第一項的編號'
|
|
25112
25472
|
});
|
|
25113
25473
|
|
|
25114
25474
|
|
|
@@ -25619,7 +25979,12 @@ _config_js__WEBPACK_IMPORTED_MODULE_13__.Config.prototype.controls.dialog = {
|
|
|
25619
25979
|
}
|
|
25620
25980
|
}
|
|
25621
25981
|
__onResizerMouseDown(e) {
|
|
25622
|
-
var _a, _b
|
|
25982
|
+
var _a, _b;
|
|
25983
|
+
// As for the header: otherwise Safari selects the dialog's text as
|
|
25984
|
+
// the pointer moves
|
|
25985
|
+
if (e.cancelable) {
|
|
25986
|
+
e.preventDefault();
|
|
25987
|
+
}
|
|
25623
25988
|
this.resizable = true;
|
|
25624
25989
|
this.startX = e.clientX;
|
|
25625
25990
|
this.startY = e.clientY;
|
|
@@ -25631,8 +25996,8 @@ _config_js__WEBPACK_IMPORTED_MODULE_13__.Config.prototype.controls.dialog = {
|
|
|
25631
25996
|
// the content area does not shrink below its CSS `min-height`,
|
|
25632
25997
|
// so it is part of the smallest height the panel can take
|
|
25633
25998
|
const contentMinHeight = content ? parseFloat(this.ow.getComputedStyle(content).minHeight) || 0 : 0;
|
|
25634
|
-
this.minSize.w = (0,_core_helpers_checker_index_js__WEBPACK_IMPORTED_MODULE_6__.isNumber)(this.o.minWidth) ? this.o.minWidth : Math.max(100,
|
|
25635
|
-
this.minSize.h = (0,_core_helpers_checker_index_js__WEBPACK_IMPORTED_MODULE_6__.isNumber)(this.o.minHeight) ? this.o.minHeight : ((
|
|
25999
|
+
this.minSize.w = (0,_core_helpers_checker_index_js__WEBPACK_IMPORTED_MODULE_6__.isNumber)(this.o.minWidth) ? this.o.minWidth : Math.max(100, header ? this.__contentWidth(header) : 0, footer ? this.__contentWidth(footer) : 0);
|
|
26000
|
+
this.minSize.h = (0,_core_helpers_checker_index_js__WEBPACK_IMPORTED_MODULE_6__.isNumber)(this.o.minHeight) ? this.o.minHeight : ((_a = header === null || header === void 0 ? void 0 : header.offsetHeight) !== null && _a !== void 0 ? _a : 0) + ((_b = footer === null || footer === void 0 ? void 0 : footer.offsetHeight) !== null && _b !== void 0 ? _b : 0) + contentMinHeight + this.resizer.offsetHeight;
|
|
25636
26001
|
this.lockSelect();
|
|
25637
26002
|
this.__addGlobalResizeListeners();
|
|
25638
26003
|
if (this.e) {
|
|
@@ -25641,13 +26006,25 @@ _config_js__WEBPACK_IMPORTED_MODULE_13__.Config.prototype.controls.dialog = {
|
|
|
25641
26006
|
*/ this.e.fire(this, 'startResize');
|
|
25642
26007
|
}
|
|
25643
26008
|
}
|
|
26009
|
+
/**
|
|
26010
|
+
* The width `box` takes with its content on one line. The header and
|
|
26011
|
+
* footer are flex rows as wide as the dialog, so the footer's
|
|
26012
|
+
* `scrollWidth` was the dialog's width and kept it from getting any
|
|
26013
|
+
* narrower
|
|
26014
|
+
*/ __contentWidth(box) {
|
|
26015
|
+
const { width } = box.style;
|
|
26016
|
+
box.style.width = 'max-content';
|
|
26017
|
+
const contentWidth = box.offsetWidth;
|
|
26018
|
+
box.style.width = width;
|
|
26019
|
+
return contentWidth;
|
|
26020
|
+
}
|
|
25644
26021
|
__addGlobalResizeListeners() {
|
|
25645
26022
|
const self1 = this;
|
|
25646
26023
|
self1.e.on(self1.ow, 'pointermove touchmove', self1.__onMouseMove).on(self1.ow, 'pointerup touchend', self1.__onMouseUp);
|
|
25647
26024
|
}
|
|
25648
26025
|
__removeGlobalResizeListeners() {
|
|
25649
26026
|
const self1 = this;
|
|
25650
|
-
self1.e.off(self1.ow, '
|
|
26027
|
+
self1.e.off(self1.ow, 'pointermove touchmove', self1.__onMouseMove).off(self1.ow, 'pointerup touchend', self1.__onMouseUp);
|
|
25651
26028
|
}
|
|
25652
26029
|
/**
|
|
25653
26030
|
* Specifies the size of the window
|
|
@@ -28218,17 +28595,29 @@ const DEFAULT_SOURCE_NAME = 'default';
|
|
|
28218
28595
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
28219
28596
|
/* harmony export */ FileBrowserFiles: function() { return /* binding */ FileBrowserFiles; }
|
|
28220
28597
|
/* harmony export */ });
|
|
28221
|
-
/* harmony import */ var
|
|
28598
|
+
/* harmony import */ var _core_decorators_index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(65478);
|
|
28599
|
+
/* harmony import */ var _core_ui_index_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(67510);
|
|
28222
28600
|
/*!
|
|
28223
28601
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
28224
28602
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
28225
28603
|
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net
|
|
28226
|
-
*/
|
|
28227
|
-
|
|
28604
|
+
*/ var __decorate = undefined && undefined.__decorate || function(decorators, target, key, desc) {
|
|
28605
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
28606
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
28607
|
+
else for(var i = decorators.length - 1; i >= 0; i--)if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
28608
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
28609
|
+
};
|
|
28610
|
+
|
|
28611
|
+
|
|
28612
|
+
let FileBrowserFiles = class FileBrowserFiles extends _core_ui_index_js__WEBPACK_IMPORTED_MODULE_1__.UIGroup {
|
|
28228
28613
|
className() {
|
|
28229
28614
|
return 'FileBrowserFiles';
|
|
28230
28615
|
}
|
|
28231
|
-
}
|
|
28616
|
+
};
|
|
28617
|
+
FileBrowserFiles = __decorate([
|
|
28618
|
+
_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_0__.component
|
|
28619
|
+
], FileBrowserFiles);
|
|
28620
|
+
|
|
28232
28621
|
|
|
28233
28622
|
|
|
28234
28623
|
/***/ }),
|
|
@@ -28260,17 +28649,29 @@ class FileBrowserFiles extends _core_ui_index_js__WEBPACK_IMPORTED_MODULE_0__.UI
|
|
|
28260
28649
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
28261
28650
|
/* harmony export */ FileBrowserTree: function() { return /* binding */ FileBrowserTree; }
|
|
28262
28651
|
/* harmony export */ });
|
|
28263
|
-
/* harmony import */ var
|
|
28652
|
+
/* harmony import */ var _core_decorators_index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(65478);
|
|
28653
|
+
/* harmony import */ var _core_ui_index_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(67510);
|
|
28264
28654
|
/*!
|
|
28265
28655
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
28266
28656
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
28267
28657
|
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net
|
|
28268
|
-
*/
|
|
28269
|
-
|
|
28658
|
+
*/ var __decorate = undefined && undefined.__decorate || function(decorators, target, key, desc) {
|
|
28659
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
28660
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
28661
|
+
else for(var i = decorators.length - 1; i >= 0; i--)if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
28662
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
28663
|
+
};
|
|
28664
|
+
|
|
28665
|
+
|
|
28666
|
+
let FileBrowserTree = class FileBrowserTree extends _core_ui_index_js__WEBPACK_IMPORTED_MODULE_1__.UIGroup {
|
|
28270
28667
|
className() {
|
|
28271
28668
|
return 'FileBrowserTree';
|
|
28272
28669
|
}
|
|
28273
|
-
}
|
|
28670
|
+
};
|
|
28671
|
+
FileBrowserTree = __decorate([
|
|
28672
|
+
_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_0__.component
|
|
28673
|
+
], FileBrowserTree);
|
|
28674
|
+
|
|
28274
28675
|
|
|
28275
28676
|
|
|
28276
28677
|
/***/ }),
|
|
@@ -29948,23 +30349,15 @@ StatusBar = __decorate([
|
|
|
29948
30349
|
/* harmony export */ });
|
|
29949
30350
|
/* harmony import */ var _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(91907);
|
|
29950
30351
|
/* harmony import */ var _core_constants_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(82758);
|
|
29951
|
-
/* harmony import */ var
|
|
29952
|
-
/* harmony import */ var
|
|
29953
|
-
/* harmony import */ var
|
|
29954
|
-
/* harmony import */ var
|
|
29955
|
-
/* harmony import */ var _core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(41180);
|
|
30352
|
+
/* harmony import */ var _core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(22732);
|
|
30353
|
+
/* harmony import */ var _core_global_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(580);
|
|
30354
|
+
/* harmony import */ var _core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(21537);
|
|
30355
|
+
/* harmony import */ var _core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(41180);
|
|
29956
30356
|
/*!
|
|
29957
30357
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
29958
30358
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
29959
30359
|
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net
|
|
29960
|
-
*/
|
|
29961
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
29962
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
29963
|
-
else for(var i = decorators.length - 1; i >= 0; i--)if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
29964
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
29965
|
-
};
|
|
29966
|
-
|
|
29967
|
-
|
|
30360
|
+
*/
|
|
29968
30361
|
|
|
29969
30362
|
|
|
29970
30363
|
|
|
@@ -29975,19 +30368,10 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
29975
30368
|
/** @override */ className() {
|
|
29976
30369
|
return 'Table';
|
|
29977
30370
|
}
|
|
29978
|
-
__recalculateStyles() {
|
|
29979
|
-
const style = (0,_core_global_js__WEBPACK_IMPORTED_MODULE_4__.getContainer)(this.j, Table, 'style', true);
|
|
29980
|
-
const selectors = [];
|
|
29981
|
-
this.selected.forEach((td)=>{
|
|
29982
|
-
const selector = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_5__.cssPath)(td);
|
|
29983
|
-
selector && selectors.push(selector);
|
|
29984
|
-
});
|
|
29985
|
-
style.innerHTML = selectors.length ? selectors.join(',') + `{${this.jodit.options.table.selectionCellStyle}}` : '';
|
|
29986
|
-
}
|
|
29987
30371
|
addSelection(td) {
|
|
29988
30372
|
this.selected.add(td);
|
|
29989
30373
|
this.__recalculateStyles();
|
|
29990
|
-
const table =
|
|
30374
|
+
const table = _core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.closest(td, 'table', this.j.editor);
|
|
29991
30375
|
if (table) {
|
|
29992
30376
|
const cells = Table.__selectedByTable.get(table) || new Set();
|
|
29993
30377
|
cells.add(td);
|
|
@@ -29997,7 +30381,7 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
29997
30381
|
removeSelection(td) {
|
|
29998
30382
|
this.selected.delete(td);
|
|
29999
30383
|
this.__recalculateStyles();
|
|
30000
|
-
const table =
|
|
30384
|
+
const table = _core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.closest(td, 'table', this.j.editor);
|
|
30001
30385
|
if (table) {
|
|
30002
30386
|
const cells = Table.__selectedByTable.get(table);
|
|
30003
30387
|
if (cells) {
|
|
@@ -30011,11 +30395,11 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30011
30395
|
/**
|
|
30012
30396
|
* Returns array of selected cells
|
|
30013
30397
|
*/ getAllSelectedCells() {
|
|
30014
|
-
return (0,
|
|
30398
|
+
return (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.toArray)(this.selected);
|
|
30015
30399
|
}
|
|
30016
30400
|
static __getSelectedCellsByTable(table) {
|
|
30017
30401
|
const cells = Table.__selectedByTable.get(table);
|
|
30018
|
-
return cells ? (0,
|
|
30402
|
+
return cells ? (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.toArray)(cells) : [];
|
|
30019
30403
|
}
|
|
30020
30404
|
/** @override **/ destruct() {
|
|
30021
30405
|
this.selected.clear();
|
|
@@ -30042,7 +30426,7 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30042
30426
|
const matrix = [
|
|
30043
30427
|
[]
|
|
30044
30428
|
];
|
|
30045
|
-
const rows = (0,
|
|
30429
|
+
const rows = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.toArray)(table.rows);
|
|
30046
30430
|
const setCell = (cell, i)=>{
|
|
30047
30431
|
if (matrix[i] === undefined) {
|
|
30048
30432
|
matrix[i] = [];
|
|
@@ -30065,7 +30449,7 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30065
30449
|
}
|
|
30066
30450
|
};
|
|
30067
30451
|
for(let i = 0; i < rows.length; i += 1){
|
|
30068
|
-
const cells = (0,
|
|
30452
|
+
const cells = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.toArray)(rows[i].cells);
|
|
30069
30453
|
for(let j = 0; j < cells.length; j += 1){
|
|
30070
30454
|
if (setCell(cells[j], i) === false) {
|
|
30071
30455
|
return matrix;
|
|
@@ -30115,34 +30499,34 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30115
30499
|
row = create.element('tr');
|
|
30116
30500
|
for(let j = 0; j < columnsCount; j += 1){
|
|
30117
30501
|
const cell = create.element('td');
|
|
30118
|
-
|
|
30119
|
-
|
|
30502
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.append(cell, create.element('br'));
|
|
30503
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.append(row, cell);
|
|
30120
30504
|
}
|
|
30121
30505
|
} else {
|
|
30122
30506
|
row = line.cloneNode(true);
|
|
30123
|
-
|
|
30124
|
-
if (!
|
|
30507
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.each(line, (cell)=>{
|
|
30508
|
+
if (!_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.isCell(cell)) {
|
|
30125
30509
|
return;
|
|
30126
30510
|
}
|
|
30127
|
-
const rowspan = (0,
|
|
30511
|
+
const rowspan = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(cell, 'rowspan');
|
|
30128
30512
|
if (rowspan && parseInt(rowspan, 10) > 1) {
|
|
30129
30513
|
const newRowSpan = parseInt(rowspan, 10) - 1;
|
|
30130
|
-
(0,
|
|
30514
|
+
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(cell, 'rowspan', newRowSpan > 1 ? newRowSpan : null);
|
|
30131
30515
|
}
|
|
30132
30516
|
});
|
|
30133
|
-
|
|
30134
|
-
if (
|
|
30135
|
-
|
|
30136
|
-
|
|
30517
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.each(row, (cell)=>{
|
|
30518
|
+
if (_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.isCell(cell)) {
|
|
30519
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.detach(cell);
|
|
30520
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.append(cell, create.element('br'));
|
|
30137
30521
|
}
|
|
30138
30522
|
});
|
|
30139
30523
|
}
|
|
30140
30524
|
if (after && line && line.nextSibling) {
|
|
30141
|
-
|
|
30525
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.after(line, row);
|
|
30142
30526
|
} else if (!after && line) {
|
|
30143
|
-
|
|
30527
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.before(line, row);
|
|
30144
30528
|
} else {
|
|
30145
|
-
|
|
30529
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.append(_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.first(table, (node)=>_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.isTag(node, 'tbody')) || table, row);
|
|
30146
30530
|
}
|
|
30147
30531
|
}
|
|
30148
30532
|
/**
|
|
@@ -30170,7 +30554,7 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30170
30554
|
while(box[rowIndex + 1][nextCell] === cell){
|
|
30171
30555
|
nextCell += 1;
|
|
30172
30556
|
}
|
|
30173
|
-
const nextRow =
|
|
30557
|
+
const nextRow = _core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.next(cell.parentNode, (elm)=>_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.isTag(elm, 'tr'), table);
|
|
30174
30558
|
if (nextRow) {
|
|
30175
30559
|
// `box[rowIndex + 1][nextCell]` is the cell that
|
|
30176
30560
|
// logically follows the moved cell in the next row, but
|
|
@@ -30187,21 +30571,21 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30187
30571
|
}
|
|
30188
30572
|
}
|
|
30189
30573
|
if (referenceCell) {
|
|
30190
|
-
|
|
30574
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.before(referenceCell, cell);
|
|
30191
30575
|
} else {
|
|
30192
|
-
|
|
30576
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.append(nextRow, cell);
|
|
30193
30577
|
}
|
|
30194
30578
|
}
|
|
30195
30579
|
}
|
|
30196
30580
|
} else {
|
|
30197
|
-
|
|
30581
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.safeRemove(cell);
|
|
30198
30582
|
}
|
|
30199
30583
|
if (dec && (cell.parentNode === row || cell !== box[rowIndex][j - 1])) {
|
|
30200
30584
|
const rowSpan = cell.rowSpan;
|
|
30201
|
-
(0,
|
|
30585
|
+
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(cell, 'rowspan', rowSpan - 1 > 1 ? rowSpan - 1 : null);
|
|
30202
30586
|
}
|
|
30203
30587
|
});
|
|
30204
|
-
|
|
30588
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.safeRemove(row);
|
|
30205
30589
|
}
|
|
30206
30590
|
/**
|
|
30207
30591
|
* Remove row
|
|
@@ -30212,7 +30596,7 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30212
30596
|
* Insert column before / after all the columns containing the selected cells
|
|
30213
30597
|
*/ appendColumn(table, selectedCell, insertAfter = true) {
|
|
30214
30598
|
const box = Table.__formalMatrix(table);
|
|
30215
|
-
if (!insertAfter &&
|
|
30599
|
+
if (!insertAfter && _core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.isCell(selectedCell.previousElementSibling)) {
|
|
30216
30600
|
return this.appendColumn(table, selectedCell.previousElementSibling, true);
|
|
30217
30601
|
}
|
|
30218
30602
|
const [, formalCol] = Table.__formalCoordinate(table, selectedCell, insertAfter);
|
|
@@ -30222,11 +30606,11 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30222
30606
|
const cells = box[i];
|
|
30223
30607
|
if (cells[columnIndex] !== cells[newColumnIndex] || columnIndex === newColumnIndex) {
|
|
30224
30608
|
const cell = this.j.createInside.element('td');
|
|
30225
|
-
|
|
30609
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.append(cell, this.j.createInside.element('br'));
|
|
30226
30610
|
if (insertAfter) {
|
|
30227
|
-
|
|
30611
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.after(cells[columnIndex], cell);
|
|
30228
30612
|
} else {
|
|
30229
|
-
|
|
30613
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.before(cells[columnIndex], cell);
|
|
30230
30614
|
}
|
|
30231
30615
|
if (cells[columnIndex].rowSpan > 1) {
|
|
30232
30616
|
cell.rowSpan = cells[columnIndex].rowSpan;
|
|
@@ -30248,11 +30632,11 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30248
30632
|
} else if (j + 1 < cells.length && box[i][j + 1] === td) {
|
|
30249
30633
|
dec = true;
|
|
30250
30634
|
} else {
|
|
30251
|
-
|
|
30635
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.safeRemove(td);
|
|
30252
30636
|
}
|
|
30253
30637
|
if (dec && (i - 1 < 0 || td !== box[i - 1][j])) {
|
|
30254
30638
|
const colSpan = td.colSpan;
|
|
30255
|
-
(0,
|
|
30639
|
+
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(td, 'colspan', colSpan - 1 > 1 ? (colSpan - 1).toString() : null);
|
|
30256
30640
|
}
|
|
30257
30641
|
});
|
|
30258
30642
|
}
|
|
@@ -30329,13 +30713,13 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30329
30713
|
continue; // broken table
|
|
30330
30714
|
}
|
|
30331
30715
|
if (box[i][j].hasAttribute('rowspan') && box[i][j].rowSpan === 1) {
|
|
30332
|
-
(0,
|
|
30716
|
+
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(box[i][j], 'rowspan', null);
|
|
30333
30717
|
}
|
|
30334
30718
|
if (box[i][j].hasAttribute('colspan') && box[i][j].colSpan === 1) {
|
|
30335
|
-
(0,
|
|
30719
|
+
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(box[i][j], 'colspan', null);
|
|
30336
30720
|
}
|
|
30337
|
-
if (box[i][j].hasAttribute('class') && !(0,
|
|
30338
|
-
(0,
|
|
30721
|
+
if (box[i][j].hasAttribute('class') && !(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(box[i][j], 'class')) {
|
|
30722
|
+
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(box[i][j], 'class', null);
|
|
30339
30723
|
}
|
|
30340
30724
|
}
|
|
30341
30725
|
}
|
|
@@ -30409,10 +30793,10 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30409
30793
|
return;
|
|
30410
30794
|
}
|
|
30411
30795
|
alreadyMerged.add(td);
|
|
30412
|
-
if (i === bound[0][0] && (0,
|
|
30796
|
+
if (i === bound[0][0] && (0,_core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_5__.cssInline)(td, 'width')) {
|
|
30413
30797
|
w += td.offsetWidth;
|
|
30414
30798
|
}
|
|
30415
|
-
if ((0,
|
|
30799
|
+
if ((0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.trim)(cell.innerHTML.replace(/<br(\/)?>/g, '')) !== '') {
|
|
30416
30800
|
html.push(cell.innerHTML);
|
|
30417
30801
|
}
|
|
30418
30802
|
if (cs > 1) {
|
|
@@ -30451,9 +30835,9 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30451
30835
|
alreadyMerged.delete(first);
|
|
30452
30836
|
Table.__unmark(__marked);
|
|
30453
30837
|
Table.__normalizeTable(table);
|
|
30454
|
-
(0,
|
|
30838
|
+
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.toArray)(table.rows).forEach((tr)=>{
|
|
30455
30839
|
if (!tr.cells.length) {
|
|
30456
|
-
|
|
30840
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.safeRemove(tr);
|
|
30457
30841
|
}
|
|
30458
30842
|
});
|
|
30459
30843
|
}
|
|
@@ -30469,7 +30853,7 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30469
30853
|
const __marked = [];
|
|
30470
30854
|
Table.__getSelectedCellsByTable(table).forEach((cell)=>{
|
|
30471
30855
|
td = jodit.createInside.element('td');
|
|
30472
|
-
|
|
30856
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.append(td, jodit.createInside.element('br'));
|
|
30473
30857
|
tr = jodit.createInside.element('tr');
|
|
30474
30858
|
coord = Table.__formalCoordinate(table, cell);
|
|
30475
30859
|
if (cell.rowSpan < 2) {
|
|
@@ -30478,8 +30862,8 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30478
30862
|
Table.__mark(tdElm, 'rowspan', tdElm.rowSpan + 1, __marked);
|
|
30479
30863
|
}
|
|
30480
30864
|
});
|
|
30481
|
-
|
|
30482
|
-
|
|
30865
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.after(_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.closest(cell, 'tr', table), tr);
|
|
30866
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.append(tr, td);
|
|
30483
30867
|
} else {
|
|
30484
30868
|
Table.__mark(cell, 'rowspan', cell.rowSpan - 1, __marked);
|
|
30485
30869
|
Table.__formalMatrix(table, (tdElm, i, j)=>{
|
|
@@ -30491,9 +30875,9 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30491
30875
|
}
|
|
30492
30876
|
});
|
|
30493
30877
|
if (after) {
|
|
30494
|
-
|
|
30878
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.after(after, td);
|
|
30495
30879
|
} else {
|
|
30496
|
-
|
|
30880
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.prepend(parent, td);
|
|
30497
30881
|
}
|
|
30498
30882
|
}
|
|
30499
30883
|
if (cell.colSpan > 1) {
|
|
@@ -30524,12 +30908,12 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30524
30908
|
Table.__mark(cell, 'colspan', cell.colSpan - 1, __marked);
|
|
30525
30909
|
}
|
|
30526
30910
|
td = jodit.createInside.element('td');
|
|
30527
|
-
|
|
30911
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.append(td, jodit.createInside.element('br'));
|
|
30528
30912
|
if (cell.rowSpan > 1) {
|
|
30529
30913
|
Table.__mark(td, 'rowspan', cell.rowSpan, __marked);
|
|
30530
30914
|
}
|
|
30531
30915
|
const oldWidth = cell.offsetWidth; // get old width
|
|
30532
|
-
|
|
30916
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.after(cell, td);
|
|
30533
30917
|
percentage = oldWidth / table.offsetWidth / 2;
|
|
30534
30918
|
Table.__mark(cell, 'width', (percentage * 100).toFixed(_core_constants_js__WEBPACK_IMPORTED_MODULE_1__.ACCURACY) + '%', __marked);
|
|
30535
30919
|
Table.__mark(td, 'width', (percentage * 100).toFixed(_core_constants_js__WEBPACK_IMPORTED_MODULE_1__.ACCURACY) + '%', __marked);
|
|
@@ -30585,22 +30969,22 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30585
30969
|
const value = dict[key];
|
|
30586
30970
|
switch(key){
|
|
30587
30971
|
case 'remove':
|
|
30588
|
-
|
|
30972
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_2__.Dom.safeRemove(cell);
|
|
30589
30973
|
break;
|
|
30590
30974
|
case 'rowspan':
|
|
30591
|
-
(0,
|
|
30975
|
+
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(cell, 'rowspan', (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.isNumber)(value) && value > 1 ? value : null);
|
|
30592
30976
|
break;
|
|
30593
30977
|
case 'colspan':
|
|
30594
|
-
(0,
|
|
30978
|
+
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(cell, 'colspan', (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.isNumber)(value) && value > 1 ? value : null);
|
|
30595
30979
|
break;
|
|
30596
30980
|
case 'width':
|
|
30597
30981
|
if (value == null) {
|
|
30598
30982
|
cell.style.removeProperty('width');
|
|
30599
|
-
if (!(0,
|
|
30600
|
-
(0,
|
|
30983
|
+
if (!(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(cell, 'style')) {
|
|
30984
|
+
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.attr)(cell, 'style', null);
|
|
30601
30985
|
}
|
|
30602
30986
|
} else {
|
|
30603
|
-
(0,
|
|
30987
|
+
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.css)(cell, 'width', value.toString());
|
|
30604
30988
|
}
|
|
30605
30989
|
break;
|
|
30606
30990
|
}
|
|
@@ -30613,12 +30997,23 @@ class Table extends _core_component_index_js__WEBPACK_IMPORTED_MODULE_0__.ViewCo
|
|
|
30613
30997
|
constructor(){
|
|
30614
30998
|
super(...arguments);
|
|
30615
30999
|
this.selected = new Set();
|
|
31000
|
+
/**
|
|
31001
|
+
* Rewrite the `<style>` that marks the selected cells once for all the
|
|
31002
|
+
* cells (un)selected in one go: a drag over a block of cells unmarks and
|
|
31003
|
+
* marks every one of them on each move. `@debounce()` was never applied,
|
|
31004
|
+
* as a Table never reaches `ready`
|
|
31005
|
+
*/ this.__recalculateStyles = this.async.microDebounce(()=>{
|
|
31006
|
+
const style = (0,_core_global_js__WEBPACK_IMPORTED_MODULE_3__.getContainer)(this.j, Table, 'style', true);
|
|
31007
|
+
const selectors = [];
|
|
31008
|
+
this.selected.forEach((td)=>{
|
|
31009
|
+
const selector = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.cssPath)(td);
|
|
31010
|
+
selector && selectors.push(selector);
|
|
31011
|
+
});
|
|
31012
|
+
style.innerHTML = selectors.length ? selectors.join(',') + `{${this.jodit.options.table.selectionCellStyle}}` : '';
|
|
31013
|
+
});
|
|
30616
31014
|
}
|
|
30617
31015
|
}
|
|
30618
31016
|
Table.__selectedByTable = new WeakMap();
|
|
30619
|
-
__decorate([
|
|
30620
|
-
(0,_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_2__.debounce)()
|
|
30621
|
-
], Table.prototype, "__recalculateStyles", null);
|
|
30622
31017
|
const instance = (j)=>j.getInstance('Table', j.o);
|
|
30623
31018
|
|
|
30624
31019
|
|
|
@@ -33961,6 +34356,10 @@ _core_global_js__WEBPACK_IMPORTED_MODULE_2__.pluginSystem.add('backspace', backs
|
|
|
33961
34356
|
mainClosestBox = nextBox;
|
|
33962
34357
|
}
|
|
33963
34358
|
if (_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(mainClosestBox) && _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isContentEditable(mainClosestBox, jodit.editor)) {
|
|
34359
|
+
// A table cell is never joined with its neighbour
|
|
34360
|
+
if (_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.up(fakeNode, _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isCell, mainClosestBox, true)) {
|
|
34361
|
+
return false;
|
|
34362
|
+
}
|
|
33964
34363
|
const sibling = _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.findNotEmptySibling(mainClosestBox, backspace);
|
|
33965
34364
|
// A line break before the cursor is a single unit: remove it instead of
|
|
33966
34365
|
// merging the current element into the (void) `<br>`, which used to move
|
|
@@ -33970,13 +34369,48 @@ _core_global_js__WEBPACK_IMPORTED_MODULE_2__.pluginSystem.add('backspace', backs
|
|
|
33970
34369
|
jodit.s.setCursorBefore(fakeNode);
|
|
33971
34370
|
return true;
|
|
33972
34371
|
}
|
|
33973
|
-
|
|
34372
|
+
// Backspace leaves a block after a table alone, as Word does, rather
|
|
34373
|
+
// than moving its text into the last cell
|
|
34374
|
+
if (backspace && _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(sibling, 'table')) {
|
|
34375
|
+
jodit.s.setCursorBefore(fakeNode);
|
|
34376
|
+
return true;
|
|
34377
|
+
}
|
|
34378
|
+
const box = findCaretBox(fakeNode, mainClosestBox);
|
|
34379
|
+
if (sibling && (checkPullNextLine(jodit, fakeNode, box, sibling, backspace) || checkMoveListContent(jodit, box, sibling, backspace) || moveContentAndRemoveEmpty(jodit, box, findEdgeBlock(resolveTableSibling(sibling, backspace), backspace, jodit.editor), backspace))) {
|
|
33974
34380
|
jodit.s.setCursorBefore(fakeNode);
|
|
33975
34381
|
return true;
|
|
33976
34382
|
}
|
|
33977
34383
|
}
|
|
33978
34384
|
return false;
|
|
33979
34385
|
}
|
|
34386
|
+
/**
|
|
34387
|
+
* The block holding the caret inside the box that has the sibling, so
|
|
34388
|
+
* `<p>one</p><div><p>|two</p></div>` joins the two paragraphs instead of
|
|
34389
|
+
* moving the whole `<div>` into the first one. For a list item that is its
|
|
34390
|
+
* list, which the list cases handle.
|
|
34391
|
+
*/ function findCaretBox(fakeNode, mainClosestBox) {
|
|
34392
|
+
const block = _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.up(fakeNode, _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isBlock, mainClosestBox);
|
|
34393
|
+
if (!block) {
|
|
34394
|
+
return mainClosestBox;
|
|
34395
|
+
}
|
|
34396
|
+
return _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isLeaf(block) && block.parentElement ? block.parentElement : block;
|
|
34397
|
+
}
|
|
34398
|
+
/**
|
|
34399
|
+
* The innermost block on the sibling's edge facing the caret, so the
|
|
34400
|
+
* content is joined to text: `<div><p>one</p></div><p>|two</p>` gives
|
|
34401
|
+
* `<div><p>one|two</p></div>`
|
|
34402
|
+
*/ function findEdgeBlock(sibling, backspace, root) {
|
|
34403
|
+
let block = sibling;
|
|
34404
|
+
while(block){
|
|
34405
|
+
const edge = backspace ? block.lastChild : block.firstChild;
|
|
34406
|
+
const child = edge && _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isEmptyTextNode(edge) ? _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.findNotEmptySibling(edge, backspace) : edge;
|
|
34407
|
+
if (!_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isBlock(child) || _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(child, _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.INSEPARABLE_TAGS) || _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(child, 'table') || !_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isContentEditable(child, root)) {
|
|
34408
|
+
return block;
|
|
34409
|
+
}
|
|
34410
|
+
block = child;
|
|
34411
|
+
}
|
|
34412
|
+
return block;
|
|
34413
|
+
}
|
|
33980
34414
|
/**
|
|
33981
34415
|
* Content cannot be merged into the `<table>` element itself — it would land
|
|
33982
34416
|
* between the table sections (after `</tbody>`), which is invalid HTML and
|
|
@@ -33993,6 +34427,40 @@ _core_global_js__WEBPACK_IMPORTED_MODULE_2__.pluginSystem.add('backspace', backs
|
|
|
33993
34427
|
});
|
|
33994
34428
|
return cells.length ? cells[backspace ? cells.length - 1 : 0] : null;
|
|
33995
34429
|
}
|
|
34430
|
+
/**
|
|
34431
|
+
* Delete at the edge of a list pulls the next line up to the caret, as the
|
|
34432
|
+
* browsers do, instead of moving the caret's line into the next block:
|
|
34433
|
+
* `<ul><li>one|</li></ul><p>two</p>` gives `<ul><li>one|two</li></ul>`, and
|
|
34434
|
+
* `<p>one|</p><ul><li>two</li></ul>` gives `<p>one|two</p>`
|
|
34435
|
+
* @private
|
|
34436
|
+
*/ function checkPullNextLine(jodit, fakeNode, box, sibling, backspace) {
|
|
34437
|
+
if (backspace || !(_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isList(box) || _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isList(sibling))) {
|
|
34438
|
+
return false;
|
|
34439
|
+
}
|
|
34440
|
+
const target = _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.up(fakeNode, _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isBlock, box, true);
|
|
34441
|
+
const source = _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isList(sibling) ? sibling.firstElementChild : sibling;
|
|
34442
|
+
if (!target || !source || _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(source, _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.INSEPARABLE_TAGS) || _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(source, 'table')) {
|
|
34443
|
+
return false;
|
|
34444
|
+
}
|
|
34445
|
+
if (!_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isEmpty(source)) {
|
|
34446
|
+
const line = [];
|
|
34447
|
+
for(let node = source.firstChild; node && !_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isBlock(node); node = node.nextSibling){
|
|
34448
|
+
line.push(node);
|
|
34449
|
+
}
|
|
34450
|
+
if (!line.length) {
|
|
34451
|
+
return false;
|
|
34452
|
+
}
|
|
34453
|
+
const filter = (0,_helpers_js__WEBPACK_IMPORTED_MODULE_2__.getMoveFilter)(jodit);
|
|
34454
|
+
line.forEach((node)=>filter(node) ? _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.append(target, node) : _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(node));
|
|
34455
|
+
}
|
|
34456
|
+
let remove = source;
|
|
34457
|
+
while(remove && remove !== jodit.editor && _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isEmpty(remove)){
|
|
34458
|
+
const parent = remove.parentElement;
|
|
34459
|
+
_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(remove);
|
|
34460
|
+
remove = parent;
|
|
34461
|
+
}
|
|
34462
|
+
return true;
|
|
34463
|
+
}
|
|
33996
34464
|
function checkMoveListContent(jodit, mainClosestBox, sibling, backspace) {
|
|
33997
34465
|
// Process UL/LI/OL cases
|
|
33998
34466
|
const siblingIsList = _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(sibling, _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.LIST_TAGS);
|
|
@@ -34134,9 +34602,10 @@ function moveContentAndRemoveEmpty(jodit, mainClosestBox, sibling, backspace) {
|
|
|
34134
34602
|
* ```html
|
|
34135
34603
|
* t|st
|
|
34136
34604
|
* ```
|
|
34605
|
+
* With `stopBeforeSpace`, nothing is removed when the next char is a space.
|
|
34137
34606
|
* @private
|
|
34138
34607
|
*/ // eslint-disable-next-line complexity
|
|
34139
|
-
function checkRemoveChar(jodit, fakeNode, backspace, mode) {
|
|
34608
|
+
function checkRemoveChar(jodit, fakeNode, backspace, mode, stopBeforeSpace = false) {
|
|
34140
34609
|
var _a, _b;
|
|
34141
34610
|
const step = backspace ? -1 : 1;
|
|
34142
34611
|
const anotherSibling = _core_dom_index_js__WEBPACK_IMPORTED_MODULE_1__.Dom.sibling(fakeNode, !backspace);
|
|
@@ -34155,6 +34624,9 @@ function checkRemoveChar(jodit, fakeNode, backspace, mode) {
|
|
|
34155
34624
|
break;
|
|
34156
34625
|
}
|
|
34157
34626
|
if ((_a = sibling.nodeValue) === null || _a === void 0 ? void 0 : _a.length) {
|
|
34627
|
+
if (stopBeforeSpace && isSpace(nextChar(sibling.nodeValue, backspace))) {
|
|
34628
|
+
break;
|
|
34629
|
+
}
|
|
34158
34630
|
removed = tryRemoveChar(sibling, backspace, step, anotherSibling);
|
|
34159
34631
|
if (!sibling.nodeValue.length && _core_dom_index_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isInlineBlock(sibling.parentNode)) {
|
|
34160
34632
|
sibling.nodeValue = _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE;
|
|
@@ -34262,9 +34734,25 @@ function replaceSpaceOnNBSP(anotherSibling, backspace, value) {
|
|
|
34262
34734
|
}
|
|
34263
34735
|
function checkRepeatRemoveCharAction(backspace, sibling, fakeNode, mode, removed, jodit) {
|
|
34264
34736
|
;(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_2__.call)(backspace ? _core_dom_index_js__WEBPACK_IMPORTED_MODULE_1__.Dom.after : _core_dom_index_js__WEBPACK_IMPORTED_MODULE_1__.Dom.before, sibling, fakeNode);
|
|
34265
|
-
|
|
34266
|
-
|
|
34737
|
+
const wordChar = mode === 'word' && !isSpace(removed);
|
|
34738
|
+
// Backspace by word removes the spaces before the caret, then the word, and keeps the space in front of it
|
|
34739
|
+
if (mode === 'sentence' || wordChar || mode === 'word' && backspace) {
|
|
34740
|
+
checkRemoveChar(jodit, fakeNode, backspace, mode, wordChar && backspace);
|
|
34741
|
+
}
|
|
34742
|
+
}
|
|
34743
|
+
/**
|
|
34744
|
+
* The char tryRemoveChar would remove next
|
|
34745
|
+
*/ function nextChar(value, backspace) {
|
|
34746
|
+
const chars = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_2__.toArray)(value);
|
|
34747
|
+
const step = backspace ? -1 : 1;
|
|
34748
|
+
let index = backspace ? chars.length - 1 : 0;
|
|
34749
|
+
while(chars[index] === _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.INVISIBLE_SPACE){
|
|
34750
|
+
index += step;
|
|
34267
34751
|
}
|
|
34752
|
+
return chars[index];
|
|
34753
|
+
}
|
|
34754
|
+
function isSpace(char) {
|
|
34755
|
+
return char === ' ' || char === _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.NBSP_SPACE;
|
|
34268
34756
|
}
|
|
34269
34757
|
|
|
34270
34758
|
|
|
@@ -34627,7 +35115,8 @@ function checkRepeatRemoveCharAction(backspace, sibling, fakeNode, mode, removed
|
|
|
34627
35115
|
/***/ 32496:
|
|
34628
35116
|
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) {
|
|
34629
35117
|
|
|
34630
|
-
/* harmony import */ var
|
|
35118
|
+
/* harmony import */ var _core_constants_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(82758);
|
|
35119
|
+
/* harmony import */ var _config_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6441);
|
|
34631
35120
|
/*!
|
|
34632
35121
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
34633
35122
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -34635,13 +35124,18 @@ function checkRepeatRemoveCharAction(backspace, sibling, fakeNode, mode, removed
|
|
|
34635
35124
|
*/ /**
|
|
34636
35125
|
* @module plugins/backspace
|
|
34637
35126
|
*/
|
|
34638
|
-
|
|
35127
|
+
|
|
35128
|
+
_config_js__WEBPACK_IMPORTED_MODULE_1__.Config.prototype.delete = {
|
|
34639
35129
|
hotkeys: {
|
|
34640
|
-
delete: [
|
|
35130
|
+
delete: _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.IS_MAC ? [
|
|
35131
|
+
'delete'
|
|
35132
|
+
] : [
|
|
34641
35133
|
'delete',
|
|
34642
35134
|
'cmd+backspace'
|
|
34643
35135
|
],
|
|
34644
|
-
deleteWord: [
|
|
35136
|
+
deleteWord: _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.IS_MAC ? [
|
|
35137
|
+
'ctrl+delete'
|
|
35138
|
+
] : [
|
|
34645
35139
|
'ctrl+delete',
|
|
34646
35140
|
'cmd+alt+backspace',
|
|
34647
35141
|
'ctrl+alt+backspace'
|
|
@@ -34653,7 +35147,7 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.delete = {
|
|
|
34653
35147
|
backspace: [
|
|
34654
35148
|
'backspace'
|
|
34655
35149
|
],
|
|
34656
|
-
backspaceWord: [
|
|
35150
|
+
backspaceWord: _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.IS_MAC ? [] : [
|
|
34657
35151
|
'ctrl+backspace'
|
|
34658
35152
|
],
|
|
34659
35153
|
backspaceSentence: [
|
|
@@ -35098,6 +35592,19 @@ class cleanHtml extends _core_plugin_plugin_js__WEBPACK_IMPORTED_MODULE_5__.Plug
|
|
|
35098
35592
|
this.walker.setWork(editor.editor);
|
|
35099
35593
|
this.currentSelectionNode = editor.s.current();
|
|
35100
35594
|
}
|
|
35595
|
+
/**
|
|
35596
|
+
* Typing into an empty block (`<p><br></p>`) replaces its `<br>`, but the
|
|
35597
|
+
* browser keeps the `<br>` when the caret is in an invisible-space text
|
|
35598
|
+
* node in front of it, as Jodit leaves the caret in many of the empty
|
|
35599
|
+
* blocks it makes (a cleared editor, a heading in an empty table cell).
|
|
35600
|
+
* See #1632
|
|
35601
|
+
*/ onInputRemovePlaceholderBr(event) {
|
|
35602
|
+
var _a;
|
|
35603
|
+
if (!this.isEditMode || event.type === 'input' && (event.isComposing || !((_a = event.inputType) === null || _a === void 0 ? void 0 : _a.startsWith('insert')))) {
|
|
35604
|
+
return;
|
|
35605
|
+
}
|
|
35606
|
+
;(0,_helpers_index_js__WEBPACK_IMPORTED_MODULE_8__.removePlaceholderBr)(this.j);
|
|
35607
|
+
}
|
|
35101
35608
|
startWalker() {
|
|
35102
35609
|
const { jodit } = this;
|
|
35103
35610
|
const allow = (0,_helpers_index_js__WEBPACK_IMPORTED_MODULE_8__.getHash)(this.j.o.cleanHTML.allowTags);
|
|
@@ -35270,6 +35777,12 @@ __decorate([
|
|
|
35270
35777
|
':keydown'
|
|
35271
35778
|
])
|
|
35272
35779
|
], cleanHtml.prototype, "onChangeCleanHTML", null);
|
|
35780
|
+
__decorate([
|
|
35781
|
+
(0,_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_0__.watch)([
|
|
35782
|
+
':input',
|
|
35783
|
+
'jodit.editor:compositionend'
|
|
35784
|
+
])
|
|
35785
|
+
], cleanHtml.prototype, "onInputRemovePlaceholderBr", null);
|
|
35273
35786
|
__decorate([
|
|
35274
35787
|
(0,_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_0__.hook)('ready')
|
|
35275
35788
|
], cleanHtml.prototype, "startWalker", null);
|
|
@@ -35401,12 +35914,14 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.controls.eraser = {
|
|
|
35401
35914
|
/* harmony export */ getHash: function() { return /* reexport safe */ _get_hash_js__WEBPACK_IMPORTED_MODULE_0__.getHash; },
|
|
35402
35915
|
/* harmony export */ removeFormatForCollapsedSelection: function() { return /* reexport safe */ _remove_format_remove_format_for_collapsed_selection_js__WEBPACK_IMPORTED_MODULE_1__.removeFormatForCollapsedSelection; },
|
|
35403
35916
|
/* harmony export */ removeFormatForSelection: function() { return /* reexport safe */ _remove_format_remove_format_for_selection_js__WEBPACK_IMPORTED_MODULE_2__.removeFormatForSelection; },
|
|
35404
|
-
/* harmony export */
|
|
35917
|
+
/* harmony export */ removePlaceholderBr: function() { return /* reexport safe */ _remove_placeholder_br_js__WEBPACK_IMPORTED_MODULE_3__.removePlaceholderBr; },
|
|
35918
|
+
/* harmony export */ visitNodeWalker: function() { return /* reexport safe */ _visitor_visit_node_walker_js__WEBPACK_IMPORTED_MODULE_4__.visitNodeWalker; }
|
|
35405
35919
|
/* harmony export */ });
|
|
35406
35920
|
/* harmony import */ var _get_hash_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(83447);
|
|
35407
35921
|
/* harmony import */ var _remove_format_remove_format_for_collapsed_selection_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(84272);
|
|
35408
35922
|
/* harmony import */ var _remove_format_remove_format_for_selection_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(42312);
|
|
35409
|
-
/* harmony import */ var
|
|
35923
|
+
/* harmony import */ var _remove_placeholder_br_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(56385);
|
|
35924
|
+
/* harmony import */ var _visitor_visit_node_walker_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(39516);
|
|
35410
35925
|
/*!
|
|
35411
35926
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
35412
35927
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -35420,6 +35935,7 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.controls.eraser = {
|
|
|
35420
35935
|
|
|
35421
35936
|
|
|
35422
35937
|
|
|
35938
|
+
|
|
35423
35939
|
/***/ }),
|
|
35424
35940
|
|
|
35425
35941
|
/***/ 15908:
|
|
@@ -35572,6 +36088,62 @@ const VIMEO_EMBED = /^(https?:)?\/\/player\.vimeo\.com\/video\//i;
|
|
|
35572
36088
|
}
|
|
35573
36089
|
|
|
35574
36090
|
|
|
36091
|
+
/***/ }),
|
|
36092
|
+
|
|
36093
|
+
/***/ 56385:
|
|
36094
|
+
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
36095
|
+
|
|
36096
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
36097
|
+
/* harmony export */ removePlaceholderBr: function() { return /* binding */ removePlaceholderBr; }
|
|
36098
|
+
/* harmony export */ });
|
|
36099
|
+
/* harmony import */ var _core_constants_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(82758);
|
|
36100
|
+
/* harmony import */ var _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2748);
|
|
36101
|
+
/* harmony import */ var _core_helpers_string_trim_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(49055);
|
|
36102
|
+
/*!
|
|
36103
|
+
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
36104
|
+
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
36105
|
+
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net
|
|
36106
|
+
*/
|
|
36107
|
+
|
|
36108
|
+
|
|
36109
|
+
function lastNode(node) {
|
|
36110
|
+
let last = node.lastChild;
|
|
36111
|
+
while(_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isText(last) && !last.nodeValue){
|
|
36112
|
+
last = last.previousSibling;
|
|
36113
|
+
}
|
|
36114
|
+
return last;
|
|
36115
|
+
}
|
|
36116
|
+
/**
|
|
36117
|
+
* Remove the `<br>` that kept the block with the caret open while it was
|
|
36118
|
+
* empty, once text has gone into the block: when the block is one line of
|
|
36119
|
+
* text that ends in that `<br>`, the `<br>` adds nothing to it
|
|
36120
|
+
* @private
|
|
36121
|
+
*/ function removePlaceholderBr(jodit) {
|
|
36122
|
+
var _a;
|
|
36123
|
+
const block = _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.closest(jodit.s.current(), _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isBlock, jodit.editor);
|
|
36124
|
+
if (!block || !(0,_core_helpers_string_trim_js__WEBPACK_IMPORTED_MODULE_2__.trim)((_a = block.textContent) !== null && _a !== void 0 ? _a : '')) {
|
|
36125
|
+
return;
|
|
36126
|
+
}
|
|
36127
|
+
let br = lastNode(block);
|
|
36128
|
+
while(_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(br) && !_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(br, _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.INSEPARABLE_TAGS) && !_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isBlock(br)){
|
|
36129
|
+
br = lastNode(br);
|
|
36130
|
+
}
|
|
36131
|
+
if (!_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(br, 'br')) {
|
|
36132
|
+
return;
|
|
36133
|
+
}
|
|
36134
|
+
// Another line break, a block, an image or an embed means the `<br>` may
|
|
36135
|
+
// end an empty line, or give the caret a place after the embed
|
|
36136
|
+
const isOneLineOfText = _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.each(block, (node)=>{
|
|
36137
|
+
if (node !== br && _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isElement(node) && (_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(node, _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.INSEPARABLE_TAGS) || _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isBlock(node) || _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isHTMLElement(node) && !node.isContentEditable)) {
|
|
36138
|
+
return false;
|
|
36139
|
+
}
|
|
36140
|
+
});
|
|
36141
|
+
if (isOneLineOfText) {
|
|
36142
|
+
_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.safeRemove(br);
|
|
36143
|
+
}
|
|
36144
|
+
}
|
|
36145
|
+
|
|
36146
|
+
|
|
35575
36147
|
/***/ }),
|
|
35576
36148
|
|
|
35577
36149
|
/***/ 82558:
|
|
@@ -36879,6 +37451,11 @@ class deleteCommand extends _core_plugin_index_js__WEBPACK_IMPORTED_MODULE_4__.P
|
|
|
36879
37451
|
}
|
|
36880
37452
|
jodit.s.expandSelection();
|
|
36881
37453
|
const range = jodit.s.range;
|
|
37454
|
+
const caret = this.__clearSelectedCells(range);
|
|
37455
|
+
if (caret && range.collapsed) {
|
|
37456
|
+
jodit.s.selectRange(caret);
|
|
37457
|
+
return false;
|
|
37458
|
+
}
|
|
36882
37459
|
range.deleteContents();
|
|
36883
37460
|
const fake = jodit.createInside.fake();
|
|
36884
37461
|
range.insertNode(fake);
|
|
@@ -36888,21 +37465,98 @@ class deleteCommand extends _core_plugin_index_js__WEBPACK_IMPORTED_MODULE_4__.P
|
|
|
36888
37465
|
range.setStartBefore(fake);
|
|
36889
37466
|
range.collapse(true);
|
|
36890
37467
|
this.__moveCursorInEditableSibling(jodit, leftSibling, fake, range);
|
|
36891
|
-
this.__addBrInEmptyBlock(fake,
|
|
37468
|
+
this.__addBrInEmptyBlock(fake, range);
|
|
36892
37469
|
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(fake);
|
|
36893
|
-
jodit.s.selectRange(range);
|
|
37470
|
+
jodit.s.selectRange(caret !== null && caret !== void 0 ? caret : range);
|
|
36894
37471
|
return false;
|
|
36895
37472
|
}
|
|
37473
|
+
/**
|
|
37474
|
+
* A selection that starts or ends in a table cell clears the selected part
|
|
37475
|
+
* of each cell it covers and keeps the cells, as the browsers do.
|
|
37476
|
+
* `deleteContents` would remove the cells it fully covers, and the cells
|
|
37477
|
+
* it cuts would then be merged as blocks. The range is moved out of those
|
|
37478
|
+
* tables, so only the content between them is left to delete.
|
|
37479
|
+
*
|
|
37480
|
+
* Returns where the caret goes, or null when no table is involved
|
|
37481
|
+
*/ __clearSelectedCells(range) {
|
|
37482
|
+
const { editor, createInside } = this.j;
|
|
37483
|
+
const startCell = _core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(range.startContainer, _core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isCell, editor);
|
|
37484
|
+
const endCell = _core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(range.endContainer, _core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isCell, editor);
|
|
37485
|
+
if (startCell === endCell) {
|
|
37486
|
+
return null;
|
|
37487
|
+
}
|
|
37488
|
+
const startTable = _core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(startCell, 'table', editor);
|
|
37489
|
+
const endTable = _core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(endCell, 'table', editor);
|
|
37490
|
+
const caret = range.cloneRange();
|
|
37491
|
+
caret.collapse(true);
|
|
37492
|
+
const parts = [];
|
|
37493
|
+
const addParts = (table)=>{
|
|
37494
|
+
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_2__.toArray)(table.rows).flatMap((row)=>(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_2__.toArray)(row.cells)).filter((cell)=>range.intersectsNode(cell)).forEach((cell)=>{
|
|
37495
|
+
const part = range.cloneRange();
|
|
37496
|
+
if (!_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isOrContains(cell, range.startContainer)) {
|
|
37497
|
+
part.setStart(cell, 0);
|
|
37498
|
+
}
|
|
37499
|
+
if (!_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isOrContains(cell, range.endContainer)) {
|
|
37500
|
+
part.setEnd(cell, cell.childNodes.length);
|
|
37501
|
+
}
|
|
37502
|
+
parts.push([
|
|
37503
|
+
cell,
|
|
37504
|
+
part
|
|
37505
|
+
]);
|
|
37506
|
+
});
|
|
37507
|
+
};
|
|
37508
|
+
if (startTable) {
|
|
37509
|
+
addParts(startTable);
|
|
37510
|
+
if (startTable === endTable) {
|
|
37511
|
+
range.collapse(true);
|
|
37512
|
+
} else {
|
|
37513
|
+
range.setStartAfter(startTable);
|
|
37514
|
+
}
|
|
37515
|
+
}
|
|
37516
|
+
if (endTable && endTable !== startTable) {
|
|
37517
|
+
addParts(endTable);
|
|
37518
|
+
range.setEndBefore(endTable);
|
|
37519
|
+
}
|
|
37520
|
+
parts.forEach(([cell, part])=>{
|
|
37521
|
+
part.deleteContents();
|
|
37522
|
+
if (_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isEmpty(cell)) {
|
|
37523
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.detach(cell);
|
|
37524
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.append(cell, createInside.element('br'));
|
|
37525
|
+
}
|
|
37526
|
+
});
|
|
37527
|
+
return startTable ? caret : null;
|
|
37528
|
+
}
|
|
36896
37529
|
__moveContentInLeftSibling(fake, leftSibling, rightSibling) {
|
|
36897
37530
|
leftSibling = this.__defineRightLeftBox(leftSibling);
|
|
37531
|
+
// Nothing is moved into a table, and a block left empty after it goes
|
|
37532
|
+
if (_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(leftSibling, 'table')) {
|
|
37533
|
+
if (_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock(rightSibling) && _core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isEmpty(rightSibling)) {
|
|
37534
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(rightSibling);
|
|
37535
|
+
}
|
|
37536
|
+
return;
|
|
37537
|
+
}
|
|
36898
37538
|
if (!_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isList(rightSibling) && !_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(rightSibling, 'table') && _core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock(rightSibling) && _core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock(leftSibling)) {
|
|
36899
37539
|
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.append(leftSibling, fake);
|
|
36900
37540
|
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.moveContent(rightSibling, leftSibling);
|
|
36901
37541
|
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(rightSibling);
|
|
36902
37542
|
}
|
|
36903
|
-
|
|
36904
|
-
|
|
36905
|
-
|
|
37543
|
+
if (_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isList(rightSibling) && _core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isLeaf(rightSibling.firstElementChild)) {
|
|
37544
|
+
const item = rightSibling.firstElementChild;
|
|
37545
|
+
// What's left of the right list's first item joins the left block,
|
|
37546
|
+
// up to a list nested in the item
|
|
37547
|
+
if (!_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isEmpty(item) && _core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock(leftSibling)) {
|
|
37548
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.append(leftSibling, fake);
|
|
37549
|
+
while(item.firstChild && !_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock(item.firstChild)){
|
|
37550
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.append(leftSibling, item.firstChild);
|
|
37551
|
+
}
|
|
37552
|
+
}
|
|
37553
|
+
// Remove empty right LI
|
|
37554
|
+
if (_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isEmpty(item)) {
|
|
37555
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(item);
|
|
37556
|
+
}
|
|
37557
|
+
if (_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isEmpty(rightSibling)) {
|
|
37558
|
+
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.safeRemove(rightSibling);
|
|
37559
|
+
}
|
|
36906
37560
|
}
|
|
36907
37561
|
}
|
|
36908
37562
|
/**
|
|
@@ -36919,8 +37573,8 @@ class deleteCommand extends _core_plugin_index_js__WEBPACK_IMPORTED_MODULE_4__.P
|
|
|
36919
37573
|
return lastLeaf;
|
|
36920
37574
|
}
|
|
36921
37575
|
/**
|
|
36922
|
-
* Add BR in empty
|
|
36923
|
-
*/ __addBrInEmptyBlock(fake,
|
|
37576
|
+
* Add BR in the empty block left at the caret
|
|
37577
|
+
*/ __addBrInEmptyBlock(fake, range) {
|
|
36924
37578
|
const jodit = this.j;
|
|
36925
37579
|
if (fake.isConnected && _core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isBlock(fake.parentNode) && !fake.nextSibling && !fake.previousSibling) {
|
|
36926
37580
|
const br = jodit.createInside.element('br');
|
|
@@ -36928,13 +37582,6 @@ class deleteCommand extends _core_plugin_index_js__WEBPACK_IMPORTED_MODULE_4__.P
|
|
|
36928
37582
|
range.setStartBefore(br);
|
|
36929
37583
|
range.collapse(true);
|
|
36930
37584
|
}
|
|
36931
|
-
// Add BR in the right empty table cell
|
|
36932
|
-
if (_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isTag(rightSibling, 'table')) {
|
|
36933
|
-
const firstCell = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_2__.$$)('td,th', rightSibling).shift();
|
|
36934
|
-
if (_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isCell(firstCell) && _core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.isEmpty(firstCell)) {
|
|
36935
|
-
_core_dom_index_js__WEBPACK_IMPORTED_MODULE_0__.Dom.append(firstCell, jodit.createInside.element('br'));
|
|
36936
|
-
}
|
|
36937
|
-
}
|
|
36938
37585
|
}
|
|
36939
37586
|
__moveCursorInEditableSibling(jodit, leftSibling, fake, range) {
|
|
36940
37587
|
var _a;
|
|
@@ -38382,7 +39029,18 @@ function focus(editor) {
|
|
|
38382
39029
|
editor.e.on('afterInit', ()=>{
|
|
38383
39030
|
if (editor.o.autofocus) {
|
|
38384
39031
|
if (editor.defaultTimeout) {
|
|
38385
|
-
editor
|
|
39032
|
+
// A click or key in the editor during the delay has put the
|
|
39033
|
+
// caret where the user wants it, so autofocus leaves it there
|
|
39034
|
+
const userInput = 'mousedown touchstart keydown';
|
|
39035
|
+
const cancel = ()=>{
|
|
39036
|
+
editor.async.clearTimeout(timeout);
|
|
39037
|
+
editor.e.off(userInput, cancel);
|
|
39038
|
+
};
|
|
39039
|
+
const timeout = editor.async.setTimeout(()=>{
|
|
39040
|
+
editor.e.off(userInput, cancel);
|
|
39041
|
+
focus();
|
|
39042
|
+
}, 300);
|
|
39043
|
+
editor.e.on(userInput, cancel);
|
|
38386
39044
|
} else {
|
|
38387
39045
|
focus();
|
|
38388
39046
|
}
|
|
@@ -39629,7 +40287,7 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.iframeBaseUrl = '';
|
|
|
39629
40287
|
_config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.iframeTitle = 'Jodit Editor';
|
|
39630
40288
|
_config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.iframeDoctype = '<!DOCTYPE html>';
|
|
39631
40289
|
_config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.iframeDefaultSrc = 'about:blank';
|
|
39632
|
-
_config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.iframeStyle = 'html{' + 'margin:0;' + 'padding:0;' + 'min-height: 100%;' + '}' + 'body{' + 'box-sizing:border-box;' + 'font-size:13px;' + 'line-height:1.6;' + 'padding:10px;' + 'margin:0;' + 'background:transparent;' + 'color:#000;' + 'position:' + 'relative;' + 'z-index:2;' + 'user-select:auto;' + 'margin:0px;' + 'overflow:auto;' + 'outline:none;' + '}' + 'table{' + 'width:100%;' + 'border:none;' + 'border-collapse:collapse;' + 'empty-cells: show;' + 'max-width: 100%;' + '}' + 'th,td{' + 'padding: 2px 5px;' + 'border:1px solid #ccc;' + '-webkit-user-select:text;' + '-moz-user-select:text;' + '-ms-user-select:text;' + 'user-select:text' + '}' + 'p{' + 'margin-top:0;' + '}' + '
|
|
40290
|
+
_config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.iframeStyle = 'html{' + 'margin:0;' + 'padding:0;' + 'min-height: 100%;' + '}' + 'body{' + 'box-sizing:border-box;' + 'font-size:13px;' + 'line-height:1.6;' + 'padding:10px;' + 'margin:0;' + 'background:transparent;' + 'color:#000;' + 'position:' + 'relative;' + 'z-index:2;' + 'user-select:auto;' + 'margin:0px;' + 'overflow:auto;' + 'outline:none;' + '}' + 'table{' + 'width:100%;' + 'border:none;' + 'border-collapse:collapse;' + 'empty-cells: show;' + 'max-width: 100%;' + '}' + 'th,td{' + 'padding: 2px 5px;' + 'border:1px solid #ccc;' + '-webkit-user-select:text;' + '-moz-user-select:text;' + '-ms-user-select:text;' + 'user-select:text' + '}' + 'p{' + 'margin-top:0;' + '}' + '.jodit_disabled{' + 'user-select: none;' + '-o-user-select: none;' + '-moz-user-select: none;' + '-khtml-user-select: none;' + '-webkit-user-select: none;' + '-ms-user-select: none' + '}';
|
|
39633
40291
|
_config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.iframeCSSLinks = [];
|
|
39634
40292
|
_config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.iframeSandbox = null;
|
|
39635
40293
|
|
|
@@ -39675,6 +40333,8 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.iframeSandbox = null;
|
|
|
39675
40333
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.attr)(link, 'rel', 'stylesheet');
|
|
39676
40334
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.attr)(link, 'href', href);
|
|
39677
40335
|
doc.head && _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.append(doc.head, link);
|
|
40336
|
+
// What plugins measured in the editing document changes once it's styled
|
|
40337
|
+
jodit.e.on(link, 'load', ()=>jodit.e.fire('resize'));
|
|
39678
40338
|
});
|
|
39679
40339
|
}
|
|
39680
40340
|
if (opt.iframeStyle) {
|
|
@@ -39712,6 +40372,8 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.iframeSandbox = null;
|
|
|
39712
40372
|
(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);
|
|
39713
40373
|
};
|
|
39714
40374
|
const clearMarkers = (html)=>{
|
|
40375
|
+
// The plugins' own styles, from `getContainer`, aren't part of the value
|
|
40376
|
+
html = html.replace(/<style[^>]+jodit-box[^>]*>[\s\S]*?<\/style>/gi, '');
|
|
39715
40377
|
const bodyReg = /<body.*<\/body>/im, bodyMarker = '{%%BODY%%}', body = bodyReg.exec(html);
|
|
39716
40378
|
if (body) {
|
|
39717
40379
|
// remove markers
|
|
@@ -39736,7 +40398,10 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.iframeSandbox = null;
|
|
|
39736
40398
|
*/ const replaceDocument = (html)=>{
|
|
39737
40399
|
const inert = new DOMParser().parseFromString(html, 'text/html');
|
|
39738
40400
|
editor.e.fire('safeHTML', inert.documentElement);
|
|
40401
|
+
// The plugins' own styles stay, as the value leaves them out
|
|
40402
|
+
const styles = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.$$)('style.jodit-box', doc.head);
|
|
39739
40403
|
doc.replaceChild(doc.adoptNode(inert.documentElement), doc.documentElement);
|
|
40404
|
+
styles.forEach((style)=>_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.append(doc.head, style));
|
|
39740
40405
|
};
|
|
39741
40406
|
if (docMode) {
|
|
39742
40407
|
const tag = editor.element.tagName;
|
|
@@ -39878,6 +40543,9 @@ const SELECTED_TAGS = new Set([
|
|
|
39878
40543
|
*/ class imageProcessor extends _core_plugin_index_js__WEBPACK_IMPORTED_MODULE_5__.Plugin {
|
|
39879
40544
|
afterInit(jodit) {
|
|
39880
40545
|
jodit.e.on(jodit.ed, 'selectionchange', this.onSelectionChange);
|
|
40546
|
+
// Over the highlight in `styles/reset.less`; the image keeps its own. It goes
|
|
40547
|
+
// in the editing document, so iframe mode has it whatever `iframeStyle` holds
|
|
40548
|
+
(0,_core_global_js__WEBPACK_IMPORTED_MODULE_3__.getContainer)(jodit, 'image-processor', 'style', true).textContent = `.jodit-wysiwyg.${IMAGE_SELECTED}::selection,` + `.jodit-wysiwyg.${IMAGE_SELECTED} *:not(img)::selection{background:transparent}`;
|
|
39881
40549
|
}
|
|
39882
40550
|
beforeDestruct(jodit) {
|
|
39883
40551
|
jodit.e.off(jodit.ed, 'selectionchange', this.onSelectionChange);
|
|
@@ -40130,8 +40798,12 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.image = {
|
|
|
40130
40798
|
dialog.close();
|
|
40131
40799
|
});
|
|
40132
40800
|
buttons.remove.onAction(()=>{
|
|
40801
|
+
const caret = j.s.createRange();
|
|
40802
|
+
caret.setStartBefore(this.state.sourceImage);
|
|
40803
|
+
caret.collapse(true);
|
|
40133
40804
|
j.s.removeNode(this.state.sourceImage);
|
|
40134
40805
|
dialog.close();
|
|
40806
|
+
j.s.selectRange(caret);
|
|
40135
40807
|
});
|
|
40136
40808
|
buttons.cancel.onAction(()=>{
|
|
40137
40809
|
dialog.close();
|
|
@@ -40145,10 +40817,20 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.image = {
|
|
|
40145
40817
|
],
|
|
40146
40818
|
buttons.check
|
|
40147
40819
|
]);
|
|
40148
|
-
|
|
40149
|
-
|
|
40150
|
-
|
|
40820
|
+
// The dialog fires `afterClose` on its own emitter, not the editor's
|
|
40821
|
+
dialog.e.on(dialog, 'afterClose', ()=>{
|
|
40822
|
+
const { sourceImage } = this.state;
|
|
40823
|
+
if (j.isInDestruct || !_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isOrContains(j.editor, sourceImage)) {
|
|
40824
|
+
return;
|
|
40825
|
+
}
|
|
40826
|
+
if (j.o.image.selectImageAfterClose) {
|
|
40827
|
+
j.s.select(sourceImage);
|
|
40828
|
+
return;
|
|
40151
40829
|
}
|
|
40830
|
+
const caret = j.s.createRange();
|
|
40831
|
+
caret.setStartAfter(sourceImage);
|
|
40832
|
+
caret.collapse(true);
|
|
40833
|
+
j.s.selectRange(caret);
|
|
40152
40834
|
});
|
|
40153
40835
|
dialog.setSize(j.o.image.dialogWidth);
|
|
40154
40836
|
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.markOwner)(j, dialog.container);
|
|
@@ -40179,6 +40861,7 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.image = {
|
|
|
40179
40861
|
this.activeTabState.activeTab = 'Image';
|
|
40180
40862
|
this.__lock();
|
|
40181
40863
|
this.dialog.open().setModal(true).setPosition();
|
|
40864
|
+
this.__focusFirstField();
|
|
40182
40865
|
this.async.promise((resolve, reject)=>(0,_readers_index_js__WEBPACK_IMPORTED_MODULE_10__.readValuesFromImage)(this.j, this.state).then(resolve, reject)).catch((e)=>{
|
|
40183
40866
|
if (!(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.isAbortError)(e)) {
|
|
40184
40867
|
this.dialog.message.error(e.message);
|
|
@@ -40186,6 +40869,14 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.image = {
|
|
|
40186
40869
|
}).finally(()=>this.__unlock());
|
|
40187
40870
|
return false;
|
|
40188
40871
|
}
|
|
40872
|
+
/**
|
|
40873
|
+
* Keys typed while the dialog is open must not reach the editor behind it,
|
|
40874
|
+
* so focus the active tab's first field, or else the first field shown
|
|
40875
|
+
*/ __focusFirstField() {
|
|
40876
|
+
var _a;
|
|
40877
|
+
const fields = (box)=>(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.toArray)(box.querySelectorAll('input, select, textarea'));
|
|
40878
|
+
(_a = fields(this.form.getElm('tabsBox')).concat(fields(this.form.container)).find((field)=>field.offsetParent != null)) === null || _a === void 0 ? void 0 : _a.focus();
|
|
40879
|
+
}
|
|
40189
40880
|
__lock() {
|
|
40190
40881
|
this.dialog.lock();
|
|
40191
40882
|
this.form.setMod('lock', true);
|
|
@@ -42374,10 +43065,11 @@ const align = {
|
|
|
42374
43065
|
/* harmony import */ var _core_global_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(580);
|
|
42375
43066
|
/* harmony import */ var _core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(21537);
|
|
42376
43067
|
/* harmony import */ var _core_plugin_index_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(50911);
|
|
42377
|
-
/* harmony import */ var
|
|
42378
|
-
/* harmony import */ var
|
|
42379
|
-
/* harmony import */ var
|
|
42380
|
-
/* harmony import */ var
|
|
43068
|
+
/* harmony import */ var _core_selection_helpers_index_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(45124);
|
|
43069
|
+
/* harmony import */ var _core_ui_index_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(67510);
|
|
43070
|
+
/* harmony import */ var _core_ui_popup_index_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(61259);
|
|
43071
|
+
/* harmony import */ var _modules_toolbar_factory_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(21491);
|
|
43072
|
+
/* harmony import */ var _config_config_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(24526);
|
|
42381
43073
|
/*!
|
|
42382
43074
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
42383
43075
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -42397,14 +43089,15 @@ const align = {
|
|
|
42397
43089
|
|
|
42398
43090
|
|
|
42399
43091
|
|
|
43092
|
+
|
|
42400
43093
|
/**
|
|
42401
43094
|
* Plugin for show inline popup dialog
|
|
42402
43095
|
*/ class inlinePopup extends _core_plugin_index_js__WEBPACK_IMPORTED_MODULE_4__.Plugin {
|
|
42403
43096
|
get popup() {
|
|
42404
|
-
return new
|
|
43097
|
+
return new _core_ui_popup_index_js__WEBPACK_IMPORTED_MODULE_7__.Popup(this.jodit, false);
|
|
42405
43098
|
}
|
|
42406
43099
|
get toolbar() {
|
|
42407
|
-
return (0,
|
|
43100
|
+
return (0,_modules_toolbar_factory_js__WEBPACK_IMPORTED_MODULE_8__.makeCollection)(this.jodit, this.popup);
|
|
42408
43101
|
}
|
|
42409
43102
|
onClick(node) {
|
|
42410
43103
|
const elements = this.elmsList, mediaWrapper = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.getMediaWrapper)(this.j, node), target = mediaWrapper !== null && mediaWrapper !== void 0 ? mediaWrapper : _core_dom_index_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(node, 'img') ? node : _core_dom_index_js__WEBPACK_IMPORTED_MODULE_1__.Dom.closest(node, elements, this.j.editor);
|
|
@@ -42478,6 +43171,33 @@ const align = {
|
|
|
42478
43171
|
onOutsideClick() {
|
|
42479
43172
|
this.popup.close();
|
|
42480
43173
|
}
|
|
43174
|
+
/**
|
|
43175
|
+
* A key that moves the caret off an element closes its popup, and one
|
|
43176
|
+
* that moves the caret into an element with a popup (a link) opens it,
|
|
43177
|
+
* as clicks do
|
|
43178
|
+
*/ onKeyUp() {
|
|
43179
|
+
this.__followCaret();
|
|
43180
|
+
}
|
|
43181
|
+
__followCaret() {
|
|
43182
|
+
if (!(0,_core_selection_helpers_index_js__WEBPACK_IMPORTED_MODULE_5__.isMoved)(this.j, this.snapRange)) {
|
|
43183
|
+
return;
|
|
43184
|
+
}
|
|
43185
|
+
const { range } = this.j.s;
|
|
43186
|
+
const target = this.previousTarget;
|
|
43187
|
+
if (this.popup.isOpened && this.type !== 'selection' && target && !range.intersectsNode(target)) {
|
|
43188
|
+
this.popup.close();
|
|
43189
|
+
}
|
|
43190
|
+
const node = range.startContainer;
|
|
43191
|
+
const element = this.__elementAt(node);
|
|
43192
|
+
if (range.collapsed && element && element !== this.__keyDownElement) {
|
|
43193
|
+
this.onClick(node);
|
|
43194
|
+
}
|
|
43195
|
+
}
|
|
43196
|
+
/**
|
|
43197
|
+
* The element with a popup that holds `node`
|
|
43198
|
+
*/ __elementAt(node) {
|
|
43199
|
+
return _core_dom_index_js__WEBPACK_IMPORTED_MODULE_1__.Dom.closest(node, this.elmsList, this.j.editor);
|
|
43200
|
+
}
|
|
42481
43201
|
/**
|
|
42482
43202
|
* Can show popup for this type
|
|
42483
43203
|
*/ canShowPopupForType(type) {
|
|
@@ -42517,12 +43237,28 @@ const align = {
|
|
|
42517
43237
|
], 'mousedown touchstart', this.__onDocumentMouseDown).on('closeAllPopups', this.__onCloseAllPopups);
|
|
42518
43238
|
this.addListenersForElements();
|
|
42519
43239
|
}
|
|
43240
|
+
onRecalcPositionPopup() {
|
|
43241
|
+
if (this.popup.isOpened && this.type !== 'selection' && this.previousTarget) {
|
|
43242
|
+
this.__reopenFor = this.previousTarget;
|
|
43243
|
+
}
|
|
43244
|
+
}
|
|
42520
43245
|
__onDocumentMouseDown(e) {
|
|
42521
|
-
|
|
43246
|
+
this.__reopenFor = null;
|
|
43247
|
+
if (this.popup.isOpened && this.type === 'selection' && e.target && _core_ui_index_js__WEBPACK_IMPORTED_MODULE_6__.UIElement.closestElement(e.target, _core_ui_popup_index_js__WEBPACK_IMPORTED_MODULE_7__.Popup)) {
|
|
42522
43248
|
this.__reopenSelectionPopup = true;
|
|
42523
43249
|
}
|
|
42524
43250
|
}
|
|
42525
43251
|
__onCloseAllPopups() {
|
|
43252
|
+
const target = this.__reopenFor;
|
|
43253
|
+
if (target) {
|
|
43254
|
+
this.__reopenFor = null;
|
|
43255
|
+
// After the popup's own `closeAllPopups` handler, as below
|
|
43256
|
+
this.j.async.setTimeout(()=>{
|
|
43257
|
+
if (this.j.editor.contains(target)) {
|
|
43258
|
+
this.onClick(target);
|
|
43259
|
+
}
|
|
43260
|
+
}, 1);
|
|
43261
|
+
}
|
|
42526
43262
|
if (!this.__reopenSelectionPopup) {
|
|
42527
43263
|
return;
|
|
42528
43264
|
}
|
|
@@ -42559,11 +43295,16 @@ const align = {
|
|
|
42559
43295
|
height: rect.height
|
|
42560
43296
|
};
|
|
42561
43297
|
}
|
|
42562
|
-
onSelectionStart() {
|
|
43298
|
+
onSelectionStart(event) {
|
|
43299
|
+
// A key held down moves the caret on every repeat, with one keyup
|
|
43300
|
+
if (event === null || event === void 0 ? void 0 : event.repeat) {
|
|
43301
|
+
this.__followCaret();
|
|
43302
|
+
}
|
|
42563
43303
|
this.snapRange = this.j.s.range.cloneRange();
|
|
43304
|
+
this.__keyDownElement = this.__elementAt(this.snapRange.startContainer);
|
|
42564
43305
|
}
|
|
42565
43306
|
onSelectionEnd(e) {
|
|
42566
|
-
if (e && e.target &&
|
|
43307
|
+
if (e && e.target && _core_ui_index_js__WEBPACK_IMPORTED_MODULE_6__.UIElement.closestElement(e.target, _core_ui_popup_index_js__WEBPACK_IMPORTED_MODULE_7__.Popup)) {
|
|
42567
43308
|
return;
|
|
42568
43309
|
}
|
|
42569
43310
|
const { snapRange } = this, { range } = this.j.s;
|
|
@@ -42647,7 +43388,13 @@ const align = {
|
|
|
42647
43388
|
* command fires `closeAllPopups`, the toolbar should be shown again
|
|
42648
43389
|
* while the selection is still there. See #1238
|
|
42649
43390
|
*/ this.__reopenSelectionPopup = false;
|
|
43391
|
+
/**
|
|
43392
|
+
* The alignment controls fire `recalcPositionPopup` once they have moved
|
|
43393
|
+
* the element, and their button then fires `closeAllPopups`. The popup
|
|
43394
|
+
* opens again beside the element, as the selection toolbar does
|
|
43395
|
+
*/ this.__reopenFor = null;
|
|
42650
43396
|
this.snapRange = null;
|
|
43397
|
+
this.__keyDownElement = null;
|
|
42651
43398
|
this.elmsList = (0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_3__.keys)(this.j.o.popup, false).filter((s)=>!this.isExcludedTarget(s));
|
|
42652
43399
|
}
|
|
42653
43400
|
}
|
|
@@ -42677,6 +43424,12 @@ __decorate([
|
|
|
42677
43424
|
__decorate([
|
|
42678
43425
|
(0,_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_0__.watch)(':outsideClick')
|
|
42679
43426
|
], inlinePopup.prototype, "onOutsideClick", null);
|
|
43427
|
+
__decorate([
|
|
43428
|
+
(0,_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_0__.watch)(':keyup')
|
|
43429
|
+
], inlinePopup.prototype, "onKeyUp", null);
|
|
43430
|
+
__decorate([
|
|
43431
|
+
(0,_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_0__.watch)(':recalcPositionPopup')
|
|
43432
|
+
], inlinePopup.prototype, "onRecalcPositionPopup", null);
|
|
42680
43433
|
__decorate([
|
|
42681
43434
|
_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_0__.autobind
|
|
42682
43435
|
], inlinePopup.prototype, "__onDocumentMouseDown", null);
|
|
@@ -44149,9 +44902,11 @@ const isButtonSeparator = (item)=>item === '|' || item === '---' || item === '\n
|
|
|
44149
44902
|
return cleaned;
|
|
44150
44903
|
}
|
|
44151
44904
|
/**
|
|
44152
|
-
* The width that decides which breakpoint set the toolbar uses
|
|
44153
|
-
*
|
|
44154
|
-
*
|
|
44905
|
+
* The width that decides which breakpoint set the toolbar uses: the editor's
|
|
44906
|
+
* own width, or its parent's while the editor has none yet (for example
|
|
44907
|
+
* while hidden at init). A toolbar rendered into an external container
|
|
44908
|
+
* (`toolbar` set to an element or a selector) lays out in that container, so
|
|
44909
|
+
* its width is what matters there.
|
|
44155
44910
|
*/ function adaptiveWidth(editor) {
|
|
44156
44911
|
var _a;
|
|
44157
44912
|
const { toolbar } = editor.o;
|
|
@@ -44161,7 +44916,7 @@ const isButtonSeparator = (item)=>item === '|' || item === '---' || item === '\n
|
|
|
44161
44916
|
return width;
|
|
44162
44917
|
}
|
|
44163
44918
|
}
|
|
44164
|
-
return ((_a = editor.container.parentElement) !== null && _a !== void 0 ? _a : editor.container).offsetWidth;
|
|
44919
|
+
return editor.container.offsetWidth || ((_a = editor.container.parentElement) !== null && _a !== void 0 ? _a : editor.container).offsetWidth;
|
|
44165
44920
|
}
|
|
44166
44921
|
/**
|
|
44167
44922
|
* Rebuild toolbar in depends on editor's width
|
|
@@ -44235,6 +44990,7 @@ _core_global_js__WEBPACK_IMPORTED_MODULE_1__.pluginSystem.add('mobile', mobile);
|
|
|
44235
44990
|
/* harmony import */ var _config_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6441);
|
|
44236
44991
|
/* harmony import */ var _icons_ol_svg_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(13465);
|
|
44237
44992
|
/* harmony import */ var _icons_ul_svg_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(50267);
|
|
44993
|
+
/* harmony import */ var _start_dialog_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(83086);
|
|
44238
44994
|
/*!
|
|
44239
44995
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
44240
44996
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -44244,11 +45000,19 @@ _core_global_js__WEBPACK_IMPORTED_MODULE_1__.pluginSystem.add('mobile', mobile);
|
|
|
44244
45000
|
|
|
44245
45001
|
|
|
44246
45002
|
|
|
45003
|
+
|
|
45004
|
+
/**
|
|
45005
|
+
* The `ol` dropdown item that asks for the list's start number
|
|
45006
|
+
*/ const START = 'start';
|
|
44247
45007
|
const memoExec = (jodit, _, { control })=>{
|
|
44248
45008
|
var _a;
|
|
44249
45009
|
const key = `button${control.command}`;
|
|
44250
45010
|
const value = (_a = control.args && control.args[0]) !== null && _a !== void 0 ? _a : (0,_core_helpers_utils_data_bind_js__WEBPACK_IMPORTED_MODULE_0__.dataBind)(jodit, key);
|
|
44251
|
-
(
|
|
45011
|
+
if (value === START) {
|
|
45012
|
+
(0,_start_dialog_js__WEBPACK_IMPORTED_MODULE_5__.openStartDialog)(jodit);
|
|
45013
|
+
return;
|
|
45014
|
+
}
|
|
45015
|
+
;(0,_core_helpers_utils_data_bind_js__WEBPACK_IMPORTED_MODULE_0__.dataBind)(jodit, key, value);
|
|
44252
45016
|
jodit.execCommand(control.command, false, value === 'default' ? null : value);
|
|
44253
45017
|
};
|
|
44254
45018
|
_core_ui_icon_js__WEBPACK_IMPORTED_MODULE_1__.Icon.set('ol', _icons_ol_svg_js__WEBPACK_IMPORTED_MODULE_3__["default"]).set('ul', _icons_ul_svg_js__WEBPACK_IMPORTED_MODULE_4__["default"]);
|
|
@@ -44278,9 +45042,14 @@ _config_js__WEBPACK_IMPORTED_MODULE_2__.Config.prototype.controls.ol = {
|
|
|
44278
45042
|
'lower-greek': 'Lower Greek',
|
|
44279
45043
|
'lower-roman': 'Lower Roman',
|
|
44280
45044
|
'upper-alpha': 'Upper Alpha',
|
|
44281
|
-
'upper-roman': 'Upper Roman'
|
|
45045
|
+
'upper-roman': 'Upper Roman',
|
|
45046
|
+
[START]: 'Start at...'
|
|
44282
45047
|
},
|
|
44283
|
-
exec: memoExec
|
|
45048
|
+
exec: memoExec,
|
|
45049
|
+
isChildDisabled: (jodit, button)=>{
|
|
45050
|
+
var _a;
|
|
45051
|
+
return ((_a = button.control.args) === null || _a === void 0 ? void 0 : _a[0]) === START && !(0,_start_dialog_js__WEBPACK_IMPORTED_MODULE_5__.closestOrderedList)(jodit);
|
|
45052
|
+
}
|
|
44284
45053
|
};
|
|
44285
45054
|
|
|
44286
45055
|
|
|
@@ -44363,6 +45132,83 @@ __decorate([
|
|
|
44363
45132
|
_core_global_js__WEBPACK_IMPORTED_MODULE_1__.pluginSystem.add('orderedList', orderedList);
|
|
44364
45133
|
|
|
44365
45134
|
|
|
45135
|
+
/***/ }),
|
|
45136
|
+
|
|
45137
|
+
/***/ 83086:
|
|
45138
|
+
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
45139
|
+
|
|
45140
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
45141
|
+
/* harmony export */ closestOrderedList: function() { return /* binding */ closestOrderedList; },
|
|
45142
|
+
/* harmony export */ openStartDialog: function() { return /* binding */ openStartDialog; }
|
|
45143
|
+
/* harmony export */ });
|
|
45144
|
+
/* harmony import */ var _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2748);
|
|
45145
|
+
/* harmony import */ var _core_helpers_utils_attr_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(29960);
|
|
45146
|
+
/* harmony import */ var _core_ui_button_index_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(62843);
|
|
45147
|
+
/* harmony import */ var _core_ui_form_index_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2525);
|
|
45148
|
+
/*!
|
|
45149
|
+
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
45150
|
+
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
45151
|
+
* Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net
|
|
45152
|
+
*/
|
|
45153
|
+
|
|
45154
|
+
|
|
45155
|
+
|
|
45156
|
+
/**
|
|
45157
|
+
* The numbered list the selection is in
|
|
45158
|
+
*/ function closestOrderedList(jodit) {
|
|
45159
|
+
const current = jodit.s.current();
|
|
45160
|
+
return current ? _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_0__.Dom.closest(current, 'ol', jodit.editor) : null;
|
|
45161
|
+
}
|
|
45162
|
+
/**
|
|
45163
|
+
* Asks for the number of the first item of the list the selection is in,
|
|
45164
|
+
* and sets the list's `start`. The selection is put back when the dialog
|
|
45165
|
+
* closes, however it closes.
|
|
45166
|
+
*/ function openStartDialog(jodit) {
|
|
45167
|
+
const list = closestOrderedList(jodit);
|
|
45168
|
+
if (!list) {
|
|
45169
|
+
return;
|
|
45170
|
+
}
|
|
45171
|
+
const dialog = jodit.dlg({
|
|
45172
|
+
resizable: false,
|
|
45173
|
+
closeOnClickOverlay: true
|
|
45174
|
+
});
|
|
45175
|
+
const input = new _core_ui_form_index_js__WEBPACK_IMPORTED_MODULE_3__.UIInput(jodit, {
|
|
45176
|
+
name: 'start',
|
|
45177
|
+
type: 'number',
|
|
45178
|
+
label: 'Number for the first item',
|
|
45179
|
+
value: list.start
|
|
45180
|
+
});
|
|
45181
|
+
const form = new _core_ui_form_index_js__WEBPACK_IMPORTED_MODULE_3__.UIForm(jodit, [
|
|
45182
|
+
new _core_ui_form_index_js__WEBPACK_IMPORTED_MODULE_3__.UIBlock(jodit, [
|
|
45183
|
+
input
|
|
45184
|
+
])
|
|
45185
|
+
]);
|
|
45186
|
+
form.container.classList.add('jodit-dialog_alert');
|
|
45187
|
+
form.onSubmit(({ start })=>{
|
|
45188
|
+
const value = start === '' ? 1 : parseInt(start, 10);
|
|
45189
|
+
if (isNaN(value)) {
|
|
45190
|
+
input.focus();
|
|
45191
|
+
return false;
|
|
45192
|
+
}
|
|
45193
|
+
dialog.close();
|
|
45194
|
+
(0,_core_helpers_utils_attr_js__WEBPACK_IMPORTED_MODULE_1__.attr)(list, 'start', value === 1 ? null : value);
|
|
45195
|
+
jodit.synchronizeValues();
|
|
45196
|
+
});
|
|
45197
|
+
jodit.s.save();
|
|
45198
|
+
dialog.e.on(dialog, 'afterClose', ()=>{
|
|
45199
|
+
jodit.s.focus();
|
|
45200
|
+
jodit.s.restore();
|
|
45201
|
+
});
|
|
45202
|
+
dialog.setFooter([
|
|
45203
|
+
(0,_core_ui_button_index_js__WEBPACK_IMPORTED_MODULE_2__.Button)(jodit, 'cancel', 'Cancel').onAction(()=>dialog.close()),
|
|
45204
|
+
(0,_core_ui_button_index_js__WEBPACK_IMPORTED_MODULE_2__.Button)(jodit, 'ok', 'Apply', 'primary').onAction(()=>form.submit())
|
|
45205
|
+
]);
|
|
45206
|
+
dialog.open(form, jodit.i18n('Start numbering at'), true, true);
|
|
45207
|
+
input.focus();
|
|
45208
|
+
input.nativeInput.select();
|
|
45209
|
+
}
|
|
45210
|
+
|
|
45211
|
+
|
|
44366
45212
|
/***/ }),
|
|
44367
45213
|
|
|
44368
45214
|
/***/ 71842:
|
|
@@ -45155,6 +46001,10 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.useInputsPlaceholder =
|
|
|
45155
46001
|
return true;
|
|
45156
46002
|
}
|
|
45157
46003
|
const first = root.firstChild;
|
|
46004
|
+
// Firefox pads an empty editable body with a bare <br>
|
|
46005
|
+
if (_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_2__.Dom.isTag(first, 'br') && !_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_2__.Dom.next(first, Boolean, root)) {
|
|
46006
|
+
return true;
|
|
46007
|
+
}
|
|
45158
46008
|
if (_core_constants_js__WEBPACK_IMPORTED_MODULE_0__.INSEPARABLE_TAGS.has((_a = first.nodeName) === null || _a === void 0 ? void 0 : _a.toLowerCase()) || /^(TABLE)$/i.test(first.nodeName)) {
|
|
45159
46009
|
return false;
|
|
45160
46010
|
}
|
|
@@ -45203,11 +46053,13 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.useInputsPlaceholder =
|
|
|
45203
46053
|
marginTop = parseInt(style2.getPropertyValue('margin-top'), 10);
|
|
45204
46054
|
marginLeft = parseInt(style2.getPropertyValue('margin-left'), 10);
|
|
45205
46055
|
(0,_core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_6__.css)(this.placeholderElm, {
|
|
46056
|
+
fontFamily: style2.getPropertyValue('font-family'),
|
|
45206
46057
|
fontSize: parseInt(style2.getPropertyValue('font-size'), 10),
|
|
45207
46058
|
lineHeight: style2.getPropertyValue('line-height')
|
|
45208
46059
|
});
|
|
45209
46060
|
} else {
|
|
45210
46061
|
(0,_core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_6__.css)(this.placeholderElm, {
|
|
46062
|
+
fontFamily: style.getPropertyValue('font-family'),
|
|
45211
46063
|
fontSize: parseInt(style.getPropertyValue('font-size'), 10),
|
|
45212
46064
|
lineHeight: style.getPropertyValue('line-height')
|
|
45213
46065
|
});
|
|
@@ -45255,7 +46107,7 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.useInputsPlaceholder =
|
|
|
45255
46107
|
this.placeholderElm.innerHTML = (0,_core_helpers_utils_attr_js__WEBPACK_IMPORTED_MODULE_5__.attr)(editor.element, 'placeholder') || '';
|
|
45256
46108
|
}
|
|
45257
46109
|
editor.e.fire('placeholder', this.placeholderElm.innerHTML);
|
|
45258
|
-
editor.e.off('.placeholder').on('changePlace.placeholder', this.addNativeListeners).on('change.placeholder focus.placeholder keyup.placeholder mouseup.placeholder keydown.placeholder ' + 'mousedown.placeholder afterSetMode.placeholder changePlace.placeholder ' + 'internalChange.placeholder afterCommand.placeholder', this.toggle).on(window, 'load', this.toggle);
|
|
46110
|
+
editor.e.off('.placeholder').on('changePlace.placeholder', this.addNativeListeners).on('change.placeholder focus.placeholder keyup.placeholder mouseup.placeholder keydown.placeholder ' + 'mousedown.placeholder afterSetMode.placeholder changePlace.placeholder ' + 'internalChange.placeholder afterCommand.placeholder resize.placeholder', this.toggle).on(window, 'load', this.toggle);
|
|
45259
46111
|
this.addNativeListeners();
|
|
45260
46112
|
this.toggle();
|
|
45261
46113
|
};
|
|
@@ -46109,7 +46961,10 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.resizer = {
|
|
|
46109
46961
|
/* harmony import */ var _core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(21537);
|
|
46110
46962
|
/* harmony import */ var _core_helpers_utils_css_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(41180);
|
|
46111
46963
|
/* harmony import */ var _core_plugin_plugin_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(20356);
|
|
46112
|
-
/* harmony import */ var
|
|
46964
|
+
/* harmony import */ var _core_selection_helpers_index_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(45124);
|
|
46965
|
+
/* harmony import */ var _core_ui_index_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(67510);
|
|
46966
|
+
/* harmony import */ var _core_ui_popup_index_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(61259);
|
|
46967
|
+
/* harmony import */ var _config_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(71675);
|
|
46113
46968
|
/*!
|
|
46114
46969
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
46115
46970
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -46129,6 +46984,9 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.resizer = {
|
|
|
46129
46984
|
|
|
46130
46985
|
|
|
46131
46986
|
|
|
46987
|
+
|
|
46988
|
+
|
|
46989
|
+
|
|
46132
46990
|
const keyBInd = '__jodit-resizer_binded';
|
|
46133
46991
|
/**
|
|
46134
46992
|
* Reads a plain pixel value out of a `width`/`height` attribute.
|
|
@@ -46148,11 +47006,19 @@ const keyBInd = '__jodit-resizer_binded';
|
|
|
46148
47006
|
*/ function heightFollowsWidth(element) {
|
|
46149
47007
|
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_5__.cssInline)(element, 'height');
|
|
46150
47008
|
}
|
|
47009
|
+
const IFRAME_WRAPPER = '[data-jodit_iframe_wrapper]';
|
|
47010
|
+
/**
|
|
47011
|
+
* A click on an embed lands on its wrapper, so it selects the embed, until the
|
|
47012
|
+
* wrapper is active. While the editor is locked, as during resizing, the
|
|
47013
|
+
* wrapper takes the mouse again.
|
|
47014
|
+
*/ 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}`;
|
|
46151
47015
|
/**
|
|
46152
47016
|
* The module creates a supporting frame for resizing of the elements img and table
|
|
46153
47017
|
*/ class resizer extends _core_plugin_plugin_js__WEBPACK_IMPORTED_MODULE_6__.Plugin {
|
|
46154
47018
|
/** @override */ afterInit(editor) {
|
|
46155
|
-
|
|
47019
|
+
// It goes in the editing document, so iframe mode has it whatever `iframeStyle` holds
|
|
47020
|
+
(0,_core_global_js__WEBPACK_IMPORTED_MODULE_3__.getContainer)(editor, 'resizer', 'style', true).textContent = EMBED_WRAPPER_STYLE;
|
|
47021
|
+
(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.$$)('div', this.rect).forEach((resizeHandle)=>{
|
|
46156
47022
|
editor.e.on(resizeHandle, 'mousedown.resizer touchstart.resizer', this.onStartResizing.bind(this, resizeHandle));
|
|
46157
47023
|
});
|
|
46158
47024
|
_core_global_js__WEBPACK_IMPORTED_MODULE_3__.eventEmitter.on('hideHelpers', this.hide);
|
|
@@ -46160,7 +47026,11 @@ const keyBInd = '__jodit-resizer_binded';
|
|
|
46160
47026
|
if (isReadOnly) {
|
|
46161
47027
|
this.hide();
|
|
46162
47028
|
}
|
|
46163
|
-
}).on('afterInit changePlace', this.addEventListeners.bind(this))
|
|
47029
|
+
}).on('afterInit changePlace', this.addEventListeners.bind(this))// Handlers without a namespace run first, ahead of those that
|
|
47030
|
+
// move the caret, as table-keyboard-navigation's do
|
|
47031
|
+
.on('keydown', this.onEditorKeyDown, {
|
|
47032
|
+
top: true
|
|
47033
|
+
}).on('afterGetValueFromEditor.resizer', (data)=>{
|
|
46164
47034
|
const rgx = /<jodit[^>]+data-jodit_iframe_wrapper[^>]+>(.*?<iframe[^>]*>.*?<\/iframe>.*?)<\/jodit>/gi;
|
|
46165
47035
|
if (rgx.test(data.value)) {
|
|
46166
47036
|
data.value = data.value.replace(rgx, '$1');
|
|
@@ -46305,6 +47175,38 @@ const keyBInd = '__jodit-resizer_binded';
|
|
|
46305
47175
|
e.stopImmediatePropagation();
|
|
46306
47176
|
}
|
|
46307
47177
|
}
|
|
47178
|
+
onEditorKeyDown(event) {
|
|
47179
|
+
// A key held down moves the caret on every repeat, with one keyup
|
|
47180
|
+
if (event === null || event === void 0 ? void 0 : event.repeat) {
|
|
47181
|
+
this.__followCaret();
|
|
47182
|
+
}
|
|
47183
|
+
this.__keyDownRange = this.j.s.range.cloneRange();
|
|
47184
|
+
this.__keyDownTable = this.__caretTable();
|
|
47185
|
+
}
|
|
47186
|
+
__caretTable() {
|
|
47187
|
+
return _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_2__.Dom.closest(this.j.s.range.startContainer, 'table', this.j.editor);
|
|
47188
|
+
}
|
|
47189
|
+
/**
|
|
47190
|
+
* Hide the frame once a key has moved the caret off its element, and
|
|
47191
|
+
* frame a table the caret has moved into, as clicks do
|
|
47192
|
+
*/ onEditorKeyUp() {
|
|
47193
|
+
this.__followCaret();
|
|
47194
|
+
}
|
|
47195
|
+
__followCaret() {
|
|
47196
|
+
const before = this.__keyDownRange;
|
|
47197
|
+
this.__keyDownRange = null;
|
|
47198
|
+
if (!(0,_core_selection_helpers_index_js__WEBPACK_IMPORTED_MODULE_7__.isMoved)(this.j, before)) {
|
|
47199
|
+
return;
|
|
47200
|
+
}
|
|
47201
|
+
if (this.isShown && this.element && !this.j.s.range.intersectsNode(this.element)) {
|
|
47202
|
+
this.hide();
|
|
47203
|
+
}
|
|
47204
|
+
const table = this.__caretTable();
|
|
47205
|
+
if (table && table !== this.__keyDownTable && this.j.o.allowResizeTags.has('table')) {
|
|
47206
|
+
this.__bind(table);
|
|
47207
|
+
this.onClickElement(table);
|
|
47208
|
+
}
|
|
47209
|
+
}
|
|
46308
47210
|
onKeyDown(e) {
|
|
46309
47211
|
this.isAltMode = e.key === _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.KEY_ALT;
|
|
46310
47212
|
if (!this.isAltMode && this.isResizeMode) {
|
|
@@ -46326,6 +47228,11 @@ const keyBInd = '__jodit-resizer_binded';
|
|
|
46326
47228
|
return;
|
|
46327
47229
|
}
|
|
46328
47230
|
if (!this.isResizeMode) {
|
|
47231
|
+
// A click in the element's popup, or in a list it opens, works on
|
|
47232
|
+
// the element, so it keeps its frame
|
|
47233
|
+
if ((e === null || e === void 0 ? void 0 : e.target) && _core_ui_index_js__WEBPACK_IMPORTED_MODULE_8__.UIElement.closestElement(e.target, _core_ui_popup_index_js__WEBPACK_IMPORTED_MODULE_9__.Popup)) {
|
|
47234
|
+
return;
|
|
47235
|
+
}
|
|
46329
47236
|
return this.hide();
|
|
46330
47237
|
}
|
|
46331
47238
|
e.stopImmediatePropagation();
|
|
@@ -46492,7 +47399,7 @@ const keyBInd = '__jodit-resizer_binded';
|
|
|
46492
47399
|
this.hide();
|
|
46493
47400
|
_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_2__.Dom.safeRemove(this.layer);
|
|
46494
47401
|
_core_global_js__WEBPACK_IMPORTED_MODULE_3__.eventEmitter.off('hideHelpers', this.hide);
|
|
46495
|
-
jodit.e.off(this.j.ow, '.resizer').off('.resizer');
|
|
47402
|
+
jodit.e.off(this.j.ow, '.resizer').off('.resizer').off('keydown', this.onEditorKeyDown);
|
|
46496
47403
|
}
|
|
46497
47404
|
constructor(){
|
|
46498
47405
|
super(...arguments);
|
|
@@ -46517,6 +47424,8 @@ const keyBInd = '__jodit-resizer_binded';
|
|
|
46517
47424
|
this.sizeViewer = this.rect.getElementsByTagName('span')[0];
|
|
46518
47425
|
this.pointerX = 0;
|
|
46519
47426
|
this.pointerY = 0;
|
|
47427
|
+
this.__keyDownRange = null;
|
|
47428
|
+
this.__keyDownTable = null;
|
|
46520
47429
|
this.isAltMode = false;
|
|
46521
47430
|
this.onClickElement = (element)=>{
|
|
46522
47431
|
if (this.isResizeMode) {
|
|
@@ -46578,6 +47487,12 @@ __decorate([
|
|
|
46578
47487
|
__decorate([
|
|
46579
47488
|
_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__.autobind
|
|
46580
47489
|
], resizer.prototype, "onResize", null);
|
|
47490
|
+
__decorate([
|
|
47491
|
+
_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__.autobind
|
|
47492
|
+
], resizer.prototype, "onEditorKeyDown", null);
|
|
47493
|
+
__decorate([
|
|
47494
|
+
(0,_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__.watch)(':keyup')
|
|
47495
|
+
], resizer.prototype, "onEditorKeyUp", null);
|
|
46581
47496
|
__decorate([
|
|
46582
47497
|
_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__.autobind
|
|
46583
47498
|
], resizer.prototype, "onKeyDown", null);
|
|
@@ -47528,8 +48443,9 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.tableAllowCellSelection
|
|
|
47528
48443
|
/* harmony import */ var _core_global_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(580);
|
|
47529
48444
|
/* harmony import */ var _core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(21537);
|
|
47530
48445
|
/* harmony import */ var _core_plugin_index_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(50911);
|
|
47531
|
-
/* harmony import */ var
|
|
47532
|
-
/* harmony import */ var
|
|
48446
|
+
/* harmony import */ var _core_selection_helpers_index_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(45124);
|
|
48447
|
+
/* harmony import */ var _modules_table_table_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(76014);
|
|
48448
|
+
/* harmony import */ var _config_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(55311);
|
|
47533
48449
|
/*!
|
|
47534
48450
|
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
47535
48451
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
@@ -47548,19 +48464,24 @@ _config_js__WEBPACK_IMPORTED_MODULE_0__.Config.prototype.tableAllowCellSelection
|
|
|
47548
48464
|
|
|
47549
48465
|
|
|
47550
48466
|
|
|
48467
|
+
|
|
47551
48468
|
const key = 'table_processor_observer';
|
|
47552
48469
|
const MOUSE_MOVE_LABEL = 'onMoveTableSelectCell';
|
|
47553
48470
|
class selectCells extends _core_plugin_index_js__WEBPACK_IMPORTED_MODULE_5__.Plugin {
|
|
47554
48471
|
/**
|
|
47555
48472
|
* Shortcut for Jodit.modules.Table
|
|
47556
48473
|
*/ get __tableModule() {
|
|
47557
|
-
return this.j.getInstance(
|
|
48474
|
+
return this.j.getInstance(_modules_table_table_js__WEBPACK_IMPORTED_MODULE_7__.Table, this.j.o);
|
|
47558
48475
|
}
|
|
47559
48476
|
afterInit(jodit) {
|
|
47560
48477
|
if (!jodit.o.tableAllowCellSelection) {
|
|
47561
48478
|
return;
|
|
47562
48479
|
}
|
|
47563
|
-
jodit.e
|
|
48480
|
+
jodit.e// Handlers without a namespace run first, ahead of those that
|
|
48481
|
+
// move the caret, as table-keyboard-navigation's do
|
|
48482
|
+
.on('keydown', this.__onKeyDown, {
|
|
48483
|
+
top: true
|
|
48484
|
+
}).on('keydown.select-cells', (event)=>{
|
|
47564
48485
|
if (event.key === _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.KEY_TAB) {
|
|
47565
48486
|
this.unselectCells();
|
|
47566
48487
|
}
|
|
@@ -47584,6 +48505,59 @@ class selectCells extends _core_plugin_index_js__WEBPACK_IMPORTED_MODULE_5__.Plu
|
|
|
47584
48505
|
}
|
|
47585
48506
|
});
|
|
47586
48507
|
}
|
|
48508
|
+
__onKeyDown(event) {
|
|
48509
|
+
// A key held down moves the caret on every repeat, with one keyup
|
|
48510
|
+
if (event === null || event === void 0 ? void 0 : event.repeat) {
|
|
48511
|
+
this.__followCaret();
|
|
48512
|
+
}
|
|
48513
|
+
this.__keyDownCell = this.__caretCell();
|
|
48514
|
+
this.__keyDownRange = this.j.s.range.cloneRange();
|
|
48515
|
+
this.__keyDownInLink = this.__isInLink();
|
|
48516
|
+
}
|
|
48517
|
+
__isInLink() {
|
|
48518
|
+
return Boolean(_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_2__.Dom.closest(this.j.s.range.startContainer, 'a', this.j.editor));
|
|
48519
|
+
}
|
|
48520
|
+
/**
|
|
48521
|
+
* Where the selection starts rather than `s.current()`, which finds the
|
|
48522
|
+
* first cell when the caret is just before the table
|
|
48523
|
+
*/ __caretCell() {
|
|
48524
|
+
return _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_2__.Dom.closest(this.j.s.range.startContainer, _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_2__.Dom.isCell, this.j.editor);
|
|
48525
|
+
}
|
|
48526
|
+
/**
|
|
48527
|
+
* A key that moves the caret into a cell, from another cell or from
|
|
48528
|
+
* outside the table, marks that cell and opens its popup, as a click on
|
|
48529
|
+
* it does. One that moves the caret out of the table unmarks the cells
|
|
48530
|
+
*/ onKeyUp() {
|
|
48531
|
+
this.__followCaret();
|
|
48532
|
+
}
|
|
48533
|
+
__followCaret() {
|
|
48534
|
+
const before = this.__keyDownRange;
|
|
48535
|
+
this.__keyDownRange = null;
|
|
48536
|
+
if (this.j.o.readonly || !(0,_core_selection_helpers_index_js__WEBPACK_IMPORTED_MODULE_6__.isMoved)(this.j, before)) {
|
|
48537
|
+
return;
|
|
48538
|
+
}
|
|
48539
|
+
const cell = this.__caretCell();
|
|
48540
|
+
const hasLeftLink = this.__keyDownInLink && !this.__isInLink();
|
|
48541
|
+
if (cell === this.__keyDownCell && !(cell && hasLeftLink)) {
|
|
48542
|
+
return;
|
|
48543
|
+
}
|
|
48544
|
+
const hadMarked = this.__tableModule.getAllSelectedCells().length > 0;
|
|
48545
|
+
this.unselectCells();
|
|
48546
|
+
if (!cell) {
|
|
48547
|
+
if (hadMarked) {
|
|
48548
|
+
this.j.e.fire('hidePopup', 'cells');
|
|
48549
|
+
}
|
|
48550
|
+
return;
|
|
48551
|
+
}
|
|
48552
|
+
const table = _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_2__.Dom.closest(cell, 'table', this.j.editor);
|
|
48553
|
+
if (!table) {
|
|
48554
|
+
return;
|
|
48555
|
+
}
|
|
48556
|
+
// As after a click, the first change to the cell keeps the mark
|
|
48557
|
+
this.__selectedCell = cell;
|
|
48558
|
+
this.__tableModule.addSelection(cell);
|
|
48559
|
+
this.j.e.fire('showPopup', table, ()=>(0,_core_helpers_index_js__WEBPACK_IMPORTED_MODULE_4__.position)(cell, this.j), 'cells');
|
|
48560
|
+
}
|
|
47587
48561
|
/**
|
|
47588
48562
|
* Mouse click inside the table
|
|
47589
48563
|
*/ onStartSelection(cell, event) {
|
|
@@ -47905,10 +48879,17 @@ class selectCells extends _core_plugin_index_js__WEBPACK_IMPORTED_MODULE_5__.Plu
|
|
|
47905
48879
|
}
|
|
47906
48880
|
/** @override */ beforeDestruct(jodit) {
|
|
47907
48881
|
this.__onRemoveSelection();
|
|
47908
|
-
jodit.e.off('.select-cells');
|
|
48882
|
+
jodit.e.off('.select-cells').off('keydown', this.__onKeyDown);
|
|
47909
48883
|
}
|
|
47910
48884
|
constructor(){
|
|
47911
48885
|
super(...arguments);
|
|
48886
|
+
/**
|
|
48887
|
+
* The cell with the caret, and the selection, when a key went down
|
|
48888
|
+
*/ this.__keyDownCell = null;
|
|
48889
|
+
this.__keyDownRange = null;
|
|
48890
|
+
/**
|
|
48891
|
+
* A link's popup replaces the cell's while the caret is in the link
|
|
48892
|
+
*/ this.__keyDownInLink = false;
|
|
47912
48893
|
/**
|
|
47913
48894
|
* First selected cell
|
|
47914
48895
|
*/ this.__selectedCell = null;
|
|
@@ -47920,6 +48901,12 @@ class selectCells extends _core_plugin_index_js__WEBPACK_IMPORTED_MODULE_5__.Plu
|
|
|
47920
48901
|
selectCells.requires = [
|
|
47921
48902
|
'select'
|
|
47922
48903
|
];
|
|
48904
|
+
__decorate([
|
|
48905
|
+
_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__.autobind
|
|
48906
|
+
], selectCells.prototype, "__onKeyDown", null);
|
|
48907
|
+
__decorate([
|
|
48908
|
+
(0,_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__.watch)(':keyup')
|
|
48909
|
+
], selectCells.prototype, "onKeyUp", null);
|
|
47923
48910
|
__decorate([
|
|
47924
48911
|
_core_decorators_index_js__WEBPACK_IMPORTED_MODULE_1__.autobind
|
|
47925
48912
|
], selectCells.prototype, "onStartSelection", null);
|
|
@@ -51054,7 +52041,9 @@ const WORK_KEYS = new Set([
|
|
|
51054
52041
|
case _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.KEY_LEFT:
|
|
51055
52042
|
{
|
|
51056
52043
|
next = getNextCell();
|
|
51057
|
-
|
|
52044
|
+
// Left in the first cell leaves the table, as Up in the
|
|
52045
|
+
// top row does
|
|
52046
|
+
if (!next && key === _core_constants_js__WEBPACK_IMPORTED_MODULE_0__.KEY_TAB) {
|
|
51058
52047
|
tableModule.appendRow(table, !isPrev ? false : _core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.first(table, (node)=>_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.isTag(node, 'tr')), !isPrev);
|
|
51059
52048
|
next = getNextCell();
|
|
51060
52049
|
}
|
|
@@ -51080,7 +52069,6 @@ const WORK_KEYS = new Set([
|
|
|
51080
52069
|
if (!next) {
|
|
51081
52070
|
return;
|
|
51082
52071
|
}
|
|
51083
|
-
editor.e.fire('hidePopup hideResizer');
|
|
51084
52072
|
if (!next.firstChild) {
|
|
51085
52073
|
const first = editor.createInside.element('br');
|
|
51086
52074
|
_core_dom_dom_js__WEBPACK_IMPORTED_MODULE_1__.Dom.append(next, first);
|