{% from "components/select-input.html" import select_nested %} {% macro checkbox( field, hint=False, width='2-3' ) %}
{{ checkbox_input(field.id, field.name, field.data) }}
{% endmacro %} {% macro checkboxes_nested(field, child_map, hint=None, disable=[], option_hints={}, hide_legend=False) %} {{ select_nested(field, child_map, hint=None, disable=[], option_hints={}, hide_legend=False, input="checkbox") }} {% endmacro %} {% macro checkbox_input(id, name, data=None, value="y") %} {% endmacro %} {% macro unlabelled_checkbox(id, name, data=None, value="y") %}
{{ checkbox_input(id, name, data, value) }}
{% endmacro %} {% macro checkbox_group( legend, fields ) %}
{{ legend }} {% for field in fields %} {{ checkbox(field) }} {% endfor %}
{% endmacro %}