File

packages/components/externals/eui-editor/eui-editor.component.ts

Description

Rich text editor component based on Quill with customizable toolbar and formatting options. Provides WYSIWYG editing capabilities with support for text formatting, images, tables, links, and code blocks. Implements ControlValueAccessor for seamless integration with Angular forms. Supports both HTML and JSON output formats with character and word counting. Commonly used for content management, document editing, comment systems, and rich text input fields. Dependencies: Quill editor library, EuiDialogService for image URL dialogs.

Implements

ControlValueAccessor OnInit OnDestroy OnChanges

Metadata

Index

Properties
Methods
Inputs
Outputs
HostBindings
Accessors

Constructor

constructor()

Inputs

customToolbarConfig
Type : ToolbarItemConfig[]
customToolbarPosition
Type : "top" | "bottom"
Default value : 'top'
debug
Type : "warn" | "log" | "error" | unknown
Default value : false
e2eAttr
Type : string
Default value : 'eui-editor'
format
Type : "html" | "json"
Default value : 'html'
formats
Type : string[] | null
height
Type : string
id
Type : string
isEnabledOnFocus
Type : boolean

Please check the showcase sample in order to replace this feature using the focus emitter.

isMinimalToolbar
Type : boolean
isReadOnly
Type : boolean
modules
Type : QuillModules
placeholder
Type : string
Default value : ''
showCounters
Type : boolean
tabindex
Type : string
Default value : '0'
theme
Type : "snow" | "bubble"
Default value : 'snow'

Outputs

blur
Type : EventEmitter
charactersCountChange
Type : EventEmitter
contentChange
Type : EventEmitter
editorChange
Type : EventEmitter
editorCreate
Type : EventEmitter
focus
Type : EventEmitter
selectionChange
Type : EventEmitter
wordsCountChange
Type : EventEmitter

HostBindings

attr.aria-invalid
Type : boolean
attr.readonly
Type : string
class
Type : string
class.eui-editor
Type : boolean

Methods

Public _onBlur
_onBlur(event: Blur)
Parameters :
Name Type Optional
event Blur No
Returns : void
Public _onContentChanged
_onContentChanged(event: ContentChange)
Parameters :
Name Type Optional
event ContentChange No
Returns : void
Public _onEditorCreated
_onEditorCreated(quill: unknown)
Parameters :
Name Type Optional
quill unknown No
Returns : void
Public _onFocus
_onFocus(event: Focus)
Parameters :
Name Type Optional
event Focus No
Returns : void
Public _onSelectionChanged
_onSelectionChanged(event: SelectionChange)
Parameters :
Name Type Optional
event SelectionChange No
Returns : void
Public editorDeleteContent
editorDeleteContent()
Returns : void
Public editorRedo
editorRedo()
Returns : void
Public editorUndo
editorUndo()
Returns : void
Public enableEditorOnFocus
enableEditorOnFocus(event: any)
Parameters :
Name Type Optional
event any No
Returns : void
Public imageUrlHandler
imageUrlHandler()
Returns : void
Public insertTable
insertTable()
Returns : void
Public registerOnChange
registerOnChange(fn: any)
Parameters :
Name Type Optional
fn any No
Returns : void
Public registerOnTouched
registerOnTouched(fn: any)
Parameters :
Name Type Optional
fn any No
Returns : void
Public writeValue
writeValue(value: string)
Parameters :
Name Type Optional
value string No
Returns : void

Properties

Public bytesCount
Type : number
Default value : 0
Public charactersCount
Type : number
Default value : 0
euiEditorCustomToolbar
Type : EuiEditorCustomToolbarTagDirective
Decorators :
@ContentChild(undefined, {static: false})
Public formControl
Type : FormControl
Default value : new FormControl()
Public generatedId
Type : string
Public isFocused
Type : unknown
Default value : false
Public jsonToHtmlContent
Type : string
Public toolbarConfig
Type : literal type
true
Type : boolean
Decorators :
@HostBinding('class.eui-editor')
Public value
Type : string | any
Default value : ''
Public wordsCount
Type : number
Default value : 0

Accessors

class
getclass()
readonly
getreadonly()
isReadOnly
getisReadOnly()
setisReadOnly(value: BooleanInput)
Parameters :
Name Type Optional
value BooleanInput No
Returns : void
showCounters
getshowCounters()
setshowCounters(value: BooleanInput)
Parameters :
Name Type Optional
value BooleanInput No
Returns : void
isEnabledOnFocus
getisEnabledOnFocus()

Please check the showcase sample in order to replace this feature using the focus emitter.

Returns : boolean
setisEnabledOnFocus(value: unknown)
Parameters :
Name Type Optional
value unknown No
Returns : void
isMinimalToolbar
getisMinimalToolbar()
setisMinimalToolbar(value: BooleanInput)
Parameters :
Name Type Optional
value BooleanInput No
Returns : void
isInvalid
getisInvalid()
setisInvalid(value: BooleanInput)
Parameters :
Name Type Optional
value BooleanInput No
Returns : void
hasImageFeature
gethasImageFeature()
hasCharactersCounter
gethasCharactersCounter()
charactersCounterLabel
getcharactersCounterLabel()
hasWordsCounter
gethasWordsCounter()
wordsCounterLabel
getwordsCounterLabel()

results matching ""

    No results matching ""