Renders the "hot" and "new" tabs of the index page, from the feed Index
loads and passes down as MainFeedProps.
Renders the "hot" and "new" tabs as a DumpCardList, sorted on the
client, followed by the infinite-scroll sentinel, or the loading, error or
empty state. Index is its only user.
Passed to DumpFeed by Index for the "hot" and "new" tabs. It adds
the active tab, as order, to the state all tabs share.
Passed by Index to whichever of the "hot", "new" and "journal" tabs is
showing. The tabs share this one state, so switching tabs doesn't refetch.
-
dumps: Dump[]
It holds the loaded dumps, with those
WSContextadded since and without the deleted ones. -
sentinelRef: Ref<HTMLDivElement>
It comes from
useInfiniteScroll, and goes after the last card. -
state: DumpFeedState
The tabs read its status and paging, and show
dumpsinstead of its items.
Held by usePagedList for Index's feed and for each section of
FollowedFeed.
Usage
import * as mod from "src/components/feed/DumpFeed.tsx";