From 0691317d19d08dd029cf4c9d80049e8b2b324548 Mon Sep 17 00:00:00 2001 From: Thomas Mathews Date: Tue, 24 Jan 2023 14:51:06 -0800 Subject: [PATCH] Fix hide replys button on nav change --- index.html | 2 +- js/ui/state.js | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/index.html b/index.html index c7e420d..8b1a736 100644 --- a/index.html +++ b/index.html @@ -187,7 +187,7 @@
-
+
diff --git a/js/ui/state.js b/js/ui/state.js index d5d15b8..b180eaf 100644 --- a/js/ui/state.js +++ b/js/ui/state.js @@ -36,6 +36,10 @@ function view_timeline_apply_mode(model, mode, opts={}, push_state=true) { const el = view_get_timeline_el(); const now = new Date().getTime(); + if (opts.hide_replys == undefined) { + opts.hide_replys = el.dataset.hideReplys == "true"; + } + // Don't do anything if we are already here if (el.dataset.mode == mode) { switch (mode) { @@ -96,7 +100,6 @@ function view_timeline_apply_mode(model, mode, opts={}, push_state=true) { el.dataset.mode = mode; delete el.dataset.threadId; delete el.dataset.pubkey; - delete el.dataset.hideReplys; switch(mode) { case VM_FRIENDS: el.dataset.hideReplys = opts.hide_replys;