Types
Context
Argument for functions initialValue
and hidden in Vev props
export type SchemaContextModel<T> = {
key?: string;
/**
* The whole form value: every field of the component
*/
value?: Partial<T>;
/**
* The object the field sits in: the array item or object field being edited,
* or the whole value at the top level. Set for hidden only
*/
item?: Record<string, any>;
storage?: SchemaStorage;
/**
* Project
*/
project?: { title: string; key: string; index: string };
/**
* Project pages
*/
pages?: { title: string; key: string; path?: string }[];
currentPage?: { title: string; key: string; path?: string; project?: string };
/**
* Named content models
*/
content?: {
key: string;
name?: string;
parentKey: string;
type: string;
content?: { [key: string]: any };
}[];
/**
* Events
*/
events?: VevContentEvent[];
};