Report an issue
Module

engine/view/placeholder

@ckeditor/ckeditor5-engine/src/view/placeholder

module

Filtering

Functions

  • attachPlaceholder( view, element, placeholderText, [ checkFunction ] )

    static

    Attaches placeholder to provided element and updates it's visibility. To change placeholder simply call this method once again with new parameters.

    Parameters

    view : View

    View controller.

    element : Element

    Element to attach placeholder to.

    placeholderText : String

    Placeholder text to use.

    [ checkFunction ] : function

    If provided it will be called before checking if placeholder should be displayed. If function returns false placeholder will not be showed.

  • detachPlaceholder( view, element )

    static

    Removes placeholder functionality from given element.

    Parameters

    view : View
    element : Element