AIContainerSidebar
interface
The configuration of the AI user interface container in the sidebar mode. Provide an existing DOM element to use as the container the AI user interface will automatically render into that element.
Additionally, the tab buttons can be positioned on the preferred side of the container.
ClassicEditor
.create( document.querySelector( '#editor' ), {
// ... Other configuration options ...
ai: {
container: {
type: 'sidebar',
// Existing DOM element to use as the container for the AI user interface.
element: document.querySelector( '#ai-sidebar-container' ),
// (Optional) The preferred side of the element to position the tab buttons.
side: 'right'
},
}
} )
.then( ... )
.catch( ... );
Copy code
Properties
-
element : HTMLElementmodule:ai/aiconfig~AIContainerSidebar#element -
showResizeButton : boolean | undefinedinheritedmodule:ai/aiconfig~AIContainerSidebar#showResizeButtonThis option is used to show or hide the resize button in the AI user interface.
Defaults to
true. -
side : AIContainerSide | undefinedmodule:ai/aiconfig~AIContainerSidebar#side -
type : 'sidebar'module:ai/aiconfig~AIContainerSidebar#type -
visibleByDefault : boolean | undefinedinheritedmodule:ai/aiconfig~AIContainerSidebar#visibleByDefaultWhether the AI interface should be visible when the editor is created.