@ckeditor/ckeditor5-editor-inline 41.3.1 → 41.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index-content.css +4 -0
- package/dist/index-editor.css +4 -0
- package/dist/index.css +4 -0
- package/dist/index.js +431 -0
- package/dist/index.js.map +1 -0
- package/dist/types/index.d.ts +12 -0
- package/dist/types/inlineeditor.d.ts +180 -0
- package/dist/types/inlineeditorui.d.ts +56 -0
- package/dist/types/inlineeditoruiview.d.ts +141 -0
- package/package.json +3 -2
package/dist/index.css
ADDED
package/dist/index.js
ADDED
@@ -0,0 +1,431 @@
|
|
1
|
+
/**
|
2
|
+
* @license Copyright (c) 2003-2024, 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
|
+
import { ElementApiMixin, Editor, secureSourceElement, attachToForm, Context } from '@ckeditor/ckeditor5-core/dist/index.js';
|
6
|
+
import { toUnit, ResizeObserver, Rect, CKEditorError, getDataFromElement } from '@ckeditor/ckeditor5-utils/dist/index.js';
|
7
|
+
import { EditorWatchdog, ContextWatchdog } from '@ckeditor/ckeditor5-watchdog/dist/index.js';
|
8
|
+
import { EditorUI, normalizeToolbarConfig, EditorUIView, ToolbarView, BalloonPanelView, InlineEditableUIView } from '@ckeditor/ckeditor5-ui/dist/index.js';
|
9
|
+
import { enablePlaceholder } from '@ckeditor/ckeditor5-engine/dist/index.js';
|
10
|
+
import { isElement as isElement$1 } from 'lodash-es';
|
11
|
+
|
12
|
+
class InlineEditorUI extends EditorUI {
|
13
|
+
/**
|
14
|
+
* @inheritDoc
|
15
|
+
*/ get element() {
|
16
|
+
return this.view.editable.element;
|
17
|
+
}
|
18
|
+
/**
|
19
|
+
* Initializes the UI.
|
20
|
+
*/ init() {
|
21
|
+
const editor = this.editor;
|
22
|
+
const view = this.view;
|
23
|
+
const editingView = editor.editing.view;
|
24
|
+
const editable = view.editable;
|
25
|
+
const editingRoot = editingView.document.getRoot();
|
26
|
+
// The editable UI and editing root should share the same name. Then name is used
|
27
|
+
// to recognize the particular editable, for instance in ARIA attributes.
|
28
|
+
editable.name = editingRoot.rootName;
|
29
|
+
view.render();
|
30
|
+
// The editable UI element in DOM is available for sure only after the editor UI view has been rendered.
|
31
|
+
// But it can be available earlier if a DOM element has been passed to InlineEditor.create().
|
32
|
+
const editableElement = editable.element;
|
33
|
+
// Register the editable UI view in the editor. A single editor instance can aggregate multiple
|
34
|
+
// editable areas (roots) but the inline editor has only one.
|
35
|
+
this.setEditableElement(editable.name, editableElement);
|
36
|
+
// Let the editable UI element respond to the changes in the global editor focus
|
37
|
+
// tracker. It has been added to the same tracker a few lines above but, in reality, there are
|
38
|
+
// many focusable areas in the editor, like balloons, toolbars or dropdowns and as long
|
39
|
+
// as they have focus, the editable should act like it is focused too (although technically
|
40
|
+
// it isn't), e.g. by setting the proper CSS class, visually announcing focus to the user.
|
41
|
+
// Doing otherwise will result in editable focus styles disappearing, once e.g. the
|
42
|
+
// toolbar gets focused.
|
43
|
+
editable.bind('isFocused').to(this.focusTracker);
|
44
|
+
// Bind the editable UI element to the editing view, making it an end– and entry–point
|
45
|
+
// of the editor's engine. This is where the engine meets the UI.
|
46
|
+
editingView.attachDomRoot(editableElement);
|
47
|
+
this._initPlaceholder();
|
48
|
+
this._initToolbar();
|
49
|
+
this.fire('ready');
|
50
|
+
}
|
51
|
+
/**
|
52
|
+
* @inheritDoc
|
53
|
+
*/ destroy() {
|
54
|
+
super.destroy();
|
55
|
+
const view = this.view;
|
56
|
+
const editingView = this.editor.editing.view;
|
57
|
+
editingView.detachDomRoot(view.editable.name);
|
58
|
+
view.destroy();
|
59
|
+
}
|
60
|
+
/**
|
61
|
+
* Initializes the inline editor toolbar and its panel.
|
62
|
+
*/ _initToolbar() {
|
63
|
+
const editor = this.editor;
|
64
|
+
const view = this.view;
|
65
|
+
const editableElement = view.editable.element;
|
66
|
+
const toolbar = view.toolbar;
|
67
|
+
// Set–up the view#panel.
|
68
|
+
view.panel.bind('isVisible').to(this.focusTracker, 'isFocused');
|
69
|
+
view.bind('viewportTopOffset').to(this, 'viewportOffset', ({ top })=>top || 0);
|
70
|
+
// https://github.com/ckeditor/ckeditor5-editor-inline/issues/4
|
71
|
+
view.listenTo(editor.ui, 'update', ()=>{
|
72
|
+
// Don't pin if the panel is not already visible. It prevents the panel
|
73
|
+
// showing up when there's no focus in the UI.
|
74
|
+
if (view.panel.isVisible) {
|
75
|
+
view.panel.pin({
|
76
|
+
target: editableElement,
|
77
|
+
positions: view.panelPositions
|
78
|
+
});
|
79
|
+
}
|
80
|
+
});
|
81
|
+
toolbar.fillFromConfig(this._toolbarConfig, this.componentFactory);
|
82
|
+
// Register the toolbar so it becomes available for Alt+F10 and Esc navigation.
|
83
|
+
this.addToolbar(toolbar);
|
84
|
+
}
|
85
|
+
/**
|
86
|
+
* Enable the placeholder text on the editing root.
|
87
|
+
*/ _initPlaceholder() {
|
88
|
+
const editor = this.editor;
|
89
|
+
const editingView = editor.editing.view;
|
90
|
+
const editingRoot = editingView.document.getRoot();
|
91
|
+
const placeholder = editor.config.get('placeholder');
|
92
|
+
if (placeholder) {
|
93
|
+
const placeholderText = typeof placeholder === 'string' ? placeholder : placeholder[editingRoot.rootName];
|
94
|
+
if (placeholderText) {
|
95
|
+
editingRoot.placeholder = placeholderText;
|
96
|
+
}
|
97
|
+
}
|
98
|
+
enablePlaceholder({
|
99
|
+
view: editingView,
|
100
|
+
element: editingRoot,
|
101
|
+
isDirectHost: false,
|
102
|
+
keepOnFocus: true
|
103
|
+
});
|
104
|
+
}
|
105
|
+
/**
|
106
|
+
* Creates an instance of the inline editor UI class.
|
107
|
+
*
|
108
|
+
* @param editor The editor instance.
|
109
|
+
* @param view The view of the UI.
|
110
|
+
*/ constructor(editor, view){
|
111
|
+
super(editor);
|
112
|
+
this.view = view;
|
113
|
+
this._toolbarConfig = normalizeToolbarConfig(editor.config.get('toolbar'));
|
114
|
+
}
|
115
|
+
}
|
116
|
+
|
117
|
+
const toPx = toUnit('px');
|
118
|
+
class InlineEditorUIView extends EditorUIView {
|
119
|
+
/**
|
120
|
+
* @inheritDoc
|
121
|
+
*/ render() {
|
122
|
+
super.render();
|
123
|
+
this.body.add(this.panel);
|
124
|
+
this.registerChild(this.editable);
|
125
|
+
this.panel.content.add(this.toolbar);
|
126
|
+
const options = this.toolbar.options;
|
127
|
+
// Set toolbar's max-width on the initialization and update it on the editable resize,
|
128
|
+
// if 'shouldToolbarGroupWhenFull' in config is set to 'true'.
|
129
|
+
if (options.shouldGroupWhenFull) {
|
130
|
+
const editableElement = this.editable.element;
|
131
|
+
this._resizeObserver = new ResizeObserver(editableElement, ()=>{
|
132
|
+
this.toolbar.maxWidth = toPx(new Rect(editableElement).width);
|
133
|
+
});
|
134
|
+
}
|
135
|
+
}
|
136
|
+
/**
|
137
|
+
* @inheritDoc
|
138
|
+
*/ destroy() {
|
139
|
+
super.destroy();
|
140
|
+
if (this._resizeObserver) {
|
141
|
+
this._resizeObserver.destroy();
|
142
|
+
}
|
143
|
+
}
|
144
|
+
/**
|
145
|
+
* Determines the panel top position of the {@link #panel} in {@link #panelPositions}.
|
146
|
+
*
|
147
|
+
* @param editableRect Rect of the {@link #element}.
|
148
|
+
* @param panelRect Rect of the {@link #panel}.
|
149
|
+
*/ _getPanelPositionTop(editableRect, panelRect) {
|
150
|
+
let top;
|
151
|
+
if (editableRect.top > panelRect.height + this.viewportTopOffset) {
|
152
|
+
top = editableRect.top - panelRect.height;
|
153
|
+
} else if (editableRect.bottom > panelRect.height + this.viewportTopOffset + 50) {
|
154
|
+
top = this.viewportTopOffset;
|
155
|
+
} else {
|
156
|
+
top = editableRect.bottom;
|
157
|
+
}
|
158
|
+
return top;
|
159
|
+
}
|
160
|
+
/**
|
161
|
+
* Returns the positions for {@link #panelPositions}.
|
162
|
+
*
|
163
|
+
* See: {@link module:utils/dom/position~Options#positions}.
|
164
|
+
*/ _getPanelPositions() {
|
165
|
+
const positions = [
|
166
|
+
(editableRect, panelRect)=>{
|
167
|
+
return {
|
168
|
+
top: this._getPanelPositionTop(editableRect, panelRect),
|
169
|
+
left: editableRect.left,
|
170
|
+
name: 'toolbar_west',
|
171
|
+
config: {
|
172
|
+
withArrow: false
|
173
|
+
}
|
174
|
+
};
|
175
|
+
},
|
176
|
+
(editableRect, panelRect)=>{
|
177
|
+
return {
|
178
|
+
top: this._getPanelPositionTop(editableRect, panelRect),
|
179
|
+
left: editableRect.left + editableRect.width - panelRect.width,
|
180
|
+
name: 'toolbar_east',
|
181
|
+
config: {
|
182
|
+
withArrow: false
|
183
|
+
}
|
184
|
+
};
|
185
|
+
}
|
186
|
+
];
|
187
|
+
if (this.locale.uiLanguageDirection === 'ltr') {
|
188
|
+
return positions;
|
189
|
+
} else {
|
190
|
+
return positions.reverse();
|
191
|
+
}
|
192
|
+
}
|
193
|
+
/**
|
194
|
+
* Creates an instance of the inline editor UI view.
|
195
|
+
*
|
196
|
+
* @param locale The {@link module:core/editor/editor~Editor#locale} instance.
|
197
|
+
* @param editingView The editing view instance this view is related to.
|
198
|
+
* @param editableElement The editable element. If not specified, it will be automatically created by
|
199
|
+
* {@link module:ui/editableui/editableuiview~EditableUIView}. Otherwise, the given element will be used.
|
200
|
+
* @param options Configuration options for the view instance.
|
201
|
+
* @param options.shouldToolbarGroupWhenFull When set `true` enables automatic items grouping
|
202
|
+
* in the main {@link module:editor-inline/inlineeditoruiview~InlineEditorUIView#toolbar toolbar}.
|
203
|
+
* See {@link module:ui/toolbar/toolbarview~ToolbarOptions#shouldGroupWhenFull} to learn more.
|
204
|
+
*/ constructor(locale, editingView, editableElement, options = {}){
|
205
|
+
super(locale);
|
206
|
+
const t = locale.t;
|
207
|
+
this.toolbar = new ToolbarView(locale, {
|
208
|
+
shouldGroupWhenFull: options.shouldToolbarGroupWhenFull,
|
209
|
+
isFloating: true
|
210
|
+
});
|
211
|
+
this.set('viewportTopOffset', 0);
|
212
|
+
this.panel = new BalloonPanelView(locale);
|
213
|
+
this.panelPositions = this._getPanelPositions();
|
214
|
+
this.panel.extendTemplate({
|
215
|
+
attributes: {
|
216
|
+
class: 'ck-toolbar-container'
|
217
|
+
}
|
218
|
+
});
|
219
|
+
this.editable = new InlineEditableUIView(locale, editingView, editableElement, {
|
220
|
+
label: (editableView)=>{
|
221
|
+
return t('Rich Text Editor. Editing area: %0', editableView.name);
|
222
|
+
}
|
223
|
+
});
|
224
|
+
this._resizeObserver = null;
|
225
|
+
}
|
226
|
+
}
|
227
|
+
|
228
|
+
/**
|
229
|
+
* The {@glink installation/getting-started/predefined-builds#inline-editor inline editor} implementation.
|
230
|
+
* It uses an inline editable and a floating toolbar.
|
231
|
+
* See the {@glink examples/builds/inline-editor demo}.
|
232
|
+
*
|
233
|
+
* In order to create a inline editor instance, use the static
|
234
|
+
* {@link module:editor-inline/inlineeditor~InlineEditor.create `InlineEditor.create()`} method.
|
235
|
+
*
|
236
|
+
* # Inline editor and inline build
|
237
|
+
*
|
238
|
+
* The inline editor can be used directly from source (if you installed the
|
239
|
+
* [`@ckeditor/ckeditor5-editor-inline`](https://www.npmjs.com/package/@ckeditor/ckeditor5-editor-inline) package)
|
240
|
+
* but it is also available in the {@glink installation/getting-started/predefined-builds#inline-editor inline build}.
|
241
|
+
*
|
242
|
+
* {@glink installation/getting-started/predefined-builds Builds}
|
243
|
+
* are ready-to-use editors with plugins bundled in. When using the editor from
|
244
|
+
* source you need to take care of loading all plugins by yourself
|
245
|
+
* (through the {@link module:core/editor/editorconfig~EditorConfig#plugins `config.plugins`} option).
|
246
|
+
* Using the editor from source gives much better flexibility and allows easier customization.
|
247
|
+
*
|
248
|
+
* Read more about initializing the editor from source or as a build in
|
249
|
+
* {@link module:editor-inline/inlineeditor~InlineEditor.create `InlineEditor.create()`}.
|
250
|
+
*/ class InlineEditor extends ElementApiMixin(Editor) {
|
251
|
+
/**
|
252
|
+
* Destroys the editor instance, releasing all resources used by it.
|
253
|
+
*
|
254
|
+
* Updates the original editor element with the data if the
|
255
|
+
* {@link module:core/editor/editorconfig~EditorConfig#updateSourceElementOnDestroy `updateSourceElementOnDestroy`}
|
256
|
+
* configuration option is set to `true`.
|
257
|
+
*/ destroy() {
|
258
|
+
// Cache the data, then destroy.
|
259
|
+
// It's safe to assume that the model->view conversion will not work after super.destroy().
|
260
|
+
const data = this.getData();
|
261
|
+
this.ui.destroy();
|
262
|
+
return super.destroy().then(()=>{
|
263
|
+
if (this.sourceElement) {
|
264
|
+
this.updateSourceElement(data);
|
265
|
+
}
|
266
|
+
});
|
267
|
+
}
|
268
|
+
/**
|
269
|
+
* Creates a new inline editor instance.
|
270
|
+
*
|
271
|
+
* There are three general ways how the editor can be initialized.
|
272
|
+
*
|
273
|
+
* # Using an existing DOM element (and loading data from it)
|
274
|
+
*
|
275
|
+
* You can initialize the editor using an existing DOM element:
|
276
|
+
*
|
277
|
+
* ```ts
|
278
|
+
* InlineEditor
|
279
|
+
* .create( document.querySelector( '#editor' ) )
|
280
|
+
* .then( editor => {
|
281
|
+
* console.log( 'Editor was initialized', editor );
|
282
|
+
* } )
|
283
|
+
* .catch( err => {
|
284
|
+
* console.error( err.stack );
|
285
|
+
* } );
|
286
|
+
* ```
|
287
|
+
*
|
288
|
+
* The element's content will be used as the editor data and the element will become the editable element.
|
289
|
+
*
|
290
|
+
* # Creating a detached editor
|
291
|
+
*
|
292
|
+
* Alternatively, you can initialize the editor by passing the initial data directly as a `String`.
|
293
|
+
* In this case, the editor will render an element that must be inserted into the DOM for the editor to work properly:
|
294
|
+
*
|
295
|
+
* ```ts
|
296
|
+
* InlineEditor
|
297
|
+
* .create( '<p>Hello world!</p>' )
|
298
|
+
* .then( editor => {
|
299
|
+
* console.log( 'Editor was initialized', editor );
|
300
|
+
*
|
301
|
+
* // Initial data was provided so the editor UI element needs to be added manually to the DOM.
|
302
|
+
* document.body.appendChild( editor.ui.element );
|
303
|
+
* } )
|
304
|
+
* .catch( err => {
|
305
|
+
* console.error( err.stack );
|
306
|
+
* } );
|
307
|
+
* ```
|
308
|
+
*
|
309
|
+
* This lets you dynamically append the editor to your web page whenever it is convenient for you. You may use this method if your
|
310
|
+
* web page content is generated on the client side and the DOM structure is not ready at the moment when you initialize the editor.
|
311
|
+
*
|
312
|
+
* # Using an existing DOM element (and data provided in `config.initialData`)
|
313
|
+
*
|
314
|
+
* You can also mix these two ways by providing a DOM element to be used and passing the initial data through the configuration:
|
315
|
+
*
|
316
|
+
* ```ts
|
317
|
+
* InlineEditor
|
318
|
+
* .create( document.querySelector( '#editor' ), {
|
319
|
+
* initialData: '<h2>Initial data</h2><p>Foo bar.</p>'
|
320
|
+
* } )
|
321
|
+
* .then( editor => {
|
322
|
+
* console.log( 'Editor was initialized', editor );
|
323
|
+
* } )
|
324
|
+
* .catch( err => {
|
325
|
+
* console.error( err.stack );
|
326
|
+
* } );
|
327
|
+
* ```
|
328
|
+
*
|
329
|
+
* This method can be used to initialize the editor on an existing element with the specified content in case if your integration
|
330
|
+
* makes it difficult to set the content of the source element.
|
331
|
+
*
|
332
|
+
* Note that an error will be thrown if you pass the initial data both as the first parameter and also in the configuration.
|
333
|
+
*
|
334
|
+
* # Configuring the editor
|
335
|
+
*
|
336
|
+
* See the {@link module:core/editor/editorconfig~EditorConfig editor configuration documentation} to learn more about
|
337
|
+
* customizing plugins, toolbar and more.
|
338
|
+
*
|
339
|
+
* # Using the editor from source
|
340
|
+
*
|
341
|
+
* The code samples listed in the previous sections of this documentation assume that you are using an
|
342
|
+
* {@glink installation/getting-started/predefined-builds editor build} (for example – `@ckeditor/ckeditor5-build-inline`).
|
343
|
+
*
|
344
|
+
* If you want to use the inline editor from source (`@ckeditor/ckeditor5-editor-inline/src/inlineeditor`),
|
345
|
+
* you need to define the list of
|
346
|
+
* {@link module:core/editor/editorconfig~EditorConfig#plugins plugins to be initialized} and
|
347
|
+
* {@link module:core/editor/editorconfig~EditorConfig#toolbar toolbar items}. Read more about using the editor from
|
348
|
+
* source in the {@glink installation/advanced/alternative-setups/integrating-from-source-webpack dedicated guide}.
|
349
|
+
*
|
350
|
+
* @param sourceElementOrData The DOM element that will be the source for the created editor
|
351
|
+
* or the editor's initial data.
|
352
|
+
*
|
353
|
+
* If a DOM element is passed, its content will be automatically loaded to the editor upon initialization.
|
354
|
+
* The editor data will be set back to the original element once the editor is destroyed only if the
|
355
|
+
* {@link module:core/editor/editorconfig~EditorConfig#updateSourceElementOnDestroy updateSourceElementOnDestroy}
|
356
|
+
* option is set to `true`.
|
357
|
+
*
|
358
|
+
* If the initial data is passed, a detached editor will be created. In this case you need to insert it into the DOM manually.
|
359
|
+
* It is available under the {@link module:editor-inline/inlineeditorui~InlineEditorUI#element `editor.ui.element`} property.
|
360
|
+
*
|
361
|
+
* @param config The editor configuration.
|
362
|
+
* @returns A promise resolved once the editor is ready. The promise resolves with the created editor instance.
|
363
|
+
*/ static create(sourceElementOrData, config = {}) {
|
364
|
+
return new Promise((resolve)=>{
|
365
|
+
if (isElement(sourceElementOrData) && sourceElementOrData.tagName === 'TEXTAREA') {
|
366
|
+
// Documented in core/editor/editor.js
|
367
|
+
// eslint-disable-next-line ckeditor5-rules/ckeditor-error-message
|
368
|
+
throw new CKEditorError('editor-wrong-element', null);
|
369
|
+
}
|
370
|
+
const editor = new this(sourceElementOrData, config);
|
371
|
+
resolve(editor.initPlugins().then(()=>editor.ui.init()).then(()=>editor.data.init(editor.config.get('initialData'))).then(()=>editor.fire('ready')).then(()=>editor));
|
372
|
+
});
|
373
|
+
}
|
374
|
+
/**
|
375
|
+
* Creates an instance of the inline editor.
|
376
|
+
*
|
377
|
+
* **Note:** Do not use the constructor to create editor instances. Use the static
|
378
|
+
* {@link module:editor-inline/inlineeditor~InlineEditor.create `InlineEditor.create()`} method instead.
|
379
|
+
*
|
380
|
+
* @param sourceElementOrData The DOM element that will be the source for the created editor
|
381
|
+
* (on which the editor will be initialized) or initial data for the editor. For more information see
|
382
|
+
* {@link module:editor-inline/inlineeditor~InlineEditor.create `InlineEditor.create()`}.
|
383
|
+
* @param config The editor configuration.
|
384
|
+
*/ constructor(sourceElementOrData, config = {}){
|
385
|
+
// If both `config.initialData` and initial data parameter in `create()` are set, then throw.
|
386
|
+
if (!isElement(sourceElementOrData) && config.initialData !== undefined) {
|
387
|
+
// Documented in core/editor/editorconfig.jsdoc.
|
388
|
+
// eslint-disable-next-line ckeditor5-rules/ckeditor-error-message
|
389
|
+
throw new CKEditorError('editor-create-initial-data', null);
|
390
|
+
}
|
391
|
+
super(config);
|
392
|
+
if (this.config.get('initialData') === undefined) {
|
393
|
+
this.config.set('initialData', getInitialData(sourceElementOrData));
|
394
|
+
}
|
395
|
+
this.model.document.createRoot();
|
396
|
+
if (isElement(sourceElementOrData)) {
|
397
|
+
this.sourceElement = sourceElementOrData;
|
398
|
+
secureSourceElement(this, sourceElementOrData);
|
399
|
+
}
|
400
|
+
const shouldToolbarGroupWhenFull = !this.config.get('toolbar.shouldNotGroupWhenFull');
|
401
|
+
const view = new InlineEditorUIView(this.locale, this.editing.view, this.sourceElement, {
|
402
|
+
shouldToolbarGroupWhenFull
|
403
|
+
});
|
404
|
+
this.ui = new InlineEditorUI(this, view);
|
405
|
+
attachToForm(this);
|
406
|
+
}
|
407
|
+
}
|
408
|
+
/**
|
409
|
+
* The {@link module:core/context~Context} class.
|
410
|
+
*
|
411
|
+
* Exposed as static editor field for easier access in editor builds.
|
412
|
+
*/ InlineEditor.Context = Context;
|
413
|
+
/**
|
414
|
+
* The {@link module:watchdog/editorwatchdog~EditorWatchdog} class.
|
415
|
+
*
|
416
|
+
* Exposed as static editor field for easier access in editor builds.
|
417
|
+
*/ InlineEditor.EditorWatchdog = EditorWatchdog;
|
418
|
+
/**
|
419
|
+
* The {@link module:watchdog/contextwatchdog~ContextWatchdog} class.
|
420
|
+
*
|
421
|
+
* Exposed as static editor field for easier access in editor builds.
|
422
|
+
*/ InlineEditor.ContextWatchdog = ContextWatchdog;
|
423
|
+
function getInitialData(sourceElementOrData) {
|
424
|
+
return isElement(sourceElementOrData) ? getDataFromElement(sourceElementOrData) : sourceElementOrData;
|
425
|
+
}
|
426
|
+
function isElement(value) {
|
427
|
+
return isElement$1(value);
|
428
|
+
}
|
429
|
+
|
430
|
+
export { InlineEditor };
|
431
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["index.js","../src/inlineeditorui.ts","../src/inlineeditoruiview.ts","../src/inlineeditor.ts"],"names":["InlineEditorUI","EditorUI","element","view","editable","init","editor","editingView","editing","editingRoot","document","getRoot","name","rootName","render","editableElement","setEditableElement","bind","to","focusTracker","attachDomRoot","_initPlaceholder","_initToolbar","fire","destroy","detachDomRoot","toolbar","panel","top","listenTo","ui","isVisible","pin","target","positions","panelPositions","fillFromConfig","_toolbarConfig","componentFactory","addToolbar","placeholder","config","get","placeholderText","enablePlaceholder","isDirectHost","keepOnFocus","constructor","normalizeToolbarConfig","toPx","toUnit","InlineEditorUIView","EditorUIView","body","add","registerChild","content","options","shouldGroupWhenFull","_resizeObserver","ResizeObserver","maxWidth","Rect","width","_getPanelPositionTop","editableRect","panelRect","height","viewportTopOffset","bottom","_getPanelPositions","left","withArrow","locale","uiLanguageDirection","reverse","t","ToolbarView","shouldToolbarGroupWhenFull","isFloating","set","BalloonPanelView","extendTemplate","attributes","class","InlineEditableUIView","label","editableView","InlineEditor","ElementApiMixin","Editor","data","getData","then","sourceElement","updateSourceElement","create","sourceElementOrData","Promise","resolve","isElement","tagName","CKEditorError","initPlugins","initialData","undefined","getInitialData","model","createRoot","secureSourceElement","attachToForm","Context","EditorWatchdog","ContextWatchdog","getDataFromElement","value","_isElement"],"mappings":";;;;AAAA,MAAM,CAAC,CAAC,CAAC,eAAe,CAAC,CAAC,MAAM,CAAC,CAAC,mBAAmB,CAAC,CAAC,YAAY,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,SAAS,CAAC,IAAI,CAAC,IAAI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AC,CAAC,CAAC,OAAO,CAAC,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC;AACrE,CAAC,CAAC,CAAC,CGlKYxB,YAAAA,CAAeyB,eAAA,CAAA,CAAA,CAAGA,eAAAA,CAAAA;AAGjC,QAASP,CAAAA,cAAAA,CAAgBT,mBAAyC,CAAA,CAAA,CAAA;AHiKlE,CAAC,CAAC,CAAC,CGhKF,MAAOG,CAAAA,SAAAA,CAAWH,mBAAwBiB,CAAAA,CAAAA,CAAAA,CAAAA,kBAAAA,CAAoBjB,mBAAwBA,CAAAA,CAAAA,CAAAA,CAAAA,mBAAAA,CAAAA;AACvF,CAAA;AAEA,QAASG,CAAAA,SAAAA,CAAWe,KAAU,CAAA,CAAA,CAAA;AAC7B,CAAA,CAAA,CAAA,CAAA,MAAOC,CAAAA,SAAAA,CAAAA,CAAYD,CAAAA,KAAAA,CAAAA,CAAAA;AACpB,CAAA;AHgKA;AACA,MAAM,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,CAAC;AACxB,CAAC,CAAC,CAAC,CAAC,gBAAgB,CAAC,KAAK,CAAC,EAAE,CAAC,GAAG","file":"index.js.map","sourcesContent":["import { ElementApiMixin, Editor, secureSourceElement, attachToForm, Context } from '@ckeditor/ckeditor5-core/dist/index.js';\nimport { toUnit, ResizeObserver, Rect, CKEditorError, getDataFromElement } from '@ckeditor/ckeditor5-utils/dist/index.js';\nimport { EditorWatchdog, ContextWatchdog } from '@ckeditor/ckeditor5-watchdog/dist/index.js';\nimport { EditorUI, normalizeToolbarConfig, EditorUIView, ToolbarView, BalloonPanelView, InlineEditableUIView } from '@ckeditor/ckeditor5-ui/dist/index.js';\nimport { enablePlaceholder } from '@ckeditor/ckeditor5-engine/dist/index.js';\nimport { isElement as isElement$1 } from 'lodash-es';\n\nclass InlineEditorUI extends EditorUI {\n /**\n * @inheritDoc\n */ get element() {\n return this.view.editable.element;\n }\n /**\n * Initializes the UI.\n */ init() {\n const editor = this.editor;\n const view = this.view;\n const editingView = editor.editing.view;\n const editable = view.editable;\n const editingRoot = editingView.document.getRoot();\n // The editable UI and editing root should share the same name. Then name is used\n // to recognize the particular editable, for instance in ARIA attributes.\n editable.name = editingRoot.rootName;\n view.render();\n // The editable UI element in DOM is available for sure only after the editor UI view has been rendered.\n // But it can be available earlier if a DOM element has been passed to InlineEditor.create().\n const editableElement = editable.element;\n // Register the editable UI view in the editor. A single editor instance can aggregate multiple\n // editable areas (roots) but the inline editor has only one.\n this.setEditableElement(editable.name, editableElement);\n // Let the editable UI element respond to the changes in the global editor focus\n // tracker. It has been added to the same tracker a few lines above but, in reality, there are\n // many focusable areas in the editor, like balloons, toolbars or dropdowns and as long\n // as they have focus, the editable should act like it is focused too (although technically\n // it isn't), e.g. by setting the proper CSS class, visually announcing focus to the user.\n // Doing otherwise will result in editable focus styles disappearing, once e.g. the\n // toolbar gets focused.\n editable.bind('isFocused').to(this.focusTracker);\n // Bind the editable UI element to the editing view, making it an end– and entry–point\n // of the editor's engine. This is where the engine meets the UI.\n editingView.attachDomRoot(editableElement);\n this._initPlaceholder();\n this._initToolbar();\n this.fire('ready');\n }\n /**\n * @inheritDoc\n */ destroy() {\n super.destroy();\n const view = this.view;\n const editingView = this.editor.editing.view;\n editingView.detachDomRoot(view.editable.name);\n view.destroy();\n }\n /**\n * Initializes the inline editor toolbar and its panel.\n */ _initToolbar() {\n const editor = this.editor;\n const view = this.view;\n const editableElement = view.editable.element;\n const toolbar = view.toolbar;\n // Set–up the view#panel.\n view.panel.bind('isVisible').to(this.focusTracker, 'isFocused');\n view.bind('viewportTopOffset').to(this, 'viewportOffset', ({ top })=>top || 0);\n // https://github.com/ckeditor/ckeditor5-editor-inline/issues/4\n view.listenTo(editor.ui, 'update', ()=>{\n // Don't pin if the panel is not already visible. It prevents the panel\n // showing up when there's no focus in the UI.\n if (view.panel.isVisible) {\n view.panel.pin({\n target: editableElement,\n positions: view.panelPositions\n });\n }\n });\n toolbar.fillFromConfig(this._toolbarConfig, this.componentFactory);\n // Register the toolbar so it becomes available for Alt+F10 and Esc navigation.\n this.addToolbar(toolbar);\n }\n /**\n * Enable the placeholder text on the editing root.\n */ _initPlaceholder() {\n const editor = this.editor;\n const editingView = editor.editing.view;\n const editingRoot = editingView.document.getRoot();\n const placeholder = editor.config.get('placeholder');\n if (placeholder) {\n const placeholderText = typeof placeholder === 'string' ? placeholder : placeholder[editingRoot.rootName];\n if (placeholderText) {\n editingRoot.placeholder = placeholderText;\n }\n }\n enablePlaceholder({\n view: editingView,\n element: editingRoot,\n isDirectHost: false,\n keepOnFocus: true\n });\n }\n /**\n * Creates an instance of the inline editor UI class.\n *\n * @param editor The editor instance.\n * @param view The view of the UI.\n */ constructor(editor, view){\n super(editor);\n this.view = view;\n this._toolbarConfig = normalizeToolbarConfig(editor.config.get('toolbar'));\n }\n}\n\nconst toPx = toUnit('px');\nclass InlineEditorUIView extends EditorUIView {\n /**\n * @inheritDoc\n */ render() {\n super.render();\n this.body.add(this.panel);\n this.registerChild(this.editable);\n this.panel.content.add(this.toolbar);\n const options = this.toolbar.options;\n // Set toolbar's max-width on the initialization and update it on the editable resize,\n // if 'shouldToolbarGroupWhenFull' in config is set to 'true'.\n if (options.shouldGroupWhenFull) {\n const editableElement = this.editable.element;\n this._resizeObserver = new ResizeObserver(editableElement, ()=>{\n this.toolbar.maxWidth = toPx(new Rect(editableElement).width);\n });\n }\n }\n /**\n * @inheritDoc\n */ destroy() {\n super.destroy();\n if (this._resizeObserver) {\n this._resizeObserver.destroy();\n }\n }\n /**\n * Determines the panel top position of the {@link #panel} in {@link #panelPositions}.\n *\n * @param editableRect Rect of the {@link #element}.\n * @param panelRect Rect of the {@link #panel}.\n */ _getPanelPositionTop(editableRect, panelRect) {\n let top;\n if (editableRect.top > panelRect.height + this.viewportTopOffset) {\n top = editableRect.top - panelRect.height;\n } else if (editableRect.bottom > panelRect.height + this.viewportTopOffset + 50) {\n top = this.viewportTopOffset;\n } else {\n top = editableRect.bottom;\n }\n return top;\n }\n /**\n * Returns the positions for {@link #panelPositions}.\n *\n * See: {@link module:utils/dom/position~Options#positions}.\n */ _getPanelPositions() {\n const positions = [\n (editableRect, panelRect)=>{\n return {\n top: this._getPanelPositionTop(editableRect, panelRect),\n left: editableRect.left,\n name: 'toolbar_west',\n config: {\n withArrow: false\n }\n };\n },\n (editableRect, panelRect)=>{\n return {\n top: this._getPanelPositionTop(editableRect, panelRect),\n left: editableRect.left + editableRect.width - panelRect.width,\n name: 'toolbar_east',\n config: {\n withArrow: false\n }\n };\n }\n ];\n if (this.locale.uiLanguageDirection === 'ltr') {\n return positions;\n } else {\n return positions.reverse();\n }\n }\n /**\n * Creates an instance of the inline editor UI view.\n *\n * @param locale The {@link module:core/editor/editor~Editor#locale} instance.\n * @param editingView The editing view instance this view is related to.\n * @param editableElement The editable element. If not specified, it will be automatically created by\n * {@link module:ui/editableui/editableuiview~EditableUIView}. Otherwise, the given element will be used.\n * @param options Configuration options for the view instance.\n * @param options.shouldToolbarGroupWhenFull When set `true` enables automatic items grouping\n * in the main {@link module:editor-inline/inlineeditoruiview~InlineEditorUIView#toolbar toolbar}.\n * See {@link module:ui/toolbar/toolbarview~ToolbarOptions#shouldGroupWhenFull} to learn more.\n */ constructor(locale, editingView, editableElement, options = {}){\n super(locale);\n const t = locale.t;\n this.toolbar = new ToolbarView(locale, {\n shouldGroupWhenFull: options.shouldToolbarGroupWhenFull,\n isFloating: true\n });\n this.set('viewportTopOffset', 0);\n this.panel = new BalloonPanelView(locale);\n this.panelPositions = this._getPanelPositions();\n this.panel.extendTemplate({\n attributes: {\n class: 'ck-toolbar-container'\n }\n });\n this.editable = new InlineEditableUIView(locale, editingView, editableElement, {\n label: (editableView)=>{\n return t('Rich Text Editor. Editing area: %0', editableView.name);\n }\n });\n this._resizeObserver = null;\n }\n}\n\n/**\n * The {@glink installation/getting-started/predefined-builds#inline-editor inline editor} implementation.\n * It uses an inline editable and a floating toolbar.\n * See the {@glink examples/builds/inline-editor demo}.\n *\n * In order to create a inline editor instance, use the static\n * {@link module:editor-inline/inlineeditor~InlineEditor.create `InlineEditor.create()`} method.\n *\n * # Inline editor and inline build\n *\n * The inline editor can be used directly from source (if you installed the\n * [`@ckeditor/ckeditor5-editor-inline`](https://www.npmjs.com/package/@ckeditor/ckeditor5-editor-inline) package)\n * but it is also available in the {@glink installation/getting-started/predefined-builds#inline-editor inline build}.\n *\n * {@glink installation/getting-started/predefined-builds Builds}\n * are ready-to-use editors with plugins bundled in. When using the editor from\n * source you need to take care of loading all plugins by yourself\n * (through the {@link module:core/editor/editorconfig~EditorConfig#plugins `config.plugins`} option).\n * Using the editor from source gives much better flexibility and allows easier customization.\n *\n * Read more about initializing the editor from source or as a build in\n * {@link module:editor-inline/inlineeditor~InlineEditor.create `InlineEditor.create()`}.\n */ class InlineEditor extends ElementApiMixin(Editor) {\n /**\n * Destroys the editor instance, releasing all resources used by it.\n *\n * Updates the original editor element with the data if the\n * {@link module:core/editor/editorconfig~EditorConfig#updateSourceElementOnDestroy `updateSourceElementOnDestroy`}\n * configuration option is set to `true`.\n */ destroy() {\n // Cache the data, then destroy.\n // It's safe to assume that the model->view conversion will not work after super.destroy().\n const data = this.getData();\n this.ui.destroy();\n return super.destroy().then(()=>{\n if (this.sourceElement) {\n this.updateSourceElement(data);\n }\n });\n }\n /**\n * Creates a new inline editor instance.\n *\n * There are three general ways how the editor can be initialized.\n *\n * # Using an existing DOM element (and loading data from it)\n *\n * You can initialize the editor using an existing DOM element:\n *\n * ```ts\n * InlineEditor\n * \t.create( document.querySelector( '#editor' ) )\n * \t.then( editor => {\n * \t\tconsole.log( 'Editor was initialized', editor );\n * \t} )\n * \t.catch( err => {\n * \t\tconsole.error( err.stack );\n * \t} );\n * ```\n *\n * The element's content will be used as the editor data and the element will become the editable element.\n *\n * # Creating a detached editor\n *\n * Alternatively, you can initialize the editor by passing the initial data directly as a `String`.\n * In this case, the editor will render an element that must be inserted into the DOM for the editor to work properly:\n *\n * ```ts\n * InlineEditor\n * \t.create( '<p>Hello world!</p>' )\n * \t.then( editor => {\n * \t\tconsole.log( 'Editor was initialized', editor );\n *\n * \t\t// Initial data was provided so the editor UI element needs to be added manually to the DOM.\n * \t\tdocument.body.appendChild( editor.ui.element );\n * \t} )\n * \t.catch( err => {\n * \t\tconsole.error( err.stack );\n * \t} );\n * ```\n *\n * This lets you dynamically append the editor to your web page whenever it is convenient for you. You may use this method if your\n * web page content is generated on the client side and the DOM structure is not ready at the moment when you initialize the editor.\n *\n * # Using an existing DOM element (and data provided in `config.initialData`)\n *\n * You can also mix these two ways by providing a DOM element to be used and passing the initial data through the configuration:\n *\n * ```ts\n * InlineEditor\n * \t.create( document.querySelector( '#editor' ), {\n * \t\tinitialData: '<h2>Initial data</h2><p>Foo bar.</p>'\n * \t} )\n * \t.then( editor => {\n * \t\tconsole.log( 'Editor was initialized', editor );\n * \t} )\n * \t.catch( err => {\n * \t\tconsole.error( err.stack );\n * \t} );\n * ```\n *\n * This method can be used to initialize the editor on an existing element with the specified content in case if your integration\n * makes it difficult to set the content of the source element.\n *\n * Note that an error will be thrown if you pass the initial data both as the first parameter and also in the configuration.\n *\n * # Configuring the editor\n *\n * See the {@link module:core/editor/editorconfig~EditorConfig editor configuration documentation} to learn more about\n * customizing plugins, toolbar and more.\n *\n * # Using the editor from source\n *\n * The code samples listed in the previous sections of this documentation assume that you are using an\n * {@glink installation/getting-started/predefined-builds editor build} (for example – `@ckeditor/ckeditor5-build-inline`).\n *\n * If you want to use the inline editor from source (`@ckeditor/ckeditor5-editor-inline/src/inlineeditor`),\n * you need to define the list of\n * {@link module:core/editor/editorconfig~EditorConfig#plugins plugins to be initialized} and\n * {@link module:core/editor/editorconfig~EditorConfig#toolbar toolbar items}. Read more about using the editor from\n * source in the {@glink installation/advanced/alternative-setups/integrating-from-source-webpack dedicated guide}.\n *\n * @param sourceElementOrData The DOM element that will be the source for the created editor\n * or the editor's initial data.\n *\n * If a DOM element is passed, its content will be automatically loaded to the editor upon initialization.\n * The editor data will be set back to the original element once the editor is destroyed only if the\n * {@link module:core/editor/editorconfig~EditorConfig#updateSourceElementOnDestroy updateSourceElementOnDestroy}\n * option is set to `true`.\n *\n * If the initial data is passed, a detached editor will be created. In this case you need to insert it into the DOM manually.\n * It is available under the {@link module:editor-inline/inlineeditorui~InlineEditorUI#element `editor.ui.element`} property.\n *\n * @param config The editor configuration.\n * @returns A promise resolved once the editor is ready. The promise resolves with the created editor instance.\n */ static create(sourceElementOrData, config = {}) {\n return new Promise((resolve)=>{\n if (isElement(sourceElementOrData) && sourceElementOrData.tagName === 'TEXTAREA') {\n // Documented in core/editor/editor.js\n // eslint-disable-next-line ckeditor5-rules/ckeditor-error-message\n throw new CKEditorError('editor-wrong-element', null);\n }\n const editor = new this(sourceElementOrData, config);\n resolve(editor.initPlugins().then(()=>editor.ui.init()).then(()=>editor.data.init(editor.config.get('initialData'))).then(()=>editor.fire('ready')).then(()=>editor));\n });\n }\n /**\n * Creates an instance of the inline editor.\n *\n * **Note:** Do not use the constructor to create editor instances. Use the static\n * {@link module:editor-inline/inlineeditor~InlineEditor.create `InlineEditor.create()`} method instead.\n *\n * @param sourceElementOrData The DOM element that will be the source for the created editor\n * (on which the editor will be initialized) or initial data for the editor. For more information see\n * {@link module:editor-inline/inlineeditor~InlineEditor.create `InlineEditor.create()`}.\n * @param config The editor configuration.\n */ constructor(sourceElementOrData, config = {}){\n // If both `config.initialData` and initial data parameter in `create()` are set, then throw.\n if (!isElement(sourceElementOrData) && config.initialData !== undefined) {\n // Documented in core/editor/editorconfig.jsdoc.\n // eslint-disable-next-line ckeditor5-rules/ckeditor-error-message\n throw new CKEditorError('editor-create-initial-data', null);\n }\n super(config);\n if (this.config.get('initialData') === undefined) {\n this.config.set('initialData', getInitialData(sourceElementOrData));\n }\n this.model.document.createRoot();\n if (isElement(sourceElementOrData)) {\n this.sourceElement = sourceElementOrData;\n secureSourceElement(this, sourceElementOrData);\n }\n const shouldToolbarGroupWhenFull = !this.config.get('toolbar.shouldNotGroupWhenFull');\n const view = new InlineEditorUIView(this.locale, this.editing.view, this.sourceElement, {\n shouldToolbarGroupWhenFull\n });\n this.ui = new InlineEditorUI(this, view);\n attachToForm(this);\n }\n}\n/**\n * The {@link module:core/context~Context} class.\n *\n * Exposed as static editor field for easier access in editor builds.\n */ InlineEditor.Context = Context;\n/**\n * The {@link module:watchdog/editorwatchdog~EditorWatchdog} class.\n *\n * Exposed as static editor field for easier access in editor builds.\n */ InlineEditor.EditorWatchdog = EditorWatchdog;\n/**\n * The {@link module:watchdog/contextwatchdog~ContextWatchdog} class.\n *\n * Exposed as static editor field for easier access in editor builds.\n */ InlineEditor.ContextWatchdog = ContextWatchdog;\nfunction getInitialData(sourceElementOrData) {\n return isElement(sourceElementOrData) ? getDataFromElement(sourceElementOrData) : sourceElementOrData;\n}\nfunction isElement(value) {\n return isElement$1(value);\n}\n\nexport { InlineEditor };\n//# sourceMappingURL=index.js.map\n","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * @module editor-inline/inlineeditorui\n */\n\nimport {\n\ttype Editor\n} from 'ckeditor5/src/core.js';\n\nimport {\n\tEditorUI,\n\tnormalizeToolbarConfig,\n\ttype EditorUIReadyEvent,\n\ttype EditorUIUpdateEvent\n} from 'ckeditor5/src/ui.js';\n\nimport { enablePlaceholder } from 'ckeditor5/src/engine.js';\n\nimport type InlineEditorUIView from './inlineeditoruiview.js';\n\n/**\n * The inline editor UI class.\n *\n * @extends module:ui/editorui/editorui~EditorUI\n */\nexport default class InlineEditorUI extends EditorUI {\n\t/**\n\t * The main (top–most) view of the editor UI.\n\t */\n\tpublic readonly view: InlineEditorUIView;\n\n\t/**\n\t * A normalized `config.toolbar` object.\n\t */\n\tprivate readonly _toolbarConfig: ReturnType<typeof normalizeToolbarConfig>;\n\n\t/**\n\t * Creates an instance of the inline editor UI class.\n\t *\n\t * @param editor The editor instance.\n\t * @param view The view of the UI.\n\t */\n\tconstructor( editor: Editor, view: InlineEditorUIView ) {\n\t\tsuper( editor );\n\n\t\tthis.view = view;\n\t\tthis._toolbarConfig = normalizeToolbarConfig( editor.config.get( 'toolbar' ) );\n\t}\n\n\t/**\n\t * @inheritDoc\n\t */\n\tpublic override get element(): HTMLElement | null {\n\t\treturn this.view.editable.element;\n\t}\n\n\t/**\n\t * Initializes the UI.\n\t */\n\tpublic init(): void {\n\t\tconst editor = this.editor;\n\t\tconst view = this.view;\n\t\tconst editingView = editor.editing.view;\n\t\tconst editable = view.editable;\n\t\tconst editingRoot = editingView.document.getRoot()!;\n\n\t\t// The editable UI and editing root should share the same name. Then name is used\n\t\t// to recognize the particular editable, for instance in ARIA attributes.\n\t\teditable.name = editingRoot.rootName;\n\n\t\tview.render();\n\n\t\t// The editable UI element in DOM is available for sure only after the editor UI view has been rendered.\n\t\t// But it can be available earlier if a DOM element has been passed to InlineEditor.create().\n\t\tconst editableElement = editable.element!;\n\n\t\t// Register the editable UI view in the editor. A single editor instance can aggregate multiple\n\t\t// editable areas (roots) but the inline editor has only one.\n\t\tthis.setEditableElement( editable.name, editableElement );\n\n\t\t// Let the editable UI element respond to the changes in the global editor focus\n\t\t// tracker. It has been added to the same tracker a few lines above but, in reality, there are\n\t\t// many focusable areas in the editor, like balloons, toolbars or dropdowns and as long\n\t\t// as they have focus, the editable should act like it is focused too (although technically\n\t\t// it isn't), e.g. by setting the proper CSS class, visually announcing focus to the user.\n\t\t// Doing otherwise will result in editable focus styles disappearing, once e.g. the\n\t\t// toolbar gets focused.\n\t\teditable.bind( 'isFocused' ).to( this.focusTracker );\n\n\t\t// Bind the editable UI element to the editing view, making it an end– and entry–point\n\t\t// of the editor's engine. This is where the engine meets the UI.\n\t\teditingView.attachDomRoot( editableElement );\n\n\t\tthis._initPlaceholder();\n\t\tthis._initToolbar();\n\t\tthis.fire<EditorUIReadyEvent>( 'ready' );\n\t}\n\n\t/**\n\t * @inheritDoc\n\t */\n\tpublic override destroy(): void {\n\t\tsuper.destroy();\n\n\t\tconst view = this.view;\n\t\tconst editingView = this.editor.editing.view;\n\n\t\teditingView.detachDomRoot( view.editable.name! );\n\t\tview.destroy();\n\t}\n\n\t/**\n\t * Initializes the inline editor toolbar and its panel.\n\t */\n\tprivate _initToolbar(): void {\n\t\tconst editor = this.editor;\n\t\tconst view = this.view;\n\t\tconst editableElement = view.editable.element!;\n\t\tconst toolbar = view.toolbar;\n\n\t\t// Set–up the view#panel.\n\t\tview.panel.bind( 'isVisible' ).to( this.focusTracker, 'isFocused' );\n\n\t\tview.bind( 'viewportTopOffset' ).to( this, 'viewportOffset', ( { top } ) => top || 0 );\n\n\t\t// https://github.com/ckeditor/ckeditor5-editor-inline/issues/4\n\t\tview.listenTo<EditorUIUpdateEvent>( editor.ui, 'update', () => {\n\t\t\t// Don't pin if the panel is not already visible. It prevents the panel\n\t\t\t// showing up when there's no focus in the UI.\n\t\t\tif ( view.panel.isVisible ) {\n\t\t\t\tview.panel.pin( {\n\t\t\t\t\ttarget: editableElement,\n\t\t\t\t\tpositions: view.panelPositions\n\t\t\t\t} );\n\t\t\t}\n\t\t} );\n\n\t\ttoolbar.fillFromConfig( this._toolbarConfig, this.componentFactory );\n\n\t\t// Register the toolbar so it becomes available for Alt+F10 and Esc navigation.\n\t\tthis.addToolbar( toolbar );\n\t}\n\n\t/**\n\t * Enable the placeholder text on the editing root.\n\t */\n\tprivate _initPlaceholder(): void {\n\t\tconst editor = this.editor;\n\t\tconst editingView = editor.editing.view;\n\t\tconst editingRoot = editingView.document.getRoot()!;\n\t\tconst placeholder = editor.config.get( 'placeholder' );\n\n\t\tif ( placeholder ) {\n\t\t\tconst placeholderText = typeof placeholder === 'string' ? placeholder : placeholder[ editingRoot.rootName ];\n\n\t\t\tif ( placeholderText ) {\n\t\t\t\teditingRoot.placeholder = placeholderText;\n\t\t\t}\n\t\t}\n\n\t\tenablePlaceholder( {\n\t\t\tview: editingView,\n\t\t\telement: editingRoot,\n\t\t\tisDirectHost: false,\n\t\t\tkeepOnFocus: true\n\t\t} );\n\t}\n}\n","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * @module editor-inline/inlineeditoruiview\n */\n\nimport {\n\tBalloonPanelView,\n\tEditorUIView,\n\tInlineEditableUIView,\n\tToolbarView\n} from 'ckeditor5/src/ui.js';\nimport {\n\tRect,\n\tResizeObserver,\n\ttoUnit,\n\ttype PositioningFunction,\n\ttype Locale\n} from 'ckeditor5/src/utils.js';\nimport type { EditingView } from 'ckeditor5/src/engine.js';\n\nconst toPx = toUnit( 'px' );\n\n/**\n * Inline editor UI view. Uses an nline editable and a floating toolbar.\n */\nexport default class InlineEditorUIView extends EditorUIView {\n\t/**\n\t * A floating toolbar view instance.\n\t */\n\tpublic readonly toolbar: ToolbarView;\n\n\t/**\n\t * The offset from the top edge of the web browser's viewport which makes the\n\t * UI become sticky. The default value is `0`, which means that the UI becomes\n\t * sticky when its upper edge touches the top of the page viewport.\n\t *\n\t * This attribute is useful when the web page has UI elements positioned to the top\n\t * either using `position: fixed` or `position: sticky`, which would cover the\n\t * UI or vice–versa (depending on the `z-index` hierarchy).\n\t *\n\t * Bound to {@link module:ui/editorui/editorui~EditorUI#viewportOffset `EditorUI#viewportOffset`}.\n\t *\n\t * If {@link module:core/editor/editorconfig~EditorConfig#ui `EditorConfig#ui.viewportOffset.top`} is defined, then\n\t * it will override the default value.\n\t *\n\t * @observable\n\t * @default 0\n\t */\n\tdeclare public viewportTopOffset: number;\n\n\t/**\n\t * A balloon panel view instance.\n\t */\n\tpublic readonly panel: BalloonPanelView;\n\n\t/**\n\t * A set of positioning functions used by the {@link #panel} to float around\n\t * {@link #element editableElement}.\n\t *\n\t * The positioning functions are as follows:\n\t *\n\t * * West:\n\t *\n\t * ```\n\t * [ Panel ]\n\t * +------------------+\n\t * | #editableElement |\n\t * +------------------+\n\t *\n\t * +------------------+\n\t * | #editableElement |\n\t * |[ Panel ] |\n\t * | |\n\t * +------------------+\n\t *\n\t * +------------------+\n\t * | #editableElement |\n\t * +------------------+\n\t * [ Panel ]\n\t * ```\n\t *\n\t * * East:\n\t *\n\t * ```\n\t * [ Panel ]\n\t * +------------------+\n\t * | #editableElement |\n\t * +------------------+\n\t *\n\t * +------------------+\n\t * | #editableElement |\n\t * | [ Panel ]|\n\t * | |\n\t * +------------------+\n\t *\n\t * +------------------+\n\t * | #editableElement |\n\t * +------------------+\n\t * [ Panel ]\n\t * ```\n\t *\n\t * See: {@link module:utils/dom/position~Options#positions}.\n\t */\n\tpublic readonly panelPositions: Array<PositioningFunction>;\n\n\t/**\n\t * Editable UI view.\n\t */\n\tpublic readonly editable: InlineEditableUIView;\n\n\t/**\n\t * An instance of the resize observer that helps dynamically determine the geometry of the toolbar\n\t * and manage items that do not fit into a single row.\n\t *\n\t * **Note:** Created in {@link #render}.\n\t */\n\tprivate _resizeObserver: ResizeObserver | null;\n\n\t/**\n\t * Creates an instance of the inline editor UI view.\n\t *\n\t * @param locale The {@link module:core/editor/editor~Editor#locale} instance.\n\t * @param editingView The editing view instance this view is related to.\n\t * @param editableElement The editable element. If not specified, it will be automatically created by\n\t * {@link module:ui/editableui/editableuiview~EditableUIView}. Otherwise, the given element will be used.\n\t * @param options Configuration options for the view instance.\n\t * @param options.shouldToolbarGroupWhenFull When set `true` enables automatic items grouping\n\t * in the main {@link module:editor-inline/inlineeditoruiview~InlineEditorUIView#toolbar toolbar}.\n\t * See {@link module:ui/toolbar/toolbarview~ToolbarOptions#shouldGroupWhenFull} to learn more.\n\t */\n\tconstructor(\n\t\tlocale: Locale,\n\t\teditingView: EditingView,\n\t\teditableElement?: HTMLElement,\n\t\toptions: {\n\t\t\tshouldToolbarGroupWhenFull?: boolean;\n\t\t} = {}\n\t) {\n\t\tsuper( locale );\n\n\t\tconst t = locale.t;\n\n\t\tthis.toolbar = new ToolbarView( locale, {\n\t\t\tshouldGroupWhenFull: options.shouldToolbarGroupWhenFull,\n\t\t\tisFloating: true\n\t\t} );\n\n\t\tthis.set( 'viewportTopOffset', 0 );\n\n\t\tthis.panel = new BalloonPanelView( locale );\n\t\tthis.panelPositions = this._getPanelPositions();\n\n\t\tthis.panel.extendTemplate( {\n\t\t\tattributes: {\n\t\t\t\tclass: 'ck-toolbar-container'\n\t\t\t}\n\t\t} );\n\n\t\tthis.editable = new InlineEditableUIView( locale, editingView, editableElement, {\n\t\t\tlabel: editableView => {\n\t\t\t\treturn t( 'Rich Text Editor. Editing area: %0', editableView.name! );\n\t\t\t}\n\t\t} );\n\n\t\tthis._resizeObserver = null;\n\t}\n\n\t/**\n\t * @inheritDoc\n\t */\n\tpublic override render(): void {\n\t\tsuper.render();\n\n\t\tthis.body.add( this.panel );\n\t\tthis.registerChild( this.editable );\n\t\tthis.panel.content.add( this.toolbar );\n\n\t\tconst options = this.toolbar.options;\n\n\t\t// Set toolbar's max-width on the initialization and update it on the editable resize,\n\t\t// if 'shouldToolbarGroupWhenFull' in config is set to 'true'.\n\t\tif ( options.shouldGroupWhenFull ) {\n\t\t\tconst editableElement = this.editable.element!;\n\n\t\t\tthis._resizeObserver = new ResizeObserver( editableElement, () => {\n\t\t\t\tthis.toolbar.maxWidth = toPx( new Rect( editableElement ).width );\n\t\t\t} );\n\t\t}\n\t}\n\n\t/**\n\t * @inheritDoc\n\t */\n\tpublic override destroy(): void {\n\t\tsuper.destroy();\n\n\t\tif ( this._resizeObserver ) {\n\t\t\tthis._resizeObserver.destroy();\n\t\t}\n\t}\n\n\t/**\n\t * Determines the panel top position of the {@link #panel} in {@link #panelPositions}.\n\t *\n\t * @param editableRect Rect of the {@link #element}.\n\t * @param panelRect Rect of the {@link #panel}.\n\t */\n\tprivate _getPanelPositionTop( editableRect: Rect, panelRect: Rect ): number {\n\t\tlet top;\n\n\t\tif ( editableRect.top > panelRect.height + this.viewportTopOffset ) {\n\t\t\ttop = editableRect.top - panelRect.height;\n\t\t} else if ( editableRect.bottom > panelRect.height + this.viewportTopOffset + 50 ) {\n\t\t\ttop = this.viewportTopOffset;\n\t\t} else {\n\t\t\ttop = editableRect.bottom;\n\t\t}\n\n\t\treturn top;\n\t}\n\n\t/**\n\t * Returns the positions for {@link #panelPositions}.\n\t *\n\t * See: {@link module:utils/dom/position~Options#positions}.\n\t */\n\tprivate _getPanelPositions(): Array<PositioningFunction> {\n\t\tconst positions: Array<PositioningFunction> = [\n\t\t\t( editableRect, panelRect ) => {\n\t\t\t\treturn {\n\t\t\t\t\ttop: this._getPanelPositionTop( editableRect, panelRect ),\n\t\t\t\t\tleft: editableRect.left,\n\t\t\t\t\tname: 'toolbar_west',\n\t\t\t\t\tconfig: {\n\t\t\t\t\t\twithArrow: false\n\t\t\t\t\t}\n\t\t\t\t};\n\t\t\t},\n\t\t\t( editableRect, panelRect ) => {\n\t\t\t\treturn {\n\t\t\t\t\ttop: this._getPanelPositionTop( editableRect, panelRect ),\n\t\t\t\t\tleft: editableRect.left + editableRect.width - panelRect.width,\n\t\t\t\t\tname: 'toolbar_east',\n\t\t\t\t\tconfig: {\n\t\t\t\t\t\twithArrow: false\n\t\t\t\t\t}\n\t\t\t\t};\n\t\t\t}\n\t\t];\n\n\t\tif ( this.locale.uiLanguageDirection === 'ltr' ) {\n\t\t\treturn positions;\n\t\t} else {\n\t\t\treturn positions.reverse();\n\t\t}\n\t}\n}\n","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * @module editor-inline/inlineeditor\n */\n\nimport {\n\tEditor,\n\tContext,\n\tElementApiMixin,\n\tattachToForm,\n\tsecureSourceElement,\n\ttype EditorConfig,\n\ttype EditorReadyEvent\n} from 'ckeditor5/src/core.js';\nimport { getDataFromElement, CKEditorError } from 'ckeditor5/src/utils.js';\n\nimport { ContextWatchdog, EditorWatchdog } from 'ckeditor5/src/watchdog.js';\n\nimport InlineEditorUI from './inlineeditorui.js';\nimport InlineEditorUIView from './inlineeditoruiview.js';\n\nimport { isElement as _isElement } from 'lodash-es';\n\n/**\n * The {@glink installation/getting-started/predefined-builds#inline-editor inline editor} implementation.\n * It uses an inline editable and a floating toolbar.\n * See the {@glink examples/builds/inline-editor demo}.\n *\n * In order to create a inline editor instance, use the static\n * {@link module:editor-inline/inlineeditor~InlineEditor.create `InlineEditor.create()`} method.\n *\n * # Inline editor and inline build\n *\n * The inline editor can be used directly from source (if you installed the\n * [`@ckeditor/ckeditor5-editor-inline`](https://www.npmjs.com/package/@ckeditor/ckeditor5-editor-inline) package)\n * but it is also available in the {@glink installation/getting-started/predefined-builds#inline-editor inline build}.\n *\n * {@glink installation/getting-started/predefined-builds Builds}\n * are ready-to-use editors with plugins bundled in. When using the editor from\n * source you need to take care of loading all plugins by yourself\n * (through the {@link module:core/editor/editorconfig~EditorConfig#plugins `config.plugins`} option).\n * Using the editor from source gives much better flexibility and allows easier customization.\n *\n * Read more about initializing the editor from source or as a build in\n * {@link module:editor-inline/inlineeditor~InlineEditor.create `InlineEditor.create()`}.\n */\nexport default class InlineEditor extends ElementApiMixin( Editor ) {\n\t/**\n\t * @inheritDoc\n\t */\n\tpublic readonly ui: InlineEditorUI;\n\n\t/**\n\t * Creates an instance of the inline editor.\n\t *\n\t * **Note:** Do not use the constructor to create editor instances. Use the static\n\t * {@link module:editor-inline/inlineeditor~InlineEditor.create `InlineEditor.create()`} method instead.\n\t *\n\t * @param sourceElementOrData The DOM element that will be the source for the created editor\n\t * (on which the editor will be initialized) or initial data for the editor. For more information see\n\t * {@link module:editor-inline/inlineeditor~InlineEditor.create `InlineEditor.create()`}.\n\t * @param config The editor configuration.\n\t */\n\tprotected constructor( sourceElementOrData: HTMLElement | string, config: EditorConfig = {} ) {\n\t\t// If both `config.initialData` and initial data parameter in `create()` are set, then throw.\n\t\tif ( !isElement( sourceElementOrData ) && config.initialData !== undefined ) {\n\t\t\t// Documented in core/editor/editorconfig.jsdoc.\n\t\t\t// eslint-disable-next-line ckeditor5-rules/ckeditor-error-message\n\t\t\tthrow new CKEditorError( 'editor-create-initial-data', null );\n\t\t}\n\n\t\tsuper( config );\n\n\t\tif ( this.config.get( 'initialData' ) === undefined ) {\n\t\t\tthis.config.set( 'initialData', getInitialData( sourceElementOrData ) );\n\t\t}\n\n\t\tthis.model.document.createRoot();\n\n\t\tif ( isElement( sourceElementOrData ) ) {\n\t\t\tthis.sourceElement = sourceElementOrData;\n\t\t\tsecureSourceElement( this, sourceElementOrData );\n\t\t}\n\n\t\tconst shouldToolbarGroupWhenFull = !this.config.get( 'toolbar.shouldNotGroupWhenFull' );\n\n\t\tconst view = new InlineEditorUIView( this.locale, this.editing.view, this.sourceElement, {\n\t\t\tshouldToolbarGroupWhenFull\n\t\t} );\n\t\tthis.ui = new InlineEditorUI( this, view );\n\n\t\tattachToForm( this );\n\t}\n\n\t/**\n\t * Destroys the editor instance, releasing all resources used by it.\n\t *\n\t * Updates the original editor element with the data if the\n\t * {@link module:core/editor/editorconfig~EditorConfig#updateSourceElementOnDestroy `updateSourceElementOnDestroy`}\n\t * configuration option is set to `true`.\n\t */\n\tpublic override destroy(): Promise<unknown> {\n\t\t// Cache the data, then destroy.\n\t\t// It's safe to assume that the model->view conversion will not work after super.destroy().\n\t\tconst data = this.getData();\n\n\t\tthis.ui.destroy();\n\n\t\treturn super.destroy()\n\t\t\t.then( () => {\n\t\t\t\tif ( this.sourceElement ) {\n\t\t\t\t\tthis.updateSourceElement( data );\n\t\t\t\t}\n\t\t\t} );\n\t}\n\n\t/**\n\t * Creates a new inline editor instance.\n\t *\n\t * There are three general ways how the editor can be initialized.\n\t *\n\t * # Using an existing DOM element (and loading data from it)\n\t *\n\t * You can initialize the editor using an existing DOM element:\n\t *\n\t * ```ts\n\t * InlineEditor\n\t * \t.create( document.querySelector( '#editor' ) )\n\t * \t.then( editor => {\n\t * \t\tconsole.log( 'Editor was initialized', editor );\n\t * \t} )\n\t * \t.catch( err => {\n\t * \t\tconsole.error( err.stack );\n\t * \t} );\n\t * ```\n\t *\n\t * The element's content will be used as the editor data and the element will become the editable element.\n\t *\n\t * # Creating a detached editor\n\t *\n\t * Alternatively, you can initialize the editor by passing the initial data directly as a `String`.\n\t * In this case, the editor will render an element that must be inserted into the DOM for the editor to work properly:\n\t *\n\t * ```ts\n\t * InlineEditor\n\t * \t.create( '<p>Hello world!</p>' )\n\t * \t.then( editor => {\n\t * \t\tconsole.log( 'Editor was initialized', editor );\n\t *\n\t * \t\t// Initial data was provided so the editor UI element needs to be added manually to the DOM.\n\t * \t\tdocument.body.appendChild( editor.ui.element );\n\t * \t} )\n\t * \t.catch( err => {\n\t * \t\tconsole.error( err.stack );\n\t * \t} );\n\t * ```\n\t *\n\t * This lets you dynamically append the editor to your web page whenever it is convenient for you. You may use this method if your\n\t * web page content is generated on the client side and the DOM structure is not ready at the moment when you initialize the editor.\n\t *\n\t * # Using an existing DOM element (and data provided in `config.initialData`)\n\t *\n\t * You can also mix these two ways by providing a DOM element to be used and passing the initial data through the configuration:\n\t *\n\t * ```ts\n\t * InlineEditor\n\t * \t.create( document.querySelector( '#editor' ), {\n\t * \t\tinitialData: '<h2>Initial data</h2><p>Foo bar.</p>'\n\t * \t} )\n\t * \t.then( editor => {\n\t * \t\tconsole.log( 'Editor was initialized', editor );\n\t * \t} )\n\t * \t.catch( err => {\n\t * \t\tconsole.error( err.stack );\n\t * \t} );\n\t * ```\n\t *\n\t * This method can be used to initialize the editor on an existing element with the specified content in case if your integration\n\t * makes it difficult to set the content of the source element.\n\t *\n\t * Note that an error will be thrown if you pass the initial data both as the first parameter and also in the configuration.\n\t *\n\t * # Configuring the editor\n\t *\n\t * See the {@link module:core/editor/editorconfig~EditorConfig editor configuration documentation} to learn more about\n\t * customizing plugins, toolbar and more.\n\t *\n\t * # Using the editor from source\n\t *\n\t * The code samples listed in the previous sections of this documentation assume that you are using an\n\t * {@glink installation/getting-started/predefined-builds editor build} (for example – `@ckeditor/ckeditor5-build-inline`).\n\t *\n\t * If you want to use the inline editor from source (`@ckeditor/ckeditor5-editor-inline/src/inlineeditor`),\n\t * you need to define the list of\n\t * {@link module:core/editor/editorconfig~EditorConfig#plugins plugins to be initialized} and\n\t * {@link module:core/editor/editorconfig~EditorConfig#toolbar toolbar items}. Read more about using the editor from\n\t * source in the {@glink installation/advanced/alternative-setups/integrating-from-source-webpack dedicated guide}.\n\t *\n\t * @param sourceElementOrData The DOM element that will be the source for the created editor\n\t * or the editor's initial data.\n\t *\n\t * If a DOM element is passed, its content will be automatically loaded to the editor upon initialization.\n\t * The editor data will be set back to the original element once the editor is destroyed only if the\n\t * {@link module:core/editor/editorconfig~EditorConfig#updateSourceElementOnDestroy updateSourceElementOnDestroy}\n\t * option is set to `true`.\n\t *\n\t * If the initial data is passed, a detached editor will be created. In this case you need to insert it into the DOM manually.\n\t * It is available under the {@link module:editor-inline/inlineeditorui~InlineEditorUI#element `editor.ui.element`} property.\n\t *\n\t * @param config The editor configuration.\n\t * @returns A promise resolved once the editor is ready. The promise resolves with the created editor instance.\n\t */\n\tpublic static override create( sourceElementOrData: HTMLElement | string, config: EditorConfig = {} ): Promise<InlineEditor> {\n\t\treturn new Promise( resolve => {\n\t\t\tif ( isElement( sourceElementOrData ) && sourceElementOrData.tagName === 'TEXTAREA' ) {\n\t\t\t\t// Documented in core/editor/editor.js\n\t\t\t\t// eslint-disable-next-line ckeditor5-rules/ckeditor-error-message\n\t\t\t\tthrow new CKEditorError( 'editor-wrong-element', null );\n\t\t\t}\n\n\t\t\tconst editor = new this( sourceElementOrData, config );\n\n\t\t\tresolve(\n\t\t\t\teditor.initPlugins()\n\t\t\t\t\t.then( () => editor.ui.init() )\n\t\t\t\t\t.then( () => editor.data.init( editor.config.get( 'initialData' )! ) )\n\t\t\t\t\t.then( () => editor.fire<EditorReadyEvent>( 'ready' ) )\n\t\t\t\t\t.then( () => editor )\n\t\t\t);\n\t\t} );\n\t}\n\n\t/**\n\t * The {@link module:core/context~Context} class.\n\t *\n\t * Exposed as static editor field for easier access in editor builds.\n\t */\n\tpublic static Context = Context;\n\n\t/**\n\t * The {@link module:watchdog/editorwatchdog~EditorWatchdog} class.\n\t *\n\t * Exposed as static editor field for easier access in editor builds.\n\t */\n\tpublic static EditorWatchdog = EditorWatchdog;\n\n\t/**\n\t * The {@link module:watchdog/contextwatchdog~ContextWatchdog} class.\n\t *\n\t * Exposed as static editor field for easier access in editor builds.\n\t */\n\tpublic static ContextWatchdog = ContextWatchdog;\n}\n\nfunction getInitialData( sourceElementOrData: HTMLElement | string ): string {\n\treturn isElement( sourceElementOrData ) ? getDataFromElement( sourceElementOrData ) : sourceElementOrData;\n}\n\nfunction isElement( value: any ): value is Element {\n\treturn _isElement( value );\n}\n"]}
|
@@ -0,0 +1,12 @@
|
|
1
|
+
/**
|
2
|
+
* @license Copyright (c) 2003-2024, 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
|
+
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
7
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
8
|
+
*/
|
9
|
+
/**
|
10
|
+
* @module editor-inline
|
11
|
+
*/
|
12
|
+
export { default as InlineEditor } from './inlineeditor.js';
|
@@ -0,0 +1,180 @@
|
|
1
|
+
/**
|
2
|
+
* @license Copyright (c) 2003-2024, 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
|
+
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
7
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
8
|
+
*/
|
9
|
+
/**
|
10
|
+
* @module editor-inline/inlineeditor
|
11
|
+
*/
|
12
|
+
import { Editor, Context, type EditorConfig } from 'ckeditor5/src/core.js';
|
13
|
+
import { ContextWatchdog, EditorWatchdog } from 'ckeditor5/src/watchdog.js';
|
14
|
+
import InlineEditorUI from './inlineeditorui.js';
|
15
|
+
declare const InlineEditor_base: import("ckeditor5/src/utils.js").Mixed<typeof Editor, import("ckeditor5/src/core.js").ElementApi>;
|
16
|
+
/**
|
17
|
+
* The {@glink installation/getting-started/predefined-builds#inline-editor inline editor} implementation.
|
18
|
+
* It uses an inline editable and a floating toolbar.
|
19
|
+
* See the {@glink examples/builds/inline-editor demo}.
|
20
|
+
*
|
21
|
+
* In order to create a inline editor instance, use the static
|
22
|
+
* {@link module:editor-inline/inlineeditor~InlineEditor.create `InlineEditor.create()`} method.
|
23
|
+
*
|
24
|
+
* # Inline editor and inline build
|
25
|
+
*
|
26
|
+
* The inline editor can be used directly from source (if you installed the
|
27
|
+
* [`@ckeditor/ckeditor5-editor-inline`](https://www.npmjs.com/package/@ckeditor/ckeditor5-editor-inline) package)
|
28
|
+
* but it is also available in the {@glink installation/getting-started/predefined-builds#inline-editor inline build}.
|
29
|
+
*
|
30
|
+
* {@glink installation/getting-started/predefined-builds Builds}
|
31
|
+
* are ready-to-use editors with plugins bundled in. When using the editor from
|
32
|
+
* source you need to take care of loading all plugins by yourself
|
33
|
+
* (through the {@link module:core/editor/editorconfig~EditorConfig#plugins `config.plugins`} option).
|
34
|
+
* Using the editor from source gives much better flexibility and allows easier customization.
|
35
|
+
*
|
36
|
+
* Read more about initializing the editor from source or as a build in
|
37
|
+
* {@link module:editor-inline/inlineeditor~InlineEditor.create `InlineEditor.create()`}.
|
38
|
+
*/
|
39
|
+
export default class InlineEditor extends InlineEditor_base {
|
40
|
+
/**
|
41
|
+
* @inheritDoc
|
42
|
+
*/
|
43
|
+
readonly ui: InlineEditorUI;
|
44
|
+
/**
|
45
|
+
* Creates an instance of the inline editor.
|
46
|
+
*
|
47
|
+
* **Note:** Do not use the constructor to create editor instances. Use the static
|
48
|
+
* {@link module:editor-inline/inlineeditor~InlineEditor.create `InlineEditor.create()`} method instead.
|
49
|
+
*
|
50
|
+
* @param sourceElementOrData The DOM element that will be the source for the created editor
|
51
|
+
* (on which the editor will be initialized) or initial data for the editor. For more information see
|
52
|
+
* {@link module:editor-inline/inlineeditor~InlineEditor.create `InlineEditor.create()`}.
|
53
|
+
* @param config The editor configuration.
|
54
|
+
*/
|
55
|
+
protected constructor(sourceElementOrData: HTMLElement | string, config?: EditorConfig);
|
56
|
+
/**
|
57
|
+
* Destroys the editor instance, releasing all resources used by it.
|
58
|
+
*
|
59
|
+
* Updates the original editor element with the data if the
|
60
|
+
* {@link module:core/editor/editorconfig~EditorConfig#updateSourceElementOnDestroy `updateSourceElementOnDestroy`}
|
61
|
+
* configuration option is set to `true`.
|
62
|
+
*/
|
63
|
+
destroy(): Promise<unknown>;
|
64
|
+
/**
|
65
|
+
* Creates a new inline editor instance.
|
66
|
+
*
|
67
|
+
* There are three general ways how the editor can be initialized.
|
68
|
+
*
|
69
|
+
* # Using an existing DOM element (and loading data from it)
|
70
|
+
*
|
71
|
+
* You can initialize the editor using an existing DOM element:
|
72
|
+
*
|
73
|
+
* ```ts
|
74
|
+
* InlineEditor
|
75
|
+
* .create( document.querySelector( '#editor' ) )
|
76
|
+
* .then( editor => {
|
77
|
+
* console.log( 'Editor was initialized', editor );
|
78
|
+
* } )
|
79
|
+
* .catch( err => {
|
80
|
+
* console.error( err.stack );
|
81
|
+
* } );
|
82
|
+
* ```
|
83
|
+
*
|
84
|
+
* The element's content will be used as the editor data and the element will become the editable element.
|
85
|
+
*
|
86
|
+
* # Creating a detached editor
|
87
|
+
*
|
88
|
+
* Alternatively, you can initialize the editor by passing the initial data directly as a `String`.
|
89
|
+
* In this case, the editor will render an element that must be inserted into the DOM for the editor to work properly:
|
90
|
+
*
|
91
|
+
* ```ts
|
92
|
+
* InlineEditor
|
93
|
+
* .create( '<p>Hello world!</p>' )
|
94
|
+
* .then( editor => {
|
95
|
+
* console.log( 'Editor was initialized', editor );
|
96
|
+
*
|
97
|
+
* // Initial data was provided so the editor UI element needs to be added manually to the DOM.
|
98
|
+
* document.body.appendChild( editor.ui.element );
|
99
|
+
* } )
|
100
|
+
* .catch( err => {
|
101
|
+
* console.error( err.stack );
|
102
|
+
* } );
|
103
|
+
* ```
|
104
|
+
*
|
105
|
+
* This lets you dynamically append the editor to your web page whenever it is convenient for you. You may use this method if your
|
106
|
+
* web page content is generated on the client side and the DOM structure is not ready at the moment when you initialize the editor.
|
107
|
+
*
|
108
|
+
* # Using an existing DOM element (and data provided in `config.initialData`)
|
109
|
+
*
|
110
|
+
* You can also mix these two ways by providing a DOM element to be used and passing the initial data through the configuration:
|
111
|
+
*
|
112
|
+
* ```ts
|
113
|
+
* InlineEditor
|
114
|
+
* .create( document.querySelector( '#editor' ), {
|
115
|
+
* initialData: '<h2>Initial data</h2><p>Foo bar.</p>'
|
116
|
+
* } )
|
117
|
+
* .then( editor => {
|
118
|
+
* console.log( 'Editor was initialized', editor );
|
119
|
+
* } )
|
120
|
+
* .catch( err => {
|
121
|
+
* console.error( err.stack );
|
122
|
+
* } );
|
123
|
+
* ```
|
124
|
+
*
|
125
|
+
* This method can be used to initialize the editor on an existing element with the specified content in case if your integration
|
126
|
+
* makes it difficult to set the content of the source element.
|
127
|
+
*
|
128
|
+
* Note that an error will be thrown if you pass the initial data both as the first parameter and also in the configuration.
|
129
|
+
*
|
130
|
+
* # Configuring the editor
|
131
|
+
*
|
132
|
+
* See the {@link module:core/editor/editorconfig~EditorConfig editor configuration documentation} to learn more about
|
133
|
+
* customizing plugins, toolbar and more.
|
134
|
+
*
|
135
|
+
* # Using the editor from source
|
136
|
+
*
|
137
|
+
* The code samples listed in the previous sections of this documentation assume that you are using an
|
138
|
+
* {@glink installation/getting-started/predefined-builds editor build} (for example – `@ckeditor/ckeditor5-build-inline`).
|
139
|
+
*
|
140
|
+
* If you want to use the inline editor from source (`@ckeditor/ckeditor5-editor-inline/src/inlineeditor`),
|
141
|
+
* you need to define the list of
|
142
|
+
* {@link module:core/editor/editorconfig~EditorConfig#plugins plugins to be initialized} and
|
143
|
+
* {@link module:core/editor/editorconfig~EditorConfig#toolbar toolbar items}. Read more about using the editor from
|
144
|
+
* source in the {@glink installation/advanced/alternative-setups/integrating-from-source-webpack dedicated guide}.
|
145
|
+
*
|
146
|
+
* @param sourceElementOrData The DOM element that will be the source for the created editor
|
147
|
+
* or the editor's initial data.
|
148
|
+
*
|
149
|
+
* If a DOM element is passed, its content will be automatically loaded to the editor upon initialization.
|
150
|
+
* The editor data will be set back to the original element once the editor is destroyed only if the
|
151
|
+
* {@link module:core/editor/editorconfig~EditorConfig#updateSourceElementOnDestroy updateSourceElementOnDestroy}
|
152
|
+
* option is set to `true`.
|
153
|
+
*
|
154
|
+
* If the initial data is passed, a detached editor will be created. In this case you need to insert it into the DOM manually.
|
155
|
+
* It is available under the {@link module:editor-inline/inlineeditorui~InlineEditorUI#element `editor.ui.element`} property.
|
156
|
+
*
|
157
|
+
* @param config The editor configuration.
|
158
|
+
* @returns A promise resolved once the editor is ready. The promise resolves with the created editor instance.
|
159
|
+
*/
|
160
|
+
static create(sourceElementOrData: HTMLElement | string, config?: EditorConfig): Promise<InlineEditor>;
|
161
|
+
/**
|
162
|
+
* The {@link module:core/context~Context} class.
|
163
|
+
*
|
164
|
+
* Exposed as static editor field for easier access in editor builds.
|
165
|
+
*/
|
166
|
+
static Context: typeof Context;
|
167
|
+
/**
|
168
|
+
* The {@link module:watchdog/editorwatchdog~EditorWatchdog} class.
|
169
|
+
*
|
170
|
+
* Exposed as static editor field for easier access in editor builds.
|
171
|
+
*/
|
172
|
+
static EditorWatchdog: typeof EditorWatchdog;
|
173
|
+
/**
|
174
|
+
* The {@link module:watchdog/contextwatchdog~ContextWatchdog} class.
|
175
|
+
*
|
176
|
+
* Exposed as static editor field for easier access in editor builds.
|
177
|
+
*/
|
178
|
+
static ContextWatchdog: typeof ContextWatchdog;
|
179
|
+
}
|
180
|
+
export {};
|
@@ -0,0 +1,56 @@
|
|
1
|
+
/**
|
2
|
+
* @license Copyright (c) 2003-2024, 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
|
+
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
7
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
8
|
+
*/
|
9
|
+
/**
|
10
|
+
* @module editor-inline/inlineeditorui
|
11
|
+
*/
|
12
|
+
import { type Editor } from 'ckeditor5/src/core.js';
|
13
|
+
import { EditorUI } from 'ckeditor5/src/ui.js';
|
14
|
+
import type InlineEditorUIView from './inlineeditoruiview.js';
|
15
|
+
/**
|
16
|
+
* The inline editor UI class.
|
17
|
+
*
|
18
|
+
* @extends module:ui/editorui/editorui~EditorUI
|
19
|
+
*/
|
20
|
+
export default class InlineEditorUI extends EditorUI {
|
21
|
+
/**
|
22
|
+
* The main (top–most) view of the editor UI.
|
23
|
+
*/
|
24
|
+
readonly view: InlineEditorUIView;
|
25
|
+
/**
|
26
|
+
* A normalized `config.toolbar` object.
|
27
|
+
*/
|
28
|
+
private readonly _toolbarConfig;
|
29
|
+
/**
|
30
|
+
* Creates an instance of the inline editor UI class.
|
31
|
+
*
|
32
|
+
* @param editor The editor instance.
|
33
|
+
* @param view The view of the UI.
|
34
|
+
*/
|
35
|
+
constructor(editor: Editor, view: InlineEditorUIView);
|
36
|
+
/**
|
37
|
+
* @inheritDoc
|
38
|
+
*/
|
39
|
+
get element(): HTMLElement | null;
|
40
|
+
/**
|
41
|
+
* Initializes the UI.
|
42
|
+
*/
|
43
|
+
init(): void;
|
44
|
+
/**
|
45
|
+
* @inheritDoc
|
46
|
+
*/
|
47
|
+
destroy(): void;
|
48
|
+
/**
|
49
|
+
* Initializes the inline editor toolbar and its panel.
|
50
|
+
*/
|
51
|
+
private _initToolbar;
|
52
|
+
/**
|
53
|
+
* Enable the placeholder text on the editing root.
|
54
|
+
*/
|
55
|
+
private _initPlaceholder;
|
56
|
+
}
|
@@ -0,0 +1,141 @@
|
|
1
|
+
/**
|
2
|
+
* @license Copyright (c) 2003-2024, 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
|
+
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
7
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
8
|
+
*/
|
9
|
+
/**
|
10
|
+
* @module editor-inline/inlineeditoruiview
|
11
|
+
*/
|
12
|
+
import { BalloonPanelView, EditorUIView, InlineEditableUIView, ToolbarView } from 'ckeditor5/src/ui.js';
|
13
|
+
import { type PositioningFunction, type Locale } from 'ckeditor5/src/utils.js';
|
14
|
+
import type { EditingView } from 'ckeditor5/src/engine.js';
|
15
|
+
/**
|
16
|
+
* Inline editor UI view. Uses an nline editable and a floating toolbar.
|
17
|
+
*/
|
18
|
+
export default class InlineEditorUIView extends EditorUIView {
|
19
|
+
/**
|
20
|
+
* A floating toolbar view instance.
|
21
|
+
*/
|
22
|
+
readonly toolbar: ToolbarView;
|
23
|
+
/**
|
24
|
+
* The offset from the top edge of the web browser's viewport which makes the
|
25
|
+
* UI become sticky. The default value is `0`, which means that the UI becomes
|
26
|
+
* sticky when its upper edge touches the top of the page viewport.
|
27
|
+
*
|
28
|
+
* This attribute is useful when the web page has UI elements positioned to the top
|
29
|
+
* either using `position: fixed` or `position: sticky`, which would cover the
|
30
|
+
* UI or vice–versa (depending on the `z-index` hierarchy).
|
31
|
+
*
|
32
|
+
* Bound to {@link module:ui/editorui/editorui~EditorUI#viewportOffset `EditorUI#viewportOffset`}.
|
33
|
+
*
|
34
|
+
* If {@link module:core/editor/editorconfig~EditorConfig#ui `EditorConfig#ui.viewportOffset.top`} is defined, then
|
35
|
+
* it will override the default value.
|
36
|
+
*
|
37
|
+
* @observable
|
38
|
+
* @default 0
|
39
|
+
*/
|
40
|
+
viewportTopOffset: number;
|
41
|
+
/**
|
42
|
+
* A balloon panel view instance.
|
43
|
+
*/
|
44
|
+
readonly panel: BalloonPanelView;
|
45
|
+
/**
|
46
|
+
* A set of positioning functions used by the {@link #panel} to float around
|
47
|
+
* {@link #element editableElement}.
|
48
|
+
*
|
49
|
+
* The positioning functions are as follows:
|
50
|
+
*
|
51
|
+
* * West:
|
52
|
+
*
|
53
|
+
* ```
|
54
|
+
* [ Panel ]
|
55
|
+
* +------------------+
|
56
|
+
* | #editableElement |
|
57
|
+
* +------------------+
|
58
|
+
*
|
59
|
+
* +------------------+
|
60
|
+
* | #editableElement |
|
61
|
+
* |[ Panel ] |
|
62
|
+
* | |
|
63
|
+
* +------------------+
|
64
|
+
*
|
65
|
+
* +------------------+
|
66
|
+
* | #editableElement |
|
67
|
+
* +------------------+
|
68
|
+
* [ Panel ]
|
69
|
+
* ```
|
70
|
+
*
|
71
|
+
* * East:
|
72
|
+
*
|
73
|
+
* ```
|
74
|
+
* [ Panel ]
|
75
|
+
* +------------------+
|
76
|
+
* | #editableElement |
|
77
|
+
* +------------------+
|
78
|
+
*
|
79
|
+
* +------------------+
|
80
|
+
* | #editableElement |
|
81
|
+
* | [ Panel ]|
|
82
|
+
* | |
|
83
|
+
* +------------------+
|
84
|
+
*
|
85
|
+
* +------------------+
|
86
|
+
* | #editableElement |
|
87
|
+
* +------------------+
|
88
|
+
* [ Panel ]
|
89
|
+
* ```
|
90
|
+
*
|
91
|
+
* See: {@link module:utils/dom/position~Options#positions}.
|
92
|
+
*/
|
93
|
+
readonly panelPositions: Array<PositioningFunction>;
|
94
|
+
/**
|
95
|
+
* Editable UI view.
|
96
|
+
*/
|
97
|
+
readonly editable: InlineEditableUIView;
|
98
|
+
/**
|
99
|
+
* An instance of the resize observer that helps dynamically determine the geometry of the toolbar
|
100
|
+
* and manage items that do not fit into a single row.
|
101
|
+
*
|
102
|
+
* **Note:** Created in {@link #render}.
|
103
|
+
*/
|
104
|
+
private _resizeObserver;
|
105
|
+
/**
|
106
|
+
* Creates an instance of the inline editor UI view.
|
107
|
+
*
|
108
|
+
* @param locale The {@link module:core/editor/editor~Editor#locale} instance.
|
109
|
+
* @param editingView The editing view instance this view is related to.
|
110
|
+
* @param editableElement The editable element. If not specified, it will be automatically created by
|
111
|
+
* {@link module:ui/editableui/editableuiview~EditableUIView}. Otherwise, the given element will be used.
|
112
|
+
* @param options Configuration options for the view instance.
|
113
|
+
* @param options.shouldToolbarGroupWhenFull When set `true` enables automatic items grouping
|
114
|
+
* in the main {@link module:editor-inline/inlineeditoruiview~InlineEditorUIView#toolbar toolbar}.
|
115
|
+
* See {@link module:ui/toolbar/toolbarview~ToolbarOptions#shouldGroupWhenFull} to learn more.
|
116
|
+
*/
|
117
|
+
constructor(locale: Locale, editingView: EditingView, editableElement?: HTMLElement, options?: {
|
118
|
+
shouldToolbarGroupWhenFull?: boolean;
|
119
|
+
});
|
120
|
+
/**
|
121
|
+
* @inheritDoc
|
122
|
+
*/
|
123
|
+
render(): void;
|
124
|
+
/**
|
125
|
+
* @inheritDoc
|
126
|
+
*/
|
127
|
+
destroy(): void;
|
128
|
+
/**
|
129
|
+
* Determines the panel top position of the {@link #panel} in {@link #panelPositions}.
|
130
|
+
*
|
131
|
+
* @param editableRect Rect of the {@link #element}.
|
132
|
+
* @param panelRect Rect of the {@link #panel}.
|
133
|
+
*/
|
134
|
+
private _getPanelPositionTop;
|
135
|
+
/**
|
136
|
+
* Returns the positions for {@link #panelPositions}.
|
137
|
+
*
|
138
|
+
* See: {@link module:utils/dom/position~Options#positions}.
|
139
|
+
*/
|
140
|
+
private _getPanelPositions;
|
141
|
+
}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@ckeditor/ckeditor5-editor-inline",
|
3
|
-
"version": "41.
|
3
|
+
"version": "41.4.0",
|
4
4
|
"description": "Inline editor implementation for CKEditor 5.",
|
5
5
|
"keywords": [
|
6
6
|
"ckeditor",
|
@@ -12,7 +12,7 @@
|
|
12
12
|
"type": "module",
|
13
13
|
"main": "src/index.js",
|
14
14
|
"dependencies": {
|
15
|
-
"ckeditor5": "41.
|
15
|
+
"ckeditor5": "41.4.0",
|
16
16
|
"lodash-es": "4.17.21"
|
17
17
|
},
|
18
18
|
"author": "CKSource (http://cksource.com/)",
|
@@ -25,6 +25,7 @@
|
|
25
25
|
"directory": "packages/ckeditor5-editor-inline"
|
26
26
|
},
|
27
27
|
"files": [
|
28
|
+
"dist",
|
28
29
|
"lang",
|
29
30
|
"src/**/*.js",
|
30
31
|
"src/**/*.d.ts",
|