This commit is contained in:
@@ -11,8 +11,13 @@
|
||||
<link href="https://fonts.googleapis.com/css2?family=Archivo:ital,wght@0,400;0,500;0,600;1,400&family=IBM+Plex+Mono:wght@400;500;600&display=swap" rel="stylesheet">
|
||||
<link rel="stylesheet" href="/static/app.css">
|
||||
<script src="/static/htmx.min.js" defer></script>
|
||||
<script src="/static/app.js" defer></script>
|
||||
</head>
|
||||
<body>
|
||||
<div id="submit-progress" class="submit-progress" role="progressbar"
|
||||
aria-label="Posting" aria-valuetext="Posting" hidden>
|
||||
<span class="submit-progress-bar"></span>
|
||||
</div>
|
||||
<a class="skip" href="#main">Skip to content</a>
|
||||
<header class="top">
|
||||
<div class="top-inner">
|
||||
|
||||
@@ -3,13 +3,14 @@
|
||||
{{if canReply .User .Root}}
|
||||
<details class="post-composer">
|
||||
<summary>Reply</summary>
|
||||
<form class="post-form" method="post" action="/posts">
|
||||
<form class="post-form" method="post" action="/posts"
|
||||
data-submit-once data-submitting-label="Posting…">
|
||||
<input type="hidden" name="_csrf" value="{{.CSRF}}">
|
||||
<input type="hidden" name="parent_id" value="{{.Post.ID}}">
|
||||
<label for="reply-{{.Post.ID}}">Reply to {{.Post.AuthorName}}</label>
|
||||
<textarea id="reply-{{.Post.ID}}" name="body" rows="5" required maxlength="12000"></textarea>
|
||||
<div class="post-form-actions">
|
||||
<button type="submit" class="btn btn-primary">Post reply</button>
|
||||
<button type="submit" class="btn btn-primary" data-submit-button>Post reply</button>
|
||||
<button type="reset" class="btn btn-ghost"
|
||||
onclick="this.closest('details').removeAttribute('open')">Cancel</button>
|
||||
</div>
|
||||
|
||||
@@ -4,7 +4,8 @@
|
||||
<h1>Ask a question</h1>
|
||||
<p class="lede">It lands on today’s hunt (Pacific time). People vote; the ranking resets at midnight PT.</p>
|
||||
{{if .Error}}<p class="banner error" role="alert">{{.Error}}</p>{{end}}
|
||||
<form class="ask" method="post" action="/submit">
|
||||
<form class="ask" method="post" action="/submit"
|
||||
data-submit-once data-submitting-label="Posting…">
|
||||
<input type="hidden" name="_csrf" value="{{.CSRF}}">
|
||||
<label for="title">Title</label>
|
||||
<input id="title" name="title" type="text" required maxlength="120" value="{{.TitleVal}}" placeholder="Water heater popping after showers">
|
||||
@@ -12,7 +13,7 @@
|
||||
<textarea id="body" name="body" rows="8" required maxlength="8000" placeholder="Age of the house, what you already tried, where you are in the Bay if it helps.">{{.BodyVal}}</textarea>
|
||||
<label for="city">City <span class="optional">(optional)</span></label>
|
||||
<input id="city" name="city" type="text" maxlength="80" value="{{.CityVal}}" placeholder="Oakland">
|
||||
<button type="submit" class="btn btn-primary">Submit to today’s hunt</button>
|
||||
<button type="submit" class="btn btn-primary" data-submit-button>Submit to today’s hunt</button>
|
||||
</form>
|
||||
</main>
|
||||
{{template "footer" .}}
|
||||
|
||||
Reference in New Issue
Block a user