UNPKG

@tinacms/toolkit

Version:

Tina is a lightweight but powerful toolkit for creating a site editing ui with javascript components. Tina surfaces superpowers for dev’s to create, expand on and customize a simple yet intuitive ui for editing content.

19 lines (15 loc) 505 B
/** */ import { CMS, Plugin } from '../core'; import { Field } from './field'; import { FormOptions } from './form'; export interface ContentCreatorPlugin<FormShape> extends Plugin { __type: 'content-creator'; fields: Field[]; actions?: FormOptions<any>['actions']; buttons?: FormOptions<any>['buttons']; initialValues?: FormShape; onSubmit(value: FormShape, cms: CMS): Promise<void> | void; reset?: FormOptions<any>['reset']; onChange?: FormOptions<any>['onChange']; }