@sveltia/cms 0.115.2 → 0.116.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/dist/sveltia-cms.js +206 -206
- package/dist/sveltia-cms.js.map +1 -1
- package/dist/sveltia-cms.mjs +193 -193
- package/dist/sveltia-cms.mjs.map +1 -1
- package/package.json +1 -1
- package/schema/sveltia-cms.json +19 -6
- package/types/public.d.ts +9 -5
package/package.json
CHANGED
package/schema/sveltia-cms.json
CHANGED
|
@@ -3828,21 +3828,25 @@
|
|
|
3828
3828
|
},
|
|
3829
3829
|
"default": {
|
|
3830
3830
|
"anyOf": [
|
|
3831
|
-
{
|
|
3831
|
+
{
|
|
3832
|
+
"$ref": "#/definitions/SelectFieldValue"
|
|
3833
|
+
},
|
|
3832
3834
|
{
|
|
3833
3835
|
"type": "array",
|
|
3834
|
-
"items": {
|
|
3836
|
+
"items": {
|
|
3837
|
+
"$ref": "#/definitions/SelectFieldValue"
|
|
3838
|
+
}
|
|
3835
3839
|
}
|
|
3836
3840
|
],
|
|
3837
|
-
"description": "Default value
|
|
3838
|
-
"markdownDescription": "Default value
|
|
3841
|
+
"description": "Default value that matches one of the options. When `multiple` is `true`, it should be an array of valid values.",
|
|
3842
|
+
"markdownDescription": "Default value that matches one of the options. When `multiple` is `true`, it should be an array of valid values."
|
|
3839
3843
|
},
|
|
3840
3844
|
"options": {
|
|
3841
3845
|
"anyOf": [
|
|
3842
3846
|
{
|
|
3843
3847
|
"type": "array",
|
|
3844
3848
|
"items": {
|
|
3845
|
-
"
|
|
3849
|
+
"$ref": "#/definitions/SelectFieldValue"
|
|
3846
3850
|
}
|
|
3847
3851
|
},
|
|
3848
3852
|
{
|
|
@@ -3854,7 +3858,7 @@
|
|
|
3854
3858
|
"type": "string"
|
|
3855
3859
|
},
|
|
3856
3860
|
"value": {
|
|
3857
|
-
"
|
|
3861
|
+
"$ref": "#/definitions/SelectFieldValue"
|
|
3858
3862
|
}
|
|
3859
3863
|
},
|
|
3860
3864
|
"required": [
|
|
@@ -3966,6 +3970,15 @@
|
|
|
3966
3970
|
"description": "Select field definition.",
|
|
3967
3971
|
"markdownDescription": "Select field definition."
|
|
3968
3972
|
},
|
|
3973
|
+
"SelectFieldValue": {
|
|
3974
|
+
"type": [
|
|
3975
|
+
"string",
|
|
3976
|
+
"number",
|
|
3977
|
+
"null"
|
|
3978
|
+
],
|
|
3979
|
+
"description": "Select field option value.",
|
|
3980
|
+
"markdownDescription": "Select field option value."
|
|
3981
|
+
},
|
|
3969
3982
|
"StringField": {
|
|
3970
3983
|
"type": "object",
|
|
3971
3984
|
"additionalProperties": false,
|
package/types/public.d.ts
CHANGED
|
@@ -992,6 +992,10 @@ export type RelationFieldProps = {
|
|
|
992
992
|
* Relation field definition.
|
|
993
993
|
*/
|
|
994
994
|
export type RelationField = CommonFieldProps & StandardFieldProps & RelationFieldProps & MultiOptionFieldProps;
|
|
995
|
+
/**
|
|
996
|
+
* Select field option value.
|
|
997
|
+
*/
|
|
998
|
+
export type SelectFieldValue = string | number | null;
|
|
995
999
|
/**
|
|
996
1000
|
* Select field properties.
|
|
997
1001
|
*/
|
|
@@ -1001,16 +1005,16 @@ export type SelectFieldProps = {
|
|
|
1001
1005
|
*/
|
|
1002
1006
|
widget: "select";
|
|
1003
1007
|
/**
|
|
1004
|
-
* Default value
|
|
1005
|
-
* `multiple` is `
|
|
1008
|
+
* Default value that matches one of the
|
|
1009
|
+
* options. When `multiple` is `true`, it should be an array of valid values.
|
|
1006
1010
|
*/
|
|
1007
|
-
default?:
|
|
1011
|
+
default?: SelectFieldValue | SelectFieldValue[];
|
|
1008
1012
|
/**
|
|
1009
1013
|
* Options.
|
|
1010
1014
|
*/
|
|
1011
|
-
options:
|
|
1015
|
+
options: SelectFieldValue[] | {
|
|
1012
1016
|
label: string;
|
|
1013
|
-
value:
|
|
1017
|
+
value: SelectFieldValue;
|
|
1014
1018
|
}[];
|
|
1015
1019
|
};
|
|
1016
1020
|
/**
|