about summary refs log tree commit diff
path: root/src/view/com/post-thread/PostThreadShowHiddenReplies.tsx
diff options
context:
space:
mode:
authorHailey <me@haileyok.com>2024-05-29 20:28:32 -0700
committerGitHub <noreply@github.com>2024-05-30 04:28:32 +0100
commit9edb4879494b348616caca6999ee89658f439c49 (patch)
tree276f24d9b2cefb6fdde8ef5964c650c21037a41c /src/view/com/post-thread/PostThreadShowHiddenReplies.tsx
parent9628070e52c4f50e2f381a3f4ad1f3932743d011 (diff)
downloadvoidsky-9edb4879494b348616caca6999ee89658f439c49.tar.zst
Always show the header on post threads on native (#4254)
* always show header on native

* ALF ALF ALF

* rm offset for top border

* wrap in a `CenteredView`

* use `CenteredView`'s side borders

* account for loading state on web

* move `isTabletOrMobile`

* hide top border on first post in list

* show border if parents are loading

* don't show top border for deleted or blocked posts

* hide top border for hidden replies

* Rm root post top border

---------

Co-authored-by: Dan Abramov <dan.abramov@gmail.com>
Diffstat (limited to 'src/view/com/post-thread/PostThreadShowHiddenReplies.tsx')
-rw-r--r--src/view/com/post-thread/PostThreadShowHiddenReplies.tsx4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/view/com/post-thread/PostThreadShowHiddenReplies.tsx b/src/view/com/post-thread/PostThreadShowHiddenReplies.tsx
index 998906524..7c021d88b 100644
--- a/src/view/com/post-thread/PostThreadShowHiddenReplies.tsx
+++ b/src/view/com/post-thread/PostThreadShowHiddenReplies.tsx
@@ -11,9 +11,11 @@ import {Text} from '#/components/Typography'
 export function PostThreadShowHiddenReplies({
   type,
   onPress,
+  hideTopBorder,
 }: {
   type: 'hidden' | 'muted'
   onPress: () => void
+  hideTopBorder?: boolean
 }) {
   const {_} = useLingui()
   const t = useTheme()
@@ -31,7 +33,7 @@ export function PostThreadShowHiddenReplies({
             a.gap_sm,
             a.py_lg,
             a.px_xl,
-            a.border_t,
+            !hideTopBorder && a.border_t,
             t.atoms.border_contrast_low,
             hovered || pressed ? t.atoms.bg_contrast_25 : t.atoms.bg,
           ]}>