Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(clients): move settled pinned threads into the settled section #7969

Mergedt3dotgg(GitHub profile, opens in a new tab)merged 4 commits intomain fromrefs/pull/7969/headmerged by t3dotgg(GitHub profile, opens in a new tab) View on GitHub

Showing 6 changed files with 88 additions and 17 deletions (loading 3).

x
0 of 6 viewed, 6 left
9 additions and 3 deletionsapps/mobile/src/features/threads/thread-list-v2-items.tsxModified
View file
@@ -506,7 +506,7 @@
} satisfies MenuAction,
: []),
- pinnedRow
+ thread.pinnedAt != null
? { id: "unpin", title: "Unpin", image: "pin.slash" }
: { id: "pin", title: "Pin", image: "pin" },
@@ -517,6 +517,7 @@
props.canMovePinnedUp,
props.pinReorderSupported,
props.pinningSupported,
+ thread.pinnedAt,
const titleRegenerationMenuItems = useMemo<MenuAction[]>(
@@ -552,8 +553,13 @@
[pinMenuItem, titleRegenerationMenuItems],
const slimMenuActions = useMemo<MenuAction[]>(
- () => [SLIM_MENU_ACTIONS[0]!, ...titleRegenerationMenuItems, SLIM_MENU_ACTIONS[1]!],
- [titleRegenerationMenuItems],
+ () => [
+ SLIM_MENU_ACTIONS[0]!,
+ ...(thread.pinnedAt != null ? pinMenuItem : []),
+ ...titleRegenerationMenuItems,
+ SLIM_MENU_ACTIONS[1]!,