chore(richtext-slate): export types

This commit is contained in:
Alessio Gravili
2023-10-09 04:38:14 +02:00
parent 27ba1fc79e
commit 92fdfbe333
2 changed files with 14 additions and 1 deletions

View File

@@ -49,3 +49,16 @@ export function slateEditor(args: AdapterArguments): RichTextAdapter<AdapterArgu
validate: richTextValidate,
}
}
export type {
AdapterArguments,
ElementNode,
FieldProps,
RichTextCustomElement,
RichTextCustomLeaf,
RichTextElement,
RichTextLeaf,
TextNode,
} from './types'
export { nodeIsTextNode } from './types'

View File

@@ -1,6 +1,6 @@
import type { i18n as Ii18n } from 'i18next'
import type { SanitizedConfig } from 'payload/config'
import type { Field, RichTextField, RichTextFieldProps } from 'payload/types'
import type { Field, RichTextFieldProps } from 'payload/types'
import type { Editor } from 'slate'
export type TextNode = { [x: string]: unknown; text: string }