- Notifications
You must be signed in to change notification settings - Fork 52
Closed
Labels
djangoRelated to Django templates capabilitiesRelated to Django templates capabilitiesenhancementNew feature or requestNew feature or requesthelp wantedExtra attention is neededExtra attention is needed
Milestone
Description
If a template contains {% for field in form %} or even {% if form %}, then it's easy enough to render in django-pattern-library so long as we force the form to be null in the YAML context, and are happy not to have the form.
If the form is rendered explicitly by field names, then it requires a lot more work, and support for this is not documented. I had a quick go, but my template has things like:
{% include "patterns/molecules/form_field.html" with field=form.email %}and that template has a custom filter: {{ field|field_type }} which necessitated YAML like:
form: email: bound_field: field: widget: class: __name__: char_fieldI didn't go much further, because these is even more convoluted markup in my chosen template, and it wasn't a high enough priority.
Metadata
Metadata
Assignees
Labels
djangoRelated to Django templates capabilitiesRelated to Django templates capabilitiesenhancementNew feature or requestNew feature or requesthelp wantedExtra attention is neededExtra attention is needed