Bugfix/improve form widgets
In this MR, 3 commits, each one corresponding to one change:
- Improve syntax for range widgets:
- Invert the order of parameters for widgets using range (
widgets/form.js
). - Change the parameter of the sib-widget from
data-parent
on the parent template, todata-range
on the child template.
- Invert the order of parameters for widgets using range (
- Allow to use a callback after the render of a widget. With this callback, we can initialize the choices library for the autocomplete field. NB: should we move this widget in another file to import the library only when needed?
- For the placeholder dropdown widget, we force the selection of the placeholder when
value == ""
, which means no value is defined for the field