Api

Property-Types

Definition of all available property-types

These are the different inputs available for component form-structure.

Number

type Number = {
    id: string;
    label: Record<string, string>;
    description?: string;
    defaultValue?: number;
    hint?: string;
    min?: number;
    max?: numer;
    step?: number;
}

Range

type Range = {
    id: string;
    label: Record<string, string>;
    description?: string;
    defaultValue?: number;
    hint?: string;
    min: number;
    max: numer;
    step?: number;
}

Checkbox

type Checkbox = {
    id: string;
    label: Record<string, string>;
    description?: string;
    defaultValue?: boolean;
    hint?: string;
}

RelationRules

type RelationRules = {
    id: string;
    label: Record<string, string>;
    description?: string;
    defaultValue?: unknown;
    hint?: string;
    relationName: "tag" | "user" | "page" | "post" | "file";
}

Relation

type Relation = {
    id: string;
    label: Record<string, string>;
    description?: string;
    defaultValue?: Array<string>;
    hint?: string;
    relationName: "tag" | "user" | "page" | "post" | "file";
    multiple?: boolean;
}

Richtext

type Richtext = {
    id: string;
    label: Record<string, string>;
    description?: string;
    defaultValue?: string;
    hint?: string;
}

Code

type Code = {
    id: string;
    label: Record<string, string>;
    description?: string;
    defaultValue?: string;
    hint?: string;
    language: "json" | "js" | "css" | "html";
}

Text

type Text = {
    id: string;
    label: Record<string, string>;
    description?: string;
    defaultValue?: string;
    hint?: string;
}

Textarea

type Textarea = {
    id: string;
    label: Record<string, string>;
    description?: string;
    defaultValue?: string;
    hint?: string;
}

Accordion

type Accordion = {
    id: string;
    label: Record<string, string>;
    description?: string;
    defaultValue?: unknown;
    hint?: string;
    items: Array<{
        id: string;
        description: Record<string, string>;
        properties: Array<Form>;
    }>;
}

Select

type Select<T extends string | number> = {
    id: string;
    label: Record<string, string>;
    description?: string;
    defaultValue?: T;
    hint?: string;
    options: Array<{
        value: T;
        label: Record<string, string>
    }>;
    dataType: "string" | "number";
    multiple?: boolean;
}

Key-value

type KeyValue = {
    id: string;
    label: Record<string, string>;
    description?: string;
    defaultValue?: Record<any, any>;
    hint?: string;
    value: FormItem;
    key: FormItem;
}

Buider

type Builder = {
    id: string;
    label: Record<string, string>;
    description?: string;
    defaultValue?: unknown;
    hint?: string;
    previewTemplate?: string;
    items: Array<any>;
}

Buttongroup

type Buttongroup = {
    id: string;
    label: Record<string, string>;
    description?: string;
    defaultValue?: string;
    hint?: string;
    options: Array<{
        value: string;
        label: Record<string, string>;
    }>;
}

PluginData

type PluginData = {
    id: string;
    label: Record<string, string>;
    description?: string;
    defaultValue?: unknown;
    hint?: string;
    pluginId: string;
    labelKey: string;
    valueKey: string;
    filterByKey?: string;
}