mirror of
https://git.joinsharkey.org/Sharkey/Sharkey.git
synced 2024-11-10 15:23:09 +02:00
0e4a111f81
Resolve #7779
31 lines
545 B
TypeScript
31 lines
545 B
TypeScript
export type FormItem = {
|
|
label?: string;
|
|
type: 'string';
|
|
default: string | null;
|
|
hidden?: boolean;
|
|
multiline?: boolean;
|
|
} | {
|
|
label?: string;
|
|
type: 'number';
|
|
default: number | null;
|
|
hidden?: boolean;
|
|
step?: number;
|
|
} | {
|
|
label?: string;
|
|
type: 'boolean';
|
|
default: boolean | null;
|
|
hidden?: boolean;
|
|
} | {
|
|
label?: string;
|
|
type: 'enum';
|
|
default: string | null;
|
|
hidden?: boolean;
|
|
enum: string[];
|
|
} | {
|
|
label?: string;
|
|
type: 'array';
|
|
default: unknown[] | null;
|
|
hidden?: boolean;
|
|
};
|
|
|
|
export type Form = Record<string, FormItem>;
|