diff --git a/web/static/index.css b/web/static/index.css index be70867..4570100 100644 --- a/web/static/index.css +++ b/web/static/index.css @@ -201,6 +201,26 @@ body { margin: 2rem; } +.thread-title { + position: relative; + display: inline-block; + font-size: 14px; + font-weight: bold; +} + +.thread-icons { + position: absolute; + right: 100%; + margin-right: 6px; + top: 50%; + transform: translateY(-50%); + display: flex; +} + +.thread-icons .icon { + margin-left: 2px; +} + .thread-subject { font-weight: bold; color: var(--link-primary); @@ -409,6 +429,16 @@ body { color: var(--danger); } +.icon { + width: 12px; + height: 12px; + vertical-align: middle; +} + +.icon:not(:last-child) { + margin-right: 2px; +} + hr { border: none; border-top: 1px solid var(--border-light); diff --git a/web/static/media/icons/lock.svg b/web/static/media/icons/lock.svg new file mode 100644 index 0000000..4dcbe6a --- /dev/null +++ b/web/static/media/icons/lock.svg @@ -0,0 +1,2 @@ + + \ No newline at end of file diff --git a/web/static/media/icons/pin.svg b/web/static/media/icons/pin.svg new file mode 100644 index 0000000..c17635f --- /dev/null +++ b/web/static/media/icons/pin.svg @@ -0,0 +1,7 @@ + + + + + + + \ No newline at end of file diff --git a/web/views/board.templ b/web/views/board.templ index 7b46e54..c983552 100644 --- a/web/views/board.templ +++ b/web/views/board.templ @@ -95,14 +95,18 @@ templ ThreadsCatalog(previews []CatalogThreadPreview, catalogContext CatalogCont } -

- { preview.Subject } - if preview.Locked { - Locked - } - if preview.Pinned { - Pinned - } +

+ + if preview.Locked { + Locked + } + if preview.Pinned { + Pinned + } + + + { preview.Subject } +

@templ.Raw(util.EnrichPost(preview.Body)) diff --git a/web/views/thread.templ b/web/views/thread.templ index 4927a60..831629d 100644 --- a/web/views/thread.templ +++ b/web/views/thread.templ @@ -93,6 +93,14 @@ templ PostOriginal(post database.Post, thread database.Thread) { />

+ + if thread.Locked { + Locked + } + if thread.Pinned { + Pinned + } +

{ thread.Subject } -

{ post.Author } { post.CreatedAt.Format("01/02/2006") }