Closed sdetweil closed 2 weeks ago
if I change the sample in a similar way, (no array, but property in an object) , I get no results..
{
"schema": {
"menu": {
"type":"object",
"properties": {
"option":{
"type": "string",
"title": "Option",
"enum": [
"starter",
"maincourse",
"cheese",
"dessert"
]
}
}
}
},
"form": [
{
"key": "menu.option",
"type": "checkboxes",
"titleMap": {
"starter": "Starter would be great",
"maincourse": "No way I'll skip the main course",
"cheese": "Cheddar rules!",
"dessert": "Thumbs up for a dessert"
}
},
{
"type": "submit",
"title": "Submit",
"id": "submit_button"
}
]
}
so, this is a bug in the validation , when using checkboxes in the form (it also sneaks in in the schema)
the doc says
https://github.com/jsonform/jsonform/wiki#multiple-options-the-checkboxes-type
Multiple options: the checkboxes type If you need the user to select one or more options among a list of choices, the checkboxes form field is for your. _It applies to an array property whose items_ schema explicitly defines a list of possible values in an enum property.
there is a separate bug in the doc, above, which says
the checkboxes form field is for your.
should be
the checkboxes form field is for you.
wiki fixed (sept 18,2022)
i am trying to enhance lib to support scrollable checkboxes..
so I built this form
get the right presentation but on submit, I get no results.. (in playground)