Formularios
This commit is contained in:
parent
33ddca80ba
commit
ab27eaaed5
23 changed files with 126 additions and 5 deletions
1
_includes/boolean.html
Symbolic link
1
_includes/boolean.html
Symbolic link
|
@ -0,0 +1 @@
|
|||
form/boolean.html
|
1
_includes/email.html
Symbolic link
1
_includes/email.html
Symbolic link
|
@ -0,0 +1 @@
|
|||
form/email.html
|
25
_includes/form/boolean.html
Normal file
25
_includes/form/boolean.html
Normal file
|
@ -0,0 +1,25 @@
|
|||
<div class="form-check text-left">
|
||||
<input
|
||||
{% if include.field[1].help %}
|
||||
aria-describedby="help-{{ include.field[0] }}"
|
||||
{% endif %}
|
||||
{% if include.field[1].required %}
|
||||
required
|
||||
{% endif %}
|
||||
type="checkbox"
|
||||
name="{{ include.field[0] }}"
|
||||
id="{{ include.field[1].id | default: include.field[0] }}"
|
||||
class="form-check-input" />
|
||||
|
||||
<label
|
||||
class="form-check-label"
|
||||
for="{{ include.field[1].id | default: include.field[0] }}">
|
||||
{{ include.field[1].label }}
|
||||
</label>
|
||||
|
||||
{%- if include.field[1].help -%}
|
||||
<small id="help-{{ include.field[0] }}" class="form-text">
|
||||
{{ include.field[1].help }}
|
||||
</small>
|
||||
{%- endif -%}
|
||||
</div>
|
1
_includes/form/email.html
Normal file
1
_includes/form/email.html
Normal file
|
@ -0,0 +1 @@
|
|||
{% include input.html field=field %}
|
24
_includes/form/input.html
Normal file
24
_includes/form/input.html
Normal file
|
@ -0,0 +1,24 @@
|
|||
<div class="form-group">
|
||||
<label for="{{ include.field[1].id | default: include.field[0] }}">
|
||||
{% if include.field[1].required %}*{% endif %}
|
||||
{{ include.field[1].label }}
|
||||
</label>
|
||||
|
||||
<input
|
||||
{% if include.field[1].help %}
|
||||
aria-describedby="help-{{ include.field[0] }}"
|
||||
{% endif %}
|
||||
{% if include.field[1].required %}
|
||||
required
|
||||
{% endif %}
|
||||
type="{{ include.field[1].type }}"
|
||||
name="{{ include.field[0] }}"
|
||||
id="{{ include.field[1].id | default: include.field[0] }}"
|
||||
class="form-control" />
|
||||
|
||||
{%- if include.field[1].help -%}
|
||||
<small id="help-{{ include.field[0] }}" class="form-text">
|
||||
{{ include.field[1].help }}
|
||||
</small>
|
||||
{%- endif -%}
|
||||
</div>
|
1
_includes/form/number.html
Normal file
1
_includes/form/number.html
Normal file
|
@ -0,0 +1 @@
|
|||
{% include input.html field=field %}
|
30
_includes/form/predefined_array.html
Normal file
30
_includes/form/predefined_array.html
Normal file
|
@ -0,0 +1,30 @@
|
|||
<div class="form-group">
|
||||
<label for="{{ include.field[1].id | default: include.field[0] }}">
|
||||
{% if include.field[1].required %}*{% endif %}
|
||||
{{ include.field[1].label }}
|
||||
</label>
|
||||
|
||||
<select
|
||||
{% if include.field[1].help %}
|
||||
aria-describedby="help-{{ include.field[0] }}"
|
||||
{% endif %}
|
||||
{% if include.field[1].required %}
|
||||
required
|
||||
{% endif %}
|
||||
name="{{ include.field[0] }}"
|
||||
id="{{ include.field[1].id | default: include.field[0] }}"
|
||||
class="form-control">
|
||||
|
||||
<option value="" selected></option>
|
||||
|
||||
{%- for option in include.field[1].values -%}
|
||||
<option value="{{ option }}">{{ option }}</option>
|
||||
{%- endfor -%}
|
||||
</select>
|
||||
|
||||
{%- if include.field[1].help -%}
|
||||
<small id="help-{{ include.field[0] }}" class="form-text">
|
||||
{{ include.field[1].help }}
|
||||
</small>
|
||||
{%- endif -%}
|
||||
</div>
|
1
_includes/form/section.html
Normal file
1
_includes/form/section.html
Normal file
|
@ -0,0 +1 @@
|
|||
<h2 id="{{ include.field[0] }}">{{ include.field[1].title }}</h2>
|
1
_includes/form/separator.html
Normal file
1
_includes/form/separator.html
Normal file
|
@ -0,0 +1 @@
|
|||
<hr/>
|
1
_includes/form/string.html
Normal file
1
_includes/form/string.html
Normal file
|
@ -0,0 +1 @@
|
|||
{% include input.html field=field %}
|
1
_includes/form/submit.html
Normal file
1
_includes/form/submit.html
Normal file
|
@ -0,0 +1 @@
|
|||
<input type="submit" class="btn btn-success" value="{{ include.field[1].label }}" />
|
24
_includes/form/text.html
Normal file
24
_includes/form/text.html
Normal file
|
@ -0,0 +1,24 @@
|
|||
<div class="form-group">
|
||||
<label for="{{ include.field[0] }}">
|
||||
{% if include.field[1].required %}*{% endif %}
|
||||
{{ include.field[1].label }}
|
||||
</label>
|
||||
|
||||
<textarea
|
||||
{% if include.field[1].help %}
|
||||
aria-describedby="help-{{ include.field[0] }}"
|
||||
{% endif -%}
|
||||
{% if include.field[1].required %}
|
||||
required
|
||||
{% endif %}
|
||||
name="{{ include.field[0] }}"
|
||||
id="{{ include.field[1].id | default: include.field[0] }}"
|
||||
class="form-control">
|
||||
</textarea>
|
||||
|
||||
{%- if include.field[1].help -%}
|
||||
<small id="help-{{ include.field[0] }}" class="form-text">
|
||||
{{ include.field[1].help }}
|
||||
</small>
|
||||
{%- endif -%}
|
||||
</div>
|
1
_includes/form/url.html
Normal file
1
_includes/form/url.html
Normal file
|
@ -0,0 +1 @@
|
|||
{% include input.html field=field %}
|
1
_includes/input.html
Symbolic link
1
_includes/input.html
Symbolic link
|
@ -0,0 +1 @@
|
|||
form/input.html
|
|
@ -1,6 +1,6 @@
|
|||
<nav class="navbar navbar-expand-lg navbar-light bg-light d-print-block" role="navigation" aria-label="{{ site.i18n.menu.title }}">
|
||||
<a class="navbar-brand" href="">
|
||||
{% include_cached logo.svg %}
|
||||
{% include_cached logo.html %}
|
||||
</a>
|
||||
|
||||
{% comment %}
|
||||
|
@ -14,14 +14,14 @@
|
|||
{% endcomment %}
|
||||
|
||||
<li class="nav-item">
|
||||
<a class="nav-link{% if page.url == item.url %} active{% endif %}" href="{{ item.url }}">
|
||||
{{ item.text }}
|
||||
<a class="nav-link{% if page.url == item.href %} active{% endif %}" href="{{ item.href }}">
|
||||
{{ item.title }}
|
||||
|
||||
{%- if page.url == item.url -%}
|
||||
{%- if page.url == item.href -%}
|
||||
<span class="sr-only">
|
||||
{{ site.i18n.menu.active | default: '(current)' }}
|
||||
</span>
|
||||
{%- endif %}
|
||||
{%- endif -%}
|
||||
</a>
|
||||
</li>
|
||||
{%- endfor -%}
|
||||
|
|
1
_includes/number.html
Symbolic link
1
_includes/number.html
Symbolic link
|
@ -0,0 +1 @@
|
|||
form/number.html
|
1
_includes/predefined_array.html
Symbolic link
1
_includes/predefined_array.html
Symbolic link
|
@ -0,0 +1 @@
|
|||
form/predefined_array.html
|
1
_includes/section.html
Symbolic link
1
_includes/section.html
Symbolic link
|
@ -0,0 +1 @@
|
|||
form/section.html
|
1
_includes/separator.html
Symbolic link
1
_includes/separator.html
Symbolic link
|
@ -0,0 +1 @@
|
|||
form/separator.html
|
1
_includes/string.html
Symbolic link
1
_includes/string.html
Symbolic link
|
@ -0,0 +1 @@
|
|||
form/string.html
|
1
_includes/submit.html
Symbolic link
1
_includes/submit.html
Symbolic link
|
@ -0,0 +1 @@
|
|||
form/submit.html
|
1
_includes/text.html
Symbolic link
1
_includes/text.html
Symbolic link
|
@ -0,0 +1 @@
|
|||
form/text.html
|
1
_includes/url.html
Symbolic link
1
_includes/url.html
Symbolic link
|
@ -0,0 +1 @@
|
|||
form/url.html
|
Loading…
Reference in a new issue