add webmention form to posts

This commit is contained in:
yequari 2023-10-20 17:20:07 -07:00
parent 183476a9f3
commit 7cc89d81b0
4 changed files with 22 additions and 0 deletions

View File

@ -10,6 +10,7 @@
{{ .Content }}
</div>
</article>
{{ partial "webmentions.html" }}
<div id="webmentions"></div>
</section>
{{ end }}

View File

@ -10,6 +10,7 @@
{{ .Content }}
</div>
</article>
{{ partial "webmentions.html" }}
<div id="webmentions"></div>
</section>
{{ end }}

View File

@ -0,0 +1,9 @@
<div class="send-webmention">
<p>Have you written a response to this post? Send me a webmention!</p>
<form action="https://webmention.io/yequari.com/webmention" method="post" class="webmention-form">
<label for="form-webmention-source">URL</label>
<input id="form-webmention-source" type="url" name="source" placeholder="https://example.com" required/>
<input type="hidden" name="target" value="{{ .Page.URL }}"/>
<input type="submit" class="button" value="Send Webmention"/>
</form>
</div>

View File

@ -374,6 +374,17 @@ footer {
overflow-wrap: break-word;
}
.send-webmention {
margin: 55px 25px;
max-width: fit-content;
border: 1px dotted var(--primary-text);
padding: 0 20px 20px;
}
.send-webmention p {
font-size: 1.3rem;
}
@media only screen and (max-width: 500px) {
div.nav {
border: none;