fix(board): hide feed footer on flash table

This commit is contained in:
Tommaso Casaburi
2026-05-30 16:44:55 +07:00
parent 05ecfb47a1
commit 08ebdce29c
2 changed files with 23 additions and 18 deletions
+3
View File
@@ -629,6 +629,8 @@ describe('Board', () => {
expect(table).toBeTruthy();
expect(container.querySelector('[data-testid="post"]')).toBeNull();
expect(table?.textContent).toContain('no posts');
expect(container.textContent).not.toContain('no_threads');
expect(container.querySelector('[data-testid="board-pagination"]')).toBeTruthy();
});
it('keeps the flash table in loading state until the empty board feed finishes syncing', async () => {
@@ -660,6 +662,7 @@ describe('Board', () => {
expect(table).toBeTruthy();
expect(table?.textContent).not.toContain('no posts');
expect(table?.querySelector('[data-testid="loading-ellipsis"]')?.textContent).toBe('downloading_board');
expect(container.querySelectorAll('[data-testid="loading-ellipsis"]').length).toBe(1);
});
it('inserts a nonoko pending account comment after pinned posts on the redirected board index', async () => {
+20 -18
View File
@@ -459,24 +459,26 @@ const Board = ({ feedCacheKey, viewType, boardIdentifier: boardIdentifierProp, t
() => ({
Footer: () => (
<>
<BoardFooter
communityAddresses={communityAddresses}
hasMore={hasMore}
feedState={feedState}
combinedFeedLength={combinedFeed.length}
isSingleCommunityBoard={!isInAllView && !isInSubscriptionsView && !isInModView}
isInSubscriptionsView={isInSubscriptionsView}
isInModView={isInModView}
currentTimeFilterName={currentTimeFilterName}
moreThreadsSuggestion={moreThreadsSuggestion}
moreThreadsSuggestionPathname={moreThreadsSuggestionPathname}
moreThreadsSuggestionSearch={routerLocation.search}
onExpandTimeWindow={expandSuggestionTimeWindow}
communityState={communityState}
subscriptionsLength={subscriptions?.length || 0}
accountCommunityAddressesLength={accountCommunityAddresses?.length || 0}
showLoadingEllipsis={effectiveInfiniteScroll || combinedFeed.length === 0}
/>
{shouldUseFlashTable ? null : (
<BoardFooter
communityAddresses={communityAddresses}
hasMore={hasMore}
feedState={feedState}
combinedFeedLength={combinedFeed.length}
isSingleCommunityBoard={!isInAllView && !isInSubscriptionsView && !isInModView}
isInSubscriptionsView={isInSubscriptionsView}
isInModView={isInModView}
currentTimeFilterName={currentTimeFilterName}
moreThreadsSuggestion={moreThreadsSuggestion}
moreThreadsSuggestionPathname={moreThreadsSuggestionPathname}
moreThreadsSuggestionSearch={routerLocation.search}
onExpandTimeWindow={expandSuggestionTimeWindow}
communityState={communityState}
subscriptionsLength={subscriptions?.length || 0}
accountCommunityAddressesLength={accountCommunityAddresses?.length || 0}
showLoadingEllipsis={effectiveInfiniteScroll || combinedFeed.length === 0}
/>
)}
<PageFooterDesktop
firstRow={
<BoardPagination