commit 5914279

default  ·  2024-10-28 09:20:27 +0000 UTC
parent a0fc1b3
Some work towards collapsing threads by default.
1 files changed,  +2, -1
M html.c
M html.c
+2, -1
 1@@ -1453,6 +1453,7 @@ xs_html *html_entry(snac *user, xs_dict *msg, int read_only,
 2     const char *actor;
 3     const char *v;
 4     int has_title = 0;
 5+    int collapse_threads = 0;
 6 
 7     /* do not show non-public messages in the public timeline */
 8     if ((read_only || !user) && !is_msg_public(msg))
 9@@ -2053,7 +2054,7 @@ xs_html *html_entry(snac *user, xs_dict *msg, int read_only,
10 
11         if (left) {
12             xs_html *ch_details = xs_html_tag("details",
13-                xs_html_attr("open", NULL),
14+                xs_html_attr(collapse_threads ? "" : "open", NULL),
15                 xs_html_tag("summary",
16                     xs_html_text("...")));
17