@sfxcode/formkit-nuxt-ui 0.7.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (106) hide show
  1. package/LICENSE +22 -0
  2. package/README.md +385 -0
  3. package/dist/module.d.mts +7 -0
  4. package/dist/module.json +12 -0
  5. package/dist/module.mjs +29 -0
  6. package/dist/runtime/components/FUDataDebug.d.vue.ts +43 -0
  7. package/dist/runtime/components/FUDataDebug.vue +30 -0
  8. package/dist/runtime/components/FUDataDebug.vue.d.ts +43 -0
  9. package/dist/runtime/components/FUDataEdit.d.vue.ts +180 -0
  10. package/dist/runtime/components/FUDataEdit.vue +141 -0
  11. package/dist/runtime/components/FUDataEdit.vue.d.ts +180 -0
  12. package/dist/runtime/components/FUDataView.d.vue.ts +73 -0
  13. package/dist/runtime/components/FUDataView.vue +49 -0
  14. package/dist/runtime/components/FUDataView.vue.d.ts +73 -0
  15. package/dist/runtime/components/inputs/FUCheckbox.d.vue.ts +27 -0
  16. package/dist/runtime/components/inputs/FUCheckbox.vue +33 -0
  17. package/dist/runtime/components/inputs/FUCheckbox.vue.d.ts +27 -0
  18. package/dist/runtime/components/inputs/FUCheckboxGroup.d.vue.ts +38 -0
  19. package/dist/runtime/components/inputs/FUCheckboxGroup.vue +34 -0
  20. package/dist/runtime/components/inputs/FUCheckboxGroup.vue.d.ts +38 -0
  21. package/dist/runtime/components/inputs/FUColorPicker.d.vue.ts +22 -0
  22. package/dist/runtime/components/inputs/FUColorPicker.vue +27 -0
  23. package/dist/runtime/components/inputs/FUColorPicker.vue.d.ts +22 -0
  24. package/dist/runtime/components/inputs/FUInput.d.vue.ts +44 -0
  25. package/dist/runtime/components/inputs/FUInput.vue +50 -0
  26. package/dist/runtime/components/inputs/FUInput.vue.d.ts +44 -0
  27. package/dist/runtime/components/inputs/FUInputDate.d.vue.ts +51 -0
  28. package/dist/runtime/components/inputs/FUInputDate.vue +52 -0
  29. package/dist/runtime/components/inputs/FUInputDate.vue.d.ts +51 -0
  30. package/dist/runtime/components/inputs/FUInputMenu.d.vue.ts +73 -0
  31. package/dist/runtime/components/inputs/FUInputMenu.vue +65 -0
  32. package/dist/runtime/components/inputs/FUInputMenu.vue.d.ts +73 -0
  33. package/dist/runtime/components/inputs/FUInputNumber.d.vue.ts +43 -0
  34. package/dist/runtime/components/inputs/FUInputNumber.vue +49 -0
  35. package/dist/runtime/components/inputs/FUInputNumber.vue.d.ts +43 -0
  36. package/dist/runtime/components/inputs/FUInputTags.d.vue.ts +47 -0
  37. package/dist/runtime/components/inputs/FUInputTags.vue +53 -0
  38. package/dist/runtime/components/inputs/FUInputTags.vue.d.ts +47 -0
  39. package/dist/runtime/components/inputs/FUInputTime.d.vue.ts +50 -0
  40. package/dist/runtime/components/inputs/FUInputTime.vue +50 -0
  41. package/dist/runtime/components/inputs/FUInputTime.vue.d.ts +50 -0
  42. package/dist/runtime/components/inputs/FUPinInput.d.vue.ts +30 -0
  43. package/dist/runtime/components/inputs/FUPinInput.vue +37 -0
  44. package/dist/runtime/components/inputs/FUPinInput.vue.d.ts +30 -0
  45. package/dist/runtime/components/inputs/FURadioGroup.d.vue.ts +37 -0
  46. package/dist/runtime/components/inputs/FURadioGroup.vue +35 -0
  47. package/dist/runtime/components/inputs/FURadioGroup.vue.d.ts +37 -0
  48. package/dist/runtime/components/inputs/FUSelect.d.vue.ts +48 -0
  49. package/dist/runtime/components/inputs/FUSelect.vue +51 -0
  50. package/dist/runtime/components/inputs/FUSelect.vue.d.ts +48 -0
  51. package/dist/runtime/components/inputs/FUSelectMenu.d.vue.ts +73 -0
  52. package/dist/runtime/components/inputs/FUSelectMenu.vue +62 -0
  53. package/dist/runtime/components/inputs/FUSelectMenu.vue.d.ts +73 -0
  54. package/dist/runtime/components/inputs/FUSlider.d.vue.ts +29 -0
  55. package/dist/runtime/components/inputs/FUSlider.vue +36 -0
  56. package/dist/runtime/components/inputs/FUSlider.vue.d.ts +29 -0
  57. package/dist/runtime/components/inputs/FUSwitch.d.vue.ts +28 -0
  58. package/dist/runtime/components/inputs/FUSwitch.vue +34 -0
  59. package/dist/runtime/components/inputs/FUSwitch.vue.d.ts +28 -0
  60. package/dist/runtime/components/inputs/FUTextarea.d.vue.ts +44 -0
  61. package/dist/runtime/components/inputs/FUTextarea.vue +50 -0
  62. package/dist/runtime/components/inputs/FUTextarea.vue.d.ts +44 -0
  63. package/dist/runtime/components/output/FUIcon.d.vue.ts +38 -0
  64. package/dist/runtime/components/output/FUIcon.vue +21 -0
  65. package/dist/runtime/components/output/FUIcon.vue.d.ts +38 -0
  66. package/dist/runtime/components/output/FUOutputBoolean.d.vue.ts +30 -0
  67. package/dist/runtime/components/output/FUOutputBoolean.vue +56 -0
  68. package/dist/runtime/components/output/FUOutputBoolean.vue.d.ts +30 -0
  69. package/dist/runtime/components/output/FUOutputDate.d.vue.ts +30 -0
  70. package/dist/runtime/components/output/FUOutputDate.vue +52 -0
  71. package/dist/runtime/components/output/FUOutputDate.vue.d.ts +30 -0
  72. package/dist/runtime/components/output/FUOutputLink.d.vue.ts +28 -0
  73. package/dist/runtime/components/output/FUOutputLink.vue +78 -0
  74. package/dist/runtime/components/output/FUOutputLink.vue.d.ts +28 -0
  75. package/dist/runtime/components/output/FUOutputList.d.vue.ts +29 -0
  76. package/dist/runtime/components/output/FUOutputList.vue +143 -0
  77. package/dist/runtime/components/output/FUOutputList.vue.d.ts +29 -0
  78. package/dist/runtime/components/output/FUOutputNumber.d.vue.ts +28 -0
  79. package/dist/runtime/components/output/FUOutputNumber.vue +52 -0
  80. package/dist/runtime/components/output/FUOutputNumber.vue.d.ts +28 -0
  81. package/dist/runtime/components/output/FUOutputText.d.vue.ts +26 -0
  82. package/dist/runtime/components/output/FUOutputText.vue +35 -0
  83. package/dist/runtime/components/output/FUOutputText.vue.d.ts +26 -0
  84. package/dist/runtime/composables/useFormKitRepeater.d.ts +5 -0
  85. package/dist/runtime/composables/useFormKitRepeater.js +54 -0
  86. package/dist/runtime/composables/useFormKitSchema.d.ts +26 -0
  87. package/dist/runtime/composables/useFormKitSchema.js +58 -0
  88. package/dist/runtime/definitions/index.d.ts +26 -0
  89. package/dist/runtime/definitions/index.js +28 -0
  90. package/dist/runtime/definitions/input.d.ts +17 -0
  91. package/dist/runtime/definitions/input.js +81 -0
  92. package/dist/runtime/definitions/output.d.ts +7 -0
  93. package/dist/runtime/definitions/output.js +31 -0
  94. package/dist/runtime/formkit.config.d.ts +3 -0
  95. package/dist/runtime/formkit.config.js +33 -0
  96. package/dist/runtime/plugin.d.ts +2 -0
  97. package/dist/runtime/plugin.js +5 -0
  98. package/dist/runtime/plugins/index.d.ts +3 -0
  99. package/dist/runtime/plugins/index.js +55 -0
  100. package/dist/runtime/server/tsconfig.json +3 -0
  101. package/dist/runtime/utils/useFormKitInput.d.ts +13 -0
  102. package/dist/runtime/utils/useFormKitInput.js +42 -0
  103. package/dist/runtime/utils/useFormKitOutput.d.ts +10 -0
  104. package/dist/runtime/utils/useFormKitOutput.js +73 -0
  105. package/dist/types.d.mts +3 -0
  106. package/package.json +91 -0
@@ -0,0 +1,180 @@
1
+ import type { FormKitSchemaDefinition } from '@formkit/core';
2
+ import type { PropType } from 'vue';
3
+ declare var __VLS_15: {}, __VLS_18: {}, __VLS_26: {};
4
+ type __VLS_Slots = {} & {
5
+ default?: (props: typeof __VLS_15) => any;
6
+ } & {
7
+ messages?: (props: typeof __VLS_18) => any;
8
+ } & {
9
+ submit?: (props: typeof __VLS_26) => any;
10
+ };
11
+ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
12
+ id: {
13
+ type: StringConstructor;
14
+ default: string;
15
+ };
16
+ data: {
17
+ type: ObjectConstructor;
18
+ default: null;
19
+ };
20
+ schema: {
21
+ type: PropType<FormKitSchemaDefinition>;
22
+ default: null;
23
+ };
24
+ formClass: {
25
+ type: StringConstructor;
26
+ default: string;
27
+ };
28
+ actionsClass: {
29
+ type: StringConstructor;
30
+ default: string;
31
+ };
32
+ submitSeverity: {
33
+ type: StringConstructor;
34
+ default: string;
35
+ };
36
+ submitClass: {
37
+ type: StringConstructor;
38
+ default: string;
39
+ };
40
+ submitLabel: {
41
+ type: StringConstructor;
42
+ default: string;
43
+ };
44
+ submitIcon: {
45
+ type: StringConstructor;
46
+ default: string;
47
+ };
48
+ showReset: {
49
+ type: BooleanConstructor;
50
+ default: boolean;
51
+ };
52
+ resetSeverity: {
53
+ type: StringConstructor;
54
+ default: string;
55
+ };
56
+ resetLabel: {
57
+ type: StringConstructor;
58
+ default: string;
59
+ };
60
+ resetClass: {
61
+ type: StringConstructor;
62
+ default: string;
63
+ };
64
+ resetIcon: {
65
+ type: StringConstructor;
66
+ default: string;
67
+ };
68
+ debugData: {
69
+ type: BooleanConstructor;
70
+ default: boolean;
71
+ };
72
+ debugSchema: {
73
+ type: BooleanConstructor;
74
+ default: boolean;
75
+ };
76
+ modelValue: {
77
+ type: PropType<object>;
78
+ };
79
+ }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
80
+ onReset: (...args: any[]) => void;
81
+ dataSaved: (...args: any[]) => void;
82
+ "update:modelValue": (value: object | undefined) => void;
83
+ }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
84
+ id: {
85
+ type: StringConstructor;
86
+ default: string;
87
+ };
88
+ data: {
89
+ type: ObjectConstructor;
90
+ default: null;
91
+ };
92
+ schema: {
93
+ type: PropType<FormKitSchemaDefinition>;
94
+ default: null;
95
+ };
96
+ formClass: {
97
+ type: StringConstructor;
98
+ default: string;
99
+ };
100
+ actionsClass: {
101
+ type: StringConstructor;
102
+ default: string;
103
+ };
104
+ submitSeverity: {
105
+ type: StringConstructor;
106
+ default: string;
107
+ };
108
+ submitClass: {
109
+ type: StringConstructor;
110
+ default: string;
111
+ };
112
+ submitLabel: {
113
+ type: StringConstructor;
114
+ default: string;
115
+ };
116
+ submitIcon: {
117
+ type: StringConstructor;
118
+ default: string;
119
+ };
120
+ showReset: {
121
+ type: BooleanConstructor;
122
+ default: boolean;
123
+ };
124
+ resetSeverity: {
125
+ type: StringConstructor;
126
+ default: string;
127
+ };
128
+ resetLabel: {
129
+ type: StringConstructor;
130
+ default: string;
131
+ };
132
+ resetClass: {
133
+ type: StringConstructor;
134
+ default: string;
135
+ };
136
+ resetIcon: {
137
+ type: StringConstructor;
138
+ default: string;
139
+ };
140
+ debugData: {
141
+ type: BooleanConstructor;
142
+ default: boolean;
143
+ };
144
+ debugSchema: {
145
+ type: BooleanConstructor;
146
+ default: boolean;
147
+ };
148
+ modelValue: {
149
+ type: PropType<object>;
150
+ };
151
+ }>> & Readonly<{
152
+ onOnReset?: ((...args: any[]) => any) | undefined;
153
+ onDataSaved?: ((...args: any[]) => any) | undefined;
154
+ "onUpdate:modelValue"?: ((value: object | undefined) => any) | undefined;
155
+ }>, {
156
+ data: Record<string, any>;
157
+ id: string;
158
+ schema: FormKitSchemaDefinition;
159
+ formClass: string;
160
+ actionsClass: string;
161
+ submitSeverity: string;
162
+ submitClass: string;
163
+ submitLabel: string;
164
+ submitIcon: string;
165
+ showReset: boolean;
166
+ resetSeverity: string;
167
+ resetLabel: string;
168
+ resetClass: string;
169
+ resetIcon: string;
170
+ debugData: boolean;
171
+ debugSchema: boolean;
172
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
173
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
174
+ declare const _default: typeof __VLS_export;
175
+ export default _default;
176
+ type __VLS_WithSlots<T, S> = T & {
177
+ new (): {
178
+ $slots: S;
179
+ };
180
+ };
@@ -0,0 +1,141 @@
1
+ <script setup>
2
+ import { reset } from "@formkit/core";
3
+ import { FormKit, FormKitMessages, FormKitSchema } from "@formkit/vue";
4
+ import { ref } from "vue";
5
+ import FUDataDebug from "./FUDataDebug.vue";
6
+ const props = defineProps({
7
+ id: {
8
+ type: String,
9
+ default: "formkit_form"
10
+ },
11
+ data: {
12
+ type: Object,
13
+ default: null
14
+ },
15
+ schema: {
16
+ type: Object,
17
+ default: null
18
+ },
19
+ formClass: {
20
+ type: String,
21
+ default: ""
22
+ },
23
+ actionsClass: {
24
+ type: String,
25
+ default: ""
26
+ },
27
+ submitSeverity: {
28
+ type: String,
29
+ default: ""
30
+ },
31
+ submitClass: {
32
+ type: String,
33
+ default: ""
34
+ },
35
+ submitLabel: {
36
+ type: String,
37
+ default: "Save"
38
+ },
39
+ submitIcon: {
40
+ type: String,
41
+ default: ""
42
+ },
43
+ showReset: {
44
+ type: Boolean,
45
+ default: false
46
+ },
47
+ resetSeverity: {
48
+ type: String,
49
+ default: "danger"
50
+ },
51
+ resetLabel: {
52
+ type: String,
53
+ default: "Reset"
54
+ },
55
+ resetClass: {
56
+ type: String,
57
+ default: ""
58
+ },
59
+ resetIcon: {
60
+ type: String,
61
+ default: ""
62
+ },
63
+ debugData: {
64
+ type: Boolean,
65
+ default: false
66
+ },
67
+ debugSchema: {
68
+ type: Boolean,
69
+ default: false
70
+ }
71
+ });
72
+ const emit = defineEmits(["dataSaved", "onReset"]);
73
+ const formData = defineModel({ type: Object });
74
+ if (props.data) {
75
+ formData.value = props.data;
76
+ }
77
+ const formSchema = ref(props.schema);
78
+ function handleSave() {
79
+ emit("dataSaved", formData.value);
80
+ }
81
+ function handleReset() {
82
+ reset(props.id);
83
+ emit("onReset");
84
+ }
85
+ </script>
86
+
87
+ <template>
88
+ <FormKit
89
+ :id="id"
90
+ v-model="formData"
91
+ :form-class="formClass"
92
+ :actions-class="actionsClass"
93
+ type="form"
94
+ @submit="handleSave"
95
+ >
96
+ <template #default>
97
+ <FormKitSchema
98
+ v-if="formSchema"
99
+ :schema="formSchema"
100
+ :data="formData"
101
+ />
102
+ <slot />
103
+ </template>
104
+ <template #messages>
105
+ <slot name="messages">
106
+ <FormKitMessages class="p-formkit-data-edit-messages" />
107
+ </slot>
108
+ </template>
109
+ <template #submit>
110
+ <slot name="submit">
111
+ <UButton
112
+ :icon="submitIcon"
113
+ type="submit"
114
+ :label="submitLabel"
115
+ :class="submitClass"
116
+ :severity="submitSeverity"
117
+ @submit="handleSave"
118
+ />
119
+ <UButton
120
+ v-if="showReset"
121
+ type="reset"
122
+ :icon="resetIcon"
123
+ :label="resetLabel"
124
+ :class="resetClass"
125
+ :severity="resetSeverity"
126
+ @click="handleReset"
127
+ />
128
+ </slot>
129
+ </template>
130
+ </FormKit>
131
+ <FUDataDebug
132
+ v-if="debugData"
133
+ :data="formData"
134
+ header="Data"
135
+ />
136
+ <FUDataDebug
137
+ v-if="debugSchema"
138
+ :data="formSchema"
139
+ header="Schema"
140
+ />
141
+ </template>
@@ -0,0 +1,180 @@
1
+ import type { FormKitSchemaDefinition } from '@formkit/core';
2
+ import type { PropType } from 'vue';
3
+ declare var __VLS_15: {}, __VLS_18: {}, __VLS_26: {};
4
+ type __VLS_Slots = {} & {
5
+ default?: (props: typeof __VLS_15) => any;
6
+ } & {
7
+ messages?: (props: typeof __VLS_18) => any;
8
+ } & {
9
+ submit?: (props: typeof __VLS_26) => any;
10
+ };
11
+ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
12
+ id: {
13
+ type: StringConstructor;
14
+ default: string;
15
+ };
16
+ data: {
17
+ type: ObjectConstructor;
18
+ default: null;
19
+ };
20
+ schema: {
21
+ type: PropType<FormKitSchemaDefinition>;
22
+ default: null;
23
+ };
24
+ formClass: {
25
+ type: StringConstructor;
26
+ default: string;
27
+ };
28
+ actionsClass: {
29
+ type: StringConstructor;
30
+ default: string;
31
+ };
32
+ submitSeverity: {
33
+ type: StringConstructor;
34
+ default: string;
35
+ };
36
+ submitClass: {
37
+ type: StringConstructor;
38
+ default: string;
39
+ };
40
+ submitLabel: {
41
+ type: StringConstructor;
42
+ default: string;
43
+ };
44
+ submitIcon: {
45
+ type: StringConstructor;
46
+ default: string;
47
+ };
48
+ showReset: {
49
+ type: BooleanConstructor;
50
+ default: boolean;
51
+ };
52
+ resetSeverity: {
53
+ type: StringConstructor;
54
+ default: string;
55
+ };
56
+ resetLabel: {
57
+ type: StringConstructor;
58
+ default: string;
59
+ };
60
+ resetClass: {
61
+ type: StringConstructor;
62
+ default: string;
63
+ };
64
+ resetIcon: {
65
+ type: StringConstructor;
66
+ default: string;
67
+ };
68
+ debugData: {
69
+ type: BooleanConstructor;
70
+ default: boolean;
71
+ };
72
+ debugSchema: {
73
+ type: BooleanConstructor;
74
+ default: boolean;
75
+ };
76
+ modelValue: {
77
+ type: PropType<object>;
78
+ };
79
+ }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
80
+ onReset: (...args: any[]) => void;
81
+ dataSaved: (...args: any[]) => void;
82
+ "update:modelValue": (value: object | undefined) => void;
83
+ }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
84
+ id: {
85
+ type: StringConstructor;
86
+ default: string;
87
+ };
88
+ data: {
89
+ type: ObjectConstructor;
90
+ default: null;
91
+ };
92
+ schema: {
93
+ type: PropType<FormKitSchemaDefinition>;
94
+ default: null;
95
+ };
96
+ formClass: {
97
+ type: StringConstructor;
98
+ default: string;
99
+ };
100
+ actionsClass: {
101
+ type: StringConstructor;
102
+ default: string;
103
+ };
104
+ submitSeverity: {
105
+ type: StringConstructor;
106
+ default: string;
107
+ };
108
+ submitClass: {
109
+ type: StringConstructor;
110
+ default: string;
111
+ };
112
+ submitLabel: {
113
+ type: StringConstructor;
114
+ default: string;
115
+ };
116
+ submitIcon: {
117
+ type: StringConstructor;
118
+ default: string;
119
+ };
120
+ showReset: {
121
+ type: BooleanConstructor;
122
+ default: boolean;
123
+ };
124
+ resetSeverity: {
125
+ type: StringConstructor;
126
+ default: string;
127
+ };
128
+ resetLabel: {
129
+ type: StringConstructor;
130
+ default: string;
131
+ };
132
+ resetClass: {
133
+ type: StringConstructor;
134
+ default: string;
135
+ };
136
+ resetIcon: {
137
+ type: StringConstructor;
138
+ default: string;
139
+ };
140
+ debugData: {
141
+ type: BooleanConstructor;
142
+ default: boolean;
143
+ };
144
+ debugSchema: {
145
+ type: BooleanConstructor;
146
+ default: boolean;
147
+ };
148
+ modelValue: {
149
+ type: PropType<object>;
150
+ };
151
+ }>> & Readonly<{
152
+ onOnReset?: ((...args: any[]) => any) | undefined;
153
+ onDataSaved?: ((...args: any[]) => any) | undefined;
154
+ "onUpdate:modelValue"?: ((value: object | undefined) => any) | undefined;
155
+ }>, {
156
+ data: Record<string, any>;
157
+ id: string;
158
+ schema: FormKitSchemaDefinition;
159
+ formClass: string;
160
+ actionsClass: string;
161
+ submitSeverity: string;
162
+ submitClass: string;
163
+ submitLabel: string;
164
+ submitIcon: string;
165
+ showReset: boolean;
166
+ resetSeverity: string;
167
+ resetLabel: string;
168
+ resetClass: string;
169
+ resetIcon: string;
170
+ debugData: boolean;
171
+ debugSchema: boolean;
172
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
173
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
174
+ declare const _default: typeof __VLS_export;
175
+ export default _default;
176
+ type __VLS_WithSlots<T, S> = T & {
177
+ new (): {
178
+ $slots: S;
179
+ };
180
+ };
@@ -0,0 +1,73 @@
1
+ import type { FormKitSchemaDefinition } from '@formkit/core';
2
+ import type { PropType } from 'vue';
3
+ declare var __VLS_6: {};
4
+ type __VLS_Slots = {} & {
5
+ default?: (props: typeof __VLS_6) => any;
6
+ };
7
+ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
8
+ data: {
9
+ type: ObjectConstructor;
10
+ default: null;
11
+ };
12
+ schema: {
13
+ type: PropType<FormKitSchemaDefinition>;
14
+ default: null;
15
+ };
16
+ formClass: {
17
+ type: StringConstructor;
18
+ default: string;
19
+ };
20
+ debugData: {
21
+ type: BooleanConstructor;
22
+ default: boolean;
23
+ };
24
+ debugSchema: {
25
+ type: BooleanConstructor;
26
+ default: boolean;
27
+ };
28
+ modelValue: {
29
+ type: PropType<Record<string, unknown>>;
30
+ };
31
+ }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
32
+ "update:modelValue": (value: Record<string, unknown> | undefined) => any;
33
+ }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
34
+ data: {
35
+ type: ObjectConstructor;
36
+ default: null;
37
+ };
38
+ schema: {
39
+ type: PropType<FormKitSchemaDefinition>;
40
+ default: null;
41
+ };
42
+ formClass: {
43
+ type: StringConstructor;
44
+ default: string;
45
+ };
46
+ debugData: {
47
+ type: BooleanConstructor;
48
+ default: boolean;
49
+ };
50
+ debugSchema: {
51
+ type: BooleanConstructor;
52
+ default: boolean;
53
+ };
54
+ modelValue: {
55
+ type: PropType<Record<string, unknown>>;
56
+ };
57
+ }>> & Readonly<{
58
+ "onUpdate:modelValue"?: ((value: Record<string, unknown> | undefined) => any) | undefined;
59
+ }>, {
60
+ data: Record<string, any>;
61
+ schema: FormKitSchemaDefinition;
62
+ formClass: string;
63
+ debugData: boolean;
64
+ debugSchema: boolean;
65
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
66
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
67
+ declare const _default: typeof __VLS_export;
68
+ export default _default;
69
+ type __VLS_WithSlots<T, S> = T & {
70
+ new (): {
71
+ $slots: S;
72
+ };
73
+ };
@@ -0,0 +1,49 @@
1
+ <script setup>
2
+ import { FormKitSchema } from "@formkit/vue";
3
+ import FuDataDebug from "./FUDataDebug.vue";
4
+ const props = defineProps({
5
+ data: {
6
+ type: Object,
7
+ default: null
8
+ },
9
+ schema: {
10
+ type: Object,
11
+ default: null
12
+ },
13
+ formClass: {
14
+ type: String,
15
+ default: ""
16
+ },
17
+ debugData: {
18
+ type: Boolean,
19
+ default: false
20
+ },
21
+ debugSchema: {
22
+ type: Boolean,
23
+ default: false
24
+ }
25
+ });
26
+ const formData = defineModel({ type: Object });
27
+ if (props.data) {
28
+ formData.value = props.data;
29
+ }
30
+ </script>
31
+
32
+ <template>
33
+ <FormKitSchema
34
+ v-if="schema"
35
+ :schema="schema"
36
+ :data="formData"
37
+ />
38
+ <slot />
39
+ <FuDataDebug
40
+ v-if="debugData"
41
+ :data="formData"
42
+ header="Data"
43
+ />
44
+ <FuDataDebug
45
+ v-if="debugSchema"
46
+ :data="schema"
47
+ header="Debug Schema"
48
+ />
49
+ </template>
@@ -0,0 +1,73 @@
1
+ import type { FormKitSchemaDefinition } from '@formkit/core';
2
+ import type { PropType } from 'vue';
3
+ declare var __VLS_6: {};
4
+ type __VLS_Slots = {} & {
5
+ default?: (props: typeof __VLS_6) => any;
6
+ };
7
+ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
8
+ data: {
9
+ type: ObjectConstructor;
10
+ default: null;
11
+ };
12
+ schema: {
13
+ type: PropType<FormKitSchemaDefinition>;
14
+ default: null;
15
+ };
16
+ formClass: {
17
+ type: StringConstructor;
18
+ default: string;
19
+ };
20
+ debugData: {
21
+ type: BooleanConstructor;
22
+ default: boolean;
23
+ };
24
+ debugSchema: {
25
+ type: BooleanConstructor;
26
+ default: boolean;
27
+ };
28
+ modelValue: {
29
+ type: PropType<Record<string, unknown>>;
30
+ };
31
+ }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
32
+ "update:modelValue": (value: Record<string, unknown> | undefined) => any;
33
+ }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
34
+ data: {
35
+ type: ObjectConstructor;
36
+ default: null;
37
+ };
38
+ schema: {
39
+ type: PropType<FormKitSchemaDefinition>;
40
+ default: null;
41
+ };
42
+ formClass: {
43
+ type: StringConstructor;
44
+ default: string;
45
+ };
46
+ debugData: {
47
+ type: BooleanConstructor;
48
+ default: boolean;
49
+ };
50
+ debugSchema: {
51
+ type: BooleanConstructor;
52
+ default: boolean;
53
+ };
54
+ modelValue: {
55
+ type: PropType<Record<string, unknown>>;
56
+ };
57
+ }>> & Readonly<{
58
+ "onUpdate:modelValue"?: ((value: Record<string, unknown> | undefined) => any) | undefined;
59
+ }>, {
60
+ data: Record<string, any>;
61
+ schema: FormKitSchemaDefinition;
62
+ formClass: string;
63
+ debugData: boolean;
64
+ debugSchema: boolean;
65
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
66
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
67
+ declare const _default: typeof __VLS_export;
68
+ export default _default;
69
+ type __VLS_WithSlots<T, S> = T & {
70
+ new (): {
71
+ $slots: S;
72
+ };
73
+ };