AbstractEditorHandler (fullscreen/handlers)
@ckeditor/ckeditor5-fullscreen/src/handlers/abstracteditorhandler
The abstract editor type handler. It should be extended by the particular editor type handler.
Filtering
Properties
-
updateDialogPositionCallback : ( EventInfo<string, unknown>, string, boolean ) => void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#updateDialogPositionCallback
Stores a bound reference to the _updateDialogPosition method, allowing it to be attached and detached from change event.
-
protected
_closeRevisionViewerCallback : null | ( default ) => Promise<unknown>
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_closeRevisionViewerCallback
A callback that closes the revision viewer, stored to restore the original one after exiting the fullscreen mode.
-
protected
_editor : object
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_editor
An editor instance. It should be set by the particular editor type handler.
-
protected
_showRevisionViewerCallback : null | ( EditorConfig ) => Promise<null | default>
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_showRevisionViewerCallback
A callback that shows the revision viewer, stored to restore the original one after exiting the fullscreen mode.
-
private
_annotationsUIsData : null | Map<string, Record<string, any>>
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_annotationsUIsData
Data of the annotations UIs that were active before entering the fullscreen mode.
-
private
_document : Document
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_document
The document object in which the editor is located.
-
private
_hiddenElements : Map<HTMLElement, string>
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_hiddenElements
A map of elements that were hidden when entering the fullscreen mode. It is used to restore their previous visibility when leaving the fullscreen mode and avoid showing elements that were hidden before entering the fullscreen mode.
-
private
_paginationBodyCollection : null | BodyCollection
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_paginationBodyCollection
The pagination body collection that is used in the fullscreen mode. If we don't move pagination lines to the fullscreen container, they won't be visible.
-
private
_placeholderMap : Map<string, object>
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_placeholderMap
Maps placeholder names to placeholder elements and moved elements.
-
private
_savedAncestorsScrollPositions : Map<HTMLElement, object>
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_savedAncestorsScrollPositions
A map matching the ancestors of the editable element with their scroll positions before entering fullscreen mode.
-
private
_wrapper : null | HTMLElement
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_wrapper
The wrapper element that holds the fullscreen mode layout.
Methods
-
constructor( editor )
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#constructor
-
destroy() → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#destroy
-
disable() → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#disable
Disables the fullscreen mode by restoring all moved elements and destroying the fullscreen container.
Returns
void
-
enable() → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#enable
Enables the fullscreen mode. It executes the editor-specific enable handler and then the configured callback.
Returns
void
-
getWrapper() → HTMLElement
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#getWrapper
-
moveToFullscreen( elementToMove, placeholderName ) → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#moveToFullscreen
Moves the given element to the fullscreen mode container, leaving a placeholder in its place.
Parameters
elementToMove : HTMLElement
placeholderName : string
Returns
void
-
restoreMovedElementLocation( placeholderName ) → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#restoreMovedElementLocation
Returns a single moved element to its original place.
Parameters
placeholderName : string
Returns
void
-
protected
_defaultOnEnter() → HTMLElement
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_defaultOnEnter
A function that moves the editor UI elements to the fullscreen mode. It should be set by the particular editor type handler.
Returns the fullscreen mode container element so it can be further customized via
fullscreen.onEnterCallback
configuration property.Returns
HTMLElement
-
private
_destroyContainer() → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_destroyContainer
-
private
_generateDocumentOutlineContainer() → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_generateDocumentOutlineContainer
Checks if the DocumentOutlineUI plugin is available and moves its elements to fullscreen mode.
Returns
void
-
private
_generatePresenceListContainer() → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_generatePresenceListContainer
Checks if the PresenceListUI plugin is available and moves its elements to fullscreen mode.
Returns
void
-
private
_overrideAnnotationsUIs() → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_overrideAnnotationsUIs
Stores the current state of the annotations UIs to restore it when leaving fullscreen mode.
Returns
void
-
private
_overrideRevisionHistoryCallbacks() → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_overrideRevisionHistoryCallbacks
Modifies the revision history viewer callbacks to display the viewer in the fullscreen mode.
Returns
void
-
private
_registerFullscreenDialogPositionAdjustments() → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_registerFullscreenDialogPositionAdjustments
Adds an event listener when the dialog opens to adjust its position in fullscreen mode, utilizing the empty space on the right side of the editable element.
Returns
void
-
private
_restoreAnnotationsUIs() → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_restoreAnnotationsUIs
-
private
_restoreDocumentOutlineDefaultContainer() → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_restoreDocumentOutlineDefaultContainer
Restores the default value of documentOutlineContainer, which is modified in fullscreen mode.
Returns
void
-
private
_restoreRevisionHistoryCallbacks() → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_restoreRevisionHistoryCallbacks
-
private
_saveAncestorsScrollPositions( domElement ) → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_saveAncestorsScrollPositions
Saves the scroll positions of all ancestors of the given element.
Parameters
domElement : HTMLElement
Returns
void
-
private
_setNewDialogPosition() → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_setNewDialogPosition
Adjusts the dialog position to utilize the empty space on the right side of the editable. The new dialog position should be on the right side of the fullscreen view with a 30px margin. Only dialogs with the position set to "editor-top-side" should have their position changed.
Returns
void
-
private
_sourceEditingCallback( _evt, _name, value ) → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_sourceEditingCallback
A callback that hides the document outline header when the source editing mode is enabled. Document outline element itself is hidden by source editing plugin.
Parameters
_evt : EventInfo<string, unknown>
_name : string
value : boolean
Returns
void
-
private
_unregisterFullscreenDialogPositionAdjustments() → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_unregisterFullscreenDialogPositionAdjustments
Removes an event listener that adjusts the dialog's position in fullscreen mode.
Returns
void
-
private
_updateDialogPosition( _evt, _name, isOpen ) → void
module:fullscreen/handlers/abstracteditorhandler~AbstractEditorHandler#_updateDialogPosition
If dialog is open, adjust its positioning.
Parameters
_evt : EventInfo<string, unknown>
_name : string
isOpen : boolean
Returns
void
Every day, we work hard to keep our documentation complete. Have you spotted outdated information? Is something missing? Please report it via our issue tracker.
With the release of version 42.0.0, we have rewritten much of our documentation to reflect the new import paths and features. We appreciate your feedback to help us ensure its accuracy and completeness.