Nicer forms

This commit is contained in:
Martin Müller 2017-07-18 16:51:50 +02:00
parent e2687550f5
commit ab381d2729
2 changed files with 42 additions and 7 deletions

View File

@ -21,7 +21,6 @@ h1 {
form { form {
padding: 5px; padding: 5px;
text-align: center;
} }
input { input {
@ -30,11 +29,21 @@ input {
border-radius: 5px; border-radius: 5px;
color: #eee; color: #eee;
margin: 0; margin: 0;
padding: 5px; padding: 1em;
vertical-align: middle; vertical-align: middle;
} }
label { .editform {
display: table;
margin-left: auto;
margin-right: auto;
}
.editform input {
margin: 0.5em;
}
.youtube label {
vertical-align: middle; vertical-align: middle;
} }
@ -119,3 +128,12 @@ nav .extra > a {
.edit { .edit {
border: 1px dashed #eee; border: 1px dashed #eee;
} }
.table-row {
display: table-row;
}
.table-cell {
display: table-cell;
}

View File

@ -2,8 +2,25 @@
{% block navigation %} {% block navigation %}
{% endblock %} {% endblock %}
{% block content %} {% block content %}
<form action="{{ request.path }}" method="POST"> <div class="editform">
<input type="button" value="Cancel" /> <h1>Filename</h1>
<input type="submit" value="Submit" /> <form action="{{ request.path }}" method="POST">
</form> <div class="table-row">
<div class="table-cell">
<label for="tags">Tags</label>
</div>
<div class="table-cell">
<input type="input" name="tags" id="tags" />
</div>
</div>
<div class="table-row">
<div class="table-cell">
</div>
<div class="table-cell">
<input type="button" value="Cancel" />
<input type="submit" value="Submit" />
</div>
</div>
</form>
</div>
{% endblock %} {% endblock %}