From a185b585ae5abb16b69b4f384a2e708a43968f79 Mon Sep 17 00:00:00 2001 From: Filip Sobol Date: Fri, 10 Jan 2025 13:45:40 +0100 Subject: [PATCH 1/8] Move icons to the `@ckeditor/ckeditor5-icons` package --- .../contributing/package-metadata.md | 2 +- package.json | 1 + .../tsconfig.dist.json | 5 +- .../ckeditor5-adapter-ckfinder/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../ckeditor5-alignment/tests/alignmentui.js | 13 +- .../ckeditor5-alignment/tsconfig.dist.json | 5 +- packages/ckeditor5-alignment/tsconfig.json | 3 +- .../ckeditor5-autoformat/tsconfig.dist.json | 5 +- packages/ckeditor5-autoformat/tsconfig.json | 3 +- .../ckeditor5-autosave/tsconfig.dist.json | 5 +- packages/ckeditor5-autosave/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 14 +- .../ckeditor5-basic-styles/src/code/codeui.ts | 5 +- .../src/italic/italicui.ts | 5 +- .../src/strikethrough/strikethroughui.ts | 5 +- .../src/subscript/subscriptui.ts | 5 +- .../src/superscript/superscriptui.ts | 5 +- .../src/underline/underlineui.ts | 5 +- .../ckeditor5-basic-styles/tsconfig.dist.json | 5 +- packages/ckeditor5-basic-styles/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../ckeditor5-block-quote/tsconfig.dist.json | 5 +- packages/ckeditor5-block-quote/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../ckeditor5-bookmark/tsconfig.dist.json | 5 +- packages/ckeditor5-bookmark/tsconfig.json | 3 +- .../tsconfig.json | 3 +- .../tsconfig.types.json | 3 +- .../ckeditor5-build-balloon/tsconfig.json | 3 +- .../tsconfig.types.json | 3 +- .../ckeditor5-build-classic/tsconfig.json | 3 +- .../tsconfig.types.json | 3 +- .../tsconfig.json | 3 +- .../tsconfig.types.json | 3 +- packages/ckeditor5-build-inline/tsconfig.json | 3 +- .../tsconfig.types.json | 3 +- .../ckeditor5-build-multi-root/tsconfig.json | 3 +- .../tsconfig.types.json | 3 +- .../ckeditor5-ckbox/ckeditor5-metadata.json | 4 +- .../src/ckboximageedit/ckboximageeditui.ts | 5 +- packages/ckeditor5-ckbox/tsconfig.dist.json | 5 +- packages/ckeditor5-ckbox/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../ckeditor5-ckfinder/tsconfig.dist.json | 5 +- packages/ckeditor5-ckfinder/tsconfig.json | 3 +- .../ckeditor5-clipboard/tsconfig.dist.json | 5 +- packages/ckeditor5-clipboard/tsconfig.json | 3 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-cloud-services/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../ckeditor5-code-block/tsconfig.dist.json | 5 +- packages/ckeditor5-code-block/tsconfig.json | 3 +- packages/ckeditor5-core/package.json | 1 - packages/ckeditor5-core/src/index.ts | 167 ------------------ packages/ckeditor5-core/tsconfig.dist.json | 5 +- packages/ckeditor5-core/tsconfig.json | 3 +- .../ckeditor5-easy-image/tsconfig.dist.json | 5 +- packages/ckeditor5-easy-image/tsconfig.json | 3 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-editor-balloon/tsconfig.json | 3 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-editor-classic/tsconfig.json | 3 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-editor-decoupled/tsconfig.json | 3 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-editor-inline/tsconfig.json | 3 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-editor-multi-root/tsconfig.json | 3 +- packages/ckeditor5-engine/tsconfig.dist.json | 5 +- packages/ckeditor5-engine/tsconfig.json | 3 +- packages/ckeditor5-enter/tsconfig.dist.json | 5 +- packages/ckeditor5-enter/tsconfig.json | 3 +- .../ckeditor5-essentials/tsconfig.dist.json | 5 +- packages/ckeditor5-essentials/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../src/findandreplaceui.ts | 8 +- .../tests/findandreplaceui.js | 6 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-find-and-replace/tsconfig.json | 3 +- .../ckeditor5-font/ckeditor5-metadata.json | 8 +- .../fontbackgroundcolorui.ts | 5 +- .../src/fontcolor/fontcolorui.ts | 5 +- .../src/fontfamily/fontfamilyui.ts | 7 +- .../ckeditor5-font/src/fontsize/fontsizeui.ts | 7 +- .../fontbackgroundcolorui.js | 4 +- .../tests/fontcolor/fontcolorui.js | 4 +- .../tests/fontfamily/fontfamilyui.js | 7 +- .../tests/fontsize/fontsizeui.js | 7 +- packages/ckeditor5-font/tsconfig.dist.json | 5 +- packages/ckeditor5-font/tsconfig.json | 3 +- packages/ckeditor5-heading/tsconfig.dist.json | 5 +- packages/ckeditor5-heading/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../ckeditor5-highlight/src/highlightui.ts | 11 +- .../ckeditor5-highlight/tests/highlightui.js | 29 ++- .../ckeditor5-highlight/tsconfig.dist.json | 5 +- packages/ckeditor5-highlight/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-horizontal-line/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../ckeditor5-html-embed/tsconfig.dist.json | 5 +- packages/ckeditor5-html-embed/tsconfig.json | 3 +- .../ckeditor5-html-support/tsconfig.dist.json | 5 +- packages/ckeditor5-html-support/tsconfig.json | 3 +- packages/ckeditor5-icons/CHANGELOG.md | 4 + packages/ckeditor5-icons/CONTRIBUTING.md | 4 + packages/ckeditor5-icons/LICENSE.md | 26 +++ packages/ckeditor5-icons/README.md | 29 +++ packages/ckeditor5-icons/package.json | 40 +++++ packages/ckeditor5-icons/src/index.ts | 155 ++++++++++++++++ .../theme}/accessibility.svg | 0 .../ckeditor5-icons/theme/add-comment.svg | 11 ++ .../theme}/align-bottom.svg | 0 .../theme}/align-center.svg | 0 .../theme}/align-justify.svg | 0 .../theme}/align-left.svg | 0 .../theme}/align-middle.svg | 0 .../theme}/align-right.svg | 0 .../theme}/align-top.svg | 0 packages/ckeditor5-icons/theme/arrow-down.svg | 1 + packages/ckeditor5-icons/theme/arrow-up.svg | 1 + .../icons => ckeditor5-icons/theme}/bold.svg | 0 .../theme/bookmark-inline.svg} | 0 .../theme}/bookmark.svg | 0 .../theme}/browse-files.svg | 0 .../theme/bulleted-list.svg} | 0 .../theme}/cancel.svg | 0 .../theme}/caption.svg | 0 .../ckeditor5-icons/theme/case-change.svg | 1 + .../icons => ckeditor5-icons/theme}/check.svg | 0 .../ckeditor5-icons/theme/chevron-down.svg | 1 + packages/ckeditor5-icons/theme/chevron-up.svg | 1 + .../theme}/ckbox-image-edit.svg | 0 .../theme/code-block.svg} | 0 .../icons => ckeditor5-icons/theme}/code.svg | 0 .../icons => ckeditor5-icons/theme}/cog.svg | 0 .../theme}/color-palette.svg | 0 .../theme}/color-tile-check.svg | 0 .../theme/comments-archive.svg | 11 ++ .../theme/content-lock.svg} | 0 .../theme/content-unlock.svg} | 0 packages/ckeditor5-icons/theme/copy.svg | 1 + .../theme}/drag-handle.svg | 0 .../theme}/drag-indicator.svg | 0 .../theme}/dropdown-arrow.svg | 0 .../ckeditor5-icons/theme/edit-comment.svg | 11 ++ .../theme}/eraser.svg | 0 packages/ckeditor5-icons/theme/error.svg | 1 + packages/ckeditor5-icons/theme/export-pdf.svg | 1 + .../ckeditor5-icons/theme/export-word.svg | 1 + .../theme}/find-replace.svg | 0 .../theme}/font-background.svg | 0 .../theme}/font-color.svg | 0 .../theme}/font-family.svg | 0 .../theme}/font-size.svg | 0 .../theme}/heading1.svg | 0 .../theme}/heading2.svg | 0 .../theme}/heading3.svg | 0 .../theme}/heading4.svg | 0 .../theme}/heading5.svg | 0 .../theme}/heading6.svg | 0 .../theme}/history.svg | 0 .../theme/horizontal-line.svg} | 0 .../icons => ckeditor5-icons/theme}/html.svg | 0 .../theme}/image-asset-manager.svg | 0 .../theme}/image-upload.svg | 0 .../theme}/image-url.svg | 0 .../icons => ckeditor5-icons/theme}/image.svg | 0 .../theme/import-export.svg} | 0 packages/ckeditor5-icons/theme/importword.svg | 1 + .../theme}/indent.svg | 0 .../theme/insert-merge-field.svg | 7 + .../theme}/italic.svg | 0 .../theme/legal-style-list.svg | 1 + .../icons => ckeditor5-icons/theme}/link.svg | 0 .../theme/list-style-circle.svg} | 0 .../list-style-decimal-leading-zero.svg} | 0 .../theme/list-style-decimal.svg} | 0 .../theme/list-style-disc.svg} | 0 .../theme/list-style-lower-latin.svg} | 0 .../theme/list-style-lower-roman.svg} | 0 .../theme/list-style-square.svg} | 0 .../theme/list-style-upper-latin.svg} | 0 .../theme/list-style-upper-roman.svg} | 0 .../icons => ckeditor5-icons/theme}/loupe.svg | 0 .../theme}/low-vision.svg | 0 packages/ckeditor5-icons/theme/magic-wand.svg | 1 + .../theme}/marker.svg | 0 .../theme}/media-placeholder.svg | 0 .../icons => ckeditor5-icons/theme}/media.svg | 0 .../theme/multi-level-list.svg | 1 + .../theme}/next-arrow.svg | 0 .../ckeditor5-icons/theme/notification.svg | 11 ++ .../theme/numbered-list.svg} | 0 .../theme}/object-center.svg | 0 .../theme}/object-full-width.svg | 0 .../theme}/object-inline-left.svg | 0 .../theme}/object-inline-right.svg | 0 .../theme}/object-inline.svg | 0 .../theme}/object-left.svg | 0 .../theme}/object-right.svg | 0 .../theme}/object-size-custom.svg | 0 .../theme}/object-size-full.svg | 0 .../theme}/object-size-large.svg | 0 .../theme}/object-size-medium.svg | 0 .../theme}/object-size-small.svg | 0 .../theme}/outdent.svg | 0 .../theme/page-break.svg} | 0 .../theme/pagination-example.svg | 1 + .../theme/paint-roller-cursor-default.svg | 17 ++ .../theme/paint-roller-cursor-text.svg | 7 + .../ckeditor5-icons/theme/paint-roller.svg | 1 + .../theme}/paragraph.svg | 0 .../icons => ckeditor5-icons/theme}/pen.svg | 0 .../theme}/pencil.svg | 0 .../theme}/pilcrow.svg | 0 packages/ckeditor5-icons/theme/play.svg | 1 + .../icons => ckeditor5-icons/theme}/plus.svg | 0 .../theme/preview-merge-fields.svg | 8 + .../theme}/previous-arrow.svg | 0 packages/ckeditor5-icons/theme/print.svg | 1 + .../theme}/project-logo.svg | 0 .../icons => ckeditor5-icons/theme}/quote.svg | 0 .../icons => ckeditor5-icons/theme}/redo.svg | 0 .../ckeditor5-icons/theme/remove-comment.svg | 11 ++ .../theme}/remove-format.svg | 0 .../theme}/remove.svg | 0 .../theme}/return-arrow.svg | 0 .../theme/revision-history.svg | 1 + .../ckeditor5-icons/theme/robot-pencil.svg | 1 + .../theme}/select-all.svg | 0 .../theme}/show-blocks.svg | 0 .../theme}/source-editing.svg | 0 .../theme/special-characters.svg} | 0 .../theme}/strikethrough.svg | 0 packages/ckeditor5-icons/theme/submit.svg | 1 + .../theme}/subscript.svg | 0 .../theme}/superscript.svg | 0 .../theme}/table-cell-properties.svg | 0 .../theme}/table-column.svg | 0 .../theme}/table-merge-cell.svg | 0 .../theme/table-of-contents.svg | 1 + .../theme}/table-properties.svg | 0 .../theme}/table-row.svg | 0 .../icons => ckeditor5-icons/theme}/table.svg | 0 .../theme/template-generic.svg | 6 + packages/ckeditor5-icons/theme/template.svg | 1 + .../theme}/text-alternative.svg | 0 .../icons => ckeditor5-icons/theme}/text.svg | 0 .../theme}/three-vertical-dots.svg | 0 .../theme/todo-list.svg} | 0 .../theme/track-changes-accept.svg | 11 ++ .../theme/track-changes-discard.svg | 11 ++ .../ckeditor5-icons/theme/track-changes.svg | 11 ++ .../theme}/twitter.svg | 0 .../theme}/underline.svg | 0 .../icons => ckeditor5-icons/theme}/undo.svg | 0 .../theme}/unlink.svg | 0 packages/ckeditor5-icons/theme/user.svg | 1 + packages/ckeditor5-icons/theme/warning.svg | 3 + packages/ckeditor5-icons/tsconfig.dist.json | 9 + packages/ckeditor5-icons/tsconfig.json | 9 + .../ckeditor5-image/ckeditor5-metadata.json | 18 +- .../tests/imageresize/imageresizebuttons.js | 19 +- packages/ckeditor5-image/tsconfig.dist.json | 5 +- packages/ckeditor5-image/tsconfig.json | 3 +- .../ckeditor5-indent/ckeditor5-metadata.json | 4 +- packages/ckeditor5-indent/tsconfig.dist.json | 5 +- packages/ckeditor5-indent/tsconfig.json | 3 +- .../ckeditor5-language/tsconfig.dist.json | 5 +- packages/ckeditor5-language/tsconfig.json | 3 +- .../ckeditor5-link/ckeditor5-metadata.json | 4 +- packages/ckeditor5-link/src/linkimageui.ts | 5 +- packages/ckeditor5-link/src/linkui.ts | 5 +- .../ckeditor5-link/src/ui/linkactionsview.ts | 7 +- packages/ckeditor5-link/tests/linkui.js | 5 +- packages/ckeditor5-link/tsconfig.dist.json | 5 +- packages/ckeditor5-link/tsconfig.json | 3 +- .../ckeditor5-list/ckeditor5-metadata.json | 12 +- .../src/listproperties/listpropertiesui.ts | 50 +++--- .../tests/listproperties/listpropertiesui.js | 57 +++--- packages/ckeditor5-list/tsconfig.dist.json | 5 +- packages/ckeditor5-list/tsconfig.json | 3 +- .../ckeditor5-markdown-gfm/tsconfig.dist.json | 5 +- packages/ckeditor5-markdown-gfm/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../ckeditor5-media-embed/src/mediaembedui.ts | 4 +- .../src/mediaregistry.ts | 8 +- .../tests/mediaembedui.js | 4 +- .../ckeditor5-media-embed/tsconfig.dist.json | 5 +- packages/ckeditor5-media-embed/tsconfig.json | 3 +- packages/ckeditor5-mention/tsconfig.dist.json | 5 +- packages/ckeditor5-mention/tsconfig.json | 3 +- packages/ckeditor5-minimap/tsconfig.dist.json | 5 +- packages/ckeditor5-minimap/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../ckeditor5-page-break/src/pagebreakui.ts | 5 +- .../ckeditor5-page-break/tests/pagebreakui.js | 5 +- .../ckeditor5-page-break/tsconfig.dist.json | 5 +- packages/ckeditor5-page-break/tsconfig.json | 3 +- .../tests/paragraphbuttonui.js | 4 +- .../ckeditor5-paragraph/tsconfig.dist.json | 5 +- packages/ckeditor5-paragraph/tsconfig.json | 3 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-paste-from-office/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- packages/ckeditor5-remove-format/package.json | 1 - .../src/removeformatui.ts | 5 +- .../tests/removeformatui.js | 5 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-remove-format/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 4 +- .../src/restrictededitingmodeui.ts | 7 +- .../src/standardeditingmodeui.ts | 5 +- .../tests/restrictededitingmodeui.js | 6 +- .../tests/standardeditingmodeui.js | 5 +- .../tsconfig.dist.json | 5 +- .../tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- packages/ckeditor5-select-all/package.json | 1 - .../ckeditor5-select-all/src/selectallui.ts | 5 +- .../ckeditor5-select-all/tsconfig.dist.json | 5 +- packages/ckeditor5-select-all/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../ckeditor5-show-blocks/src/showblocksui.ts | 4 +- .../tests/showblocksui.js | 5 +- .../ckeditor5-show-blocks/tsconfig.dist.json | 5 +- packages/ckeditor5-show-blocks/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../src/sourceediting.ts | 6 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-source-editing/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../src/specialcharacters.ts | 5 +- .../tests/specialcharacters.js | 4 +- .../tsconfig.dist.json | 5 +- .../tsconfig.json | 3 +- packages/ckeditor5-style/tsconfig.dist.json | 5 +- packages/ckeditor5-style/tsconfig.json | 3 +- .../ckeditor5-table/ckeditor5-metadata.json | 12 +- .../tablecellpropertiesui.ts | 5 +- .../src/tableproperties/tablepropertiesui.ts | 6 +- packages/ckeditor5-table/src/tableui.ts | 16 +- packages/ckeditor5-table/tsconfig.dist.json | 5 +- packages/ckeditor5-table/tsconfig.json | 3 +- .../tests/manual/iconset.js | 105 +---------- .../tests/manual/theme.js | 78 ++++---- packages/ckeditor5-typing/tsconfig.dist.json | 5 +- packages/ckeditor5-typing/tsconfig.json | 3 +- packages/ckeditor5-ui/ckeditor5-metadata.json | 2 +- .../src/collapsible/collapsibleview.ts | 8 +- .../src/colorgrid/colortileview.ts | 8 +- .../src/dropdown/button/dropdownbuttonview.ts | 5 +- .../src/dropdown/button/splitbuttonview.ts | 16 +- .../dropdown/menu/dropdownmenubuttonview.ts | 5 +- .../accessibilityhelp/accessibilityhelp.ts | 6 +- .../ckeditor5-ui/src/editorui/poweredby.ts | 7 +- .../src/menubar/menubarmenubuttonview.ts | 5 +- .../tests/collapsible/collapsibleview.js | 4 +- .../tests/colorgrid/colortileview.js | 4 +- .../tests/colorselector/colorselectorview.js | 11 +- packages/ckeditor5-ui/tests/dialog/dialog.js | 4 +- .../ckeditor5-ui/tests/dialog/dialogview.js | 4 +- .../dropdown/menu/dropdownmenubuttonview.js | 4 +- .../tests/formheader/formheaderview.js | 7 +- .../tests/manual/dropdown/dropdown.js | 9 +- .../tests/manual/tickets/9412/1.js | 4 +- .../tests/menubar/menubarmenubuttonview.js | 4 +- packages/ckeditor5-ui/tsconfig.dist.json | 5 +- packages/ckeditor5-ui/tsconfig.json | 3 +- .../ckeditor5-undo/ckeditor5-metadata.json | 4 +- packages/ckeditor5-undo/tsconfig.dist.json | 5 +- packages/ckeditor5-undo/tsconfig.json | 3 +- packages/ckeditor5-upload/tsconfig.dist.json | 5 +- packages/ckeditor5-upload/tsconfig.json | 3 +- packages/ckeditor5-utils/tsconfig.dist.json | 5 +- packages/ckeditor5-utils/tsconfig.json | 3 +- .../ckeditor5-watchdog/tsconfig.dist.json | 5 +- packages/ckeditor5-watchdog/tsconfig.json | 3 +- packages/ckeditor5-widget/src/utils.ts | 5 +- .../src/widgettypearound/widgettypearound.ts | 6 +- packages/ckeditor5-widget/tsconfig.dist.json | 5 +- packages/ckeditor5-widget/tsconfig.json | 3 +- .../ckeditor5-word-count/tsconfig.dist.json | 5 +- packages/ckeditor5-word-count/tsconfig.json | 3 +- scripts/clean-up-svg-icons.mjs | 2 +- scripts/collect-svg-icons.mjs | 2 +- scripts/dll/webpack.config.dll.mjs | 2 + .../ckeditor5-metadata.json | 4 +- .../ckeditor5-metadata.json | 2 +- typings/types.d.ts => src/icons.ts | 9 +- src/index.ts | 1 + tsconfig.dist.ckeditor5.json | 5 +- tsconfig.dll.json | 5 +- tsconfig.docs.json | 1 - tsconfig.json | 5 +- tsconfig.release-ckeditor5.json | 3 +- tsconfig.test.json | 1 - tsconfig.typedoc.json | 3 +- 401 files changed, 923 insertions(+), 1064 deletions(-) create mode 100644 packages/ckeditor5-icons/CHANGELOG.md create mode 100644 packages/ckeditor5-icons/CONTRIBUTING.md create mode 100644 packages/ckeditor5-icons/LICENSE.md create mode 100644 packages/ckeditor5-icons/README.md create mode 100644 packages/ckeditor5-icons/package.json create mode 100644 packages/ckeditor5-icons/src/index.ts rename packages/{ckeditor5-ui/theme/icons => ckeditor5-icons/theme}/accessibility.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/add-comment.svg rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/align-bottom.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/align-center.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/align-justify.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/align-left.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/align-middle.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/align-right.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/align-top.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/arrow-down.svg create mode 100644 packages/ckeditor5-icons/theme/arrow-up.svg rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/bold.svg (100%) rename packages/{ckeditor5-core/theme/icons/bookmark_inline.svg => ckeditor5-icons/theme/bookmark-inline.svg} (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/bookmark.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/browse-files.svg (100%) rename packages/{ckeditor5-core/theme/icons/bulletedlist.svg => ckeditor5-icons/theme/bulleted-list.svg} (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/cancel.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/caption.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/case-change.svg rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/check.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/chevron-down.svg create mode 100644 packages/ckeditor5-icons/theme/chevron-up.svg rename packages/{ckeditor5-ckbox/theme/icons => ckeditor5-icons/theme}/ckbox-image-edit.svg (100%) rename packages/{ckeditor5-core/theme/icons/codeblock.svg => ckeditor5-icons/theme/code-block.svg} (100%) rename packages/{ckeditor5-basic-styles/theme/icons => ckeditor5-icons/theme}/code.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/cog.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/color-palette.svg (100%) rename packages/{ckeditor5-ui/theme/icons => ckeditor5-icons/theme}/color-tile-check.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/comments-archive.svg rename packages/{ckeditor5-restricted-editing/theme/icons/contentlock.svg => ckeditor5-icons/theme/content-lock.svg} (100%) rename packages/{ckeditor5-restricted-editing/theme/icons/contentunlock.svg => ckeditor5-icons/theme/content-unlock.svg} (100%) create mode 100644 packages/ckeditor5-icons/theme/copy.svg rename packages/{ckeditor5-widget/theme/icons => ckeditor5-icons/theme}/drag-handle.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/drag-indicator.svg (100%) rename packages/{ckeditor5-ui/theme/icons => ckeditor5-icons/theme}/dropdown-arrow.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/edit-comment.svg rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/eraser.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/error.svg create mode 100644 packages/ckeditor5-icons/theme/export-pdf.svg create mode 100644 packages/ckeditor5-icons/theme/export-word.svg rename packages/{ckeditor5-find-and-replace/theme/icons => ckeditor5-icons/theme}/find-replace.svg (100%) rename packages/{ckeditor5-font/theme/icons => ckeditor5-icons/theme}/font-background.svg (100%) rename packages/{ckeditor5-font/theme/icons => ckeditor5-icons/theme}/font-color.svg (100%) rename packages/{ckeditor5-font/theme/icons => ckeditor5-icons/theme}/font-family.svg (100%) rename packages/{ckeditor5-font/theme/icons => ckeditor5-icons/theme}/font-size.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/heading1.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/heading2.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/heading3.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/heading4.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/heading5.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/heading6.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/history.svg (100%) rename packages/{ckeditor5-core/theme/icons/horizontalline.svg => ckeditor5-icons/theme/horizontal-line.svg} (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/html.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/image-asset-manager.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/image-upload.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/image-url.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/image.svg (100%) rename packages/{ckeditor5-core/theme/icons/importexport.svg => ckeditor5-icons/theme/import-export.svg} (100%) create mode 100644 packages/ckeditor5-icons/theme/importword.svg rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/indent.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/insert-merge-field.svg rename packages/{ckeditor5-basic-styles/theme/icons => ckeditor5-icons/theme}/italic.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/legal-style-list.svg rename packages/{ckeditor5-link/theme/icons => ckeditor5-icons/theme}/link.svg (100%) rename packages/{ckeditor5-list/theme/icons/liststylecircle.svg => ckeditor5-icons/theme/list-style-circle.svg} (100%) rename packages/{ckeditor5-list/theme/icons/liststyledecimalleadingzero.svg => ckeditor5-icons/theme/list-style-decimal-leading-zero.svg} (100%) rename packages/{ckeditor5-list/theme/icons/liststyledecimal.svg => ckeditor5-icons/theme/list-style-decimal.svg} (100%) rename packages/{ckeditor5-list/theme/icons/liststyledisc.svg => ckeditor5-icons/theme/list-style-disc.svg} (100%) rename packages/{ckeditor5-list/theme/icons/liststylelowerlatin.svg => ckeditor5-icons/theme/list-style-lower-latin.svg} (100%) rename packages/{ckeditor5-list/theme/icons/liststylelowerroman.svg => ckeditor5-icons/theme/list-style-lower-roman.svg} (100%) rename packages/{ckeditor5-list/theme/icons/liststylesquare.svg => ckeditor5-icons/theme/list-style-square.svg} (100%) rename packages/{ckeditor5-list/theme/icons/liststyleupperlatin.svg => ckeditor5-icons/theme/list-style-upper-latin.svg} (100%) rename packages/{ckeditor5-list/theme/icons/liststyleupperroman.svg => ckeditor5-icons/theme/list-style-upper-roman.svg} (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/loupe.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/low-vision.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/magic-wand.svg rename packages/{ckeditor5-highlight/theme/icons => ckeditor5-icons/theme}/marker.svg (100%) rename packages/{ckeditor5-media-embed/theme/icons => ckeditor5-icons/theme}/media-placeholder.svg (100%) rename packages/{ckeditor5-media-embed/theme/icons => ckeditor5-icons/theme}/media.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/multi-level-list.svg rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/next-arrow.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/notification.svg rename packages/{ckeditor5-core/theme/icons/numberedlist.svg => ckeditor5-icons/theme/numbered-list.svg} (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/object-center.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/object-full-width.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/object-inline-left.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/object-inline-right.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/object-inline.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/object-left.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/object-right.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/object-size-custom.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/object-size-full.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/object-size-large.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/object-size-medium.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/object-size-small.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/outdent.svg (100%) rename packages/{ckeditor5-page-break/theme/icons/pagebreak.svg => ckeditor5-icons/theme/page-break.svg} (100%) create mode 100644 packages/ckeditor5-icons/theme/pagination-example.svg create mode 100644 packages/ckeditor5-icons/theme/paint-roller-cursor-default.svg create mode 100644 packages/ckeditor5-icons/theme/paint-roller-cursor-text.svg create mode 100644 packages/ckeditor5-icons/theme/paint-roller.svg rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/paragraph.svg (100%) rename packages/{ckeditor5-highlight/theme/icons => ckeditor5-icons/theme}/pen.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/pencil.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/pilcrow.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/play.svg rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/plus.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/preview-merge-fields.svg rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/previous-arrow.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/print.svg rename packages/{ckeditor5-ui/theme/icons => ckeditor5-icons/theme}/project-logo.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/quote.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/redo.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/remove-comment.svg rename packages/{ckeditor5-remove-format/theme/icons => ckeditor5-icons/theme}/remove-format.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/remove.svg (100%) rename packages/{ckeditor5-widget/theme/icons => ckeditor5-icons/theme}/return-arrow.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/revision-history.svg create mode 100644 packages/ckeditor5-icons/theme/robot-pencil.svg rename packages/{ckeditor5-select-all/theme/icons => ckeditor5-icons/theme}/select-all.svg (100%) rename packages/{ckeditor5-show-blocks/theme/icons => ckeditor5-icons/theme}/show-blocks.svg (100%) rename packages/{ckeditor5-source-editing/theme/icons => ckeditor5-icons/theme}/source-editing.svg (100%) rename packages/{ckeditor5-special-characters/theme/icons/specialcharacters.svg => ckeditor5-icons/theme/special-characters.svg} (100%) rename packages/{ckeditor5-basic-styles/theme/icons => ckeditor5-icons/theme}/strikethrough.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/submit.svg rename packages/{ckeditor5-basic-styles/theme/icons => ckeditor5-icons/theme}/subscript.svg (100%) rename packages/{ckeditor5-basic-styles/theme/icons => ckeditor5-icons/theme}/superscript.svg (100%) rename packages/{ckeditor5-table/theme/icons => ckeditor5-icons/theme}/table-cell-properties.svg (100%) rename packages/{ckeditor5-table/theme/icons => ckeditor5-icons/theme}/table-column.svg (100%) rename packages/{ckeditor5-table/theme/icons => ckeditor5-icons/theme}/table-merge-cell.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/table-of-contents.svg rename packages/{ckeditor5-table/theme/icons => ckeditor5-icons/theme}/table-properties.svg (100%) rename packages/{ckeditor5-table/theme/icons => ckeditor5-icons/theme}/table-row.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/table.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/template-generic.svg create mode 100644 packages/ckeditor5-icons/theme/template.svg rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/text-alternative.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/text.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/three-vertical-dots.svg (100%) rename packages/{ckeditor5-core/theme/icons/todolist.svg => ckeditor5-icons/theme/todo-list.svg} (100%) create mode 100644 packages/ckeditor5-icons/theme/track-changes-accept.svg create mode 100644 packages/ckeditor5-icons/theme/track-changes-discard.svg create mode 100644 packages/ckeditor5-icons/theme/track-changes.svg rename packages/{ckeditor5-media-embed/theme/icons/media => ckeditor5-icons/theme}/twitter.svg (100%) rename packages/{ckeditor5-basic-styles/theme/icons => ckeditor5-icons/theme}/underline.svg (100%) rename packages/{ckeditor5-core/theme/icons => ckeditor5-icons/theme}/undo.svg (100%) rename packages/{ckeditor5-link/theme/icons => ckeditor5-icons/theme}/unlink.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/user.svg create mode 100644 packages/ckeditor5-icons/theme/warning.svg create mode 100644 packages/ckeditor5-icons/tsconfig.dist.json create mode 100644 packages/ckeditor5-icons/tsconfig.json rename typings/types.d.ts => src/icons.ts (70%) diff --git a/docs/framework/contributing/package-metadata.md b/docs/framework/contributing/package-metadata.md index 676d6f4bcba..650099198ed 100644 --- a/docs/framework/contributing/package-metadata.md +++ b/docs/framework/contributing/package-metadata.md @@ -56,7 +56,7 @@ Below is an example showing how the `Bold` plugin can be documented using this f { "type": "Button", "name": "bold", - "iconPath": "theme/icons/bold.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/bold.svg" } ], "htmlOutput": [ diff --git a/package.json b/package.json index c9f6b77531e..dbc31247586 100644 --- a/package.json +++ b/package.json @@ -50,6 +50,7 @@ "@ckeditor/ckeditor5-horizontal-line": "44.1.0", "@ckeditor/ckeditor5-html-embed": "44.1.0", "@ckeditor/ckeditor5-html-support": "44.1.0", + "@ckeditor/ckeditor5-icons": "44.1.0", "@ckeditor/ckeditor5-image": "44.1.0", "@ckeditor/ckeditor5-indent": "44.1.0", "@ckeditor/ckeditor5-language": "44.1.0", diff --git a/packages/ckeditor5-adapter-ckfinder/tsconfig.dist.json b/packages/ckeditor5-adapter-ckfinder/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-adapter-ckfinder/tsconfig.dist.json +++ b/packages/ckeditor5-adapter-ckfinder/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-adapter-ckfinder/tsconfig.json b/packages/ckeditor5-adapter-ckfinder/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-adapter-ckfinder/tsconfig.json +++ b/packages/ckeditor5-adapter-ckfinder/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-alignment/ckeditor5-metadata.json b/packages/ckeditor5-alignment/ckeditor5-metadata.json index 2c559076b33..e9e8ee67a90 100644 --- a/packages/ckeditor5-alignment/ckeditor5-metadata.json +++ b/packages/ckeditor5-alignment/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "SplitButton", "name": "alignment", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/align-left.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/align-left.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-alignment/tests/alignmentui.js b/packages/ckeditor5-alignment/tests/alignmentui.js index 2ddad7409a4..3c9b758d0d2 100644 --- a/packages/ckeditor5-alignment/tests/alignmentui.js +++ b/packages/ckeditor5-alignment/tests/alignmentui.js @@ -5,12 +5,11 @@ /* global document */ +import { IconAlignLeft, IconAlignRight } from 'ckeditor5/src/icons.js'; + import AlignmentEditing from '../src/alignmentediting.js'; import AlignmentUI from '../src/alignmentui.js'; -import alignLeftIcon from '@ckeditor/ckeditor5-core/theme/icons/align-left.svg'; -import alignRightIcon from '@ckeditor/ckeditor5-core/theme/icons/align-right.svg'; - import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; describe( 'Alignment UI', () => { @@ -327,11 +326,11 @@ describe( 'Alignment UI', () => { // Trigger toolbar view creation (lazy init). dropdown.isOpen = true; - expect( dropdown.buttonView.icon ).to.equal( alignLeftIcon ); + expect( dropdown.buttonView.icon ).to.equal( IconAlignLeft ); command.value = 'right'; - expect( dropdown.buttonView.icon ).to.equal( alignRightIcon ); + expect( dropdown.buttonView.icon ).to.equal( IconAlignRight ); } ); it( 'should be disabled if command is not enabled', () => { @@ -428,7 +427,7 @@ describe( 'Alignment UI', () => { it( 'should have default icon set (LTR content)', () => { command.value = undefined; - expect( dropdown.buttonView.icon ).to.equal( alignLeftIcon ); + expect( dropdown.buttonView.icon ).to.equal( IconAlignLeft ); } ); it( 'should have default icon set (RTL content)', async () => { @@ -447,7 +446,7 @@ describe( 'Alignment UI', () => { dropdown = newEditor.ui.componentFactory.create( 'alignment' ); editor.commands.get( 'alignment' ).value = undefined; - expect( dropdown.buttonView.icon ).to.equal( alignRightIcon ); + expect( dropdown.buttonView.icon ).to.equal( IconAlignRight ); return newEditor.destroy(); } ); diff --git a/packages/ckeditor5-alignment/tsconfig.dist.json b/packages/ckeditor5-alignment/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-alignment/tsconfig.dist.json +++ b/packages/ckeditor5-alignment/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-alignment/tsconfig.json b/packages/ckeditor5-alignment/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-alignment/tsconfig.json +++ b/packages/ckeditor5-alignment/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-autoformat/tsconfig.dist.json b/packages/ckeditor5-autoformat/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-autoformat/tsconfig.dist.json +++ b/packages/ckeditor5-autoformat/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-autoformat/tsconfig.json b/packages/ckeditor5-autoformat/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-autoformat/tsconfig.json +++ b/packages/ckeditor5-autoformat/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-autosave/tsconfig.dist.json b/packages/ckeditor5-autosave/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-autosave/tsconfig.dist.json +++ b/packages/ckeditor5-autosave/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-autosave/tsconfig.json b/packages/ckeditor5-autosave/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-autosave/tsconfig.json +++ b/packages/ckeditor5-autosave/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-basic-styles/ckeditor5-metadata.json b/packages/ckeditor5-basic-styles/ckeditor5-metadata.json index 91308e78f17..64b8da97d9b 100644 --- a/packages/ckeditor5-basic-styles/ckeditor5-metadata.json +++ b/packages/ckeditor5-basic-styles/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "bold", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/bold.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/bold.svg" } ], "htmlOutput": [ @@ -29,7 +29,7 @@ { "type": "Button", "name": "code", - "iconPath": "theme/icons/code.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/code.svg" } ], "htmlOutput": [ @@ -48,7 +48,7 @@ { "type": "Button", "name": "italic", - "iconPath": "theme/icons/italic.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/italic.svg" } ], "htmlOutput": [ @@ -67,7 +67,7 @@ { "type": "Button", "name": "strikethrough", - "iconPath": "theme/icons/strikethrough.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/strikethrough.svg" } ], "htmlOutput": [ @@ -86,7 +86,7 @@ { "type": "Button", "name": "subscript", - "iconPath": "theme/icons/subscript.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/subscript.svg" } ], "htmlOutput": [ @@ -105,7 +105,7 @@ { "type": "Button", "name": "superscript", - "iconPath": "theme/icons/superscript.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/superscript.svg" } ], "htmlOutput": [ @@ -124,7 +124,7 @@ { "type": "Button", "name": "underline", - "iconPath": "theme/icons/underline.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/underline.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-basic-styles/src/code/codeui.ts b/packages/ckeditor5-basic-styles/src/code/codeui.ts index fadcd456e09..b554533e219 100644 --- a/packages/ckeditor5-basic-styles/src/code/codeui.ts +++ b/packages/ckeditor5-basic-styles/src/code/codeui.ts @@ -8,11 +8,10 @@ */ import { Plugin } from 'ckeditor5/src/core.js'; +import { IconCode } from 'ckeditor5/src/icons.js'; import { ButtonView, MenuBarMenuListItemButtonView } from 'ckeditor5/src/ui.js'; import { getButtonCreator } from '../utils.js'; -import codeIcon from '../../theme/icons/code.svg'; - import '../../theme/code.css'; const CODE = 'code'; @@ -45,7 +44,7 @@ export default class CodeUI extends Plugin { editor, commandName: CODE, plugin: this, - icon: codeIcon, + icon: IconCode, label: t( 'Code' ) } ); diff --git a/packages/ckeditor5-basic-styles/src/italic/italicui.ts b/packages/ckeditor5-basic-styles/src/italic/italicui.ts index 2d7b31f1180..d410159614e 100644 --- a/packages/ckeditor5-basic-styles/src/italic/italicui.ts +++ b/packages/ckeditor5-basic-styles/src/italic/italicui.ts @@ -8,11 +8,10 @@ */ import { Plugin } from 'ckeditor5/src/core.js'; +import { IconItalic } from 'ckeditor5/src/icons.js'; import { MenuBarMenuListItemButtonView, ButtonView } from 'ckeditor5/src/ui.js'; import { getButtonCreator } from '../utils.js'; -import italicIcon from '../../theme/icons/italic.svg'; - const ITALIC = 'italic'; /** @@ -43,7 +42,7 @@ export default class ItalicUI extends Plugin { editor, commandName: ITALIC, plugin: this, - icon: italicIcon, + icon: IconItalic, keystroke: 'CTRL+I', label: t( 'Italic' ) } ); diff --git a/packages/ckeditor5-basic-styles/src/strikethrough/strikethroughui.ts b/packages/ckeditor5-basic-styles/src/strikethrough/strikethroughui.ts index 74ff6ae0d7f..900cf80c279 100644 --- a/packages/ckeditor5-basic-styles/src/strikethrough/strikethroughui.ts +++ b/packages/ckeditor5-basic-styles/src/strikethrough/strikethroughui.ts @@ -8,11 +8,10 @@ */ import { Plugin } from 'ckeditor5/src/core.js'; +import { IconStrikethrough } from 'ckeditor5/src/icons.js'; import { ButtonView, MenuBarMenuListItemButtonView } from 'ckeditor5/src/ui.js'; import { getButtonCreator } from '../utils.js'; -import strikethroughIcon from '../../theme/icons/strikethrough.svg'; - const STRIKETHROUGH = 'strikethrough'; /** @@ -43,7 +42,7 @@ export default class StrikethroughUI extends Plugin { editor, commandName: STRIKETHROUGH, plugin: this, - icon: strikethroughIcon, + icon: IconStrikethrough, keystroke: 'CTRL+SHIFT+X', label: t( 'Strikethrough' ) } ); diff --git a/packages/ckeditor5-basic-styles/src/subscript/subscriptui.ts b/packages/ckeditor5-basic-styles/src/subscript/subscriptui.ts index b118327588c..67cf35538a9 100644 --- a/packages/ckeditor5-basic-styles/src/subscript/subscriptui.ts +++ b/packages/ckeditor5-basic-styles/src/subscript/subscriptui.ts @@ -8,11 +8,10 @@ */ import { Plugin } from 'ckeditor5/src/core.js'; +import { IconSubscript } from 'ckeditor5/src/icons.js'; import { ButtonView, MenuBarMenuListItemButtonView } from 'ckeditor5/src/ui.js'; import { getButtonCreator } from '../utils.js'; -import subscriptIcon from '../../theme/icons/subscript.svg'; - const SUBSCRIPT = 'subscript'; /** @@ -44,7 +43,7 @@ export default class SubscriptUI extends Plugin { editor, commandName: SUBSCRIPT, plugin: this, - icon: subscriptIcon, + icon: IconSubscript, label: t( 'Subscript' ) } ); diff --git a/packages/ckeditor5-basic-styles/src/superscript/superscriptui.ts b/packages/ckeditor5-basic-styles/src/superscript/superscriptui.ts index 09a812b167f..97755fa0c5c 100644 --- a/packages/ckeditor5-basic-styles/src/superscript/superscriptui.ts +++ b/packages/ckeditor5-basic-styles/src/superscript/superscriptui.ts @@ -8,11 +8,10 @@ */ import { Plugin } from 'ckeditor5/src/core.js'; +import { IconSuperscript } from 'ckeditor5/src/icons.js'; import { ButtonView, MenuBarMenuListItemButtonView } from 'ckeditor5/src/ui.js'; import { getButtonCreator } from '../utils.js'; -import superscriptIcon from '../../theme/icons/superscript.svg'; - const SUPERSCRIPT = 'superscript'; /** @@ -43,7 +42,7 @@ export default class SuperscriptUI extends Plugin { editor, commandName: SUPERSCRIPT, plugin: this, - icon: superscriptIcon, + icon: IconSuperscript, label: t( 'Superscript' ) } ); diff --git a/packages/ckeditor5-basic-styles/src/underline/underlineui.ts b/packages/ckeditor5-basic-styles/src/underline/underlineui.ts index df543215d38..b999cd68644 100644 --- a/packages/ckeditor5-basic-styles/src/underline/underlineui.ts +++ b/packages/ckeditor5-basic-styles/src/underline/underlineui.ts @@ -8,11 +8,10 @@ */ import { Plugin } from 'ckeditor5/src/core.js'; +import { IconUnderline } from 'ckeditor5/src/icons.js'; import { ButtonView, MenuBarMenuListItemButtonView } from 'ckeditor5/src/ui.js'; import { getButtonCreator } from '../utils.js'; -import underlineIcon from '../../theme/icons/underline.svg'; - const UNDERLINE = 'underline'; /** @@ -43,7 +42,7 @@ export default class UnderlineUI extends Plugin { editor, commandName: UNDERLINE, plugin: this, - icon: underlineIcon, + icon: IconUnderline, label: t( 'Underline' ), keystroke: 'CTRL+U' } ); diff --git a/packages/ckeditor5-basic-styles/tsconfig.dist.json b/packages/ckeditor5-basic-styles/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-basic-styles/tsconfig.dist.json +++ b/packages/ckeditor5-basic-styles/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-basic-styles/tsconfig.json b/packages/ckeditor5-basic-styles/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-basic-styles/tsconfig.json +++ b/packages/ckeditor5-basic-styles/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-block-quote/ckeditor5-metadata.json b/packages/ckeditor5-block-quote/ckeditor5-metadata.json index 6668d465909..5da4943dbd3 100644 --- a/packages/ckeditor5-block-quote/ckeditor5-metadata.json +++ b/packages/ckeditor5-block-quote/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "blockQuote", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/quote.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/quote.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-block-quote/tsconfig.dist.json b/packages/ckeditor5-block-quote/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-block-quote/tsconfig.dist.json +++ b/packages/ckeditor5-block-quote/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-block-quote/tsconfig.json b/packages/ckeditor5-block-quote/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-block-quote/tsconfig.json +++ b/packages/ckeditor5-block-quote/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-bookmark/ckeditor5-metadata.json b/packages/ckeditor5-bookmark/ckeditor5-metadata.json index 89b1e5aabc9..fb1d217ae1a 100644 --- a/packages/ckeditor5-bookmark/ckeditor5-metadata.json +++ b/packages/ckeditor5-bookmark/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "bookmark", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/bookmark.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/bookmark.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-bookmark/tsconfig.dist.json b/packages/ckeditor5-bookmark/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-bookmark/tsconfig.dist.json +++ b/packages/ckeditor5-bookmark/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-bookmark/tsconfig.json b/packages/ckeditor5-bookmark/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-bookmark/tsconfig.json +++ b/packages/ckeditor5-bookmark/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-build-balloon-block/tsconfig.json b/packages/ckeditor5-build-balloon-block/tsconfig.json index 204c6484097..e1ba67ba708 100644 --- a/packages/ckeditor5-build-balloon-block/tsconfig.json +++ b/packages/ckeditor5-build-balloon-block/tsconfig.json @@ -1,7 +1,6 @@ { "extends": "ckeditor5/tsconfig.json", "include": [ - "src", - "../../typings" + "src" ] } diff --git a/packages/ckeditor5-build-balloon-block/tsconfig.types.json b/packages/ckeditor5-build-balloon-block/tsconfig.types.json index 9b51af3ccbb..69bc431ea75 100644 --- a/packages/ckeditor5-build-balloon-block/tsconfig.types.json +++ b/packages/ckeditor5-build-balloon-block/tsconfig.types.json @@ -7,7 +7,6 @@ "stripInternal": true }, "include": [ - "src", - "../../typings" + "src" ] } diff --git a/packages/ckeditor5-build-balloon/tsconfig.json b/packages/ckeditor5-build-balloon/tsconfig.json index 204c6484097..e1ba67ba708 100644 --- a/packages/ckeditor5-build-balloon/tsconfig.json +++ b/packages/ckeditor5-build-balloon/tsconfig.json @@ -1,7 +1,6 @@ { "extends": "ckeditor5/tsconfig.json", "include": [ - "src", - "../../typings" + "src" ] } diff --git a/packages/ckeditor5-build-balloon/tsconfig.types.json b/packages/ckeditor5-build-balloon/tsconfig.types.json index 9b51af3ccbb..69bc431ea75 100644 --- a/packages/ckeditor5-build-balloon/tsconfig.types.json +++ b/packages/ckeditor5-build-balloon/tsconfig.types.json @@ -7,7 +7,6 @@ "stripInternal": true }, "include": [ - "src", - "../../typings" + "src" ] } diff --git a/packages/ckeditor5-build-classic/tsconfig.json b/packages/ckeditor5-build-classic/tsconfig.json index 204c6484097..e1ba67ba708 100644 --- a/packages/ckeditor5-build-classic/tsconfig.json +++ b/packages/ckeditor5-build-classic/tsconfig.json @@ -1,7 +1,6 @@ { "extends": "ckeditor5/tsconfig.json", "include": [ - "src", - "../../typings" + "src" ] } diff --git a/packages/ckeditor5-build-classic/tsconfig.types.json b/packages/ckeditor5-build-classic/tsconfig.types.json index 9b51af3ccbb..69bc431ea75 100644 --- a/packages/ckeditor5-build-classic/tsconfig.types.json +++ b/packages/ckeditor5-build-classic/tsconfig.types.json @@ -7,7 +7,6 @@ "stripInternal": true }, "include": [ - "src", - "../../typings" + "src" ] } diff --git a/packages/ckeditor5-build-decoupled-document/tsconfig.json b/packages/ckeditor5-build-decoupled-document/tsconfig.json index 204c6484097..e1ba67ba708 100644 --- a/packages/ckeditor5-build-decoupled-document/tsconfig.json +++ b/packages/ckeditor5-build-decoupled-document/tsconfig.json @@ -1,7 +1,6 @@ { "extends": "ckeditor5/tsconfig.json", "include": [ - "src", - "../../typings" + "src" ] } diff --git a/packages/ckeditor5-build-decoupled-document/tsconfig.types.json b/packages/ckeditor5-build-decoupled-document/tsconfig.types.json index 9b51af3ccbb..69bc431ea75 100644 --- a/packages/ckeditor5-build-decoupled-document/tsconfig.types.json +++ b/packages/ckeditor5-build-decoupled-document/tsconfig.types.json @@ -7,7 +7,6 @@ "stripInternal": true }, "include": [ - "src", - "../../typings" + "src" ] } diff --git a/packages/ckeditor5-build-inline/tsconfig.json b/packages/ckeditor5-build-inline/tsconfig.json index 204c6484097..e1ba67ba708 100644 --- a/packages/ckeditor5-build-inline/tsconfig.json +++ b/packages/ckeditor5-build-inline/tsconfig.json @@ -1,7 +1,6 @@ { "extends": "ckeditor5/tsconfig.json", "include": [ - "src", - "../../typings" + "src" ] } diff --git a/packages/ckeditor5-build-inline/tsconfig.types.json b/packages/ckeditor5-build-inline/tsconfig.types.json index 9b51af3ccbb..69bc431ea75 100644 --- a/packages/ckeditor5-build-inline/tsconfig.types.json +++ b/packages/ckeditor5-build-inline/tsconfig.types.json @@ -7,7 +7,6 @@ "stripInternal": true }, "include": [ - "src", - "../../typings" + "src" ] } diff --git a/packages/ckeditor5-build-multi-root/tsconfig.json b/packages/ckeditor5-build-multi-root/tsconfig.json index 204c6484097..e1ba67ba708 100644 --- a/packages/ckeditor5-build-multi-root/tsconfig.json +++ b/packages/ckeditor5-build-multi-root/tsconfig.json @@ -1,7 +1,6 @@ { "extends": "ckeditor5/tsconfig.json", "include": [ - "src", - "../../typings" + "src" ] } diff --git a/packages/ckeditor5-build-multi-root/tsconfig.types.json b/packages/ckeditor5-build-multi-root/tsconfig.types.json index 9b51af3ccbb..69bc431ea75 100644 --- a/packages/ckeditor5-build-multi-root/tsconfig.types.json +++ b/packages/ckeditor5-build-multi-root/tsconfig.types.json @@ -7,7 +7,6 @@ "stripInternal": true }, "include": [ - "src", - "../../typings" + "src" ] } diff --git a/packages/ckeditor5-ckbox/ckeditor5-metadata.json b/packages/ckeditor5-ckbox/ckeditor5-metadata.json index 6393996625b..3fbb3e56e4e 100644 --- a/packages/ckeditor5-ckbox/ckeditor5-metadata.json +++ b/packages/ckeditor5-ckbox/ckeditor5-metadata.json @@ -20,7 +20,7 @@ { "name": "ckbox", "type": "Button", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/browse-files.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/browse-files.svg" } ], "htmlOutput": [ @@ -50,7 +50,7 @@ { "name": "ckboxImageEdit", "type": "Button", - "iconPath": "theme/icons/ckbox-image-edit.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/ckbox-image-edit.svg" } ] } diff --git a/packages/ckeditor5-ckbox/src/ckboximageedit/ckboximageeditui.ts b/packages/ckeditor5-ckbox/src/ckboximageedit/ckboximageeditui.ts index bb82e2a3831..0458526463c 100644 --- a/packages/ckeditor5-ckbox/src/ckboximageedit/ckboximageeditui.ts +++ b/packages/ckeditor5-ckbox/src/ckboximageedit/ckboximageeditui.ts @@ -9,8 +9,7 @@ import { Plugin } from 'ckeditor5/src/core.js'; import { ButtonView } from 'ckeditor5/src/ui.js'; - -import ckboxImageEditIcon from '../../theme/icons/ckbox-image-edit.svg'; +import { IconCkboxImageEdit } from 'ckeditor5/src/icons.js'; /** * The UI plugin of the CKBox image edit feature. @@ -46,7 +45,7 @@ export default class CKBoxImageEditUI extends Plugin { const t = locale.t; view.set( { - icon: ckboxImageEditIcon, + icon: IconCkboxImageEdit, tooltip: true } ); diff --git a/packages/ckeditor5-ckbox/tsconfig.dist.json b/packages/ckeditor5-ckbox/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-ckbox/tsconfig.dist.json +++ b/packages/ckeditor5-ckbox/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-ckbox/tsconfig.json b/packages/ckeditor5-ckbox/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-ckbox/tsconfig.json +++ b/packages/ckeditor5-ckbox/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-ckfinder/ckeditor5-metadata.json b/packages/ckeditor5-ckfinder/ckeditor5-metadata.json index a02486318fb..efbd1160abd 100644 --- a/packages/ckeditor5-ckfinder/ckeditor5-metadata.json +++ b/packages/ckeditor5-ckfinder/ckeditor5-metadata.json @@ -18,7 +18,7 @@ { "name": "CKFinder", "type": "Button", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/browse-files.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/browse-files.svg" } ] } diff --git a/packages/ckeditor5-ckfinder/tsconfig.dist.json b/packages/ckeditor5-ckfinder/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-ckfinder/tsconfig.dist.json +++ b/packages/ckeditor5-ckfinder/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-ckfinder/tsconfig.json b/packages/ckeditor5-ckfinder/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-ckfinder/tsconfig.json +++ b/packages/ckeditor5-ckfinder/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-clipboard/tsconfig.dist.json b/packages/ckeditor5-clipboard/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-clipboard/tsconfig.dist.json +++ b/packages/ckeditor5-clipboard/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-clipboard/tsconfig.json b/packages/ckeditor5-clipboard/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-clipboard/tsconfig.json +++ b/packages/ckeditor5-clipboard/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-cloud-services/tsconfig.dist.json b/packages/ckeditor5-cloud-services/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-cloud-services/tsconfig.dist.json +++ b/packages/ckeditor5-cloud-services/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-cloud-services/tsconfig.json b/packages/ckeditor5-cloud-services/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-cloud-services/tsconfig.json +++ b/packages/ckeditor5-cloud-services/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-code-block/ckeditor5-metadata.json b/packages/ckeditor5-code-block/ckeditor5-metadata.json index 8a3b2989f49..eae95f76f4f 100644 --- a/packages/ckeditor5-code-block/ckeditor5-metadata.json +++ b/packages/ckeditor5-code-block/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "codeBlock", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/codeblock.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/code-block.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-code-block/tsconfig.dist.json b/packages/ckeditor5-code-block/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-code-block/tsconfig.dist.json +++ b/packages/ckeditor5-code-block/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-code-block/tsconfig.json b/packages/ckeditor5-code-block/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-code-block/tsconfig.json +++ b/packages/ckeditor5-code-block/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-core/package.json b/packages/ckeditor5-core/package.json index c8ada44ecc2..bacd369f9c2 100644 --- a/packages/ckeditor5-core/package.json +++ b/packages/ckeditor5-core/package.json @@ -62,7 +62,6 @@ "lang", "src/**/*.js", "src/**/*.d.ts", - "theme", "ckeditor5-metadata.json", "CHANGELOG.md" ], diff --git a/packages/ckeditor5-core/src/index.ts b/packages/ckeditor5-core/src/index.ts index a726c298123..0f51f2eb5f5 100644 --- a/packages/ckeditor5-core/src/index.ts +++ b/packages/ckeditor5-core/src/index.ts @@ -42,171 +42,4 @@ export type { KeystrokeInfoDefinition as KeystrokeInfoDefinition } from './accessibility.js'; -import cancel from './../theme/icons/cancel.svg'; -import caption from './../theme/icons/caption.svg'; -import check from './../theme/icons/check.svg'; -import cog from './../theme/icons/cog.svg'; -import colorPalette from './../theme/icons/color-palette.svg'; -import eraser from './../theme/icons/eraser.svg'; -import history from './../theme/icons/history.svg'; -import lowVision from './../theme/icons/low-vision.svg'; -import textAlternative from './../theme/icons/text-alternative.svg'; -import loupe from './../theme/icons/loupe.svg'; -import previousArrow from './../theme/icons/previous-arrow.svg'; -import nextArrow from './../theme/icons/next-arrow.svg'; -import image from './../theme/icons/image.svg'; -import imageUpload from './../theme/icons/image-upload.svg'; -import imageAssetManager from './../theme/icons/image-asset-manager.svg'; -import imageUrl from './../theme/icons/image-url.svg'; - -import alignBottom from './../theme/icons/align-bottom.svg'; -import alignMiddle from './../theme/icons/align-middle.svg'; -import alignTop from './../theme/icons/align-top.svg'; -import alignLeft from './../theme/icons/align-left.svg'; -import alignCenter from './../theme/icons/align-center.svg'; -import alignRight from './../theme/icons/align-right.svg'; -import alignJustify from './../theme/icons/align-justify.svg'; - -import objectBlockLeft from './../theme/icons/object-left.svg'; -import objectCenter from './../theme/icons/object-center.svg'; -import objectBlockRight from './../theme/icons/object-right.svg'; -import objectFullWidth from './../theme/icons/object-full-width.svg'; -import objectInline from './../theme/icons/object-inline.svg'; -import objectLeft from './../theme/icons/object-inline-left.svg'; -import objectRight from './../theme/icons/object-inline-right.svg'; - -import objectSizeFull from './../theme/icons/object-size-full.svg'; -import objectSizeCustom from './../theme/icons/object-size-custom.svg'; -import objectSizeLarge from './../theme/icons/object-size-large.svg'; -import objectSizeSmall from './../theme/icons/object-size-small.svg'; -import objectSizeMedium from './../theme/icons/object-size-medium.svg'; - -import pencil from './../theme/icons/pencil.svg'; -import pilcrow from './../theme/icons/pilcrow.svg'; -import quote from './../theme/icons/quote.svg'; -import threeVerticalDots from './../theme/icons/three-vertical-dots.svg'; -import dragIndicator from './../theme/icons/drag-indicator.svg'; - -import bold from './../theme/icons/bold.svg'; -import paragraph from './../theme/icons/paragraph.svg'; -import plus from './../theme/icons/plus.svg'; -import text from './../theme/icons/text.svg'; -import importExport from './../theme/icons/importexport.svg'; - -import redo from './../theme/icons/redo.svg'; -import undo from './../theme/icons/undo.svg'; - -import bulletedList from './../theme/icons/bulletedlist.svg'; -import numberedList from './../theme/icons/numberedlist.svg'; -import todoList from './../theme/icons/todolist.svg'; - -import codeBlock from './../theme/icons/codeblock.svg'; - -import browseFiles from './../theme/icons/browse-files.svg'; - -import heading1 from './../theme/icons/heading1.svg'; -import heading2 from './../theme/icons/heading2.svg'; -import heading3 from './../theme/icons/heading3.svg'; -import heading4 from './../theme/icons/heading4.svg'; -import heading5 from './../theme/icons/heading5.svg'; -import heading6 from './../theme/icons/heading6.svg'; - -import horizontalLine from './../theme/icons/horizontalline.svg'; - -import html from './../theme/icons/html.svg'; - -import indent from './../theme/icons/indent.svg'; -import outdent from './../theme/icons/outdent.svg'; - -import table from './../theme/icons/table.svg'; - -import remove from './../theme/icons/remove.svg'; - -import bookmark from './../theme/icons/bookmark.svg'; -import bookmarkInline from './../theme/icons/bookmark_inline.svg'; - -export const icons = { - bold, - cancel, - caption, - check, - cog, - colorPalette, - eraser, - history, - image, - imageUpload, - imageAssetManager, - imageUrl, - lowVision, - textAlternative, - loupe, - previousArrow, - nextArrow, - importExport, - paragraph, - plus, - text, - - alignBottom, - alignMiddle, - alignTop, - alignLeft, - alignCenter, - alignRight, - alignJustify, - - objectLeft, - objectCenter, - objectRight, - objectFullWidth, - objectInline, - objectBlockLeft, - objectBlockRight, - - objectSizeCustom, - objectSizeFull, - objectSizeLarge, - objectSizeSmall, - objectSizeMedium, - - pencil, - pilcrow, - quote, - threeVerticalDots, - dragIndicator, - - redo, - undo, - - bulletedList, - numberedList, - todoList, - - codeBlock, - - browseFiles, - - heading1, - heading2, - heading3, - heading4, - heading5, - heading6, - - horizontalLine, - - html, - - indent, - outdent, - - table, - - remove, - - bookmark, - bookmarkInline -}; - import './augmentation.js'; diff --git a/packages/ckeditor5-core/tsconfig.dist.json b/packages/ckeditor5-core/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-core/tsconfig.dist.json +++ b/packages/ckeditor5-core/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-core/tsconfig.json b/packages/ckeditor5-core/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-core/tsconfig.json +++ b/packages/ckeditor5-core/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-easy-image/tsconfig.dist.json b/packages/ckeditor5-easy-image/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-easy-image/tsconfig.dist.json +++ b/packages/ckeditor5-easy-image/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-easy-image/tsconfig.json b/packages/ckeditor5-easy-image/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-easy-image/tsconfig.json +++ b/packages/ckeditor5-easy-image/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-editor-balloon/tsconfig.dist.json b/packages/ckeditor5-editor-balloon/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-editor-balloon/tsconfig.dist.json +++ b/packages/ckeditor5-editor-balloon/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-editor-balloon/tsconfig.json b/packages/ckeditor5-editor-balloon/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-editor-balloon/tsconfig.json +++ b/packages/ckeditor5-editor-balloon/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-editor-classic/tsconfig.dist.json b/packages/ckeditor5-editor-classic/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-editor-classic/tsconfig.dist.json +++ b/packages/ckeditor5-editor-classic/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-editor-classic/tsconfig.json b/packages/ckeditor5-editor-classic/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-editor-classic/tsconfig.json +++ b/packages/ckeditor5-editor-classic/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-editor-decoupled/tsconfig.dist.json b/packages/ckeditor5-editor-decoupled/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-editor-decoupled/tsconfig.dist.json +++ b/packages/ckeditor5-editor-decoupled/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-editor-decoupled/tsconfig.json b/packages/ckeditor5-editor-decoupled/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-editor-decoupled/tsconfig.json +++ b/packages/ckeditor5-editor-decoupled/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-editor-inline/tsconfig.dist.json b/packages/ckeditor5-editor-inline/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-editor-inline/tsconfig.dist.json +++ b/packages/ckeditor5-editor-inline/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-editor-inline/tsconfig.json b/packages/ckeditor5-editor-inline/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-editor-inline/tsconfig.json +++ b/packages/ckeditor5-editor-inline/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-editor-multi-root/tsconfig.dist.json b/packages/ckeditor5-editor-multi-root/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-editor-multi-root/tsconfig.dist.json +++ b/packages/ckeditor5-editor-multi-root/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-editor-multi-root/tsconfig.json b/packages/ckeditor5-editor-multi-root/tsconfig.json index 890e077e061..11ce5be5a65 100644 --- a/packages/ckeditor5-editor-multi-root/tsconfig.json +++ b/packages/ckeditor5-editor-multi-root/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-engine/tsconfig.dist.json b/packages/ckeditor5-engine/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-engine/tsconfig.dist.json +++ b/packages/ckeditor5-engine/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-engine/tsconfig.json b/packages/ckeditor5-engine/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-engine/tsconfig.json +++ b/packages/ckeditor5-engine/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-enter/tsconfig.dist.json b/packages/ckeditor5-enter/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-enter/tsconfig.dist.json +++ b/packages/ckeditor5-enter/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-enter/tsconfig.json b/packages/ckeditor5-enter/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-enter/tsconfig.json +++ b/packages/ckeditor5-enter/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-essentials/tsconfig.dist.json b/packages/ckeditor5-essentials/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-essentials/tsconfig.dist.json +++ b/packages/ckeditor5-essentials/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-essentials/tsconfig.json b/packages/ckeditor5-essentials/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-essentials/tsconfig.json +++ b/packages/ckeditor5-essentials/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-find-and-replace/ckeditor5-metadata.json b/packages/ckeditor5-find-and-replace/ckeditor5-metadata.json index be6623eb4bb..c3ffdadf400 100644 --- a/packages/ckeditor5-find-and-replace/ckeditor5-metadata.json +++ b/packages/ckeditor5-find-and-replace/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "findAndReplace", - "iconPath": "theme/icons/find-replace.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/find-replace.svg" } ] } diff --git a/packages/ckeditor5-find-and-replace/src/findandreplaceui.ts b/packages/ckeditor5-find-and-replace/src/findandreplaceui.ts index 7d0a7a21199..3f0d842ed77 100644 --- a/packages/ckeditor5-find-and-replace/src/findandreplaceui.ts +++ b/packages/ckeditor5-find-and-replace/src/findandreplaceui.ts @@ -7,7 +7,8 @@ * @module find-and-replace/findandreplaceui */ -import { type Editor, Plugin } from 'ckeditor5/src/core.js'; +import { Plugin, type Editor } from 'ckeditor5/src/core.js'; +import { IconFindReplace } from 'ckeditor5/src/icons.js'; import { ButtonView, MenuBarMenuListItemButtonView, @@ -20,7 +21,6 @@ import { type ViewWithCssTransitionDisabler } from 'ckeditor5/src/ui.js'; import FindAndReplaceFormView from './ui/findandreplaceformview.js'; -import loupeIcon from '../theme/icons/find-replace.svg'; import type FindAndReplaceEditing from './findandreplaceediting.js'; import type FindNextCommand from './findnextcommand.js'; import type FindPreviousCommand from './findpreviouscommand.js'; @@ -176,7 +176,7 @@ export default class FindAndReplaceUI extends Plugin { }, { priority: 'low' } ); dropdownView.buttonView.set( { - icon: loupeIcon, + icon: IconFindReplace, label: t( 'Find and replace' ), keystroke: 'CTRL+F', tooltip: true @@ -257,7 +257,7 @@ export default class FindAndReplaceUI extends Plugin { buttonView.bind( 'isEnabled' ).to( findCommand ); buttonView.set( { - icon: loupeIcon, + icon: IconFindReplace, label: t( 'Find and replace' ), keystroke: 'CTRL+F' } ); diff --git a/packages/ckeditor5-find-and-replace/tests/findandreplaceui.js b/packages/ckeditor5-find-and-replace/tests/findandreplaceui.js index b5447fb645f..5f51c6a670c 100644 --- a/packages/ckeditor5-find-and-replace/tests/findandreplaceui.js +++ b/packages/ckeditor5-find-and-replace/tests/findandreplaceui.js @@ -3,6 +3,7 @@ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options */ +import { IconFindReplace } from 'ckeditor5/src/icons.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; import { Paragraph } from '@ckeditor/ckeditor5-paragraph'; import DropdownView from '@ckeditor/ckeditor5-ui/src/dropdown/dropdownview.js'; @@ -15,7 +16,6 @@ import MenuBarMenuListItemButtonView from '@ckeditor/ckeditor5-ui/src/menubar/me import DialogView from '@ckeditor/ckeditor5-ui/src/dialog/dialogview.js'; import FindAndReplaceUI from '../src/findandreplaceui.js'; import FindAndReplace from '../src/findandreplace.js'; -import loupeIcon from '../theme/icons/find-replace.svg'; import FindAndReplaceFormView from '../src/ui/findandreplaceformview.js'; /* global window */ @@ -236,7 +236,7 @@ describe( 'FindAndReplaceUI', () => { } ); it( 'should set an #icon of the #buttonView', () => { - expect( button.icon ).to.equal( loupeIcon ); + expect( button.icon ).to.equal( IconFindReplace ); } ); it( 'should set a #label of the #buttonView', () => { @@ -629,7 +629,7 @@ describe( 'FindAndReplaceUI', () => { describe( 'button', () => { it( 'should set an #icon of the #buttonView', () => { - expect( dropdown.buttonView.icon ).to.equal( loupeIcon ); + expect( dropdown.buttonView.icon ).to.equal( IconFindReplace ); } ); it( 'should set a #label of the #buttonView', () => { diff --git a/packages/ckeditor5-find-and-replace/tsconfig.dist.json b/packages/ckeditor5-find-and-replace/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-find-and-replace/tsconfig.dist.json +++ b/packages/ckeditor5-find-and-replace/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-find-and-replace/tsconfig.json b/packages/ckeditor5-find-and-replace/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-find-and-replace/tsconfig.json +++ b/packages/ckeditor5-find-and-replace/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-font/ckeditor5-metadata.json b/packages/ckeditor5-font/ckeditor5-metadata.json index fae9f8f69fb..e8831ef1019 100644 --- a/packages/ckeditor5-font/ckeditor5-metadata.json +++ b/packages/ckeditor5-font/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "SplitButton", "name": "fontBackgroundColor", - "iconPath": "theme/icons/font-background.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/font-background.svg" } ], "htmlOutput": [ @@ -30,7 +30,7 @@ { "type": "SplitButton", "name": "fontColor", - "iconPath": "theme/icons/font-color.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/font-color.svg" } ], "htmlOutput": [ @@ -50,7 +50,7 @@ { "type": "SplitButton", "name": "fontSize", - "iconPath": "theme/icons/font-size.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/font-size.svg" } ], "htmlOutput": [ @@ -89,7 +89,7 @@ { "type": "SplitButton", "name": "fontFamily", - "iconPath": "theme/icons/font-family.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/font-family.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-font/src/fontbackgroundcolor/fontbackgroundcolorui.ts b/packages/ckeditor5-font/src/fontbackgroundcolor/fontbackgroundcolorui.ts index 3410069edd9..38c8cfd5a1c 100644 --- a/packages/ckeditor5-font/src/fontbackgroundcolor/fontbackgroundcolorui.ts +++ b/packages/ckeditor5-font/src/fontbackgroundcolor/fontbackgroundcolorui.ts @@ -7,12 +7,11 @@ * @module font/fontbackgroundcolor/fontbackgroundcolorui */ +import { IconFontBackground } from 'ckeditor5/src/icons.js'; import ColorUI from '../ui/colorui.js'; import { FONT_BACKGROUND_COLOR } from '../utils.js'; import type { Editor } from 'ckeditor5/src/core.js'; -import fontBackgroundColorIcon from '../../theme/icons/font-background.svg'; - /** * The font background color UI plugin. It introduces the `'fontBackgroundColor'` dropdown. */ @@ -26,7 +25,7 @@ export default class FontBackgroundColorUI extends ColorUI { super( editor, { commandName: FONT_BACKGROUND_COLOR, componentName: FONT_BACKGROUND_COLOR, - icon: fontBackgroundColorIcon, + icon: IconFontBackground, dropdownLabel: t( 'Font Background Color' ) } ); } diff --git a/packages/ckeditor5-font/src/fontcolor/fontcolorui.ts b/packages/ckeditor5-font/src/fontcolor/fontcolorui.ts index e46ffb99099..5365e3c1bc2 100644 --- a/packages/ckeditor5-font/src/fontcolor/fontcolorui.ts +++ b/packages/ckeditor5-font/src/fontcolor/fontcolorui.ts @@ -7,12 +7,11 @@ * @module font/fontcolor/fontcolorui */ +import { IconFontColor } from 'ckeditor5/src/icons.js'; import ColorUI from '../ui/colorui.js'; import { FONT_COLOR } from '../utils.js'; import type { Editor } from 'ckeditor5/src/core.js'; -import fontColorIcon from '../../theme/icons/font-color.svg'; - /** * The font color UI plugin. It introduces the `'fontColor'` dropdown. */ @@ -26,7 +25,7 @@ export default class FontColorUI extends ColorUI { super( editor, { commandName: FONT_COLOR, componentName: FONT_COLOR, - icon: fontColorIcon, + icon: IconFontColor, dropdownLabel: t( 'Font Color' ) } ); } diff --git a/packages/ckeditor5-font/src/fontfamily/fontfamilyui.ts b/packages/ckeditor5-font/src/fontfamily/fontfamilyui.ts index fbddaed618d..ba03b40e7fa 100644 --- a/packages/ckeditor5-font/src/fontfamily/fontfamilyui.ts +++ b/packages/ckeditor5-font/src/fontfamily/fontfamilyui.ts @@ -9,6 +9,7 @@ import { Plugin } from 'ckeditor5/src/core.js'; import { Collection } from 'ckeditor5/src/utils.js'; +import { IconFontFamily } from 'ckeditor5/src/icons.js'; import { ViewModel, createDropdown, @@ -26,8 +27,6 @@ import { FONT_FAMILY } from '../utils.js'; import type { FontFamilyOption } from '../fontconfig.js'; import type FontFamilyCommand from './fontfamilycommand.js'; -import fontFamilyIcon from '../../theme/icons/font-family.svg'; - /** * The font family UI plugin. It introduces the `'fontFamily'` dropdown. */ @@ -70,7 +69,7 @@ export default class FontFamilyUI extends Plugin { dropdownView.buttonView.set( { label: accessibleLabel, - icon: fontFamilyIcon, + icon: IconFontFamily, tooltip: true } ); @@ -96,7 +95,7 @@ export default class FontFamilyUI extends Plugin { menuView.buttonView.set( { label: accessibleLabel, - icon: fontFamilyIcon + icon: IconFontFamily } ); menuView.bind( 'isEnabled' ).to( command ); diff --git a/packages/ckeditor5-font/src/fontsize/fontsizeui.ts b/packages/ckeditor5-font/src/fontsize/fontsizeui.ts index 32a6f91623c..21c145e9056 100644 --- a/packages/ckeditor5-font/src/fontsize/fontsizeui.ts +++ b/packages/ckeditor5-font/src/fontsize/fontsizeui.ts @@ -8,6 +8,7 @@ */ import { Plugin } from 'ckeditor5/src/core.js'; +import { IconFontSize } from 'ckeditor5/src/icons.js'; import { ViewModel, createDropdown, @@ -27,8 +28,6 @@ import '../../theme/fontsize.css'; import type { FontSizeOption } from '../fontconfig.js'; import type FontSizeCommand from './fontsizecommand.js'; -import fontSizeIcon from '../../theme/icons/font-size.svg'; - /** * The font size UI plugin. It introduces the `'fontSize'` dropdown. */ @@ -73,7 +72,7 @@ export default class FontSizeUI extends Plugin { // Create dropdown model. dropdownView.buttonView.set( { label: accessibleLabel, - icon: fontSizeIcon, + icon: IconFontSize, tooltip: true } ); @@ -101,7 +100,7 @@ export default class FontSizeUI extends Plugin { menuView.buttonView.set( { label: accessibleLabel, - icon: fontSizeIcon + icon: IconFontSize } ); menuView.bind( 'isEnabled' ).to( command ); diff --git a/packages/ckeditor5-font/tests/fontbackgroundcolor/fontbackgroundcolorui.js b/packages/ckeditor5-font/tests/fontbackgroundcolor/fontbackgroundcolorui.js index e0e4d382643..cfd7daa6b5f 100644 --- a/packages/ckeditor5-font/tests/fontbackgroundcolor/fontbackgroundcolorui.js +++ b/packages/ckeditor5-font/tests/fontbackgroundcolor/fontbackgroundcolorui.js @@ -5,11 +5,11 @@ /* global document */ +import { IconFontBackground } from 'ckeditor5/src/icons.js'; import FontBackgroundColorEditing from './../../src/fontbackgroundcolor/fontbackgroundcolorediting.js'; import FontBackgroundColorUI from './../../src/fontbackgroundcolor/fontbackgroundcolorui.js'; import ColorUI from './../../src/ui/colorui.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; -import fontBackgroundColorIcon from '../../theme/icons/font-background.svg'; describe( 'FontBckgroundColorUI', () => { let element, editor; @@ -42,7 +42,7 @@ describe( 'FontBckgroundColorUI', () => { expect( fontBackgroundColorUIPlugin.commandName ).to.equal( 'fontBackgroundColor' ); expect( fontBackgroundColorUIPlugin.componentName ).to.equal( 'fontBackgroundColor' ); - expect( fontBackgroundColorUIPlugin.icon ).to.equal( fontBackgroundColorIcon ); + expect( fontBackgroundColorUIPlugin.icon ).to.equal( IconFontBackground ); expect( fontBackgroundColorUIPlugin.dropdownLabel ).to.equal( 'Font Background Color' ); expect( fontBackgroundColorUIPlugin.columns ).to.equal( 5 ); } ); diff --git a/packages/ckeditor5-font/tests/fontcolor/fontcolorui.js b/packages/ckeditor5-font/tests/fontcolor/fontcolorui.js index b5398775595..cb60e0ac86d 100644 --- a/packages/ckeditor5-font/tests/fontcolor/fontcolorui.js +++ b/packages/ckeditor5-font/tests/fontcolor/fontcolorui.js @@ -5,11 +5,11 @@ /* global document */ +import { IconFontColor } from 'ckeditor5/src/icons.js'; import FontColorEditing from './../../src/fontcolor/fontcolorediting.js'; import FontColorUI from './../../src/fontcolor/fontcolorui.js'; import ColorUI from './../../src/ui/colorui.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; -import fontColorIcon from '../../theme/icons/font-color.svg'; describe( 'FontColorUI', () => { let element, editor; @@ -42,7 +42,7 @@ describe( 'FontColorUI', () => { expect( fontColorUIPlugin.commandName ).to.equal( 'fontColor' ); expect( fontColorUIPlugin.componentName ).to.equal( 'fontColor' ); - expect( fontColorUIPlugin.icon ).to.equal( fontColorIcon ); + expect( fontColorUIPlugin.icon ).to.equal( IconFontColor ); expect( fontColorUIPlugin.dropdownLabel ).to.equal( 'Font Color' ); expect( fontColorUIPlugin.columns ).to.equal( 5 ); } ); diff --git a/packages/ckeditor5-font/tests/fontfamily/fontfamilyui.js b/packages/ckeditor5-font/tests/fontfamily/fontfamilyui.js index 1eab86930e7..ef09039697d 100644 --- a/packages/ckeditor5-font/tests/fontfamily/fontfamilyui.js +++ b/packages/ckeditor5-font/tests/fontfamily/fontfamilyui.js @@ -5,11 +5,10 @@ /* global document */ +import { IconFontFamily } from 'ckeditor5/src/icons.js'; import FontFamilyEditing from '../../src/fontfamily/fontfamilyediting.js'; import FontFamilyUI from '../../src/fontfamily/fontfamilyui.js'; -import fontFamilyIcon from '../../theme/icons/font-family.svg'; - import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils.js'; @@ -77,7 +76,7 @@ describe( 'FontFamilyUI', () => { expect( button ).to.have.property( 'label', 'Font Family' ); expect( button ).to.have.property( 'tooltip', true ); - expect( button ).to.have.property( 'icon', fontFamilyIcon ); + expect( button ).to.have.property( 'icon', IconFontFamily ); } ); it( 'should add custom CSS class to dropdown', () => { @@ -288,7 +287,7 @@ describe( 'FontFamilyUI', () => { const button = subMenu.buttonView; expect( button ).to.have.property( 'label', 'Font Family' ); - expect( button ).to.have.property( 'icon', fontFamilyIcon ); + expect( button ).to.have.property( 'icon', IconFontFamily ); } ); it( 'button has binding to isEnabled', () => { diff --git a/packages/ckeditor5-font/tests/fontsize/fontsizeui.js b/packages/ckeditor5-font/tests/fontsize/fontsizeui.js index 4b5162f015e..6caaeaff16c 100644 --- a/packages/ckeditor5-font/tests/fontsize/fontsizeui.js +++ b/packages/ckeditor5-font/tests/fontsize/fontsizeui.js @@ -5,11 +5,10 @@ /* global document */ +import { IconFontSize } from 'ckeditor5/src/icons.js'; import FontSizeEditing from '../../src/fontsize/fontsizeediting.js'; import FontSizeUI from '../../src/fontsize/fontsizeui.js'; -import fontSizeIcon from '../../theme/icons/font-size.svg'; - import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils.js'; import { _clear as clearTranslations, add as addTranslations } from '@ckeditor/ckeditor5-utils/src/translation-service.js'; @@ -84,7 +83,7 @@ describe( 'FontSizeUI', () => { expect( button ).to.have.property( 'label', 'Font Size' ); expect( button ).to.have.property( 'tooltip', true ); - expect( button ).to.have.property( 'icon', fontSizeIcon ); + expect( button ).to.have.property( 'icon', IconFontSize ); } ); it( 'should add custom CSS class to dropdown', () => { @@ -327,7 +326,7 @@ describe( 'FontSizeUI', () => { const button = subMenu.buttonView; expect( button ).to.have.property( 'label', 'Font Size' ); - expect( button ).to.have.property( 'icon', fontSizeIcon ); + expect( button ).to.have.property( 'icon', IconFontSize ); } ); it( 'button has binding to isEnabled', () => { diff --git a/packages/ckeditor5-font/tsconfig.dist.json b/packages/ckeditor5-font/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-font/tsconfig.dist.json +++ b/packages/ckeditor5-font/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-font/tsconfig.json b/packages/ckeditor5-font/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-font/tsconfig.json +++ b/packages/ckeditor5-font/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-heading/tsconfig.dist.json b/packages/ckeditor5-heading/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-heading/tsconfig.dist.json +++ b/packages/ckeditor5-heading/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-heading/tsconfig.json b/packages/ckeditor5-heading/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-heading/tsconfig.json +++ b/packages/ckeditor5-heading/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-highlight/ckeditor5-metadata.json b/packages/ckeditor5-highlight/ckeditor5-metadata.json index c88a1e4ed0e..28333cb9baf 100644 --- a/packages/ckeditor5-highlight/ckeditor5-metadata.json +++ b/packages/ckeditor5-highlight/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "SplitButton", "name": "highlight", - "iconPath": "theme/icons/pen.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/pen.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-highlight/src/highlightui.ts b/packages/ckeditor5-highlight/src/highlightui.ts index 08ba1c1bf06..5c6e21ecd6a 100644 --- a/packages/ckeditor5-highlight/src/highlightui.ts +++ b/packages/ckeditor5-highlight/src/highlightui.ts @@ -7,7 +7,8 @@ * @module highlight/highlightui */ -import { Plugin, icons } from 'ckeditor5/src/core.js'; +import { Plugin } from 'ckeditor5/src/core.js'; +import { IconEraser, IconMarker, IconPen } from 'ckeditor5/src/icons.js'; import { addToolbarToDropdown, createDropdown, @@ -22,8 +23,6 @@ import { type DropdownView } from 'ckeditor5/src/ui.js'; -import markerIcon from './../theme/icons/marker.svg'; -import penIcon from './../theme/icons/pen.svg'; import type { HighlightOption } from './highlightconfig.js'; import type HighlightCommand from './highlightcommand.js'; @@ -112,7 +111,7 @@ export default class HighlightUI extends Plugin { const t = this.editor.t; const command: HighlightCommand = this.editor.commands.get( 'highlight' )!; - this._addButton( 'removeHighlight', t( 'Remove highlight' ), icons.eraser, null, button => { + this._addButton( 'removeHighlight', t( 'Remove highlight' ), IconEraser, null, button => { button.bind( 'isEnabled' ).to( command, 'isEnabled' ); } ); } @@ -320,7 +319,7 @@ export default class HighlightUI extends Plugin { buttonView.set( { label: t( 'Remove highlight' ), - icon: icons.eraser + icon: IconEraser } ); buttonView.delegate( 'execute' ).to( menuView ); @@ -354,7 +353,7 @@ function bindToolbarIconStyleToActiveColor( dropdownView: DropdownView ): void { * Returns icon for given highlighter type. */ function getIconForType( type: 'marker' | 'pen' ) { - return type === 'marker' ? markerIcon : penIcon; + return type === 'marker' ? IconMarker : IconPen; } type HighlightSplitButtonView = SplitButtonView & { diff --git a/packages/ckeditor5-highlight/tests/highlightui.js b/packages/ckeditor5-highlight/tests/highlightui.js index e35a565b3d0..456e5d8f340 100644 --- a/packages/ckeditor5-highlight/tests/highlightui.js +++ b/packages/ckeditor5-highlight/tests/highlightui.js @@ -4,14 +4,11 @@ */ /* global document */ +import { IconMarker, IconPen, IconEraser } from 'ckeditor5/src/icons.js'; import HighlightEditing from '../src/highlightediting.js'; import HighlightUI from '../src/highlightui.js'; -import markerIcon from '../theme/icons/marker.svg'; -import penIcon from '../theme/icons/pen.svg'; -import eraserIcon from '@ckeditor/ckeditor5-core/theme/icons/eraser.svg'; - import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils.js'; import { _clear as clearTranslations, add as addTranslations } from '@ckeditor/ckeditor5-utils/src/translation-service.js'; @@ -89,7 +86,7 @@ describe( 'HighlightUI', () => { expect( button ).to.have.property( 'label', 'Highlight' ); expect( button ).to.have.property( 'tooltip', true ); - expect( button ).to.have.property( 'icon', markerIcon ); + expect( button ).to.have.property( 'icon', IconMarker ); expect( button ).to.have.property( 'isToggleable', true ); } ); @@ -118,7 +115,7 @@ describe( 'HighlightUI', () => { command.value = undefined; expect( toolbar.items.map( item => item.icon ) ) - .to.deep.equal( [ markerIcon, markerIcon, markerIcon, markerIcon, penIcon, penIcon, undefined, eraserIcon ] ); + .to.deep.equal( [ IconMarker, IconMarker, IconMarker, IconMarker, IconPen, IconPen, undefined, IconEraser ] ); } ); it( 'should have proper colors in dropdown', () => { @@ -349,7 +346,7 @@ describe( 'HighlightUI', () => { it( 'should have correct attribute values', () => { expect( menuView.buttonView.label ).to.equal( 'Highlight' ); - expect( menuView.buttonView.icon ).to.equal( markerIcon ); + expect( menuView.buttonView.icon ).to.equal( IconMarker ); expect( menuView.buttonView.iconView.fillColor ).to.equal( 'transparent' ); } ); @@ -371,13 +368,13 @@ describe( 'HighlightUI', () => { it( 'should set #label and #icon of an option', () => { expect( dumpItems( 'icon' ) ).to.have.deep.ordered.members( [ - [ 'Yellow marker', markerIcon ], - [ 'Green marker', markerIcon ], - [ 'Pink marker', markerIcon ], - [ 'Blue marker', markerIcon ], - [ 'Red pen', penIcon ], - [ 'Green pen', penIcon ], - [ 'Remove highlight', eraserIcon ] + [ 'Yellow marker', IconMarker ], + [ 'Green marker', IconMarker ], + [ 'Pink marker', IconMarker ], + [ 'Blue marker', IconMarker ], + [ 'Red pen', IconPen ], + [ 'Green pen', IconPen ], + [ 'Remove highlight', IconEraser ] ] ); } ); @@ -464,7 +461,7 @@ describe( 'HighlightUI', () => { it( 'should diplay the remove highlight button at the end', () => { expect( menuView.panelView.children.first.items.get( 6 ) ).to.be.instanceOf( ListSeparatorView ); - expect( menuView.panelView.children.first.items.last.children.first.icon ).to.equal( eraserIcon ); + expect( menuView.panelView.children.first.items.last.children.first.icon ).to.equal( IconEraser ); } ); function dumpItems( propertyName ) { @@ -488,7 +485,7 @@ describe( 'HighlightUI', () => { expect( editor.ui.componentFactory.has( 'removeHighlight' ) ).to.be.true; expect( removeHighlightButton ).to.have.property( 'tooltip', true ); expect( removeHighlightButton ).to.have.property( 'label', 'Remove highlight' ); - expect( removeHighlightButton ).to.have.property( 'icon', eraserIcon ); + expect( removeHighlightButton ).to.have.property( 'icon', IconEraser ); } ); it( 'should execute the command only once', () => { diff --git a/packages/ckeditor5-highlight/tsconfig.dist.json b/packages/ckeditor5-highlight/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-highlight/tsconfig.dist.json +++ b/packages/ckeditor5-highlight/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-highlight/tsconfig.json b/packages/ckeditor5-highlight/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-highlight/tsconfig.json +++ b/packages/ckeditor5-highlight/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-horizontal-line/ckeditor5-metadata.json b/packages/ckeditor5-horizontal-line/ckeditor5-metadata.json index 98fc7b1a5de..cd616859256 100644 --- a/packages/ckeditor5-horizontal-line/ckeditor5-metadata.json +++ b/packages/ckeditor5-horizontal-line/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "horizontalLine", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/horizontalline.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/horizontal-line.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-horizontal-line/tsconfig.dist.json b/packages/ckeditor5-horizontal-line/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-horizontal-line/tsconfig.dist.json +++ b/packages/ckeditor5-horizontal-line/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-horizontal-line/tsconfig.json b/packages/ckeditor5-horizontal-line/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-horizontal-line/tsconfig.json +++ b/packages/ckeditor5-horizontal-line/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-html-embed/ckeditor5-metadata.json b/packages/ckeditor5-html-embed/ckeditor5-metadata.json index 30542858005..6ddb85ad92f 100644 --- a/packages/ckeditor5-html-embed/ckeditor5-metadata.json +++ b/packages/ckeditor5-html-embed/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "htmlEmbed", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/html.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/html.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-html-embed/tsconfig.dist.json b/packages/ckeditor5-html-embed/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-html-embed/tsconfig.dist.json +++ b/packages/ckeditor5-html-embed/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-html-embed/tsconfig.json b/packages/ckeditor5-html-embed/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-html-embed/tsconfig.json +++ b/packages/ckeditor5-html-embed/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-html-support/tsconfig.dist.json b/packages/ckeditor5-html-support/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-html-support/tsconfig.dist.json +++ b/packages/ckeditor5-html-support/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-html-support/tsconfig.json b/packages/ckeditor5-html-support/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-html-support/tsconfig.json +++ b/packages/ckeditor5-html-support/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-icons/CHANGELOG.md b/packages/ckeditor5-icons/CHANGELOG.md new file mode 100644 index 00000000000..01711a3f749 --- /dev/null +++ b/packages/ckeditor5-icons/CHANGELOG.md @@ -0,0 +1,4 @@ +Changelog +========= + +All changes in the package are documented in https://github.com/ckeditor/ckeditor5/blob/master/CHANGELOG.md. diff --git a/packages/ckeditor5-icons/CONTRIBUTING.md b/packages/ckeditor5-icons/CONTRIBUTING.md new file mode 100644 index 00000000000..ae3ecb8ff7d --- /dev/null +++ b/packages/ckeditor5-icons/CONTRIBUTING.md @@ -0,0 +1,4 @@ +Contributing +======================================== + +See the [official contributors' guide to CKEditor 5](https://ckeditor.com/docs/ckeditor5/latest/framework/contributing/contributing.html) to learn more. diff --git a/packages/ckeditor5-icons/LICENSE.md b/packages/ckeditor5-icons/LICENSE.md new file mode 100644 index 00000000000..92cd61ea37a --- /dev/null +++ b/packages/ckeditor5-icons/LICENSE.md @@ -0,0 +1,26 @@ +Software License Agreement +========================== + +**CKEditor 5 Image feature** (https://github.com/ckeditor/ckeditor5)
+Copyright (c) 2003–2025, [CKSource Holding sp. z o.o.](https://cksource.com) All rights reserved. + +Licensed under a dual-license model, this software is available under: + +* the [GNU General Public License Version 2 or later](https://www.gnu.org/licenses/gpl.html), +* or commercial license terms from CKSource Holding sp. z o.o. + +For more information, see: [https://ckeditor.com/legal/ckeditor-licensing-options](https://ckeditor.com/legal/ckeditor-licensing-options). + +Sources of Intellectual Property Included in CKEditor +----------------------------------------------------- + +Where not otherwise indicated, all CKEditor content is authored by CKSource engineers and consists of CKSource-owned intellectual property. In some specific instances, CKEditor will incorporate work done by developers outside of CKSource with their express permission. + +The following libraries are included in CKEditor under the [MIT license](https://opensource.org/licenses/MIT): + +* Lodash - Copyright (c) JS Foundation and other contributors https://js.foundation/. Based on Underscore.js, copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors http://underscorejs.org/. + +Trademarks +---------- + +**CKEditor** is a trademark of [CKSource Holding sp. z o.o.](https://cksource.com) All other brand and product names are trademarks, registered trademarks, or service marks of their respective holders. diff --git a/packages/ckeditor5-icons/README.md b/packages/ckeditor5-icons/README.md new file mode 100644 index 00000000000..7203c04e086 --- /dev/null +++ b/packages/ckeditor5-icons/README.md @@ -0,0 +1,29 @@ +CKEditor 5 icons +======================================== + +[![npm version](https://badge.fury.io/js/%40ckeditor%2Fckeditor5-icons.svg)](https://www.npmjs.com/package/@ckeditor/ckeditor5-icons) +[![Coverage Status](https://coveralls.io/repos/github/ckeditor/ckeditor5/badge.svg?branch=master)](https://coveralls.io/github/ckeditor/ckeditor5?branch=master) +[![CircleCI](https://circleci.com/gh/ckeditor/ckeditor5.svg?style=shield)](https://app.circleci.com/pipelines/github/ckeditor/ckeditor5?branch=master) + +This package contains icons for CKEditor 5. + +## Installation + +This plugin is part of the `ckeditor5` package. Install the whole package to use it. + +```bash +npm install ckeditor5 +``` + +## Create free account + +If you want to check full CKEditor 5 capabilities, sign up for a [free non-commitment 14-day trial](https://portal.ckeditor.com/checkout?plan=free). + +## License + +Licensed under a dual-license model, this software is available under: + +* the [GNU General Public License Version 2 or later](https://www.gnu.org/licenses/gpl.html), +* or commercial license terms from CKSource Holding sp. z o.o. + +For more information, see: [https://ckeditor.com/legal/ckeditor-licensing-options](https://ckeditor.com/legal/ckeditor-licensing-options). diff --git a/packages/ckeditor5-icons/package.json b/packages/ckeditor5-icons/package.json new file mode 100644 index 00000000000..f8fe28b5864 --- /dev/null +++ b/packages/ckeditor5-icons/package.json @@ -0,0 +1,40 @@ +{ + "name": "@ckeditor/ckeditor5-icons", + "version": "44.1.0", + "description": "Icons for CKEditor 5.", + "keywords": [ + "ckeditor", + "ckeditor5", + "ckeditor 5", + "ckeditor5-lib", + "ckeditor5-dll" + ], + "type": "module", + "main": "src/index.ts", + "author": "CKSource (http://cksource.com/)", + "license": "SEE LICENSE IN LICENSE.md", + "homepage": "https://ckeditor.com/ckeditor-5", + "bugs": "https://github.com/ckeditor/ckeditor5/issues", + "repository": { + "type": "git", + "url": "https://github.com/ckeditor/ckeditor5.git", + "directory": "packages/ckeditor5-icons" + }, + "devDependencies": { + "typescript": "5.0.4", + "webpack": "^5.94.0", + "webpack-cli": "^5.1.4" + }, + "files": [ + "dist", + "src/**/*.js", + "src/**/*.d.ts", + "theme", + "build", + "CHANGELOG.md" + ], + "scripts": { + "build": "tsc -p ./tsconfig.json", + "build:dist": "node ../../scripts/nim/build-package.mjs" + } +} diff --git a/packages/ckeditor5-icons/src/index.ts b/packages/ckeditor5-icons/src/index.ts new file mode 100644 index 00000000000..17c8ed1356d --- /dev/null +++ b/packages/ckeditor5-icons/src/index.ts @@ -0,0 +1,155 @@ +/** + * @license Copyright (c) 2003-2025, CKSource Holding sp. z o.o. All rights reserved. + * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options + */ + +export { default as IconAccessibility } from 'accessibility.svg'; +export { default as IconAddComment } from 'add-comment.svg'; +export { default as IconAlignBottom } from 'align-bottom.svg'; +export { default as IconAlignCenter } from 'align-center.svg'; +export { default as IconAlignJustify } from 'align-justify.svg'; +export { default as IconAlignLeft } from 'align-left.svg'; +export { default as IconAlignMiddle } from 'align-middle.svg'; +export { default as IconAlignRight } from 'align-right.svg'; +export { default as IconAlignTop } from 'align-top.svg'; +export { default as IconArrowDown } from 'arrow-down.svg'; +export { default as IconArrowUp } from 'arrow-up.svg'; +export { default as IconBold } from 'bold.svg'; +export { default as IconBookmarkInline } from 'bookmark-inline.svg'; +export { default as IconBookmark } from 'bookmark.svg'; +export { default as IconBrowseFiles } from 'browse-files.svg'; +export { default as IconBulletedList } from 'bulleted-list.svg'; +export { default as IconCancel } from 'cancel.svg'; +export { default as IconCaption } from 'caption.svg'; +export { default as IconCaseChange } from 'case-change.svg'; +export { default as IconCheck } from 'check.svg'; +export { default as IconChevronDown } from 'chevron-down.svg'; +export { default as IconChevronUp } from 'chevron-up.svg'; +export { default as IconCkboxImageEdit } from 'ckbox-image-edit.svg'; +export { default as IconCodeBlock } from 'code-block.svg'; +export { default as IconCode } from 'code.svg'; +export { default as IconCog } from 'cog.svg'; +export { default as IconColorPalette } from 'color-palette.svg'; +export { default as IconColorTileCheck } from 'color-tile-check.svg'; +export { default as IconCommentsArchive } from 'comments-archive.svg'; +export { default as IconContentLock } from 'content-lock.svg'; +export { default as IconContentUnlock } from 'content-unlock.svg'; +export { default as IconCopy } from 'copy.svg'; +export { default as IconDragHandle } from 'drag-handle.svg'; +export { default as IconDragIndicator } from 'drag-indicator.svg'; +export { default as IconDropdownArrow } from 'dropdown-arrow.svg'; +export { default as IconEditComment } from 'edit-comment.svg'; +export { default as IconEraser } from 'eraser.svg'; +export { default as IconError } from 'error.svg'; +export { default as IconExportPdf } from 'export-pdf.svg'; +export { default as IconExportWord } from 'export-word.svg'; +export { default as IconFindReplace } from 'find-replace.svg'; +export { default as IconFontBackground } from 'font-background.svg'; +export { default as IconFontColor } from 'font-color.svg'; +export { default as IconFontFamily } from 'font-family.svg'; +export { default as IconFontSize } from 'font-size.svg'; +export { default as IconHeading1 } from 'heading1.svg'; +export { default as IconHeading2 } from 'heading2.svg'; +export { default as IconHeading3 } from 'heading3.svg'; +export { default as IconHeading4 } from 'heading4.svg'; +export { default as IconHeading5 } from 'heading5.svg'; +export { default as IconHeading6 } from 'heading6.svg'; +export { default as IconHistory } from 'history.svg'; +export { default as IconHorizontalLine } from 'horizontal-line.svg'; +export { default as IconHtml } from 'html.svg'; +export { default as IconImageAssetManager } from 'image-asset-manager.svg'; +export { default as IconImage } from 'image.svg'; +export { default as IconImageUpload } from 'image-upload.svg'; +export { default as IconImageRrl } from 'image-url.svg'; +export { default as IconImportExport } from 'import-export.svg'; +export { default as IconImportWord } from 'import-word.svg'; +export { default as IconIndent } from 'indent.svg'; +export { default as IconInsertMergeField } from 'insert-merge-field.svg'; +export { default as IconItalic } from 'italic.svg'; +export { default as IconLegalStyleList } from 'legal-style-list.svg'; +export { default as IconLink } from 'link.svg'; +export { default as IconListStyleCircle } from 'list-style-circle.svg'; +export { default as IconListStyleDecimalLeadingZero } from 'list-style-decimal-leading-zero.svg'; +export { default as IconListStyleDecimal } from 'list-style-decimal.svg'; +export { default as IconListStyleDisc } from 'list-style-disc.svg'; +export { default as IconListStyleLowerLatin } from 'list-style-lower-latin.svg'; +export { default as IconListStyleLowerRoman } from 'list-style-lower-roman.svg'; +export { default as IconListStyleSquare } from 'list-style-square.svg'; +export { default as IconListStyleUpperLatin } from 'list-style-upper-latin.svg'; +export { default as IconListStyleUpperRoman } from 'list-style-upper-roman.svg'; +export { default as IconLoupe } from 'loupe.svg'; +export { default as IconLowVision } from 'low-vision.svg'; +export { default as IconMagicWand } from 'magic-wand.svg'; +export { default as IconMarker } from 'marker.svg'; +export { default as IconMediaPlaceholder } from 'media-placeholder.svg'; +export { default as IconMedia } from 'media.svg'; +export { default as IconMultiLevelList } from 'multi-level-list.svg'; +export { default as IconNextArrow } from 'next-arrow.svg'; +export { default as IconNotification } from 'notification.svg'; +export { default as IconNumberedList } from 'numbered-list.svg'; +export { default as IconObjectCenter } from 'object-center.svg'; +export { default as IconObjectFullWidth } from 'object-full-width.svg'; +export { default as IconObjectInlineLeft } from 'object-inline-left.svg'; +export { default as IconObjectInlineRight } from 'object-inline-right.svg'; +export { default as IconObjectInline } from 'object-inline.svg'; +export { default as IconObjectLeft } from 'object-left.svg'; +export { default as IconObjectRight } from 'object-right.svg'; +export { default as IconObjectSizeCustom } from 'object-size-custom.svg'; +export { default as IconObjectSizeFull } from 'object-size-full.svg'; +export { default as IconObjectSizeLarge } from 'object-size-large.svg'; +export { default as IconObjectSizeMedium } from 'object-size-medium.svg'; +export { default as IconObjectSizeSmall } from 'object-size-small.svg'; +export { default as IconOutdent } from 'outdent.svg'; +export { default as IconPageBreak } from 'page-break.svg'; +export { default as IconPaginationExample } from 'pagination-example.svg'; +export { default as IconPaintRollerCursorDefault } from 'paint-roller-cursor-default.svg'; +export { default as IconPaintRollerCursorText } from 'paint-roller-cursor-text.svg'; +export { default as IconPaintRoller } from 'paint-roller.svg'; +export { default as IconParagraph } from 'paragraph.svg'; +export { default as IconPencil } from 'pencil.svg'; +export { default as IconPen } from 'pen.svg'; +export { default as IconPilcrow } from 'pilcrow.svg'; +export { default as IconPlay } from 'play.svg'; +export { default as IconPlus } from 'plus.svg'; +export { default as IconPreviewMergeFields } from 'preview-merge-fields.svg'; +export { default as IconPreviousArrow } from 'previous-arrow.svg'; +export { default as IconPrint } from 'print.svg'; +export { default as IconProjectLogo } from 'project-logo.svg'; +export { default as IconQuote } from 'quote.svg'; +export { default as IconRedo } from 'redo.svg'; +export { default as IconRemoveComment } from 'remove-comment.svg'; +export { default as IconRemoveFormat } from 'remove-format.svg'; +export { default as IconRemove } from 'remove.svg'; +export { default as IconReturnArrow } from 'return-arrow.svg'; +export { default as IconRevisionHistory } from 'revision-history.svg'; +export { default as IconRobotPencil } from 'robot-pencil.svg'; +export { default as IconSelectAll } from 'select-all.svg'; +export { default as IconShowBlocks } from 'show-blocks.svg'; +export { default as IconSourceEditing } from 'source-editing.svg'; +export { default as IconSpecialCharacters } from 'special-characters.svg'; +export { default as IconStrikethrough } from 'strikethrough.svg'; +export { default as IconSubmit } from 'submit.svg'; +export { default as IconSubscript } from 'subscript.svg'; +export { default as IconSuperscript } from 'superscript.svg'; +export { default as IconTableCellProperties } from 'table-cell-properties.svg'; +export { default as IconTableColumn } from 'table-column.svg'; +export { default as IconTableMergeCell } from 'table-merge-cell.svg'; +export { default as IconTableOfContents } from 'table-of-contents.svg'; +export { default as IconTableProperties } from 'table-properties.svg'; +export { default as IconTableRow } from 'table-row.svg'; +export { default as IconTable } from 'table.svg'; +export { default as IconTemplateGeneric } from 'template-generic.svg'; +export { default as IconTemplate } from 'template.svg'; +export { default as IconTextAlternative } from 'text-alternative.svg'; +export { default as IconText } from 'text.svg'; +export { default as IconThreeVerticalDots } from 'three-vertical-dots.svg'; +export { default as IconTodoList } from 'todo-list.svg'; +export { default as IconTrackChangesAccept } from 'track-changes-accept.svg'; +export { default as IconTrackChangesDiscard } from 'track-changes-discard.svg'; +export { default as IconTrackChanges } from 'track-changes.svg'; +export { default as IconTwitter } from 'twitter.svg'; +export { default as IconUnderline } from 'underline.svg'; +export { default as IconUndo } from 'undo.svg'; +export { default as IconUnlink } from 'unlink.svg'; +export { default as IconUser } from 'user.svg'; +export { default as IconWarning } from 'warning.svg'; diff --git a/packages/ckeditor5-ui/theme/icons/accessibility.svg b/packages/ckeditor5-icons/theme/accessibility.svg similarity index 100% rename from packages/ckeditor5-ui/theme/icons/accessibility.svg rename to packages/ckeditor5-icons/theme/accessibility.svg diff --git a/packages/ckeditor5-icons/theme/add-comment.svg b/packages/ckeditor5-icons/theme/add-comment.svg new file mode 100644 index 00000000000..1a67e532e5a --- /dev/null +++ b/packages/ckeditor5-icons/theme/add-comment.svg @@ -0,0 +1,11 @@ + + + diff --git a/packages/ckeditor5-core/theme/icons/align-bottom.svg b/packages/ckeditor5-icons/theme/align-bottom.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/align-bottom.svg rename to packages/ckeditor5-icons/theme/align-bottom.svg diff --git a/packages/ckeditor5-core/theme/icons/align-center.svg b/packages/ckeditor5-icons/theme/align-center.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/align-center.svg rename to packages/ckeditor5-icons/theme/align-center.svg diff --git a/packages/ckeditor5-core/theme/icons/align-justify.svg b/packages/ckeditor5-icons/theme/align-justify.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/align-justify.svg rename to packages/ckeditor5-icons/theme/align-justify.svg diff --git a/packages/ckeditor5-core/theme/icons/align-left.svg b/packages/ckeditor5-icons/theme/align-left.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/align-left.svg rename to packages/ckeditor5-icons/theme/align-left.svg diff --git a/packages/ckeditor5-core/theme/icons/align-middle.svg b/packages/ckeditor5-icons/theme/align-middle.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/align-middle.svg rename to packages/ckeditor5-icons/theme/align-middle.svg diff --git a/packages/ckeditor5-core/theme/icons/align-right.svg b/packages/ckeditor5-icons/theme/align-right.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/align-right.svg rename to packages/ckeditor5-icons/theme/align-right.svg diff --git a/packages/ckeditor5-core/theme/icons/align-top.svg b/packages/ckeditor5-icons/theme/align-top.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/align-top.svg rename to packages/ckeditor5-icons/theme/align-top.svg diff --git a/packages/ckeditor5-icons/theme/arrow-down.svg b/packages/ckeditor5-icons/theme/arrow-down.svg new file mode 100644 index 00000000000..7190bc6b28c --- /dev/null +++ b/packages/ckeditor5-icons/theme/arrow-down.svg @@ -0,0 +1 @@ + diff --git a/packages/ckeditor5-icons/theme/arrow-up.svg b/packages/ckeditor5-icons/theme/arrow-up.svg new file mode 100644 index 00000000000..f6f66d88f85 --- /dev/null +++ b/packages/ckeditor5-icons/theme/arrow-up.svg @@ -0,0 +1 @@ + diff --git a/packages/ckeditor5-core/theme/icons/bold.svg b/packages/ckeditor5-icons/theme/bold.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/bold.svg rename to packages/ckeditor5-icons/theme/bold.svg diff --git a/packages/ckeditor5-core/theme/icons/bookmark_inline.svg b/packages/ckeditor5-icons/theme/bookmark-inline.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/bookmark_inline.svg rename to packages/ckeditor5-icons/theme/bookmark-inline.svg diff --git a/packages/ckeditor5-core/theme/icons/bookmark.svg b/packages/ckeditor5-icons/theme/bookmark.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/bookmark.svg rename to packages/ckeditor5-icons/theme/bookmark.svg diff --git a/packages/ckeditor5-core/theme/icons/browse-files.svg b/packages/ckeditor5-icons/theme/browse-files.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/browse-files.svg rename to packages/ckeditor5-icons/theme/browse-files.svg diff --git a/packages/ckeditor5-core/theme/icons/bulletedlist.svg b/packages/ckeditor5-icons/theme/bulleted-list.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/bulletedlist.svg rename to packages/ckeditor5-icons/theme/bulleted-list.svg diff --git a/packages/ckeditor5-core/theme/icons/cancel.svg b/packages/ckeditor5-icons/theme/cancel.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/cancel.svg rename to packages/ckeditor5-icons/theme/cancel.svg diff --git a/packages/ckeditor5-core/theme/icons/caption.svg b/packages/ckeditor5-icons/theme/caption.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/caption.svg rename to packages/ckeditor5-icons/theme/caption.svg diff --git a/packages/ckeditor5-icons/theme/case-change.svg b/packages/ckeditor5-icons/theme/case-change.svg new file mode 100644 index 00000000000..96725424057 --- /dev/null +++ b/packages/ckeditor5-icons/theme/case-change.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/packages/ckeditor5-core/theme/icons/check.svg b/packages/ckeditor5-icons/theme/check.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/check.svg rename to packages/ckeditor5-icons/theme/check.svg diff --git a/packages/ckeditor5-icons/theme/chevron-down.svg b/packages/ckeditor5-icons/theme/chevron-down.svg new file mode 100644 index 00000000000..a6f9d8de409 --- /dev/null +++ b/packages/ckeditor5-icons/theme/chevron-down.svg @@ -0,0 +1 @@ + diff --git a/packages/ckeditor5-icons/theme/chevron-up.svg b/packages/ckeditor5-icons/theme/chevron-up.svg new file mode 100644 index 00000000000..c5fedea38a0 --- /dev/null +++ b/packages/ckeditor5-icons/theme/chevron-up.svg @@ -0,0 +1 @@ + diff --git a/packages/ckeditor5-ckbox/theme/icons/ckbox-image-edit.svg b/packages/ckeditor5-icons/theme/ckbox-image-edit.svg similarity index 100% rename from packages/ckeditor5-ckbox/theme/icons/ckbox-image-edit.svg rename to packages/ckeditor5-icons/theme/ckbox-image-edit.svg diff --git a/packages/ckeditor5-core/theme/icons/codeblock.svg b/packages/ckeditor5-icons/theme/code-block.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/codeblock.svg rename to packages/ckeditor5-icons/theme/code-block.svg diff --git a/packages/ckeditor5-basic-styles/theme/icons/code.svg b/packages/ckeditor5-icons/theme/code.svg similarity index 100% rename from packages/ckeditor5-basic-styles/theme/icons/code.svg rename to packages/ckeditor5-icons/theme/code.svg diff --git a/packages/ckeditor5-core/theme/icons/cog.svg b/packages/ckeditor5-icons/theme/cog.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/cog.svg rename to packages/ckeditor5-icons/theme/cog.svg diff --git a/packages/ckeditor5-core/theme/icons/color-palette.svg b/packages/ckeditor5-icons/theme/color-palette.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/color-palette.svg rename to packages/ckeditor5-icons/theme/color-palette.svg diff --git a/packages/ckeditor5-ui/theme/icons/color-tile-check.svg b/packages/ckeditor5-icons/theme/color-tile-check.svg similarity index 100% rename from packages/ckeditor5-ui/theme/icons/color-tile-check.svg rename to packages/ckeditor5-icons/theme/color-tile-check.svg diff --git a/packages/ckeditor5-icons/theme/comments-archive.svg b/packages/ckeditor5-icons/theme/comments-archive.svg new file mode 100644 index 00000000000..4079b3302ec --- /dev/null +++ b/packages/ckeditor5-icons/theme/comments-archive.svg @@ -0,0 +1,11 @@ + + + diff --git a/packages/ckeditor5-restricted-editing/theme/icons/contentlock.svg b/packages/ckeditor5-icons/theme/content-lock.svg similarity index 100% rename from packages/ckeditor5-restricted-editing/theme/icons/contentlock.svg rename to packages/ckeditor5-icons/theme/content-lock.svg diff --git a/packages/ckeditor5-restricted-editing/theme/icons/contentunlock.svg b/packages/ckeditor5-icons/theme/content-unlock.svg similarity index 100% rename from packages/ckeditor5-restricted-editing/theme/icons/contentunlock.svg rename to packages/ckeditor5-icons/theme/content-unlock.svg diff --git a/packages/ckeditor5-icons/theme/copy.svg b/packages/ckeditor5-icons/theme/copy.svg new file mode 100644 index 00000000000..ee66767ea4a --- /dev/null +++ b/packages/ckeditor5-icons/theme/copy.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/packages/ckeditor5-widget/theme/icons/drag-handle.svg b/packages/ckeditor5-icons/theme/drag-handle.svg similarity index 100% rename from packages/ckeditor5-widget/theme/icons/drag-handle.svg rename to packages/ckeditor5-icons/theme/drag-handle.svg diff --git a/packages/ckeditor5-core/theme/icons/drag-indicator.svg b/packages/ckeditor5-icons/theme/drag-indicator.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/drag-indicator.svg rename to packages/ckeditor5-icons/theme/drag-indicator.svg diff --git a/packages/ckeditor5-ui/theme/icons/dropdown-arrow.svg b/packages/ckeditor5-icons/theme/dropdown-arrow.svg similarity index 100% rename from packages/ckeditor5-ui/theme/icons/dropdown-arrow.svg rename to packages/ckeditor5-icons/theme/dropdown-arrow.svg diff --git a/packages/ckeditor5-icons/theme/edit-comment.svg b/packages/ckeditor5-icons/theme/edit-comment.svg new file mode 100644 index 00000000000..f5aa9e092ef --- /dev/null +++ b/packages/ckeditor5-icons/theme/edit-comment.svg @@ -0,0 +1,11 @@ + + + diff --git a/packages/ckeditor5-core/theme/icons/eraser.svg b/packages/ckeditor5-icons/theme/eraser.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/eraser.svg rename to packages/ckeditor5-icons/theme/eraser.svg diff --git a/packages/ckeditor5-icons/theme/error.svg b/packages/ckeditor5-icons/theme/error.svg new file mode 100644 index 00000000000..5c65387d3d9 --- /dev/null +++ b/packages/ckeditor5-icons/theme/error.svg @@ -0,0 +1 @@ + diff --git a/packages/ckeditor5-icons/theme/export-pdf.svg b/packages/ckeditor5-icons/theme/export-pdf.svg new file mode 100644 index 00000000000..7550e994265 --- /dev/null +++ b/packages/ckeditor5-icons/theme/export-pdf.svg @@ -0,0 +1 @@ + diff --git a/packages/ckeditor5-icons/theme/export-word.svg b/packages/ckeditor5-icons/theme/export-word.svg new file mode 100644 index 00000000000..d8fa35a80b3 --- /dev/null +++ b/packages/ckeditor5-icons/theme/export-word.svg @@ -0,0 +1 @@ + diff --git a/packages/ckeditor5-find-and-replace/theme/icons/find-replace.svg b/packages/ckeditor5-icons/theme/find-replace.svg similarity index 100% rename from packages/ckeditor5-find-and-replace/theme/icons/find-replace.svg rename to packages/ckeditor5-icons/theme/find-replace.svg diff --git a/packages/ckeditor5-font/theme/icons/font-background.svg b/packages/ckeditor5-icons/theme/font-background.svg similarity index 100% rename from packages/ckeditor5-font/theme/icons/font-background.svg rename to packages/ckeditor5-icons/theme/font-background.svg diff --git a/packages/ckeditor5-font/theme/icons/font-color.svg b/packages/ckeditor5-icons/theme/font-color.svg similarity index 100% rename from packages/ckeditor5-font/theme/icons/font-color.svg rename to packages/ckeditor5-icons/theme/font-color.svg diff --git a/packages/ckeditor5-font/theme/icons/font-family.svg b/packages/ckeditor5-icons/theme/font-family.svg similarity index 100% rename from packages/ckeditor5-font/theme/icons/font-family.svg rename to packages/ckeditor5-icons/theme/font-family.svg diff --git a/packages/ckeditor5-font/theme/icons/font-size.svg b/packages/ckeditor5-icons/theme/font-size.svg similarity index 100% rename from packages/ckeditor5-font/theme/icons/font-size.svg rename to packages/ckeditor5-icons/theme/font-size.svg diff --git a/packages/ckeditor5-core/theme/icons/heading1.svg b/packages/ckeditor5-icons/theme/heading1.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/heading1.svg rename to packages/ckeditor5-icons/theme/heading1.svg diff --git a/packages/ckeditor5-core/theme/icons/heading2.svg b/packages/ckeditor5-icons/theme/heading2.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/heading2.svg rename to packages/ckeditor5-icons/theme/heading2.svg diff --git a/packages/ckeditor5-core/theme/icons/heading3.svg b/packages/ckeditor5-icons/theme/heading3.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/heading3.svg rename to packages/ckeditor5-icons/theme/heading3.svg diff --git a/packages/ckeditor5-core/theme/icons/heading4.svg b/packages/ckeditor5-icons/theme/heading4.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/heading4.svg rename to packages/ckeditor5-icons/theme/heading4.svg diff --git a/packages/ckeditor5-core/theme/icons/heading5.svg b/packages/ckeditor5-icons/theme/heading5.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/heading5.svg rename to packages/ckeditor5-icons/theme/heading5.svg diff --git a/packages/ckeditor5-core/theme/icons/heading6.svg b/packages/ckeditor5-icons/theme/heading6.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/heading6.svg rename to packages/ckeditor5-icons/theme/heading6.svg diff --git a/packages/ckeditor5-core/theme/icons/history.svg b/packages/ckeditor5-icons/theme/history.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/history.svg rename to packages/ckeditor5-icons/theme/history.svg diff --git a/packages/ckeditor5-core/theme/icons/horizontalline.svg b/packages/ckeditor5-icons/theme/horizontal-line.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/horizontalline.svg rename to packages/ckeditor5-icons/theme/horizontal-line.svg diff --git a/packages/ckeditor5-core/theme/icons/html.svg b/packages/ckeditor5-icons/theme/html.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/html.svg rename to packages/ckeditor5-icons/theme/html.svg diff --git a/packages/ckeditor5-core/theme/icons/image-asset-manager.svg b/packages/ckeditor5-icons/theme/image-asset-manager.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/image-asset-manager.svg rename to packages/ckeditor5-icons/theme/image-asset-manager.svg diff --git a/packages/ckeditor5-core/theme/icons/image-upload.svg b/packages/ckeditor5-icons/theme/image-upload.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/image-upload.svg rename to packages/ckeditor5-icons/theme/image-upload.svg diff --git a/packages/ckeditor5-core/theme/icons/image-url.svg b/packages/ckeditor5-icons/theme/image-url.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/image-url.svg rename to packages/ckeditor5-icons/theme/image-url.svg diff --git a/packages/ckeditor5-core/theme/icons/image.svg b/packages/ckeditor5-icons/theme/image.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/image.svg rename to packages/ckeditor5-icons/theme/image.svg diff --git a/packages/ckeditor5-core/theme/icons/importexport.svg b/packages/ckeditor5-icons/theme/import-export.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/importexport.svg rename to packages/ckeditor5-icons/theme/import-export.svg diff --git a/packages/ckeditor5-icons/theme/importword.svg b/packages/ckeditor5-icons/theme/importword.svg new file mode 100644 index 00000000000..5fbb56cb531 --- /dev/null +++ b/packages/ckeditor5-icons/theme/importword.svg @@ -0,0 +1 @@ + diff --git a/packages/ckeditor5-core/theme/icons/indent.svg b/packages/ckeditor5-icons/theme/indent.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/indent.svg rename to packages/ckeditor5-icons/theme/indent.svg diff --git a/packages/ckeditor5-icons/theme/insert-merge-field.svg b/packages/ckeditor5-icons/theme/insert-merge-field.svg new file mode 100644 index 00000000000..d65063db6f6 --- /dev/null +++ b/packages/ckeditor5-icons/theme/insert-merge-field.svg @@ -0,0 +1,7 @@ + + + + + + + diff --git a/packages/ckeditor5-basic-styles/theme/icons/italic.svg b/packages/ckeditor5-icons/theme/italic.svg similarity index 100% rename from packages/ckeditor5-basic-styles/theme/icons/italic.svg rename to packages/ckeditor5-icons/theme/italic.svg diff --git a/packages/ckeditor5-icons/theme/legal-style-list.svg b/packages/ckeditor5-icons/theme/legal-style-list.svg new file mode 100644 index 00000000000..d5ad369b3e6 --- /dev/null +++ b/packages/ckeditor5-icons/theme/legal-style-list.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/packages/ckeditor5-link/theme/icons/link.svg b/packages/ckeditor5-icons/theme/link.svg similarity index 100% rename from packages/ckeditor5-link/theme/icons/link.svg rename to packages/ckeditor5-icons/theme/link.svg diff --git a/packages/ckeditor5-list/theme/icons/liststylecircle.svg b/packages/ckeditor5-icons/theme/list-style-circle.svg similarity index 100% rename from packages/ckeditor5-list/theme/icons/liststylecircle.svg rename to packages/ckeditor5-icons/theme/list-style-circle.svg diff --git a/packages/ckeditor5-list/theme/icons/liststyledecimalleadingzero.svg b/packages/ckeditor5-icons/theme/list-style-decimal-leading-zero.svg similarity index 100% rename from packages/ckeditor5-list/theme/icons/liststyledecimalleadingzero.svg rename to packages/ckeditor5-icons/theme/list-style-decimal-leading-zero.svg diff --git a/packages/ckeditor5-list/theme/icons/liststyledecimal.svg b/packages/ckeditor5-icons/theme/list-style-decimal.svg similarity index 100% rename from packages/ckeditor5-list/theme/icons/liststyledecimal.svg rename to packages/ckeditor5-icons/theme/list-style-decimal.svg diff --git a/packages/ckeditor5-list/theme/icons/liststyledisc.svg b/packages/ckeditor5-icons/theme/list-style-disc.svg similarity index 100% rename from packages/ckeditor5-list/theme/icons/liststyledisc.svg rename to packages/ckeditor5-icons/theme/list-style-disc.svg diff --git a/packages/ckeditor5-list/theme/icons/liststylelowerlatin.svg b/packages/ckeditor5-icons/theme/list-style-lower-latin.svg similarity index 100% rename from packages/ckeditor5-list/theme/icons/liststylelowerlatin.svg rename to packages/ckeditor5-icons/theme/list-style-lower-latin.svg diff --git a/packages/ckeditor5-list/theme/icons/liststylelowerroman.svg b/packages/ckeditor5-icons/theme/list-style-lower-roman.svg similarity index 100% rename from packages/ckeditor5-list/theme/icons/liststylelowerroman.svg rename to packages/ckeditor5-icons/theme/list-style-lower-roman.svg diff --git a/packages/ckeditor5-list/theme/icons/liststylesquare.svg b/packages/ckeditor5-icons/theme/list-style-square.svg similarity index 100% rename from packages/ckeditor5-list/theme/icons/liststylesquare.svg rename to packages/ckeditor5-icons/theme/list-style-square.svg diff --git a/packages/ckeditor5-list/theme/icons/liststyleupperlatin.svg b/packages/ckeditor5-icons/theme/list-style-upper-latin.svg similarity index 100% rename from packages/ckeditor5-list/theme/icons/liststyleupperlatin.svg rename to packages/ckeditor5-icons/theme/list-style-upper-latin.svg diff --git a/packages/ckeditor5-list/theme/icons/liststyleupperroman.svg b/packages/ckeditor5-icons/theme/list-style-upper-roman.svg similarity index 100% rename from packages/ckeditor5-list/theme/icons/liststyleupperroman.svg rename to packages/ckeditor5-icons/theme/list-style-upper-roman.svg diff --git a/packages/ckeditor5-core/theme/icons/loupe.svg b/packages/ckeditor5-icons/theme/loupe.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/loupe.svg rename to packages/ckeditor5-icons/theme/loupe.svg diff --git a/packages/ckeditor5-core/theme/icons/low-vision.svg b/packages/ckeditor5-icons/theme/low-vision.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/low-vision.svg rename to packages/ckeditor5-icons/theme/low-vision.svg diff --git a/packages/ckeditor5-icons/theme/magic-wand.svg b/packages/ckeditor5-icons/theme/magic-wand.svg new file mode 100644 index 00000000000..e55366b5a98 --- /dev/null +++ b/packages/ckeditor5-icons/theme/magic-wand.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/packages/ckeditor5-highlight/theme/icons/marker.svg b/packages/ckeditor5-icons/theme/marker.svg similarity index 100% rename from packages/ckeditor5-highlight/theme/icons/marker.svg rename to packages/ckeditor5-icons/theme/marker.svg diff --git a/packages/ckeditor5-media-embed/theme/icons/media-placeholder.svg b/packages/ckeditor5-icons/theme/media-placeholder.svg similarity index 100% rename from packages/ckeditor5-media-embed/theme/icons/media-placeholder.svg rename to packages/ckeditor5-icons/theme/media-placeholder.svg diff --git a/packages/ckeditor5-media-embed/theme/icons/media.svg b/packages/ckeditor5-icons/theme/media.svg similarity index 100% rename from packages/ckeditor5-media-embed/theme/icons/media.svg rename to packages/ckeditor5-icons/theme/media.svg diff --git a/packages/ckeditor5-icons/theme/multi-level-list.svg b/packages/ckeditor5-icons/theme/multi-level-list.svg new file mode 100644 index 00000000000..a9a3e1d7f17 --- /dev/null +++ b/packages/ckeditor5-icons/theme/multi-level-list.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/packages/ckeditor5-core/theme/icons/next-arrow.svg b/packages/ckeditor5-icons/theme/next-arrow.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/next-arrow.svg rename to packages/ckeditor5-icons/theme/next-arrow.svg diff --git a/packages/ckeditor5-icons/theme/notification.svg b/packages/ckeditor5-icons/theme/notification.svg new file mode 100644 index 00000000000..b954e7b04e2 --- /dev/null +++ b/packages/ckeditor5-icons/theme/notification.svg @@ -0,0 +1,11 @@ + + + diff --git a/packages/ckeditor5-core/theme/icons/numberedlist.svg b/packages/ckeditor5-icons/theme/numbered-list.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/numberedlist.svg rename to packages/ckeditor5-icons/theme/numbered-list.svg diff --git a/packages/ckeditor5-core/theme/icons/object-center.svg b/packages/ckeditor5-icons/theme/object-center.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/object-center.svg rename to packages/ckeditor5-icons/theme/object-center.svg diff --git a/packages/ckeditor5-core/theme/icons/object-full-width.svg b/packages/ckeditor5-icons/theme/object-full-width.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/object-full-width.svg rename to packages/ckeditor5-icons/theme/object-full-width.svg diff --git a/packages/ckeditor5-core/theme/icons/object-inline-left.svg b/packages/ckeditor5-icons/theme/object-inline-left.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/object-inline-left.svg rename to packages/ckeditor5-icons/theme/object-inline-left.svg diff --git a/packages/ckeditor5-core/theme/icons/object-inline-right.svg b/packages/ckeditor5-icons/theme/object-inline-right.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/object-inline-right.svg rename to packages/ckeditor5-icons/theme/object-inline-right.svg diff --git a/packages/ckeditor5-core/theme/icons/object-inline.svg b/packages/ckeditor5-icons/theme/object-inline.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/object-inline.svg rename to packages/ckeditor5-icons/theme/object-inline.svg diff --git a/packages/ckeditor5-core/theme/icons/object-left.svg b/packages/ckeditor5-icons/theme/object-left.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/object-left.svg rename to packages/ckeditor5-icons/theme/object-left.svg diff --git a/packages/ckeditor5-core/theme/icons/object-right.svg b/packages/ckeditor5-icons/theme/object-right.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/object-right.svg rename to packages/ckeditor5-icons/theme/object-right.svg diff --git a/packages/ckeditor5-core/theme/icons/object-size-custom.svg b/packages/ckeditor5-icons/theme/object-size-custom.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/object-size-custom.svg rename to packages/ckeditor5-icons/theme/object-size-custom.svg diff --git a/packages/ckeditor5-core/theme/icons/object-size-full.svg b/packages/ckeditor5-icons/theme/object-size-full.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/object-size-full.svg rename to packages/ckeditor5-icons/theme/object-size-full.svg diff --git a/packages/ckeditor5-core/theme/icons/object-size-large.svg b/packages/ckeditor5-icons/theme/object-size-large.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/object-size-large.svg rename to packages/ckeditor5-icons/theme/object-size-large.svg diff --git a/packages/ckeditor5-core/theme/icons/object-size-medium.svg b/packages/ckeditor5-icons/theme/object-size-medium.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/object-size-medium.svg rename to packages/ckeditor5-icons/theme/object-size-medium.svg diff --git a/packages/ckeditor5-core/theme/icons/object-size-small.svg b/packages/ckeditor5-icons/theme/object-size-small.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/object-size-small.svg rename to packages/ckeditor5-icons/theme/object-size-small.svg diff --git a/packages/ckeditor5-core/theme/icons/outdent.svg b/packages/ckeditor5-icons/theme/outdent.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/outdent.svg rename to packages/ckeditor5-icons/theme/outdent.svg diff --git a/packages/ckeditor5-page-break/theme/icons/pagebreak.svg b/packages/ckeditor5-icons/theme/page-break.svg similarity index 100% rename from packages/ckeditor5-page-break/theme/icons/pagebreak.svg rename to packages/ckeditor5-icons/theme/page-break.svg diff --git a/packages/ckeditor5-icons/theme/pagination-example.svg b/packages/ckeditor5-icons/theme/pagination-example.svg new file mode 100644 index 00000000000..52ed1d139ff --- /dev/null +++ b/packages/ckeditor5-icons/theme/pagination-example.svg @@ -0,0 +1 @@ + diff --git a/packages/ckeditor5-icons/theme/paint-roller-cursor-default.svg b/packages/ckeditor5-icons/theme/paint-roller-cursor-default.svg new file mode 100644 index 00000000000..5f3abededf3 --- /dev/null +++ b/packages/ckeditor5-icons/theme/paint-roller-cursor-default.svg @@ -0,0 +1,17 @@ + + + + + + + + + + + + + + + + + diff --git a/packages/ckeditor5-icons/theme/paint-roller-cursor-text.svg b/packages/ckeditor5-icons/theme/paint-roller-cursor-text.svg new file mode 100644 index 00000000000..06342b7c733 --- /dev/null +++ b/packages/ckeditor5-icons/theme/paint-roller-cursor-text.svg @@ -0,0 +1,7 @@ + + + + + + + diff --git a/packages/ckeditor5-icons/theme/paint-roller.svg b/packages/ckeditor5-icons/theme/paint-roller.svg new file mode 100644 index 00000000000..f3f7db3be2f --- /dev/null +++ b/packages/ckeditor5-icons/theme/paint-roller.svg @@ -0,0 +1 @@ + diff --git a/packages/ckeditor5-core/theme/icons/paragraph.svg b/packages/ckeditor5-icons/theme/paragraph.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/paragraph.svg rename to packages/ckeditor5-icons/theme/paragraph.svg diff --git a/packages/ckeditor5-highlight/theme/icons/pen.svg b/packages/ckeditor5-icons/theme/pen.svg similarity index 100% rename from packages/ckeditor5-highlight/theme/icons/pen.svg rename to packages/ckeditor5-icons/theme/pen.svg diff --git a/packages/ckeditor5-core/theme/icons/pencil.svg b/packages/ckeditor5-icons/theme/pencil.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/pencil.svg rename to packages/ckeditor5-icons/theme/pencil.svg diff --git a/packages/ckeditor5-core/theme/icons/pilcrow.svg b/packages/ckeditor5-icons/theme/pilcrow.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/pilcrow.svg rename to packages/ckeditor5-icons/theme/pilcrow.svg diff --git a/packages/ckeditor5-icons/theme/play.svg b/packages/ckeditor5-icons/theme/play.svg new file mode 100644 index 00000000000..b2af729d1b4 --- /dev/null +++ b/packages/ckeditor5-icons/theme/play.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/packages/ckeditor5-core/theme/icons/plus.svg b/packages/ckeditor5-icons/theme/plus.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/plus.svg rename to packages/ckeditor5-icons/theme/plus.svg diff --git a/packages/ckeditor5-icons/theme/preview-merge-fields.svg b/packages/ckeditor5-icons/theme/preview-merge-fields.svg new file mode 100644 index 00000000000..2f814fb3585 --- /dev/null +++ b/packages/ckeditor5-icons/theme/preview-merge-fields.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/packages/ckeditor5-core/theme/icons/previous-arrow.svg b/packages/ckeditor5-icons/theme/previous-arrow.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/previous-arrow.svg rename to packages/ckeditor5-icons/theme/previous-arrow.svg diff --git a/packages/ckeditor5-icons/theme/print.svg b/packages/ckeditor5-icons/theme/print.svg new file mode 100644 index 00000000000..e32d8c523ed --- /dev/null +++ b/packages/ckeditor5-icons/theme/print.svg @@ -0,0 +1 @@ + diff --git a/packages/ckeditor5-ui/theme/icons/project-logo.svg b/packages/ckeditor5-icons/theme/project-logo.svg similarity index 100% rename from packages/ckeditor5-ui/theme/icons/project-logo.svg rename to packages/ckeditor5-icons/theme/project-logo.svg diff --git a/packages/ckeditor5-core/theme/icons/quote.svg b/packages/ckeditor5-icons/theme/quote.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/quote.svg rename to packages/ckeditor5-icons/theme/quote.svg diff --git a/packages/ckeditor5-core/theme/icons/redo.svg b/packages/ckeditor5-icons/theme/redo.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/redo.svg rename to packages/ckeditor5-icons/theme/redo.svg diff --git a/packages/ckeditor5-icons/theme/remove-comment.svg b/packages/ckeditor5-icons/theme/remove-comment.svg new file mode 100644 index 00000000000..7e493685466 --- /dev/null +++ b/packages/ckeditor5-icons/theme/remove-comment.svg @@ -0,0 +1,11 @@ + + + diff --git a/packages/ckeditor5-remove-format/theme/icons/remove-format.svg b/packages/ckeditor5-icons/theme/remove-format.svg similarity index 100% rename from packages/ckeditor5-remove-format/theme/icons/remove-format.svg rename to packages/ckeditor5-icons/theme/remove-format.svg diff --git a/packages/ckeditor5-core/theme/icons/remove.svg b/packages/ckeditor5-icons/theme/remove.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/remove.svg rename to packages/ckeditor5-icons/theme/remove.svg diff --git a/packages/ckeditor5-widget/theme/icons/return-arrow.svg b/packages/ckeditor5-icons/theme/return-arrow.svg similarity index 100% rename from packages/ckeditor5-widget/theme/icons/return-arrow.svg rename to packages/ckeditor5-icons/theme/return-arrow.svg diff --git a/packages/ckeditor5-icons/theme/revision-history.svg b/packages/ckeditor5-icons/theme/revision-history.svg new file mode 100644 index 00000000000..daf9197f3e6 --- /dev/null +++ b/packages/ckeditor5-icons/theme/revision-history.svg @@ -0,0 +1 @@ + diff --git a/packages/ckeditor5-icons/theme/robot-pencil.svg b/packages/ckeditor5-icons/theme/robot-pencil.svg new file mode 100644 index 00000000000..122af0e5b58 --- /dev/null +++ b/packages/ckeditor5-icons/theme/robot-pencil.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/packages/ckeditor5-select-all/theme/icons/select-all.svg b/packages/ckeditor5-icons/theme/select-all.svg similarity index 100% rename from packages/ckeditor5-select-all/theme/icons/select-all.svg rename to packages/ckeditor5-icons/theme/select-all.svg diff --git a/packages/ckeditor5-show-blocks/theme/icons/show-blocks.svg b/packages/ckeditor5-icons/theme/show-blocks.svg similarity index 100% rename from packages/ckeditor5-show-blocks/theme/icons/show-blocks.svg rename to packages/ckeditor5-icons/theme/show-blocks.svg diff --git a/packages/ckeditor5-source-editing/theme/icons/source-editing.svg b/packages/ckeditor5-icons/theme/source-editing.svg similarity index 100% rename from packages/ckeditor5-source-editing/theme/icons/source-editing.svg rename to packages/ckeditor5-icons/theme/source-editing.svg diff --git a/packages/ckeditor5-special-characters/theme/icons/specialcharacters.svg b/packages/ckeditor5-icons/theme/special-characters.svg similarity index 100% rename from packages/ckeditor5-special-characters/theme/icons/specialcharacters.svg rename to packages/ckeditor5-icons/theme/special-characters.svg diff --git a/packages/ckeditor5-basic-styles/theme/icons/strikethrough.svg b/packages/ckeditor5-icons/theme/strikethrough.svg similarity index 100% rename from packages/ckeditor5-basic-styles/theme/icons/strikethrough.svg rename to packages/ckeditor5-icons/theme/strikethrough.svg diff --git a/packages/ckeditor5-icons/theme/submit.svg b/packages/ckeditor5-icons/theme/submit.svg new file mode 100644 index 00000000000..451847bf171 --- /dev/null +++ b/packages/ckeditor5-icons/theme/submit.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/packages/ckeditor5-basic-styles/theme/icons/subscript.svg b/packages/ckeditor5-icons/theme/subscript.svg similarity index 100% rename from packages/ckeditor5-basic-styles/theme/icons/subscript.svg rename to packages/ckeditor5-icons/theme/subscript.svg diff --git a/packages/ckeditor5-basic-styles/theme/icons/superscript.svg b/packages/ckeditor5-icons/theme/superscript.svg similarity index 100% rename from packages/ckeditor5-basic-styles/theme/icons/superscript.svg rename to packages/ckeditor5-icons/theme/superscript.svg diff --git a/packages/ckeditor5-table/theme/icons/table-cell-properties.svg b/packages/ckeditor5-icons/theme/table-cell-properties.svg similarity index 100% rename from packages/ckeditor5-table/theme/icons/table-cell-properties.svg rename to packages/ckeditor5-icons/theme/table-cell-properties.svg diff --git a/packages/ckeditor5-table/theme/icons/table-column.svg b/packages/ckeditor5-icons/theme/table-column.svg similarity index 100% rename from packages/ckeditor5-table/theme/icons/table-column.svg rename to packages/ckeditor5-icons/theme/table-column.svg diff --git a/packages/ckeditor5-table/theme/icons/table-merge-cell.svg b/packages/ckeditor5-icons/theme/table-merge-cell.svg similarity index 100% rename from packages/ckeditor5-table/theme/icons/table-merge-cell.svg rename to packages/ckeditor5-icons/theme/table-merge-cell.svg diff --git a/packages/ckeditor5-icons/theme/table-of-contents.svg b/packages/ckeditor5-icons/theme/table-of-contents.svg new file mode 100644 index 00000000000..72bb0fc582c --- /dev/null +++ b/packages/ckeditor5-icons/theme/table-of-contents.svg @@ -0,0 +1 @@ + diff --git a/packages/ckeditor5-table/theme/icons/table-properties.svg b/packages/ckeditor5-icons/theme/table-properties.svg similarity index 100% rename from packages/ckeditor5-table/theme/icons/table-properties.svg rename to packages/ckeditor5-icons/theme/table-properties.svg diff --git a/packages/ckeditor5-table/theme/icons/table-row.svg b/packages/ckeditor5-icons/theme/table-row.svg similarity index 100% rename from packages/ckeditor5-table/theme/icons/table-row.svg rename to packages/ckeditor5-icons/theme/table-row.svg diff --git a/packages/ckeditor5-core/theme/icons/table.svg b/packages/ckeditor5-icons/theme/table.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/table.svg rename to packages/ckeditor5-icons/theme/table.svg diff --git a/packages/ckeditor5-icons/theme/template-generic.svg b/packages/ckeditor5-icons/theme/template-generic.svg new file mode 100644 index 00000000000..b2a339b41c2 --- /dev/null +++ b/packages/ckeditor5-icons/theme/template-generic.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/packages/ckeditor5-icons/theme/template.svg b/packages/ckeditor5-icons/theme/template.svg new file mode 100644 index 00000000000..f165200168e --- /dev/null +++ b/packages/ckeditor5-icons/theme/template.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/packages/ckeditor5-core/theme/icons/text-alternative.svg b/packages/ckeditor5-icons/theme/text-alternative.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/text-alternative.svg rename to packages/ckeditor5-icons/theme/text-alternative.svg diff --git a/packages/ckeditor5-core/theme/icons/text.svg b/packages/ckeditor5-icons/theme/text.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/text.svg rename to packages/ckeditor5-icons/theme/text.svg diff --git a/packages/ckeditor5-core/theme/icons/three-vertical-dots.svg b/packages/ckeditor5-icons/theme/three-vertical-dots.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/three-vertical-dots.svg rename to packages/ckeditor5-icons/theme/three-vertical-dots.svg diff --git a/packages/ckeditor5-core/theme/icons/todolist.svg b/packages/ckeditor5-icons/theme/todo-list.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/todolist.svg rename to packages/ckeditor5-icons/theme/todo-list.svg diff --git a/packages/ckeditor5-icons/theme/track-changes-accept.svg b/packages/ckeditor5-icons/theme/track-changes-accept.svg new file mode 100644 index 00000000000..c1609d1e3f4 --- /dev/null +++ b/packages/ckeditor5-icons/theme/track-changes-accept.svg @@ -0,0 +1,11 @@ + + + diff --git a/packages/ckeditor5-icons/theme/track-changes-discard.svg b/packages/ckeditor5-icons/theme/track-changes-discard.svg new file mode 100644 index 00000000000..d8d9ec08101 --- /dev/null +++ b/packages/ckeditor5-icons/theme/track-changes-discard.svg @@ -0,0 +1,11 @@ + + + diff --git a/packages/ckeditor5-icons/theme/track-changes.svg b/packages/ckeditor5-icons/theme/track-changes.svg new file mode 100644 index 00000000000..acaba36836f --- /dev/null +++ b/packages/ckeditor5-icons/theme/track-changes.svg @@ -0,0 +1,11 @@ + + + diff --git a/packages/ckeditor5-media-embed/theme/icons/media/twitter.svg b/packages/ckeditor5-icons/theme/twitter.svg similarity index 100% rename from packages/ckeditor5-media-embed/theme/icons/media/twitter.svg rename to packages/ckeditor5-icons/theme/twitter.svg diff --git a/packages/ckeditor5-basic-styles/theme/icons/underline.svg b/packages/ckeditor5-icons/theme/underline.svg similarity index 100% rename from packages/ckeditor5-basic-styles/theme/icons/underline.svg rename to packages/ckeditor5-icons/theme/underline.svg diff --git a/packages/ckeditor5-core/theme/icons/undo.svg b/packages/ckeditor5-icons/theme/undo.svg similarity index 100% rename from packages/ckeditor5-core/theme/icons/undo.svg rename to packages/ckeditor5-icons/theme/undo.svg diff --git a/packages/ckeditor5-link/theme/icons/unlink.svg b/packages/ckeditor5-icons/theme/unlink.svg similarity index 100% rename from packages/ckeditor5-link/theme/icons/unlink.svg rename to packages/ckeditor5-icons/theme/unlink.svg diff --git a/packages/ckeditor5-icons/theme/user.svg b/packages/ckeditor5-icons/theme/user.svg new file mode 100644 index 00000000000..9f075f7be1d --- /dev/null +++ b/packages/ckeditor5-icons/theme/user.svg @@ -0,0 +1 @@ + diff --git a/packages/ckeditor5-icons/theme/warning.svg b/packages/ckeditor5-icons/theme/warning.svg new file mode 100644 index 00000000000..b005cdfa7ba --- /dev/null +++ b/packages/ckeditor5-icons/theme/warning.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/ckeditor5-icons/tsconfig.dist.json b/packages/ckeditor5-icons/tsconfig.dist.json new file mode 100644 index 00000000000..a8ab888e091 --- /dev/null +++ b/packages/ckeditor5-icons/tsconfig.dist.json @@ -0,0 +1,9 @@ +{ + "extends": "../../tsconfig.dist.json", + "compilerOptions": { + "rootDir": "src" + }, + "include": [ + "src" + ] +} diff --git a/packages/ckeditor5-icons/tsconfig.json b/packages/ckeditor5-icons/tsconfig.json new file mode 100644 index 00000000000..f011696cd1c --- /dev/null +++ b/packages/ckeditor5-icons/tsconfig.json @@ -0,0 +1,9 @@ +{ + "extends": "../../tsconfig.release.json", + "include": [ + "src" + ], + "exclude": [ + "tests" + ] +} diff --git a/packages/ckeditor5-image/ckeditor5-metadata.json b/packages/ckeditor5-image/ckeditor5-metadata.json index 3f89c5d4f2d..503be79d477 100644 --- a/packages/ckeditor5-image/ckeditor5-metadata.json +++ b/packages/ckeditor5-image/ckeditor5-metadata.json @@ -23,7 +23,7 @@ { "type": "Button", "name": "imageTextAlternative", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/text-alternative.svg", + "iconPath": "@ckeditor/ckeditor5-icons/theme/text-alternative.svg", "toolbars": [ "image.toolbar" ] @@ -57,7 +57,7 @@ { "type": "Button", "name": "imageTextAlternative", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/text-alternative.svg", + "iconPath": "@ckeditor/ckeditor5-icons/theme/text-alternative.svg", "toolbars": [ "image.toolbar" ] @@ -97,7 +97,7 @@ { "type": "Button", "name": "toggleImageCaption", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/caption.svg", + "iconPath": "@ckeditor/ckeditor5-icons/theme/caption.svg", "toolbars": [ "image.toolbar" ] @@ -160,7 +160,7 @@ "toolbars": [ "image.toolbar" ], - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/object-inline.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/object-inline.svg" }, { "type": "Button", @@ -168,7 +168,7 @@ "toolbars": [ "image.toolbar" ], - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/object-center.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/object-center.svg" }, { "type": "Button", @@ -176,7 +176,7 @@ "toolbars": [ "image.toolbar" ], - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/object-right.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/object-right.svg" } ], "htmlOutput": [ @@ -231,7 +231,7 @@ { "type": "Button", "name": "uploadImage", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/image.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/image.svg" } ] }, @@ -248,7 +248,7 @@ { "type": "SplitButton", "name": "insertImage", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/image.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/image.svg" } ] }, @@ -262,7 +262,7 @@ { "type": "Button", "name": "insertImageViaUrl", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/image-url.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/image-url.svg" } ] } diff --git a/packages/ckeditor5-image/tests/imageresize/imageresizebuttons.js b/packages/ckeditor5-image/tests/imageresize/imageresizebuttons.js index d6a7837c1f7..7af32e25892 100644 --- a/packages/ckeditor5-image/tests/imageresize/imageresizebuttons.js +++ b/packages/ckeditor5-image/tests/imageresize/imageresizebuttons.js @@ -5,6 +5,12 @@ /* global document */ +import { + IconObjectSizeSmall, + IconObjectSizeMedium, + IconObjectSizeLarge, + IconObjectSizeFull +} from 'ckeditor5/src/icons.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph.js'; import Image from '../../src/image.js'; @@ -20,11 +26,6 @@ import Table from '@ckeditor/ckeditor5-table/src/table.js'; import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils.js'; import { expectToThrowCKEditorError } from '@ckeditor/ckeditor5-utils/tests/_utils/utils.js'; -import iconSmall from '@ckeditor/ckeditor5-core/theme/icons/object-size-small.svg'; -import iconMedium from '@ckeditor/ckeditor5-core/theme/icons/object-size-medium.svg'; -import iconLarge from '@ckeditor/ckeditor5-core/theme/icons/object-size-large.svg'; -import iconFull from '@ckeditor/ckeditor5-core/theme/icons/object-size-full.svg'; - describe( 'ImageResizeButtons', () => { let plugin, command, editor, editorElement; @@ -370,10 +371,10 @@ describe( 'ImageResizeButtons', () => { const button50 = editor.ui.componentFactory.create( 'resizeImage:50' ); const button75 = editor.ui.componentFactory.create( 'resizeImage:75' ); - expect( buttonOriginal.icon ).to.deep.equal( iconFull ); - expect( button25.icon ).to.deep.equal( iconSmall ); - expect( button50.icon ).to.deep.equal( iconMedium ); - expect( button75.icon ).to.deep.equal( iconLarge ); + expect( buttonOriginal.icon ).to.deep.equal( IconObjectSizeFull ); + expect( button25.icon ).to.deep.equal( IconObjectSizeSmall ); + expect( button50.icon ).to.deep.equal( IconObjectSizeMedium ); + expect( button75.icon ).to.deep.equal( IconObjectSizeLarge ); } ); it( 'should throw the CKEditorError if no `icon` is provided', async () => { diff --git a/packages/ckeditor5-image/tsconfig.dist.json b/packages/ckeditor5-image/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-image/tsconfig.dist.json +++ b/packages/ckeditor5-image/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-image/tsconfig.json b/packages/ckeditor5-image/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-image/tsconfig.json +++ b/packages/ckeditor5-image/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-indent/ckeditor5-metadata.json b/packages/ckeditor5-indent/ckeditor5-metadata.json index 012cf12e9b7..a5f4173fd0b 100644 --- a/packages/ckeditor5-indent/ckeditor5-metadata.json +++ b/packages/ckeditor5-indent/ckeditor5-metadata.json @@ -10,12 +10,12 @@ { "type": "Button", "name": "indent", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/indent.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/indent.svg" }, { "type": "Button", "name": "outdent", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/outdent.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/outdent.svg" } ] }, diff --git a/packages/ckeditor5-indent/tsconfig.dist.json b/packages/ckeditor5-indent/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-indent/tsconfig.dist.json +++ b/packages/ckeditor5-indent/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-indent/tsconfig.json b/packages/ckeditor5-indent/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-indent/tsconfig.json +++ b/packages/ckeditor5-indent/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-language/tsconfig.dist.json b/packages/ckeditor5-language/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-language/tsconfig.dist.json +++ b/packages/ckeditor5-language/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-language/tsconfig.json b/packages/ckeditor5-language/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-language/tsconfig.json +++ b/packages/ckeditor5-language/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-link/ckeditor5-metadata.json b/packages/ckeditor5-link/ckeditor5-metadata.json index e1e255c0c54..abc872f02b4 100644 --- a/packages/ckeditor5-link/ckeditor5-metadata.json +++ b/packages/ckeditor5-link/ckeditor5-metadata.json @@ -20,7 +20,7 @@ { "type": "Button", "name": "link", - "iconPath": "theme/icons/link.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/link.svg" } ], "htmlOutput": [ @@ -61,7 +61,7 @@ { "type": "Button", "name": "linkImage", - "iconPath": "theme/icons/link.svg", + "iconPath": "@ckeditor/ckeditor5-icons/theme/link.svg", "toolbars": [ "image.toolbar" ] diff --git a/packages/ckeditor5-link/src/linkimageui.ts b/packages/ckeditor5-link/src/linkimageui.ts index dbdadd68c40..10733222214 100644 --- a/packages/ckeditor5-link/src/linkimageui.ts +++ b/packages/ckeditor5-link/src/linkimageui.ts @@ -9,6 +9,7 @@ import { ButtonView } from 'ckeditor5/src/ui.js'; import { Plugin } from 'ckeditor5/src/core.js'; +import { IconLink } from 'ckeditor5/src/icons.js'; import type { DocumentSelection, Selection, @@ -23,8 +24,6 @@ import type LinkCommand from './linkcommand.js'; import { LINK_KEYSTROKE } from './utils.js'; -import linkIcon from '../theme/icons/link.svg'; - /** * The link image UI plugin. * @@ -93,7 +92,7 @@ export default class LinkImageUI extends Plugin { button.set( { isEnabled: true, label: t( 'Link image' ), - icon: linkIcon, + icon: IconLink, keystroke: LINK_KEYSTROKE, tooltip: true, isToggleable: true diff --git a/packages/ckeditor5-link/src/linkui.ts b/packages/ckeditor5-link/src/linkui.ts index 518f8f76630..9c167084462 100644 --- a/packages/ckeditor5-link/src/linkui.ts +++ b/packages/ckeditor5-link/src/linkui.ts @@ -8,6 +8,7 @@ */ import { Plugin, type Editor } from 'ckeditor5/src/core.js'; +import { IconLink } from 'ckeditor5/src/icons.js'; import { ClickObserver, type ViewAttributeElement, @@ -37,8 +38,6 @@ import { LINK_KEYSTROKE } from './utils.js'; -import linkIcon from '../theme/icons/link.svg'; - const VISUAL_SELECTION_MARKER_NAME = 'link-ui'; /** @@ -301,7 +300,7 @@ export default class LinkUI extends Plugin { view.set( { label: t( 'Link' ), - icon: linkIcon, + icon: IconLink, keystroke: LINK_KEYSTROKE, isToggleable: true } ); diff --git a/packages/ckeditor5-link/src/ui/linkactionsview.ts b/packages/ckeditor5-link/src/ui/linkactionsview.ts index fe2b99fc5b2..f7c9ba50350 100644 --- a/packages/ckeditor5-link/src/ui/linkactionsview.ts +++ b/packages/ckeditor5-link/src/ui/linkactionsview.ts @@ -7,9 +7,9 @@ * @module link/ui/linkactionsview */ +import { IconUnlink, IconPencil } from 'ckeditor5/src/icons.js'; import { ButtonView, View, ViewCollection, FocusCycler, type FocusableView } from 'ckeditor5/src/ui.js'; import { FocusTracker, KeystrokeHandler, type LocaleTranslate, type Locale } from 'ckeditor5/src/utils.js'; -import { icons } from 'ckeditor5/src/core.js'; import { ensureSafeUrl, openLink } from '../utils.js'; @@ -18,7 +18,6 @@ import { ensureSafeUrl, openLink } from '../utils.js'; import '@ckeditor/ckeditor5-ui/theme/components/responsive-form/responsiveform.css'; import '../../theme/linkactions.css'; -import unlinkIcon from '../../theme/icons/unlink.svg'; import type { LinkConfig } from '../linkconfig.js'; /** @@ -84,8 +83,8 @@ export default class LinkActionsView extends View { this._options = options; this.previewButtonView = this._createPreviewButton(); - this.unlinkButtonView = this._createButton( t( 'Unlink' ), unlinkIcon, 'unlink' ); - this.editButtonView = this._createButton( t( 'Edit link' ), icons.pencil, 'edit' ); + this.unlinkButtonView = this._createButton( t( 'Unlink' ), IconUnlink, 'unlink' ); + this.editButtonView = this._createButton( t( 'Edit link' ), IconPencil, 'edit' ); this.set( 'href', undefined ); diff --git a/packages/ckeditor5-link/tests/linkui.js b/packages/ckeditor5-link/tests/linkui.js index 9ded8c77958..a800e598e22 100644 --- a/packages/ckeditor5-link/tests/linkui.js +++ b/packages/ckeditor5-link/tests/linkui.js @@ -5,6 +5,7 @@ /* globals document, Event */ +import { IconLink } from 'ckeditor5/src/icons.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils.js'; @@ -29,8 +30,6 @@ import LinkFormView from '../src/ui/linkformview.js'; import LinkActionsView from '../src/ui/linkactionsview.js'; import { MenuBarMenuListItemButtonView } from '@ckeditor/ckeditor5-ui'; -import linkIcon from '../theme/icons/link.svg'; - describe( 'LinkUI', () => { let editor, linkUIFeature, linkButton, balloon, formView, actionsView, editorElement; @@ -139,7 +138,7 @@ describe( 'LinkUI', () => { it( 'should create UI component with correct attribute values', () => { expect( linkButton.isOn ).to.be.false; expect( linkButton.label ).to.equal( label ); - expect( linkButton.icon ).to.equal( linkIcon ); + expect( linkButton.icon ).to.equal( IconLink ); expect( linkButton.keystroke ).to.equal( 'Ctrl+K' ); } ); diff --git a/packages/ckeditor5-link/tsconfig.dist.json b/packages/ckeditor5-link/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-link/tsconfig.dist.json +++ b/packages/ckeditor5-link/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-link/tsconfig.json b/packages/ckeditor5-link/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-link/tsconfig.json +++ b/packages/ckeditor5-link/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-list/ckeditor5-metadata.json b/packages/ckeditor5-list/ckeditor5-metadata.json index 5714f5de526..221242d6b4c 100644 --- a/packages/ckeditor5-list/ckeditor5-metadata.json +++ b/packages/ckeditor5-list/ckeditor5-metadata.json @@ -10,12 +10,12 @@ { "type": "Button", "name": "numberedList", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/numberedlist.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/numbered-list.svg" }, { "type": "Button", "name": "bulletedList", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/bulletedlist.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/bulleted-list.svg" } ], "htmlOutput": [ @@ -41,7 +41,7 @@ { "type": "Button", "name": "todoList", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/todolist.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/todo-list.svg" } ], "htmlOutput": [ @@ -103,12 +103,12 @@ { "type": "Button", "name": "numberedList", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/numberedlist.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/numbered-list.svg" }, { "type": "Button", "name": "bulletedList", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/bulletedlist.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/bulleted-list.svg" } ], "htmlOutput": [ @@ -136,7 +136,7 @@ { "type": "Button", "name": "todoList", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/todolist.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/todo-list.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-list/src/listproperties/listpropertiesui.ts b/packages/ckeditor5-list/src/listproperties/listpropertiesui.ts index 07c027189c9..b4821d531e6 100644 --- a/packages/ckeditor5-list/src/listproperties/listpropertiesui.ts +++ b/packages/ckeditor5-list/src/listproperties/listpropertiesui.ts @@ -7,8 +7,20 @@ * @module list/listproperties/listpropertiesui */ -import { icons, Plugin, type Editor } from 'ckeditor5/src/core.js'; - +import { Plugin, type Editor } from 'ckeditor5/src/core.js'; +import { + IconBulletedList, + IconNumberedList, + IconListStyleCircle, + IconListStyleDecimal, + IconListStyleDecimalLeadingZero, + IconListStyleDisc, + IconListStyleLowerLatin, + IconListStyleLowerRoman, + IconListStyleSquare, + IconListStyleUpperLatin, + IconListStyleUpperRoman +} from 'ckeditor5/src/icons.js'; import { ButtonView, SplitButtonView, @@ -32,16 +44,6 @@ import type ListReversedCommand from '../listproperties/listreversedcommand.js'; import { getNormalizedConfig, type NormalizedListPropertiesConfig } from './utils/config.js'; import { type ListPropertiesStyleListType } from '../listconfig.js'; -import listStyleDiscIcon from '../../theme/icons/liststyledisc.svg'; -import listStyleCircleIcon from '../../theme/icons/liststylecircle.svg'; -import listStyleSquareIcon from '../../theme/icons/liststylesquare.svg'; -import listStyleDecimalIcon from '../../theme/icons/liststyledecimal.svg'; -import listStyleDecimalWithLeadingZeroIcon from '../../theme/icons/liststyledecimalleadingzero.svg'; -import listStyleLowerRomanIcon from '../../theme/icons/liststylelowerroman.svg'; -import listStyleUpperRomanIcon from '../../theme/icons/liststyleupperroman.svg'; -import listStyleLowerLatinIcon from '../../theme/icons/liststylelowerlatin.svg'; -import listStyleUpperLatinIcon from '../../theme/icons/liststyleupperlatin.svg'; - import '../../theme/liststyles.css'; /** @@ -82,19 +84,19 @@ export default class ListPropertiesUI extends Plugin { label: t( 'Toggle the disc list style' ), tooltip: t( 'Disc' ), type: 'disc', - icon: listStyleDiscIcon + icon: IconListStyleDisc }, { label: t( 'Toggle the circle list style' ), tooltip: t( 'Circle' ), type: 'circle', - icon: listStyleCircleIcon + icon: IconListStyleCircle }, { label: t( 'Toggle the square list style' ), tooltip: t( 'Square' ), type: 'square', - icon: listStyleSquareIcon + icon: IconListStyleSquare } ]; const buttonLabel = t( 'Bulleted List' ); @@ -106,7 +108,7 @@ export default class ListPropertiesUI extends Plugin { normalizedConfig, parentCommandName: commandName, buttonLabel, - buttonIcon: icons.bulletedList, + buttonIcon: IconBulletedList, styleGridAriaLabel, styleDefinitions } ) ); @@ -131,37 +133,37 @@ export default class ListPropertiesUI extends Plugin { label: t( 'Toggle the decimal list style' ), tooltip: t( 'Decimal' ), type: 'decimal', - icon: listStyleDecimalIcon + icon: IconListStyleDecimal }, { label: t( 'Toggle the decimal with leading zero list style' ), tooltip: t( 'Decimal with leading zero' ), type: 'decimal-leading-zero', - icon: listStyleDecimalWithLeadingZeroIcon + icon: IconListStyleDecimalLeadingZero }, { label: t( 'Toggle the lower–roman list style' ), tooltip: t( 'Lower–roman' ), type: 'lower-roman', - icon: listStyleLowerRomanIcon + icon: IconListStyleLowerRoman }, { label: t( 'Toggle the upper–roman list style' ), tooltip: t( 'Upper-roman' ), type: 'upper-roman', - icon: listStyleUpperRomanIcon + icon: IconListStyleUpperRoman }, { label: t( 'Toggle the lower–latin list style' ), tooltip: t( 'Lower-latin' ), type: 'lower-latin', - icon: listStyleLowerLatinIcon + icon: IconListStyleLowerLatin }, { label: t( 'Toggle the upper–latin list style' ), tooltip: t( 'Upper-latin' ), type: 'upper-latin', - icon: listStyleUpperLatinIcon + icon: IconListStyleUpperLatin } ]; const buttonLabel = t( 'Numbered List' ); @@ -173,7 +175,7 @@ export default class ListPropertiesUI extends Plugin { normalizedConfig, parentCommandName: commandName, buttonLabel, - buttonIcon: icons.numberedList, + buttonIcon: IconNumberedList, styleGridAriaLabel, styleDefinitions } ) ); @@ -472,7 +474,7 @@ function getMenuBarStylesMenuCreator( menuView.buttonView.set( { label: buttonLabel, - icon: icons[ parentCommandName ] + icon: parentCommandName === 'bulletedList' ? IconBulletedList : IconNumberedList } ); menuView.panelView.children.add( listPropertiesView ); menuView.bind( 'isEnabled' ).to( listCommand, 'isEnabled' ); diff --git a/packages/ckeditor5-list/tests/listproperties/listpropertiesui.js b/packages/ckeditor5-list/tests/listproperties/listpropertiesui.js index 3c53a92374d..882f86f05c2 100644 --- a/packages/ckeditor5-list/tests/listproperties/listpropertiesui.js +++ b/packages/ckeditor5-list/tests/listproperties/listpropertiesui.js @@ -6,6 +6,17 @@ /* globals document */ // TODO change to new plugin +import { + IconListStyleCircle, + IconListStyleDecimal, + IconListStyleDecimalLeadingZero, + IconListStyleDisc, + IconListStyleLowerLatin, + IconListStyleLowerRoman, + IconListStyleSquare, + IconListStyleUpperLatin, + IconListStyleUpperRoman +} from 'ckeditor5/src/icons.js'; import ListProperties from '../../src/legacylistproperties.js'; import ListPropertiesUI from '../../src/listproperties/listpropertiesui.js'; @@ -16,16 +27,6 @@ import { UndoEditing } from '@ckeditor/ckeditor5-undo'; import DropdownView from '@ckeditor/ckeditor5-ui/src/dropdown/dropdownview.js'; import { View, ButtonView, LabeledFieldView, SwitchButtonView, MenuBarMenuView } from '@ckeditor/ckeditor5-ui'; -import listStyleDiscIcon from '../../theme/icons/liststyledisc.svg'; -import listStyleCircleIcon from '../../theme/icons/liststylecircle.svg'; -import listStyleSquareIcon from '../../theme/icons/liststylesquare.svg'; -import listStyleDecimalIcon from '../../theme/icons/liststyledecimal.svg'; -import listStyleDecimalWithLeadingZeroIcon from '../../theme/icons/liststyledecimalleadingzero.svg'; -import listStyleLowerRomanIcon from '../../theme/icons/liststylelowerroman.svg'; -import listStyleUpperRomanIcon from '../../theme/icons/liststyleupperroman.svg'; -import listStyleLowerLatinIcon from '../../theme/icons/liststylelowerlatin.svg'; -import listStyleUpperLatinIcon from '../../theme/icons/liststyleupperlatin.svg'; - import { getData, setData } from '@ckeditor/ckeditor5-engine/src/dev-utils/model.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; @@ -362,7 +363,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the disc list style' ); expect( buttonView.tooltip ).to.equal( 'Disc' ); - expect( buttonView.icon ).to.equal( listStyleDiscIcon ); + expect( buttonView.icon ).to.equal( IconListStyleDisc ); } ); it( 'should bring the "circle" list style button', () => { @@ -370,7 +371,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the circle list style' ); expect( buttonView.tooltip ).to.equal( 'Circle' ); - expect( buttonView.icon ).to.equal( listStyleCircleIcon ); + expect( buttonView.icon ).to.equal( IconListStyleCircle ); } ); it( 'should bring the "square" list style button', () => { @@ -378,7 +379,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the square list style' ); expect( buttonView.tooltip ).to.equal( 'Square' ); - expect( buttonView.icon ).to.equal( listStyleSquareIcon ); + expect( buttonView.icon ).to.equal( IconListStyleSquare ); } ); it( 'should only bring the style buttons supported by the command', () => { @@ -738,7 +739,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the decimal list style' ); expect( buttonView.tooltip ).to.equal( 'Decimal' ); - expect( buttonView.icon ).to.equal( listStyleDecimalIcon ); + expect( buttonView.icon ).to.equal( IconListStyleDecimal ); } ); it( 'should bring the "decimal-leading-zero" list style button', () => { @@ -746,7 +747,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the decimal with leading zero list style' ); expect( buttonView.tooltip ).to.equal( 'Decimal with leading zero' ); - expect( buttonView.icon ).to.equal( listStyleDecimalWithLeadingZeroIcon ); + expect( buttonView.icon ).to.equal( IconListStyleDecimalLeadingZero ); } ); it( 'should bring the "lower-roman" list style button', () => { @@ -754,7 +755,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the lower–roman list style' ); expect( buttonView.tooltip ).to.equal( 'Lower–roman' ); - expect( buttonView.icon ).to.equal( listStyleLowerRomanIcon ); + expect( buttonView.icon ).to.equal( IconListStyleLowerRoman ); } ); it( 'should bring the "upper-roman" list style button', () => { @@ -762,7 +763,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the upper–roman list style' ); expect( buttonView.tooltip ).to.equal( 'Upper-roman' ); - expect( buttonView.icon ).to.equal( listStyleUpperRomanIcon ); + expect( buttonView.icon ).to.equal( IconListStyleUpperRoman ); } ); it( 'should bring the "lower–latin" list style button', () => { @@ -770,7 +771,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the lower–latin list style' ); expect( buttonView.tooltip ).to.equal( 'Lower-latin' ); - expect( buttonView.icon ).to.equal( listStyleLowerLatinIcon ); + expect( buttonView.icon ).to.equal( IconListStyleLowerLatin ); } ); it( 'should bring the "upper–latin" list style button', () => { @@ -778,7 +779,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the upper–latin list style' ); expect( buttonView.tooltip ).to.equal( 'Upper-latin' ); - expect( buttonView.icon ).to.equal( listStyleUpperLatinIcon ); + expect( buttonView.icon ).to.equal( IconListStyleUpperLatin ); } ); it( 'should only bring the style buttons supported by the command', () => { @@ -1147,7 +1148,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the disc list style' ); expect( buttonView.tooltip ).to.equal( 'Disc' ); - expect( buttonView.icon ).to.equal( listStyleDiscIcon ); + expect( buttonView.icon ).to.equal( IconListStyleDisc ); } ); it( 'should bring the "circle" list style button', () => { @@ -1155,7 +1156,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the circle list style' ); expect( buttonView.tooltip ).to.equal( 'Circle' ); - expect( buttonView.icon ).to.equal( listStyleCircleIcon ); + expect( buttonView.icon ).to.equal( IconListStyleCircle ); } ); it( 'should bring the "square" list style button', () => { @@ -1163,7 +1164,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the square list style' ); expect( buttonView.tooltip ).to.equal( 'Square' ); - expect( buttonView.icon ).to.equal( listStyleSquareIcon ); + expect( buttonView.icon ).to.equal( IconListStyleSquare ); } ); it( 'should only bring the style buttons supported by the command', () => { @@ -1446,7 +1447,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the decimal list style' ); expect( buttonView.tooltip ).to.equal( 'Decimal' ); - expect( buttonView.icon ).to.equal( listStyleDecimalIcon ); + expect( buttonView.icon ).to.equal( IconListStyleDecimal ); } ); it( 'should bring the "decimal-leading-zero" list style button', () => { @@ -1454,7 +1455,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the decimal with leading zero list style' ); expect( buttonView.tooltip ).to.equal( 'Decimal with leading zero' ); - expect( buttonView.icon ).to.equal( listStyleDecimalWithLeadingZeroIcon ); + expect( buttonView.icon ).to.equal( IconListStyleDecimalLeadingZero ); } ); it( 'should bring the "lower-roman" list style button', () => { @@ -1462,7 +1463,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the lower–roman list style' ); expect( buttonView.tooltip ).to.equal( 'Lower–roman' ); - expect( buttonView.icon ).to.equal( listStyleLowerRomanIcon ); + expect( buttonView.icon ).to.equal( IconListStyleLowerRoman ); } ); it( 'should bring the "upper-roman" list style button', () => { @@ -1470,7 +1471,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the upper–roman list style' ); expect( buttonView.tooltip ).to.equal( 'Upper-roman' ); - expect( buttonView.icon ).to.equal( listStyleUpperRomanIcon ); + expect( buttonView.icon ).to.equal( IconListStyleUpperRoman ); } ); it( 'should bring the "lower–latin" list style button', () => { @@ -1478,7 +1479,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the lower–latin list style' ); expect( buttonView.tooltip ).to.equal( 'Lower-latin' ); - expect( buttonView.icon ).to.equal( listStyleLowerLatinIcon ); + expect( buttonView.icon ).to.equal( IconListStyleLowerLatin ); } ); it( 'should bring the "upper–latin" list style button', () => { @@ -1486,7 +1487,7 @@ describe( 'ListPropertiesUI', () => { expect( buttonView.label ).to.equal( 'Toggle the upper–latin list style' ); expect( buttonView.tooltip ).to.equal( 'Upper-latin' ); - expect( buttonView.icon ).to.equal( listStyleUpperLatinIcon ); + expect( buttonView.icon ).to.equal( IconListStyleUpperLatin ); } ); it( 'should only bring the style buttons supported by the command', () => { diff --git a/packages/ckeditor5-list/tsconfig.dist.json b/packages/ckeditor5-list/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-list/tsconfig.dist.json +++ b/packages/ckeditor5-list/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-list/tsconfig.json b/packages/ckeditor5-list/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-list/tsconfig.json +++ b/packages/ckeditor5-list/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-markdown-gfm/tsconfig.dist.json b/packages/ckeditor5-markdown-gfm/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-markdown-gfm/tsconfig.dist.json +++ b/packages/ckeditor5-markdown-gfm/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-markdown-gfm/tsconfig.json b/packages/ckeditor5-markdown-gfm/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-markdown-gfm/tsconfig.json +++ b/packages/ckeditor5-markdown-gfm/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-media-embed/ckeditor5-metadata.json b/packages/ckeditor5-media-embed/ckeditor5-metadata.json index fae3c32d8b5..2be839fe312 100644 --- a/packages/ckeditor5-media-embed/ckeditor5-metadata.json +++ b/packages/ckeditor5-media-embed/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "SplitButton", "name": "mediaEmbed", - "iconPath": "theme/icons/media.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/media.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-media-embed/src/mediaembedui.ts b/packages/ckeditor5-media-embed/src/mediaembedui.ts index 5258cd2906c..091b14e5171 100644 --- a/packages/ckeditor5-media-embed/src/mediaembedui.ts +++ b/packages/ckeditor5-media-embed/src/mediaembedui.ts @@ -8,11 +8,11 @@ */ import { Plugin } from 'ckeditor5/src/core.js'; +import { IconMedia } from 'ckeditor5/src/icons.js'; import { ButtonView, CssTransitionDisablerMixin, MenuBarMenuListItemButtonView, Dialog } from 'ckeditor5/src/ui.js'; import MediaFormView from './ui/mediaformview.js'; import MediaEmbedEditing from './mediaembedediting.js'; -import mediaIcon from '../theme/icons/media.svg'; import type { LocaleTranslate } from 'ckeditor5/src/utils.js'; import type MediaRegistry from './mediaregistry.js'; @@ -78,7 +78,7 @@ export default class MediaEmbedUI extends Plugin { const command = editor.commands.get( 'mediaEmbed' )!; const dialogPlugin = this.editor.plugins.get( 'Dialog' ); - buttonView.icon = mediaIcon; + buttonView.icon = IconMedia; buttonView.bind( 'isEnabled' ).to( command, 'isEnabled' ); diff --git a/packages/ckeditor5-media-embed/src/mediaregistry.ts b/packages/ckeditor5-media-embed/src/mediaregistry.ts index 1de4ca4f5ab..fbaa9598625 100644 --- a/packages/ckeditor5-media-embed/src/mediaregistry.ts +++ b/packages/ckeditor5-media-embed/src/mediaregistry.ts @@ -7,11 +7,11 @@ * @module media-embed/mediaregistry */ -import type { DowncastWriter, ViewElement } from 'ckeditor5/src/engine.js'; import { IconView, Template } from 'ckeditor5/src/ui.js'; -import { type Locale, logWarning, toArray } from 'ckeditor5/src/utils.js'; +import { IconMediaPlaceholder } from 'ckeditor5/src/icons.js'; +import { logWarning, toArray, type Locale } from 'ckeditor5/src/utils.js'; -import mediaPlaceholderIcon from '../theme/icons/media-placeholder.svg'; +import type { DowncastWriter, ViewElement } from 'ckeditor5/src/engine.js'; import type { MediaEmbedConfig, MediaEmbedProvider } from './mediaembedconfig.js'; import type { MediaOptions } from './utils.js'; @@ -258,7 +258,7 @@ class Media { const icon = new IconView(); const t = this._locale.t; - icon.content = mediaPlaceholderIcon; + icon.content = IconMediaPlaceholder; icon.viewBox = mediaPlaceholderIconViewBox; const placeholder = new Template( { diff --git a/packages/ckeditor5-media-embed/tests/mediaembedui.js b/packages/ckeditor5-media-embed/tests/mediaembedui.js index 4e8e32f119c..d5acd0e28f4 100644 --- a/packages/ckeditor5-media-embed/tests/mediaembedui.js +++ b/packages/ckeditor5-media-embed/tests/mediaembedui.js @@ -3,11 +3,11 @@ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options */ +import { IconMedia } from 'ckeditor5/src/icons.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; import MediaEmbed from '../src/mediaembed.js'; import MediaEmbedUI from '../src/mediaembedui.js'; import global from '@ckeditor/ckeditor5-utils/src/dom/global.js'; -import mediaIcon from '../theme/icons/media.svg'; import { ButtonView, DialogViewPosition, MenuBarMenuListItemButtonView } from '@ckeditor/ckeditor5-ui'; describe( 'MediaEmbedUI', () => { @@ -220,7 +220,7 @@ describe( 'MediaEmbedUI', () => { } ); it( 'should set an #icon of the #buttonView', () => { - expect( button.icon ).to.equal( mediaIcon ); + expect( button.icon ).to.equal( IconMedia ); } ); it( 'should open media embed dialog', () => { diff --git a/packages/ckeditor5-media-embed/tsconfig.dist.json b/packages/ckeditor5-media-embed/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-media-embed/tsconfig.dist.json +++ b/packages/ckeditor5-media-embed/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-media-embed/tsconfig.json b/packages/ckeditor5-media-embed/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-media-embed/tsconfig.json +++ b/packages/ckeditor5-media-embed/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-mention/tsconfig.dist.json b/packages/ckeditor5-mention/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-mention/tsconfig.dist.json +++ b/packages/ckeditor5-mention/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-mention/tsconfig.json b/packages/ckeditor5-mention/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-mention/tsconfig.json +++ b/packages/ckeditor5-mention/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-minimap/tsconfig.dist.json b/packages/ckeditor5-minimap/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-minimap/tsconfig.dist.json +++ b/packages/ckeditor5-minimap/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-minimap/tsconfig.json b/packages/ckeditor5-minimap/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-minimap/tsconfig.json +++ b/packages/ckeditor5-minimap/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-page-break/ckeditor5-metadata.json b/packages/ckeditor5-page-break/ckeditor5-metadata.json index e49f67da4c2..62a0b9eab4b 100644 --- a/packages/ckeditor5-page-break/ckeditor5-metadata.json +++ b/packages/ckeditor5-page-break/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "pageBreak", - "iconPath": "theme/icons/pagebreak.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/page-break.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-page-break/src/pagebreakui.ts b/packages/ckeditor5-page-break/src/pagebreakui.ts index 593efb06501..d5236dd0def 100644 --- a/packages/ckeditor5-page-break/src/pagebreakui.ts +++ b/packages/ckeditor5-page-break/src/pagebreakui.ts @@ -8,10 +8,9 @@ */ import { Plugin } from 'ckeditor5/src/core.js'; +import { IconPageBreak } from 'ckeditor5/src/icons.js'; import { ButtonView, MenuBarMenuListItemButtonView } from 'ckeditor5/src/ui.js'; -import pageBreakIcon from '../theme/icons/pagebreak.svg'; - /** * The page break UI plugin. */ @@ -62,7 +61,7 @@ export default class PageBreakUI extends Plugin { view.set( { label: t( 'Page break' ), - icon: pageBreakIcon + icon: IconPageBreak } ); view.bind( 'isEnabled' ).to( command, 'isEnabled' ); diff --git a/packages/ckeditor5-page-break/tests/pagebreakui.js b/packages/ckeditor5-page-break/tests/pagebreakui.js index 28421cddc2b..79fcb90ed85 100644 --- a/packages/ckeditor5-page-break/tests/pagebreakui.js +++ b/packages/ckeditor5-page-break/tests/pagebreakui.js @@ -5,6 +5,7 @@ /* globals document */ +import { IconPageBreak } from 'ckeditor5/src/icons.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; import PageBreakEditing from '../src/pagebreakediting.js'; import PageBreakUI from '../src/pagebreakui.js'; @@ -13,8 +14,6 @@ import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils.js'; import { MenuBarMenuListItemButtonView } from '@ckeditor/ckeditor5-ui'; import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph.js'; -import pageBreakIcon from '../theme/icons/pagebreak.svg'; - describe( 'PageBreakUI', () => { let editor, editorElement, button; @@ -76,7 +75,7 @@ describe( 'PageBreakUI', () => { it( 'should create UI component with correct attribute values', () => { expect( button.isOn ).to.be.false; expect( button.label ).to.equal( label ); - expect( button.icon ).to.equal( pageBreakIcon ); + expect( button.icon ).to.equal( IconPageBreak ); } ); it( `should execute ${ featureName } command on model execute event and focus the view`, () => { diff --git a/packages/ckeditor5-page-break/tsconfig.dist.json b/packages/ckeditor5-page-break/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-page-break/tsconfig.dist.json +++ b/packages/ckeditor5-page-break/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-page-break/tsconfig.json b/packages/ckeditor5-page-break/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-page-break/tsconfig.json +++ b/packages/ckeditor5-page-break/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-paragraph/tests/paragraphbuttonui.js b/packages/ckeditor5-paragraph/tests/paragraphbuttonui.js index 83af0140cca..3bc58cd59ac 100644 --- a/packages/ckeditor5-paragraph/tests/paragraphbuttonui.js +++ b/packages/ckeditor5-paragraph/tests/paragraphbuttonui.js @@ -5,13 +5,13 @@ /* globals document */ +import { IconParagraph } from 'ckeditor5/src/icons.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; import Paragraph from '../src/paragraph.js'; import Heading from '@ckeditor/ckeditor5-heading/src/heading.js'; import ParagraphButtonUI from '../src/paragraphbuttonui.js'; import { setData } from '@ckeditor/ckeditor5-engine/src/dev-utils/model.js'; import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview.js'; -import icon from '@ckeditor/ckeditor5-core/theme/icons/paragraph.svg'; describe( 'HeadingButtonUI', () => { let editorElement, editor; @@ -48,7 +48,7 @@ describe( 'HeadingButtonUI', () => { const paragraphButton = editor.ui.componentFactory.create( 'paragraph' ); expect( paragraphButton.label ).to.equal( 'Paragraph' ); - expect( paragraphButton.icon ).to.equal( icon ); + expect( paragraphButton.icon ).to.equal( IconParagraph ); expect( paragraphButton.tooltip ).to.equal( true ); expect( paragraphButton.isToggleable ).to.equal( true ); } ); diff --git a/packages/ckeditor5-paragraph/tsconfig.dist.json b/packages/ckeditor5-paragraph/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-paragraph/tsconfig.dist.json +++ b/packages/ckeditor5-paragraph/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-paragraph/tsconfig.json b/packages/ckeditor5-paragraph/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-paragraph/tsconfig.json +++ b/packages/ckeditor5-paragraph/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-paste-from-office/tsconfig.dist.json b/packages/ckeditor5-paste-from-office/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-paste-from-office/tsconfig.dist.json +++ b/packages/ckeditor5-paste-from-office/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-paste-from-office/tsconfig.json b/packages/ckeditor5-paste-from-office/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-paste-from-office/tsconfig.json +++ b/packages/ckeditor5-paste-from-office/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-remove-format/ckeditor5-metadata.json b/packages/ckeditor5-remove-format/ckeditor5-metadata.json index 188e391c426..78b8abc81b5 100644 --- a/packages/ckeditor5-remove-format/ckeditor5-metadata.json +++ b/packages/ckeditor5-remove-format/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "removeFormat", - "iconPath": "theme/icons/remove-format.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/remove-format.svg" } ] } diff --git a/packages/ckeditor5-remove-format/package.json b/packages/ckeditor5-remove-format/package.json index de9654f3bb3..418e2a3e27c 100644 --- a/packages/ckeditor5-remove-format/package.json +++ b/packages/ckeditor5-remove-format/package.json @@ -50,7 +50,6 @@ "lang", "src/**/*.js", "src/**/*.d.ts", - "theme", "build", "ckeditor5-metadata.json", "CHANGELOG.md" diff --git a/packages/ckeditor5-remove-format/src/removeformatui.ts b/packages/ckeditor5-remove-format/src/removeformatui.ts index 6b247d5c322..bed6fe62a40 100644 --- a/packages/ckeditor5-remove-format/src/removeformatui.ts +++ b/packages/ckeditor5-remove-format/src/removeformatui.ts @@ -8,12 +8,11 @@ */ import { Plugin } from 'ckeditor5/src/core.js'; +import { IconRemoveFormat } from 'ckeditor5/src/icons.js'; import { ButtonView, MenuBarMenuListItemButtonView } from 'ckeditor5/src/ui.js'; import type RemoveFormatCommand from './removeformatcommand.js'; -import removeFormatIcon from '../theme/icons/remove-format.svg'; - const REMOVE_FORMAT = 'removeFormat'; /** @@ -66,7 +65,7 @@ export default class RemoveFormatUI extends Plugin { view.set( { label: t( 'Remove Format' ), - icon: removeFormatIcon + icon: IconRemoveFormat } ); view.bind( 'isEnabled' ).to( command, 'isEnabled' ); diff --git a/packages/ckeditor5-remove-format/tests/removeformatui.js b/packages/ckeditor5-remove-format/tests/removeformatui.js index 5f4cdf1a29f..f20da6647df 100644 --- a/packages/ckeditor5-remove-format/tests/removeformatui.js +++ b/packages/ckeditor5-remove-format/tests/removeformatui.js @@ -5,6 +5,7 @@ /* global document */ +import { IconRemoveFormat } from 'ckeditor5/src/icons.js'; import RemoveFormat from '../src/removeformat.js'; import RemoveFormatUI from '../src/removeformatui.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; @@ -15,8 +16,6 @@ import { add as addTranslations } from '@ckeditor/ckeditor5-utils/src/translation-service.js'; -import removeFormatIcon from '../theme/icons/remove-format.svg'; - describe( 'RemoveFormatUI', () => { let editor, element, button; @@ -92,7 +91,7 @@ describe( 'RemoveFormatUI', () => { it( 'should create UI component with correct attribute values', () => { expect( button.isOn ).to.be.false; expect( button.label ).to.equal( label ); - expect( button.icon ).to.equal( removeFormatIcon ); + expect( button.icon ).to.equal( IconRemoveFormat ); } ); it( `should execute ${ featureName } command on model execute event and focus the view`, () => { diff --git a/packages/ckeditor5-remove-format/tsconfig.dist.json b/packages/ckeditor5-remove-format/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-remove-format/tsconfig.dist.json +++ b/packages/ckeditor5-remove-format/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-remove-format/tsconfig.json b/packages/ckeditor5-remove-format/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-remove-format/tsconfig.json +++ b/packages/ckeditor5-remove-format/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-restricted-editing/ckeditor5-metadata.json b/packages/ckeditor5-restricted-editing/ckeditor5-metadata.json index 9bb6812f97e..19286674df3 100644 --- a/packages/ckeditor5-restricted-editing/ckeditor5-metadata.json +++ b/packages/ckeditor5-restricted-editing/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "SplitButton", "name": "restrictedEditing", - "iconPath": "theme/icons/contentlock.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/content-lock.svg" } ], "htmlOutput": [ @@ -30,7 +30,7 @@ { "type": "Button", "name": "restrictedEditingException", - "iconPath": "theme/icons/contentunlock.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/content-unlock.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-restricted-editing/src/restrictededitingmodeui.ts b/packages/ckeditor5-restricted-editing/src/restrictededitingmodeui.ts index accdbf84a0c..dd17c69ae46 100644 --- a/packages/ckeditor5-restricted-editing/src/restrictededitingmodeui.ts +++ b/packages/ckeditor5-restricted-editing/src/restrictededitingmodeui.ts @@ -8,6 +8,7 @@ */ import { Plugin, type Command } from 'ckeditor5/src/core.js'; +import { IconContentLock } from 'ckeditor5/src/icons.js'; import { ViewModel, createDropdown, @@ -18,8 +19,6 @@ import { } from 'ckeditor5/src/ui.js'; import { Collection } from 'ckeditor5/src/utils.js'; -import lockIcon from '../theme/icons/contentlock.svg'; - /** * The restricted editing mode UI feature. * @@ -62,7 +61,7 @@ export default class RestrictedEditingModeUI extends Plugin { dropdownView.buttonView.set( { label: t( 'Navigate editable regions' ), - icon: lockIcon, + icon: IconContentLock, tooltip: true, isEnabled: true, isOn: false @@ -88,7 +87,7 @@ export default class RestrictedEditingModeUI extends Plugin { menuView.buttonView.set( { label: t( 'Navigate editable regions' ), - icon: lockIcon + icon: IconContentLock } ); menuView.panelView.children.add( listView ); diff --git a/packages/ckeditor5-restricted-editing/src/standardeditingmodeui.ts b/packages/ckeditor5-restricted-editing/src/standardeditingmodeui.ts index ff61419f1e1..10b3af12365 100644 --- a/packages/ckeditor5-restricted-editing/src/standardeditingmodeui.ts +++ b/packages/ckeditor5-restricted-editing/src/standardeditingmodeui.ts @@ -8,10 +8,9 @@ */ import { Plugin } from 'ckeditor5/src/core.js'; +import { IconContentUnlock } from 'ckeditor5/src/icons.js'; import { ButtonView, MenuBarMenuListItemButtonView } from 'ckeditor5/src/ui.js'; -import unlockIcon from '../theme/icons/contentunlock.svg'; - /** * The standard editing mode UI feature. * @@ -64,7 +63,7 @@ export default class StandardEditingModeUI extends Plugin { const view = new ButtonClass( locale ) as InstanceType; const t = locale.t; - view.icon = unlockIcon; + view.icon = IconContentUnlock; view.bind( 'isOn', 'isEnabled' ).to( command, 'value', 'isEnabled' ); view.bind( 'label' ).to( command, 'value', value => { diff --git a/packages/ckeditor5-restricted-editing/tests/restrictededitingmodeui.js b/packages/ckeditor5-restricted-editing/tests/restrictededitingmodeui.js index e3faecbb2e0..19bf9efcfd8 100644 --- a/packages/ckeditor5-restricted-editing/tests/restrictededitingmodeui.js +++ b/packages/ckeditor5-restricted-editing/tests/restrictededitingmodeui.js @@ -5,13 +5,13 @@ /* global document */ +import { IconContentLock } from 'ckeditor5/src/icons.js'; import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; import ClipboardPipeline from '@ckeditor/ckeditor5-clipboard/src/clipboardpipeline.js'; import RestrictedEditingModeEditing from './../src/restrictededitingmodeediting.js'; import RestrictedEditingModeUI from './../src/restrictededitingmodeui.js'; -import lockIcon from '../theme/icons/contentlock.svg'; describe( 'RestrictedEditingModeUI', () => { let editor, element, goToPreviousCommand, goToNextCommand; @@ -66,7 +66,7 @@ describe( 'RestrictedEditingModeUI', () => { expect( button ).to.have.property( 'label', 'Navigate editable regions' ); expect( button ).to.have.property( 'tooltip', true ); - expect( button ).to.have.property( 'icon', lockIcon ); + expect( button ).to.have.property( 'icon', IconContentLock ); expect( button ).to.have.property( 'isEnabled', true ); expect( button ).to.have.property( 'isOn', false ); } ); @@ -167,7 +167,7 @@ describe( 'RestrictedEditingModeUI', () => { const button = menuView.buttonView; expect( button ).to.have.property( 'label', 'Navigate editable regions' ); - expect( button ).to.have.property( 'icon', lockIcon ); + expect( button ).to.have.property( 'icon', IconContentLock ); expect( button ).to.have.property( 'isEnabled', true ); expect( button ).to.have.property( 'isOn', false ); } ); diff --git a/packages/ckeditor5-restricted-editing/tests/standardeditingmodeui.js b/packages/ckeditor5-restricted-editing/tests/standardeditingmodeui.js index 3e4e5824b24..3d84ab64546 100644 --- a/packages/ckeditor5-restricted-editing/tests/standardeditingmodeui.js +++ b/packages/ckeditor5-restricted-editing/tests/standardeditingmodeui.js @@ -5,6 +5,7 @@ /* globals document */ +import { IconContentUnlock } from 'ckeditor5/src/icons.js'; import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview.js'; @@ -14,8 +15,6 @@ import { MenuBarMenuListItemButtonView } from '@ckeditor/ckeditor5-ui'; import StandardEditingModeUI from '../src/standardeditingmodeui.js'; import StandardEditingModeEditing from '../src/standardeditingmodeediting.js'; -import unlockIcon from '../theme/icons/contentunlock.svg'; - describe( 'StandardEditingModeUI', () => { let editor, button, editorElement; @@ -75,7 +74,7 @@ describe( 'StandardEditingModeUI', () => { it( 'should create UI component with correct attribute values', () => { expect( button.isOn ).to.be.false; expect( button.label ).to.equal( labels[ 0 ] ); - expect( button.icon ).to.equal( unlockIcon ); + expect( button.icon ).to.equal( IconContentUnlock ); } ); it( `should execute ${ featureName } command on model execute event and focus the view`, () => { diff --git a/packages/ckeditor5-restricted-editing/tsconfig.dist.json b/packages/ckeditor5-restricted-editing/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-restricted-editing/tsconfig.dist.json +++ b/packages/ckeditor5-restricted-editing/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-restricted-editing/tsconfig.json b/packages/ckeditor5-restricted-editing/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-restricted-editing/tsconfig.json +++ b/packages/ckeditor5-restricted-editing/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-select-all/ckeditor5-metadata.json b/packages/ckeditor5-select-all/ckeditor5-metadata.json index 9248f3bdded..d5d24a05cce 100644 --- a/packages/ckeditor5-select-all/ckeditor5-metadata.json +++ b/packages/ckeditor5-select-all/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "selectAll", - "iconPath": "theme/icons/select-all.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/select-all.svg" } ] } diff --git a/packages/ckeditor5-select-all/package.json b/packages/ckeditor5-select-all/package.json index edb849b2986..1688e73f17e 100644 --- a/packages/ckeditor5-select-all/package.json +++ b/packages/ckeditor5-select-all/package.json @@ -44,7 +44,6 @@ "lang", "src/**/*.js", "src/**/*.d.ts", - "theme", "ckeditor5-metadata.json", "CHANGELOG.md" ], diff --git a/packages/ckeditor5-select-all/src/selectallui.ts b/packages/ckeditor5-select-all/src/selectallui.ts index e86d84ecc8b..45f524af701 100644 --- a/packages/ckeditor5-select-all/src/selectallui.ts +++ b/packages/ckeditor5-select-all/src/selectallui.ts @@ -8,10 +8,9 @@ */ import { Plugin } from '@ckeditor/ckeditor5-core'; +import { IconSelectAll } from '@ckeditor/ckeditor5-icons'; import { ButtonView, MenuBarMenuListItemButtonView } from '@ckeditor/ckeditor5-ui'; -import selectAllIcon from '../theme/icons/select-all.svg'; - /** * The select all UI feature. * @@ -67,7 +66,7 @@ export default class SelectAllUI extends Plugin { view.set( { label: t( 'Select all' ), - icon: selectAllIcon, + icon: IconSelectAll, keystroke: 'Ctrl+A' } ); diff --git a/packages/ckeditor5-select-all/tsconfig.dist.json b/packages/ckeditor5-select-all/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-select-all/tsconfig.dist.json +++ b/packages/ckeditor5-select-all/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-select-all/tsconfig.json b/packages/ckeditor5-select-all/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-select-all/tsconfig.json +++ b/packages/ckeditor5-select-all/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-show-blocks/ckeditor5-metadata.json b/packages/ckeditor5-show-blocks/ckeditor5-metadata.json index ef1cf8e13ea..61d40ddfadf 100644 --- a/packages/ckeditor5-show-blocks/ckeditor5-metadata.json +++ b/packages/ckeditor5-show-blocks/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "showBlocks", - "iconPath": "theme/icons/show-blocks.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/show-blocks.svg" } ] } diff --git a/packages/ckeditor5-show-blocks/src/showblocksui.ts b/packages/ckeditor5-show-blocks/src/showblocksui.ts index 71313c61811..ed169197d0d 100644 --- a/packages/ckeditor5-show-blocks/src/showblocksui.ts +++ b/packages/ckeditor5-show-blocks/src/showblocksui.ts @@ -8,9 +8,9 @@ */ import { Plugin } from 'ckeditor5/src/core.js'; +import { IconShowBlocks } from 'ckeditor5/src/icons.js'; import { ButtonView, MenuBarMenuListItemButtonView } from 'ckeditor5/src/ui.js'; -import showBlocksIcon from '../theme/icons/show-blocks.svg'; import '../theme/showblocks.css'; /** @@ -45,7 +45,7 @@ export default class ShowBlocksUI extends Plugin { buttonView.set( { tooltip: true, - icon: showBlocksIcon + icon: IconShowBlocks } ); return buttonView; diff --git a/packages/ckeditor5-show-blocks/tests/showblocksui.js b/packages/ckeditor5-show-blocks/tests/showblocksui.js index a388494b835..68ca5e734e8 100644 --- a/packages/ckeditor5-show-blocks/tests/showblocksui.js +++ b/packages/ckeditor5-show-blocks/tests/showblocksui.js @@ -3,6 +3,7 @@ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options */ +import { IconShowBlocks } from 'ckeditor5/src/icons.js'; import { global } from '@ckeditor/ckeditor5-utils'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; import SourceEditing from '@ckeditor/ckeditor5-source-editing/src/sourceediting.js'; @@ -12,8 +13,6 @@ import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils.js'; import ShowBlocksEditing from '../src/showblocksediting.js'; import ShowBlocksUI from '../src/showblocksui.js'; -import showBlocksIcon from '../theme/icons/show-blocks.svg'; - describe( 'ShowBlocksUI', () => { let editor, element, button; @@ -62,7 +61,7 @@ describe( 'ShowBlocksUI', () => { } ); it( 'should have an icon', () => { - expect( button.icon ).to.equal( showBlocksIcon ); + expect( button.icon ).to.equal( IconShowBlocks ); } ); } ); diff --git a/packages/ckeditor5-show-blocks/tsconfig.dist.json b/packages/ckeditor5-show-blocks/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-show-blocks/tsconfig.dist.json +++ b/packages/ckeditor5-show-blocks/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-show-blocks/tsconfig.json b/packages/ckeditor5-show-blocks/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-show-blocks/tsconfig.json +++ b/packages/ckeditor5-show-blocks/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-source-editing/ckeditor5-metadata.json b/packages/ckeditor5-source-editing/ckeditor5-metadata.json index 5a5f2fc053b..3738b0057eb 100644 --- a/packages/ckeditor5-source-editing/ckeditor5-metadata.json +++ b/packages/ckeditor5-source-editing/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "sourceEditing", - "iconPath": "theme/icons/source-editing.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/source-editing.svg" } ] } diff --git a/packages/ckeditor5-source-editing/src/sourceediting.ts b/packages/ckeditor5-source-editing/src/sourceediting.ts index 9cf1d4af5fc..c7df1f0dea4 100644 --- a/packages/ckeditor5-source-editing/src/sourceediting.ts +++ b/packages/ckeditor5-source-editing/src/sourceediting.ts @@ -9,13 +9,13 @@ /* global console */ -import { type Editor, Plugin, PendingActions } from 'ckeditor5/src/core.js'; +import { Plugin, PendingActions, type Editor } from 'ckeditor5/src/core.js'; +import { IconSourceEditing } from 'ckeditor5/src/icons.js'; import { ButtonView, MenuBarMenuListItemButtonView, type Dialog } from 'ckeditor5/src/ui.js'; import { CKEditorError, createElement, ElementReplacer } from 'ckeditor5/src/utils.js'; import { formatHtml } from './utils/formathtml.js'; import '../theme/sourceediting.css'; -import sourceEditingIcon from '../theme/icons/source-editing.svg'; const COMMAND_FORCE_DISABLE_ID = 'SourceEditingMode'; @@ -99,7 +99,7 @@ export default class SourceEditing extends Plugin { buttonView.set( { label: t( 'Source' ), - icon: sourceEditingIcon, + icon: IconSourceEditing, tooltip: true, class: 'ck-source-editing-button' } ); diff --git a/packages/ckeditor5-source-editing/tsconfig.dist.json b/packages/ckeditor5-source-editing/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-source-editing/tsconfig.dist.json +++ b/packages/ckeditor5-source-editing/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-source-editing/tsconfig.json b/packages/ckeditor5-source-editing/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-source-editing/tsconfig.json +++ b/packages/ckeditor5-source-editing/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-special-characters/ckeditor5-metadata.json b/packages/ckeditor5-special-characters/ckeditor5-metadata.json index 53be7c73656..0b19bc77f25 100644 --- a/packages/ckeditor5-special-characters/ckeditor5-metadata.json +++ b/packages/ckeditor5-special-characters/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "SplitButton", "name": "specialCharacters", - "iconPath": "theme/icons/specialcharacters.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/special-characters.svg" } ] }, diff --git a/packages/ckeditor5-special-characters/src/specialcharacters.ts b/packages/ckeditor5-special-characters/src/specialcharacters.ts index 112f35f88e1..a9b90e601a9 100644 --- a/packages/ckeditor5-special-characters/src/specialcharacters.ts +++ b/packages/ckeditor5-special-characters/src/specialcharacters.ts @@ -9,6 +9,7 @@ import { Plugin, type Editor } from 'ckeditor5/src/core.js'; import { Typing } from 'ckeditor5/src/typing.js'; +import { IconSpecialCharacters } from 'ckeditor5/src/icons.js'; import { ButtonView, MenuBarMenuListItemButtonView, DialogViewPosition, Dialog } from 'ckeditor5/src/ui.js'; import { CKEditorError, type Locale } from 'ckeditor5/src/utils.js'; import CharacterGridView, { @@ -19,8 +20,6 @@ import CharacterGridView, { import CharacterInfoView from './ui/characterinfoview.js'; import SpecialCharactersView from './ui/specialcharactersview.js'; -import specialCharactersIcon from '../theme/icons/specialcharacters.svg'; - import '../theme/specialcharacters.css'; import SpecialCharactersCategoriesView from './ui/specialcharacterscategoriesview.js'; @@ -266,7 +265,7 @@ export default class SpecialCharacters extends Plugin { buttonView.set( { label: t( 'Special characters' ), - icon: specialCharactersIcon, + icon: IconSpecialCharacters, isToggleable: true } ); diff --git a/packages/ckeditor5-special-characters/tests/specialcharacters.js b/packages/ckeditor5-special-characters/tests/specialcharacters.js index 0c9d64c210c..4eb348f18d8 100644 --- a/packages/ckeditor5-special-characters/tests/specialcharacters.js +++ b/packages/ckeditor5-special-characters/tests/specialcharacters.js @@ -5,6 +5,7 @@ /* global document */ +import { IconSpecialCharacters } from 'ckeditor5/src/icons.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; import EventInfo from '@ckeditor/ckeditor5-utils/src/eventinfo.js'; import Typing from '@ckeditor/ckeditor5-typing/src/typing.js'; @@ -13,7 +14,6 @@ import SpecialCharactersMathematical from '../src/specialcharactersmathematical. import SpecialCharactersArrows from '../src/specialcharactersarrows.js'; import CharacterGridView from '../src/ui/charactergridview.js'; import CharacterInfoView from '../src/ui/characterinfoview.js'; -import specialCharactersIcon from '../theme/icons/specialcharacters.svg'; import { expectToThrowCKEditorError } from '@ckeditor/ckeditor5-utils/tests/_utils/utils.js'; import SpecialCharactersCategoriesView from '../src/ui/specialcharacterscategoriesview.js'; import { Dialog } from '@ckeditor/ckeditor5-ui'; @@ -87,7 +87,7 @@ describe( 'SpecialCharacters', () => { function testButton() { it( 'should get basic properties', () => { expect( button.label ).to.equal( 'Special characters' ); - expect( button.icon ).to.equal( specialCharactersIcon ); + expect( button.icon ).to.equal( IconSpecialCharacters ); expect( button.isToggleable ).to.be.true; } ); diff --git a/packages/ckeditor5-special-characters/tsconfig.dist.json b/packages/ckeditor5-special-characters/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-special-characters/tsconfig.dist.json +++ b/packages/ckeditor5-special-characters/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-special-characters/tsconfig.json b/packages/ckeditor5-special-characters/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-special-characters/tsconfig.json +++ b/packages/ckeditor5-special-characters/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-style/tsconfig.dist.json b/packages/ckeditor5-style/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-style/tsconfig.dist.json +++ b/packages/ckeditor5-style/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-style/tsconfig.json b/packages/ckeditor5-style/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-style/tsconfig.json +++ b/packages/ckeditor5-style/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-table/ckeditor5-metadata.json b/packages/ckeditor5-table/ckeditor5-metadata.json index 4571d3c534e..214d1cc81c1 100644 --- a/packages/ckeditor5-table/ckeditor5-metadata.json +++ b/packages/ckeditor5-table/ckeditor5-metadata.json @@ -10,12 +10,12 @@ { "type": "SplitButton", "name": "insertTable", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/table.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/table.svg" }, { "type": "Button", "name": "tableColumn", - "iconPath": "theme/icons/table-column.svg", + "iconPath": "@ckeditor/ckeditor5-icons/theme/table-column.svg", "toolbars": [ "table.contentToolbar" ] @@ -23,7 +23,7 @@ { "type": "Button", "name": "tableRow", - "iconPath": "theme/icons/table-row.svg", + "iconPath": "@ckeditor/ckeditor5-icons/theme/table-row.svg", "toolbars": [ "table.contentToolbar" ] @@ -31,7 +31,7 @@ { "type": "Button", "name": "mergeTableCells", - "iconPath": "theme/icons/table-merge-cell.svg", + "iconPath": "@ckeditor/ckeditor5-icons/theme/table-merge-cell.svg", "toolbars": [ "table.contentToolbar" ] @@ -76,7 +76,7 @@ { "type": "Button", "name": "tableCellProperties", - "iconPath": "theme/icons/table-cell-properties.svg", + "iconPath": "@ckeditor/ckeditor5-icons/theme/table-cell-properties.svg", "toolbars": [ "table.contentToolbar" ] @@ -115,7 +115,7 @@ { "type": "Button", "name": "tableProperties", - "iconPath": "theme/icons/table-properties.svg", + "iconPath": "@ckeditor/ckeditor5-icons/theme/table-properties.svg", "toolbars": [ "table.contentToolbar" ] diff --git a/packages/ckeditor5-table/src/tablecellproperties/tablecellpropertiesui.ts b/packages/ckeditor5-table/src/tablecellproperties/tablecellpropertiesui.ts index abaaa9f07b3..407ea8f649c 100644 --- a/packages/ckeditor5-table/src/tablecellproperties/tablecellpropertiesui.ts +++ b/packages/ckeditor5-table/src/tablecellproperties/tablecellpropertiesui.ts @@ -8,6 +8,7 @@ */ import { Plugin, type Editor } from 'ckeditor5/src/core.js'; +import { IconTableCellProperties } from 'ckeditor5/src/icons.js'; import { ButtonView, clickOutsideHandler, @@ -30,8 +31,6 @@ import { import { debounce } from 'lodash-es'; import { getTableWidgetAncestor } from '../utils/ui/widget.js'; import { getBalloonCellPositionData, repositionContextualBalloon } from '../utils/ui/contextualballoon.js'; - -import tableCellProperties from './../../theme/icons/table-cell-properties.svg'; import { getNormalizedDefaultCellProperties, type NormalizedDefaultProperties } from '../utils/table-properties.js'; import type { GetCallback, ObservableChangeEvent } from 'ckeditor5/src/utils.js'; @@ -145,7 +144,7 @@ export default class TableCellPropertiesUI extends Plugin { view.set( { label: t( 'Cell properties' ), - icon: tableCellProperties, + icon: IconTableCellProperties, tooltip: true } ); diff --git a/packages/ckeditor5-table/src/tableproperties/tablepropertiesui.ts b/packages/ckeditor5-table/src/tableproperties/tablepropertiesui.ts index b4775f56bd3..e6597ced63b 100644 --- a/packages/ckeditor5-table/src/tableproperties/tablepropertiesui.ts +++ b/packages/ckeditor5-table/src/tableproperties/tablepropertiesui.ts @@ -7,7 +7,8 @@ * @module table/tableproperties/tablepropertiesui */ -import { type Editor, Plugin } from 'ckeditor5/src/core.js'; +import { Plugin, type Editor } from 'ckeditor5/src/core.js'; +import { IconTableProperties } from 'ckeditor5/src/icons.js'; import { ButtonView, ContextualBalloon, @@ -20,7 +21,6 @@ import { import { debounce } from 'lodash-es'; import TablePropertiesView from './ui/tablepropertiesview.js'; -import tableProperties from './../../theme/icons/table-properties.svg'; import { colorFieldValidator, getLocalizedColorErrorText, @@ -138,7 +138,7 @@ export default class TablePropertiesUI extends Plugin { view.set( { label: t( 'Table properties' ), - icon: tableProperties, + icon: IconTableProperties, tooltip: true } ); diff --git a/packages/ckeditor5-table/src/tableui.ts b/packages/ckeditor5-table/src/tableui.ts index 9de2f499a3d..db7df4bdbe3 100644 --- a/packages/ckeditor5-table/src/tableui.ts +++ b/packages/ckeditor5-table/src/tableui.ts @@ -7,7 +7,8 @@ * @module table/tableui */ -import { icons, Plugin, type Command, type Editor } from 'ckeditor5/src/core.js'; +import { Plugin, type Command, type Editor } from 'ckeditor5/src/core.js'; +import { IconTable, IconTableColumn, IconTableRow, IconTableMergeCell } from 'ckeditor5/src/icons.js'; import { addListToDropdown, createDropdown, @@ -22,9 +23,6 @@ import { Collection, type ObservableChangeEvent, type Locale } from 'ckeditor5/s import InsertTableView from './ui/inserttableview.js'; -import tableColumnIcon from './../theme/icons/table-column.svg'; -import tableRowIcon from './../theme/icons/table-row.svg'; -import tableMergeCellIcon from './../theme/icons/table-merge-cell.svg'; import type InsertTableCommand from './commands/inserttablecommand.js'; import type MergeCellsCommand from './commands/mergecellscommand.js'; @@ -71,7 +69,7 @@ export default class TableUI extends Plugin { // Decorate dropdown's button. dropdownView.buttonView.set( { - icon: icons.table, + icon: IconTable, label: t( 'Insert table' ), tooltip: true } ); @@ -118,7 +116,7 @@ export default class TableUI extends Plugin { menuView.buttonView.set( { label: t( 'Table' ), - icon: icons.table + icon: IconTable } ); menuView.panelView.children.add( insertTableView ); @@ -169,7 +167,7 @@ export default class TableUI extends Plugin { } ] as Array; - return this._prepareDropdown( t( 'Column' ), tableColumnIcon, options, locale ); + return this._prepareDropdown( t( 'Column' ), IconTableColumn, options, locale ); } ); editor.ui.componentFactory.add( 'tableRow', locale => { @@ -213,7 +211,7 @@ export default class TableUI extends Plugin { } ] as Array; - return this._prepareDropdown( t( 'Row' ), tableRowIcon, options, locale ); + return this._prepareDropdown( t( 'Row' ), IconTableRow, options, locale ); } ); editor.ui.componentFactory.add( 'mergeTableCells', locale => { @@ -263,7 +261,7 @@ export default class TableUI extends Plugin { } ] as Array; - return this._prepareMergeSplitButtonDropdown( t( 'Merge cells' ), tableMergeCellIcon, options, locale ); + return this._prepareMergeSplitButtonDropdown( t( 'Merge cells' ), IconTableMergeCell, options, locale ); } ); } diff --git a/packages/ckeditor5-table/tsconfig.dist.json b/packages/ckeditor5-table/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-table/tsconfig.dist.json +++ b/packages/ckeditor5-table/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-table/tsconfig.json b/packages/ckeditor5-table/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-table/tsconfig.json +++ b/packages/ckeditor5-table/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-theme-lark/tests/manual/iconset.js b/packages/ckeditor5-theme-lark/tests/manual/iconset.js index b4999ef7831..0b49d6e633a 100644 --- a/packages/ckeditor5-theme-lark/tests/manual/iconset.js +++ b/packages/ckeditor5-theme-lark/tests/manual/iconset.js @@ -5,114 +5,11 @@ /* global document */ +import * as icons from 'ckeditor5/src/icons.js'; import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview.js'; import ToolbarView from '@ckeditor/ckeditor5-ui/src/toolbar/toolbarview.js'; import Locale from '@ckeditor/ckeditor5-utils/src/locale.js'; -import italic from '@ckeditor/ckeditor5-basic-styles/theme/icons/italic.svg'; -import underline from '@ckeditor/ckeditor5-basic-styles/theme/icons/underline.svg'; -import code from '@ckeditor/ckeditor5-basic-styles/theme/icons/code.svg'; -import strikethrough from '@ckeditor/ckeditor5-basic-styles/theme/icons/strikethrough.svg'; -import subscript from '@ckeditor/ckeditor5-basic-styles/theme/icons/subscript.svg'; -import superscript from '@ckeditor/ckeditor5-basic-styles/theme/icons/superscript.svg'; - -import { icons as coreIcons } from 'ckeditor5/src/core.js'; - -import fontFamily from '@ckeditor/ckeditor5-font/theme/icons/font-family.svg'; -import fontSize from '@ckeditor/ckeditor5-font/theme/icons/font-size.svg'; -import fontColor from '@ckeditor/ckeditor5-font/theme/icons/font-color.svg'; -import fontBackground from '@ckeditor/ckeditor5-font/theme/icons/font-background.svg'; - -import marker from '@ckeditor/ckeditor5-highlight/theme/icons/marker.svg'; -import pen from '@ckeditor/ckeditor5-highlight/theme/icons/pen.svg'; - -import link from '@ckeditor/ckeditor5-link/theme/icons/link.svg'; -import unlink from '@ckeditor/ckeditor5-link/theme/icons/unlink.svg'; - -import media from '@ckeditor/ckeditor5-media-embed/theme/icons/media.svg'; - -import pageBreak from '@ckeditor/ckeditor5-page-break/theme/icons/pagebreak.svg'; - -import removeFormat from '@ckeditor/ckeditor5-remove-format/theme/icons/remove-format.svg'; - -import contentLock from '@ckeditor/ckeditor5-restricted-editing/theme/icons/contentlock.svg'; -import contentUnlock from '@ckeditor/ckeditor5-restricted-editing/theme/icons/contentunlock.svg'; - -import selectAll from '@ckeditor/ckeditor5-select-all/theme/icons/select-all.svg'; - -import showBlocks from '@ckeditor/ckeditor5-show-blocks/theme/icons/show-blocks.svg'; - -import sourceEditing from '@ckeditor/ckeditor5-source-editing/theme/icons/source-editing.svg'; - -import specialCharacters from '@ckeditor/ckeditor5-special-characters/theme/icons/specialcharacters.svg'; - -import tableRow from '@ckeditor/ckeditor5-table/theme/icons/table-row.svg'; -import tableColumn from '@ckeditor/ckeditor5-table/theme/icons/table-column.svg'; -import tableMergeCell from '@ckeditor/ckeditor5-table/theme/icons/table-merge-cell.svg'; -import tableCellProperties from '@ckeditor/ckeditor5-table/theme/icons/table-cell-properties.svg'; -import tableProperties from '@ckeditor/ckeditor5-table/theme/icons/table-properties.svg'; - -import nextArrow from '@ckeditor/ckeditor5-core/theme/icons/next-arrow.svg'; -import previousArrow from '@ckeditor/ckeditor5-core/theme/icons/previous-arrow.svg'; - -import loupe from '@ckeditor/ckeditor5-find-and-replace/theme/icons/find-replace.svg'; - -import '../../theme/ckeditor5-ui/components/editorui/editorui.css'; - -const icons = { - // basic-styles - italic, underline, code, strikethrough, subscript, superscript, - - // core - ...coreIcons, - - // font - fontFamily, fontSize, fontColor, fontBackground, - - // highlight - marker, pen, - - // link - link, unlink, - - // media-embed - media, - - // page-break - pageBreak, - - // remove-format - removeFormat, - - // restricted-editing - contentLock, contentUnlock, - - // select-all - selectAll, - - // show-blocks - showBlocks, - - // source-editing - sourceEditing, - - // special-characters - specialCharacters, - - // table - tableRow, - tableColumn, - tableMergeCell, - tableCellProperties, - tableProperties, - - // ui - nextArrow, previousArrow, - - // find and replace - loupe -}; - const toolbar = new ToolbarView( new Locale() ); for ( const i in icons ) { diff --git a/packages/ckeditor5-theme-lark/tests/manual/theme.js b/packages/ckeditor5-theme-lark/tests/manual/theme.js index ce453e3bd61..a572c456ef9 100644 --- a/packages/ckeditor5-theme-lark/tests/manual/theme.js +++ b/packages/ckeditor5-theme-lark/tests/manual/theme.js @@ -5,6 +5,7 @@ /* globals document */ +import { IconBold, IconItalic, IconCheck, IconCancel } from 'ckeditor5/src/icons.js'; import testUtils from '@ckeditor/ckeditor5-ui/tests/_utils/utils.js'; import Collection from '@ckeditor/ckeditor5-utils/src/collection.js'; @@ -24,11 +25,6 @@ import ToolbarSeparatorView from '@ckeditor/ckeditor5-ui/src/toolbar/toolbarsepa import LabeledFieldView from '@ckeditor/ckeditor5-ui/src/labeledfield/labeledfieldview.js'; import { createLabeledInputText } from '@ckeditor/ckeditor5-ui/src/labeledfield/utils.js'; -import boldIcon from '@ckeditor/ckeditor5-core/theme/icons/bold.svg'; -import italicIcon from '@ckeditor/ckeditor5-basic-styles/theme/icons/italic.svg'; -import checkIcon from '@ckeditor/ckeditor5-core/theme/icons/check.svg'; -import cancelIcon from '@ckeditor/ckeditor5-core/theme/icons/cancel.svg'; - import SplitButtonView from '@ckeditor/ckeditor5-ui/src/dropdown/button/splitbuttonview.js'; import { SpinnerView } from '@ckeditor/ckeditor5-ui'; @@ -99,10 +95,10 @@ renderInput(); function renderIcon() { // --- In-text ------------------------------------------------------------ - ui.iconPlain1.add( icon( boldIcon ) ); - ui.iconPlain2.add( icon( italicIcon ) ); - ui.iconColor1.add( icon( boldIcon ) ); - ui.iconColor2.add( icon( italicIcon ) ); + ui.iconPlain1.add( icon( IconBold ) ); + ui.iconPlain2.add( icon( IconItalic ) ); + ui.iconColor1.add( icon( IconBold ) ); + ui.iconColor2.add( icon( IconItalic ) ); } function renderButton() { @@ -127,8 +123,8 @@ function renderButton() { const actionButton = button( { label: 'Action button' } ); const roundedButton = button( { label: 'Rounded corners' } ); const boldButton = button( { label: 'Bold text' } ); - const saveButton = button( { label: 'Save', withText: false, icon: checkIcon } ); - const cancelButton = button( { label: 'Cancel', withText: false, icon: cancelIcon } ); + const saveButton = button( { label: 'Save', withText: false, icon: IconCheck } ); + const cancelButton = button( { label: 'Cancel', withText: false, icon: IconCancel } ); ui.buttonTypes.add( toolbar( [ actionButton, roundedButton, boldButton, saveButton, cancelButton @@ -151,13 +147,13 @@ function renderButton() { ui.buttonIcon.add( toolbar( [ button( { label: 'Bold', - icon: boldIcon + icon: IconBold } ) ] ) ); const styledButton = button( { label: 'Button with an icon and custom styles', - icon: italicIcon + icon: IconItalic } ); ui.buttonIconCustom.add( toolbar( [ styledButton ] ) ); @@ -167,14 +163,14 @@ function renderButton() { const disabledActionButton = button( { label: 'Disabled action', - icon: boldIcon, + icon: IconBold, isEnabled: false } ); ui.buttonIconStates.add( toolbar( [ button( { label: 'Disabled', - icon: boldIcon, + icon: IconBold, isEnabled: false } ), disabledActionButton, @@ -182,7 +178,7 @@ function renderButton() { label: 'Bold', withText: false, tooltip: true, - icon: boldIcon + icon: IconBold } ) ] ) ); @@ -199,7 +195,7 @@ function renderButton() { } ), button( { label: 'Bar', - icon: boldIcon, + icon: IconBold, keystroke: 'Shift+Tab', withKeystroke: true } ) @@ -212,7 +208,7 @@ function renderButton() { label: 'Bold', withText: false, tooltip: true, - icon: boldIcon + icon: IconBold } ); ui[ `buttonResponsive${ i }` ].add( toolbar( [ @@ -222,7 +218,7 @@ function renderButton() { } ), button( { label: 'Bold', - icon: boldIcon, + icon: IconBold, isEnabled: true } ), notextButton @@ -313,7 +309,7 @@ function renderDropdown() { label: 'On with an icon', withText: true, isOn: true, - icon: boldIcon + icon: IconBold } ) } ); @@ -322,7 +318,7 @@ function renderDropdown() { model: new Model( { label: 'Icon and key', withText: true, - icon: boldIcon, + icon: IconBold, keystroke: 'Shift+Tab', withKeystroke: true } ) @@ -334,7 +330,7 @@ function renderDropdown() { label: 'On with a keystroke', withText: true, isOn: true, - icon: boldIcon, + icon: IconBold, keystroke: 'Ctrl+A', withKeystroke: true } ) @@ -369,7 +365,7 @@ function renderDropdown() { model: new Model( { label: 'Bold', withText: true, - icon: boldIcon + icon: IconBold } ) } ); @@ -378,7 +374,7 @@ function renderDropdown() { model: new Model( { label: 'This item is on', withText: true, - icon: boldIcon, + icon: IconBold, isOn: true } ) } ); @@ -388,7 +384,7 @@ function renderDropdown() { model: new Model( { label: 'Disabled', withText: true, - icon: boldIcon, + icon: IconBold, isEnabled: false } ) } ); @@ -414,12 +410,12 @@ function renderDropdown() { button( { withText: false, label: 'foo', - icon: boldIcon + icon: IconBold } ), button( { withText: false, label: 'foo', - icon: italicIcon + icon: IconBold } ) ] } ), @@ -431,13 +427,13 @@ function renderDropdown() { withText: false, isEnabled: false, label: 'foo', - icon: boldIcon + icon: IconBold } ), button( { withText: false, isEnabled: false, label: 'foo', - icon: italicIcon + icon: IconItalic } ) ] } ) @@ -448,7 +444,7 @@ function renderToolbar() { // --- Text ------------------------------------------------------------ ui.toolbarText.add( toolbar( [ - icon( boldIcon ), + icon( IconBold ), text() ] ) ); @@ -459,13 +455,13 @@ function renderToolbar() { text(), button( { label: 'Button with an icon', - icon: boldIcon + icon: IconBold } ), listDropdown(), splitButtonDropdown( { label: 'Split button dropdown', withText: false, - icon: boldIcon + icon: IconBold } ), button(), switchbutton( { @@ -482,7 +478,7 @@ function renderToolbar() { } ), button( { label: 'Button with an icon', - icon: boldIcon + icon: IconBold } ) ] ) ); @@ -506,12 +502,12 @@ function renderToolbar() { toolbarSeparator(), button( { label: 'Foo', - icon: boldIcon + icon: IconBold } ), toolbarSeparator(), button( { label: 'Bar RTL', - icon: boldIcon + icon: IconBold } ) ] ) ); @@ -523,15 +519,15 @@ function renderToolbar() { toolbarNewLine(), button( { label: 'Foo', - icon: boldIcon + icon: IconBold } ), button( { label: 'Bar', - icon: boldIcon + icon: IconBold } ), button( { label: 'Baz', - icon: boldIcon + icon: IconBold } ) ] ) ); @@ -539,16 +535,16 @@ function renderToolbar() { const compactToolbar = toolbar( [ button( { - icon: boldIcon, + icon: IconBold, withText: false } ), button( { - icon: italicIcon, + icon: IconItalic, withText: false, isOn: true } ), button( { - icon: cancelIcon, + icon: IconCancel, withText: false } ) ] ); diff --git a/packages/ckeditor5-typing/tsconfig.dist.json b/packages/ckeditor5-typing/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-typing/tsconfig.dist.json +++ b/packages/ckeditor5-typing/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-typing/tsconfig.json b/packages/ckeditor5-typing/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-typing/tsconfig.json +++ b/packages/ckeditor5-typing/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-ui/ckeditor5-metadata.json b/packages/ckeditor5-ui/ckeditor5-metadata.json index 6a8e5451467..ca17618b8aa 100644 --- a/packages/ckeditor5-ui/ckeditor5-metadata.json +++ b/packages/ckeditor5-ui/ckeditor5-metadata.json @@ -17,7 +17,7 @@ { "type": "Button", "name": "accessibilityHelp", - "iconPath": "theme/icons/accessibility.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/accessibility.svg" } ] } diff --git a/packages/ckeditor5-ui/src/collapsible/collapsibleview.ts b/packages/ckeditor5-ui/src/collapsible/collapsibleview.ts index 39c04705751..71071a24fb9 100644 --- a/packages/ckeditor5-ui/src/collapsible/collapsibleview.ts +++ b/packages/ckeditor5-ui/src/collapsible/collapsibleview.ts @@ -7,14 +7,12 @@ * @module ui/collapsible/collapsibleview */ -import type { Locale } from '@ckeditor/ckeditor5-utils'; - +import { IconDropdownArrow } from '@ckeditor/ckeditor5-icons'; import View from '../view.js'; import ButtonView from '../button/buttonview.js'; import type ViewCollection from '../viewcollection.js'; import type { FocusableView } from '../focuscycler.js'; - -import dropdownArrowIcon from '../../theme/icons/dropdown-arrow.svg'; +import type { Locale } from '@ckeditor/ckeditor5-utils'; import '../../theme/components/collapsible/collapsible.css'; @@ -136,7 +134,7 @@ export default class CollapsibleView extends View { buttonView.set( { withText: true, - icon: dropdownArrowIcon + icon: IconDropdownArrow } ); buttonView.extendTemplate( { diff --git a/packages/ckeditor5-ui/src/colorgrid/colortileview.ts b/packages/ckeditor5-ui/src/colorgrid/colortileview.ts index 109b40c8142..c9de4832517 100644 --- a/packages/ckeditor5-ui/src/colorgrid/colortileview.ts +++ b/packages/ckeditor5-ui/src/colorgrid/colortileview.ts @@ -7,11 +7,9 @@ * @module ui/colorgrid/colortileview */ -import ButtonView from '../button/buttonview.js'; - +import { IconColorTileCheck } from '@ckeditor/ckeditor5-icons'; import { env, type Locale } from '@ckeditor/ckeditor5-utils'; - -import checkIcon from '../../theme/icons/color-tile-check.svg'; +import ButtonView from '../button/buttonview.js'; /** * This class represents a single color tile in the {@link module:ui/colorgrid/colorgridview~ColorGridView}. @@ -36,7 +34,7 @@ export default class ColorTileView extends ButtonView { this.set( 'color', undefined ); this.set( 'hasBorder', false ); - this.icon = checkIcon; + this.icon = IconColorTileCheck; this.extendTemplate( { attributes: { diff --git a/packages/ckeditor5-ui/src/dropdown/button/dropdownbuttonview.ts b/packages/ckeditor5-ui/src/dropdown/button/dropdownbuttonview.ts index 84b27384efa..dae2eed1187 100644 --- a/packages/ckeditor5-ui/src/dropdown/button/dropdownbuttonview.ts +++ b/packages/ckeditor5-ui/src/dropdown/button/dropdownbuttonview.ts @@ -7,14 +7,13 @@ * @module ui/dropdown/button/dropdownbuttonview */ +import { IconDropdownArrow } from '@ckeditor/ckeditor5-icons'; import ButtonView from '../../button/buttonview.js'; import type DropdownButton from './dropdownbutton.js'; import IconView from '../../icon/iconview.js'; import type { Locale } from '@ckeditor/ckeditor5-utils'; -import dropdownArrowIcon from '../../../theme/icons/dropdown-arrow.svg'; - /** * The default dropdown button view class. * @@ -74,7 +73,7 @@ export default class DropdownButtonView extends ButtonView implements DropdownBu private _createArrowView() { const arrowView = new IconView(); - arrowView.content = dropdownArrowIcon; + arrowView.content = IconDropdownArrow; arrowView.extendTemplate( { attributes: { diff --git a/packages/ckeditor5-ui/src/dropdown/button/splitbuttonview.ts b/packages/ckeditor5-ui/src/dropdown/button/splitbuttonview.ts index 4d99eef7e1e..4b68f316a1f 100644 --- a/packages/ckeditor5-ui/src/dropdown/button/splitbuttonview.ts +++ b/packages/ckeditor5-ui/src/dropdown/button/splitbuttonview.ts @@ -7,6 +7,12 @@ * @module ui/dropdown/button/splitbuttonview */ +import { IconDropdownArrow } from '@ckeditor/ckeditor5-icons'; +import { + KeystrokeHandler, + FocusTracker, + type Locale +} from '@ckeditor/ckeditor5-utils'; import View from '../../view.js'; import ButtonView from '../../button/buttonview.js'; import type ViewCollection from '../../viewcollection.js'; @@ -14,14 +20,6 @@ import type Button from '../../button/button.js'; import type DropdownButton from './dropdownbutton.js'; import type { FocusableView } from '../../focuscycler.js'; -import { - KeystrokeHandler, - FocusTracker, - type Locale -} from '@ckeditor/ckeditor5-utils'; - -import dropdownArrowIcon from '../../../theme/icons/dropdown-arrow.svg'; - import '../../../theme/components/dropdown/splitbutton.css'; /** @@ -308,7 +306,7 @@ export default class SplitButtonView extends View implements Dro const arrowView = new ButtonView(); const bind = arrowView.bindTemplate; - arrowView.icon = dropdownArrowIcon; + arrowView.icon = IconDropdownArrow; arrowView.extendTemplate( { attributes: { diff --git a/packages/ckeditor5-ui/src/dropdown/menu/dropdownmenubuttonview.ts b/packages/ckeditor5-ui/src/dropdown/menu/dropdownmenubuttonview.ts index ae564a8c5cd..c5c643b3d2f 100644 --- a/packages/ckeditor5-ui/src/dropdown/menu/dropdownmenubuttonview.ts +++ b/packages/ckeditor5-ui/src/dropdown/menu/dropdownmenubuttonview.ts @@ -7,12 +7,11 @@ * @module ui/dropdown/menu/dropdownmenubuttonview */ +import { IconDropdownArrow } from '@ckeditor/ckeditor5-icons'; import IconView from '../../icon/iconview.js'; import ListItemButtonView from '../../button/listitembuttonview.js'; import type { Locale } from '@ckeditor/ckeditor5-utils'; -import dropdownArrowIcon from '../../../theme/icons/dropdown-arrow.svg'; - import '../../../theme/components/dropdown/menu/dropdownmenubutton.css'; /** @@ -73,7 +72,7 @@ export default class DropdownMenuButtonView extends ListItemButtonView { private _createArrowView() { const arrowView = new IconView(); - arrowView.content = dropdownArrowIcon; + arrowView.content = IconDropdownArrow; arrowView.extendTemplate( { attributes: { class: 'ck-dropdown-menu-list__nested-menu__button__arrow' diff --git a/packages/ckeditor5-ui/src/editorui/accessibilityhelp/accessibilityhelp.ts b/packages/ckeditor5-ui/src/editorui/accessibilityhelp/accessibilityhelp.ts index 49298837518..8d8b53b5d80 100644 --- a/packages/ckeditor5-ui/src/editorui/accessibilityhelp/accessibilityhelp.ts +++ b/packages/ckeditor5-ui/src/editorui/accessibilityhelp/accessibilityhelp.ts @@ -8,6 +8,7 @@ */ import { Plugin } from '@ckeditor/ckeditor5-core'; +import { IconAccessibility } from '@ckeditor/ckeditor5-icons'; import ButtonView from '../../button/buttonview.js'; import Dialog from '../../dialog/dialog.js'; import MenuBarMenuListItemButtonView from '../../menubar/menubarmenulistitembuttonview.js'; @@ -17,7 +18,6 @@ import type { EditorUIReadyEvent } from '../../editorui/editorui.js'; import type { AddRootEvent } from '@ckeditor/ckeditor5-editor-multi-root'; import type { DowncastWriter, ViewRootEditableElement } from '@ckeditor/ckeditor5-engine'; -import accessibilityIcon from '../../../theme/icons/accessibility.svg'; import '../../../theme/components/editorui/accessibilityhelp.css'; /** @@ -102,7 +102,7 @@ export default class AccessibilityHelp extends Plugin { view.set( { keystroke: 'Alt+0', - icon: accessibilityIcon, + icon: IconAccessibility, isToggleable: true } ); @@ -164,7 +164,7 @@ export default class AccessibilityHelp extends Plugin { id: 'accessibilityHelp', className: 'ck-accessibility-help-dialog', title: t( 'Accessibility help' ), - icon: accessibilityIcon, + icon: IconAccessibility, hasCloseButton: true, content: this.contentView } ); diff --git a/packages/ckeditor5-ui/src/editorui/poweredby.ts b/packages/ckeditor5-ui/src/editorui/poweredby.ts index 9a5ea87f58c..17c82dd825e 100644 --- a/packages/ckeditor5-ui/src/editorui/poweredby.ts +++ b/packages/ckeditor5-ui/src/editorui/poweredby.ts @@ -7,14 +7,13 @@ * @module ui/editorui/poweredby */ -import type { Editor, UiConfig } from '@ckeditor/ckeditor5-core'; +import { IconProjectLogo } from '@ckeditor/ckeditor5-icons'; import { parseBase64EncodedObject, type Locale } from '@ckeditor/ckeditor5-utils'; import View from '../view.js'; import Badge from '../badge/badge.js'; import IconView from '../icon/iconview.js'; - -import poweredByIcon from '../../theme/icons/project-logo.svg'; +import type { Editor, UiConfig } from '@ckeditor/ckeditor5-core'; const DEFAULT_LABEL = 'Powered by'; @@ -102,7 +101,7 @@ class PoweredByView extends View { const bind = this.bindTemplate; iconView.set( { - content: poweredByIcon, + content: IconProjectLogo, isColorInherited: false } ); diff --git a/packages/ckeditor5-ui/src/menubar/menubarmenubuttonview.ts b/packages/ckeditor5-ui/src/menubar/menubarmenubuttonview.ts index 706c3e667fc..f3c230f06f9 100644 --- a/packages/ckeditor5-ui/src/menubar/menubarmenubuttonview.ts +++ b/packages/ckeditor5-ui/src/menubar/menubarmenubuttonview.ts @@ -7,12 +7,11 @@ * @module ui/menubar/menubarmenubuttonview */ +import { IconDropdownArrow } from '@ckeditor/ckeditor5-icons'; import IconView from '../icon/iconview.js'; import ListItemButtonView from '../button/listitembuttonview.js'; import type { Locale } from '@ckeditor/ckeditor5-utils'; -import dropdownArrowIcon from '../../theme/icons/dropdown-arrow.svg'; - import '../../theme/components/menubar/menubarmenubutton.css'; /** @@ -72,7 +71,7 @@ export default class MenuBarMenuButtonView extends ListItemButtonView { private _createArrowView() { const arrowView = new IconView(); - arrowView.content = dropdownArrowIcon; + arrowView.content = IconDropdownArrow; arrowView.extendTemplate( { attributes: { class: 'ck-menu-bar__menu__button__arrow' diff --git a/packages/ckeditor5-ui/tests/collapsible/collapsibleview.js b/packages/ckeditor5-ui/tests/collapsible/collapsibleview.js index f31fc672154..d4f0c5ef6b5 100644 --- a/packages/ckeditor5-ui/tests/collapsible/collapsibleview.js +++ b/packages/ckeditor5-ui/tests/collapsible/collapsibleview.js @@ -3,10 +3,10 @@ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options */ +import { IconDropdownArrow } from 'ckeditor5/src/icons.js'; import CollapsibleView from '../../src/collapsible/collapsibleview.js'; import ButtonView from '../../src/button/buttonview.js'; -import dropdownArrowIcon from '../../theme/icons/dropdown-arrow.svg'; import ViewCollection from '../../src/viewcollection.js'; describe( 'CollapsibleView', () => { @@ -53,7 +53,7 @@ describe( 'CollapsibleView', () => { describe( 'main button', () => { it( 'should have an icon', () => { - expect( view.buttonView.icon ).to.equal( dropdownArrowIcon ); + expect( view.buttonView.icon ).to.equal( IconDropdownArrow ); } ); it( 'should display its text', () => { diff --git a/packages/ckeditor5-ui/tests/colorgrid/colortileview.js b/packages/ckeditor5-ui/tests/colorgrid/colortileview.js index bb6d5f67f6e..c24a38fa296 100644 --- a/packages/ckeditor5-ui/tests/colorgrid/colortileview.js +++ b/packages/ckeditor5-ui/tests/colorgrid/colortileview.js @@ -3,9 +3,9 @@ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options */ +import { IconColorTileCheck } from 'ckeditor5/src/icons.js'; import ColorTileView from '../../src/colorgrid/colortileview.js'; import ButtonView from '../../src/button/buttonview.js'; -import checkIcon from '../../theme/icons/color-tile-check.svg'; import { env } from '@ckeditor/ckeditor5-utils'; import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils.js'; @@ -55,7 +55,7 @@ describe( 'ColorTileView', () => { it( 'has a check icon', () => { colorTile.render(); - expect( colorTile.icon ).to.equal( checkIcon ); + expect( colorTile.icon ).to.equal( IconColorTileCheck ); expect( colorTile.iconView.fillColor ).to.equal( 'hsl(0, 0%, 100%)' ); } ); } ); diff --git a/packages/ckeditor5-ui/tests/colorselector/colorselectorview.js b/packages/ckeditor5-ui/tests/colorselector/colorselectorview.js index 74b6aaea455..1684a80995d 100644 --- a/packages/ckeditor5-ui/tests/colorselector/colorselectorview.js +++ b/packages/ckeditor5-ui/tests/colorselector/colorselectorview.js @@ -5,6 +5,7 @@ /* globals document,Event */ +import { IconEraser, IconCheck, IconCancel } from 'ckeditor5/src/icons.js'; import ColorSelectorView from './../../src/colorselector/colorselectorview.js'; import ColorTileView from '../../src/colorgrid/colortileview.js'; import FocusCycler from '../../src/focuscycler.js'; @@ -21,10 +22,6 @@ import { setData as setModelData } from '@ckeditor/ckeditor5-engine/src/dev-util import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils.js'; -import removeButtonIcon from '@ckeditor/ckeditor5-core/theme/icons/eraser.svg'; -import checkButtonIcon from '@ckeditor/ckeditor5-core/theme/icons/check.svg'; -import cancelButtonIcon from '@ckeditor/ckeditor5-core/theme/icons/cancel.svg'; - const colorDefinitions = [ { color: '#000', @@ -601,7 +598,7 @@ describe( 'ColorSelectorView', () => { it( 'should have proper settings', () => { expect( removeButton.withText ).to.be.true; - expect( removeButton.icon ).to.equal( removeButtonIcon ); + expect( removeButton.icon ).to.equal( IconEraser ); expect( removeButton.label ).to.equal( 'Remove color' ); } ); @@ -638,7 +635,7 @@ describe( 'ColorSelectorView', () => { it( 'should have proper settings', () => { expect( saveButton.withText ).to.be.false; - expect( saveButton.icon ).to.equal( checkButtonIcon ); + expect( saveButton.icon ).to.equal( IconCheck ); } ); it( 'should not fire "execute" event with incorrect value', () => { @@ -684,7 +681,7 @@ describe( 'ColorSelectorView', () => { it( 'should have proper settings', () => { expect( cancelButton.withText ).to.be.false; - expect( cancelButton.icon ).to.equal( cancelButtonIcon ); + expect( cancelButton.icon ).to.equal( IconCancel ); } ); it( 'should fire "cancel" event', () => { diff --git a/packages/ckeditor5-ui/tests/dialog/dialog.js b/packages/ckeditor5-ui/tests/dialog/dialog.js index b72c806df1d..e75d68d6ae4 100644 --- a/packages/ckeditor5-ui/tests/dialog/dialog.js +++ b/packages/ckeditor5-ui/tests/dialog/dialog.js @@ -3,12 +3,12 @@ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options */ +import { IconFindReplace } from 'ckeditor5/src/icons.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; import { Paragraph } from '@ckeditor/ckeditor5-paragraph'; import { Dialog, DialogView, DialogViewPosition, IconView } from '../../src/index.js'; import { env, keyCodes } from '@ckeditor/ckeditor5-utils'; -import loupeIcon from '@ckeditor/ckeditor5-find-and-replace/theme/icons/find-replace.svg'; /* global document */ @@ -444,7 +444,7 @@ describe( 'Dialog', () => { it( 'should properly setup the header view with the passed arguments', () => { dialogPlugin._show( { - icon: loupeIcon, + icon: IconFindReplace, title: 'foo', hasCloseButton: false } ); diff --git a/packages/ckeditor5-ui/tests/dialog/dialogview.js b/packages/ckeditor5-ui/tests/dialog/dialogview.js index d7d1e771cb1..ed283c285b9 100644 --- a/packages/ckeditor5-ui/tests/dialog/dialogview.js +++ b/packages/ckeditor5-ui/tests/dialog/dialogview.js @@ -5,11 +5,11 @@ /* global document, Event, KeyboardEvent, MouseEvent, console */ +import { IconCancel } from 'ckeditor5/src/icons.js'; import { FocusTracker, KeystrokeHandler, Locale, global, keyCodes } from '@ckeditor/ckeditor5-utils'; import { ButtonView, FormHeaderView, View, ViewCollection } from '../../src/index.js'; import DialogView, { DialogViewPosition } from '../../src/dialog/dialogview.js'; import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils.js'; -import cancelIcon from '@ckeditor/ckeditor5-core/theme/icons/cancel.svg'; describe( 'DialogView', () => { let view, fakeDomRootElement; @@ -701,7 +701,7 @@ describe( 'DialogView', () => { expect( closeButtonView ).to.be.instanceOf( ButtonView ); expect( closeButtonView.label ).to.equal( 'Close' ); expect( closeButtonView.tooltip ).to.be.true; - expect( closeButtonView.icon ).to.equal( cancelIcon ); + expect( closeButtonView.icon ).to.equal( IconCancel ); } ); it( 'should fire an event with data upon clicking', () => { diff --git a/packages/ckeditor5-ui/tests/dropdown/menu/dropdownmenubuttonview.js b/packages/ckeditor5-ui/tests/dropdown/menu/dropdownmenubuttonview.js index c225bdf3125..220dc5e4d49 100644 --- a/packages/ckeditor5-ui/tests/dropdown/menu/dropdownmenubuttonview.js +++ b/packages/ckeditor5-ui/tests/dropdown/menu/dropdownmenubuttonview.js @@ -5,11 +5,11 @@ /* global Event */ +import { IconDropdownArrow } from 'ckeditor5/src/icons.js'; import { createMockLocale } from './_utils/dropdowntreemock.js'; import { IconView, ListItemButtonView } from '../../../src/index.js'; import DropdownMenuButtonView from '../../../src/dropdown/menu/dropdownmenubuttonview.js'; -import dropdownArrowIcon from '../../../theme/icons/dropdown-arrow.svg'; describe( 'DropdownMenuButtonView', () => { let buttonView, locale; @@ -48,7 +48,7 @@ describe( 'DropdownMenuButtonView', () => { } ); it( 'should use a specific SVG icon', () => { - expect( buttonView.arrowView.content ).to.equal( dropdownArrowIcon ); + expect( buttonView.arrowView.content ).to.equal( IconDropdownArrow ); } ); } ); diff --git a/packages/ckeditor5-ui/tests/formheader/formheaderview.js b/packages/ckeditor5-ui/tests/formheader/formheaderview.js index eaf4908d220..2c4a3602fdf 100644 --- a/packages/ckeditor5-ui/tests/formheader/formheaderview.js +++ b/packages/ckeditor5-ui/tests/formheader/formheaderview.js @@ -3,13 +3,12 @@ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options */ +import { IconCheck } from 'ckeditor5/src/icons.js'; import View from '../../src/view.js'; import ViewCollection from '../../src/viewcollection.js'; import FormHeaderView from '../../src/formheader/formheaderview.js'; import { IconView } from '../../src/index.js'; -import checkIcon from '@ckeditor/ckeditor5-core/theme/icons/check.svg'; - describe( 'FormHeaderView', () => { let view, locale; @@ -78,7 +77,7 @@ describe( 'FormHeaderView', () => { it( 'should allow passing an icon', () => { const view = new FormHeaderView( locale, { label: 'foo', - icon: checkIcon + icon: IconCheck } ); view.render(); @@ -91,7 +90,7 @@ describe( 'FormHeaderView', () => { expect( view.element.firstChild.classList.contains( 'ck-icon' ) ).to.be.true; expect( view.iconView ).to.be.instanceOf( IconView ); - expect( view.iconView.content ).to.equal( checkIcon ); + expect( view.iconView.content ).to.equal( IconCheck ); expect( view.iconView.element ).to.equal( view.element.firstChild ); view.destroy(); diff --git a/packages/ckeditor5-ui/tests/manual/dropdown/dropdown.js b/packages/ckeditor5-ui/tests/manual/dropdown/dropdown.js index e31c518049f..bdc4c56e2c2 100644 --- a/packages/ckeditor5-ui/tests/manual/dropdown/dropdown.js +++ b/packages/ckeditor5-ui/tests/manual/dropdown/dropdown.js @@ -5,14 +5,11 @@ /* globals window, console */ +import { IconAlignLeft, IconAlignCenter, IconAlignRight } from 'ckeditor5/src/icons.js'; import Model from '../../../src/model.js'; import Collection from '@ckeditor/ckeditor5-utils/src/collection.js'; import testUtils from '../../_utils/utils.js'; - -import alignLeftIcon from '@ckeditor/ckeditor5-core/theme/icons/object-left.svg'; -import alignRightIcon from '@ckeditor/ckeditor5-core/theme/icons/object-right.svg'; -import alignCenterIcon from '@ckeditor/ckeditor5-core/theme/icons/object-center.svg'; import ButtonView from '../../../src/button/buttonview.js'; import SplitButtonView from '../../../src/dropdown/button/splitbuttonview.js'; @@ -177,7 +174,7 @@ function testLongLabel() { function testToolbar() { const locale = { t: langString => langString }; - const icons = { left: alignLeftIcon, right: alignRightIcon, center: alignCenterIcon }; + const icons = { left: IconAlignLeft, right: IconAlignRight, center: IconAlignCenter }; // Buttons to be obtained from factory later on. const buttons = Object.keys( icons ).map( icon => new Model( { label: icon, isEnabled: true, isOn: false, icon: icons[ icon ] } ) ); @@ -225,7 +222,7 @@ function testSplitButton() { dropdownView.buttonView.set( { label: 'Dropdown', - icon: alignCenterIcon + icon: IconAlignCenter } ); ui.splitButton.add( dropdownView ); diff --git a/packages/ckeditor5-ui/tests/manual/tickets/9412/1.js b/packages/ckeditor5-ui/tests/manual/tickets/9412/1.js index dd752f8a6c7..ea79001a64e 100644 --- a/packages/ckeditor5-ui/tests/manual/tickets/9412/1.js +++ b/packages/ckeditor5-ui/tests/manual/tickets/9412/1.js @@ -5,11 +5,11 @@ /* globals window, document, console:false */ +import { IconBold } from 'ckeditor5/src/icons.js'; import ClassicEditor from '@ckeditor/ckeditor5-editor-classic/src/classiceditor.js'; import Essentials from '@ckeditor/ckeditor5-essentials/src/essentials.js'; import { Paragraph } from '@ckeditor/ckeditor5-paragraph'; import Heading from '@ckeditor/ckeditor5-heading/src/heading.js'; -import boldIcon from '@ckeditor/ckeditor5-core/theme/icons/bold.svg'; import ButtonView from '../../../../src/button/buttonview.js'; function customButtonView( editor ) { @@ -17,7 +17,7 @@ function customButtonView( editor ) { const view = new ButtonView( locale ); view.set( { label: 'Custom Button', - icon: boldIcon, + icon: IconBold, tooltip: true, withKeystroke: true } ); diff --git a/packages/ckeditor5-ui/tests/menubar/menubarmenubuttonview.js b/packages/ckeditor5-ui/tests/menubar/menubarmenubuttonview.js index 643f3a43abe..4ec6e5b3b2b 100644 --- a/packages/ckeditor5-ui/tests/menubar/menubarmenubuttonview.js +++ b/packages/ckeditor5-ui/tests/menubar/menubarmenubuttonview.js @@ -5,10 +5,10 @@ /* global Event */ +import { IconDropdownArrow } from 'ckeditor5/src/icons.js'; import { Locale } from '@ckeditor/ckeditor5-utils'; import MenuBarMenuButtonView from '../../src/menubar/menubarmenubuttonview.js'; import { ButtonView, IconView } from '../../src/index.js'; -import dropdownArrowIcon from '../../theme/icons/dropdown-arrow.svg'; describe( 'MenuBarMenuButtonView', () => { let buttonView, locale; @@ -45,7 +45,7 @@ describe( 'MenuBarMenuButtonView', () => { } ); it( 'should use a specific SVG icon', () => { - expect( buttonView.arrowView.content ).to.equal( dropdownArrowIcon ); + expect( buttonView.arrowView.content ).to.equal( IconDropdownArrow ); } ); } ); diff --git a/packages/ckeditor5-ui/tsconfig.dist.json b/packages/ckeditor5-ui/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-ui/tsconfig.dist.json +++ b/packages/ckeditor5-ui/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-ui/tsconfig.json b/packages/ckeditor5-ui/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-ui/tsconfig.json +++ b/packages/ckeditor5-ui/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-undo/ckeditor5-metadata.json b/packages/ckeditor5-undo/ckeditor5-metadata.json index 451eb1052c9..60932c521aa 100644 --- a/packages/ckeditor5-undo/ckeditor5-metadata.json +++ b/packages/ckeditor5-undo/ckeditor5-metadata.json @@ -10,12 +10,12 @@ { "type": "Button", "name": "undo", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/undo.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/undo.svg" }, { "type": "Button", "name": "redo", - "iconPath": "@ckeditor/ckeditor5-core/theme/icons/redo.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/redo.svg" } ] } diff --git a/packages/ckeditor5-undo/tsconfig.dist.json b/packages/ckeditor5-undo/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-undo/tsconfig.dist.json +++ b/packages/ckeditor5-undo/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-undo/tsconfig.json b/packages/ckeditor5-undo/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-undo/tsconfig.json +++ b/packages/ckeditor5-undo/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-upload/tsconfig.dist.json b/packages/ckeditor5-upload/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-upload/tsconfig.dist.json +++ b/packages/ckeditor5-upload/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-upload/tsconfig.json b/packages/ckeditor5-upload/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-upload/tsconfig.json +++ b/packages/ckeditor5-upload/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-utils/tsconfig.dist.json b/packages/ckeditor5-utils/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-utils/tsconfig.dist.json +++ b/packages/ckeditor5-utils/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-utils/tsconfig.json b/packages/ckeditor5-utils/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-utils/tsconfig.json +++ b/packages/ckeditor5-utils/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-watchdog/tsconfig.dist.json b/packages/ckeditor5-watchdog/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-watchdog/tsconfig.dist.json +++ b/packages/ckeditor5-watchdog/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-watchdog/tsconfig.json b/packages/ckeditor5-watchdog/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-watchdog/tsconfig.json +++ b/packages/ckeditor5-watchdog/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-widget/src/utils.ts b/packages/ckeditor5-widget/src/utils.ts index 47838e55052..3b8f4d42da6 100644 --- a/packages/ckeditor5-widget/src/utils.ts +++ b/packages/ckeditor5-widget/src/utils.ts @@ -7,6 +7,7 @@ * @module widget/utils */ +import { IconDragHandle } from '@ckeditor/ckeditor5-icons'; import { Rect, CKEditorError, @@ -36,8 +37,6 @@ import { IconView } from '@ckeditor/ckeditor5-ui'; import HighlightStack, { type HighlightStackChangeEvent } from './highlightstack.js'; import { getTypeAroundFakeCaretPosition } from './widgettypearound/utils.js'; -import dragHandleIcon from '../theme/icons/drag-handle.svg'; - /** * CSS class added to each widget element. */ @@ -434,7 +433,7 @@ function addSelectionHandle( widgetElement: ViewContainerElement, writer: Downca // Use the IconView from the ui library. const icon = new IconView(); - icon.set( 'content', dragHandleIcon ); + icon.set( 'content', IconDragHandle ); // Render the icon view right away to append its #element to the selectionHandle DOM element. icon.render(); diff --git a/packages/ckeditor5-widget/src/widgettypearound/widgettypearound.ts b/packages/ckeditor5-widget/src/widgettypearound/widgettypearound.ts index 2d1a65a865c..12a2ec60559 100644 --- a/packages/ckeditor5-widget/src/widgettypearound/widgettypearound.ts +++ b/packages/ckeditor5-widget/src/widgettypearound/widgettypearound.ts @@ -10,7 +10,7 @@ */ import { Plugin } from '@ckeditor/ckeditor5-core'; - +import { IconReturnArrow } from '@ckeditor/ckeditor5-icons'; import { Template } from '@ckeditor/ckeditor5-ui'; import { @@ -67,14 +67,12 @@ import { import { isWidget } from '../utils.js'; import type Widget from '../widget.js'; -import returnIcon from '../../theme/icons/return-arrow.svg'; - import '../../theme/widgettypearound.css'; const POSSIBLE_INSERTION_POSITIONS = [ 'before', 'after' ] as const; // Do the SVG parsing once and then clone the result DOM element for each new button. -const RETURN_ARROW_ICON_ELEMENT = new DOMParser().parseFromString( returnIcon, 'image/svg+xml' ).firstChild!; +const RETURN_ARROW_ICON_ELEMENT = new DOMParser().parseFromString( IconReturnArrow, 'image/svg+xml' ).firstChild!; const PLUGIN_DISABLED_EDITING_ROOT_CLASS = 'ck-widget__type-around_disabled'; diff --git a/packages/ckeditor5-widget/tsconfig.dist.json b/packages/ckeditor5-widget/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-widget/tsconfig.dist.json +++ b/packages/ckeditor5-widget/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-widget/tsconfig.json b/packages/ckeditor5-widget/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-widget/tsconfig.json +++ b/packages/ckeditor5-widget/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-word-count/tsconfig.dist.json b/packages/ckeditor5-word-count/tsconfig.dist.json index d8e5823ec97..a8ab888e091 100644 --- a/packages/ckeditor5-word-count/tsconfig.dist.json +++ b/packages/ckeditor5-word-count/tsconfig.dist.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src", - "types": [ - "../../typings/types" - ] + "rootDir": "src" }, "include": [ "src" diff --git a/packages/ckeditor5-word-count/tsconfig.json b/packages/ckeditor5-word-count/tsconfig.json index 06d45c8982e..f011696cd1c 100644 --- a/packages/ckeditor5-word-count/tsconfig.json +++ b/packages/ckeditor5-word-count/tsconfig.json @@ -1,8 +1,7 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src", - "../../typings" + "src" ], "exclude": [ "tests" diff --git a/scripts/clean-up-svg-icons.mjs b/scripts/clean-up-svg-icons.mjs index 7fb383c7ec4..7f2ec2d46e8 100644 --- a/scripts/clean-up-svg-icons.mjs +++ b/scripts/clean-up-svg-icons.mjs @@ -51,7 +51,7 @@ const EXCLUDED_ICONS = [ ]; // A pattern to match all the icons. -const ALL_ICONS_PATTERN = 'packages/*/theme/icons'; +const ALL_ICONS_PATTERN = 'packages/ckeditor5-icons/theme'; const { paths, verifyOnly } = parseArguments( process.argv.slice( 2 ) ); diff --git a/scripts/collect-svg-icons.mjs b/scripts/collect-svg-icons.mjs index 8fc14c0d517..f22b4066501 100644 --- a/scripts/collect-svg-icons.mjs +++ b/scripts/collect-svg-icons.mjs @@ -33,7 +33,7 @@ async function collectSvgIcons() { logProcess( 'Collecting SVG icons...' ); const globOptions = { cwd: CKEDITOR5_ROOT_PATH, ignore: [ '**/build/**', '**/node_modules/**' ] }; - const svgFilesData = globSync( '**/packages/*/theme/icons/*.svg', globOptions ).map( getDataFromPath ); + const svgFilesData = globSync( '**/packages/ckeditor5-icons/theme/*.svg', globOptions ).map( getDataFromPath ); logProcess( 'Converting to PNG...' ); diff --git a/scripts/dll/webpack.config.dll.mjs b/scripts/dll/webpack.config.dll.mjs index 06ecae82b15..40e6ea85003 100644 --- a/scripts/dll/webpack.config.dll.mjs +++ b/scripts/dll/webpack.config.dll.mjs @@ -45,6 +45,7 @@ function loadCKEditor5modules( window ) { 'select-all', 'typing', 'undo', + 'icons', 'upload', 'widget', 'watchdog' @@ -76,6 +77,7 @@ const webpackConfig = { './src/undo.js', // Other, common packages: + './src/icons.js', './src/upload.js', './src/widget.js', './src/watchdog.js' diff --git a/scripts/docs/features-html-output/third-party-packages/mathtype-ckeditor5/ckeditor5-metadata.json b/scripts/docs/features-html-output/third-party-packages/mathtype-ckeditor5/ckeditor5-metadata.json index 7a339b19c44..a45b11c070f 100644 --- a/scripts/docs/features-html-output/third-party-packages/mathtype-ckeditor5/ckeditor5-metadata.json +++ b/scripts/docs/features-html-output/third-party-packages/mathtype-ckeditor5/ckeditor5-metadata.json @@ -10,12 +10,12 @@ { "type": "Button", "name": "MathType", - "iconPath": "theme/icons/formula.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/formula.svg" }, { "type": "Button", "name": "ChemType", - "iconPath": "theme/icons/chem.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/chem.svg" } ], "htmlOutput": [ diff --git a/scripts/docs/features-html-output/third-party-packages/wproofreader-ckeditor5/ckeditor5-metadata.json b/scripts/docs/features-html-output/third-party-packages/wproofreader-ckeditor5/ckeditor5-metadata.json index 4c0b0d2ca19..9398e74d07b 100644 --- a/scripts/docs/features-html-output/third-party-packages/wproofreader-ckeditor5/ckeditor5-metadata.json +++ b/scripts/docs/features-html-output/third-party-packages/wproofreader-ckeditor5/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "SplitButton", "name": "wproofreader", - "iconPath": "theme/icons/wproofreader.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/wproofreader.svg" } ] } diff --git a/typings/types.d.ts b/src/icons.ts similarity index 70% rename from typings/types.d.ts rename to src/icons.ts index f8296b35ab5..99a358b5759 100644 --- a/typings/types.d.ts +++ b/src/icons.ts @@ -3,7 +3,8 @@ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options */ -declare module '*.svg' { - const content: string; - export default content; -} +/** + * @module ckeditor5/icons + */ + +export * from '@ckeditor/ckeditor5-icons'; diff --git a/src/index.ts b/src/index.ts index 2914b0dc857..9a7b8785c30 100644 --- a/src/index.ts +++ b/src/index.ts @@ -34,6 +34,7 @@ export * from '@ckeditor/ckeditor5-highlight'; export * from '@ckeditor/ckeditor5-horizontal-line'; export * from '@ckeditor/ckeditor5-html-embed'; export * from '@ckeditor/ckeditor5-html-support'; +export * from '@ckeditor/ckeditor5-icons'; export * from '@ckeditor/ckeditor5-image'; export * from '@ckeditor/ckeditor5-indent'; export * from '@ckeditor/ckeditor5-language'; diff --git a/tsconfig.dist.ckeditor5.json b/tsconfig.dist.ckeditor5.json index 12944b998f1..85ee798a9fb 100644 --- a/tsconfig.dist.ckeditor5.json +++ b/tsconfig.dist.ckeditor5.json @@ -1,10 +1,7 @@ { "extends": "./tsconfig.dist.json", "compilerOptions": { - "rootDir": "./src", - "types": [ - "./typings/types" - ] + "rootDir": "./src" }, "include": [ "src" diff --git a/tsconfig.dll.json b/tsconfig.dll.json index 59dabe9a2d6..bc2abf90e3f 100644 --- a/tsconfig.dll.json +++ b/tsconfig.dll.json @@ -2,8 +2,5 @@ * The configuration is used when preparing DLL builds. */ { - "extends": "./tsconfig.json", - "include": [ - "./typings/" - ] + "extends": "./tsconfig.json" } diff --git a/tsconfig.docs.json b/tsconfig.docs.json index cf784525cd6..6abeede0b7f 100644 --- a/tsconfig.docs.json +++ b/tsconfig.docs.json @@ -5,7 +5,6 @@ { "extends": "./tsconfig.json", "include": [ - "./typings/", "./packages/*/src/augmentation.ts", "./external/ckeditor5-commercial/packages/*/src/augmentation.ts" ] diff --git a/tsconfig.json b/tsconfig.json index acb6117ee6f..60383420aa2 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -30,8 +30,5 @@ "moduleResolution": "node", "skipLibCheck": true, "allowSyntheticDefaultImports": true - }, - "include": [ - "./typings/" - ] + } } diff --git a/tsconfig.release-ckeditor5.json b/tsconfig.release-ckeditor5.json index b9501c7a868..c3e7369cb8d 100644 --- a/tsconfig.release-ckeditor5.json +++ b/tsconfig.release-ckeditor5.json @@ -4,7 +4,6 @@ { "extends": "./tsconfig.release.json", "include": [ - "./src/", - "./typings/" + "./src/" ] } diff --git a/tsconfig.test.json b/tsconfig.test.json index 0fcfdb17e02..6b369b65454 100644 --- a/tsconfig.test.json +++ b/tsconfig.test.json @@ -16,7 +16,6 @@ }, "include": [ "**/*.ts", - "./typings/", "./packages/*/src/augmentation.ts", "./external/ckeditor5-commercial/packages/*/src/augmentation.ts" ] diff --git a/tsconfig.typedoc.json b/tsconfig.typedoc.json index 94e00475d66..d81bed11b7c 100644 --- a/tsconfig.typedoc.json +++ b/tsconfig.typedoc.json @@ -26,8 +26,7 @@ }, "include": [ "./packages/*/src/**/*.ts", - "./external/ckeditor5-commercial/packages/*/src/**/*.ts", - "./typings/" + "./external/ckeditor5-commercial/packages/*/src/**/*.ts" ], "exclude": [ "node_modules" From 84e714105242aeed5a674d2cea860a2245530d17 Mon Sep 17 00:00:00 2001 From: Filip Sobol Date: Thu, 23 Jan 2025 16:45:32 +0100 Subject: [PATCH 2/8] Move all icons to the `@ckeditor/ckeditor5-icons package` --- .../examples/bottom-toolbar-editor.js | 5 +- docs/_snippets/framework/ui/ui-balloon.js | 12 +- docs/_snippets/framework/ui/ui-button.js | 4 +- docs/_snippets/framework/ui/ui-dropdown.js | 6 +- docs/_snippets/framework/ui/ui-icons.js | 4 +- .../tutorials/abbreviationView-level-2.js | 6 +- .../tutorials/abbreviationView-level-3.js | 6 +- docs/examples/builds/balloon-block-editor.md | 2 +- docs/examples/custom/bottom-toolbar-editor.md | 9 +- docs/features/image-upload.md | 2 +- docs/features/index.md | 32 +- docs/framework/architecture/ui-components.md | 137 +------- docs/framework/architecture/ui-library.md | 4 +- docs/framework/contributing/code-style.md | 2 +- docs/framework/deep-dive/localization.md | 2 +- .../integrating-from-source-webpack.md | 10 +- .../integrations/react.md | 4 +- .../integrations/vuejs-v2.md | 2 +- .../integrations/vuejs-v3.md | 2 +- .../quick-start-other.md | 2 +- .../licensing/license-and-legal.md | 2 +- docs/getting-started/setup/toolbar.md | 30 +- .../abbreviation-plugin-level-2.md | 11 +- .../tutorials/supporting-multiple-versions.md | 2 +- docs/updating/nim-migration/custom-plugins.md | 6 +- .../migration-to-new-installation-methods.md | 22 +- docs/updating/update-to-40.md | 16 +- package.json | 26 +- .../ckeditor5-adapter-ckfinder/package.json | 2 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-adapter-ckfinder/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../docs/features/text-alignment.md | 2 +- packages/ckeditor5-alignment/package.json | 3 +- .../ckeditor5-alignment/src/alignmentui.ts | 11 +- .../ckeditor5-alignment/tsconfig.dist.json | 5 +- packages/ckeditor5-alignment/tsconfig.json | 3 +- packages/ckeditor5-autoformat/package.json | 4 +- .../ckeditor5-autoformat/tsconfig.dist.json | 5 +- packages/ckeditor5-autoformat/tsconfig.json | 3 +- packages/ckeditor5-autosave/package.json | 2 +- .../ckeditor5-autosave/tsconfig.dist.json | 5 +- packages/ckeditor5-autosave/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 14 +- .../docs/features/basic-styles.md | 8 +- packages/ckeditor5-basic-styles/package.json | 5 +- .../ckeditor5-basic-styles/src/bold/boldui.ts | 5 +- .../src/code/codeediting.ts | 7 +- .../tests/code/codeediting.js | 7 +- .../ckeditor5-basic-styles/tsconfig.dist.json | 5 +- packages/ckeditor5-basic-styles/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../docs/features/block-quote.md | 2 +- packages/ckeditor5-block-quote/package.json | 3 +- .../ckeditor5-block-quote/src/blockquoteui.ts | 5 +- .../ckeditor5-block-quote/tsconfig.dist.json | 5 +- packages/ckeditor5-block-quote/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../docs/features/bookmarks.md | 4 +- packages/ckeditor5-bookmark/package.json | 3 +- .../ckeditor5-bookmark/src/bookmarkediting.ts | 5 +- packages/ckeditor5-bookmark/src/bookmarkui.ts | 6 +- .../src/ui/bookmarkactionsview.ts | 7 +- .../ckeditor5-bookmark/tests/bookmarkui.js | 6 +- .../ckeditor5-bookmark/tsconfig.dist.json | 5 +- packages/ckeditor5-bookmark/tsconfig.json | 3 +- .../package.json | 4 +- .../tsconfig.json | 3 +- .../tsconfig.types.json | 3 +- packages/ckeditor5-build-balloon/package.json | 4 +- .../ckeditor5-build-balloon/tsconfig.json | 3 +- .../tsconfig.types.json | 3 +- packages/ckeditor5-build-classic/package.json | 4 +- .../ckeditor5-build-classic/tsconfig.json | 3 +- .../tsconfig.types.json | 3 +- .../package.json | 4 +- .../tsconfig.json | 3 +- .../tsconfig.types.json | 3 +- packages/ckeditor5-build-inline/package.json | 4 +- packages/ckeditor5-build-inline/tsconfig.json | 3 +- .../tsconfig.types.json | 3 +- .../ckeditor5-build-multi-root/package.json | 4 +- .../ckeditor5-build-multi-root/tsconfig.json | 3 +- .../tsconfig.types.json | 3 +- .../ckeditor5-ckbox/ckeditor5-metadata.json | 4 +- .../ckeditor5-ckbox/docs/features/ckbox.md | 6 +- packages/ckeditor5-ckbox/package.json | 7 +- packages/ckeditor5-ckbox/src/ckboxcommand.ts | 44 ++- packages/ckeditor5-ckbox/src/ckboxconfig.ts | 18 ++ packages/ckeditor5-ckbox/src/ckboxui.ts | 13 +- .../ckeditor5-ckbox/tests/ckboxcommand.js | 137 ++++++++ packages/ckeditor5-ckbox/tests/ckboxui.js | 12 +- .../ckeditor5-ckbox/tests/manual/ckbox.js | 3 +- packages/ckeditor5-ckbox/tsconfig.dist.json | 5 +- packages/ckeditor5-ckbox/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../docs/features/ckfinder.md | 4 +- packages/ckeditor5-ckfinder/package.json | 5 +- packages/ckeditor5-ckfinder/src/ckfinderui.ts | 13 +- .../ckeditor5-ckfinder/tests/ckfinderui.js | 12 +- .../ckeditor5-ckfinder/tsconfig.dist.json | 5 +- packages/ckeditor5-ckfinder/tsconfig.json | 3 +- .../docs/features/drag-drop.md | 4 +- .../src/clipboardpipeline.ts | 18 +- packages/ckeditor5-clipboard/src/index.ts | 1 + .../src/utils/viewtoplaintext.ts | 38 ++- .../tests/clipboardpipeline.js | 138 +++++++- .../tests/utils/viewtoplaintext.js | 26 +- .../ckeditor5-clipboard/tsconfig.dist.json | 5 +- packages/ckeditor5-clipboard/tsconfig.json | 3 +- .../ckeditor5-cloud-services/package.json | 2 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-cloud-services/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../docs/features/code-blocks.md | 2 +- packages/ckeditor5-code-block/package.json | 3 +- .../ckeditor5-code-block/src/codeblockui.ts | 7 +- .../tests/codeblockediting.js | 4 +- .../ckeditor5-code-block/tests/codeblockui.js | 4 +- .../ckeditor5-code-block/tsconfig.dist.json | 5 +- packages/ckeditor5-code-block/tsconfig.json | 3 +- packages/ckeditor5-core/package.json | 2 +- packages/ckeditor5-core/tsconfig.dist.json | 5 +- packages/ckeditor5-core/tsconfig.json | 3 +- packages/ckeditor5-easy-image/package.json | 4 +- .../ckeditor5-easy-image/tsconfig.dist.json | 5 +- packages/ckeditor5-easy-image/tsconfig.json | 3 +- .../ckeditor5-editor-balloon/package.json | 2 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-editor-balloon/tsconfig.json | 3 +- .../ckeditor5-editor-classic/package.json | 2 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-editor-classic/tsconfig.json | 3 +- .../ckeditor5-editor-decoupled/package.json | 2 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-editor-decoupled/tsconfig.json | 3 +- packages/ckeditor5-editor-inline/package.json | 2 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-editor-inline/tsconfig.json | 3 +- .../ckeditor5-editor-multi-root/package.json | 2 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-editor-multi-root/tsconfig.json | 3 +- packages/ckeditor5-engine/src/index.ts | 1 + packages/ckeditor5-engine/tsconfig.dist.json | 5 +- packages/ckeditor5-engine/tsconfig.json | 3 +- packages/ckeditor5-enter/tsconfig.dist.json | 5 +- packages/ckeditor5-enter/tsconfig.json | 3 +- packages/ckeditor5-essentials/package.json | 2 +- .../ckeditor5-essentials/tsconfig.dist.json | 5 +- packages/ckeditor5-essentials/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../docs/features/find-and-replace.md | 2 +- .../ckeditor5-find-and-replace/package.json | 3 +- .../src/ui/findandreplaceformview.ts | 6 +- .../tests/ui/findandreplaceformview.js | 6 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-find-and-replace/tsconfig.json | 3 +- .../ckeditor5-font/ckeditor5-metadata.json | 8 +- packages/ckeditor5-font/docs/features/font.md | 2 +- packages/ckeditor5-font/package.json | 3 +- packages/ckeditor5-font/src/index.ts | 3 +- packages/ckeditor5-font/tsconfig.dist.json | 5 +- packages/ckeditor5-font/tsconfig.json | 3 +- packages/ckeditor5-heading/package.json | 3 +- .../ckeditor5-heading/src/headingbuttonsui.ts | 15 +- .../tests/headingbuttonsui.js | 4 +- packages/ckeditor5-heading/tsconfig.dist.json | 5 +- packages/ckeditor5-heading/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../docs/features/highlight.md | 2 +- packages/ckeditor5-highlight/package.json | 5 +- .../ckeditor5-highlight/tsconfig.dist.json | 5 +- packages/ckeditor5-highlight/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../docs/features/horizontal-line.md | 2 +- .../ckeditor5-horizontal-line/package.json | 5 +- .../src/horizontallineui.ts | 5 +- .../tests/horizontallineui.js | 4 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-horizontal-line/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../docs/features/html-embed.md | 2 +- packages/ckeditor5-html-embed/package.json | 3 +- .../src/htmlembedediting.ts | 11 +- .../ckeditor5-html-embed/src/htmlembedui.ts | 5 +- .../ckeditor5-html-embed/tests/htmlembedui.js | 4 +- .../ckeditor5-html-embed/tsconfig.dist.json | 5 +- packages/ckeditor5-html-embed/tsconfig.json | 3 +- .../docs/features/full-page-html.md | 2 +- .../docs/features/general-html-support.md | 2 +- .../docs/features/html-comments.md | 2 +- packages/ckeditor5-html-support/package.json | 10 +- .../tests/manual/ghs-no-features.html | 9 +- .../tests/manual/objects.html | 4 +- .../ckeditor5-html-support/tsconfig.dist.json | 5 +- packages/ckeditor5-html-support/tsconfig.json | 3 +- packages/ckeditor5-icons/package.json | 2 +- packages/ckeditor5-icons/src/index.ts | 303 +++++++++--------- packages/ckeditor5-icons/tests/index.js | 10 + packages/ckeditor5-icons/theme/arrow-down.svg | 1 - packages/ckeditor5-icons/theme/arrow-up.svg | 1 - .../ckeditor5-icons/theme/edit-comment.svg | 11 - .../theme/{ => icons}/accessibility.svg | 0 .../theme/{ => icons}/add-comment.svg | 12 +- .../theme/{ => icons}/align-bottom.svg | 0 .../theme/{ => icons}/align-center.svg | 0 .../theme/{ => icons}/align-justify.svg | 0 .../theme/{ => icons}/align-left.svg | 0 .../theme/{ => icons}/align-middle.svg | 0 .../theme/{ => icons}/align-right.svg | 0 .../theme/{ => icons}/align-top.svg | 0 .../theme/icons/arrow-down.svg | 1 + .../ckeditor5-icons/theme/icons/arrow-up.svg | 1 + .../theme/{ => icons}/bold.svg | 0 .../theme/{ => icons}/bookmark-inline.svg | 0 .../theme/{ => icons}/bookmark.svg | 0 .../theme/{ => icons}/browse-files.svg | 0 .../theme/{ => icons}/bulleted-list.svg | 0 .../theme/{ => icons}/cancel.svg | 0 .../theme/{ => icons}/caption.svg | 0 .../theme/{ => icons}/case-change.svg | 0 .../theme/{ => icons}/check.svg | 0 .../theme/{ => icons}/chevron-down.svg | 2 +- .../theme/{ => icons}/chevron-up.svg | 2 +- .../theme/{ => icons}/ckbox-image-edit.svg | 0 .../theme/{ => icons}/code-block.svg | 0 .../theme/{ => icons}/code.svg | 0 .../ckeditor5-icons/theme/{ => icons}/cog.svg | 0 .../theme/{ => icons}/color-palette.svg | 0 .../theme/{ => icons}/color-tile-check.svg | 0 .../theme/{ => icons}/comments-archive.svg | 12 +- .../theme/{ => icons}/content-lock.svg | 0 .../theme/{ => icons}/content-unlock.svg | 0 .../theme/{ => icons}/copy.svg | 0 .../theme/{ => icons}/drag-handle.svg | 0 .../theme/{ => icons}/drag-indicator.svg | 0 .../theme/{ => icons}/dropdown-arrow.svg | 0 .../theme/icons/edit-comment.svg | 1 + .../theme/{ => icons}/eraser.svg | 0 .../theme/{ => icons}/error.svg | 2 +- .../theme/{ => icons}/export-pdf.svg | 2 +- .../theme/{ => icons}/export-word.svg | 2 +- .../theme/{ => icons}/find-replace.svg | 0 .../theme/{ => icons}/font-background.svg | 0 .../theme/{ => icons}/font-color.svg | 0 .../theme/{ => icons}/font-family.svg | 0 .../theme/{ => icons}/font-size.svg | 0 .../theme/{ => icons}/heading1.svg | 0 .../theme/{ => icons}/heading2.svg | 0 .../theme/{ => icons}/heading3.svg | 0 .../theme/{ => icons}/heading4.svg | 0 .../theme/{ => icons}/heading5.svg | 0 .../theme/{ => icons}/heading6.svg | 0 .../theme/{ => icons}/history.svg | 0 .../theme/{ => icons}/horizontal-line.svg | 0 .../theme/{ => icons}/html.svg | 0 .../theme/{ => icons}/image-asset-manager.svg | 0 .../theme/{ => icons}/image-upload.svg | 0 .../theme/{ => icons}/image-url.svg | 0 .../theme/{ => icons}/image.svg | 0 .../theme/{ => icons}/import-export.svg | 0 .../{importword.svg => icons/import-word.svg} | 2 +- .../theme/{ => icons}/indent.svg | 0 .../theme/icons/insert-merge-field.svg | 1 + .../theme/{ => icons}/italic.svg | 0 .../theme/{ => icons}/legal-style-list.svg | 0 .../theme/{ => icons}/link.svg | 0 .../theme/{ => icons}/list-style-circle.svg | 0 .../list-style-decimal-leading-zero.svg | 0 .../theme/{ => icons}/list-style-decimal.svg | 0 .../theme/{ => icons}/list-style-disc.svg | 0 .../{ => icons}/list-style-lower-latin.svg | 0 .../{ => icons}/list-style-lower-roman.svg | 0 .../theme/{ => icons}/list-style-square.svg | 0 .../{ => icons}/list-style-upper-latin.svg | 0 .../{ => icons}/list-style-upper-roman.svg | 0 .../theme/{ => icons}/loupe.svg | 0 .../theme/{ => icons}/low-vision.svg | 0 .../theme/{ => icons}/magic-wand.svg | 0 .../theme/{ => icons}/marker.svg | 0 .../theme/{ => icons}/media-placeholder.svg | 0 .../theme/{ => icons}/media.svg | 0 .../theme/{ => icons}/multi-level-list.svg | 0 .../theme/{ => icons}/next-arrow.svg | 0 .../theme/icons/notification.svg | 1 + .../theme/{ => icons}/numbered-list.svg | 0 .../theme/{ => icons}/object-center.svg | 0 .../theme/{ => icons}/object-full-width.svg | 0 .../theme/{ => icons}/object-inline-left.svg | 0 .../theme/{ => icons}/object-inline-right.svg | 0 .../theme/{ => icons}/object-inline.svg | 0 .../theme/{ => icons}/object-left.svg | 0 .../theme/{ => icons}/object-right.svg | 0 .../theme/{ => icons}/object-size-custom.svg | 0 .../theme/{ => icons}/object-size-full.svg | 0 .../theme/{ => icons}/object-size-large.svg | 0 .../theme/{ => icons}/object-size-medium.svg | 0 .../theme/{ => icons}/object-size-small.svg | 0 .../theme/{ => icons}/outdent.svg | 0 .../theme/{ => icons}/page-break.svg | 0 .../theme/icons/pagination-example.svg | 1 + .../icons/paint-roller-cursor-default.svg | 1 + .../theme/icons/paint-roller-cursor-text.svg | 1 + .../theme/icons/paint-roller.svg | 1 + .../theme/{ => icons}/paragraph.svg | 0 .../ckeditor5-icons/theme/{ => icons}/pen.svg | 0 .../theme/{ => icons}/pencil.svg | 0 .../theme/{ => icons}/pilcrow.svg | 0 .../theme/{ => icons}/play.svg | 0 .../theme/{ => icons}/plus.svg | 0 .../theme/icons/preview-merge-fields.svg | 1 + .../theme/{ => icons}/previous-arrow.svg | 0 .../ckeditor5-icons/theme/icons/print.svg | 1 + .../theme/{ => icons}/project-logo.svg | 0 .../theme/{ => icons}/quote.svg | 0 .../theme/{ => icons}/redo.svg | 0 .../theme/icons/remove-comment.svg | 1 + .../theme/{ => icons}/remove-format.svg | 0 .../theme/{ => icons}/remove.svg | 0 .../theme/{ => icons}/return-arrow.svg | 0 .../theme/icons/revision-history.svg | 1 + .../theme/{ => icons}/robot-pencil.svg | 0 .../theme/{ => icons}/select-all.svg | 0 .../theme/{ => icons}/show-blocks.svg | 0 .../theme/{ => icons}/source-editing.svg | 0 .../theme/{ => icons}/special-characters.svg | 0 .../theme/{ => icons}/strikethrough.svg | 0 .../theme/{ => icons}/submit.svg | 0 .../theme/{ => icons}/subscript.svg | 0 .../theme/{ => icons}/superscript.svg | 0 .../{ => icons}/table-cell-properties.svg | 0 .../theme/{ => icons}/table-column.svg | 0 .../theme/{ => icons}/table-merge-cell.svg | 0 .../theme/icons/table-of-contents.svg | 1 + .../theme/{ => icons}/table-properties.svg | 0 .../theme/{ => icons}/table-row.svg | 0 .../theme/{ => icons}/table.svg | 0 .../theme/icons/template-generic.svg | 1 + .../theme/{ => icons}/template.svg | 0 .../theme/{ => icons}/text-alternative.svg | 0 .../theme/{ => icons}/text.svg | 0 .../theme/{ => icons}/three-vertical-dots.svg | 0 .../theme/{ => icons}/todo-list.svg | 0 .../{ => icons}/track-changes-accept.svg | 12 +- .../{ => icons}/track-changes-discard.svg | 12 +- .../theme/{ => icons}/track-changes.svg | 12 +- .../theme/{ => icons}/underline.svg | 0 .../theme/{ => icons}/undo.svg | 0 .../theme/{ => icons}/unlink.svg | 0 .../theme/{ => icons}/user.svg | 2 +- .../ckeditor5-icons/theme/icons/warning.svg | 1 + .../theme/insert-merge-field.svg | 7 - .../ckeditor5-icons/theme/notification.svg | 11 - .../theme/pagination-example.svg | 1 - .../theme/paint-roller-cursor-default.svg | 17 - .../theme/paint-roller-cursor-text.svg | 7 - .../ckeditor5-icons/theme/paint-roller.svg | 1 - .../theme/preview-merge-fields.svg | 8 - packages/ckeditor5-icons/theme/print.svg | 1 - .../ckeditor5-icons/theme/remove-comment.svg | 11 - .../theme/revision-history.svg | 1 - .../theme/table-of-contents.svg | 1 - .../theme/template-generic.svg | 6 - packages/ckeditor5-icons/theme/twitter.svg | 20 -- packages/ckeditor5-icons/theme/warning.svg | 3 - packages/ckeditor5-icons/tsconfig.dist.json | 5 +- packages/ckeditor5-icons/tsconfig.json | 3 +- .../ckeditor5-image/ckeditor5-metadata.json | 32 +- .../docs/features/images-captions.md | 2 +- .../docs/features/images-inserting.md | 4 +- .../docs/features/images-installation.md | 8 +- .../docs/features/images-linking.md | 2 +- .../docs/features/images-resizing.md | 6 +- .../docs/features/images-responsive.md | 2 +- .../docs/features/images-styles.md | 22 +- .../docs/features/images-text-alternative.md | 2 +- packages/ckeditor5-image/package.json | 3 +- .../src/image/insertimagecommand.ts | 4 + .../src/imagecaption/imagecaptionui.ts | 5 +- .../src/imageinsert/imageinsertui.ts | 9 +- .../src/imageinsert/imageinsertviaurlui.ts | 5 +- .../src/imageresize/imageresizebuttons.ts | 19 +- .../ui/imagecustomresizeformview.ts | 6 +- .../ckeditor5-image/src/imagestyle/utils.ts | 41 ++- .../imagetextalternativeui.ts | 5 +- .../ui/textalternativeformview.ts | 6 +- .../src/imageupload/imageuploadui.ts | 11 +- packages/ckeditor5-image/src/index.ts | 1 + .../tests/image/insertimagecommand.js | 16 + .../tests/imagecaption/imagecaptionui.js | 4 +- .../tests/imageinsert/imageinsertviaurlui.js | 6 +- .../tests/imageupload/imageuploadui.js | 12 +- packages/ckeditor5-image/tsconfig.dist.json | 5 +- packages/ckeditor5-image/tsconfig.json | 3 +- .../ckeditor5-indent/ckeditor5-metadata.json | 4 +- .../ckeditor5-indent/docs/features/indent.md | 2 +- packages/ckeditor5-indent/package.json | 7 +- packages/ckeditor5-indent/src/indentui.ts | 7 +- packages/ckeditor5-indent/tests/indentui.js | 18 +- packages/ckeditor5-indent/tsconfig.dist.json | 5 +- packages/ckeditor5-indent/tsconfig.json | 3 +- packages/ckeditor5-language/package.json | 2 +- .../ckeditor5-language/tsconfig.dist.json | 5 +- packages/ckeditor5-language/tsconfig.json | 3 +- .../ckeditor5-link/ckeditor5-metadata.json | 4 +- packages/ckeditor5-link/docs/features/link.md | 4 +- packages/ckeditor5-link/package.json | 7 +- .../ckeditor5-link/src/ui/linkformview.ts | 6 +- packages/ckeditor5-link/tsconfig.dist.json | 5 +- packages/ckeditor5-link/tsconfig.json | 3 +- .../ckeditor5-list/ckeditor5-metadata.json | 12 +- .../docs/features/lists-editing.md | 2 +- .../ckeditor5-list/docs/features/lists.md | 8 +- .../docs/features/todo-lists.md | 2 +- packages/ckeditor5-list/package.json | 3 +- packages/ckeditor5-list/src/list/listui.ts | 7 +- packages/ckeditor5-list/src/listconfig.ts | 68 ++++ .../src/listproperties/listpropertiesui.ts | 33 +- .../src/listproperties/utils/config.ts | 12 +- .../ckeditor5-list/src/todolist/todolistui.ts | 5 +- .../tests/listproperties/listpropertiesui.js | 237 +++++++++++++- .../tests/manual/list-properties.html | 4 + .../tests/manual/list-properties.js | 35 ++ packages/ckeditor5-list/tsconfig.dist.json | 5 +- packages/ckeditor5-list/tsconfig.json | 3 +- packages/ckeditor5-markdown-gfm/package.json | 6 +- .../ckeditor5-markdown-gfm/tsconfig.dist.json | 5 +- packages/ckeditor5-markdown-gfm/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../docs/features/media-embed.md | 2 +- packages/ckeditor5-media-embed/package.json | 3 +- .../ckeditor5-media-embed/tsconfig.dist.json | 5 +- packages/ckeditor5-media-embed/tsconfig.json | 3 +- packages/ckeditor5-mention/package.json | 2 +- .../ckeditor5-mention/src/mentioncommand.ts | 22 +- packages/ckeditor5-mention/src/mentionui.ts | 10 +- .../ckeditor5-mention/tests/mentioncommand.js | 13 - packages/ckeditor5-mention/tests/mentionui.js | 69 +++- packages/ckeditor5-mention/tsconfig.dist.json | 5 +- packages/ckeditor5-mention/tsconfig.json | 3 +- packages/ckeditor5-minimap/package.json | 2 +- packages/ckeditor5-minimap/tsconfig.dist.json | 5 +- packages/ckeditor5-minimap/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../docs/features/page-break.md | 2 +- packages/ckeditor5-page-break/package.json | 5 +- .../ckeditor5-page-break/tsconfig.dist.json | 5 +- packages/ckeditor5-page-break/tsconfig.json | 3 +- packages/ckeditor5-paragraph/package.json | 3 +- .../src/paragraphbuttonui.ts | 5 +- .../tests/paragraphbuttonui.js | 2 +- .../ckeditor5-paragraph/tsconfig.dist.json | 5 +- packages/ckeditor5-paragraph/tsconfig.json | 3 +- .../ckeditor5-paste-from-office/package.json | 2 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-paste-from-office/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../docs/features/remove-format.md | 2 +- packages/ckeditor5-remove-format/package.json | 3 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-remove-format/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 4 +- .../docs/features/restricted-editing.md | 2 +- .../ckeditor5-restricted-editing/package.json | 3 +- .../tsconfig.dist.json | 5 +- .../tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../docs/features/select-all.md | 2 +- packages/ckeditor5-select-all/package.json | 3 +- .../ckeditor5-select-all/tsconfig.dist.json | 5 +- packages/ckeditor5-select-all/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../docs/features/show-blocks.md | 2 +- packages/ckeditor5-show-blocks/package.json | 5 +- .../ckeditor5-show-blocks/tsconfig.dist.json | 5 +- packages/ckeditor5-show-blocks/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../docs/features/source-editing.md | 2 +- .../ckeditor5-source-editing/package.json | 3 +- .../tsconfig.dist.json | 5 +- .../ckeditor5-source-editing/tsconfig.json | 3 +- .../ckeditor5-metadata.json | 2 +- .../docs/features/special-characters.md | 8 +- .../ckeditor5-special-characters/package.json | 3 +- .../tsconfig.dist.json | 5 +- .../tsconfig.json | 3 +- packages/ckeditor5-style/package.json | 8 +- packages/ckeditor5-style/tsconfig.dist.json | 5 +- packages/ckeditor5-style/tsconfig.json | 3 +- .../ckeditor5-table/ckeditor5-metadata.json | 12 +- .../docs/features/tables-caption.md | 2 +- .../docs/features/tables-styling.md | 6 +- .../ckeditor5-table/docs/features/tables.md | 10 +- packages/ckeditor5-table/package.json | 3 +- .../src/tablecaption/tablecaptionui.ts | 6 +- .../ui/tablecellpropertiesview.ts | 32 +- .../tableproperties/ui/tablepropertiesview.ts | 19 +- .../src/utils/ui/table-properties.ts | 2 + .../ui/tablecellpropertiesview.js | 21 ++ .../tableproperties/ui/tablepropertiesview.js | 10 + packages/ckeditor5-table/tests/tableui.js | 6 +- packages/ckeditor5-table/tsconfig.dist.json | 5 +- packages/ckeditor5-table/tsconfig.json | 3 +- packages/ckeditor5-theme-lark/package.json | 12 - packages/ckeditor5-typing/tsconfig.dist.json | 5 +- packages/ckeditor5-typing/tsconfig.json | 3 +- packages/ckeditor5-ui/ckeditor5-metadata.json | 2 +- packages/ckeditor5-ui/package.json | 5 +- .../src/button/listitembuttonview.ts | 4 +- .../colorselector/colorgridsfragmentview.ts | 7 +- .../colorselector/colorpickerfragmentview.ts | 7 +- .../ckeditor5-ui/src/dialog/dialogview.ts | 4 +- packages/ckeditor5-ui/src/index.ts | 2 + .../src/panel/balloon/contextualballoon.ts | 7 +- .../src/search/text/searchtextqueryview.ts | 8 +- .../ckeditor5-ui/src/toolbar/toolbarview.ts | 49 ++- packages/ckeditor5-ui/src/tooltipmanager.ts | 34 +- .../tests/collapsible/collapsibleview.js | 2 +- .../tests/colorgrid/colortileview.js | 2 +- .../tests/colorselector/colorselectorview.js | 2 +- packages/ckeditor5-ui/tests/dialog/dialog.js | 2 +- .../ckeditor5-ui/tests/dialog/dialogview.js | 2 +- .../dropdown/menu/dropdownmenubuttonview.js | 2 +- .../tests/formheader/formheaderview.js | 2 +- .../tests/manual/dialog/dialog.ts | 5 +- .../tests/manual/dropdown/dropdown.js | 2 +- .../tests/manual/tickets/9412/1.js | 2 +- .../tests/menubar/menubarmenubuttonview.js | 2 +- .../tests/search/text/searchtextqueryview.js | 6 +- .../tests/toolbar/block/blocktoolbar.js | 8 +- .../ckeditor5-ui/tests/toolbar/toolbarview.js | 54 +++- .../tests/tooltip/tooltipmanager.js | 25 ++ packages/ckeditor5-ui/tsconfig.dist.json | 5 +- packages/ckeditor5-ui/tsconfig.json | 3 +- .../ckeditor5-undo/ckeditor5-metadata.json | 4 +- .../ckeditor5-undo/docs/features/undo-redo.md | 2 +- packages/ckeditor5-undo/package.json | 5 +- packages/ckeditor5-undo/src/undoui.ts | 8 +- packages/ckeditor5-undo/tests/undoui.js | 10 +- packages/ckeditor5-undo/tsconfig.dist.json | 5 +- packages/ckeditor5-undo/tsconfig.json | 3 +- packages/ckeditor5-upload/tsconfig.dist.json | 5 +- packages/ckeditor5-upload/tsconfig.json | 3 +- packages/ckeditor5-utils/package.json | 6 +- .../ckeditor5-utils/src/collectstylesheets.ts | 66 ++++ packages/ckeditor5-utils/src/index.ts | 2 + .../tests/collectstylesheets.js | 109 +++++++ packages/ckeditor5-utils/tsconfig.dist.json | 5 +- packages/ckeditor5-utils/tsconfig.json | 3 +- packages/ckeditor5-watchdog/package.json | 10 +- .../ckeditor5-watchdog/src/augmentation.ts | 1 - .../ckeditor5-watchdog/src/contextwatchdog.ts | 16 +- .../ckeditor5-watchdog/src/editorwatchdog.ts | 19 +- packages/ckeditor5-watchdog/src/watchdog.ts | 3 +- .../ckeditor5-watchdog/tsconfig.dist.json | 5 +- packages/ckeditor5-watchdog/tsconfig.json | 3 +- packages/ckeditor5-widget/package.json | 1 + packages/ckeditor5-widget/tsconfig.dist.json | 5 +- packages/ckeditor5-widget/tsconfig.json | 3 +- packages/ckeditor5-word-count/package.json | 2 +- .../ckeditor5-word-count/tsconfig.dist.json | 5 +- packages/ckeditor5-word-count/tsconfig.json | 3 +- scripts/clean-up-svg-icons.mjs | 27 +- scripts/collect-svg-icons.mjs | 2 +- .../ckeditor5-metadata.json | 4 +- .../ckeditor5-metadata.json | 2 +- scripts/svgo.config.cjs | 5 +- scripts/utils/svgoviewboxplugin.cjs | 46 +++ tests/_utils/abbreviationView-level-2.js | 6 +- tests/_utils/abbreviationView-level-3.js | 6 +- tests/manual/abbreviation-level-2.md | 11 +- tests/manual/abbreviation-level-3.md | 2 +- tsconfig.dist.ckeditor5.json | 5 +- tsconfig.dll.json | 5 +- tsconfig.docs.json | 1 + tsconfig.json | 5 +- tsconfig.release-ckeditor5.json | 3 +- tsconfig.test.json | 1 + tsconfig.typedoc.json | 3 +- typings/types.d.ts | 9 + 580 files changed, 2597 insertions(+), 1342 deletions(-) create mode 100644 packages/ckeditor5-icons/tests/index.js delete mode 100644 packages/ckeditor5-icons/theme/arrow-down.svg delete mode 100644 packages/ckeditor5-icons/theme/arrow-up.svg delete mode 100644 packages/ckeditor5-icons/theme/edit-comment.svg rename packages/ckeditor5-icons/theme/{ => icons}/accessibility.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/add-comment.svg (50%) rename packages/ckeditor5-icons/theme/{ => icons}/align-bottom.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/align-center.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/align-justify.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/align-left.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/align-middle.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/align-right.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/align-top.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/icons/arrow-down.svg create mode 100644 packages/ckeditor5-icons/theme/icons/arrow-up.svg rename packages/ckeditor5-icons/theme/{ => icons}/bold.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/bookmark-inline.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/bookmark.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/browse-files.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/bulleted-list.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/cancel.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/caption.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/case-change.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/check.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/chevron-down.svg (82%) rename packages/ckeditor5-icons/theme/{ => icons}/chevron-up.svg (81%) rename packages/ckeditor5-icons/theme/{ => icons}/ckbox-image-edit.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/code-block.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/code.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/cog.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/color-palette.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/color-tile-check.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/comments-archive.svg (61%) rename packages/ckeditor5-icons/theme/{ => icons}/content-lock.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/content-unlock.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/copy.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/drag-handle.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/drag-indicator.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/dropdown-arrow.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/icons/edit-comment.svg rename packages/ckeditor5-icons/theme/{ => icons}/eraser.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/error.svg (97%) rename packages/ckeditor5-icons/theme/{ => icons}/export-pdf.svg (87%) rename packages/ckeditor5-icons/theme/{ => icons}/export-word.svg (99%) rename packages/ckeditor5-icons/theme/{ => icons}/find-replace.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/font-background.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/font-color.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/font-family.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/font-size.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/heading1.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/heading2.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/heading3.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/heading4.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/heading5.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/heading6.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/history.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/horizontal-line.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/html.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/image-asset-manager.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/image-upload.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/image-url.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/image.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/import-export.svg (100%) rename packages/ckeditor5-icons/theme/{importword.svg => icons/import-word.svg} (76%) rename packages/ckeditor5-icons/theme/{ => icons}/indent.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/icons/insert-merge-field.svg rename packages/ckeditor5-icons/theme/{ => icons}/italic.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/legal-style-list.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/link.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/list-style-circle.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/list-style-decimal-leading-zero.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/list-style-decimal.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/list-style-disc.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/list-style-lower-latin.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/list-style-lower-roman.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/list-style-square.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/list-style-upper-latin.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/list-style-upper-roman.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/loupe.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/low-vision.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/magic-wand.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/marker.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/media-placeholder.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/media.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/multi-level-list.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/next-arrow.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/icons/notification.svg rename packages/ckeditor5-icons/theme/{ => icons}/numbered-list.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/object-center.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/object-full-width.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/object-inline-left.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/object-inline-right.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/object-inline.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/object-left.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/object-right.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/object-size-custom.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/object-size-full.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/object-size-large.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/object-size-medium.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/object-size-small.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/outdent.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/page-break.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/icons/pagination-example.svg create mode 100644 packages/ckeditor5-icons/theme/icons/paint-roller-cursor-default.svg create mode 100644 packages/ckeditor5-icons/theme/icons/paint-roller-cursor-text.svg create mode 100644 packages/ckeditor5-icons/theme/icons/paint-roller.svg rename packages/ckeditor5-icons/theme/{ => icons}/paragraph.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/pen.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/pencil.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/pilcrow.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/play.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/plus.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/icons/preview-merge-fields.svg rename packages/ckeditor5-icons/theme/{ => icons}/previous-arrow.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/icons/print.svg rename packages/ckeditor5-icons/theme/{ => icons}/project-logo.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/quote.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/redo.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/icons/remove-comment.svg rename packages/ckeditor5-icons/theme/{ => icons}/remove-format.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/remove.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/return-arrow.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/icons/revision-history.svg rename packages/ckeditor5-icons/theme/{ => icons}/robot-pencil.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/select-all.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/show-blocks.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/source-editing.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/special-characters.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/strikethrough.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/submit.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/subscript.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/superscript.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/table-cell-properties.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/table-column.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/table-merge-cell.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/icons/table-of-contents.svg rename packages/ckeditor5-icons/theme/{ => icons}/table-properties.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/table-row.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/table.svg (100%) create mode 100644 packages/ckeditor5-icons/theme/icons/template-generic.svg rename packages/ckeditor5-icons/theme/{ => icons}/template.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/text-alternative.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/text.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/three-vertical-dots.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/todo-list.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/track-changes-accept.svg (66%) rename packages/ckeditor5-icons/theme/{ => icons}/track-changes-discard.svg (69%) rename packages/ckeditor5-icons/theme/{ => icons}/track-changes.svg (51%) rename packages/ckeditor5-icons/theme/{ => icons}/underline.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/undo.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/unlink.svg (100%) rename packages/ckeditor5-icons/theme/{ => icons}/user.svg (95%) create mode 100644 packages/ckeditor5-icons/theme/icons/warning.svg delete mode 100644 packages/ckeditor5-icons/theme/insert-merge-field.svg delete mode 100644 packages/ckeditor5-icons/theme/notification.svg delete mode 100644 packages/ckeditor5-icons/theme/pagination-example.svg delete mode 100644 packages/ckeditor5-icons/theme/paint-roller-cursor-default.svg delete mode 100644 packages/ckeditor5-icons/theme/paint-roller-cursor-text.svg delete mode 100644 packages/ckeditor5-icons/theme/paint-roller.svg delete mode 100644 packages/ckeditor5-icons/theme/preview-merge-fields.svg delete mode 100644 packages/ckeditor5-icons/theme/print.svg delete mode 100644 packages/ckeditor5-icons/theme/remove-comment.svg delete mode 100644 packages/ckeditor5-icons/theme/revision-history.svg delete mode 100644 packages/ckeditor5-icons/theme/table-of-contents.svg delete mode 100644 packages/ckeditor5-icons/theme/template-generic.svg delete mode 100755 packages/ckeditor5-icons/theme/twitter.svg delete mode 100644 packages/ckeditor5-icons/theme/warning.svg create mode 100644 packages/ckeditor5-utils/src/collectstylesheets.ts create mode 100644 packages/ckeditor5-utils/tests/collectstylesheets.js create mode 100644 scripts/utils/svgoviewboxplugin.cjs create mode 100644 typings/types.d.ts diff --git a/docs/_snippets/examples/bottom-toolbar-editor.js b/docs/_snippets/examples/bottom-toolbar-editor.js index 93b870020fe..a056cf1f848 100644 --- a/docs/_snippets/examples/bottom-toolbar-editor.js +++ b/docs/_snippets/examples/bottom-toolbar-editor.js @@ -6,6 +6,7 @@ /* globals console, window, document */ import { Plugin } from '@ckeditor/ckeditor5-core'; +import { IconFontColor } from '@ckeditor/ckeditor5-icons'; import { Font } from '@ckeditor/ckeditor5-font'; import { Indent } from '@ckeditor/ckeditor5-indent'; import { List } from '@ckeditor/ckeditor5-list'; @@ -26,8 +27,6 @@ import { Bold, Italic, Strikethrough, Superscript, Subscript, Underline } from ' import { Table, TableToolbar } from '@ckeditor/ckeditor5-table'; import { CS_CONFIG } from '@ckeditor/ckeditor5-cloud-services/tests/_utils/cloud-services-config.js'; -import fontColorIcon from '@ckeditor/ckeditor5-font/theme/icons/font-color.svg'; - import DecoupledEditor from '../build-decoupled-document.js'; class FormattingOptions extends Plugin { @@ -96,7 +95,7 @@ class FormattingOptions extends Plugin { // Using the font color icon to visually represent the formatting. dropdownView.buttonView.set( { tooltip: t( 'Formatting options' ), - icon: fontColorIcon + icon: IconFontColor } ); dropdownView.panelView.children.add( toolbarView ); diff --git a/docs/_snippets/framework/ui/ui-balloon.js b/docs/_snippets/framework/ui/ui-balloon.js index 4f7146d2f9c..5433e13c06f 100644 --- a/docs/_snippets/framework/ui/ui-balloon.js +++ b/docs/_snippets/framework/ui/ui-balloon.js @@ -32,16 +32,12 @@ import { createLabeledInputText } from '@ckeditor/ckeditor5-ui'; import { Collection, Locale } from '@ckeditor/ckeditor5-utils'; - -import italicIcon from '@ckeditor/ckeditor5-basic-styles/theme/icons/italic.svg'; -import boldIcon from '@ckeditor/ckeditor5-core/theme/icons/bold.svg'; -import { icons as coreIcons } from 'ckeditor5/src/core.js'; - import { ClassicEditor } from '@ckeditor/ckeditor5-editor-classic'; import { Essentials } from '@ckeditor/ckeditor5-essentials'; import { Bold, Italic, Underline } from '@ckeditor/ckeditor5-basic-styles'; import { Plugin } from '@ckeditor/ckeditor5-core'; import { Paragraph } from '@ckeditor/ckeditor5-paragraph'; +import * as icons from '@ckeditor/ckeditor5-icons'; window.BalloonPanelView = BalloonPanelView; window.ButtonView = ButtonView; @@ -68,11 +64,7 @@ window.createLabeledInputText = createLabeledInputText; window.Collection = Collection; window.Locale = Locale; -window.checkIcon = coreIcons.check; -window.coreIcons = coreIcons; -window.cancelIcon = coreIcons.cancel; -window.boldIcon = boldIcon; -window.italicIcon = italicIcon; +window.icons = icons; window.DialogViewPosition = DialogViewPosition; window.Plugin = Plugin; diff --git a/docs/_snippets/framework/ui/ui-button.js b/docs/_snippets/framework/ui/ui-button.js index 87f63f1457c..2c9a115e994 100644 --- a/docs/_snippets/framework/ui/ui-button.js +++ b/docs/_snippets/framework/ui/ui-button.js @@ -3,7 +3,7 @@ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options */ -/* globals document, console, Locale, ButtonView, checkIcon, ToolbarView, ClassicEditor, TooltipManager, Essentials */ +/* globals document, console, Locale, ButtonView, icons, ToolbarView, ClassicEditor, TooltipManager, Essentials */ const locale = new Locale(); @@ -35,7 +35,7 @@ const saveButton = new ButtonView(); saveButton.set( { label: 'Save', withText: false, - icon: checkIcon, + icon: icons.IconCheck, class: 'ck-button-save' } ); saveButton.render(); diff --git a/docs/_snippets/framework/ui/ui-dropdown.js b/docs/_snippets/framework/ui/ui-dropdown.js index 55e8afb16bc..23f2b3242bc 100644 --- a/docs/_snippets/framework/ui/ui-dropdown.js +++ b/docs/_snippets/framework/ui/ui-dropdown.js @@ -4,7 +4,7 @@ */ /* globals Locale, Collection, Model, createDropdown, addListToDropdown, ButtonView, -boldIcon, italicIcon, SplitButtonView, addToolbarToDropdown, ToolbarView, document */ +icons, SplitButtonView, addToolbarToDropdown, ToolbarView, document */ const locale = new Locale(); @@ -35,8 +35,8 @@ listDropdown.render(); const bold = new ButtonView(); const italic = new ButtonView(); -bold.set( { label: 'Bold', withText: false, icon: boldIcon } ); -italic.set( { label: 'Italic', withText: false, icon: italicIcon } ); +bold.set( { label: 'Bold', withText: false, icon: icons.IconBold } ); +italic.set( { label: 'Italic', withText: false, icon: icons.IconItalic } ); const buttons = [ bold, italic ]; diff --git a/docs/_snippets/framework/ui/ui-icons.js b/docs/_snippets/framework/ui/ui-icons.js index ecedcacd258..66fcaf78f78 100644 --- a/docs/_snippets/framework/ui/ui-icons.js +++ b/docs/_snippets/framework/ui/ui-icons.js @@ -3,13 +3,13 @@ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options */ -/* globals Locale, ToolbarView, coreIcons, IconView, document */ +/* globals Locale, ToolbarView, icons, IconView, document */ const locale = new Locale(); const toolbarIcons = new ToolbarView( locale ); -Object.values( coreIcons ).forEach( svg => { +Object.values( icons ).forEach( svg => { const icon = new IconView(); icon.content = svg; icon.render(); diff --git a/docs/_snippets/tutorials/abbreviationView-level-2.js b/docs/_snippets/tutorials/abbreviationView-level-2.js index bffccd2336b..6e29c40d8ed 100644 --- a/docs/_snippets/tutorials/abbreviationView-level-2.js +++ b/docs/_snippets/tutorials/abbreviationView-level-2.js @@ -10,7 +10,7 @@ import { ButtonView, submitHandler } from '@ckeditor/ckeditor5-ui'; -import { icons } from '@ckeditor/ckeditor5-core'; +import { IconCheck, IconCancel } from '@ckeditor/ckeditor5-icons'; export default class FormView extends View { constructor( locale ) { @@ -19,11 +19,11 @@ export default class FormView extends View { this.abbrInputView = this._createInput( 'Add abbreviation' ); this.titleInputView = this._createInput( 'Add title' ); - this.saveButtonView = this._createButton( 'Save', icons.check, 'ck-button-save' ); + this.saveButtonView = this._createButton( 'Save', IconCheck, 'ck-button-save' ); // Submit type of the button will trigger the submit event on entire form when clicked (see submitHandler() in render() below). this.saveButtonView.type = 'submit'; - this.cancelButtonView = this._createButton( 'Cancel', icons.cancel, 'ck-button-cancel' ); + this.cancelButtonView = this._createButton( 'Cancel', IconCancel, 'ck-button-cancel' ); // Delegate ButtonView#execute to FormView#cancel this.cancelButtonView.delegate( 'execute' ).to( this, 'cancel' ); diff --git a/docs/_snippets/tutorials/abbreviationView-level-3.js b/docs/_snippets/tutorials/abbreviationView-level-3.js index f1061d0d09c..6907c939695 100644 --- a/docs/_snippets/tutorials/abbreviationView-level-3.js +++ b/docs/_snippets/tutorials/abbreviationView-level-3.js @@ -12,7 +12,7 @@ import { FocusCycler } from '@ckeditor/ckeditor5-ui'; import { FocusTracker, KeystrokeHandler } from '@ckeditor/ckeditor5-utils'; -import { icons } from '@ckeditor/ckeditor5-core'; +import { IconCheck, IconCancel } from '@ckeditor/ckeditor5-icons'; export default class FormView extends View { constructor( locale ) { @@ -24,12 +24,12 @@ export default class FormView extends View { this.abbrInputView = this._createInput( 'Add abbreviation' ); this.titleInputView = this._createInput( 'Add title' ); - this.saveButtonView = this._createButton( 'Save', icons.check, 'ck-button-save' ); + this.saveButtonView = this._createButton( 'Save', IconCheck, 'ck-button-save' ); // Submit type of the button will trigger the submit event on entire form when clicked (see submitHandler() in render() below). this.saveButtonView.type = 'submit'; - this.cancelButtonView = this._createButton( 'Cancel', icons.cancel, 'ck-button-cancel' ); + this.cancelButtonView = this._createButton( 'Cancel', IconCancel, 'ck-button-cancel' ); // Delegate ButtonView#execute to FormView#cancel this.cancelButtonView.delegate( 'execute' ).to( this, 'cancel' ); diff --git a/docs/examples/builds/balloon-block-editor.md b/docs/examples/builds/balloon-block-editor.md index 1cdf2625d52..0e9475e437e 100644 --- a/docs/examples/builds/balloon-block-editor.md +++ b/docs/examples/builds/balloon-block-editor.md @@ -12,7 +12,7 @@ classes: main__content--no-toc The balloon block editor type lets you create your content directly in its target location with the help of two toolbars: * A balloon toolbar that appears next to the selected editable document element (offering inline content formatting tools). -* A {@link getting-started/setup/toolbar#block-toolbar block toolbar} accessible using the toolbar handle button {@icon @ckeditor/ckeditor5-core/theme/icons/drag-indicator.svg Drag indicator} attached to the editable content area and following the selection in the document (bringing additional block formatting tools). The {@icon @ckeditor/ckeditor5-core/theme/icons/drag-indicator.svg Drag indicator} button is also a handle that can be used to drag and drop blocks around the content. +* A {@link getting-started/setup/toolbar#block-toolbar block toolbar} accessible using the toolbar handle button {@icon @ckeditor/ckeditor5-icons/theme/icons/drag-indicator.svg Drag indicator} attached to the editable content area and following the selection in the document (bringing additional block formatting tools). The {@icon @ckeditor/ckeditor5-icons/theme/icons/drag-indicator.svg Drag indicator} button is also a handle that can be used to drag and drop blocks around the content. Check out the [source code](https://github.com/ckeditor/ckeditor5-demos/tree/master/user-interface-balloon-block) of this editor preset or build your custom editor setup with our [interactive Builder](https://ckeditor.com/ckeditor-5/builder/?redirect=docs). diff --git a/docs/examples/custom/bottom-toolbar-editor.md b/docs/examples/custom/bottom-toolbar-editor.md index 89e1e70c46c..f4e77e890a8 100644 --- a/docs/examples/custom/bottom-toolbar-editor.md +++ b/docs/examples/custom/bottom-toolbar-editor.md @@ -59,10 +59,13 @@ import { DropdownButtonView, DropdownPanelView, DropdownView, - ToolbarView + ToolbarView, + IconFontColor, + registerIcon } from 'ckeditor5'; import { EasyImage } from 'ckeditor5-premium-features'; -import fontColorIcon from '@ckeditor/ckeditor5-font/theme/icons/font-color.svg'; + +const fontColorIcon =/* #__PURE__ */ registerIcon( 'fontColor', IconFontColor ); class FormattingOptions extends Plugin { /** @@ -143,7 +146,7 @@ class FormattingOptions extends Plugin { // Using the font color icon to visually represent the formatting. buttonView.set( { tooltip: t( 'Formatting options' ), - icon: fontColorIcon + icon: fontColorIcon() } ); dropdownView.panelView.children.add( toolbarView ); diff --git a/docs/features/image-upload.md b/docs/features/image-upload.md index dccc37b8e5c..572fd5c5a20 100644 --- a/docs/features/image-upload.md +++ b/docs/features/image-upload.md @@ -18,7 +18,7 @@ Inserting {@link features/images-overview images} into content created with CKEd ## Demo -This demo is configured to use {@link features/ckbox CKBox} for image upload and management. Use the image upload button {@icon @ckeditor/ckeditor5-core/theme/icons/image-upload.svg Image} to upload images or the CKBox button {@icon @ckeditor/ckeditor5-core/theme/icons/browse-files.svg Open file manager} to browse and select existing images from the file manager. It also includes the `AutoImage` plugin, which lets you {@link features/images-inserting#inserting-images-via-pasting-a-url-into-the-editor paste image URLs directly}. +This demo is configured to use {@link features/ckbox CKBox} for image upload and management. Use the image upload button {@icon @ckeditor/ckeditor5-icons/theme/icons/image-upload.svg Image} to upload images or the CKBox button {@icon @ckeditor/ckeditor5-icons/theme/icons/browse-files.svg Open file manager} to browse and select existing images from the file manager. It also includes the `AutoImage` plugin, which lets you {@link features/images-inserting#inserting-images-via-pasting-a-url-into-the-editor paste image URLs directly}. {@snippet features/image-upload} diff --git a/docs/features/index.md b/docs/features/index.md index 45162244e94..3e2dc2bcbf2 100644 --- a/docs/features/index.md +++ b/docs/features/index.md @@ -25,25 +25,25 @@ CKEditor 5 features cover several functional areas. Listed below are some o ### Formatting features -{@link features/basic-styles Basic text styles} include essentials like bold {@icon @ckeditor/ckeditor5-core/theme/icons/bold.svg Bold}, italics {@icon @ckeditor/ckeditor5-basic-styles/theme/icons/italic.svg Italic}, superscript {@icon @ckeditor/ckeditor5-basic-styles/theme/icons/superscript.svg Superscript}, and subscript {@icon @ckeditor/ckeditor5-basic-styles/theme/icons/subscript.svg Subscript} as well as inline code formatting and more. +{@link features/basic-styles Basic text styles} include essentials like bold {@icon @ckeditor/ckeditor5-icons/theme/icons/bold.svg Bold}, italics {@icon @ckeditor/ckeditor5-icons/theme/icons/italic.svg Italic}, superscript {@icon @ckeditor/ckeditor5-icons/theme/icons/superscript.svg Superscript}, and subscript {@icon @ckeditor/ckeditor5-icons/theme/icons/subscript.svg Subscript} as well as inline code formatting and more. -The {@link features/font font feature} provides support for using different font families {@icon @ckeditor/ckeditor5-font/theme/icons/font-family.svg Font Family}, controlling the font size {@icon @ckeditor/ckeditor5-font/theme/icons/font-size.svg Font Size} as well as font {@icon @ckeditor/ckeditor5-font/theme/icons/font-color.svg Font Color} and background colors {@icon @ckeditor/ckeditor5-font/theme/icons/font-background.svg Background Colors}. +The {@link features/font font feature} provides support for using different font families {@icon @ckeditor/ckeditor5-icons/theme/icons/font-family.svg Font Family}, controlling the font size {@icon @ckeditor/ckeditor5-icons/theme/icons/font-size.svg Font Size} as well as font {@icon @ckeditor/ckeditor5-icons/theme/icons/font-color.svg Font Color} and background colors {@icon @ckeditor/ckeditor5-icons/theme/icons/font-background.svg Background Colors}. -{@link features/headings Headings} {@icon @ckeditor/ckeditor5-core/theme/icons/heading1.svg Heading 1} (with configurable levels and styles) and the {@link features/text-alignment text alignment feature} {@icon @ckeditor/ckeditor5-core/theme/icons/align-left.svg Align Left} help organize the structure of the document. +{@link features/headings Headings} {@icon @ckeditor/ckeditor5-icons/theme/icons/heading1.svg Heading 1} (with configurable levels and styles) and the {@link features/text-alignment text alignment feature} {@icon @ckeditor/ckeditor5-icons/theme/icons/align-left.svg Align Left} help organize the structure of the document. -You can apply most of these formatting options from the {@link getting-started/setup/toolbar toolbar} or on the go, as you type, thanks to the {@link features/autoformat autoformatting feature} that employs Markdown syntax. You can remove them with the {@link features/remove-format remove format feature} {@icon @ckeditor/ckeditor5-remove-format/theme/icons/remove-format.svg Remove Format}. +You can apply most of these formatting options from the {@link getting-started/setup/toolbar toolbar} or on the go, as you type, thanks to the {@link features/autoformat autoformatting feature} that employs Markdown syntax. You can remove them with the {@link features/remove-format remove format feature} {@icon @ckeditor/ckeditor5-icons/theme/icons/remove-format.svg Remove Format}. {@img assets/img/features-basic-formatting.png 800 CKEditor 5 formatting features.} ### Advanced content editing -Rich text would not be rich without images. You can upload, caption, edit, or style them. You can even paste them straight from the URL with the help of the {@link features/images-overview image feature} {@icon @ckeditor/ckeditor5-core/theme/icons/image-upload.svg Image} and create a responsive design. If that is not enough, {@link features/media-embed embed media} {@icon @ckeditor/ckeditor5-media-embed/theme/icons/media.svg Media} into your content. +Rich text would not be rich without images. You can upload, caption, edit, or style them. You can even paste them straight from the URL with the help of the {@link features/images-overview image feature} {@icon @ckeditor/ckeditor5-icons/theme/icons/image-upload.svg Image} and create a responsive design. If that is not enough, {@link features/media-embed embed media} {@icon @ckeditor/ckeditor5-icons/theme/icons/media.svg Media} into your content. -{@link features/link Links} {@icon @ckeditor/ckeditor5-link/theme/icons/link.svg Link} are an essential feature for online content. You can paste, change, or attribute them. +{@link features/link Links} {@icon @ckeditor/ckeditor5-icons/theme/icons/link.svg Link} are an essential feature for online content. You can paste, change, or attribute them. -Provide clear and accessible data using {@link features/tables tables} {@icon @ckeditor/ckeditor5-core/theme/icons/table.svg Table} (you can even nest them to create advanced layouts), ordered {@icon @ckeditor/ckeditor5-core/theme/icons/numberedlist.svg Numbered List} and unordered {@link features/lists lists} {@icon @ckeditor/ckeditor5-core/theme/icons/bulletedlist.svg Bulleted List} with various markers to choose from, and {@link features/todo-lists to-do lists} {@icon @ckeditor/ckeditor5-core/theme/icons/todolist.svg To-do List}. Use {@link features/indent indents and outdents} {@icon @ckeditor/ckeditor5-core/theme/icons/indent.svg Indent} and {@link features/block-quote block quotes} {@icon @ckeditor/ckeditor5-core/theme/icons/quote.svg Quote} to structure the content and draw the reader's attention to it. +Provide clear and accessible data using {@link features/tables tables} {@icon @ckeditor/ckeditor5-icons/theme/icons/table.svg Table} (you can even nest them to create advanced layouts), ordered {@icon @ckeditor/ckeditor5-icons/theme/icons/numbered-list.svg Numbered List} and unordered {@link features/lists lists} {@icon @ckeditor/ckeditor5-icons/theme/icons/bulleted-list.svg Bulleted List} with various markers to choose from, and {@link features/todo-lists to-do lists} {@icon @ckeditor/ckeditor5-icons/theme/icons/todo-list.svg To-do List}. Use {@link features/indent indents and outdents} {@icon @ckeditor/ckeditor5-icons/theme/icons/indent.svg Indent} and {@link features/block-quote block quotes} {@icon @ckeditor/ckeditor5-icons/theme/icons/quote.svg Quote} to structure the content and draw the reader's attention to it. -Enrich your content further by {@link features/html-embed embedding HTML code} {@icon @ckeditor/ckeditor5-core/theme/icons/html.svg HTML} – this one is useful for webmasters. If you need to present code instead of employing it, use the {@link features/code-blocks code block} {@icon @ckeditor/ckeditor5-core/theme/icons/codeblock.svg Code Block} that lets you produce code listing with a syntax highlight, too! +Enrich your content further by {@link features/html-embed embedding HTML code} {@icon @ckeditor/ckeditor5-icons/theme/icons/html.svg HTML} – this one is useful for webmasters. If you need to present code instead of employing it, use the {@link features/code-blocks code block} {@icon @ckeditor/ckeditor5-icons/theme/icons/code-block.svg Code Block} that lets you produce code listing with a syntax highlight, too! {@img assets/img/features-images.png 800 CKEditor 5 image feature.} @@ -51,25 +51,25 @@ Enrich your content further by {@link features/html-embed embedding HTML code} { We created the {@link framework/index CKEditor 5 Framework} with {@link features/collaboration collaboration} in mind. -All collaboration features manage user data and permissions with the {@link features/users users API}. {@link features/track-changes Track changes} {@icon @ckeditor/ckeditor5-track-changes/theme/icons/track-changes.svg Track changes} allows the users to follow any changes made to the edited document both asynchronously and in real time. The users accept or reject these changes with a single click from a convenient side panel. +All collaboration features manage user data and permissions with the {@link features/users users API}. {@link features/track-changes Track changes} {@icon @ckeditor/ckeditor5-icons/theme/icons/track-changes.svg Track changes} allows the users to follow any changes made to the edited document both asynchronously and in real time. The users accept or reject these changes with a single click from a convenient side panel. -Where tracking changes is not enough, the {@link features/comments comments} {@icon @ckeditor/ckeditor5-comments/theme/icons/add-comment.svg Comments} come in, offering a perfect collaborative communication platform for writing and editing as a team. When you resolve a discussion, it moves to the comments archive. +Where tracking changes is not enough, the {@link features/comments comments} {@icon @ckeditor/ckeditor5-icons/theme/icons/add-comment.svg Comments} come in, offering a perfect collaborative communication platform for writing and editing as a team. When you resolve a discussion, it moves to the comments archive. -Additionally, CKEditor 5 offers the {@link features/restricted-editing restricted editing mode} {@icon @ckeditor/ckeditor5-restricted-editing/theme/icons/contentunlock.svg Enable editing} where just the selected parts of the content may be edited by some users, based on a permissions system. And when there is a need for even more control, there are the {@link features/read-only read-only} and {@link features/comments-only-mode comments-only} modes that let the user access the content, but not edit it. +Additionally, CKEditor 5 offers the {@link features/restricted-editing restricted editing mode} {@icon @ckeditor/ckeditor5-icons/theme/icons/content-unlock.svg Enable editing} where just the selected parts of the content may be edited by some users, based on a permissions system. And when there is a need for even more control, there are the {@link features/read-only read-only} and {@link features/comments-only-mode comments-only} modes that let the user access the content, but not edit it. {@img assets/img/features-collaboration.png 800 CKEditor 5 collaboration features.} -You can also track the progress and changes done in the content with the {@link features/revision-history revision history feature} {@icon @ckeditor/ckeditor5-core/theme/icons/history.svg Revision history}. This robust document versioning tool lets you create named versions, compare changes, and restore previous document versions. It tracks all progress – also when many editors work together. +You can also track the progress and changes done in the content with the {@link features/revision-history revision history feature} {@icon @ckeditor/ckeditor5-icons/theme/icons/history.svg Revision history}. This robust document versioning tool lets you create named versions, compare changes, and restore previous document versions. It tracks all progress – also when many editors work together. {@img assets/img/features-revision-history.png 800 CKEditor 5 document versioning feature.} ### Document conversion -If you need to share the document outside your team, use the {@link features/export-pdf export to PDF feature} {@icon @ckeditor/ckeditor5-export-pdf/theme/icons/exportpdf.svg Export to PDF} to produce industry-standard, portable, cross-platform files. +If you need to share the document outside your team, use the {@link features/export-pdf export to PDF feature} {@icon @ckeditor/ckeditor5-icons/theme/icons/export-pdf.svg Export to PDF} to produce industry-standard, portable, cross-platform files. -If you need to work further on the document, choose the {@link features/export-word export to Word feature} {@icon @ckeditor/ckeditor5-export-word/theme/icons/exportword.svg Export to Word} instead – and keep your comments and changes in the resulting document, ready to edit further. +If you need to work further on the document, choose the {@link features/export-word export to Word feature} {@icon @ckeditor/ckeditor5-icons/theme/icons/export-word.svg Export to Word} instead – and keep your comments and changes in the resulting document, ready to edit further. -The {@link features/pagination pagination feature} {@icon @ckeditor/ckeditor5-pagination/theme/icons/arrow-up.svg Previous page}{@icon @ckeditor/ckeditor5-pagination/theme/icons/arrow-down.svg Next page} complements the exports to ensure all produced documents will always look the way they should. +The {@link features/pagination pagination feature} {@icon @ckeditor/ckeditor5-icons/theme/icons/arrow-up.svg Previous page}{@icon @ckeditor/ckeditor5-icons/theme/icons/arrow-down.svg Next page} complements the exports to ensure all produced documents will always look the way they should. If you have any documents in the DOCX format, you can convert them into HTML with the {@link features/import-word import from Word feature} and then continue editing in CKEditor 5. @@ -81,7 +81,7 @@ The CKEditor 5 WYSIWYG editor by default produces HTML output that you can ### Other productivity features -The {@link features/ai-assistant-overview AI Assistant} {@icon ckeditor5-collaboration/theme/icons/robot-pencil.svg AI Assistant} will help you rewrite, edit, or translate the existing content to match your needs, or even come up with a completely new one! +The {@link features/ai-assistant-overview AI Assistant} {@icon @ckeditor/ckeditor5-icons/theme/icons/robot-pencil.svg AI Assistant} will help you rewrite, edit, or translate the existing content to match your needs, or even come up with a completely new one! The {@link features/word-count word and character counter} will help you track progress and control the volume of the content. diff --git a/docs/framework/architecture/ui-components.md b/docs/framework/architecture/ui-components.md index d689d48c119..24db58aed43 100644 --- a/docs/framework/architecture/ui-components.md +++ b/docs/framework/architecture/ui-components.md @@ -150,14 +150,14 @@ To get a button with an icon, import it first. Then set the `icon` property on t ```js -import { ButtonView, icons } from 'ckeditor5'; +import { ButtonView, IconCheck } from 'ckeditor5'; const saveButton = new ButtonView(); saveButton.set( { label: 'Save', withText: false, - icon: icons.check, + icon: IconCheck, class: 'ck-button-save' } ); saveButton.render(); @@ -385,10 +385,11 @@ You can use the {@link module:ui/dropdown/utils#addToolbarToDropdown `addToolbar ```js import { addToolbarToDropdown, - icons, ButtonView, createDropdown, - Locale + Locale, + IconBold, + IconItalic } from 'ckeditor5'; const locale = new Locale(); @@ -396,8 +397,8 @@ const locale = new Locale(); const bold = new ButtonView(); const italic = new ButtonView(); -bold.set( { label: 'Bold', withText: false, icon: icons.bold } ); -italic.set( { label: 'Italic', withText: false, icon: icons.italic } ); +bold.set( { label: 'Bold', withText: false, icon: IconBold } ); +italic.set( { label: 'Italic', withText: false, icon: IconItalic } ); const buttons = [ bold, italic ]; @@ -473,9 +474,10 @@ import { addToolbarToDropdown, ButtonView, createDropdown, - icons, SplitButtonViewm, - Locale + Locale, + IconBold, + IconItalic } from 'ckeditor5'; const locale = new Locale(); @@ -483,8 +485,8 @@ const locale = new Locale(); const bold = new ButtonView(); const italic = new ButtonView(); -bold.set( { label: 'Bold', withText: false, icon: icons.bold } ); -italic.set( { label: 'Italic', withText: false, icon: icons.italic } ); +bold.set( { label: 'Bold', withText: false, icon: IconBold } ); +italic.set( { label: 'Italic', withText: false, icon: IconItalic } ); const buttons = [ bold, italic ]; @@ -783,127 +785,18 @@ The CKEditor 5 library has a collection of icons representing different edi ```js -import { icons, IconView } from 'ckeditor5'; +import { IconView, IconBold } from 'ckeditor5'; const icon = new IconView(); -icon.content = icons.bold; +icon.content = IconBold; icon.render(); document.getElementById( 'icon-bold' ).append( icon.element ); ``` -CKEditor 5 features use different icons. You can find them in their respective packages. Here is a list of all available icons. - - -```js -import { icons } from 'ckeditor5'; - -console.log( icons.bold ); -console.log( icons.italic ); -console.log( icons.underline ); -console.log( icons.code ); -console.log( icons.strikethrough ); -console.log( icons.subscript ); -console.log( icons.superscript ); - -console.log( icons.browserFiles ); - -console.log( icons.codeBlock ); - -console.log( icons.cancel ); -console.log( icons.caption ); -console.log( icons.check ); -console.log( icons.cog ); -console.log( icons.eraser ); -console.log( icons.lowVision ); -console.log( icons.textAlternative ); -console.log( icons.image ); -console.log( icons.alignBottom ); -console.log( icons.alignMiddle ); -console.log( icons.alignTop ); -console.log( icons.alignLeft ); -console.log( icons.alignCenter ); -console.log( icons.alignRight ); -console.log( icons.alignJustify ); -console.log( icons.objectLeft ); -console.log( icons.objectCenter ); -console.log( icons.objectRight ); -console.log( icons.objectFullWidth ); -console.log( icons.objectInline ); -console.log( icons.objectBlockLeft ); -console.log( icons.objectBlockRight ); -console.log( icons.objectFullSize ); -console.log( icons.objectSizeLarge ); -console.log( icons.objectSizeSmall ); -console.log( icons.objectSizeMedium ); -console.log( icons.pencil ); -console.log( icons.pilcrow ); -console.log( icons.quote ); -console.log( icons.threeVerticalDots ); - -console.log( icons.fontFamily ); -console.log( icons.fontSize ); -console.log( icons.fontColor ); -console.log( icons.fontBackground ); - -console.log( icons.heading1 ); -console.log( icons.heading2 ); -console.log( icons.heading3 ); -console.log( icons.heading4 ); -console.log( icons.heading5 ); -console.log( icons.heading6 ); - -console.log( icons.indent ); -console.log( icons.outdent ); - -console.log( icons.marker ); -console.log( icons.pen ); - -console.log( icons.html ); - -console.log( icons.link ); -console.log( icons.unlink ); - -console.log( icons.bulletedList ); -console.log( icons.numberedList ); -console.log( icons.todoList ); - -console.log( icons.media ); - -console.log( icons.pageBreak ); - -console.log( icons.paragraph ); - -console.log( icons.removeFormat ); - -console.log( icons.contentLock ); -console.log( icons.contentUnlock ); - -console.log( icons.selectAll ); - -console.log( icons.sourceEditing ); - -console.log( icons.specialCharacters ); - -console.log( icons.table ); -console.log( icons.tableRow ); -console.log( icons.tableColumn ); -console.log( icons.tableMergeCell ); -console.log( icons.tableCellProperties ); -console.log( icons.tableProperties ); - -console.log( icons.nextArrow ); -console.log( icons.previousArrow ); - -console.log( icons.undo ); -console.log( icons.redo ); - -console.log( icons.history ); -console.log( icons.loupe ); -``` - +CKEditor 5 features use different icons. You can find them in the `@ckeditor/ckeditor5-icons` package. You can also {@link framework/architecture/ui-library#setting-label-icon-and-tooltip add a custom icon to the dropdown} by providing the entire XML string of the icon diff --git a/docs/framework/architecture/ui-library.md b/docs/framework/architecture/ui-library.md index 4d14d8f4ab1..e1bcd6bc545 100644 --- a/docs/framework/architecture/ui-library.md +++ b/docs/framework/architecture/ui-library.md @@ -569,12 +569,12 @@ By default, the "Close" button ("X") is added to the header as long as you provi ```js -import { icons } from 'ckeditor5'; +import { IconPencil } from 'ckeditor5'; // ... editor.plugins.get( 'Dialog' ).show( { - icon: icons.pencil, + icon: IconPencil, title: 'My first dialog', // Do not display the "Close" button. hasCloseButton: false, diff --git a/docs/framework/contributing/code-style.md b/docs/framework/contributing/code-style.md index e8b418cf2c1..1e9dc0e79ed 100644 --- a/docs/framework/contributing/code-style.md +++ b/docs/framework/contributing/code-style.md @@ -1086,7 +1086,7 @@ This rule ensures that all imports from the `@ckeditor/*` packages are done thro import Table from '@ckeditor/ckeditor5-table/src/table'; // Importing from the `/theme/` folder is not allowed. -import BoldIcon from '@ckeditor/ckeditor5-core/theme/icons/bold.svg'; +import BoldIcon from '@ckeditor/ckeditor5-icons/theme/icons/bold.svg'; ``` 👍  Examples of correct code for this rule: diff --git a/docs/framework/deep-dive/localization.md b/docs/framework/deep-dive/localization.md index 78712880d94..4983dbf259d 100644 --- a/docs/framework/deep-dive/localization.md +++ b/docs/framework/deep-dive/localization.md @@ -258,7 +258,7 @@ public getDefaultCommands() { { id: 'blockQuote', commandName: 'blockQuote', - icon: icons.quote, + icon: IconQuote, title: translateVariableKey( 'Block quote' ), description: t( 'Create a block quote' ) }, diff --git a/docs/getting-started/advanced/integrating-from-source-webpack.md b/docs/getting-started/advanced/integrating-from-source-webpack.md index 6f757353b3c..f52a450c782 100644 --- a/docs/getting-started/advanced/integrating-from-source-webpack.md +++ b/docs/getting-started/advanced/integrating-from-source-webpack.md @@ -93,7 +93,7 @@ module.exports = { module: { rules: [ { - test: /ckeditor5-[^/\\]+[/\\]theme[/\\]icons[/\\][^/\\]+\.svg$/, + test: /\.svg$/, use: [ 'raw-loader' ] }, { @@ -170,7 +170,7 @@ module.exports = { use: [ 'ts-loader' ] }, { - test: /ckeditor5-[^/\\]+[/\\]theme[/\\]icons[/\\][^/\\]+\.svg$/, + test: /\.svg$/, use: [ 'raw-loader' ] }, @@ -225,13 +225,13 @@ Encore. // Use raw-loader for CKEditor 5 SVG files. .addRule( { - test: /ckeditor5-[^/\\]+[/\\]theme[/\\]icons[/\\][^/\\]+\.svg$/, + test: /\.svg$/, loader: 'raw-loader' } ) // Configure other image loaders to exclude CKEditor 5 SVG files. .configureLoaderRule( 'images', loader => { - loader.exclude = /ckeditor5-[^/\\]+[/\\]theme[/\\]icons[/\\][^/\\]+\.svg$/; + loader.exclude = /\.svg$/; } ) // Configure PostCSS loader. @@ -586,7 +586,7 @@ module.exports = { module: { rules: [ { - test: /ckeditor5-[^/\\]+[/\\]theme[/\\]icons[/\\][^/\\]+\.svg$/, + test: /\.svg$/, use: [ 'raw-loader' ] }, { diff --git a/docs/getting-started/legacy-getting-started/integrations/react.md b/docs/getting-started/legacy-getting-started/integrations/react.md index 4334d51a2a7..637b3944bc7 100644 --- a/docs/getting-started/legacy-getting-started/integrations/react.md +++ b/docs/getting-started/legacy-getting-started/integrations/react.md @@ -450,7 +450,7 @@ Then, add two new elements to the exported object under the `module.rules` array ```js { - test: /ckeditor5-[^/\\]+[/\\]theme[/\\]icons[/\\][^/\\]+\.svg$/, + test: /ckeditor5-icons\/theme\/icons\/[^/\\]+\.svg$/, use: [ 'raw-loader' ] }, { @@ -522,7 +522,7 @@ Finally, exclude CKEditor 5 SVG and CSS files from `file-loader`. Find the /\.(js|mjs|jsx|ts|tsx)$/, /\.html$/, /\.json$/, - /ckeditor5-[^/\\]+[/\\]theme[/\\]icons[/\\][^/\\]+\.svg$/, + /\.svg$/, /ckeditor5-[^/\\]+[/\\]theme[/\\].+\.css$/ ], name: 'static/media/[name].[hash:8].[ext]', diff --git a/docs/getting-started/legacy-getting-started/integrations/vuejs-v2.md b/docs/getting-started/legacy-getting-started/integrations/vuejs-v2.md index 7c799b46500..3ef6f92776f 100644 --- a/docs/getting-started/legacy-getting-started/integrations/vuejs-v2.md +++ b/docs/getting-started/legacy-getting-started/integrations/vuejs-v2.md @@ -384,7 +384,7 @@ module.exports = { // * or add a new one: config.module .rule( 'cke-svg' ) - .test( /ckeditor5-[^/\\]+[/\\]theme[/\\]icons[/\\][^/\\]+\.svg$/ ) + .test( /\.svg$/ ) .use( 'raw-loader' ) .loader( 'raw-loader' ); diff --git a/docs/getting-started/legacy-getting-started/integrations/vuejs-v3.md b/docs/getting-started/legacy-getting-started/integrations/vuejs-v3.md index b89f8477eed..aeb7e63443c 100644 --- a/docs/getting-started/legacy-getting-started/integrations/vuejs-v3.md +++ b/docs/getting-started/legacy-getting-started/integrations/vuejs-v3.md @@ -402,7 +402,7 @@ module.exports = { // * or add a new one: config.module .rule( 'cke-svg' ) - .test( /ckeditor5-[^/\\]+[/\\]theme[/\\]icons[/\\][^/\\]+\.svg$/ ) + .test( /\.svg$/ ) .use( 'raw-loader' ) .loader( 'raw-loader' ); diff --git a/docs/getting-started/legacy-getting-started/quick-start-other.md b/docs/getting-started/legacy-getting-started/quick-start-other.md index 4881997243f..f27eb1647e0 100644 --- a/docs/getting-started/legacy-getting-started/quick-start-other.md +++ b/docs/getting-started/legacy-getting-started/quick-start-other.md @@ -240,7 +240,7 @@ module.exports = { module: { rules: [ { - test: /ckeditor5-[^/\\]+[/\\]theme[/\\]icons[/\\][^/\\]+\.svg$/, + test: /\.svg$/, use: [ 'raw-loader' ] }, diff --git a/docs/getting-started/licensing/license-and-legal.md b/docs/getting-started/licensing/license-and-legal.md index 63b179a1549..a8ed37ac083 100644 --- a/docs/getting-started/licensing/license-and-legal.md +++ b/docs/getting-started/licensing/license-and-legal.md @@ -15,7 +15,7 @@ CKEditor is dual-licensed. This means you can choose between an open-source and The open-source distribution of CKEditor 5 is licensed under the terms of GPL 2+. If you plan to use CKEditor 5 under this license, you can register your application using the [CKEditor 5 GPL 2+ license registration form](https://info.ckeditor.com/l/1018062/2024-08-22/39jtg). -If you are running an open-source project with an OSS license incompatible with GPL please [contact us](https://ckeditor.com/contact/) – we will be happy to support your project with a[CKEditor 5 open-source license that works for you](https://ckeditor.com/wysiwyg-editor-open-source/). +If you are running an open-source project with an OSS license incompatible with GPL please [contact us](https://ckeditor.com/contact/) – we will be happy to support your project with a [CKEditor 5 open-source license that works for you](https://ckeditor.com/wysiwyg-editor-open-source/). **Note:** the CKEditor 5 Free Plan is licensed under the GPL 2+ license. diff --git a/docs/getting-started/setup/toolbar.md b/docs/getting-started/setup/toolbar.md index 18fd0865d40..64ad27c4894 100644 --- a/docs/getting-started/setup/toolbar.md +++ b/docs/getting-started/setup/toolbar.md @@ -98,7 +98,7 @@ toolbar: { * **{@link module:core/editor/editorconfig~ToolbarConfig#shouldNotGroupWhenFull `shouldNotGroupWhenFull`}** – When set to `true`, the toolbar will stop grouping items and let them wrap to the next line when there is not enough space to display them in a single row. This setting is `false` by default, which enables item grouping. -The demo below presents the "regular" toolbar look with `shouldNotGroupWhenFull` set to `false`. If there are more toolbar items than can fit in the toolbar in the current display width, some items get hidden. You can access them by clicking the show more items button {@icon @ckeditor/ckeditor5-core/theme/icons/three-vertical-dots.svg Show more items}. +The demo below presents the "regular" toolbar look with `shouldNotGroupWhenFull` set to `false`. If there are more toolbar items than can fit in the toolbar in the current display width, some items get hidden. You can access them by clicking the show more items button {@icon @ckeditor/ckeditor5-icons/theme/icons/three-vertical-dots.svg Show more items}. {@snippet installation/setup/toolbar-grouping} @@ -183,7 +183,7 @@ toolbar: [ ] ``` -It will create a "Basic styles" dropdown with a three vertical dots icon {@icon @ckeditor/ckeditor5-core/theme/icons/three-vertical-dots.svg Three vertical dots} containing the additional basic text styles buttons set. You can test it in the demo below along with a few more toolbar dropdowns. +It will create a "Basic styles" dropdown with a three vertical dots icon {@icon @ckeditor/ckeditor5-icons/theme/icons/three-vertical-dots.svg Three vertical dots} containing the additional basic text styles buttons set. You can test it in the demo below along with a few more toolbar dropdowns. {@snippet installation/setup/toolbar-nested-simple} @@ -215,15 +215,15 @@ You can use one of the icons listed below for your dropdown: | Icon name | Preview | |-------------------|-----------------------------------------------------------------------------| -| `'threeVerticalDots'` **(default)** | {@icon @ckeditor/ckeditor5-core/theme/icons/three-vertical-dots.svg Three vertical dots} | -| `'alignLeft'` | {@icon @ckeditor/ckeditor5-core/theme/icons/align-left.svg Align left} | -| `'bold'` | {@icon @ckeditor/ckeditor5-core/theme/icons/bold.svg Bold} | -| `'importExport'` | {@icon @ckeditor/ckeditor5-core/theme/icons/importexport.svg Import export} | -| `'paragraph'` | {@icon @ckeditor/ckeditor5-core/theme/icons/paragraph.svg Paragraph} | -| `'text'` | {@icon @ckeditor/ckeditor5-core/theme/icons/text.svg Text} | -| `'plus'` | {@icon @ckeditor/ckeditor5-core/theme/icons/plus.svg Plus} | -| `'dragIndicator'` | {@icon @ckeditor/ckeditor5-core/theme/icons/drag-indicator.svg Drag indicator} | -| `'pilcrow'` | {@icon @ckeditor/ckeditor5-core/theme/icons/pilcrow.svg Pilcrow} | +| `'threeVerticalDots'` **(default)** | {@icon @ckeditor/ckeditor5-icons/theme/icons/three-vertical-dots.svg Three vertical dots} | +| `'alignLeft'` | {@icon @ckeditor/ckeditor5-icons/theme/icons/align-left.svg Align left} | +| `'bold'` | {@icon @ckeditor/ckeditor5-icons/theme/icons/bold.svg Bold} | +| `'importExport'` | {@icon @ckeditor/ckeditor5-icons/theme/icons/import-export.svg Import export} | +| `'paragraph'` | {@icon @ckeditor/ckeditor5-icons/theme/icons/paragraph.svg Paragraph} | +| `'text'` | {@icon @ckeditor/ckeditor5-icons/theme/icons/text.svg Text} | +| `'plus'` | {@icon @ckeditor/ckeditor5-icons/theme/icons/plus.svg Plus} | +| `'dragIndicator'` | {@icon @ckeditor/ckeditor5-icons/theme/icons/drag-indicator.svg Drag indicator} | +| `'pilcrow'` | {@icon @ckeditor/ckeditor5-icons/theme/icons/pilcrow.svg Pilcrow} | * The default icons are loaded from the `ckeditor5-core` package. * If no icon is specified, `'threeVerticalDots'` will be used as a default. @@ -333,7 +333,7 @@ The block toolbar provides an additional configurable toolbar on the left-hand s ### Demo - In the editor below, move the caret around the content. You will see that the block toolbar button {@icon @ckeditor/ckeditor5-core/theme/icons/drag-indicator.svg drag indicator} is following your selection. Click the button to show the toolbar. + In the editor below, move the caret around the content. You will see that the block toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/drag-indicator.svg drag indicator} is following your selection. Click the button to show the toolbar. {@snippet installation/setup/blocktoolbar} @@ -344,9 +344,9 @@ The block toolbar provides an additional configurable toolbar on the left-hand s ### Additional feature information -To access the block toolbar, you need to click the button with braille pattern dots icon {@icon @ckeditor/ckeditor5-core/theme/icons/drag-indicator.svg drag indicator} on the left-hand side of the content area (the gutter). The button appears next to the selected block element (for example, a paragraph), following the caret as the user edits the content and navigates the document. +To access the block toolbar, you need to click the button with braille pattern dots icon {@icon @ckeditor/ckeditor5-icons/theme/icons/drag-indicator.svg drag indicator} on the left-hand side of the content area (the gutter). The button appears next to the selected block element (for example, a paragraph), following the caret as the user edits the content and navigates the document. -The icon {@icon @ckeditor/ckeditor5-core/theme/icons/drag-indicator.svg drag indicator} is also a handle to drag blocks of content around the editor. Click a heading in the demo above and drag it all the way down between the following paragraphs to see this functionality in action. +The icon {@icon @ckeditor/ckeditor5-icons/theme/icons/drag-indicator.svg drag indicator} is also a handle to drag blocks of content around the editor. Click a heading in the demo above and drag it all the way down between the following paragraphs to see this functionality in action. The block toolbar complements the [balloon editor type](https://ckeditor.com/ckeditor-5/builder/?redirect=docs) where it falls short, for example when you must insert some content (like an image), but the selection is collapsed, so you cannot access the toolbar. It can, however, be added to any type of editor and configure accordingly (see below). @@ -418,7 +418,7 @@ If you plan to run the editor in a right–to–left (RTL) language, keep in min You can use the `shouldNotGroupWhenFull` [configuration option](#multiline-wrapping-toolbar) to prevent {@link module:core/editor/editorconfig~EditorConfig#toolbar automatic items grouping} in the block toolbar. -You can also change the current default toolbar icon `'dragIndicator'` {@icon @ckeditor/ckeditor5-core/theme/icons/drag-indicator.svg Drag indicator} by choosing predefined icon from [icon list](#changing-the-icon) using the `icon` option or by passing a `SVG` string: +You can also change the current default toolbar icon `'dragIndicator'` {@icon @ckeditor/ckeditor5-icons/theme/icons/drag-indicator.svg Drag indicator} by choosing predefined icon from [icon list](#changing-the-icon) using the `icon` option or by passing a `SVG` string: ```js blockToolbar: { diff --git a/docs/tutorials/abbreviation-plugin-tutorial/abbreviation-plugin-level-2.md b/docs/tutorials/abbreviation-plugin-tutorial/abbreviation-plugin-level-2.md index 518c94dac7e..30cc89fae9f 100644 --- a/docs/tutorials/abbreviation-plugin-tutorial/abbreviation-plugin-level-2.md +++ b/docs/tutorials/abbreviation-plugin-tutorial/abbreviation-plugin-level-2.md @@ -112,7 +112,8 @@ import { LabeledFieldView, createLabeledInputText, ButtonView, // ADDED - icons // ADDED + IconCheck, // ADDED + IconCancel // ADDED } from 'ckeditor5'; export default class FormView extends View { @@ -122,14 +123,14 @@ export default class FormView extends View { // Create the save and cancel buttons. this.saveButtonView = this._createButton( - 'Save', icons.check, 'ck-button-save' + 'Save', IconCheck, 'ck-button-save' ); // Set the type to 'submit', which will trigger // the submit event on entire form when clicked. this.saveButtonView.type = 'submit'; this.cancelButtonView = this._createButton( - 'Cancel', icons.cancel, 'ck-button-cancel' + 'Cancel', IconCancel, 'ck-button-cancel' ); // Previously set template. @@ -176,11 +177,11 @@ export default class FormView extends View { // ... this.saveButtonView = this._createButton( - 'Save', icons.check, 'ck-button-save' + 'Save', IconCheck, 'ck-button-save' ); this.saveButtonView.type = 'submit'; this.cancelButtonView = this._createButton( - 'Cancel', icons.cancel, 'ck-button-cancel' + 'Cancel', IconCancel, 'ck-button-cancel' ); // Delegate ButtonView#execute to FormView#cancel. this.cancelButtonView.delegate( 'execute' ).to( this, 'cancel' ); diff --git a/docs/tutorials/supporting-multiple-versions.md b/docs/tutorials/supporting-multiple-versions.md index 8424f4af451..f2c17fe0c7f 100644 --- a/docs/tutorials/supporting-multiple-versions.md +++ b/docs/tutorials/supporting-multiple-versions.md @@ -74,7 +74,7 @@ If you want to support legacy versions of CKEditor 5, you cannot import fro import Table from '@ckeditor/ckeditor5-table/src/table'; // ❌ - import TableRowIcon from '@ckeditor/ckeditor5-table/theme/icons/table-row.svg'; + import TableRowIcon from '@ckeditor/ckeditor5-icons/theme/icons/table-row.svg'; ``` During the build process, these imports will be used as-is when generating the bundles for the legacy versions of CKEditor 5, but will be replaced with `ckeditor5` and `ckeditor5-premium-features` in the bundles for the latest version. diff --git a/docs/updating/nim-migration/custom-plugins.md b/docs/updating/nim-migration/custom-plugins.md index ef27b339a2a..33deddfb089 100644 --- a/docs/updating/nim-migration/custom-plugins.md +++ b/docs/updating/nim-migration/custom-plugins.md @@ -98,14 +98,14 @@ The same rule applies to the `theme` folder in the `@ckeditor/ckeditor5-*` packa ```js // ❌ -import undo from '@ckeditor/ckeditor5-core/theme/icons/undo.svg'; +import undo from '@ckeditor/ckeditor5-icons/theme/undo.svg'; console.log( undo ); // ✅ -import { icons } from '@ckeditor/ckeditor5-core'; +import { IconUndo } from '@ckeditor/ckeditor5-icons'; -console.log( icons.undo ); +console.log( IconUndo ); ``` If you run the following command, the `ckeditor5-rules/allow-imports-only-from-main-package-entry-point` eslint rule will list all the places where you need to update the imports. diff --git a/docs/updating/nim-migration/migration-to-new-installation-methods.md b/docs/updating/nim-migration/migration-to-new-installation-methods.md index 17877286c89..1c17c5f97de 100644 --- a/docs/updating/nim-migration/migration-to-new-installation-methods.md +++ b/docs/updating/nim-migration/migration-to-new-installation-methods.md @@ -39,7 +39,7 @@ module.exports = { module: { rules: [ { - test: /ckeditor5-[^/\\]+[/\\]theme[/\\]icons[/\\][^/\\]+\.svg$/, + test: /\.svg$/, use: [ 'raw-loader' ] }, { @@ -313,17 +313,25 @@ With the release of version 42.0.0, we have decided to deprecate the older metho However, we understand that migrating to a new setup, even if easy, requires planning and work allocation. We would rather not block anyone from receiving bug fixes and improvements due to a deprecated update path. Therefore, we will support all existing methods according to the timelines given below. -### Deprecation of the predefined builds and custom builds +### Deprecation of the predefined builds -The setup methods, which were “webpack-first” or provided predefined editors without the possibility of extending them will be supported until **the end of Q1 (March), 2025**. +Our provided predefined editor builds, such as `ckeditor5-build-classic`, will be supported until **the end of Q1 (March), 2025**. What we will sunset on this date: -1. The documentation for the predefined builds, superbuild, and custom builds will be removed. +1. The documentation for the predefined builds and superbuild will be removed. 2. No more new versions of predefined builds packages will be published to npm. +5. We will update our environment to target ES2022 (or newer), thus dropping the support for webpack 4. + +### Deprecation of the custom builds + +The setup method which was “webpack-first”, in which you imported from specific packages from `src` folder, will be supported until **the end of 2025**. + +What we will sunset on this date: + +1. The documentation for the custom builds will be removed. 3. New versions of npm packages published after this date will not have the `src` directory. It will not be possible to import files from those destinations, as `dist` will become the main folder. 4. Deprecation of `@ckeditor/ckeditor5-dev-translations` package, as it will not be needed anymore. -5. We will update our environment to target ES2022 (or newer), thus dropping the support for webpack 4. ### Deprecation of DLLs @@ -337,7 +345,9 @@ What we will sunset on this date: 2. New versions of npm packages published after this date will not have `build` directory. It will not be possible to import files from those destinations. - If any of the above worries you, reach out to our support or inform us via the [GitHub issue tracker](https://github.com/ckeditor/ckeditor5/issues/new?assignees=&labels=type:question&projects=&template=8-question.md&title=). We are open to discussing the timelines or potential cases that you would need us to support. + We have an [active GitHub issue](https://github.com/ckeditor/ckeditor5/issues/17779) which goes into details, and also documents improvements we planned for new installation methods. + + If any of the above worries you, comment on the above issue or reach out to our support. We are open to discussing the timelines or potential cases that you would need us to support. diff --git a/docs/updating/update-to-40.md b/docs/updating/update-to-40.md index f4ca070fc8f..7e8d4b0e99b 100644 --- a/docs/updating/update-to-40.md +++ b/docs/updating/update-to-40.md @@ -84,7 +84,7 @@ ClassicEditor ### CKBox image editing -The new release includes the {@link features/ckbox CKBox} image editing feature. You can access this feature either through a main toolbar button or the image contextual toolbar button {@icon @ckeditor/ckeditor5-ckbox/theme/icons/ckbox-image-edit.svg Image upload}. It lets users perform quick image edits such as cropping, resizing, flipping, and rotating the image. Image editing is called from within the editor and the process takes place right in the asset manager. This speeds up and simplifies the content editing process. +The new release includes the {@link features/ckbox CKBox} image editing feature. You can access this feature either through a main toolbar button or the image contextual toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/ckbox-image-edit.svg Image upload}. It lets users perform quick image edits such as cropping, resizing, flipping, and rotating the image. Image editing is called from within the editor and the process takes place right in the asset manager. This speeds up and simplifies the content editing process. {@img assets/img/ckbox-editing-area.png 1062 CKBox image editing panel.} @@ -127,7 +127,7 @@ You can read more about image editing in the {@link @ckbox features/images/editi ### Expanded image insert dropdown -We have updated the toolbar `insertImage` component. By default, the image toolbar dropdown {@icon @ckeditor/ckeditor5-core/theme/icons/image.svg Image} provides access to all installed methods of inserting images into content: +We have updated the toolbar `insertImage` component. By default, the image toolbar dropdown {@icon @ckeditor/ckeditor5-icons/theme/icons/image.svg Image} provides access to all installed methods of inserting images into content: * {@link features/image-upload Uploading images from your computer}. * Adding images from {@link features/using-file-managers file managers}. @@ -190,14 +190,14 @@ Additional image inserting plugins: #### New image upload icons -Due to the changes to the image insert mechanisms, we introduced new toolbar icons and replaced the old {@icon @ckeditor/ckeditor5-core/theme/icons/image.svg Image} image icon. +Due to the changes to the image insert mechanisms, we introduced new toolbar icons and replaced the old {@icon @ckeditor/ckeditor5-icons/theme/icons/image.svg Image} image icon. Now there are: -* {@icon @ckeditor/ckeditor5-core/theme/icons/image-upload.svg Image upload} image upload icon that is the default for the dropdown or the upload from computer command. -* {@icon @ckeditor/ckeditor5-core/theme/icons/image-asset-manager.svg Image manager} image manager icon. -* {@icon @ckeditor/ckeditor5-core/theme/icons/image-url.svg Insert via URL} insert via URL icon. +* {@icon @ckeditor/ckeditor5-icons/theme/icons/image-upload.svg Image upload} image upload icon that is the default for the dropdown or the upload from computer command. +* {@icon @ckeditor/ckeditor5-icons/theme/icons/image-asset-manager.svg Image manager} image manager icon. +* {@icon @ckeditor/ckeditor5-icons/theme/icons/image-url.svg Insert via URL} insert via URL icon. -The toolbar dropdown will use the {@icon @ckeditor/ckeditor5-core/theme/icons/image-upload.svg Image upload} image upload icon by default. If no upload adapter is present, the toolbar will use the next available icon instead. +The toolbar dropdown will use the {@icon @ckeditor/ckeditor5-icons/theme/icons/image-upload.svg Image upload} image upload icon by default. If no upload adapter is present, the toolbar will use the next available icon instead. ### Removal of the `insertImageViaUrl` option @@ -244,7 +244,7 @@ If you omit the `type` setting in the configuration, the behavior defaults to in ### Updated image text alternative icon -The {@link features/images-text-alternative image text alternative} (the `alt` attribute) helps screen reader users navigate and understand the document. We have updated the toolbar icon {@icon @ckeditor/ckeditor5-core/theme/icons/text-alternative.svg Alternative text} to be more intuitive and easier to recognize, following global standards. +The {@link features/images-text-alternative image text alternative} (the `alt` attribute) helps screen reader users navigate and understand the document. We have updated the toolbar icon {@icon @ckeditor/ckeditor5-icons/theme/icons/text-alternative.svg Alternative text} to be more intuitive and easier to recognize, following global standards. ## Update to CKEditor 5 v40.0.0 diff --git a/package.json b/package.json index dbc31247586..70a0d0615aa 100644 --- a/package.json +++ b/package.json @@ -50,7 +50,7 @@ "@ckeditor/ckeditor5-horizontal-line": "44.1.0", "@ckeditor/ckeditor5-html-embed": "44.1.0", "@ckeditor/ckeditor5-html-support": "44.1.0", - "@ckeditor/ckeditor5-icons": "44.1.0", + "@ckeditor/ckeditor5-icons": "0.0.1", "@ckeditor/ckeditor5-image": "44.1.0", "@ckeditor/ckeditor5-indent": "44.1.0", "@ckeditor/ckeditor5-language": "44.1.0", @@ -92,17 +92,17 @@ "@ckeditor/ckeditor5-build-multi-root": "44.1.0", "@ckeditor/ckeditor5-case-change": "44.1.0", "@ckeditor/ckeditor5-comments": "44.1.0", - "@ckeditor/ckeditor5-dev-build-tools": "^45.0.0", - "@ckeditor/ckeditor5-dev-bump-year": "^45.0.0", - "@ckeditor/ckeditor5-dev-ci": "^45.0.0", - "@ckeditor/ckeditor5-dev-dependency-checker": "^45.0.0", - "@ckeditor/ckeditor5-dev-docs": "^45.0.0", - "@ckeditor/ckeditor5-dev-release-tools": "^45.0.0", - "@ckeditor/ckeditor5-dev-stale-bot": "^45.0.0", - "@ckeditor/ckeditor5-dev-tests": "^45.0.0", - "@ckeditor/ckeditor5-dev-translations": "^45.0.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", - "@ckeditor/ckeditor5-dev-web-crawler": "^45.0.0", + "@ckeditor/ckeditor5-dev-build-tools": "^46.0.0", + "@ckeditor/ckeditor5-dev-bump-year": "^46.0.0", + "@ckeditor/ckeditor5-dev-ci": "^46.0.0", + "@ckeditor/ckeditor5-dev-dependency-checker": "^46.0.0", + "@ckeditor/ckeditor5-dev-docs": "^46.0.0", + "@ckeditor/ckeditor5-dev-release-tools": "^46.0.0", + "@ckeditor/ckeditor5-dev-stale-bot": "^46.0.0", + "@ckeditor/ckeditor5-dev-tests": "^46.0.0", + "@ckeditor/ckeditor5-dev-translations": "^46.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", + "@ckeditor/ckeditor5-dev-web-crawler": "^46.0.0", "@ckeditor/ckeditor5-document-outline": "44.1.0", "@ckeditor/ckeditor5-export-pdf": "44.1.0", "@ckeditor/ckeditor5-export-word": "44.1.0", @@ -133,7 +133,7 @@ "coveralls": "^3.1.0", "date-fns": "2.30.0", "eslint": "^8.21.0", - "eslint-config-ckeditor5": "^8.0.0", + "eslint-config-ckeditor5": "^9.0.0", "eslint-formatter-stylish": "^8.40.0", "estree-walker": "^3.0.3", "fs-extra": "^11.0.0", diff --git a/packages/ckeditor5-adapter-ckfinder/package.json b/packages/ckeditor5-adapter-ckfinder/package.json index 64837e2378e..6075145f400 100644 --- a/packages/ckeditor5-adapter-ckfinder/package.json +++ b/packages/ckeditor5-adapter-ckfinder/package.json @@ -20,7 +20,7 @@ "devDependencies": { "@ckeditor/ckeditor5-basic-styles": "44.1.0", "@ckeditor/ckeditor5-clipboard": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-enter": "44.1.0", "@ckeditor/ckeditor5-heading": "44.1.0", diff --git a/packages/ckeditor5-adapter-ckfinder/tsconfig.dist.json b/packages/ckeditor5-adapter-ckfinder/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-adapter-ckfinder/tsconfig.dist.json +++ b/packages/ckeditor5-adapter-ckfinder/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-adapter-ckfinder/tsconfig.json b/packages/ckeditor5-adapter-ckfinder/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-adapter-ckfinder/tsconfig.json +++ b/packages/ckeditor5-adapter-ckfinder/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-alignment/ckeditor5-metadata.json b/packages/ckeditor5-alignment/ckeditor5-metadata.json index e9e8ee67a90..875808dd1db 100644 --- a/packages/ckeditor5-alignment/ckeditor5-metadata.json +++ b/packages/ckeditor5-alignment/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "SplitButton", "name": "alignment", - "iconPath": "@ckeditor/ckeditor5-icons/theme/align-left.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/align-left.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-alignment/docs/features/text-alignment.md b/packages/ckeditor5-alignment/docs/features/text-alignment.md index 77fcb9fe518..1a74fa7ac65 100644 --- a/packages/ckeditor5-alignment/docs/features/text-alignment.md +++ b/packages/ckeditor5-alignment/docs/features/text-alignment.md @@ -10,7 +10,7 @@ The alignment feature lets you align your content to the left or right as well a ## Demo -Click inside a paragraph or a header and use the toolbar dropdown {@icon @ckeditor/ckeditor5-core/theme/icons/align-right.svg Text alignment} to change the alignment of the element. +Click inside a paragraph or a header and use the toolbar dropdown {@icon @ckeditor/ckeditor5-icons/theme/icons/align-right.svg Text alignment} to change the alignment of the element. {@snippet features/text-alignment} diff --git a/packages/ckeditor5-alignment/package.json b/packages/ckeditor5-alignment/package.json index 4ba9e6680bd..780587995bf 100644 --- a/packages/ckeditor5-alignment/package.json +++ b/packages/ckeditor5-alignment/package.json @@ -14,13 +14,14 @@ "main": "src/index.ts", "dependencies": { "@ckeditor/ckeditor5-core": "44.1.0", + "@ckeditor/ckeditor5-icons": "0.0.1", "@ckeditor/ckeditor5-ui": "44.1.0", "@ckeditor/ckeditor5-utils": "44.1.0", "ckeditor5": "44.1.0" }, "devDependencies": { "@ckeditor/ckeditor5-block-quote": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-engine": "44.1.0", "@ckeditor/ckeditor5-enter": "44.1.0", diff --git a/packages/ckeditor5-alignment/src/alignmentui.ts b/packages/ckeditor5-alignment/src/alignmentui.ts index e1a0f900550..cb21b86f3d1 100644 --- a/packages/ckeditor5-alignment/src/alignmentui.ts +++ b/packages/ckeditor5-alignment/src/alignmentui.ts @@ -7,7 +7,7 @@ * @module alignment/alignmentui */ -import { Plugin, icons } from 'ckeditor5/src/core.js'; +import { Plugin } from 'ckeditor5/src/core.js'; import { type Button, ButtonView, @@ -18,6 +18,7 @@ import { MenuBarMenuView, MenuBarMenuListView } from 'ckeditor5/src/ui.js'; +import { IconAlignCenter, IconAlignJustify, IconAlignLeft, IconAlignRight } from 'ckeditor5/src/icons.js'; import type { Locale } from 'ckeditor5/src/utils.js'; import { isSupported, normalizeAlignmentOptions } from './utils.js'; @@ -25,10 +26,10 @@ import type { AlignmentFormat, SupportedOption } from './alignmentconfig.js'; import type AlignmentCommand from './alignmentcommand.js'; const iconsMap = /* #__PURE__ */ ( () => new Map( [ - [ 'left', icons.alignLeft ], - [ 'right', icons.alignRight ], - [ 'center', icons.alignCenter ], - [ 'justify', icons.alignJustify ] + [ 'left', IconAlignLeft ], + [ 'right', IconAlignRight ], + [ 'center', IconAlignCenter ], + [ 'justify', IconAlignJustify ] ] ) )(); /** diff --git a/packages/ckeditor5-alignment/tsconfig.dist.json b/packages/ckeditor5-alignment/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-alignment/tsconfig.dist.json +++ b/packages/ckeditor5-alignment/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-alignment/tsconfig.json b/packages/ckeditor5-alignment/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-alignment/tsconfig.json +++ b/packages/ckeditor5-alignment/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-autoformat/package.json b/packages/ckeditor5-autoformat/package.json index f1dc2f43f10..b121ffdab91 100644 --- a/packages/ckeditor5-autoformat/package.json +++ b/packages/ckeditor5-autoformat/package.json @@ -15,6 +15,7 @@ "dependencies": { "@ckeditor/ckeditor5-core": "44.1.0", "@ckeditor/ckeditor5-engine": "44.1.0", + "@ckeditor/ckeditor5-heading": "44.1.0", "@ckeditor/ckeditor5-typing": "44.1.0", "@ckeditor/ckeditor5-utils": "44.1.0", "ckeditor5": "44.1.0" @@ -23,10 +24,9 @@ "@ckeditor/ckeditor5-basic-styles": "44.1.0", "@ckeditor/ckeditor5-block-quote": "44.1.0", "@ckeditor/ckeditor5-code-block": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-enter": "44.1.0", - "@ckeditor/ckeditor5-heading": "44.1.0", "@ckeditor/ckeditor5-horizontal-line": "44.1.0", "@ckeditor/ckeditor5-list": "44.1.0", "@ckeditor/ckeditor5-paragraph": "44.1.0", diff --git a/packages/ckeditor5-autoformat/tsconfig.dist.json b/packages/ckeditor5-autoformat/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-autoformat/tsconfig.dist.json +++ b/packages/ckeditor5-autoformat/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-autoformat/tsconfig.json b/packages/ckeditor5-autoformat/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-autoformat/tsconfig.json +++ b/packages/ckeditor5-autoformat/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-autosave/package.json b/packages/ckeditor5-autosave/package.json index 76efb8d7e6a..71c7f706f76 100644 --- a/packages/ckeditor5-autosave/package.json +++ b/packages/ckeditor5-autosave/package.json @@ -19,7 +19,7 @@ "lodash-es": "4.17.21" }, "devDependencies": { - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-paragraph": "44.1.0", "@ckeditor/ckeditor5-source-editing": "44.1.0", diff --git a/packages/ckeditor5-autosave/tsconfig.dist.json b/packages/ckeditor5-autosave/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-autosave/tsconfig.dist.json +++ b/packages/ckeditor5-autosave/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-autosave/tsconfig.json b/packages/ckeditor5-autosave/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-autosave/tsconfig.json +++ b/packages/ckeditor5-autosave/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-basic-styles/ckeditor5-metadata.json b/packages/ckeditor5-basic-styles/ckeditor5-metadata.json index 64b8da97d9b..f6273bee5b3 100644 --- a/packages/ckeditor5-basic-styles/ckeditor5-metadata.json +++ b/packages/ckeditor5-basic-styles/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "bold", - "iconPath": "@ckeditor/ckeditor5-icons/theme/bold.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/bold.svg" } ], "htmlOutput": [ @@ -29,7 +29,7 @@ { "type": "Button", "name": "code", - "iconPath": "@ckeditor/ckeditor5-icons/theme/code.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/code.svg" } ], "htmlOutput": [ @@ -48,7 +48,7 @@ { "type": "Button", "name": "italic", - "iconPath": "@ckeditor/ckeditor5-icons/theme/italic.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/italic.svg" } ], "htmlOutput": [ @@ -67,7 +67,7 @@ { "type": "Button", "name": "strikethrough", - "iconPath": "@ckeditor/ckeditor5-icons/theme/strikethrough.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/strikethrough.svg" } ], "htmlOutput": [ @@ -86,7 +86,7 @@ { "type": "Button", "name": "subscript", - "iconPath": "@ckeditor/ckeditor5-icons/theme/subscript.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/subscript.svg" } ], "htmlOutput": [ @@ -105,7 +105,7 @@ { "type": "Button", "name": "superscript", - "iconPath": "@ckeditor/ckeditor5-icons/theme/superscript.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/superscript.svg" } ], "htmlOutput": [ @@ -124,7 +124,7 @@ { "type": "Button", "name": "underline", - "iconPath": "@ckeditor/ckeditor5-icons/theme/underline.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/underline.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-basic-styles/docs/features/basic-styles.md b/packages/ckeditor5-basic-styles/docs/features/basic-styles.md index e9658c4423b..363e4367de2 100644 --- a/packages/ckeditor5-basic-styles/docs/features/basic-styles.md +++ b/packages/ckeditor5-basic-styles/docs/features/basic-styles.md @@ -12,10 +12,10 @@ The basic styles feature lets you apply the most essential formatting such as bo You may apply basic formatting options with toolbar buttons. You can also make use of the {@link features/autoformat autoformatting feature} that changes Markdown code to formatted text as you type. Use one of these to format text: -* Bold – Use the bold toolbar button {@icon @ckeditor/ckeditor5-core/theme/icons/bold.svg Bold} or type `**text**` or `__text__`. -* Italic – Use the italic toolbar button {@icon @ckeditor/ckeditor5-basic-styles/theme/icons/italic.svg Italic} or type `*text*` or `_text_`. -* Code – Use the code toolbar button {@icon @ckeditor/ckeditor5-basic-styles/theme/icons/code.svg Code} or type ``` `text` ```. -* Strikethrough – Use the strikethrough toolbar button {@icon @ckeditor/ckeditor5-basic-styles/theme/icons/strikethrough.svg Strikethrough} or type `~~text~~`. +* Bold – Use the bold toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/bold.svg Bold} or type `**text**` or `__text__`. +* Italic – Use the italic toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/italic.svg Italic} or type `*text*` or `_text_`. +* Code – Use the code toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/code.svg Code} or type ``` `text` ```. +* Strikethrough – Use the strikethrough toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/strikethrough.svg Strikethrough} or type `~~text~~`. {@snippet features/basic-styles} diff --git a/packages/ckeditor5-basic-styles/package.json b/packages/ckeditor5-basic-styles/package.json index e509f6ea070..f6cf2aaaed6 100644 --- a/packages/ckeditor5-basic-styles/package.json +++ b/packages/ckeditor5-basic-styles/package.json @@ -14,18 +14,19 @@ "main": "src/index.ts", "dependencies": { "@ckeditor/ckeditor5-core": "44.1.0", + "@ckeditor/ckeditor5-icons": "0.0.1", "@ckeditor/ckeditor5-typing": "44.1.0", "@ckeditor/ckeditor5-ui": "44.1.0", + "@ckeditor/ckeditor5-utils": "44.1.0", "ckeditor5": "44.1.0" }, "devDependencies": { - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-engine": "44.1.0", "@ckeditor/ckeditor5-essentials": "44.1.0", "@ckeditor/ckeditor5-paragraph": "44.1.0", "@ckeditor/ckeditor5-theme-lark": "44.1.0", - "@ckeditor/ckeditor5-utils": "44.1.0", "typescript": "5.0.4", "webpack": "^5.94.0", "webpack-cli": "^5.1.4" diff --git a/packages/ckeditor5-basic-styles/src/bold/boldui.ts b/packages/ckeditor5-basic-styles/src/bold/boldui.ts index d15e9d92809..ad1ab3bb31f 100644 --- a/packages/ckeditor5-basic-styles/src/bold/boldui.ts +++ b/packages/ckeditor5-basic-styles/src/bold/boldui.ts @@ -7,7 +7,8 @@ * @module basic-styles/bold/boldui */ -import { Plugin, icons } from 'ckeditor5/src/core.js'; +import { Plugin } from 'ckeditor5/src/core.js'; +import { IconBold } from 'ckeditor5/src/icons.js'; import { ButtonView, MenuBarMenuListItemButtonView } from 'ckeditor5/src/ui.js'; import { getButtonCreator } from '../utils.js'; @@ -41,7 +42,7 @@ export default class BoldUI extends Plugin { editor, commandName: BOLD, plugin: this, - icon: icons.bold, + icon: IconBold, label: t( 'Bold' ), keystroke: 'CTRL+B' } ); diff --git a/packages/ckeditor5-basic-styles/src/code/codeediting.ts b/packages/ckeditor5-basic-styles/src/code/codeediting.ts index f2c926b20bf..d8c8e275538 100644 --- a/packages/ckeditor5-basic-styles/src/code/codeediting.ts +++ b/packages/ckeditor5-basic-styles/src/code/codeediting.ts @@ -59,12 +59,7 @@ export default class CodeEditing extends Plugin { editor.conversion.attributeToElement( { model: CODE, - view: 'code', - upcastAlso: { - styles: { - 'word-wrap': 'break-word' - } - } + view: 'code' } ); // Create code command. diff --git a/packages/ckeditor5-basic-styles/tests/code/codeediting.js b/packages/ckeditor5-basic-styles/tests/code/codeediting.js index d8b58cac0a6..00825156a6d 100644 --- a/packages/ckeditor5-basic-styles/tests/code/codeediting.js +++ b/packages/ckeditor5-basic-styles/tests/code/codeediting.js @@ -95,13 +95,14 @@ describe( 'CodeEditing', () => { expect( editor.getData() ).to.equal( '

foobar

' ); } ); - it( 'should convert word-wrap:break-word to code attribute', () => { + // See: https://github.com/ckeditor/ckeditor5/issues/17789 + it( 'should not convert word-wrap:break-word to code attribute', () => { editor.setData( '

foobar

' ); expect( getModelData( model, { withoutSelection: true } ) ) - .to.equal( '<$text code="true">foobar' ); + .to.equal( 'foobar' ); - expect( editor.getData() ).to.equal( '

foobar

' ); + expect( editor.getData() ).to.equal( '

foobar

' ); } ); it( 'should be integrated with autoparagraphing', () => { diff --git a/packages/ckeditor5-basic-styles/tsconfig.dist.json b/packages/ckeditor5-basic-styles/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-basic-styles/tsconfig.dist.json +++ b/packages/ckeditor5-basic-styles/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-basic-styles/tsconfig.json b/packages/ckeditor5-basic-styles/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-basic-styles/tsconfig.json +++ b/packages/ckeditor5-basic-styles/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-block-quote/ckeditor5-metadata.json b/packages/ckeditor5-block-quote/ckeditor5-metadata.json index 5da4943dbd3..eedda4aefa8 100644 --- a/packages/ckeditor5-block-quote/ckeditor5-metadata.json +++ b/packages/ckeditor5-block-quote/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "blockQuote", - "iconPath": "@ckeditor/ckeditor5-icons/theme/quote.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/quote.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-block-quote/docs/features/block-quote.md b/packages/ckeditor5-block-quote/docs/features/block-quote.md index 8a597451de9..c8fc7aee12a 100644 --- a/packages/ckeditor5-block-quote/docs/features/block-quote.md +++ b/packages/ckeditor5-block-quote/docs/features/block-quote.md @@ -11,7 +11,7 @@ The block quote feature lets you easily include block quotations or pull quotes ## Demo -Use the block quote toolbar button {@icon @ckeditor/ckeditor5-core/theme/icons/quote.svg Insert block quote} in the editor below to see the feature in action. You can also type `>` followed by a space before the quotation to format it on the go thanks to the {@link features/autoformat autoformatting} feature. +Use the block quote toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/quote.svg Insert block quote} in the editor below to see the feature in action. You can also type `>` followed by a space before the quotation to format it on the go thanks to the {@link features/autoformat autoformatting} feature. {@snippet features/block-quote} diff --git a/packages/ckeditor5-block-quote/package.json b/packages/ckeditor5-block-quote/package.json index 0c441b8ee03..5b885315dda 100644 --- a/packages/ckeditor5-block-quote/package.json +++ b/packages/ckeditor5-block-quote/package.json @@ -15,6 +15,7 @@ "dependencies": { "@ckeditor/ckeditor5-core": "44.1.0", "@ckeditor/ckeditor5-enter": "44.1.0", + "@ckeditor/ckeditor5-icons": "0.0.1", "@ckeditor/ckeditor5-typing": "44.1.0", "@ckeditor/ckeditor5-ui": "44.1.0", "@ckeditor/ckeditor5-utils": "44.1.0", @@ -22,7 +23,7 @@ }, "devDependencies": { "@ckeditor/ckeditor5-basic-styles": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-engine": "44.1.0", "@ckeditor/ckeditor5-heading": "44.1.0", diff --git a/packages/ckeditor5-block-quote/src/blockquoteui.ts b/packages/ckeditor5-block-quote/src/blockquoteui.ts index d2f72b6bb77..e22a6fa4f3a 100644 --- a/packages/ckeditor5-block-quote/src/blockquoteui.ts +++ b/packages/ckeditor5-block-quote/src/blockquoteui.ts @@ -7,7 +7,8 @@ * @module block-quote/blockquoteui */ -import { Plugin, icons } from 'ckeditor5/src/core.js'; +import { Plugin } from 'ckeditor5/src/core.js'; +import { IconQuote } from 'ckeditor5/src/icons.js'; import { ButtonView, MenuBarMenuListItemButtonView } from 'ckeditor5/src/ui.js'; import '../theme/blockquote.css'; @@ -73,7 +74,7 @@ export default class BlockQuoteUI extends Plugin { view.set( { label: t( 'Block quote' ), - icon: icons.quote, + icon: IconQuote, isToggleable: true } ); diff --git a/packages/ckeditor5-block-quote/tsconfig.dist.json b/packages/ckeditor5-block-quote/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-block-quote/tsconfig.dist.json +++ b/packages/ckeditor5-block-quote/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-block-quote/tsconfig.json b/packages/ckeditor5-block-quote/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-block-quote/tsconfig.json +++ b/packages/ckeditor5-block-quote/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-bookmark/ckeditor5-metadata.json b/packages/ckeditor5-bookmark/ckeditor5-metadata.json index fb1d217ae1a..30731a9eba4 100644 --- a/packages/ckeditor5-bookmark/ckeditor5-metadata.json +++ b/packages/ckeditor5-bookmark/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "bookmark", - "iconPath": "@ckeditor/ckeditor5-icons/theme/bookmark.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/bookmark.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-bookmark/docs/features/bookmarks.md b/packages/ckeditor5-bookmark/docs/features/bookmarks.md index 3393bd56b30..53465713b20 100644 --- a/packages/ckeditor5-bookmark/docs/features/bookmarks.md +++ b/packages/ckeditor5-bookmark/docs/features/bookmarks.md @@ -12,9 +12,9 @@ The bookmarks feature allows for adding and managing the bookmarks anchors attac ## Demo -Use the bookmark toolbar button {@icon @ckeditor/ckeditor5-core/theme/icons/bookmark.svg Add bookmark} in the editor below to see the feature in action. Or use the "Insert" command from the menu bar to add a bookmark. Add a unique name to identify the bookmark (for example, `Rights`). +Use the bookmark toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/bookmark.svg Add bookmark} in the editor below to see the feature in action. Or use the "Insert" command from the menu bar to add a bookmark. Add a unique name to identify the bookmark (for example, `Rights`). -To use the bookmark as an anchor in the content, add a link {@icon @ckeditor/ckeditor5-link/theme/icons/link.svg Add link} and put the bookmark name as target. In the example below it would be `#Rights`. You can change the bookmark's name or remove it by clicking the bookmark icon inside the content. A contextual bookmark toolbar will pop up. +To use the bookmark as an anchor in the content, add a link {@icon @ckeditor/ckeditor5-icons/theme/icons/link.svg Add link} and put the bookmark name as target. In the example below it would be `#Rights`. You can change the bookmark's name or remove it by clicking the bookmark icon inside the content. A contextual bookmark toolbar will pop up. The Bookmarks feature is production-ready but does not include integration with the linking experience yet (see [#17230](https://github.com/ckeditor/ckeditor5/issues/17230)). diff --git a/packages/ckeditor5-bookmark/package.json b/packages/ckeditor5-bookmark/package.json index 8046056bb3f..f71133eefe7 100644 --- a/packages/ckeditor5-bookmark/package.json +++ b/packages/ckeditor5-bookmark/package.json @@ -16,6 +16,7 @@ "ckeditor5": "44.1.0", "@ckeditor/ckeditor5-core": "44.1.0", "@ckeditor/ckeditor5-engine": "44.1.0", + "@ckeditor/ckeditor5-icons": "0.0.1", "@ckeditor/ckeditor5-widget": "44.1.0", "@ckeditor/ckeditor5-utils": "44.1.0", "@ckeditor/ckeditor5-ui": "44.1.0" @@ -25,7 +26,7 @@ "@ckeditor/ckeditor5-block-quote": "44.1.0", "@ckeditor/ckeditor5-cloud-services": "44.1.0", "@ckeditor/ckeditor5-code-block": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-easy-image": "44.1.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-essentials": "44.1.0", diff --git a/packages/ckeditor5-bookmark/src/bookmarkediting.ts b/packages/ckeditor5-bookmark/src/bookmarkediting.ts index 0950cfaecc6..5b181aababc 100644 --- a/packages/ckeditor5-bookmark/src/bookmarkediting.ts +++ b/packages/ckeditor5-bookmark/src/bookmarkediting.ts @@ -7,9 +7,10 @@ * @module bookmark/bookmarkediting */ -import { type Editor, Plugin, icons } from 'ckeditor5/src/core.js'; +import { type Editor, Plugin } from 'ckeditor5/src/core.js'; import { toWidget } from 'ckeditor5/src/widget.js'; import { IconView } from 'ckeditor5/src/ui.js'; +import { IconBookmarkInline } from 'ckeditor5/src/icons.js'; import type { EventInfo } from 'ckeditor5/src/utils.js'; import type { @@ -160,7 +161,7 @@ export default class BookmarkEditing extends Plugin { const icon = new IconView(); icon.set( { - content: icons.bookmarkInline, + content: IconBookmarkInline, isColorInherited: false } ); diff --git a/packages/ckeditor5-bookmark/src/bookmarkui.ts b/packages/ckeditor5-bookmark/src/bookmarkui.ts index d7c6838535b..4d071a23ff2 100644 --- a/packages/ckeditor5-bookmark/src/bookmarkui.ts +++ b/packages/ckeditor5-bookmark/src/bookmarkui.ts @@ -7,7 +7,7 @@ * @module bookmark/bookmarkui */ -import { Plugin, type Editor, icons } from 'ckeditor5/src/core.js'; +import { Plugin, type Editor } from 'ckeditor5/src/core.js'; import { ButtonView, ContextualBalloon, @@ -16,7 +16,7 @@ import { clickOutsideHandler, type ViewWithCssTransitionDisabler } from 'ckeditor5/src/ui.js'; - +import { IconBookmark } from 'ckeditor5/src/icons.js'; import { ClickObserver, type ViewDocumentClickEvent, @@ -273,7 +273,7 @@ export default class BookmarkUI extends Plugin { view.set( { label: t( 'Bookmark' ), - icon: icons.bookmark + icon: IconBookmark } ); // Execute the command. diff --git a/packages/ckeditor5-bookmark/src/ui/bookmarkactionsview.ts b/packages/ckeditor5-bookmark/src/ui/bookmarkactionsview.ts index 6675edbbe39..1711d4b57f6 100644 --- a/packages/ckeditor5-bookmark/src/ui/bookmarkactionsview.ts +++ b/packages/ckeditor5-bookmark/src/ui/bookmarkactionsview.ts @@ -22,8 +22,7 @@ import { type LocaleTranslate, type Locale } from 'ckeditor5/src/utils.js'; - -import { icons } from 'ckeditor5/src/core.js'; +import { IconPencil, IconRemove } from 'ckeditor5/src/icons.js'; // eslint-disable-next-line ckeditor5-rules/ckeditor-imports import '@ckeditor/ckeditor5-ui/theme/components/responsive-form/responsiveform.css'; @@ -87,8 +86,8 @@ export default class BookmarkActionsView extends View { const t = locale.t; this.bookmarkPreviewView = this._createBookmarkPreviewView(); - this.removeButtonView = this._createButton( t( 'Remove bookmark' ), icons.remove, 'remove', this.bookmarkPreviewView ); - this.editButtonView = this._createButton( t( 'Edit bookmark' ), icons.pencil, 'edit', this.bookmarkPreviewView ); + this.removeButtonView = this._createButton( t( 'Remove bookmark' ), IconRemove, 'remove', this.bookmarkPreviewView ); + this.editButtonView = this._createButton( t( 'Edit bookmark' ), IconPencil, 'edit', this.bookmarkPreviewView ); this.set( 'id', undefined ); diff --git a/packages/ckeditor5-bookmark/tests/bookmarkui.js b/packages/ckeditor5-bookmark/tests/bookmarkui.js index ccc06f7345b..7291ee2f7f4 100644 --- a/packages/ckeditor5-bookmark/tests/bookmarkui.js +++ b/packages/ckeditor5-bookmark/tests/bookmarkui.js @@ -11,7 +11,7 @@ import { Paragraph } from '@ckeditor/ckeditor5-paragraph'; import { BlockQuote } from '@ckeditor/ckeditor5-block-quote'; import { View, ButtonView, ContextualBalloon, MenuBarMenuListItemButtonView } from '@ckeditor/ckeditor5-ui'; -import { icons } from '@ckeditor/ckeditor5-core'; +import { IconBookmark } from '@ckeditor/ckeditor5-icons'; import { ClickObserver } from '@ckeditor/ckeditor5-engine'; import { indexOf, isRange, keyCodes } from '@ckeditor/ckeditor5-utils'; import { setData as setModelData } from '@ckeditor/ckeditor5-engine/src/dev-utils/model.js'; @@ -23,8 +23,6 @@ import BookmarkActionsView from '../src/ui/bookmarkactionsview.js'; import BookmarkEditing from '../src/bookmarkediting.js'; import BookmarkUI from '../src/bookmarkui.js'; -const bookmarkIcon = icons.bookmark; - describe( 'BookmarkUI', () => { let editor, element, button, balloon, bookmarkUIFeature, formView, actionsView; @@ -92,7 +90,7 @@ describe( 'BookmarkUI', () => { } ); it( 'should have an icon', () => { - expect( button.icon ).to.equal( bookmarkIcon ); + expect( button.icon ).to.equal( IconBookmark ); } ); it( 'should bind #isEnabled to insert and update command', () => { diff --git a/packages/ckeditor5-bookmark/tsconfig.dist.json b/packages/ckeditor5-bookmark/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-bookmark/tsconfig.dist.json +++ b/packages/ckeditor5-bookmark/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-bookmark/tsconfig.json b/packages/ckeditor5-bookmark/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-bookmark/tsconfig.json +++ b/packages/ckeditor5-bookmark/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-build-balloon-block/package.json b/packages/ckeditor5-build-balloon-block/package.json index 12de3336fae..56a35771d8a 100644 --- a/packages/ckeditor5-build-balloon-block/package.json +++ b/packages/ckeditor5-build-balloon-block/package.json @@ -52,8 +52,8 @@ }, "devDependencies": { "@ckeditor/ckeditor5-core": "44.1.0", - "@ckeditor/ckeditor5-dev-translations": "^45.0.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-translations": "^46.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-theme-lark": "44.1.0", "terser-webpack-plugin": "^5.0.0", "typescript": "5.0.4", diff --git a/packages/ckeditor5-build-balloon-block/tsconfig.json b/packages/ckeditor5-build-balloon-block/tsconfig.json index e1ba67ba708..204c6484097 100644 --- a/packages/ckeditor5-build-balloon-block/tsconfig.json +++ b/packages/ckeditor5-build-balloon-block/tsconfig.json @@ -1,6 +1,7 @@ { "extends": "ckeditor5/tsconfig.json", "include": [ - "src" + "src", + "../../typings" ] } diff --git a/packages/ckeditor5-build-balloon-block/tsconfig.types.json b/packages/ckeditor5-build-balloon-block/tsconfig.types.json index 69bc431ea75..9b51af3ccbb 100644 --- a/packages/ckeditor5-build-balloon-block/tsconfig.types.json +++ b/packages/ckeditor5-build-balloon-block/tsconfig.types.json @@ -7,6 +7,7 @@ "stripInternal": true }, "include": [ - "src" + "src", + "../../typings" ] } diff --git a/packages/ckeditor5-build-balloon/package.json b/packages/ckeditor5-build-balloon/package.json index 40194215172..8bb60a24535 100644 --- a/packages/ckeditor5-build-balloon/package.json +++ b/packages/ckeditor5-build-balloon/package.json @@ -51,8 +51,8 @@ }, "devDependencies": { "@ckeditor/ckeditor5-core": "44.1.0", - "@ckeditor/ckeditor5-dev-translations": "^45.0.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-translations": "^46.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-theme-lark": "44.1.0", "terser-webpack-plugin": "^5.0.0", "typescript": "5.0.4", diff --git a/packages/ckeditor5-build-balloon/tsconfig.json b/packages/ckeditor5-build-balloon/tsconfig.json index e1ba67ba708..204c6484097 100644 --- a/packages/ckeditor5-build-balloon/tsconfig.json +++ b/packages/ckeditor5-build-balloon/tsconfig.json @@ -1,6 +1,7 @@ { "extends": "ckeditor5/tsconfig.json", "include": [ - "src" + "src", + "../../typings" ] } diff --git a/packages/ckeditor5-build-balloon/tsconfig.types.json b/packages/ckeditor5-build-balloon/tsconfig.types.json index 69bc431ea75..9b51af3ccbb 100644 --- a/packages/ckeditor5-build-balloon/tsconfig.types.json +++ b/packages/ckeditor5-build-balloon/tsconfig.types.json @@ -7,6 +7,7 @@ "stripInternal": true }, "include": [ - "src" + "src", + "../../typings" ] } diff --git a/packages/ckeditor5-build-classic/package.json b/packages/ckeditor5-build-classic/package.json index 12b0faf65a4..2da7a5103cd 100644 --- a/packages/ckeditor5-build-classic/package.json +++ b/packages/ckeditor5-build-classic/package.json @@ -51,8 +51,8 @@ }, "devDependencies": { "@ckeditor/ckeditor5-core": "44.1.0", - "@ckeditor/ckeditor5-dev-translations": "^45.0.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-translations": "^46.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-theme-lark": "44.1.0", "terser-webpack-plugin": "^5.0.0", "typescript": "5.0.4", diff --git a/packages/ckeditor5-build-classic/tsconfig.json b/packages/ckeditor5-build-classic/tsconfig.json index e1ba67ba708..204c6484097 100644 --- a/packages/ckeditor5-build-classic/tsconfig.json +++ b/packages/ckeditor5-build-classic/tsconfig.json @@ -1,6 +1,7 @@ { "extends": "ckeditor5/tsconfig.json", "include": [ - "src" + "src", + "../../typings" ] } diff --git a/packages/ckeditor5-build-classic/tsconfig.types.json b/packages/ckeditor5-build-classic/tsconfig.types.json index 69bc431ea75..9b51af3ccbb 100644 --- a/packages/ckeditor5-build-classic/tsconfig.types.json +++ b/packages/ckeditor5-build-classic/tsconfig.types.json @@ -7,6 +7,7 @@ "stripInternal": true }, "include": [ - "src" + "src", + "../../typings" ] } diff --git a/packages/ckeditor5-build-decoupled-document/package.json b/packages/ckeditor5-build-decoupled-document/package.json index 7c53157d602..e4cf2c9f3a9 100644 --- a/packages/ckeditor5-build-decoupled-document/package.json +++ b/packages/ckeditor5-build-decoupled-document/package.json @@ -53,8 +53,8 @@ }, "devDependencies": { "@ckeditor/ckeditor5-core": "44.1.0", - "@ckeditor/ckeditor5-dev-translations": "^45.0.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-translations": "^46.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-theme-lark": "44.1.0", "terser-webpack-plugin": "^5.0.0", "typescript": "5.0.4", diff --git a/packages/ckeditor5-build-decoupled-document/tsconfig.json b/packages/ckeditor5-build-decoupled-document/tsconfig.json index e1ba67ba708..204c6484097 100644 --- a/packages/ckeditor5-build-decoupled-document/tsconfig.json +++ b/packages/ckeditor5-build-decoupled-document/tsconfig.json @@ -1,6 +1,7 @@ { "extends": "ckeditor5/tsconfig.json", "include": [ - "src" + "src", + "../../typings" ] } diff --git a/packages/ckeditor5-build-decoupled-document/tsconfig.types.json b/packages/ckeditor5-build-decoupled-document/tsconfig.types.json index 69bc431ea75..9b51af3ccbb 100644 --- a/packages/ckeditor5-build-decoupled-document/tsconfig.types.json +++ b/packages/ckeditor5-build-decoupled-document/tsconfig.types.json @@ -7,6 +7,7 @@ "stripInternal": true }, "include": [ - "src" + "src", + "../../typings" ] } diff --git a/packages/ckeditor5-build-inline/package.json b/packages/ckeditor5-build-inline/package.json index 965066fc0cc..f5d59442226 100644 --- a/packages/ckeditor5-build-inline/package.json +++ b/packages/ckeditor5-build-inline/package.json @@ -51,8 +51,8 @@ }, "devDependencies": { "@ckeditor/ckeditor5-core": "44.1.0", - "@ckeditor/ckeditor5-dev-translations": "^45.0.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-translations": "^46.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-theme-lark": "44.1.0", "terser-webpack-plugin": "^5.0.0", "typescript": "5.0.4", diff --git a/packages/ckeditor5-build-inline/tsconfig.json b/packages/ckeditor5-build-inline/tsconfig.json index e1ba67ba708..204c6484097 100644 --- a/packages/ckeditor5-build-inline/tsconfig.json +++ b/packages/ckeditor5-build-inline/tsconfig.json @@ -1,6 +1,7 @@ { "extends": "ckeditor5/tsconfig.json", "include": [ - "src" + "src", + "../../typings" ] } diff --git a/packages/ckeditor5-build-inline/tsconfig.types.json b/packages/ckeditor5-build-inline/tsconfig.types.json index 69bc431ea75..9b51af3ccbb 100644 --- a/packages/ckeditor5-build-inline/tsconfig.types.json +++ b/packages/ckeditor5-build-inline/tsconfig.types.json @@ -7,6 +7,7 @@ "stripInternal": true }, "include": [ - "src" + "src", + "../../typings" ] } diff --git a/packages/ckeditor5-build-multi-root/package.json b/packages/ckeditor5-build-multi-root/package.json index c48fc2e3b0e..79a4cccb75f 100644 --- a/packages/ckeditor5-build-multi-root/package.json +++ b/packages/ckeditor5-build-multi-root/package.json @@ -51,8 +51,8 @@ }, "devDependencies": { "@ckeditor/ckeditor5-core": "44.1.0", - "@ckeditor/ckeditor5-dev-translations": "^45.0.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-translations": "^46.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-theme-lark": "44.1.0", "terser-webpack-plugin": "^5.0.0", "typescript": "5.0.4", diff --git a/packages/ckeditor5-build-multi-root/tsconfig.json b/packages/ckeditor5-build-multi-root/tsconfig.json index e1ba67ba708..204c6484097 100644 --- a/packages/ckeditor5-build-multi-root/tsconfig.json +++ b/packages/ckeditor5-build-multi-root/tsconfig.json @@ -1,6 +1,7 @@ { "extends": "ckeditor5/tsconfig.json", "include": [ - "src" + "src", + "../../typings" ] } diff --git a/packages/ckeditor5-build-multi-root/tsconfig.types.json b/packages/ckeditor5-build-multi-root/tsconfig.types.json index 69bc431ea75..9b51af3ccbb 100644 --- a/packages/ckeditor5-build-multi-root/tsconfig.types.json +++ b/packages/ckeditor5-build-multi-root/tsconfig.types.json @@ -7,6 +7,7 @@ "stripInternal": true }, "include": [ - "src" + "src", + "../../typings" ] } diff --git a/packages/ckeditor5-ckbox/ckeditor5-metadata.json b/packages/ckeditor5-ckbox/ckeditor5-metadata.json index 3fbb3e56e4e..e4e37cd4078 100644 --- a/packages/ckeditor5-ckbox/ckeditor5-metadata.json +++ b/packages/ckeditor5-ckbox/ckeditor5-metadata.json @@ -20,7 +20,7 @@ { "name": "ckbox", "type": "Button", - "iconPath": "@ckeditor/ckeditor5-icons/theme/browse-files.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/browse-files.svg" } ], "htmlOutput": [ @@ -50,7 +50,7 @@ { "name": "ckboxImageEdit", "type": "Button", - "iconPath": "@ckeditor/ckeditor5-icons/theme/ckbox-image-edit.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/ckbox-image-edit.svg" } ] } diff --git a/packages/ckeditor5-ckbox/docs/features/ckbox.md b/packages/ckeditor5-ckbox/docs/features/ckbox.md index c84437e27ee..5fa682b8288 100644 --- a/packages/ckeditor5-ckbox/docs/features/ckbox.md +++ b/packages/ckeditor5-ckbox/docs/features/ckbox.md @@ -34,9 +34,9 @@ To find out more about CKBox, the brand-new file manager and image editor, visit ## Demo -To upload a file using CKBox, use the open file manager toolbar button {@icon @ckeditor/ckeditor5-core/theme/icons/browse-files.svg Open file manager}. You can choose more than one file at a time. Use the edit image button {@icon @ckeditor/ckeditor5-ckbox/theme/icons/ckbox-image-edit.svg} from either the main toolbar or the image contextual toolbar to edit the selected image. +To upload a file using CKBox, use the open file manager toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/browse-files.svg Open file manager}. You can choose more than one file at a time. Use the edit image button {@icon @ckeditor/ckeditor5-icons/theme/icons/ckbox-image-edit.svg} from either the main toolbar or the image contextual toolbar to edit the selected image. -Note that the image toolbar button {@icon @ckeditor/ckeditor5-core/theme/icons/image-upload.svg Image upload} will now also upload images right into the CKBox file manager and you can {@link features/drag-drop drag and drop} them, too. You can then access the files from the management panel. +Note that the image toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/image-upload.svg Image upload} will now also upload images right into the CKBox file manager and you can {@link features/drag-drop drag and drop} them, too. You can then access the files from the management panel. {@snippet features/ckbox} @@ -170,7 +170,7 @@ If you define your own upload category mappings for a particular image type, onl The [CKBox workspaces](https://ckeditor.com/docs/ckbox/latest/features/file-management/workspaces.html) provide a convenient solution for achieving data isolation and user separation within CKBox. With workspaces, you can easily create separate storage and data spaces, giving you precise control over assigning specific users, user groups, or tenants to each workspace. -If the user is assigned to more than one workspace, by default all the files uploaded directly from CKEditor are located in the first workspace in the list of workspaces allowed in the user's JWT token. This corresponds to uploads through drag and drop into the editor area, pasting images from the clipboard, or images uploaded using the Image {@icon @ckeditor/ckeditor5-core/theme/icons/image-upload.svg Image} feature. If you would like to define a specific workspace for files uploaded this way, you can define its ID in the `defaultUploadWorkspaceId` option. After that, all the files uploaded directly from CKEditor will be placed in the specified workspace. +If the user is assigned to more than one workspace, by default all the files uploaded directly from CKEditor are located in the first workspace in the list of workspaces allowed in the user's JWT token. This corresponds to uploads through drag and drop into the editor area, pasting images from the clipboard, or images uploaded using the Image {@icon @ckeditor/ckeditor5-icons/theme/icons/image-upload.svg Image} feature. If you would like to define a specific workspace for files uploaded this way, you can define its ID in the `defaultUploadWorkspaceId` option. After that, all the files uploaded directly from CKEditor will be placed in the specified workspace. ```js ClassicEditor diff --git a/packages/ckeditor5-ckbox/package.json b/packages/ckeditor5-ckbox/package.json index 2a2b45e0d19..3cf35f0bd52 100644 --- a/packages/ckeditor5-ckbox/package.json +++ b/packages/ckeditor5-ckbox/package.json @@ -13,8 +13,11 @@ "type": "module", "main": "src/index.ts", "dependencies": { + "@ckeditor/ckeditor5-cloud-services": "44.1.0", "@ckeditor/ckeditor5-core": "44.1.0", "@ckeditor/ckeditor5-engine": "44.1.0", + "@ckeditor/ckeditor5-icons": "0.0.1", + "@ckeditor/ckeditor5-image": "44.1.0", "@ckeditor/ckeditor5-ui": "44.1.0", "@ckeditor/ckeditor5-upload": "44.1.0", "@ckeditor/ckeditor5-utils": "44.1.0", @@ -26,12 +29,10 @@ "@ckeditor/ckeditor5-autosave": "44.1.0", "@ckeditor/ckeditor5-basic-styles": "44.1.0", "@ckeditor/ckeditor5-clipboard": "44.1.0", - "@ckeditor/ckeditor5-cloud-services": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-essentials": "44.1.0", "@ckeditor/ckeditor5-heading": "44.1.0", - "@ckeditor/ckeditor5-image": "44.1.0", "@ckeditor/ckeditor5-link": "44.1.0", "@ckeditor/ckeditor5-paragraph": "44.1.0", "@ckeditor/ckeditor5-theme-lark": "44.1.0", diff --git a/packages/ckeditor5-ckbox/src/ckboxcommand.ts b/packages/ckeditor5-ckbox/src/ckboxcommand.ts index c71d4a7c072..670089d2797 100644 --- a/packages/ckeditor5-ckbox/src/ckboxcommand.ts +++ b/packages/ckeditor5-ckbox/src/ckboxcommand.ts @@ -19,6 +19,7 @@ import type { CKBoxAssetImageDefinition, CKBoxAssetLinkAttributesDefinition, CKBoxAssetLinkDefinition, + CKBoxConfig, CKBoxRawAssetDefinition } from './ckboxconfig.js'; @@ -189,6 +190,7 @@ export default class CKBoxCommand extends Command { const editor = this.editor; const model = editor.model; const shouldInsertDataId = !editor.config.get( 'ckbox.ignoreDataId' ); + const downloadableFilesConfig = editor.config.get( 'ckbox.downloadableFiles' ); // Refresh the command after firing the `ckbox:*` event. this.on( 'ckbox', () => { @@ -230,6 +232,7 @@ export default class CKBoxCommand extends Command { const assetsToProcess = prepareAssets( { assets, + downloadableFilesConfig, isImageAllowed: imageCommand.isEnabled, isLinkAllowed: linkCommand.isEnabled } ); @@ -379,7 +382,8 @@ export default class CKBoxCommand extends Command { * Parses the chosen assets into the internal data format. Filters out chosen assets that are not allowed. */ function prepareAssets( - { assets, isImageAllowed, isLinkAllowed }: { + { downloadableFilesConfig, assets, isImageAllowed, isLinkAllowed }: { + downloadableFilesConfig: CKBoxConfig[ 'downloadableFiles' ]; assets: Array; isImageAllowed: boolean; isLinkAllowed: boolean; @@ -395,7 +399,7 @@ function prepareAssets( { id: asset.data.id, type: 'link', - attributes: prepareLinkAssetAttributes( asset ) + attributes: prepareLinkAssetAttributes( asset, downloadableFilesConfig ) } as const ) .filter( asset => asset.type === 'image' ? isImageAllowed : isLinkAllowed ); @@ -424,12 +428,16 @@ export function prepareImageAssetAttributes( asset: CKBoxRawAssetDefinition ): C /** * Parses the assets attributes into the internal data format. * - * @param origin The base URL for assets inserted into the editor. + * @param asset The asset to prepare the attributes for. + * @param config The CKBox download asset configuration. */ -function prepareLinkAssetAttributes( asset: CKBoxRawAssetDefinition ): CKBoxAssetLinkAttributesDefinition { +function prepareLinkAssetAttributes( + asset: CKBoxRawAssetDefinition, + config: CKBoxConfig[ 'downloadableFiles' ] +): CKBoxAssetLinkAttributesDefinition { return { linkName: asset.data.name, - linkHref: getAssetUrl( asset ) + linkHref: getAssetUrl( asset, config ) }; } @@ -449,16 +457,36 @@ function isImage( asset: CKBoxRawAssetDefinition ) { /** * Creates the URL for the asset. * - * @param origin The base URL for assets inserted into the editor. + * @param asset The asset to create the URL for. + * @param config The CKBox download asset configuration. */ -function getAssetUrl( asset: CKBoxRawAssetDefinition ) { +function getAssetUrl( asset: CKBoxRawAssetDefinition, config: CKBoxConfig[ 'downloadableFiles' ] ) { const url = new URL( asset.data.url ); - url.searchParams.set( 'download', 'true' ); + if ( isDownloadableAsset( asset, config ) ) { + url.searchParams.set( 'download', 'true' ); + } return url.toString(); } +/** + * Determines if download should be enabled for given asset based on configuration. + * + * @param asset The asset to check. + * @param config The CKBox download asset configuration. + */ +function isDownloadableAsset( + asset: CKBoxRawAssetDefinition, + config: CKBoxConfig[ 'downloadableFiles' ] +): boolean { + if ( typeof config === 'function' ) { + return config( asset ); + } + + return true; +} + /** * Fired when the command is executed, the dialog is closed or the assets are chosen. * diff --git a/packages/ckeditor5-ckbox/src/ckboxconfig.ts b/packages/ckeditor5-ckbox/src/ckboxconfig.ts index f189447e283..0fe9adefd59 100644 --- a/packages/ckeditor5-ckbox/src/ckboxconfig.ts +++ b/packages/ckeditor5-ckbox/src/ckboxconfig.ts @@ -173,6 +173,19 @@ export interface CKBoxConfig { * ``` */ choosableFileExtensions?: Array; + + /** + * Controls when to enable the download attribute for inserted links. + * + * By default, files are downloadable. + * + * ```ts + * const ckboxConfig = { + * downloadableFiles: asset => asset.data.extension !== 'pdf' + * }; + * ``` + */ + downloadableFiles?: ( asset: CKBoxRawAssetDefinition ) => boolean; } export interface CKBoxDialogConfig { @@ -461,6 +474,11 @@ export interface CKBoxRawAssetDataDefinition { * The asset location. */ url: string; + + /** + * The asset type. + */ + extension?: string; } /** diff --git a/packages/ckeditor5-ckbox/src/ckboxui.ts b/packages/ckeditor5-ckbox/src/ckboxui.ts index a40e44e5de8..6cf0ee11ace 100644 --- a/packages/ckeditor5-ckbox/src/ckboxui.ts +++ b/packages/ckeditor5-ckbox/src/ckboxui.ts @@ -7,8 +7,9 @@ * @module ckbox/ckboxui */ -import { icons, Plugin } from 'ckeditor5/src/core.js'; +import { Plugin } from 'ckeditor5/src/core.js'; import { ButtonView, MenuBarMenuListItemButtonView } from 'ckeditor5/src/ui.js'; +import { IconBrowseFiles, IconImageAssetManager } from 'ckeditor5/src/icons.js'; import type { ImageInsertUI } from '@ckeditor/ckeditor5-image'; @@ -88,7 +89,7 @@ export default class CKBoxUI extends Plugin { const t = this.editor.locale.t; const button = this._createButton( ButtonView ); - button.icon = icons.browseFiles; + button.icon = IconBrowseFiles; button.label = t( 'Open file manager' ); button.tooltip = true; @@ -104,7 +105,7 @@ export default class CKBoxUI extends Plugin { const button = this._createButton( ButtonView ); - button.icon = icons.imageAssetManager; + button.icon = IconImageAssetManager; button.bind( 'label' ).to( imageInsertUI, 'isImageSelected', @@ -124,7 +125,7 @@ export default class CKBoxUI extends Plugin { const button = this._createButton( ButtonView ); - button.icon = icons.imageAssetManager; + button.icon = IconImageAssetManager; button.withText = true; button.bind( 'label' ).to( imageInsertUI, @@ -146,7 +147,7 @@ export default class CKBoxUI extends Plugin { const t = this.editor.locale.t; const button = this._createButton( MenuBarMenuListItemButtonView ); - button.icon = icons.browseFiles; + button.icon = IconBrowseFiles; button.withText = true; button.label = t( 'File' ); @@ -162,7 +163,7 @@ export default class CKBoxUI extends Plugin { const t = this.editor.locale.t; const button = this._createButton( MenuBarMenuListItemButtonView ); - button.icon = icons.imageAssetManager; + button.icon = IconImageAssetManager; button.withText = true; switch ( type ) { diff --git a/packages/ckeditor5-ckbox/tests/ckboxcommand.js b/packages/ckeditor5-ckbox/tests/ckboxcommand.js index c4314863902..7eb2a447be1 100644 --- a/packages/ckeditor5-ckbox/tests/ckboxcommand.js +++ b/packages/ckeditor5-ckbox/tests/ckboxcommand.js @@ -1209,6 +1209,143 @@ describe( 'CKBoxCommand', () => { sinon.assert.calledOnce( focusSpy ); } ); + + describe( 'downloadable files configuration', () => { + let command; + + beforeEach( async () => { + assets = { + images: [ + { + data: { + id: 'image-id1', + extension: 'png', + metadata: { + width: 100, + height: 100 + }, + name: 'image1', + imageUrls: { + 100: 'https://example.com/workspace1/assets/image-id1/images/100.webp', + default: 'https://example.com/workspace1/assets/image-id1/images/100.png' + }, + url: 'https://example.com/workspace1/assets/image-id1/file' + } + } + ], + links: [ + { + data: { + id: 'link-id1', + extension: 'pdf', + name: 'file1', + url: 'https://example.com/workspace1/assets/link-id1/file' + } + }, + { + data: { + id: 'link-id2', + extension: 'zip', + name: 'file2', + url: 'https://example.com/workspace1/assets/link-id2/file' + } + } + ] + }; + } ); + + it( 'should add download parameter to URLs by default', async () => { + const editor = await createTestEditor( { + ckbox: { + tokenUrl: 'foo' + } + } ); + + command = editor.commands.get( 'ckbox' ); + onChoose = command._prepareOptions().assets.onChoose; + + onChoose( [ assets.links[ 1 ] ] ); + + expect( getModelData( editor.model ) ).to.equal( + '' + + '[<$text ' + + 'ckboxLinkId="link-id2" ' + + 'linkHref="https://example.com/workspace1/assets/link-id2/file?download=true">' + + 'file2' + + ']' + + '' + ); + + await editor.destroy(); + } ); + + it( 'should allow custom function for determining downloadable files', async () => { + const editor = await createTestEditor( { + ckbox: { + tokenUrl: 'foo', + downloadableFiles: asset => asset.data.name === 'file1' + } + } ); + + const command = editor.commands.get( 'ckbox' ); + const onChoose = command._prepareOptions().assets.onChoose; + + // `file1` should have download parameter. + onChoose( [ assets.links[ 0 ] ] ); + + expect( getModelData( editor.model ) ).to.equal( + '' + + '[<$text ' + + 'ckboxLinkId="link-id1" ' + + 'linkHref="https://example.com/workspace1/assets/link-id1/file?download=true">' + + 'file1' + + ']' + + '' + ); + + // `file2` should not have download parameter. + editor.setData( '' ); + onChoose( [ assets.links[ 1 ] ] ); + + expect( getModelData( editor.model ) ).to.equal( + '' + + '[<$text ' + + 'ckboxLinkId="link-id2" ' + + 'linkHref="https://example.com/workspace1/assets/link-id2/file">' + + 'file2' + + ']' + + '' + ); + + await editor.destroy(); + } ); + + it( 'should not affect image assets', async () => { + const editor = await createTestEditor( { + ckbox: { + tokenUrl: 'foo' + } + } ); + + const command = editor.commands.get( 'ckbox' ); + const onChoose = command._prepareOptions().assets.onChoose; + + onChoose( [ assets.images[ 0 ] ] ); + + expect( getModelData( editor.model ) ).to.equal( + '[' + + ']' + ); + + await editor.destroy(); + } ); + } ); } ); } ); } ); diff --git a/packages/ckeditor5-ckbox/tests/ckboxui.js b/packages/ckeditor5-ckbox/tests/ckboxui.js index c4408a3af4f..79205b12335 100644 --- a/packages/ckeditor5-ckbox/tests/ckboxui.js +++ b/packages/ckeditor5-ckbox/tests/ckboxui.js @@ -18,7 +18,7 @@ import CloudServicesCoreMock from './_utils/cloudservicescoremock.js'; import ImageInsertUI from '@ckeditor/ckeditor5-image/src/imageinsert/imageinsertui.js'; import Model from '@ckeditor/ckeditor5-ui/src/model.js'; import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils.js'; -import { icons } from 'ckeditor5/src/core.js'; +import { IconImageAssetManager, IconBrowseFiles } from 'ckeditor5/src/icons.js'; import CKBoxUI from '../src/ckboxui.js'; import CKBoxEditing from '../src/ckboxediting.js'; @@ -142,7 +142,7 @@ describe( 'CKBoxUI', () => { expect( dropdownButton ).to.be.instanceOf( ButtonView ); expect( dropdownButton.withText ).to.be.false; - expect( dropdownButton.icon ).to.equal( icons.imageAssetManager ); + expect( dropdownButton.icon ).to.equal( IconImageAssetManager ); expect( dropdownButton.label ).to.equal( 'Insert image with file manager' ); } ); @@ -158,7 +158,7 @@ describe( 'CKBoxUI', () => { expect( buttonView ).to.be.instanceOf( ButtonView ); expect( buttonView.withText ).to.be.true; - expect( buttonView.icon ).to.equal( icons.imageAssetManager ); + expect( buttonView.icon ).to.equal( IconImageAssetManager ); expect( buttonView.label ).to.equal( 'Insert with file manager' ); } ); @@ -170,7 +170,7 @@ describe( 'CKBoxUI', () => { expect( buttonView ).to.be.instanceOf( MenuBarMenuListItemButtonView ); expect( buttonView.withText ).to.be.true; - expect( buttonView.icon ).to.equal( icons.imageAssetManager ); + expect( buttonView.icon ).to.equal( IconImageAssetManager ); expect( buttonView.label ).to.equal( 'With file manager' ); } ); @@ -179,7 +179,7 @@ describe( 'CKBoxUI', () => { expect( buttonView ).to.be.instanceOf( MenuBarMenuListItemButtonView ); expect( buttonView.withText ).to.be.true; - expect( buttonView.icon ).to.equal( icons.imageAssetManager ); + expect( buttonView.icon ).to.equal( IconImageAssetManager ); expect( buttonView.label ).to.equal( 'Image' ); } ); @@ -249,7 +249,7 @@ describe( 'CKBoxUI', () => { } ); it( 'should set an #icon of the #buttonView', () => { - expect( button.icon ).to.equal( icons.browseFiles ); + expect( button.icon ).to.equal( IconBrowseFiles ); } ); it( 'should execute the command afer firing the event', () => { diff --git a/packages/ckeditor5-ckbox/tests/manual/ckbox.js b/packages/ckeditor5-ckbox/tests/manual/ckbox.js index 9e2d0cc875c..601f194ec71 100644 --- a/packages/ckeditor5-ckbox/tests/manual/ckbox.js +++ b/packages/ckeditor5-ckbox/tests/manual/ckbox.js @@ -55,7 +55,8 @@ ClassicEditor ckbox: { tokenUrl: TOKEN_URL, forceDemoLabel: true, - allowExternalImagesEditing: [ /^data:/, /^i.imgur.com\//, 'origin' ] + allowExternalImagesEditing: [ /^data:/, /^i.imgur.com\//, 'origin' ], + downloadableFiles: asset => asset.data.extension !== 'pdf' } } ) .then( editor => { diff --git a/packages/ckeditor5-ckbox/tsconfig.dist.json b/packages/ckeditor5-ckbox/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-ckbox/tsconfig.dist.json +++ b/packages/ckeditor5-ckbox/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-ckbox/tsconfig.json b/packages/ckeditor5-ckbox/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-ckbox/tsconfig.json +++ b/packages/ckeditor5-ckbox/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-ckfinder/ckeditor5-metadata.json b/packages/ckeditor5-ckfinder/ckeditor5-metadata.json index efbd1160abd..56c3daebbc4 100644 --- a/packages/ckeditor5-ckfinder/ckeditor5-metadata.json +++ b/packages/ckeditor5-ckfinder/ckeditor5-metadata.json @@ -18,7 +18,7 @@ { "name": "CKFinder", "type": "Button", - "iconPath": "@ckeditor/ckeditor5-icons/theme/browse-files.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/browse-files.svg" } ] } diff --git a/packages/ckeditor5-ckfinder/docs/features/ckfinder.md b/packages/ckeditor5-ckfinder/docs/features/ckfinder.md index f9b77d47357..8c21d8d7336 100644 --- a/packages/ckeditor5-ckfinder/docs/features/ckfinder.md +++ b/packages/ckeditor5-ckfinder/docs/features/ckfinder.md @@ -24,7 +24,7 @@ The CKFinder feature lets you insert images and links to files into your content This demo shows the integration where the file manager's server connector handles [image upload](#configuring-the-image-upload-only) only: * Paste an image directly into the editor. It will be automatically uploaded using the server-side connector. -* Use the insert image button {@icon @ckeditor/ckeditor5-core/theme/icons/image-upload.svg Image} in the toolbar to insert an image. +* Use the insert image button {@icon @ckeditor/ckeditor5-icons/theme/icons/image-upload.svg Image} in the toolbar to insert an image. {@snippet features/ckfinder-upload-only} @@ -33,7 +33,7 @@ This demo shows the integration where the file manager's server connector handle This demo shows the [full integration](#configuring-the-full-integration) with the CKFinder file uploader: * Paste an image directly into the editor. It will be automatically uploaded using the server-side connector. -* Use the insert image or file button {@icon @ckeditor/ckeditor5-core/theme/icons/browse-files.svg Browse files} in the toolbar to open the CKFinder file manager. Then insert an image or a link to any other file. +* Use the insert image or file button {@icon @ckeditor/ckeditor5-icons/theme/icons/browse-files.svg Browse files} in the toolbar to open the CKFinder file manager. Then insert an image or a link to any other file. {@snippet features/ckfinder} diff --git a/packages/ckeditor5-ckfinder/package.json b/packages/ckeditor5-ckfinder/package.json index e48cff6244c..d071b7bbe30 100644 --- a/packages/ckeditor5-ckfinder/package.json +++ b/packages/ckeditor5-ckfinder/package.json @@ -14,6 +14,8 @@ "main": "src/index.ts", "dependencies": { "@ckeditor/ckeditor5-core": "44.1.0", + "@ckeditor/ckeditor5-icons": "0.0.1", + "@ckeditor/ckeditor5-image": "44.1.0", "@ckeditor/ckeditor5-ui": "44.1.0", "@ckeditor/ckeditor5-utils": "44.1.0", "ckeditor5": "44.1.0" @@ -21,10 +23,9 @@ "devDependencies": { "@ckeditor/ckeditor5-adapter-ckfinder": "44.1.0", "@ckeditor/ckeditor5-clipboard": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-engine": "44.1.0", - "@ckeditor/ckeditor5-image": "44.1.0", "@ckeditor/ckeditor5-link": "44.1.0", "@ckeditor/ckeditor5-paragraph": "44.1.0", "@ckeditor/ckeditor5-theme-lark": "44.1.0", diff --git a/packages/ckeditor5-ckfinder/src/ckfinderui.ts b/packages/ckeditor5-ckfinder/src/ckfinderui.ts index de8cf369f78..1de9673d8f1 100644 --- a/packages/ckeditor5-ckfinder/src/ckfinderui.ts +++ b/packages/ckeditor5-ckfinder/src/ckfinderui.ts @@ -7,8 +7,9 @@ * @module ckfinder/ckfinderui */ -import { icons, Plugin } from 'ckeditor5/src/core.js'; +import { Plugin } from 'ckeditor5/src/core.js'; import { ButtonView, MenuBarMenuListItemButtonView } from 'ckeditor5/src/ui.js'; +import { IconBrowseFiles, IconImageAssetManager } from 'ckeditor5/src/icons.js'; import type { ImageInsertUI } from '@ckeditor/ckeditor5-image'; import type CKFinderCommand from './ckfindercommand.js'; @@ -84,7 +85,7 @@ export default class CKFinderUI extends Plugin { const t = this.editor.locale.t; const button = this._createButton( ButtonView ); - button.icon = icons.browseFiles; + button.icon = IconBrowseFiles; button.label = t( 'Insert image or file' ); button.tooltip = true; @@ -100,7 +101,7 @@ export default class CKFinderUI extends Plugin { const button = this._createButton( ButtonView ); - button.icon = icons.imageAssetManager; + button.icon = IconImageAssetManager; button.bind( 'label' ).to( imageInsertUI, 'isImageSelected', @@ -120,7 +121,7 @@ export default class CKFinderUI extends Plugin { const button = this._createButton( ButtonView ); - button.icon = icons.imageAssetManager; + button.icon = IconImageAssetManager; button.withText = true; button.bind( 'label' ).to( imageInsertUI, @@ -142,7 +143,7 @@ export default class CKFinderUI extends Plugin { const t = this.editor.locale.t; const button = this._createButton( MenuBarMenuListItemButtonView ); - button.icon = icons.browseFiles; + button.icon = IconBrowseFiles; button.withText = true; button.label = t( 'File' ); @@ -158,7 +159,7 @@ export default class CKFinderUI extends Plugin { const t = this.editor.locale.t; const button = this._createButton( MenuBarMenuListItemButtonView ); - button.icon = icons.imageAssetManager; + button.icon = IconImageAssetManager; button.withText = true; switch ( type ) { diff --git a/packages/ckeditor5-ckfinder/tests/ckfinderui.js b/packages/ckeditor5-ckfinder/tests/ckfinderui.js index ebb76d085fe..9d7efa88259 100644 --- a/packages/ckeditor5-ckfinder/tests/ckfinderui.js +++ b/packages/ckeditor5-ckfinder/tests/ckfinderui.js @@ -11,7 +11,7 @@ import global from '@ckeditor/ckeditor5-utils/src/dom/global.js'; import Image from '@ckeditor/ckeditor5-image/src/image.js'; import Link from '@ckeditor/ckeditor5-link/src/link.js'; import CKFinderUploadAdapter from '@ckeditor/ckeditor5-adapter-ckfinder/src/uploadadapter.js'; -import { icons } from 'ckeditor5/src/core.js'; +import { IconImageAssetManager, IconBrowseFiles } from 'ckeditor5/src/icons.js'; import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview.js'; import MenuBarMenuListItemButtonView from '@ckeditor/ckeditor5-ui/src/menubar/menubarmenulistitembuttonview.js'; @@ -90,7 +90,7 @@ describe( 'CKFinderUI', () => { expect( dropdownButton ).to.be.instanceOf( ButtonView ); expect( dropdownButton.withText ).to.be.false; - expect( dropdownButton.icon ).to.equal( icons.imageAssetManager ); + expect( dropdownButton.icon ).to.equal( IconImageAssetManager ); expect( dropdownButton.label ).to.equal( 'Insert image with file manager' ); } ); @@ -106,7 +106,7 @@ describe( 'CKFinderUI', () => { expect( buttonView ).to.be.instanceOf( ButtonView ); expect( buttonView.withText ).to.be.true; - expect( buttonView.icon ).to.equal( icons.imageAssetManager ); + expect( buttonView.icon ).to.equal( IconImageAssetManager ); expect( buttonView.label ).to.equal( 'Insert with file manager' ); } ); @@ -118,7 +118,7 @@ describe( 'CKFinderUI', () => { expect( buttonView ).to.be.instanceOf( MenuBarMenuListItemButtonView ); expect( buttonView.withText ).to.be.true; - expect( buttonView.icon ).to.equal( icons.imageAssetManager ); + expect( buttonView.icon ).to.equal( IconImageAssetManager ); expect( buttonView.label ).to.equal( 'With file manager' ); } ); @@ -127,7 +127,7 @@ describe( 'CKFinderUI', () => { expect( buttonView ).to.be.instanceOf( MenuBarMenuListItemButtonView ); expect( buttonView.withText ).to.be.true; - expect( buttonView.icon ).to.equal( icons.imageAssetManager ); + expect( buttonView.icon ).to.equal( IconImageAssetManager ); expect( buttonView.label ).to.equal( 'Image' ); } ); @@ -187,7 +187,7 @@ describe( 'CKFinderUI', () => { } ); it( 'should set an #icon of the #buttonView', () => { - expect( button.icon ).to.equal( icons.browseFiles ); + expect( button.icon ).to.equal( IconBrowseFiles ); } ); it( 'should execute bold command on model execute event', () => { diff --git a/packages/ckeditor5-ckfinder/tsconfig.dist.json b/packages/ckeditor5-ckfinder/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-ckfinder/tsconfig.dist.json +++ b/packages/ckeditor5-ckfinder/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-ckfinder/tsconfig.json b/packages/ckeditor5-ckfinder/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-ckfinder/tsconfig.json +++ b/packages/ckeditor5-ckfinder/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-clipboard/docs/features/drag-drop.md b/packages/ckeditor5-clipboard/docs/features/drag-drop.md index ca1dba78b67..4dfc308a580 100644 --- a/packages/ckeditor5-clipboard/docs/features/drag-drop.md +++ b/packages/ckeditor5-clipboard/docs/features/drag-drop.md @@ -37,7 +37,7 @@ The drag and drop functions include: * Selection of the text, elements, multiple blocks, and moving these around. * Placement of blocks inside other blocks such as tables, blockquotes, etc. -* The braille dots panel icon {@icon @ckeditor/ckeditor5-core/theme/icons/drag-indicator.svg Drag indicator} in the [balloon block editor](#balloon-block-editor-demo) now behaves as a drag handle. +* The braille dots panel icon {@icon @ckeditor/ckeditor5-icons/theme/icons/drag-indicator.svg Drag indicator} in the [balloon block editor](#balloon-block-editor-demo) now behaves as a drag handle. ### Classic editor demo @@ -47,7 +47,7 @@ Select a block or blocks, and drag them across the document. You can place block ### Balloon block editor demo -In the balloon block editor, you can also drag content blocks using the drag handle. Select or focus on the block, and then drag the block with the braille dots panel icon {@icon @ckeditor/ckeditor5-core/theme/icons/drag-indicator.svg Drag indicator}. +In the balloon block editor, you can also drag content blocks using the drag handle. Select or focus on the block, and then drag the block with the braille dots panel icon {@icon @ckeditor/ckeditor5-icons/theme/icons/drag-indicator.svg Drag indicator}. {@snippet features/block-balloon-drag-drop} diff --git a/packages/ckeditor5-clipboard/src/clipboardpipeline.ts b/packages/ckeditor5-clipboard/src/clipboardpipeline.ts index 8c3db74b5ca..7d731ede003 100644 --- a/packages/ckeditor5-clipboard/src/clipboardpipeline.ts +++ b/packages/ckeditor5-clipboard/src/clipboardpipeline.ts @@ -236,10 +236,12 @@ export default class ClipboardPipeline extends Plugin { } const eventInfo = new EventInfo( this, 'inputTransformation' ); + const sourceEditorId = dataTransfer.getData( 'application/ckeditor5-editor-id' ) || null; this.fire( eventInfo, { content, dataTransfer, + sourceEditorId, targetRanges: data.targetRanges, method: data.method as 'paste' | 'drop' } ); @@ -278,6 +280,7 @@ export default class ClipboardPipeline extends Plugin { this.fire( 'contentInsertion', { content: modelFragment, method: data.method, + sourceEditorId: data.sourceEditorId, dataTransfer: data.dataTransfer, targetRanges: data.targetRanges } ); @@ -318,7 +321,7 @@ export default class ClipboardPipeline extends Plugin { }, { priority: 'low' } ); this.listenTo( this, 'outputTransformation', ( evt, data ) => { - const content = editor.data.toView( data.content ); + const content = editor.data.toView( data.content, { isClipboardPipeline: true } ); viewDocument.fire( 'clipboardOutput', { dataTransfer: data.dataTransfer, @@ -330,7 +333,8 @@ export default class ClipboardPipeline extends Plugin { this.listenTo( viewDocument, 'clipboardOutput', ( evt, data ) => { if ( !data.content.isEmpty ) { data.dataTransfer.setData( 'text/html', this.editor.data.htmlProcessor.toData( data.content ) ); - data.dataTransfer.setData( 'text/plain', viewToPlainText( data.content ) ); + data.dataTransfer.setData( 'text/plain', viewToPlainText( editor.data.htmlProcessor.domConverter, data.content ) ); + data.dataTransfer.setData( 'application/ckeditor5-editor-id', this.editor.id ); } if ( data.method == 'cut' ) { @@ -389,6 +393,11 @@ export interface ClipboardInputTransformationData { * Whether the event was triggered by a paste or a drop operation. */ method: 'paste' | 'drop'; + + /** + * ID of the editor instance from which the content was copied. + */ + sourceEditorId: string | null; } /** @@ -433,6 +442,11 @@ export interface ClipboardContentInsertionData { */ method: 'paste' | 'drop'; + /** + * The ID of the editor instance from which the content was copied. + */ + sourceEditorId: string | null; + /** * The data transfer instance. */ diff --git a/packages/ckeditor5-clipboard/src/index.ts b/packages/ckeditor5-clipboard/src/index.ts index 06e89c924eb..22dac94793f 100644 --- a/packages/ckeditor5-clipboard/src/index.ts +++ b/packages/ckeditor5-clipboard/src/index.ts @@ -39,6 +39,7 @@ export { default as DragDropBlockToolbar } from './dragdropblocktoolbar.js'; export type { ViewDocumentClipboardInputEvent, ViewDocumentCopyEvent, + ViewDocumentPasteEvent, ViewDocumentCutEvent } from './clipboardobserver.js'; diff --git a/packages/ckeditor5-clipboard/src/utils/viewtoplaintext.ts b/packages/ckeditor5-clipboard/src/utils/viewtoplaintext.ts index 3f89713a393..1b44ce6b03c 100644 --- a/packages/ckeditor5-clipboard/src/utils/viewtoplaintext.ts +++ b/packages/ckeditor5-clipboard/src/utils/viewtoplaintext.ts @@ -7,7 +7,7 @@ * @module clipboard/utils/viewtoplaintext */ -import type { ViewDocumentFragment, ViewElement, ViewItem } from '@ckeditor/ckeditor5-engine'; +import type { DomConverter, ViewDocumentFragment, ViewElement, ViewItem } from '@ckeditor/ckeditor5-engine'; // Elements which should not have empty-line padding. // Most `view.ContainerElement` want to be separate by new-line, but some are creating one structure @@ -19,10 +19,14 @@ const listElements = [ 'ol', 'ul' ]; /** * Converts {@link module:engine/view/item~Item view item} and all of its children to plain text. * + * @param converter The converter instance. * @param viewItem View item to convert. * @returns Plain text representation of `viewItem`. */ -export default function viewToPlainText( viewItem: ViewItem | ViewDocumentFragment ): string { +export default function viewToPlainText( + converter: DomConverter, + viewItem: ViewItem | ViewDocumentFragment +): string { if ( viewItem.is( '$text' ) || viewItem.is( '$textProxy' ) ) { return viewItem.data; } @@ -44,10 +48,38 @@ export default function viewToPlainText( viewItem: ViewItem | ViewDocumentFragme let prev: ViewElement | null = null; for ( const child of ( viewItem as ViewElement | ViewDocumentFragment ).getChildren() ) { - text += newLinePadding( child as ViewElement, prev ) + viewToPlainText( child ); + text += newLinePadding( child as ViewElement, prev ) + viewToPlainText( converter, child ); prev = child as ViewElement; } + // If item is a raw element, the only way to get its content is to render it and read the text directly from DOM. + if ( viewItem.is( 'rawElement' ) ) { + const tempElement = document.createElement( 'div' ); + + viewItem.render( tempElement, converter ); + + text += domElementToPlainText( tempElement ); + } + + return text; +} + +/** + * Recursively converts DOM element and all of its children to plain text. + */ +function domElementToPlainText( element: HTMLElement ): string { + let text = ''; + + if ( element.nodeType === Node.TEXT_NODE ) { + return element.textContent!; + } else if ( element.tagName === 'BR' ) { + return '\n'; + } + + for ( const child of element.childNodes ) { + text += domElementToPlainText( child as HTMLElement ); + } + return text; } diff --git a/packages/ckeditor5-clipboard/tests/clipboardpipeline.js b/packages/ckeditor5-clipboard/tests/clipboardpipeline.js index 59286b73ac1..198dc70fd5e 100644 --- a/packages/ckeditor5-clipboard/tests/clipboardpipeline.js +++ b/packages/ckeditor5-clipboard/tests/clipboardpipeline.js @@ -462,10 +462,126 @@ describe( 'ClipboardPipeline feature', () => { expect( spy.callCount ).to.equal( 1 ); } ); + describe( 'source editor ID in events', () => { + it( 'should be null when pasting content from outside the editor', () => { + const dataTransferMock = createDataTransfer( { 'text/html': '

external content

' } ); + const inputTransformationSpy = sinon.spy(); + + clipboardPlugin.on( 'inputTransformation', ( evt, data ) => { + inputTransformationSpy( data.sourceEditorId ); + } ); + + viewDocument.fire( 'paste', { + dataTransfer: dataTransferMock, + preventDefault: () => {}, + stopPropagation: () => {} + } ); + + sinon.assert.calledWith( inputTransformationSpy, null ); + } ); + + it( 'should contain an editor ID when pasting content copied from the same editor (in dataTransfer)', () => { + const spy = sinon.spy(); + + setModelData( editor.model, 'f[oo]bar' ); + + // Copy selected content. + const dataTransferMock = createDataTransfer(); + + viewDocument.fire( 'copy', { + dataTransfer: dataTransferMock, + preventDefault: () => {} + } ); + + clipboardPlugin.on( 'inputTransformation', ( evt, data ) => { + spy( data.dataTransfer.getData( 'application/ckeditor5-editor-id' ) ); + } ); + + // Paste the copied content. + viewDocument.fire( 'paste', { + dataTransfer: dataTransferMock, + preventDefault: () => {}, + stopPropagation: () => {} + } ); + + sinon.assert.calledWith( spy, editor.id ); + } ); + + it( 'should contain an editor ID when pasting content copied from the same editor', () => { + const spy = sinon.spy(); + + setModelData( editor.model, 'f[oo]bar' ); + + // Copy selected content. + const dataTransferMock = createDataTransfer(); + + viewDocument.fire( 'copy', { + dataTransfer: dataTransferMock, + preventDefault: () => {} + } ); + + clipboardPlugin.on( 'inputTransformation', ( evt, data ) => { + spy( data.sourceEditorId ); + } ); + + // Paste the copied content. + viewDocument.fire( 'paste', { + dataTransfer: dataTransferMock, + preventDefault: () => {}, + stopPropagation: () => {} + } ); + + sinon.assert.calledWith( spy, editor.id ); + } ); + + it( 'should be propagated to contentInsertion event (when it\'s external content)', () => { + const dataTransferMock = createDataTransfer( { 'text/html': '

external content

' } ); + const contentInsertionSpy = sinon.spy(); + + clipboardPlugin.on( 'contentInsertion', ( evt, data ) => { + contentInsertionSpy( data.sourceEditorId ); + } ); + + viewDocument.fire( 'paste', { + dataTransfer: dataTransferMock, + preventDefault: () => {}, + stopPropagation: () => {} + } ); + + sinon.assert.calledWith( contentInsertionSpy, null ); + } ); + + it( 'should be propagated to contentInsertion event (when it\'s internal content)', () => { + const dataTransferMock = createDataTransfer( { + 'text/html': '

internal content

', + 'application/ckeditor5-editor-id': editor.id + } ); + + const contentInsertionSpy = sinon.spy(); + + clipboardPlugin.on( 'contentInsertion', ( evt, data ) => { + contentInsertionSpy( data.sourceEditorId ); + } ); + + viewDocument.fire( 'paste', { + dataTransfer: dataTransferMock, + preventDefault: () => {}, + stopPropagation: () => {} + } ); + + sinon.assert.calledWith( contentInsertionSpy, editor.id ); + } ); + } ); + function createDataTransfer( data ) { + const state = Object.create( data || {} ); + return { getData( type ) { - return data[ type ]; + return state[ type ]; + }, + setData( type, newData ) { + state[ type ] = newData; } }; } @@ -485,7 +601,6 @@ describe( 'ClipboardPipeline feature', () => { expect( data.dataTransfer ).to.equal( dataTransferMock ); expect( data.content ).is.instanceOf( ModelDocumentFragment ); expect( stringifyModel( data.content ) ).to.equal( 'bcde' ); - done(); } ); @@ -495,6 +610,25 @@ describe( 'ClipboardPipeline feature', () => { } ); } ); + it( 'triggers the conversion with the `isClipboardPipeline` flag', done => { + const dataTransferMock = createDataTransfer(); + const preventDefaultSpy = sinon.spy(); + const toViewSpy = sinon.spy( editor.data, 'toView' ); + + setModelData( editor.model, 'a[bcde]f' ); + + clipboardPlugin.on( 'outputTransformation', ( evt, data ) => { + expect( toViewSpy ).calledWithExactly( data.content, { isClipboardPipeline: true } ); + + done(); + }, { priority: 'lowest' } ); + + viewDocument.fire( 'copy', { + dataTransfer: dataTransferMock, + preventDefault: preventDefaultSpy + } ); + } ); + it( 'fires clipboardOutput for copy with the selected content and correct method', done => { const dataTransferMock = createDataTransfer(); const preventDefaultSpy = sinon.spy(); diff --git a/packages/ckeditor5-clipboard/tests/utils/viewtoplaintext.js b/packages/ckeditor5-clipboard/tests/utils/viewtoplaintext.js index 6f2859a7146..e60160bab9a 100644 --- a/packages/ckeditor5-clipboard/tests/utils/viewtoplaintext.js +++ b/packages/ckeditor5-clipboard/tests/utils/viewtoplaintext.js @@ -3,14 +3,26 @@ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options */ +import { DomConverter, StylesProcessor, ViewDocument, DowncastWriter } from '@ckeditor/ckeditor5-engine'; import viewToPlainText from '../../src/utils/viewtoplaintext.js'; import { parse as parseView } from '@ckeditor/ckeditor5-engine/src/dev-utils/view.js'; describe( 'viewToPlainText()', () => { + let converter, viewDocument; + + beforeEach( () => { + viewDocument = new ViewDocument( new StylesProcessor() ); + converter = new DomConverter( viewDocument ); + } ); + + afterEach( () => { + viewDocument.destroy(); + } ); + function testViewToPlainText( viewString, expectedText ) { const view = parseView( viewString ); - const text = viewToPlainText( view ); + const text = viewToPlainText( converter, view ); expect( text ).to.equal( expectedText ); } @@ -41,7 +53,7 @@ describe( 'viewToPlainText()', () => { const view = parseView( viewString ); view.getChild( 1 )._setCustomProperty( 'dataPipeline:transparentRendering', true ); - const text = viewToPlainText( view ); + const text = viewToPlainText( converter, view ); expect( text ).to.equal( expectedText ); } ); @@ -126,4 +138,14 @@ describe( 'viewToPlainText()', () => { 'Foo\n\nA\n\nB\n\nBar' ); } ); + + it( 'should convert a view RawElement', () => { + const writer = new DowncastWriter( viewDocument ); + const rawElement = writer.createRawElement( 'div', { 'data-foo': 'bar' }, function( domElement ) { + domElement.innerHTML = '

Foo


Bar

'; + } ); + const text = viewToPlainText( converter, rawElement ); + + expect( text ).to.equal( 'Foo\nBar' ); + } ); } ); diff --git a/packages/ckeditor5-clipboard/tsconfig.dist.json b/packages/ckeditor5-clipboard/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-clipboard/tsconfig.dist.json +++ b/packages/ckeditor5-clipboard/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-clipboard/tsconfig.json b/packages/ckeditor5-clipboard/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-clipboard/tsconfig.json +++ b/packages/ckeditor5-clipboard/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-cloud-services/package.json b/packages/ckeditor5-cloud-services/package.json index 05693feda0a..b7e8257725a 100644 --- a/packages/ckeditor5-cloud-services/package.json +++ b/packages/ckeditor5-cloud-services/package.json @@ -17,7 +17,7 @@ "ckeditor5": "44.1.0" }, "devDependencies": { - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-theme-lark": "44.1.0", "typescript": "5.0.4", diff --git a/packages/ckeditor5-cloud-services/tsconfig.dist.json b/packages/ckeditor5-cloud-services/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-cloud-services/tsconfig.dist.json +++ b/packages/ckeditor5-cloud-services/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-cloud-services/tsconfig.json b/packages/ckeditor5-cloud-services/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-cloud-services/tsconfig.json +++ b/packages/ckeditor5-cloud-services/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-code-block/ckeditor5-metadata.json b/packages/ckeditor5-code-block/ckeditor5-metadata.json index eae95f76f4f..a43d57f0923 100644 --- a/packages/ckeditor5-code-block/ckeditor5-metadata.json +++ b/packages/ckeditor5-code-block/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "codeBlock", - "iconPath": "@ckeditor/ckeditor5-icons/theme/code-block.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/code-block.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-code-block/docs/features/code-blocks.md b/packages/ckeditor5-code-block/docs/features/code-blocks.md index d2abbf45c2e..7c28c948a0d 100644 --- a/packages/ckeditor5-code-block/docs/features/code-blocks.md +++ b/packages/ckeditor5-code-block/docs/features/code-blocks.md @@ -11,7 +11,7 @@ The code block feature lets you insert and edit blocks of pre-formatted code. It ## Demo -Use the code block toolbar button {@icon @ckeditor/ckeditor5-core/theme/icons/codeblock.svg Insert code block} and the type dropdown to insert a desired code block. Alternatively, start a line with `` ``` ``, and the {@link features/autoformat autoformatting feature} will format it as a code block. To add a paragraph under a code block, simply press Enter three times. +Use the code block toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/code-block.svg Insert code block} and the type dropdown to insert a desired code block. Alternatively, start a line with `` ``` ``, and the {@link features/autoformat autoformatting feature} will format it as a code block. To add a paragraph under a code block, simply press Enter three times. {@snippet features/code-block} diff --git a/packages/ckeditor5-code-block/package.json b/packages/ckeditor5-code-block/package.json index 1bcb045ff3f..5ac01318e4e 100644 --- a/packages/ckeditor5-code-block/package.json +++ b/packages/ckeditor5-code-block/package.json @@ -17,6 +17,7 @@ "@ckeditor/ckeditor5-clipboard": "44.1.0", "@ckeditor/ckeditor5-engine": "44.1.0", "@ckeditor/ckeditor5-enter": "44.1.0", + "@ckeditor/ckeditor5-icons": "0.0.1", "@ckeditor/ckeditor5-ui": "44.1.0", "@ckeditor/ckeditor5-utils": "44.1.0", "ckeditor5": "44.1.0" @@ -26,7 +27,7 @@ "@ckeditor/ckeditor5-autoformat": "44.1.0", "@ckeditor/ckeditor5-basic-styles": "44.1.0", "@ckeditor/ckeditor5-block-quote": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-html-support": "44.1.0", "@ckeditor/ckeditor5-image": "44.1.0", diff --git a/packages/ckeditor5-code-block/src/codeblockui.ts b/packages/ckeditor5-code-block/src/codeblockui.ts index a8485995ef3..605e80b0db0 100644 --- a/packages/ckeditor5-code-block/src/codeblockui.ts +++ b/packages/ckeditor5-code-block/src/codeblockui.ts @@ -7,7 +7,7 @@ * @module code-block/codeblockui */ -import { icons, Plugin } from 'ckeditor5/src/core.js'; +import { Plugin } from 'ckeditor5/src/core.js'; import { Collection } from 'ckeditor5/src/utils.js'; import { ViewModel, @@ -20,6 +20,7 @@ import { MenuBarMenuListItemView, type ListDropdownButtonDefinition } from 'ckeditor5/src/ui.js'; +import { IconCodeBlock } from 'ckeditor5/src/icons.js'; import { getNormalizedAndLocalizedLanguageDefinitions } from './utils.js'; @@ -67,7 +68,7 @@ export default class CodeBlockUI extends Plugin { splitButtonView.set( { label: accessibleLabel, tooltip: true, - icon: icons.codeBlock, + icon: IconCodeBlock, isToggleable: true } ); @@ -107,7 +108,7 @@ export default class CodeBlockUI extends Plugin { menuView.buttonView.set( { role: 'menuitem', label: t( 'Code block' ), - icon: icons.codeBlock + icon: IconCodeBlock } ); menuView.bind( 'isEnabled' ).to( command ); diff --git a/packages/ckeditor5-code-block/tests/codeblockediting.js b/packages/ckeditor5-code-block/tests/codeblockediting.js index 6bfb6ad0d6d..e210ec4d8fc 100644 --- a/packages/ckeditor5-code-block/tests/codeblockediting.js +++ b/packages/ckeditor5-code-block/tests/codeblockediting.js @@ -1682,7 +1682,7 @@ describe( 'CodeBlockEditing', () => { '[]o' + '' ); - sinon.assert.calledOnce( dataTransferMock.getData ); + sinon.assert.calledTwice( dataTransferMock.getData ); // Make sure that ClipboardPipeline was not interrupted. sinon.assert.calledOnce( contentInsertionSpy ); @@ -1723,7 +1723,7 @@ describe( 'CodeBlockEditing', () => { 'bar' ); - sinon.assert.calledOnce( dataTransferMock.getData ); + sinon.assert.calledTwice( dataTransferMock.getData ); // Make sure that ClipboardPipeline was not interrupted. sinon.assert.calledOnce( contentInsertionSpy ); diff --git a/packages/ckeditor5-code-block/tests/codeblockui.js b/packages/ckeditor5-code-block/tests/codeblockui.js index f8e25bc84b6..795400b35f0 100644 --- a/packages/ckeditor5-code-block/tests/codeblockui.js +++ b/packages/ckeditor5-code-block/tests/codeblockui.js @@ -8,7 +8,7 @@ import CodeBlockEditing from '../src/codeblockediting.js'; import CodeBlockUI from '../src/codeblockui.js'; -import { icons } from 'ckeditor5/src/core.js'; +import { IconCodeBlock } from 'ckeditor5/src/icons.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; import { _clear as clearTranslations, add as addTranslations } from '@ckeditor/ckeditor5-utils/src/translation-service.js'; @@ -83,7 +83,7 @@ describe( 'CodeBlockUI', () => { it( 'has the base properties', () => { expect( button ).to.have.property( 'label', 'Insert code block' ); - expect( button ).to.have.property( 'icon', icons.codeBlock ); + expect( button ).to.have.property( 'icon', IconCodeBlock ); expect( button ).to.have.property( 'tooltip', true ); expect( button ).to.have.property( 'isToggleable', true ); } ); diff --git a/packages/ckeditor5-code-block/tsconfig.dist.json b/packages/ckeditor5-code-block/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-code-block/tsconfig.dist.json +++ b/packages/ckeditor5-code-block/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-code-block/tsconfig.json b/packages/ckeditor5-code-block/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-code-block/tsconfig.json +++ b/packages/ckeditor5-code-block/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-core/package.json b/packages/ckeditor5-core/package.json index bacd369f9c2..6768bee5070 100644 --- a/packages/ckeditor5-core/package.json +++ b/packages/ckeditor5-core/package.json @@ -25,6 +25,7 @@ "main": "src/index.ts", "dependencies": { "@ckeditor/ckeditor5-engine": "44.1.0", + "@ckeditor/ckeditor5-ui": "44.1.0", "@ckeditor/ckeditor5-utils": "44.1.0", "@ckeditor/ckeditor5-watchdog": "44.1.0", "lodash-es": "4.17.21" @@ -43,7 +44,6 @@ "@ckeditor/ckeditor5-media-embed": "44.1.0", "@ckeditor/ckeditor5-paragraph": "44.1.0", "@ckeditor/ckeditor5-table": "44.1.0", - "@ckeditor/ckeditor5-ui": "44.1.0", "typescript": "5.0.4", "webpack": "^5.94.0", "webpack-cli": "^5.1.4" diff --git a/packages/ckeditor5-core/tsconfig.dist.json b/packages/ckeditor5-core/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-core/tsconfig.dist.json +++ b/packages/ckeditor5-core/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-core/tsconfig.json b/packages/ckeditor5-core/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-core/tsconfig.json +++ b/packages/ckeditor5-core/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-easy-image/package.json b/packages/ckeditor5-easy-image/package.json index afc326103d9..07ef2a3991e 100644 --- a/packages/ckeditor5-easy-image/package.json +++ b/packages/ckeditor5-easy-image/package.json @@ -13,6 +13,7 @@ "type": "module", "main": "src/index.ts", "dependencies": { + "@ckeditor/ckeditor5-cloud-services": "44.1.0", "@ckeditor/ckeditor5-core": "44.1.0", "@ckeditor/ckeditor5-upload": "44.1.0", "@ckeditor/ckeditor5-utils": "44.1.0", @@ -20,8 +21,7 @@ }, "devDependencies": { "@ckeditor/ckeditor5-clipboard": "44.1.0", - "@ckeditor/ckeditor5-cloud-services": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-image": "44.1.0", "@ckeditor/ckeditor5-paragraph": "44.1.0", diff --git a/packages/ckeditor5-easy-image/tsconfig.dist.json b/packages/ckeditor5-easy-image/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-easy-image/tsconfig.dist.json +++ b/packages/ckeditor5-easy-image/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-easy-image/tsconfig.json b/packages/ckeditor5-easy-image/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-easy-image/tsconfig.json +++ b/packages/ckeditor5-easy-image/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-editor-balloon/package.json b/packages/ckeditor5-editor-balloon/package.json index 0dc961b7a6e..180808badc2 100644 --- a/packages/ckeditor5-editor-balloon/package.json +++ b/packages/ckeditor5-editor-balloon/package.json @@ -21,7 +21,7 @@ }, "devDependencies": { "@ckeditor/ckeditor5-basic-styles": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-enter": "44.1.0", "@ckeditor/ckeditor5-heading": "44.1.0", "@ckeditor/ckeditor5-image": "44.1.0", diff --git a/packages/ckeditor5-editor-balloon/tsconfig.dist.json b/packages/ckeditor5-editor-balloon/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-editor-balloon/tsconfig.dist.json +++ b/packages/ckeditor5-editor-balloon/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-editor-balloon/tsconfig.json b/packages/ckeditor5-editor-balloon/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-editor-balloon/tsconfig.json +++ b/packages/ckeditor5-editor-balloon/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-editor-classic/package.json b/packages/ckeditor5-editor-classic/package.json index 059616b2803..5aa1be063d3 100644 --- a/packages/ckeditor5-editor-classic/package.json +++ b/packages/ckeditor5-editor-classic/package.json @@ -21,7 +21,7 @@ }, "devDependencies": { "@ckeditor/ckeditor5-basic-styles": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-enter": "44.1.0", "@ckeditor/ckeditor5-heading": "44.1.0", "@ckeditor/ckeditor5-image": "44.1.0", diff --git a/packages/ckeditor5-editor-classic/tsconfig.dist.json b/packages/ckeditor5-editor-classic/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-editor-classic/tsconfig.dist.json +++ b/packages/ckeditor5-editor-classic/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-editor-classic/tsconfig.json b/packages/ckeditor5-editor-classic/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-editor-classic/tsconfig.json +++ b/packages/ckeditor5-editor-classic/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-editor-decoupled/package.json b/packages/ckeditor5-editor-decoupled/package.json index 1fbd2caae0d..b308bb7d501 100644 --- a/packages/ckeditor5-editor-decoupled/package.json +++ b/packages/ckeditor5-editor-decoupled/package.json @@ -21,7 +21,7 @@ }, "devDependencies": { "@ckeditor/ckeditor5-basic-styles": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-enter": "44.1.0", "@ckeditor/ckeditor5-heading": "44.1.0", "@ckeditor/ckeditor5-image": "44.1.0", diff --git a/packages/ckeditor5-editor-decoupled/tsconfig.dist.json b/packages/ckeditor5-editor-decoupled/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-editor-decoupled/tsconfig.dist.json +++ b/packages/ckeditor5-editor-decoupled/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-editor-decoupled/tsconfig.json b/packages/ckeditor5-editor-decoupled/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-editor-decoupled/tsconfig.json +++ b/packages/ckeditor5-editor-decoupled/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-editor-inline/package.json b/packages/ckeditor5-editor-inline/package.json index f03c5331c5c..766d910f394 100644 --- a/packages/ckeditor5-editor-inline/package.json +++ b/packages/ckeditor5-editor-inline/package.json @@ -21,7 +21,7 @@ }, "devDependencies": { "@ckeditor/ckeditor5-basic-styles": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-enter": "44.1.0", "@ckeditor/ckeditor5-heading": "44.1.0", "@ckeditor/ckeditor5-image": "44.1.0", diff --git a/packages/ckeditor5-editor-inline/tsconfig.dist.json b/packages/ckeditor5-editor-inline/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-editor-inline/tsconfig.dist.json +++ b/packages/ckeditor5-editor-inline/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-editor-inline/tsconfig.json b/packages/ckeditor5-editor-inline/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-editor-inline/tsconfig.json +++ b/packages/ckeditor5-editor-inline/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-editor-multi-root/package.json b/packages/ckeditor5-editor-multi-root/package.json index 3381c639282..85ad5956d99 100644 --- a/packages/ckeditor5-editor-multi-root/package.json +++ b/packages/ckeditor5-editor-multi-root/package.json @@ -21,7 +21,7 @@ }, "devDependencies": { "@ckeditor/ckeditor5-basic-styles": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-enter": "44.1.0", "@ckeditor/ckeditor5-heading": "44.1.0", "@ckeditor/ckeditor5-paragraph": "44.1.0", diff --git a/packages/ckeditor5-editor-multi-root/tsconfig.dist.json b/packages/ckeditor5-editor-multi-root/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-editor-multi-root/tsconfig.dist.json +++ b/packages/ckeditor5-editor-multi-root/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-editor-multi-root/tsconfig.json b/packages/ckeditor5-editor-multi-root/tsconfig.json index 11ce5be5a65..890e077e061 100644 --- a/packages/ckeditor5-editor-multi-root/tsconfig.json +++ b/packages/ckeditor5-editor-multi-root/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-engine/src/index.ts b/packages/ckeditor5-engine/src/index.ts index e414ebb7b67..5bf02a8fb5f 100644 --- a/packages/ckeditor5-engine/src/index.ts +++ b/packages/ckeditor5-engine/src/index.ts @@ -106,6 +106,7 @@ export type { SchemaChildCheckCallback, AttributeProperties, SchemaItemDefinition, + SchemaCompiledItemDefinition, SchemaContext, SchemaContextDefinition } from './model/schema.js'; diff --git a/packages/ckeditor5-engine/tsconfig.dist.json b/packages/ckeditor5-engine/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-engine/tsconfig.dist.json +++ b/packages/ckeditor5-engine/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-engine/tsconfig.json b/packages/ckeditor5-engine/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-engine/tsconfig.json +++ b/packages/ckeditor5-engine/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-enter/tsconfig.dist.json b/packages/ckeditor5-enter/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-enter/tsconfig.dist.json +++ b/packages/ckeditor5-enter/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-enter/tsconfig.json b/packages/ckeditor5-enter/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-enter/tsconfig.json +++ b/packages/ckeditor5-enter/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-essentials/package.json b/packages/ckeditor5-essentials/package.json index 072182f0299..698d08a028d 100644 --- a/packages/ckeditor5-essentials/package.json +++ b/packages/ckeditor5-essentials/package.json @@ -23,7 +23,7 @@ "ckeditor5": "44.1.0" }, "devDependencies": { - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-paragraph": "44.1.0", "@ckeditor/ckeditor5-theme-lark": "44.1.0", diff --git a/packages/ckeditor5-essentials/tsconfig.dist.json b/packages/ckeditor5-essentials/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-essentials/tsconfig.dist.json +++ b/packages/ckeditor5-essentials/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-essentials/tsconfig.json b/packages/ckeditor5-essentials/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-essentials/tsconfig.json +++ b/packages/ckeditor5-essentials/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-find-and-replace/ckeditor5-metadata.json b/packages/ckeditor5-find-and-replace/ckeditor5-metadata.json index c3ffdadf400..0d11fef8368 100644 --- a/packages/ckeditor5-find-and-replace/ckeditor5-metadata.json +++ b/packages/ckeditor5-find-and-replace/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "findAndReplace", - "iconPath": "@ckeditor/ckeditor5-icons/theme/find-replace.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/find-replace.svg" } ] } diff --git a/packages/ckeditor5-find-and-replace/docs/features/find-and-replace.md b/packages/ckeditor5-find-and-replace/docs/features/find-and-replace.md index 6ddc232f4fe..eceae761465 100644 --- a/packages/ckeditor5-find-and-replace/docs/features/find-and-replace.md +++ b/packages/ckeditor5-find-and-replace/docs/features/find-and-replace.md @@ -11,7 +11,7 @@ The find and replace feature lets you find and replace any text in your document ## Demo -Use the find and replace toolbar button {@icon @ckeditor/ckeditor5-find-and-replace/theme/icons/find-replace.svg Find and replace} to open the search dialog. Use it to find and replace words or phrases. You can also use the Ctrl/Cmd+F keyboard shortcut. Try replacing "AI" with "artificial intelligence" to make the content appeal to less tech-savvy users. Be careful to match the case! +Use the find and replace toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/find-replace.svg Find and replace} to open the search dialog. Use it to find and replace words or phrases. You can also use the Ctrl/Cmd+F keyboard shortcut. Try replacing "AI" with "artificial intelligence" to make the content appeal to less tech-savvy users. Be careful to match the case! {@snippet features/find-and-replace} diff --git a/packages/ckeditor5-find-and-replace/package.json b/packages/ckeditor5-find-and-replace/package.json index d63d6561f6a..054d7cde258 100644 --- a/packages/ckeditor5-find-and-replace/package.json +++ b/packages/ckeditor5-find-and-replace/package.json @@ -14,13 +14,14 @@ "main": "src/index.ts", "dependencies": { "@ckeditor/ckeditor5-core": "44.1.0", + "@ckeditor/ckeditor5-icons": "0.0.1", "@ckeditor/ckeditor5-ui": "44.1.0", "@ckeditor/ckeditor5-utils": "44.1.0", "ckeditor5": "44.1.0", "lodash-es": "4.17.21" }, "devDependencies": { - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-basic-styles": "44.1.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-editor-decoupled": "44.1.0", diff --git a/packages/ckeditor5-find-and-replace/src/ui/findandreplaceformview.ts b/packages/ckeditor5-find-and-replace/src/ui/findandreplaceformview.ts index 31fa11fd5a9..c52480c47ee 100644 --- a/packages/ckeditor5-find-and-replace/src/ui/findandreplaceformview.ts +++ b/packages/ckeditor5-find-and-replace/src/ui/findandreplaceformview.ts @@ -36,7 +36,7 @@ import { // eslint-disable-next-line ckeditor5-rules/ckeditor-imports import '@ckeditor/ckeditor5-ui/theme/components/responsive-form/responsiveform.css'; import '../../theme/findandreplaceform.css'; -import { icons } from 'ckeditor5/src/core.js'; +import { IconPreviousArrow } from 'ckeditor5/src/icons.js'; /** * The find and replace form view class. @@ -257,7 +257,7 @@ export default class FindAndReplaceFormView extends View { this._findPrevButtonView = this._createButton( { label: t( 'Previous result' ), class: 'ck-button-prev', - icon: icons.previousArrow, + icon: IconPreviousArrow, keystroke: 'Shift+F3', tooltip: true } ); @@ -265,7 +265,7 @@ export default class FindAndReplaceFormView extends View { this._findNextButtonView = this._createButton( { label: t( 'Next result' ), class: 'ck-button-next', - icon: icons.previousArrow, + icon: IconPreviousArrow, keystroke: 'F3', tooltip: true } ); diff --git a/packages/ckeditor5-find-and-replace/tests/ui/findandreplaceformview.js b/packages/ckeditor5-find-and-replace/tests/ui/findandreplaceformview.js index 3a7c2523135..5b9dfd63b27 100644 --- a/packages/ckeditor5-find-and-replace/tests/ui/findandreplaceformview.js +++ b/packages/ckeditor5-find-and-replace/tests/ui/findandreplaceformview.js @@ -26,7 +26,7 @@ import FindAndReplace from '../../src/findandreplace.js'; import FindAndReplaceFormView from '../../src/ui/findandreplaceformview.js'; import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils.js'; -import { icons } from 'ckeditor5/src/core.js'; +import { IconPreviousArrow } from 'ckeditor5/src/icons.js'; describe( 'FindAndReplaceFormView', () => { let view; @@ -135,7 +135,7 @@ describe( 'FindAndReplaceFormView', () => { } ); it( 'should have an icon', () => { - expect( view._findPrevButtonView.icon ).to.equal( icons.previousArrow ); + expect( view._findPrevButtonView.icon ).to.equal( IconPreviousArrow ); } ); it( 'should have a tooltip', () => { @@ -157,7 +157,7 @@ describe( 'FindAndReplaceFormView', () => { } ); it( 'should have an icon', () => { - expect( view._findNextButtonView.icon ).to.equal( icons.previousArrow ); + expect( view._findNextButtonView.icon ).to.equal( IconPreviousArrow ); } ); it( 'should have a tooltip', () => { diff --git a/packages/ckeditor5-find-and-replace/tsconfig.dist.json b/packages/ckeditor5-find-and-replace/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-find-and-replace/tsconfig.dist.json +++ b/packages/ckeditor5-find-and-replace/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-find-and-replace/tsconfig.json b/packages/ckeditor5-find-and-replace/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-find-and-replace/tsconfig.json +++ b/packages/ckeditor5-find-and-replace/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-font/ckeditor5-metadata.json b/packages/ckeditor5-font/ckeditor5-metadata.json index e8831ef1019..8fb894a2b20 100644 --- a/packages/ckeditor5-font/ckeditor5-metadata.json +++ b/packages/ckeditor5-font/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "SplitButton", "name": "fontBackgroundColor", - "iconPath": "@ckeditor/ckeditor5-icons/theme/font-background.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/font-background.svg" } ], "htmlOutput": [ @@ -30,7 +30,7 @@ { "type": "SplitButton", "name": "fontColor", - "iconPath": "@ckeditor/ckeditor5-icons/theme/font-color.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/font-color.svg" } ], "htmlOutput": [ @@ -50,7 +50,7 @@ { "type": "SplitButton", "name": "fontSize", - "iconPath": "@ckeditor/ckeditor5-icons/theme/font-size.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/font-size.svg" } ], "htmlOutput": [ @@ -89,7 +89,7 @@ { "type": "SplitButton", "name": "fontFamily", - "iconPath": "@ckeditor/ckeditor5-icons/theme/font-family.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/font-family.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-font/docs/features/font.md b/packages/ckeditor5-font/docs/features/font.md index 55435bcb402..35dd3ab65b4 100644 --- a/packages/ckeditor5-font/docs/features/font.md +++ b/packages/ckeditor5-font/docs/features/font.md @@ -10,7 +10,7 @@ The font feature lets you change font family, size, and color (including backgro ## Demo -Use the toolbar dropdowns in the demo below to control the font size {@icon @ckeditor/ckeditor5-font/theme/icons/font-size.svg Font size} and font family {@icon @ckeditor/ckeditor5-font/theme/icons/font-family.svg Font family}. You can also change both the font color {@icon @ckeditor/ckeditor5-font/theme/icons/font-color.svg Font color} and the font background color {@icon @ckeditor/ckeditor5-font/theme/icons/font-background.svg Font background color} with predefined palette or color picker {@icon @ckeditor/ckeditor5-core/theme/icons/color-palette.svg Color picker}. +Use the toolbar dropdowns in the demo below to control the font size {@icon @ckeditor/ckeditor5-icons/theme/icons/font-size.svg Font size} and font family {@icon @ckeditor/ckeditor5-icons/theme/icons/font-family.svg Font family}. You can also change both the font color {@icon @ckeditor/ckeditor5-icons/theme/icons/font-color.svg Font color} and the font background color {@icon @ckeditor/ckeditor5-icons/theme/icons/font-background.svg Font background color} with predefined palette or color picker {@icon @ckeditor/ckeditor5-icons/theme/icons/color-palette.svg Color picker}. {@snippet features/font} diff --git a/packages/ckeditor5-font/package.json b/packages/ckeditor5-font/package.json index 74a8ec7defb..1000ac657ca 100644 --- a/packages/ckeditor5-font/package.json +++ b/packages/ckeditor5-font/package.json @@ -15,13 +15,14 @@ "dependencies": { "@ckeditor/ckeditor5-core": "44.1.0", "@ckeditor/ckeditor5-engine": "44.1.0", + "@ckeditor/ckeditor5-icons": "0.0.1", "@ckeditor/ckeditor5-ui": "44.1.0", "@ckeditor/ckeditor5-utils": "44.1.0", "ckeditor5": "44.1.0" }, "devDependencies": { "@ckeditor/ckeditor5-undo": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-highlight": "44.1.0", "@ckeditor/ckeditor5-paragraph": "44.1.0", diff --git a/packages/ckeditor5-font/src/index.ts b/packages/ckeditor5-font/src/index.ts index 7a6bf93d38f..e66688a09c2 100644 --- a/packages/ckeditor5-font/src/index.ts +++ b/packages/ckeditor5-font/src/index.ts @@ -29,7 +29,8 @@ export type { FONT_BACKGROUND_COLOR, FONT_COLOR, FONT_FAMILY, - FONT_SIZE + FONT_SIZE, + ColorSelectorDropdownView } from './utils.js'; export type { diff --git a/packages/ckeditor5-font/tsconfig.dist.json b/packages/ckeditor5-font/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-font/tsconfig.dist.json +++ b/packages/ckeditor5-font/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-font/tsconfig.json b/packages/ckeditor5-font/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-font/tsconfig.json +++ b/packages/ckeditor5-font/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-heading/package.json b/packages/ckeditor5-heading/package.json index ff3f46f8aa2..de41cc5fb85 100644 --- a/packages/ckeditor5-heading/package.json +++ b/packages/ckeditor5-heading/package.json @@ -15,6 +15,7 @@ "dependencies": { "@ckeditor/ckeditor5-core": "44.1.0", "@ckeditor/ckeditor5-engine": "44.1.0", + "@ckeditor/ckeditor5-icons": "0.0.1", "@ckeditor/ckeditor5-paragraph": "44.1.0", "@ckeditor/ckeditor5-ui": "44.1.0", "@ckeditor/ckeditor5-utils": "44.1.0", @@ -25,7 +26,7 @@ "@ckeditor/ckeditor5-basic-styles": "44.1.0", "@ckeditor/ckeditor5-block-quote": "44.1.0", "@ckeditor/ckeditor5-clipboard": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-editor-multi-root": "44.1.0", "@ckeditor/ckeditor5-enter": "44.1.0", diff --git a/packages/ckeditor5-heading/src/headingbuttonsui.ts b/packages/ckeditor5-heading/src/headingbuttonsui.ts index 845a340fb52..7e9e4f60e58 100644 --- a/packages/ckeditor5-heading/src/headingbuttonsui.ts +++ b/packages/ckeditor5-heading/src/headingbuttonsui.ts @@ -7,20 +7,21 @@ * @module heading/headingbuttonsui */ -import { icons, Plugin } from 'ckeditor5/src/core.js'; +import { Plugin } from 'ckeditor5/src/core.js'; import { ButtonView } from 'ckeditor5/src/ui.js'; +import { IconHeading1, IconHeading2, IconHeading3, IconHeading4, IconHeading5, IconHeading6 } from 'ckeditor5/src/icons.js'; import { getLocalizedOptions } from './utils.js'; import type { HeadingOption } from './headingconfig.js'; import type HeadingCommand from './headingcommand.js'; const defaultIcons: Record = /* #__PURE__ */ ( () => ( { - heading1: icons.heading1, - heading2: icons.heading2, - heading3: icons.heading3, - heading4: icons.heading4, - heading5: icons.heading5, - heading6: icons.heading6 + heading1: IconHeading1, + heading2: IconHeading2, + heading3: IconHeading3, + heading4: IconHeading4, + heading5: IconHeading5, + heading6: IconHeading6 } ) )(); /** diff --git a/packages/ckeditor5-heading/tests/headingbuttonsui.js b/packages/ckeditor5-heading/tests/headingbuttonsui.js index 00e9d5c7050..ecf4bd440af 100644 --- a/packages/ckeditor5-heading/tests/headingbuttonsui.js +++ b/packages/ckeditor5-heading/tests/headingbuttonsui.js @@ -5,7 +5,7 @@ /* globals document */ -import { icons } from 'ckeditor5/src/core.js'; +import { IconHeading2 } from 'ckeditor5/src/icons.js'; import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor.js'; import HeadingEditing from '../src/headingediting.js'; import HeadingButtonsUI from '../src/headingbuttonsui.js'; @@ -67,7 +67,7 @@ describe( 'HeadingButtonUI', () => { const heading2Button = editor.ui.componentFactory.create( 'heading2' ); expect( heading2Button.label ).to.equal( localizedOptions.title ); - expect( heading2Button.icon ).to.equal( icons.heading2 ); + expect( heading2Button.icon ).to.equal( IconHeading2 ); expect( heading2Button.tooltip ).to.equal( true ); } ); diff --git a/packages/ckeditor5-heading/tsconfig.dist.json b/packages/ckeditor5-heading/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-heading/tsconfig.dist.json +++ b/packages/ckeditor5-heading/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-heading/tsconfig.json b/packages/ckeditor5-heading/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-heading/tsconfig.json +++ b/packages/ckeditor5-heading/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-highlight/ckeditor5-metadata.json b/packages/ckeditor5-highlight/ckeditor5-metadata.json index 28333cb9baf..32a9d32d0af 100644 --- a/packages/ckeditor5-highlight/ckeditor5-metadata.json +++ b/packages/ckeditor5-highlight/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "SplitButton", "name": "highlight", - "iconPath": "@ckeditor/ckeditor5-icons/theme/pen.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/pen.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-highlight/docs/features/highlight.md b/packages/ckeditor5-highlight/docs/features/highlight.md index 1e91a46e3fa..0b0d3a97b0e 100644 --- a/packages/ckeditor5-highlight/docs/features/highlight.md +++ b/packages/ckeditor5-highlight/docs/features/highlight.md @@ -11,7 +11,7 @@ The highlight feature lets you mark text fragments with different colors. You ca ## Demo -Select the text you want to highlight. Then use the highlight toolbar button {@icon @ckeditor/ckeditor5-highlight/theme/icons/marker.svg Highlight} to choose a desired color from the dropdown. +Select the text you want to highlight. Then use the highlight toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/marker.svg Highlight} to choose a desired color from the dropdown. {@snippet features/highlight} diff --git a/packages/ckeditor5-highlight/package.json b/packages/ckeditor5-highlight/package.json index 16cf988fc1c..0d94d0f40b7 100644 --- a/packages/ckeditor5-highlight/package.json +++ b/packages/ckeditor5-highlight/package.json @@ -14,12 +14,14 @@ "main": "src/index.ts", "dependencies": { "@ckeditor/ckeditor5-core": "44.1.0", + "@ckeditor/ckeditor5-icons": "0.0.1", "@ckeditor/ckeditor5-ui": "44.1.0", + "@ckeditor/ckeditor5-utils": "44.1.0", "ckeditor5": "44.1.0" }, "devDependencies": { "@ckeditor/ckeditor5-block-quote": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-engine": "44.1.0", "@ckeditor/ckeditor5-enter": "44.1.0", @@ -29,7 +31,6 @@ "@ckeditor/ckeditor5-paragraph": "44.1.0", "@ckeditor/ckeditor5-theme-lark": "44.1.0", "@ckeditor/ckeditor5-typing": "44.1.0", - "@ckeditor/ckeditor5-utils": "44.1.0", "typescript": "5.0.4", "webpack": "^5.94.0", "webpack-cli": "^5.1.4" diff --git a/packages/ckeditor5-highlight/tsconfig.dist.json b/packages/ckeditor5-highlight/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-highlight/tsconfig.dist.json +++ b/packages/ckeditor5-highlight/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-highlight/tsconfig.json b/packages/ckeditor5-highlight/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-highlight/tsconfig.json +++ b/packages/ckeditor5-highlight/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-horizontal-line/ckeditor5-metadata.json b/packages/ckeditor5-horizontal-line/ckeditor5-metadata.json index cd616859256..9758d79b2d0 100644 --- a/packages/ckeditor5-horizontal-line/ckeditor5-metadata.json +++ b/packages/ckeditor5-horizontal-line/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "horizontalLine", - "iconPath": "@ckeditor/ckeditor5-icons/theme/horizontal-line.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/horizontal-line.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-horizontal-line/docs/features/horizontal-line.md b/packages/ckeditor5-horizontal-line/docs/features/horizontal-line.md index ed20506b048..85aadf0e144 100644 --- a/packages/ckeditor5-horizontal-line/docs/features/horizontal-line.md +++ b/packages/ckeditor5-horizontal-line/docs/features/horizontal-line.md @@ -10,7 +10,7 @@ The horizontal line feature lets you visually divide your content into sections ## Demo -To insert a horizontal line in the demo below, use the toolbar button {@icon @ckeditor/ckeditor5-core/theme/icons/horizontalline.svg Horizontal line}. Alternatively, start a new line with `---`. The {@link features/autoformat autoformatting feature} will turn it into a horizontal line. +To insert a horizontal line in the demo below, use the toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/horizontal-line.svg Horizontal line}. Alternatively, start a new line with `---`. The {@link features/autoformat autoformatting feature} will turn it into a horizontal line. {@snippet features/horizontal-line} diff --git a/packages/ckeditor5-horizontal-line/package.json b/packages/ckeditor5-horizontal-line/package.json index 2b280935475..9e0b105f8da 100644 --- a/packages/ckeditor5-horizontal-line/package.json +++ b/packages/ckeditor5-horizontal-line/package.json @@ -14,20 +14,21 @@ "main": "src/index.ts", "dependencies": { "@ckeditor/ckeditor5-core": "44.1.0", + "@ckeditor/ckeditor5-icons": "0.0.1", "@ckeditor/ckeditor5-ui": "44.1.0", + "@ckeditor/ckeditor5-utils": "44.1.0", "@ckeditor/ckeditor5-widget": "44.1.0", "ckeditor5": "44.1.0" }, "devDependencies": { "@ckeditor/ckeditor5-cloud-services": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-easy-image": "44.1.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-engine": "44.1.0", "@ckeditor/ckeditor5-image": "44.1.0", "@ckeditor/ckeditor5-paragraph": "44.1.0", "@ckeditor/ckeditor5-theme-lark": "44.1.0", - "@ckeditor/ckeditor5-utils": "44.1.0", "typescript": "5.0.4", "webpack": "^5.94.0", "webpack-cli": "^5.1.4" diff --git a/packages/ckeditor5-horizontal-line/src/horizontallineui.ts b/packages/ckeditor5-horizontal-line/src/horizontallineui.ts index a2c8288047b..299a5709f1a 100644 --- a/packages/ckeditor5-horizontal-line/src/horizontallineui.ts +++ b/packages/ckeditor5-horizontal-line/src/horizontallineui.ts @@ -7,7 +7,8 @@ * @module horizontal-line/horizontallineui */ -import { icons, Plugin } from 'ckeditor5/src/core.js'; +import { Plugin } from 'ckeditor5/src/core.js'; +import { IconHorizontalLine } from 'ckeditor5/src/icons.js'; import { ButtonView, MenuBarMenuListItemButtonView } from 'ckeditor5/src/ui.js'; import type HorizontalLineCommand from './horizontallinecommand.js'; @@ -64,7 +65,7 @@ export default class HorizontalLineUI extends Plugin { view.set( { label: t( 'Horizontal line' ), - icon: icons.horizontalLine + icon: IconHorizontalLine } ); view.bind( 'isEnabled' ).to( command, 'isEnabled' ); diff --git a/packages/ckeditor5-horizontal-line/tests/horizontallineui.js b/packages/ckeditor5-horizontal-line/tests/horizontallineui.js index 34735030a40..384a670f36f 100644 --- a/packages/ckeditor5-horizontal-line/tests/horizontallineui.js +++ b/packages/ckeditor5-horizontal-line/tests/horizontallineui.js @@ -10,7 +10,7 @@ import HorizontalLineEditing from '../src/horizontallineediting.js'; import HorizontalLineUI from '../src/horizontallineui.js'; import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview.js'; import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils.js'; -import { icons } from 'ckeditor5/src/core.js'; +import { IconHorizontalLine } from 'ckeditor5/src/icons.js'; import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph.js'; import { MenuBarMenuListItemButtonView } from '@ckeditor/ckeditor5-ui'; @@ -76,7 +76,7 @@ describe( 'HorizontalLineUI', () => { it( 'should create UI component with correct attribute values', () => { expect( button.isOn ).to.be.false; expect( button.label ).to.equal( label ); - expect( button.icon ).to.equal( icons.horizontalLine ); + expect( button.icon ).to.equal( IconHorizontalLine ); } ); it( `should execute ${ featureName } command on model execute event and focus the view`, () => { diff --git a/packages/ckeditor5-horizontal-line/tsconfig.dist.json b/packages/ckeditor5-horizontal-line/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-horizontal-line/tsconfig.dist.json +++ b/packages/ckeditor5-horizontal-line/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-horizontal-line/tsconfig.json b/packages/ckeditor5-horizontal-line/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-horizontal-line/tsconfig.json +++ b/packages/ckeditor5-horizontal-line/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-html-embed/ckeditor5-metadata.json b/packages/ckeditor5-html-embed/ckeditor5-metadata.json index 6ddb85ad92f..ea9e5695e4b 100644 --- a/packages/ckeditor5-html-embed/ckeditor5-metadata.json +++ b/packages/ckeditor5-html-embed/ckeditor5-metadata.json @@ -10,7 +10,7 @@ { "type": "Button", "name": "htmlEmbed", - "iconPath": "@ckeditor/ckeditor5-icons/theme/html.svg" + "iconPath": "@ckeditor/ckeditor5-icons/theme/icons/html.svg" } ], "htmlOutput": [ diff --git a/packages/ckeditor5-html-embed/docs/features/html-embed.md b/packages/ckeditor5-html-embed/docs/features/html-embed.md index ee5a6a1ffb0..0a7a4d6b176 100644 --- a/packages/ckeditor5-html-embed/docs/features/html-embed.md +++ b/packages/ckeditor5-html-embed/docs/features/html-embed.md @@ -11,7 +11,7 @@ The HTML embed feature lets you embed any HTML snippet in your content. The feat ## Demo -Use the HTML embed toolbar button {@icon @ckeditor/ckeditor5-core/theme/icons/html.svg HTML embed} in the editor below to see the plugin in action. Click the "Preview editor data" button under the editor to preview the editor content, including the embedded HTML. +Use the HTML embed toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/html.svg HTML embed} in the editor below to see the plugin in action. Click the "Preview editor data" button under the editor to preview the editor content, including the embedded HTML. {@snippet features/html-embed} diff --git a/packages/ckeditor5-html-embed/package.json b/packages/ckeditor5-html-embed/package.json index a58d31bf4da..4bcbb240f0f 100644 --- a/packages/ckeditor5-html-embed/package.json +++ b/packages/ckeditor5-html-embed/package.json @@ -14,6 +14,7 @@ "main": "src/index.ts", "dependencies": { "@ckeditor/ckeditor5-core": "44.1.0", + "@ckeditor/ckeditor5-icons": "0.0.1", "@ckeditor/ckeditor5-ui": "44.1.0", "@ckeditor/ckeditor5-utils": "44.1.0", "@ckeditor/ckeditor5-widget": "44.1.0", @@ -21,7 +22,7 @@ }, "devDependencies": { "@ckeditor/ckeditor5-basic-styles": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-clipboard": "44.1.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-engine": "44.1.0", diff --git a/packages/ckeditor5-html-embed/src/htmlembedediting.ts b/packages/ckeditor5-html-embed/src/htmlembedediting.ts index 8cb184b300c..de3e17ccadd 100644 --- a/packages/ckeditor5-html-embed/src/htmlembedediting.ts +++ b/packages/ckeditor5-html-embed/src/htmlembedediting.ts @@ -7,10 +7,11 @@ * @module html-embed/htmlembedediting */ -import { Plugin, icons, type Editor } from 'ckeditor5/src/core.js'; +import { Plugin, type Editor } from 'ckeditor5/src/core.js'; import { ButtonView } from 'ckeditor5/src/ui.js'; import { toWidget } from 'ckeditor5/src/widget.js'; import { logWarning, createElement } from 'ckeditor5/src/utils.js'; +import { IconCancel, IconCheck, IconPencil } from 'ckeditor5/src/icons.js'; import type { HtmlEmbedConfig } from './htmlembedconfig.js'; import HtmlEmbedCommand from './htmlembedcommand.js'; @@ -408,7 +409,7 @@ function createUIButton( editor: Editor, type: 'edit' | 'save' | 'cancel', onCli buttonView.set( { class: `raw-html-embed__${ type }-button`, - icon: icons.pencil, + icon: IconPencil, tooltip: true, tooltipPosition: editor.locale.uiLanguageDirection === 'rtl' ? 'e' : 'w' } ); @@ -417,21 +418,21 @@ function createUIButton( editor: Editor, type: 'edit' | 'save' | 'cancel', onCli if ( type === 'edit' ) { buttonView.set( { - icon: icons.pencil, + icon: IconPencil, label: t( 'Edit source' ) } ); buttonView.bind( 'isEnabled' ).to( command ); } else if ( type === 'save' ) { buttonView.set( { - icon: icons.check, + icon: IconCheck, label: t( 'Save changes' ) } ); buttonView.bind( 'isEnabled' ).to( command ); } else { buttonView.set( { - icon: icons.cancel, + icon: IconCancel, label: t( 'Cancel' ) } ); } diff --git a/packages/ckeditor5-html-embed/src/htmlembedui.ts b/packages/ckeditor5-html-embed/src/htmlembedui.ts index 56bc6ef1c7d..d84f70e315c 100644 --- a/packages/ckeditor5-html-embed/src/htmlembedui.ts +++ b/packages/ckeditor5-html-embed/src/htmlembedui.ts @@ -7,7 +7,8 @@ * @module html-embed/htmlembedui */ -import { icons, Plugin } from 'ckeditor5/src/core.js'; +import { Plugin } from 'ckeditor5/src/core.js'; +import { IconHtml } from 'ckeditor5/src/icons.js'; import { ButtonView, MenuBarMenuListItemButtonView } from 'ckeditor5/src/ui.js'; import type { RawHtmlApi } from './htmlembedediting.js'; import type HtmlEmbedCommand from './htmlembedcommand.js'; @@ -70,7 +71,7 @@ export default class HtmlEmbedUI extends Plugin { const view = new ButtonClass( editor.locale ) as InstanceType; view.set( { - icon: icons.html + icon: IconHtml } ); view.bind( 'isEnabled' ).to( command, 'isEnabled' ); diff --git a/packages/ckeditor5-html-embed/tests/htmlembedui.js b/packages/ckeditor5-html-embed/tests/htmlembedui.js index fcb8a828612..44ebe7e6d0b 100644 --- a/packages/ckeditor5-html-embed/tests/htmlembedui.js +++ b/packages/ckeditor5-html-embed/tests/htmlembedui.js @@ -11,7 +11,7 @@ import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictest import HtmlEmbedUI from '../src/htmlembedui.js'; import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview.js'; import { MenuBarMenuListItemButtonView } from '@ckeditor/ckeditor5-ui'; -import { icons } from 'ckeditor5/src/core.js'; +import { IconHtml } from 'ckeditor5/src/icons.js'; describe( 'HtmlEmbedUI', () => { let element, editor, button; @@ -72,7 +72,7 @@ describe( 'HtmlEmbedUI', () => { it( 'should create UI component with correct attribute values', () => { expect( button.isOn ).to.be.false; expect( button.label ).to.equal( label ); - expect( button.icon ).to.equal( icons.html ); + expect( button.icon ).to.equal( IconHtml ); } ); it( `should execute ${ featureName } command on model execute event and focus the view then switch to edit source mode` + diff --git a/packages/ckeditor5-html-embed/tsconfig.dist.json b/packages/ckeditor5-html-embed/tsconfig.dist.json index a8ab888e091..d8e5823ec97 100644 --- a/packages/ckeditor5-html-embed/tsconfig.dist.json +++ b/packages/ckeditor5-html-embed/tsconfig.dist.json @@ -1,7 +1,10 @@ { "extends": "../../tsconfig.dist.json", "compilerOptions": { - "rootDir": "src" + "rootDir": "src", + "types": [ + "../../typings/types" + ] }, "include": [ "src" diff --git a/packages/ckeditor5-html-embed/tsconfig.json b/packages/ckeditor5-html-embed/tsconfig.json index f011696cd1c..06d45c8982e 100644 --- a/packages/ckeditor5-html-embed/tsconfig.json +++ b/packages/ckeditor5-html-embed/tsconfig.json @@ -1,7 +1,8 @@ { "extends": "../../tsconfig.release.json", "include": [ - "src" + "src", + "../../typings" ], "exclude": [ "tests" diff --git a/packages/ckeditor5-html-support/docs/features/full-page-html.md b/packages/ckeditor5-html-support/docs/features/full-page-html.md index 18a564b3538..d1809afcb51 100644 --- a/packages/ckeditor5-html-support/docs/features/full-page-html.md +++ b/packages/ckeditor5-html-support/docs/features/full-page-html.md @@ -13,7 +13,7 @@ Thanks to the full page HTML feature you can use CKEditor 5 to edit entire ## Demo -Use the {@link features/source-editing source editing feature} toolbar button {@icon @ckeditor/ckeditor5-source-editing/theme/icons/source-editing.svg Source editing} to view and edit the HTML source of the document. Pay attention to the underlying markup. +Use the {@link features/source-editing source editing feature} toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/source-editing.svg Source editing} to view and edit the HTML source of the document. Pay attention to the underlying markup. {@snippet features/full-page-html} diff --git a/packages/ckeditor5-html-support/docs/features/general-html-support.md b/packages/ckeditor5-html-support/docs/features/general-html-support.md index 22d8364659c..ba0c70a8946 100644 --- a/packages/ckeditor5-html-support/docs/features/general-html-support.md +++ b/packages/ckeditor5-html-support/docs/features/general-html-support.md @@ -13,7 +13,7 @@ With the General HTML Support (GHS) feature, developers can enable HTML features ## Demo -Use the {@link features/source-editing source editing feature} toolbar button {@icon @ckeditor/ckeditor5-source-editing/theme/icons/source-editing.svg Source editing} to view and edit the HTML source of the document. You can find the configuration of this snippet below the demo. +Use the {@link features/source-editing source editing feature} toolbar button {@icon @ckeditor/ckeditor5-icons/theme/icons/source-editing.svg Source editing} to view and edit the HTML source of the document. You can find the configuration of this snippet below the demo. You can configure the General HTML Support feature using the `config.htmlSupport` property. With this property, you need to list the HTML features that should be handled by GHS. diff --git a/packages/ckeditor5-html-support/docs/features/html-comments.md b/packages/ckeditor5-html-support/docs/features/html-comments.md index de92c730dde..452e6f5b570 100644 --- a/packages/ckeditor5-html-support/docs/features/html-comments.md +++ b/packages/ckeditor5-html-support/docs/features/html-comments.md @@ -19,7 +19,7 @@ By default, the editor filters out all HTML comments on initialization. The {@li ## Demo -The editor below is configured to keep HTML comments in the document content. You can view the source of the document using the {@link features/source-editing source editing} feature. Toggle the source editing mode {@icon @ckeditor/ckeditor5-source-editing/theme/icons/source-editing.svg Source editing} to see there is an HTML comment in the document source. Try uncommenting the paragraph below the picture. Once you leave the source editing mode, you will see this paragraph in the editable area. +The editor below is configured to keep HTML comments in the document content. You can view the source of the document using the {@link features/source-editing source editing} feature. Toggle the source editing mode {@icon @ckeditor/ckeditor5-icons/theme/icons/source-editing.svg Source editing} to see there is an HTML comment in the document source. Try uncommenting the paragraph below the picture. Once you leave the source editing mode, you will see this paragraph in the editable area. {@snippet features/html-comment} diff --git a/packages/ckeditor5-html-support/package.json b/packages/ckeditor5-html-support/package.json index 702c4061815..5a7c8bbb75e 100644 --- a/packages/ckeditor5-html-support/package.json +++ b/packages/ckeditor5-html-support/package.json @@ -20,6 +20,10 @@ "@ckeditor/ckeditor5-core": "44.1.0", "@ckeditor/ckeditor5-engine": "44.1.0", "@ckeditor/ckeditor5-enter": "44.1.0", + "@ckeditor/ckeditor5-heading": "44.1.0", + "@ckeditor/ckeditor5-image": "44.1.0", + "@ckeditor/ckeditor5-list": "44.1.0", + "@ckeditor/ckeditor5-table": "44.1.0", "@ckeditor/ckeditor5-utils": "44.1.0", "@ckeditor/ckeditor5-widget": "44.1.0", "ckeditor5": "44.1.0", @@ -32,20 +36,17 @@ "@ckeditor/ckeditor5-clipboard": "44.1.0", "@ckeditor/ckeditor5-cloud-services": "44.1.0", "@ckeditor/ckeditor5-code-block": "44.1.0", - "@ckeditor/ckeditor5-dev-utils": "^45.0.0", + "@ckeditor/ckeditor5-dev-utils": "^46.0.0", "@ckeditor/ckeditor5-easy-image": "44.1.0", "@ckeditor/ckeditor5-editor-classic": "44.1.0", "@ckeditor/ckeditor5-editor-multi-root": "44.1.0", "@ckeditor/ckeditor5-essentials": "44.1.0", "@ckeditor/ckeditor5-font": "44.1.0", - "@ckeditor/ckeditor5-heading": "44.1.0", "@ckeditor/ckeditor5-highlight": "44.1.0", "@ckeditor/ckeditor5-horizontal-line": "44.1.0", "@ckeditor/ckeditor5-html-embed": "44.1.0", - "@ckeditor/ckeditor5-image": "44.1.0", "@ckeditor/ckeditor5-indent": "44.1.0", "@ckeditor/ckeditor5-link": "44.1.0", - "@ckeditor/ckeditor5-list": "44.1.0", "@ckeditor/ckeditor5-media-embed": "44.1.0", "@ckeditor/ckeditor5-page-break": "44.1.0", "@ckeditor/ckeditor5-paragraph": "44.1.0", @@ -53,7 +54,6 @@ "@ckeditor/ckeditor5-remove-format": "44.1.0", "@ckeditor/ckeditor5-source-editing": "44.1.0", "@ckeditor/ckeditor5-style": "44.1.0", - "@ckeditor/ckeditor5-table": "44.1.0", "@ckeditor/ckeditor5-theme-lark": "44.1.0", "@ckeditor/ckeditor5-typing": "44.1.0", "typescript": "5.0.4", diff --git a/packages/ckeditor5-html-support/tests/manual/ghs-no-features.html b/packages/ckeditor5-html-support/tests/manual/ghs-no-features.html index 4d422f798b6..57fdec0cd74 100644 --- a/packages/ckeditor5-html-support/tests/manual/ghs-no-features.html +++ b/packages/ckeditor5-html-support/tests/manual/ghs-no-features.html @@ -15,13 +15,6 @@ border: 1px solid red !important; } - -
@@ -303,7 +296,7 @@

h6

-

+

diff --git a/packages/ckeditor5-html-support/tests/manual/objects.html b/packages/ckeditor5-html-support/tests/manual/objects.html index 743a38f580f..e236a3e210a 100644 --- a/packages/ckeditor5-html-support/tests/manual/objects.html +++ b/packages/ckeditor5-html-support/tests/manual/objects.html @@ -30,7 +30,7 @@

-

+

some custom text

@@ -61,7 +61,7 @@

-

+