jodit 3.20.2 → 3.20.3
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/build/jodit.css +2 -2
- package/build/jodit.es2018.css +1 -1
- package/build/jodit.es2018.en.css +1 -1
- package/build/jodit.es2018.en.js +14 -12
- package/build/jodit.es2018.en.min.js +1 -1
- package/build/jodit.es2018.js +23 -12
- package/build/jodit.es2018.min.js +1 -1
- package/build/jodit.js +21 -10
- package/build/jodit.min.css +1 -1
- package/build/jodit.min.js +1 -1
- package/build/plugins/debug/debug.es2018.en.js +1 -1
- package/build/plugins/debug/debug.es2018.js +1 -1
- package/build/plugins/debug/debug.js +1 -1
- package/build/plugins/speech-recognize/speech-recognize.css +1 -1
- package/build/plugins/speech-recognize/speech-recognize.es2018.css +1 -1
- package/build/plugins/speech-recognize/speech-recognize.es2018.en.css +1 -1
- package/build/plugins/speech-recognize/speech-recognize.es2018.en.js +1 -1
- package/build/plugins/speech-recognize/speech-recognize.es2018.js +1 -1
- package/build/plugins/speech-recognize/speech-recognize.js +1 -1
- package/build/vdom.css +1 -1
- package/build/vdom.js +1 -1
- package/package.json +28 -24
- package/src/README.md +2 -0
- package/src/core/async/README.md +2 -0
- package/src/core/component/README.md +2 -0
- package/src/core/create/README.md +2 -0
- package/src/core/decorators/cache/README.md +2 -0
- package/src/core/decorators/component/README.md +2 -0
- package/src/core/decorators/debounce/README.md +2 -0
- package/src/core/decorators/hook/README.md +2 -0
- package/src/core/decorators/idle/README.md +2 -0
- package/src/core/decorators/nonenumerable/README.md +2 -0
- package/src/core/decorators/persistent/README.md +2 -0
- package/src/core/decorators/wait/README.md +2 -0
- package/src/core/decorators/watch/README.md +2 -0
- package/src/core/dom/README.md +2 -0
- package/src/core/event-emitter/README.md +2 -0
- package/src/core/helpers/README.md +2 -0
- package/src/core/plugin/README.md +2 -0
- package/src/core/request/README.md +2 -0
- package/src/core/selection/README.md +2 -0
- package/src/core/storage/README.md +2 -0
- package/src/core/vdom/README.md +2 -0
- package/src/core/view/README.md +2 -0
- package/src/index.ts +7 -4
- package/src/jodit.ts +4 -2
- package/src/langs/index.ts +7 -4
- package/src/langs/keys.js +7 -0
- package/src/modules/README.md +1 -1
- package/src/modules/dialog/README.md +2 -0
- package/src/modules/file-browser/README.md +12 -4
- package/src/modules/file-browser/file-browser.test.screenshot.js +1 -1
- package/src/modules/image-editor/README.md +1 -1
- package/src/modules/image-editor/image-editor.test.screenshot.js +1 -1
- package/src/modules/uploader/README.md +2 -0
- package/src/plugins/color/color.test.screenshot.js +26 -0
- package/src/plugins/image-properties/image-properties.test.screenshot.js +27 -0
- package/src/plugins/limit/limit.test.js +27 -0
- package/src/plugins/limit/limit.ts +1 -1
- package/src/plugins/link/link.test.screenshot.js +26 -0
- package/src/plugins/search/search.test.screenshot.js +38 -0
- package/src/plugins/symbols/symbols.test.screenshot.js +25 -0
- package/src/styles/icons/README.md +2 -0
- package/src/types/file-browser.d.ts +15 -0
- package/tsconfig.json +3 -0
- package/types/config.d.ts +0 -506
- package/types/core/async/async.d.ts +0 -32
- package/types/core/async/index.d.ts +0 -3
- package/types/core/component/component.d.ts +0 -81
- package/types/core/component/index.d.ts +0 -3
- package/types/core/component/statuses.d.ts +0 -3
- package/types/core/component/view-component.d.ts +0 -13
- package/types/core/constants.d.ts +0 -60
- package/types/core/create/create.d.ts +0 -32
- package/types/core/create/index.d.ts +0 -3
- package/types/core/decorators/component/component.d.ts +0 -9
- package/types/core/decorators/debounce/debounce.d.ts +0 -8
- package/types/core/decorators/hook/hook.d.ts +0 -8
- package/types/core/decorators/idle/idle.d.ts +0 -5
- package/types/core/decorators/index.d.ts +0 -5
- package/types/core/decorators/nonenumerable/nonenumerable.d.ts +0 -5
- package/types/core/decorators/persistent/persistent.d.ts +0 -5
- package/types/core/decorators/wait/wait.d.ts +0 -5
- package/types/core/decorators/watch/watch.d.ts +0 -8
- package/types/core/dom/dom.d.ts +0 -171
- package/types/core/dom/index.d.ts +0 -3
- package/types/core/dom/lazy-walker.d.ts +0 -3
- package/types/core/event-emitter/event-emitter.d.ts +0 -99
- package/types/core/event-emitter/eventify.d.ts +0 -25
- package/types/core/event-emitter/index.d.ts +0 -3
- package/types/core/event-emitter/observable.d.ts +0 -38
- package/types/core/event-emitter/store.d.ts +0 -3
- package/types/core/global.d.ts +0 -12
- package/types/core/helpers/array/as-array.d.ts +0 -3
- package/types/core/helpers/array/index.d.ts +0 -3
- package/types/core/helpers/array/split-array.d.ts +0 -6
- package/types/core/helpers/array/to-array.d.ts +0 -4
- package/types/core/helpers/async/index.d.ts +0 -3
- package/types/core/helpers/async/set-timeout.d.ts +0 -9
- package/types/core/helpers/checker/has-browser-color-picker.d.ts +0 -6
- package/types/core/helpers/checker/index.d.ts +0 -3
- package/types/core/helpers/checker/is-array.d.ts +0 -6
- package/types/core/helpers/checker/is-boolean.d.ts +0 -3
- package/types/core/helpers/checker/is-equal.d.ts +0 -3
- package/types/core/helpers/checker/is-function.d.ts +0 -6
- package/types/core/helpers/checker/is-html-from-word.d.ts +0 -6
- package/types/core/helpers/checker/is-html.d.ts +0 -3
- package/types/core/helpers/checker/is-imp-interface.d.ts +0 -12
- package/types/core/helpers/checker/is-int.d.ts +0 -3
- package/types/core/helpers/checker/is-jodit-object.d.ts +0 -6
- package/types/core/helpers/checker/is-native-function.d.ts +0 -6
- package/types/core/helpers/checker/is-number.d.ts +0 -6
- package/types/core/helpers/checker/is-numeric.d.ts +0 -3
- package/types/core/helpers/checker/is-plain-object.d.ts +0 -6
- package/types/core/helpers/checker/is-promise.d.ts +0 -3
- package/types/core/helpers/checker/is-string.d.ts +0 -6
- package/types/core/helpers/checker/is-url.d.ts +0 -6
- package/types/core/helpers/checker/is-valid-name.d.ts +0 -6
- package/types/core/helpers/checker/is-view-object.d.ts +0 -6
- package/types/core/helpers/checker/is-void.d.ts +0 -6
- package/types/core/helpers/checker/is-window.d.ts +0 -3
- package/types/core/helpers/color/color-to-hex.d.ts +0 -16
- package/types/core/helpers/color/index.d.ts +0 -3
- package/types/core/helpers/html/apply-styles.d.ts +0 -5
- package/types/core/helpers/html/clean-from-word.d.ts +0 -4
- package/types/core/helpers/html/htmlspecialchars.d.ts +0 -6
- package/types/core/helpers/html/index.d.ts +0 -3
- package/types/core/helpers/html/nl2br.d.ts +0 -6
- package/types/core/helpers/html/safe-html.d.ts +0 -3
- package/types/core/helpers/html/strip-tags.d.ts +0 -3
- package/types/core/helpers/index.d.ts +0 -5
- package/types/core/helpers/normalize/index.d.ts +0 -3
- package/types/core/helpers/normalize/normalize-color.d.ts +0 -6
- package/types/core/helpers/normalize/normalize-key-aliases.d.ts +0 -3
- package/types/core/helpers/normalize/normalize-license.d.ts +0 -3
- package/types/core/helpers/normalize/normalize-path.d.ts +0 -3
- package/types/core/helpers/normalize/normalize-relative-path.d.ts +0 -3
- package/types/core/helpers/normalize/normalize-size.d.ts +0 -6
- package/types/core/helpers/normalize/normalize-url.d.ts +0 -3
- package/types/core/helpers/size/get-content-width.d.ts +0 -3
- package/types/core/helpers/size/get-scroll-parent.d.ts +0 -3
- package/types/core/helpers/size/index.d.ts +0 -3
- package/types/core/helpers/size/inner-width.d.ts +0 -3
- package/types/core/helpers/size/offset.d.ts +0 -7
- package/types/core/helpers/size/position.d.ts +0 -3
- package/types/core/helpers/string/camel-case.d.ts +0 -6
- package/types/core/helpers/string/fuzzy-search-index.d.ts +0 -4
- package/types/core/helpers/string/i18n.d.ts +0 -31
- package/types/core/helpers/string/index.d.ts +0 -3
- package/types/core/helpers/string/kebab-case.d.ts +0 -3
- package/types/core/helpers/string/stringify.d.ts +0 -3
- package/types/core/helpers/string/trim.d.ts +0 -7
- package/types/core/helpers/string/ucfirst.d.ts +0 -6
- package/types/core/helpers/utils/align.d.ts +0 -12
- package/types/core/helpers/utils/append-script.d.ts +0 -12
- package/types/core/helpers/utils/assert.d.ts +0 -1
- package/types/core/helpers/utils/browser.d.ts +0 -14
- package/types/core/helpers/utils/build-query.d.ts +0 -6
- package/types/core/helpers/utils/complete-url.d.ts +0 -3
- package/types/core/helpers/utils/config-proto.d.ts +0 -33
- package/types/core/helpers/utils/convert-media-url-to-video-embed.d.ts +0 -3
- package/types/core/helpers/utils/css.d.ts +0 -6
- package/types/core/helpers/utils/ctrl-key.d.ts +0 -7
- package/types/core/helpers/utils/data-bind.d.ts +0 -3
- package/types/core/helpers/utils/default-language.d.ts +0 -3
- package/types/core/helpers/utils/error/error.d.ts +0 -3
- package/types/core/helpers/utils/error/errors/abort-error.d.ts +0 -3
- package/types/core/helpers/utils/error/errors/connection-error.d.ts +0 -3
- package/types/core/helpers/utils/error/errors/index.d.ts +0 -3
- package/types/core/helpers/utils/error/errors/options-error.d.ts +0 -3
- package/types/core/helpers/utils/error/index.d.ts +0 -3
- package/types/core/helpers/utils/get-class-name.d.ts +0 -3
- package/types/core/helpers/utils/get.d.ts +0 -22
- package/types/core/helpers/utils/human-size-to-bytes.d.ts +0 -7
- package/types/core/helpers/utils/index.d.ts +0 -3
- package/types/core/helpers/utils/mark-deprecated.d.ts +0 -10
- package/types/core/helpers/utils/parse-query.d.ts +0 -6
- package/types/core/helpers/utils/print.d.ts +0 -9
- package/types/core/helpers/utils/reset.d.ts +0 -10
- package/types/core/helpers/utils/scroll-into-view.d.ts +0 -3
- package/types/core/helpers/utils/selector.d.ts +0 -29
- package/types/core/helpers/utils/set.d.ts +0 -16
- package/types/core/helpers/utils/stack.d.ts +0 -3
- package/types/core/helpers/utils/utils.d.ts +0 -36
- package/types/core/helpers/utils/val.d.ts +0 -3
- package/types/core/plugin/index.d.ts +0 -3
- package/types/core/plugin/plugin-system.d.ts +0 -48
- package/types/core/plugin/plugin.d.ts +0 -10
- package/types/core/request/ajax.d.ts +0 -8
- package/types/core/request/config.d.ts +0 -6
- package/types/core/request/index.d.ts +0 -3
- package/types/core/request/response.d.ts +0 -3
- package/types/core/selection/helpers/index.d.ts +0 -3
- package/types/core/selection/helpers/move-node-inside-start.d.ts +0 -7
- package/types/core/selection/index.d.ts +0 -3
- package/types/core/selection/select.d.ts +0 -180
- package/types/core/selection/style/api/element-has-same-style.d.ts +0 -7
- package/types/core/selection/style/api/extract.d.ts +0 -16
- package/types/core/selection/style/api/finite-state-machine.d.ts +0 -3
- package/types/core/selection/style/api/get-suit-child.d.ts +0 -8
- package/types/core/selection/style/api/get-suit-parent.d.ts +0 -8
- package/types/core/selection/style/api/is-inside-invisible-element.d.ts +0 -4
- package/types/core/selection/style/api/is-normal-node.d.ts +0 -4
- package/types/core/selection/style/api/is-suit-element.d.ts +0 -24
- package/types/core/selection/style/api/toggle/toggle-css.d.ts +0 -4
- package/types/core/selection/style/api/toggle/toggle-ordered-list.d.ts +0 -4
- package/types/core/selection/style/api/toggle-commit-styles.d.ts +0 -5
- package/types/core/selection/style/api/unwrap-children.d.ts +0 -4
- package/types/core/selection/style/api/wrap-and-commit-style.d.ts +0 -4
- package/types/core/selection/style/api/wrap-ordered-list.d.ts +0 -5
- package/types/core/selection/style/api/wrap-unwrapped-text.d.ts +0 -4
- package/types/core/selection/style/apply-style.d.ts +0 -3
- package/types/core/selection/style/commit-style.d.ts +0 -9
- package/types/core/storage/engines/local-storage-provider.d.ts +0 -9
- package/types/core/storage/engines/memory-storage-provider.d.ts +0 -3
- package/types/core/storage/index.d.ts +0 -3
- package/types/core/storage/storage.d.ts +0 -5
- package/types/core/traits/dlgs.d.ts +0 -3
- package/types/core/traits/elms.d.ts +0 -9
- package/types/core/traits/index.d.ts +0 -3
- package/types/core/traits/mods.d.ts +0 -11
- package/types/core/ui/button/button/button.d.ts +0 -32
- package/types/core/ui/button/group/group.d.ts +0 -6
- package/types/core/ui/button/index.d.ts +0 -5
- package/types/core/ui/button/tooltip/tooltip.d.ts +0 -8
- package/types/core/ui/element.d.ts +0 -27
- package/types/core/ui/form/block/block.d.ts +0 -4
- package/types/core/ui/form/form.d.ts +0 -7
- package/types/core/ui/form/index.d.ts +0 -3
- package/types/core/ui/form/inputs/area/area.d.ts +0 -7
- package/types/core/ui/form/inputs/checkbox/checkbox.d.ts +0 -8
- package/types/core/ui/form/inputs/file/file.d.ts +0 -4
- package/types/core/ui/form/inputs/index.d.ts +0 -3
- package/types/core/ui/form/inputs/input/input.d.ts +0 -18
- package/types/core/ui/form/inputs/select/select.d.ts +0 -10
- package/types/core/ui/form/validators/index.d.ts +0 -3
- package/types/core/ui/form/validators/input.d.ts +0 -9
- package/types/core/ui/form/validators/select.d.ts +0 -6
- package/types/core/ui/group/group.d.ts +0 -32
- package/types/core/ui/group/index.d.ts +0 -3
- package/types/core/ui/group/list.d.ts +0 -16
- package/types/core/ui/group/separator.d.ts +0 -3
- package/types/core/ui/group/spacer.d.ts +0 -3
- package/types/core/ui/helpers/buttons.d.ts +0 -3
- package/types/core/ui/helpers/get-control-type.d.ts +0 -6
- package/types/core/ui/helpers/get-strong-control-types.d.ts +0 -3
- package/types/core/ui/icon.d.ts +0 -15
- package/types/core/ui/index.d.ts +0 -5
- package/types/core/ui/popup/index.d.ts +0 -3
- package/types/core/ui/popup/popup.d.ts +0 -35
- package/types/core/ui/progress-bar/progress-bar.d.ts +0 -10
- package/types/core/vdom/helpers/index.d.ts +9 -0
- package/types/core/vdom/index.d.ts +8 -0
- package/types/core/vdom/interface.d.ts +48 -0
- package/types/core/vdom/render/index.d.ts +23 -0
- package/types/core/vdom/v-dom-jodit.d.ts +15 -0
- package/types/core/view/view-with-toolbar.d.ts +0 -22
- package/types/core/view/view.d.ts +0 -64
- package/types/index.d.ts +1 -6
- package/types/jodit.d.ts +5 -257
- package/types/langs/index.d.ts +0 -5
- package/types/modules/context-menu/context-menu.d.ts +0 -20
- package/types/modules/dialog/alert.d.ts +0 -17
- package/types/modules/dialog/confirm.d.ts +0 -17
- package/types/modules/dialog/dialog.d.ts +0 -115
- package/types/modules/dialog/index.d.ts +0 -5
- package/types/modules/dialog/prompt.d.ts +0 -20
- package/types/modules/file-browser/builders/context-menu.d.ts +0 -3
- package/types/modules/file-browser/builders/elements-map.d.ts +0 -6
- package/types/modules/file-browser/builders/item.d.ts +0 -3
- package/types/modules/file-browser/data-provider.d.ts +0 -69
- package/types/modules/file-browser/factories.d.ts +0 -3
- package/types/modules/file-browser/fetch/delete-file.d.ts +0 -6
- package/types/modules/file-browser/fetch/load-items.d.ts +0 -6
- package/types/modules/file-browser/fetch/load-tree.d.ts +0 -6
- package/types/modules/file-browser/file-browser.d.ts +0 -36
- package/types/modules/file-browser/index.d.ts +0 -5
- package/types/modules/file-browser/listeners/native-listeners.d.ts +0 -3
- package/types/modules/file-browser/listeners/self-listeners.d.ts +0 -3
- package/types/modules/file-browser/listeners/state-listeners.d.ts +0 -6
- package/types/modules/file-browser/ui/index.d.ts +0 -3
- package/types/modules/history/command.d.ts +0 -3
- package/types/modules/history/history.d.ts +0 -30
- package/types/modules/history/snapshot.d.ts +0 -40
- package/types/modules/history/stack.d.ts +0 -3
- package/types/modules/image-editor/image-editor.d.ts +1 -54
- package/types/modules/image-editor/templates/form.d.ts +0 -3
- package/types/modules/index.d.ts +0 -5
- package/types/modules/status-bar/status-bar.d.ts +0 -20
- package/types/modules/table/table.d.ts +0 -57
- package/types/modules/toolbar/button/button.d.ts +1 -41
- package/types/modules/toolbar/button/content.d.ts +0 -6
- package/types/modules/toolbar/button/index.d.ts +0 -3
- package/types/modules/toolbar/collection/collection.d.ts +0 -23
- package/types/modules/toolbar/collection/editor-collection.d.ts +0 -19
- package/types/modules/toolbar/factory.d.ts +0 -11
- package/types/modules/uploader/config.d.ts +0 -6
- package/types/modules/uploader/helpers/build-data.d.ts +0 -3
- package/types/modules/uploader/helpers/data-uri-to-blob.d.ts +0 -6
- package/types/modules/uploader/helpers/index.d.ts +0 -3
- package/types/modules/uploader/helpers/process-old-browser-drag.d.ts +0 -3
- package/types/modules/uploader/helpers/send-files.d.ts +0 -6
- package/types/modules/uploader/helpers/send.d.ts +0 -3
- package/types/modules/uploader/uploader.d.ts +0 -35
- package/types/modules/widget/color-picker/color-picker.d.ts +0 -22
- package/types/modules/widget/file-selector/file-selector.d.ts +0 -41
- package/types/modules/widget/index.d.ts +0 -5
- package/types/modules/widget/tabs/tabs.d.ts +0 -22
- package/types/plugins/about/about.d.ts +0 -5
- package/types/plugins/add-new-line/add-new-line.d.ts +0 -9
- package/types/plugins/add-new-line/config.d.ts +0 -22
- package/types/plugins/backspace/backspace.d.ts +0 -14
- package/types/plugins/backspace/cases/check-join-neighbors.d.ts +0 -6
- package/types/plugins/backspace/cases/check-join-two-lists.d.ts +0 -16
- package/types/plugins/backspace/cases/check-not-collapsed.d.ts +0 -16
- package/types/plugins/backspace/cases/check-remove-char.d.ts +0 -16
- package/types/plugins/backspace/cases/check-remove-content-not-editable.d.ts +0 -7
- package/types/plugins/backspace/cases/check-remove-empty-neighbor.d.ts +0 -16
- package/types/plugins/backspace/cases/check-remove-empty-parent.d.ts +0 -17
- package/types/plugins/backspace/cases/check-remove-unbreakable-element.d.ts +0 -17
- package/types/plugins/backspace/cases/check-table-cell.d.ts +0 -17
- package/types/plugins/backspace/cases/check-unwrap-first-list-item.d.ts +0 -17
- package/types/plugins/backspace/cases/index.d.ts +1 -1
- package/types/plugins/backspace/helpers.d.ts +0 -7
- package/types/plugins/bold/bold.d.ts +0 -8
- package/types/plugins/class-span/class-span.d.ts +0 -27
- package/types/plugins/clean-html/clean-html.d.ts +0 -17
- package/types/plugins/clean-html/config.d.ts +0 -73
- package/types/plugins/clean-html/helpers/get-hash.d.ts +0 -6
- package/types/plugins/clean-html/helpers/index.d.ts +0 -3
- package/types/plugins/clean-html/helpers/remove-format/remove-format-for-collapsed-selection.d.ts +0 -10
- package/types/plugins/clean-html/helpers/remove-format/remove-format-for-selection.d.ts +0 -7
- package/types/plugins/clean-html/helpers/visitor/filters/allow-attributes.d.ts +0 -6
- package/types/plugins/clean-html/helpers/visitor/filters/fill-empty-paragraph.d.ts +0 -6
- package/types/plugins/clean-html/helpers/visitor/filters/index.d.ts +0 -6
- package/types/plugins/clean-html/helpers/visitor/filters/remove-empty-text-node.d.ts +0 -6
- package/types/plugins/clean-html/helpers/visitor/filters/remove-inv-text-nodes.d.ts +0 -6
- package/types/plugins/clean-html/helpers/visitor/filters/replace-old-tags.d.ts +0 -6
- package/types/plugins/clean-html/helpers/visitor/filters/sanitize-attributes.d.ts +0 -6
- package/types/plugins/clean-html/helpers/visitor/filters/try-remove-node.d.ts +0 -6
- package/types/plugins/clean-html/helpers/visitor/visit-node-walker.d.ts +0 -6
- package/types/plugins/clipboard/clipboard.d.ts +0 -10
- package/types/plugins/color/color.d.ts +0 -8
- package/types/plugins/copy-format/copy-format.d.ts +0 -5
- package/types/plugins/copy-format/langs/index.d.ts +25 -0
- package/types/plugins/debug/debug.d.ts +11 -0
- package/types/plugins/drag-and-drop/drag-and-drop.d.ts +0 -5
- package/types/plugins/drag-and-drop-element/config.d.ts +0 -3
- package/types/plugins/drag-and-drop-element/drag-and-drop-element.d.ts +0 -26
- package/types/plugins/dtd/after-insert/index.d.ts +0 -4
- package/types/plugins/dtd/after-insert/remove-extra-br.d.ts +0 -9
- package/types/plugins/dtd/before-insert/check-block-nesting.d.ts +0 -9
- package/types/plugins/dtd/before-insert/index.d.ts +0 -4
- package/types/plugins/dtd/config.d.ts +0 -12
- package/types/plugins/enter/enter.d.ts +0 -11
- package/types/plugins/enter/helpers/check-br.d.ts +0 -7
- package/types/plugins/enter/helpers/check-unsplittable-box.d.ts +0 -7
- package/types/plugins/enter/helpers/get-block-wrapper.d.ts +0 -7
- package/types/plugins/enter/helpers/has-previous-block.d.ts +0 -6
- package/types/plugins/enter/helpers/index.d.ts +0 -3
- package/types/plugins/enter/helpers/insert-paragraph.d.ts +0 -7
- package/types/plugins/enter/helpers/move-cursor-out-from-specal-tags.d.ts +0 -6
- package/types/plugins/enter/helpers/process-empty-li-leaf.d.ts +0 -7
- package/types/plugins/enter/helpers/split-fragment.d.ts +0 -8
- package/types/plugins/enter/helpers/wrap-text.d.ts +0 -8
- package/types/plugins/error-messages/error-messages.d.ts +0 -14
- package/types/plugins/file/file.d.ts +0 -5
- package/types/plugins/focus/focus.d.ts +0 -5
- package/types/plugins/font/font.d.ts +0 -8
- package/types/plugins/format-block/format-block.d.ts +0 -8
- package/types/plugins/fullsize/config.d.ts +0 -22
- package/types/plugins/fullsize/fullsize.d.ts +0 -8
- package/types/plugins/hotkeys/config.d.ts +0 -3
- package/types/plugins/hotkeys/hotkeys.d.ts +0 -10
- package/types/plugins/hr/hr.d.ts +0 -5
- package/types/plugins/iframe/config.d.ts +0 -49
- package/types/plugins/iframe/iframe.d.ts +0 -9
- package/types/plugins/image/image.d.ts +0 -5
- package/types/plugins/image-processor/config.d.ts +0 -3
- package/types/plugins/image-processor/image-processor.d.ts +0 -8
- package/types/plugins/image-properties/config.d.ts +0 -42
- package/types/plugins/image-properties/image-properties.d.ts +0 -42
- package/types/plugins/image-properties/templates/form.d.ts +0 -3
- package/types/plugins/image-properties/templates/main-tab.d.ts +0 -3
- package/types/plugins/image-properties/templates/position-tab.d.ts +0 -3
- package/types/plugins/indent/config.d.ts +0 -3
- package/types/plugins/indent/helpers.d.ts +0 -4
- package/types/plugins/indent/indent.d.ts +0 -8
- package/types/plugins/index.d.ts +0 -5
- package/types/plugins/inline-popup/config/config.d.ts +0 -3
- package/types/plugins/inline-popup/config/items/a.d.ts +8 -0
- package/types/plugins/inline-popup/config/items/cells.d.ts +8 -0
- package/types/plugins/inline-popup/config/items/iframe.d.ts +8 -0
- package/types/plugins/inline-popup/config/items/img.d.ts +9 -0
- package/types/plugins/inline-popup/config/items/toolbar.d.ts +7 -0
- package/types/plugins/inline-popup/inline-popup.d.ts +0 -36
- package/types/plugins/justify/justify.d.ts +0 -8
- package/types/plugins/key-arrow-outside/key-arrow-outside.d.ts +0 -8
- package/types/plugins/limit/config.d.ts +0 -9
- package/types/plugins/limit/limit.d.ts +0 -22
- package/types/plugins/line-height/config.d.ts +0 -9
- package/types/plugins/line-height/langs/index.d.ts +25 -0
- package/types/plugins/line-height/line-height.d.ts +0 -5
- package/types/plugins/link/config.d.ts +0 -33
- package/types/plugins/link/link.d.ts +0 -11
- package/types/plugins/link/template.d.ts +0 -3
- package/types/plugins/media/config.d.ts +0 -9
- package/types/plugins/media/media.d.ts +0 -8
- package/types/plugins/mobile/config.d.ts +0 -6
- package/types/plugins/mobile/mobile.d.ts +0 -8
- package/types/plugins/ordered-list/ordered-list.d.ts +0 -8
- package/types/plugins/paste/config.d.ts +0 -19
- package/types/plugins/paste/helpers.d.ts +0 -12
- package/types/plugins/paste/interface.d.ts +0 -3
- package/types/plugins/paste/paste.d.ts +0 -31
- package/types/plugins/paste-from-word/config.d.ts +0 -21
- package/types/plugins/paste-from-word/paste-from-word.d.ts +0 -11
- package/types/plugins/paste-storage/paste-storage.d.ts +0 -8
- package/types/plugins/placeholder/config.d.ts +0 -31
- package/types/plugins/placeholder/placeholder.d.ts +0 -11
- package/types/plugins/powered-by-jodit/powered-by-jodit.d.ts +0 -8
- package/types/plugins/preview/preview.d.ts +0 -5
- package/types/plugins/print/lib/generate-critical-css.d.ts +0 -6
- package/types/plugins/print/print.d.ts +0 -5
- package/types/plugins/redo-undo/redo-undo.d.ts +0 -9
- package/types/plugins/resize-cells/resize-cells.d.ts +0 -42
- package/types/plugins/resize-handler/resize-handler.d.ts +0 -26
- package/types/plugins/resizer/config.d.ts +0 -31
- package/types/plugins/resizer/resizer.d.ts +0 -22
- package/types/plugins/search/config.d.ts +0 -21
- package/types/plugins/search/helpers/index.d.ts +0 -3
- package/types/plugins/search/helpers/sentence-finder.d.ts +0 -3
- package/types/plugins/search/helpers/wrap-ranges-texts-in-tmp-span.d.ts +0 -3
- package/types/plugins/search/search.d.ts +0 -22
- package/types/plugins/search/ui/search.d.ts +0 -6
- package/types/plugins/select/config.d.ts +0 -8
- package/types/plugins/select/select.d.ts +0 -19
- package/types/plugins/select-cells/select-cells.d.ts +0 -34
- package/types/plugins/size/size.d.ts +0 -27
- package/types/plugins/source/config.d.ts +0 -25
- package/types/plugins/source/editor/engines/ace.d.ts +0 -6
- package/types/plugins/source/editor/engines/area.d.ts +0 -3
- package/types/plugins/source/editor/engines/index.d.ts +0 -3
- package/types/plugins/source/editor/factory.d.ts +0 -3
- package/types/plugins/source/editor/sourceEditor.d.ts +0 -6
- package/types/plugins/source/source.d.ts +0 -17
- package/types/plugins/speech-recognize/config.d.ts +19 -0
- package/types/plugins/speech-recognize/constants.d.ts +7 -0
- package/types/plugins/speech-recognize/helpers/api.d.ts +7 -0
- package/types/plugins/speech-recognize/helpers/exec-spell-command.d.ts +7 -0
- package/types/plugins/speech-recognize/helpers/recognize-manager.d.ts +45 -0
- package/types/plugins/speech-recognize/helpers/sound.d.ts +11 -0
- package/types/plugins/speech-recognize/interface.d.ts +30 -0
- package/types/plugins/speech-recognize/langs/index.d.ts +25 -0
- package/types/plugins/speech-recognize/speech-recognize.d.ts +19 -0
- package/types/plugins/spellcheck/config.d.ts +0 -4
- package/types/plugins/spellcheck/langs/index.d.ts +25 -0
- package/types/plugins/spellcheck/spellcheck.d.ts +0 -5
- package/types/plugins/stat/stat.d.ts +0 -5
- package/types/plugins/sticky/config.d.ts +0 -19
- package/types/plugins/sticky/sticky.d.ts +0 -18
- package/types/plugins/symbols/langs/index.d.ts +25 -0
- package/types/plugins/symbols/symbols.d.ts +0 -11
- package/types/plugins/tab/cases/index.d.ts +0 -3
- package/types/plugins/tab/cases/on-tab-inside-li.d.ts +0 -8
- package/types/plugins/tab/config.d.ts +0 -3
- package/types/plugins/table/table.d.ts +0 -5
- package/types/plugins/table-keyboard-navigation/table-keyboard-navigation.d.ts +0 -8
- package/types/plugins/wrap-nodes/config.d.ts +0 -3
- package/types/plugins/xpath/xpath.d.ts +0 -5
- package/types/polyfills.d.ts +10 -0
- package/types/styles/icons/index.d.ts +0 -5
- package/types/types/core.d.ts +0 -3
- package/types/types/file-browser.d.ts +15 -0
- package/types/types/jodit.d.ts +1 -1
- package/types/types/storage.d.ts +0 -3
- package/types/types/traits.d.ts +2 -2
- package/types/types/types.d.ts +2 -2
- package/types/types/uploader.d.ts +1 -1
- package/src/modules/file-browser/__image_snapshots__/file-browser-test-screenshot-js-filebrowser-screenshot-testing-open-filebrowser-works-1-snap.png +0 -0
- package/src/modules/image-editor/__image_snapshots__/image-editor-test-screenshot-js-image-editor-screenshot-testing-open-image-editor-works-1-snap.png +0 -0
package/build/vdom.css
CHANGED
package/build/vdom.js
CHANGED
package/package.json
CHANGED
|
@@ -1,36 +1,39 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "jodit",
|
|
3
|
-
"version": "3.20.
|
|
3
|
+
"version": "3.20.3",
|
|
4
4
|
"description": "Jodit is awesome and usefully wysiwyg editor with filebrowser",
|
|
5
5
|
"main": "build/jodit.min.js",
|
|
6
6
|
"types": "./types/index.d.ts",
|
|
7
7
|
"scripts": {
|
|
8
|
-
"coverage": "npx type-coverage ./src --detail --ignore-files 'build/**' --ignore-files 'test/**' --ignore-files 'examples/**'",
|
|
9
|
-
"newversion": "npm run lint && npm run clean && npm test && npm version patch --no-git-tag-version && npm run build && npm run newversiongit && npm publish ./ && rm -rf types/",
|
|
10
|
-
"newversiongit": "git add --all && git commit -m \"New version $npm_package_version. Read more https://github.com/xdan/jodit/blob/master/CHANGELOG.md \" && git tag $npm_package_version && git push --tags origin HEAD:master",
|
|
11
8
|
"start": "node server.js --port=2000",
|
|
12
9
|
"clean": "rm -rf ./node_modules/.cache && rm -rf build/*",
|
|
13
|
-
"
|
|
14
|
-
"
|
|
15
|
-
"
|
|
16
|
-
"
|
|
17
|
-
"build
|
|
18
|
-
"build
|
|
19
|
-
"build
|
|
20
|
-
"build
|
|
21
|
-
"build
|
|
22
|
-
"
|
|
23
|
-
"
|
|
24
|
-
"test
|
|
25
|
-
"
|
|
26
|
-
"
|
|
27
|
-
"
|
|
10
|
+
"lint": "npm run type:check && eslint ./src/ ./test/ && stylelint ./src/**/**.less",
|
|
11
|
+
"coverage": "npx type-coverage ./src --detail --ignore-files 'build/**' --ignore-files 'test/**' --ignore-files 'examples/**'",
|
|
12
|
+
"newversion": "npm run lint && npm run clean && npm test && npm version patch --no-git-tag-version && npm run build && npm run newversion:git && npm publish ./ && rm -rf types/",
|
|
13
|
+
"newversion:git": "git add --all && git commit -m \"New version $npm_package_version. Read more https://github.com/xdan/jodit/blob/master/CHANGELOG.md \" && git tag $npm_package_version && git push --tags origin HEAD:master",
|
|
14
|
+
"build": "npm run clean && npm run type:build && npm run build:es5 && npm run build:es2018 && npm run build:es2018:en && npm run build:es5:no-uglify && npm run build:es2018:no-uglify && npm run build:es2018:en:no-uglify",
|
|
15
|
+
"build:es5": "webpack --progress --mode production --env es=es5 --env uglify=true",
|
|
16
|
+
"build:es5:no-uglify": "webpack --progress --mode production --env es=es5 --env uglify=false",
|
|
17
|
+
"build:es2018": "webpack --progress --mode production --env es=es2018 --env uglify=true",
|
|
18
|
+
"build:es2018:en": "webpack --progress --mode production --env es=es2018 --env excludeLangs=true --env uglify=true",
|
|
19
|
+
"build:es2018:no-uglify": "webpack --progress --mode production --env es=es2018 --env uglify=false",
|
|
20
|
+
"build:es2018:en:no-uglify": "webpack --progress --mode production --env es=es2018 --env excludeLangs=true --env uglify=false",
|
|
21
|
+
"test": "npm run test:find && npm run clean && npm run test:only-run",
|
|
22
|
+
"docker:screenshots:build": "docker build -t jodit-screenshots -f test/screenshots/Dockerfile .",
|
|
23
|
+
"docker:screenshots:run": "docker run -v $(pwd)/build:/app/build/ -v $(pwd)/test:/app/test/ -v $(pwd)/src:/app/src/ jodit-screenshots ./node_modules/.bin/mocha ./src/**/**.screenshot.js",
|
|
24
|
+
"docker:screenshots:run:es2018": "docker run -v $(pwd)/build:/app/build/ -v $(pwd)/test:/app/test/ -v $(pwd)/src:/app/src/ jodit-screenshots ./node_modules/.bin/mocha ./src/**/**.screenshot.js --build=es2018",
|
|
25
|
+
"docker:screenshots:update": "docker run -v $(pwd)/build:/app/build/ -v $(pwd)/test:/app/test/ -e SNAPSHOT_UPDATE=true -v $(pwd)/src:/app/src/ jodit-screenshots ./node_modules/.bin/mocha ./src/**/**.screenshot.js",
|
|
26
|
+
"test:find": "node ./build-system/utils/find-tests.js",
|
|
27
|
+
"test:debug": "karma start --browsers Chrome karma.conf.js --single-run false",
|
|
28
|
+
"test:chrome": "karma start --browsers Chrome karma.conf.js",
|
|
29
|
+
"test:only-run": "karma start --browsers FirefoxHeadless karma.conf.js",
|
|
28
30
|
"jodit": "cd ../jodit-react/ && npm update && npm run newversion && cd ../jodit-pro && npm run newversion && cd ../jodit-joomla && npm run newversion",
|
|
29
|
-
"types": "rm -rf types && mkdir -p ./types && cp -r ./src/types ./types && tsc --project . --declaration --declarationDir types --outDir types --emitDeclarationOnly --removeComments false",
|
|
30
31
|
"pretty": "npx prettier --write ./src/*.{ts,less} ./src/**/*.{ts,less} ./src/**/**/*.{ts,less} ./src/**/**/**/*.{ts,less} ./src/**/**/**/**/*.{ts,less}",
|
|
31
32
|
"fix": "npx eslint ./src/ ./test/ --fix && npm run pretty",
|
|
32
|
-
"type
|
|
33
|
-
"
|
|
33
|
+
"type:check": "tsc --noemit --noErrorTruncation",
|
|
34
|
+
"type:build": "rm -rf types && mkdir -p ./types && cp -r ./src/types ./types && tsc --project . --declaration --declarationDir types --outDir types --emitDeclarationOnly --removeComments false && npm run type:remove-styles && npm run type:resolve-alias",
|
|
35
|
+
"type:resolve-alias": "tsc-alias -p tsconfig.json ./types",
|
|
36
|
+
"type:remove-styles": "replace \"import .+.(less|svg)';\" '' ./types -r --include='*.d.ts'"
|
|
34
37
|
},
|
|
35
38
|
"repository": {
|
|
36
39
|
"type": "git",
|
|
@@ -60,8 +63,7 @@
|
|
|
60
63
|
"homepage": "https://xdsoft.net/jodit/",
|
|
61
64
|
"dependencies": {
|
|
62
65
|
"autobind-decorator": "^2.4.0",
|
|
63
|
-
"core-js": "^3.24.1"
|
|
64
|
-
"nock-puppeteer": "^14.4.1"
|
|
66
|
+
"core-js": "^3.24.1"
|
|
65
67
|
},
|
|
66
68
|
"devDependencies": {
|
|
67
69
|
"@types/ace": "^0.0.48",
|
|
@@ -111,6 +113,7 @@
|
|
|
111
113
|
"prettier": "^2.7.1",
|
|
112
114
|
"puppeteer": "^17.0.0",
|
|
113
115
|
"raw-loader": "^4.0.2",
|
|
116
|
+
"replace": "^1.2.1",
|
|
114
117
|
"style-loader": "^3.3.1",
|
|
115
118
|
"stylelint": "^14.10.0",
|
|
116
119
|
"stylelint-config-idiomatic-order": "v8.1.0",
|
|
@@ -121,6 +124,7 @@
|
|
|
121
124
|
"terser-webpack-plugin": "^5.3.4",
|
|
122
125
|
"ts-loader": "^9.3.1",
|
|
123
126
|
"ts-private-uglifier": "^1.0.2",
|
|
127
|
+
"tsc-alias": "^1.7.0",
|
|
124
128
|
"tslib": "^2.4.0",
|
|
125
129
|
"typescript": "^4.8.2",
|
|
126
130
|
"url-loader": "^4.1.1",
|
package/src/README.md
CHANGED
package/src/core/async/README.md
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
# Create DOM module
|
|
2
|
+
|
|
1
3
|
Every internal DOM node of both the editor interface and the editor content itself must be created through this module.
|
|
2
4
|
This is due to the fact that the interface can be shown in an iframe, or another window.
|
|
3
5
|
And in this case, you need to create its elements using the document from this window.
|
package/src/core/dom/README.md
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
# Jodit plugin system
|
|
2
|
+
|
|
1
3
|
Jodit plugins are designed to extend the basic functionality of the editor.
|
|
2
4
|
There are built-in plugins, without which the editor will not work correctly. There are plugins that add completely new functionality.
|
|
3
5
|
You can write your own plugin that will either change the current behavior of the editor or add a new function.
|
package/src/core/vdom/README.md
CHANGED
package/src/core/view/README.md
CHANGED
package/src/index.ts
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* @module jodit
|
|
11
11
|
*/
|
|
12
12
|
|
|
13
|
-
import './styles';
|
|
13
|
+
import './styles/index.less';
|
|
14
14
|
|
|
15
15
|
declare function require(moduleName: string): any;
|
|
16
16
|
|
|
@@ -47,18 +47,21 @@ Object.keys(Icons)
|
|
|
47
47
|
Object.keys(Modules)
|
|
48
48
|
.filter(esFilter)
|
|
49
49
|
.forEach((key: string) => {
|
|
50
|
-
|
|
50
|
+
// @ts-ignore
|
|
51
|
+
DefaultJodit.modules[key] = Modules[key];
|
|
51
52
|
});
|
|
52
53
|
|
|
53
54
|
// Decorators
|
|
54
55
|
Object.keys(decorators)
|
|
55
56
|
.filter(esFilter)
|
|
56
57
|
.forEach((key: string) => {
|
|
57
|
-
|
|
58
|
+
// @ts-ignore
|
|
59
|
+
DefaultJodit.decorators[key] = decorators[key];
|
|
58
60
|
});
|
|
59
61
|
|
|
60
62
|
['Confirm', 'Alert', 'Prompt'].forEach((key: string) => {
|
|
61
|
-
|
|
63
|
+
// @ts-ignore
|
|
64
|
+
DefaultJodit[key] = Modules[key];
|
|
62
65
|
});
|
|
63
66
|
|
|
64
67
|
// Languages
|
package/src/jodit.ts
CHANGED
|
@@ -30,6 +30,8 @@ import type {
|
|
|
30
30
|
IHistory
|
|
31
31
|
} from './types';
|
|
32
32
|
|
|
33
|
+
import type * as Modules from './modules/';
|
|
34
|
+
|
|
33
35
|
import { Config } from './config';
|
|
34
36
|
import * as constants from './core/constants';
|
|
35
37
|
|
|
@@ -180,8 +182,8 @@ export class Jodit extends ViewWithToolbar implements IJodit, Dlgs {
|
|
|
180
182
|
|
|
181
183
|
static readonly plugins: IPluginSystem = pluginSystem;
|
|
182
184
|
|
|
183
|
-
static
|
|
184
|
-
static
|
|
185
|
+
static modules: typeof Modules = modules as unknown as typeof Modules;
|
|
186
|
+
static ns: typeof Modules = modules as unknown as typeof Modules;
|
|
185
187
|
|
|
186
188
|
static readonly decorators: IDictionary<Function> = {};
|
|
187
189
|
static readonly constants: typeof constants = constants;
|
package/src/langs/index.ts
CHANGED
|
@@ -19,6 +19,7 @@ if (!process.env.EXCLUDE_LANGS) {
|
|
|
19
19
|
const ar = require('jodit/langs/ar');
|
|
20
20
|
const cs_cz = require('jodit/langs/cs_cz');
|
|
21
21
|
const de = require('jodit/langs/de');
|
|
22
|
+
const en = require('jodit/langs/en');
|
|
22
23
|
const es = require('jodit/langs/es');
|
|
23
24
|
const fr = require('jodit/langs/fr');
|
|
24
25
|
const he = require('jodit/langs/he');
|
|
@@ -39,6 +40,7 @@ if (!process.env.EXCLUDE_LANGS) {
|
|
|
39
40
|
ar,
|
|
40
41
|
cs_cz,
|
|
41
42
|
de,
|
|
43
|
+
en,
|
|
42
44
|
es,
|
|
43
45
|
fr,
|
|
44
46
|
he,
|
|
@@ -57,16 +59,15 @@ if (!process.env.EXCLUDE_LANGS) {
|
|
|
57
59
|
};
|
|
58
60
|
}
|
|
59
61
|
|
|
60
|
-
const
|
|
61
|
-
exp.en = en;
|
|
62
|
+
const keys = require('jodit/langs/keys');
|
|
62
63
|
|
|
63
64
|
/* Unpack array to hash */
|
|
64
65
|
const get = (value: IDictionary): IDictionary =>
|
|
65
66
|
value ? value.default || value : {},
|
|
66
67
|
hashLang: IDictionary = {};
|
|
67
68
|
|
|
68
|
-
if (isArray(get(
|
|
69
|
-
get(
|
|
69
|
+
if (isArray(get(keys))) {
|
|
70
|
+
get(keys).forEach((key: string, index: number) => {
|
|
70
71
|
hashLang[index] = key;
|
|
71
72
|
});
|
|
72
73
|
}
|
|
@@ -80,6 +81,8 @@ Object.keys(exp).forEach((lang: string) => {
|
|
|
80
81
|
list.forEach((value: string, index: number) => {
|
|
81
82
|
exp[lang][hashLang[index]] = value;
|
|
82
83
|
});
|
|
84
|
+
} else {
|
|
85
|
+
exp[lang] = list as IDictionary;
|
|
83
86
|
}
|
|
84
87
|
});
|
|
85
88
|
|
package/src/modules/README.md
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Jodit modules
|
|
1
|
+
# Jodit modules
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
# Jodit filebrowser
|
|
2
|
+
|
|
1
3
|
Module for working with remote images or just files. Allows you to upload / delete / rename files on the server.
|
|
2
4
|
|
|
3
5
|
> A prerequisite for the module to work is the server side. Jodit offers its own implementation in php [jodit-connectors](https://github.com/xdan/jodit-connectors). The module will not work without the server side.
|
|
@@ -276,10 +278,16 @@ const options = {
|
|
|
276
278
|
create: {
|
|
277
279
|
data: { action: 'folderCreate' }
|
|
278
280
|
},
|
|
279
|
-
|
|
281
|
+
fileMove: {
|
|
280
282
|
data: { action: 'fileMove' }
|
|
281
283
|
},
|
|
282
|
-
|
|
284
|
+
fileFolder: {
|
|
285
|
+
data: { action: 'fileFolder' }
|
|
286
|
+
},
|
|
287
|
+
folderRename: {
|
|
288
|
+
data: { action: 'folderRename' }
|
|
289
|
+
},
|
|
290
|
+
fileRemove: {
|
|
283
291
|
data: { action: 'fileRemove' }
|
|
284
292
|
},
|
|
285
293
|
items: {
|
|
@@ -339,10 +347,10 @@ var editor = Jodit.make('#jodit', {
|
|
|
339
347
|
create: {
|
|
340
348
|
url: 'connector/create.php'
|
|
341
349
|
},
|
|
342
|
-
|
|
350
|
+
fileMove: {
|
|
343
351
|
url: 'connector/move.php'
|
|
344
352
|
},
|
|
345
|
-
|
|
353
|
+
fileRemove: {
|
|
346
354
|
url: 'connector/remove.php'
|
|
347
355
|
},
|
|
348
356
|
items: {
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Copyright (c) 2013-2022 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
-
require('../../../test/bootstrap.screenshot.js');
|
|
7
|
+
require('../../../test/screenshots/bootstrap.screenshot.js');
|
|
8
8
|
const expect = require('expect');
|
|
9
9
|
|
|
10
10
|
describe('Filebrowser screenshot testing', () => {
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Copyright (c) 2013-2022 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
-
require('../../../test/bootstrap.screenshot.js');
|
|
7
|
+
require('../../../test/screenshots/bootstrap.screenshot.js');
|
|
8
8
|
const expect = require('expect');
|
|
9
9
|
|
|
10
10
|
describe('Image editor screenshot testing', () => {
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
3
|
+
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
|
+
* Copyright (c) 2013-2022 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
require('../../../test/screenshots/bootstrap.screenshot.js');
|
|
8
|
+
const expect = require('expect');
|
|
9
|
+
|
|
10
|
+
describe('Color picker screenshot testing', () => {
|
|
11
|
+
describe('Open color picker', () => {
|
|
12
|
+
it('works', async function () {
|
|
13
|
+
await page.evaluate(() => {
|
|
14
|
+
return clickButton('brush', editor);
|
|
15
|
+
});
|
|
16
|
+
|
|
17
|
+
await page.waitForSelector('[role="popup"]');
|
|
18
|
+
await page.evaluate(() => editor.async.requestIdlePromise());
|
|
19
|
+
const element = await page.$(
|
|
20
|
+
'[role="popup"] .jodit-popup__content'
|
|
21
|
+
);
|
|
22
|
+
const screenshot = await element.screenshot();
|
|
23
|
+
expect(screenshot).toMatchImageSnapshot(this);
|
|
24
|
+
}).timeout(10000);
|
|
25
|
+
});
|
|
26
|
+
});
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Jodit Editor (https://xdsoft.net/jodit/)
|
|
3
|
+
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
|
+
* Copyright (c) 2013-2022 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
require('../../../test/screenshots/bootstrap.screenshot.js');
|
|
8
|
+
const expect = require('expect');
|
|
9
|
+
|
|
10
|
+
describe('Image properties screenshot testing', () => {
|
|
11
|
+
describe('Open image properties', () => {
|
|
12
|
+
it('works', async function () {
|
|
13
|
+
await page.evaluate(() => {
|
|
14
|
+
editor.value =
|
|
15
|
+
'<p><img src="https://xdsoft.net/jodit/files/artio.jpg" /></p>';
|
|
16
|
+
simulateEvent('dblclick', editor.editor.querySelector('img'));
|
|
17
|
+
});
|
|
18
|
+
|
|
19
|
+
await page.waitForSelector('[role="dialog"]');
|
|
20
|
+
const element = await page.$(
|
|
21
|
+
'[role="dialog"] .jodit-dialog__panel'
|
|
22
|
+
);
|
|
23
|
+
const screenshot = await element.screenshot();
|
|
24
|
+
expect(screenshot).toMatchImageSnapshot(this);
|
|
25
|
+
}).timeout(10000);
|
|
26
|
+
});
|
|
27
|
+
});
|