mirror of
https://github.com/simple-login/app.git
synced 2024-11-16 00:48:32 +01:00
d49f6b88a9
* update djlint * reformat all files * update precommit version --------- Co-authored-by: Son NK <son@simplelogin.io>
23 lines
683 B
HTML
23 lines
683 B
HTML
{% macro render_field(field) %}
|
|
<div class="form-group row">
|
|
<label class="col-sm-2 col-form-label">{{ field.label }}</label>
|
|
<div class="col-sm-10">
|
|
{{ field(**kwargs) |safe }}
|
|
<small class="form-text text-muted">{{ field.description }}</small>
|
|
{% if field.errors %}
|
|
|
|
<ul class="errors">
|
|
{% for error in field.errors %}<li>{{ error }}</li>{% endfor %}
|
|
</ul>
|
|
{% endif %}
|
|
</div>
|
|
</div>
|
|
{% endmacro %}
|
|
{% macro render_field_errors(field) %}
|
|
{% if field.errors %}
|
|
|
|
<ul class="errors">
|
|
{% for error in field.errors %}<li class="text-danger">{{ error }}</li>{% endfor %}
|
|
</ul>
|
|
{% endif %}
|
|
{% endmacro %}
|