The base class of all Jodit UI components. Provides work with a life cycle.

Type Parameters

Hierarchy

Implements

Properties

STATUSES: {
    beforeDestruct: "beforeDestruct";
    beforeInit: "beforeInit";
    destructed: "destructed";
    ready: "ready";
} = STATUSES

Type declaration

  • beforeDestruct: "beforeDestruct"
  • beforeInit: "beforeInit"
  • destructed: "destructed"
  • ready: "ready"
async: IAsync = ...
container: HTMLElement

DOM container for icon

isButton: true = ...

Marker for buttons

Parent View element

mods: IDictionary<null | string | boolean, string> = {}
name: string = ''
ownerWindow: Window = window

The window in which jodit was created

state: {
    activated: boolean;
    currentValue: string;
    disabled: boolean;
    hasTrigger: boolean;
    icon: IUIIconState;
    name: string;
    size: "small" | "tiny" | "xsmall" | "middle" | "large";
    tabIndex: CanUndef<number>;
    text: string;
    theme: string;
    tooltip: string;
    type: "button" | "submit";
    value: string | number | boolean;
    variant: ButtonVariant;
} = ...

Type declaration

  • activated: boolean
  • currentValue: string
  • disabled: boolean
  • hasTrigger: boolean
  • icon: IUIIconState
  • name: string
  • size: "small" | "tiny" | "xsmall" | "middle" | "large"
  • tabIndex: CanUndef<number>
  • text: string
  • theme: string
  • tooltip: string
  • type: "button" | "submit"
  • value: string | number | boolean
  • variant: ButtonVariant
target: Nullable<HTMLElement> = null

DOM container for text content

uid: string

Methods

  • Parameters

    Returns void

  • Returns string

  • Returns any

  • Returns void

  • Calc BEM element class name

    Parameters

    • elementName: string

      element name in the bem classification

    Returns string

  • Parameters

    • elementName: string
    • mod: string

    Returns string

  • Parameters

    • elementName: string
    • mod: string
    • modValue: string | boolean

    Returns string

  • Get BEM class modification value

    Parameters

    • this: IMods
    • name: string

    Returns ModType

  • Adds a handler for changing the component's status

    Parameters

    Returns void

  • Parameters

    • text: string
    • Rest ...params: (string | number)[]

    Returns string

  • Element has focus

    Returns boolean

  • Add action handler

    Parameters

    • callback: ((originalEvent: MouseEvent) => void)
        • (originalEvent: MouseEvent): void
        • Parameters

          • originalEvent: MouseEvent

          Returns void

    Returns ToolbarButton<T>

  • Set component status

    See

    ComponentStatus

    Parameters

    Returns void

    Returns void

Accessors

  • get componentName(): string
  • Returns string

  • get defaultTimeout(): number
  • Returns number

  • get isDestructed(): boolean
  • Component was destructed

    Returns boolean

  • get isInDestruct(): boolean
  • The component is currently undergoing destructuring or has already been destroyed. Those. you should not hang new events on him now or do anything else with him.

    Returns boolean

  • get isReady(): boolean
  • Component is ready for work

    Returns boolean

  • get j(): T
  • Shortcut for this.jodit

    Returns T

  • get ownerDocument(): Document
  • The document in which jodit was created

    Returns Document

Constructors

Jodit PRO

If you like Jodit - try Jodit PRO