Module

ckbox/utils

@ckeditor/ckeditor5-ckbox/src/utils

module

Filtering

Functions

  • blurHashToDataUrl( [ hash ] ) → string | undefined

    Generates an image data URL from its blurhash representation.

    Parameters

    [ hash ] : string

    Returns

    string | undefined
  • getImageUrls( imageUrls ) → object

    Converts image source set provided by the CKBox into an object containing:

    • responsive URLs for the "webp" image format,
    • one fallback URL for browsers that do not support the "webp" format.

    Parameters

    imageUrls : CKBoxImageUrls

    Returns

    object
  • getWorkspaceId( token, [ defaultWorkspaceId ] ) → string | null

    Returns a workspace id to use for communication with the CKBox service.

    Parameters

    token : InitializedToken
    [ defaultWorkspaceId ] : string

    The default workspace to use taken from editor config.

    Returns

    string | null