From 681dfaaaff6a30474053dccb9ac01143230972cb Mon Sep 17 00:00:00 2001 From: Lim Chee Aun Date: Mon, 19 Dec 2022 10:05:27 +0800 Subject: [PATCH] Auto-open details and hide summary button Only show toggle comments button if there are many statuses --- src/pages/status.jsx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/pages/status.jsx b/src/pages/status.jsx index 4fecbab3..1f7c6431 100644 --- a/src/pages/status.jsx +++ b/src/pages/status.jsx @@ -175,6 +175,8 @@ function StatusPage({ id }) { return statuses.length - limit; }, [statuses.length, limit]); + const hasManyStatuses = statuses.length > 40; + return (
@@ -229,8 +231,8 @@ function StatusPage({ id }) { )} {descendant && replies?.length > 0 && ( -
- +
+