aboutsummaryrefslogtreecommitdiffstats
path: root/src/@types/mobx-form.types.ts
diff options
context:
space:
mode:
Diffstat (limited to 'src/@types/mobx-form.types.ts')
-rw-r--r--src/@types/mobx-form.types.ts19
1 files changed, 6 insertions, 13 deletions
diff --git a/src/@types/mobx-form.types.ts b/src/@types/mobx-form.types.ts
index c9932c053..2a984d3a6 100644
--- a/src/@types/mobx-form.types.ts
+++ b/src/@types/mobx-form.types.ts
@@ -9,29 +9,22 @@ export interface FormFieldOptions {
9 9
10export interface FormFields { 10export interface FormFields {
11 fields: { 11 fields: {
12 [key: string]: { 12 [key: string]: Field;
13 label?: string;
14 placeholder?: string;
15 options?: FormFieldOptions[];
16 value?: string | boolean | number | null;
17 default?: string | boolean | number | null;
18 type?: string; // todo specifiy probably
19 disabled?: boolean;
20 validators?: any; // Not sure yet.
21 };
22 }; 13 };
23} 14}
24 15
25export interface Field extends Partial<Listeners> { 16export interface Field extends Listeners {
26 id?: string; 17 id?: string;
27 type?: string; 18 type?: string; // todo specifiy probably
28 name?: string; 19 name?: string;
29 value: string | string[]; 20 value?: any;
30 label?: string; 21 label?: string;
31 placeholder?: string; 22 placeholder?: string;
32 disabled?: boolean; 23 disabled?: boolean;
33 error?: GlobalError | string; 24 error?: GlobalError | string;
34 options?: SelectOptions[]; 25 options?: SelectOptions[];
26 default?: string | boolean | number | null;
27 validators?: any; // Not sure yet.
35} 28}
36 29
37export interface SelectOptions { 30export interface SelectOptions {