1 | /**
|
2 | * @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
|
3 | * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
4 | */
|
5 |
|
6 | /**
|
7 | * @module image/image
|
8 | */
|
9 |
|
10 | import { Plugin } from 'ckeditor5/src/core';
|
11 |
|
12 | import ImageBlock from './imageblock';
|
13 | import ImageInline from './imageinline';
|
14 |
|
15 | import '../theme/image.css';
|
16 |
|
17 | /**
|
18 | * The image plugin.
|
19 | *
|
20 | * For a detailed overview, check the {@glink features/images/images-overview image feature} documentation.
|
21 | *
|
22 | * This is a "glue" plugin which loads the following plugins:
|
23 | *
|
24 | * * {@link module:image/imageblock~ImageBlock},
|
25 | * * {@link module:image/imageinline~ImageInline},
|
26 | *
|
27 | * Usually, it is used in conjunction with other plugins from this package. See the {@glink api/image package page}
|
28 | * for more information.
|
29 | *
|
30 | * @extends module:core/plugin~Plugin
|
31 | */
|
32 | export default class Image extends Plugin {
|
33 | /**
|
34 | * @inheritDoc
|
35 | */
|
36 | static get requires() {
|
37 | return [ ImageBlock, ImageInline ];
|
38 | }
|
39 |
|
40 | /**
|
41 | * @inheritDoc
|
42 | */
|
43 | static get pluginName() {
|
44 | return 'Image';
|
45 | }
|
46 | }
|
47 |
|
48 | /**
|
49 | * The configuration of the image features. Used by the image features in the `@ckeditor/ckeditor5-image` package.
|
50 | *
|
51 | * Read more in {@link module:image/image~ImageConfig}.
|
52 | *
|
53 | * @member {module:image/image~ImageConfig} module:core/editor/editorconfig~EditorConfig#image
|
54 | */
|
55 |
|
56 | /**
|
57 | * The configuration of the image features. Used by the image features in the `@ckeditor/ckeditor5-image` package.
|
58 | *
|
59 | * ClassicEditor
|
60 | * .create( editorElement, {
|
61 | * image: ... // Image feature options.
|
62 | * } )
|
63 | * .then( ... )
|
64 | * .catch( ... );
|
65 | *
|
66 | * See {@link module:core/editor/editorconfig~EditorConfig all editor options}.
|
67 | *
|
68 | * @interface ImageConfig
|
69 | */
|