Refactor html templates
This commit entirely refactors the use of html templates. Instead of inheriting from a shared template, we insert the results into a base template.
This commit is contained in:
parent
6ede99d7c6
commit
d235ee4e5c
59 changed files with 869 additions and 777 deletions
22
pkg/httpx/form.html
Normal file
22
pkg/httpx/form.html
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
<div class="pure-u-1">
|
||||
{{ block "form/extra" . }}<!-- no extra -->{{ end }}
|
||||
|
||||
<form class="pure-form pure-form-aligned" method="POST">
|
||||
<fieldset>
|
||||
{{ block "form/message" . }}
|
||||
{{ $E := .Error }}
|
||||
{{ if not (eq $E "") }}
|
||||
<div class="pure-form-group">
|
||||
<p class="error-message">
|
||||
{{ $E }}
|
||||
</p>
|
||||
</div>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
{{ block "form/inside" . }}<!-- no inside -->{{ end }}
|
||||
{{ .Form }}
|
||||
<input type="submit" value="{{ block "form/button" .}}Submit{{ end }}" class="pure-button">
|
||||
</fieldset>
|
||||
</form>
|
||||
</div>
|
||||
Loading…
Add table
Add a link
Reference in a new issue