aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/msglist.go
diff options
context:
space:
mode:
authorKoni Marti <koni.marti@gmail.com>2023-07-14 20:37:33 +0200
committerRobin Jarry <robin@jarry.cc>2023-07-16 10:13:19 +0200
commit995dfc15a8065fdc01e0ace8cef7174e0749722e (patch)
treed0c1843a0d6695df4dd8c9ea5d76164f637fd072 /widgets/msglist.go
parentb267de83e38c09d34215e7a33991ae5c111fe649 (diff)
downloadaerc-995dfc15a8065fdc01e0ace8cef7174e0749722e.tar.gz
styles: add style for folded threads
Add a style for folded threads. Use msglist_thread_folded in the stylesheet like "msglist_thread_folded.dim = true" Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc> Tested-by: inwit <inwit@sindominio.net>
Diffstat (limited to 'widgets/msglist.go')
-rw-r--r--widgets/msglist.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/widgets/msglist.go b/widgets/msglist.go
index 9ce60756..8263b945 100644
--- a/widgets/msglist.go
+++ b/widgets/msglist.go
@@ -205,6 +205,11 @@ func addMessage(
if store.IsResult(msg.Uid) {
params.styles = append(params.styles, config.STYLE_MSGLIST_RESULT)
}
+ // folded thread
+ templateData, ok := data.(models.TemplateData)
+ if ok && templateData.ThreadFolded() {
+ params.styles = append(params.styles, config.STYLE_MSGLIST_THREAD_FOLDED)
+ }
// marked message
marked := store.Marker().IsMarked(msg.Uid)
if marked {