Skip to content
Source
Sign inSign up
pingdotgg/t3code

feat(mobile): beta Working section hides busy threads until they need you #15346

Mergedt3dotgg(GitHub profile, opens in a new tab)merged 1 commit intomain fromrefs/pull/15346/headmerged by t3dotgg(GitHub profile, opens in a new tab) View on GitHub

Showing 16 changed files with 80 additions and 7 deletions (loading 13).

x
0 of 16 viewed, 16 left
37 additions and 2 deletionsapps/mobile/src/features/home/HomeScreen.tsxModified
View file
@@ -44,6 +44,7 @@
ThreadListV2SettledShelfHeader,
ThreadListV2ShowMoreRow,
ThreadListV2SnoozedShelfHeader,
+ ThreadListV2WorkingShelfHeader,
} from "../threads/thread-list-v2-items";
import { useThreadRowProviderInstanceResolver } from "../threads/thread-provider-instance";
import {
@@ -51,6 +52,7 @@
getThreadListV2OrderedSection,
buildThreadListV2ListItems,
threadListV2ListItemsAreEqual,
+ threadListInboxReturns,
THREAD_LIST_V2_SETTLED_INITIAL_COUNT,
THREAD_LIST_V2_SETTLED_PAGE_COUNT,
type ThreadListV2ListItem,
@@ -466,8 +468,11 @@
loaded: shelfPreferencesLoaded,
settledShelfExpanded,
snoozedShelfExpanded,
+ workingShelfEnabled,
+ workingShelfExpanded,
toggleSettledShelf,
toggleSnoozedShelf,
+ toggleWorkingShelf,
} = useThreadListV2ShelfPreferences();
// The queued-start and snooze helpers need a clock while the list stays open.
const [nowMinute, setNowMinute] = useState(() => new Date().toISOString().slice(0, 16));