1
0

Moved a link to a footer of a post. Removed "Link:". Add span element if there is no URL, because justify-content: space-between is used, and without an element a date will move to the left with display: flex, even with text-align: right.

This commit is contained in:
Alexander Andreev 2023-09-25 16:55:42 +04:00
parent 5bc4f13c38
commit 24cf81a3ce
Signed by: Arav
GPG Key ID: D22A817D95815393
2 changed files with 6 additions and 4 deletions

View File

@ -5,5 +5,6 @@ button:not(:last-child) { padding-right: 1rem; }
article header a { color: var(--text-color); } article header a { color: var(--text-color); }
article footer { article footer {
text-align: right; display: flex;
justify-content: space-between;
padding: 0; } padding: 0; }

View File

@ -31,15 +31,16 @@ block content
header header
a(href=`#${post.PostID()}`) a(href=`#${post.PostID()}`)
h3= post.Category.Name + ": " + post.Title h3= post.Category.Name + ": " + post.Title
if (post.URL != "")
p Link:
a(href=post.PostURL(r.Host, false)) #{post.PostURL(r.Host, false)}
each line in strings.Split(post.Body, "\n") each line in strings.Split(post.Body, "\n")
if (line[0] == '>') if (line[0] == '>')
p.quote!= line p.quote!= line
else else
p!= line p!= line
footer footer
if (post.URL != "")
a(href=post.PostURL(r.Host, false)) #{post.PostURL(r.Host, false)}
else
span
time(datetime=util.ToClientTimezone(post.Date, r))= util.ToClientTimezone(post.Date, r).Format(time.RFC1123) time(datetime=util.ToClientTimezone(post.Date, r))= util.ToClientTimezone(post.Date, r).Format(time.RFC1123)
else else
p.center Nothing? There must be some... Looks like database went down. p.center Nothing? There must be some... Looks like database went down.