~artemis/paste

fe6758c8988a252f0c9abed1dd0dc2ef04f99cae — Diane 4 years ago 0adc548
fixed form error styling
2 files changed, 5 insertions(+), 2 deletions(-)

M handlers.go
M templates/homepage.html
M handlers.go => handlers.go +1 -1
@@ 186,7 186,7 @@ func (h Handlers) handleNewPaste(w http.ResponseWriter, req *http.Request) {
	if nil != validationErrors &&
		0 < len(validationErrors) {
		h.PasteSubmitError(400, validationErrors, &Content{
			Error:           "Form submit error",
			Error:           "You must provide a document and a valid time limit",
			OriginalCommand: command,
		})(w, req)
		return

M templates/homepage.html => templates/homepage.html +4 -1
@@ 11,6 11,9 @@
	<hr>

	<main>
		{{if .Error}}
			<p class="error">{{.Error}}</p>
		{{end}}
		<form method="post">
			<fieldset>
				<label for="paste">Your document</label>


@@ 19,7 22,7 @@
						  name="paste"
						  class="fullsize"
						  rows="20"
						  placeholder="Paste your document here"></textarea>
						  placeholder="Paste your document here">{{.Value}}</textarea>
			</fieldset>

			<footer class="spaced">