@koumoul/vjsf 3.5.1 → 3.6.0
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.
- package/package.json +2 -2
- package/src/components/node.vue +7 -7
- package/types/components/fragments/child-subtitle.vue.d.ts +2 -2
- package/types/components/fragments/select-item.vue.d.ts +2 -2
- package/types/components/fragments/select-selection.vue.d.ts +2 -2
- package/types/components/tree.vue.d.ts +2 -2
- package/types/components/vjsf.vue.d.ts +2 -2
- package/types/composables/use-get-items.d.ts +1 -1
- package/types/composables/use-node.d.ts +3 -3
- package/types/composables/use-select-node.d.ts +1 -1
- package/types/composables/use-vjsf.d.ts +2 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@koumoul/vjsf",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.6.0",
|
|
4
4
|
"description": "Generate forms for the vuetify UI library (vuejs) based on annotated JSON schemas.",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"test": "vitest",
|
|
@@ -70,7 +70,7 @@
|
|
|
70
70
|
"vuetify": "^3.6.13"
|
|
71
71
|
},
|
|
72
72
|
"dependencies": {
|
|
73
|
-
"@json-layout/core": "~1.
|
|
73
|
+
"@json-layout/core": "~1.3.0",
|
|
74
74
|
"@vueuse/core": "^10.5.0",
|
|
75
75
|
"debug": "^4.3.4"
|
|
76
76
|
},
|
package/src/components/node.vue
CHANGED
|
@@ -50,7 +50,7 @@ const nodeClasses = computed(() => {
|
|
|
50
50
|
return classes
|
|
51
51
|
})
|
|
52
52
|
|
|
53
|
-
if (props.modelValue.layout.comp !== 'none' && !props.statefulLayout.options.nodeComponents[props.modelValue.layout.comp]) {
|
|
53
|
+
if (props.modelValue.layout.comp !== 'none' && !props.modelValue.slots?.component && !props.statefulLayout.options.nodeComponents[props.modelValue.layout.comp]) {
|
|
54
54
|
console.error(`vjsf: missing component to render vjsf node "${props.modelValue.layout.comp}", maybe you forgot to register a component from a plugin ?`)
|
|
55
55
|
}
|
|
56
56
|
|
|
@@ -64,9 +64,9 @@ if (props.modelValue.layout.comp !== 'none' && !props.statefulLayout.options.nod
|
|
|
64
64
|
:class="nodeClasses"
|
|
65
65
|
>
|
|
66
66
|
<node-slot
|
|
67
|
-
v-if="modelValue.
|
|
67
|
+
v-if="modelValue.slots?.before"
|
|
68
68
|
key="before"
|
|
69
|
-
:layout-slot="modelValue.
|
|
69
|
+
:layout-slot="modelValue.slots?.before"
|
|
70
70
|
:node="modelValue"
|
|
71
71
|
:stateful-layout="statefulLayout"
|
|
72
72
|
:class="beforeAfterClasses[modelValue.options.density]"
|
|
@@ -77,9 +77,9 @@ if (props.modelValue.layout.comp !== 'none' && !props.statefulLayout.options.nod
|
|
|
77
77
|
:node="modelValue"
|
|
78
78
|
/>
|
|
79
79
|
<node-slot
|
|
80
|
-
v-if="modelValue.
|
|
80
|
+
v-if="modelValue.slots?.component"
|
|
81
81
|
key="component"
|
|
82
|
-
:layout-slot="modelValue.
|
|
82
|
+
:layout-slot="modelValue.slots?.component"
|
|
83
83
|
:node="modelValue"
|
|
84
84
|
:stateful-layout="statefulLayout"
|
|
85
85
|
/>
|
|
@@ -91,9 +91,9 @@ if (props.modelValue.layout.comp !== 'none' && !props.statefulLayout.options.nod
|
|
|
91
91
|
/>
|
|
92
92
|
|
|
93
93
|
<node-slot
|
|
94
|
-
v-if="modelValue.
|
|
94
|
+
v-if="modelValue.slots?.after"
|
|
95
95
|
key="after"
|
|
96
|
-
:layout-slot="modelValue.
|
|
96
|
+
:layout-slot="modelValue.slots?.after"
|
|
97
97
|
:node="modelValue"
|
|
98
98
|
:stateful-layout="statefulLayout"
|
|
99
99
|
:class="beforeAfterClasses[modelValue.options.density]"
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<any, {
|
|
2
|
-
modelValue: import("
|
|
2
|
+
modelValue: import("../../../node_modules/@json-layout/core/types/state/types.js").StateNode;
|
|
3
3
|
$props: {
|
|
4
|
-
modelValue?: import("
|
|
4
|
+
modelValue?: import("../../../node_modules/@json-layout/core/types/state/types.js").StateNode | undefined;
|
|
5
5
|
};
|
|
6
6
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<any> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
7
7
|
export default _default;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<any, {
|
|
2
2
|
multiple: boolean;
|
|
3
|
-
item: import("
|
|
3
|
+
item: import("../../../node_modules/@json-layout/vocabulary/types/normalized-layout/types.js").SelectItem;
|
|
4
4
|
itemProps: Record<string, any>;
|
|
5
5
|
$props: {
|
|
6
6
|
readonly multiple?: boolean | undefined;
|
|
7
|
-
readonly item?: import("
|
|
7
|
+
readonly item?: import("../../../node_modules/@json-layout/vocabulary/types/normalized-layout/types.js").SelectItem | undefined;
|
|
8
8
|
readonly itemProps?: Record<string, any> | undefined;
|
|
9
9
|
};
|
|
10
10
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<any> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<any, {
|
|
2
2
|
multiple: boolean;
|
|
3
|
-
item: import("
|
|
3
|
+
item: import("../../../node_modules/@json-layout/vocabulary/types/normalized-layout/types.js").SelectItem;
|
|
4
4
|
last: boolean;
|
|
5
5
|
$props: {
|
|
6
6
|
readonly multiple?: boolean | undefined;
|
|
7
|
-
readonly item?: import("
|
|
7
|
+
readonly item?: import("../../../node_modules/@json-layout/vocabulary/types/normalized-layout/types.js").SelectItem | undefined;
|
|
8
8
|
readonly last?: boolean | undefined;
|
|
9
9
|
};
|
|
10
10
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<any> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<any, {
|
|
2
|
-
modelValue: import("
|
|
2
|
+
modelValue: import("../../node_modules/@json-layout/core/types/state/types.js").StateTree;
|
|
3
3
|
statefulLayout: import("../types.js").VjsfStatefulLayout;
|
|
4
4
|
$props: {
|
|
5
|
-
readonly modelValue?: import("
|
|
5
|
+
readonly modelValue?: import("../../node_modules/@json-layout/core/types/state/types.js").StateTree | undefined;
|
|
6
6
|
readonly statefulLayout?: import("../types.js").VjsfStatefulLayout | undefined;
|
|
7
7
|
};
|
|
8
8
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<any> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
@@ -3,12 +3,12 @@ declare const _default: import("vue").DefineComponent<any, {
|
|
|
3
3
|
options: Partial<Omit<import("../types.js").VjsfOptions, "onData" | "onUpdate" | "onAutofocus" | "width" | "vjsfSlots">> | null;
|
|
4
4
|
modelValue: any;
|
|
5
5
|
schema: Record<string, any>;
|
|
6
|
-
precompiledLayout: import("
|
|
6
|
+
precompiledLayout: import("../../node_modules/@json-layout/core/types/compile/types.js").CompiledLayout;
|
|
7
7
|
$props: {
|
|
8
8
|
readonly options?: Partial<Omit<import("../types.js").VjsfOptions, "onData" | "onUpdate" | "onAutofocus" | "width" | "vjsfSlots">> | null | undefined;
|
|
9
9
|
readonly modelValue?: any;
|
|
10
10
|
readonly schema?: Record<string, any> | undefined;
|
|
11
|
-
readonly precompiledLayout?: import("
|
|
11
|
+
readonly precompiledLayout?: import("../../node_modules/@json-layout/core/types/compile/types.js").CompiledLayout | undefined;
|
|
12
12
|
};
|
|
13
13
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<any> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
14
14
|
export default _default;
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
export default function _default(nodeRef: import('vue').Ref<import('../types.js').VjsfNode>, statefulLayout: import('../types.js').VjsfStatefulLayout): {
|
|
6
6
|
hasItems: import("vue").ComputedRef<boolean>;
|
|
7
|
-
items: import("vue").Ref<import("
|
|
7
|
+
items: import("vue").Ref<import("../../node_modules/@json-layout/vocabulary/types/normalized-layout/types.js").SelectItems, import("../../node_modules/@json-layout/vocabulary/types/normalized-layout/types.js").SelectItems>;
|
|
8
8
|
loading: import("vue").Ref<boolean, boolean>;
|
|
9
9
|
search: import("vue").Ref<string, string>;
|
|
10
10
|
prepareSelectedItem: (selectedItem: any, itemValue: any) => any;
|
|
@@ -24,9 +24,9 @@ export default function _default(nodeRef: import('vue').Ref<import('../types.js'
|
|
|
24
24
|
}>;
|
|
25
25
|
compSlots: import("vue").ComputedRef<Record<string, any>>;
|
|
26
26
|
options: import("vue").ComputedRef<Required<import("../types.js").VjsfOptions>>;
|
|
27
|
-
skeleton: import("vue").ComputedRef<import("
|
|
28
|
-
layout: import("vue").ComputedRef<import("
|
|
27
|
+
skeleton: import("vue").ComputedRef<import("../../node_modules/@json-layout/core/types/compile/types.js").SkeletonNode>;
|
|
28
|
+
layout: import("vue").ComputedRef<import("../../node_modules/@json-layout/vocabulary/types/normalized-layout/types.js").BaseCompObject>;
|
|
29
29
|
data: import("vue").ComputedRef<unknown>;
|
|
30
|
-
children: import("vue").ComputedRef<import("
|
|
30
|
+
children: import("vue").ComputedRef<import("../../node_modules/@json-layout/core/types/state/types.js").StateNode[] | undefined>;
|
|
31
31
|
};
|
|
32
32
|
//# sourceMappingURL=use-node.d.ts.map
|
|
@@ -18,7 +18,7 @@ export default function _default(nodeRef: import('vue').Ref<import('../types.js'
|
|
|
18
18
|
}>;
|
|
19
19
|
getItems: {
|
|
20
20
|
hasItems: import("vue").ComputedRef<boolean>;
|
|
21
|
-
items: import("vue").Ref<import("
|
|
21
|
+
items: import("vue").Ref<import("../../node_modules/@json-layout/vocabulary/types/normalized-layout/types.js").SelectItems, import("../../node_modules/@json-layout/vocabulary/types/normalized-layout/types.js").SelectItems>;
|
|
22
22
|
loading: import("vue").Ref<boolean, boolean>;
|
|
23
23
|
search: import("vue").Ref<string, string>;
|
|
24
24
|
prepareSelectedItem: (selectedItem: any, itemValue: any) => any;
|
|
@@ -8,9 +8,9 @@ export const emits: {
|
|
|
8
8
|
*/
|
|
9
9
|
'update:state': (state: import('../types.js').VjsfStatefulLayout) => boolean;
|
|
10
10
|
};
|
|
11
|
-
export function useVjsf(schema: import('vue').Ref<Object>, modelValue: import('vue').Ref<any>, options: import('vue').Ref<import("../types.js").PartialVjsfOptions | null>, nodeComponents: Record<string, import('vue').Component>, emit: any, compile?: typeof import("@json-layout/core").compile | undefined, precompiledLayout?: import("vue").Ref<import("
|
|
11
|
+
export function useVjsf(schema: import('vue').Ref<Object>, modelValue: import('vue').Ref<any>, options: import('vue').Ref<import("../types.js").PartialVjsfOptions | null>, nodeComponents: Record<string, import('vue').Component>, emit: any, compile?: typeof import("@json-layout/core").compile | undefined, precompiledLayout?: import("vue").Ref<import("../../node_modules/@json-layout/core/types/compile/types.js").CompiledLayout, import("../../node_modules/@json-layout/core/types/compile/types.js").CompiledLayout> | undefined): {
|
|
12
12
|
el: import("vue").Ref<null, null>;
|
|
13
13
|
statefulLayout: import("vue").ShallowRef<import("../types.js").VjsfStatefulLayout | null>;
|
|
14
|
-
stateTree: import("vue").ShallowRef<import("
|
|
14
|
+
stateTree: import("vue").ShallowRef<import("../../node_modules/@json-layout/core/types/state/types.js").StateTree | null>;
|
|
15
15
|
};
|
|
16
16
|
//# sourceMappingURL=use-vjsf.d.ts.map
|