1.1.1 • Published 6 months ago

@getplate/delta-smart-text v1.1.1

Weekly downloads
-
License
UNLICENSED
Repository
bitbucket
Last release
6 months ago

delta-smart-text

This library is part of the Delta Client utility packages. It provides a component to display smart text by using slate

Usage

<DeltaSlateEditor />

Props

The component accepts the following props:

uuid?: string
initialValue?: Descendant[]

//defaults
uuid: () => uuidv4(),
initialValue: () => [
    {
        type: 'paragraph',
        children: [{ text: '' }],
    }
],

API

Exposes the following methods:

setValue(value: Descendant[])
setContentTypes(contentTypes: ContentType[])
setContentItemsOfContentType(contentType: string, contentItems: ContentItem[])