fix(archive): animate loading ellipsis

This commit is contained in:
Tommaso Casaburi
2026-04-29 16:41:56 +07:00
parent b951e8317b
commit 042f2df223
4 changed files with 24 additions and 2 deletions
@@ -205,6 +205,14 @@ describe('Archive', () => {
expect(testState.loadMoreMock).toHaveBeenCalledTimes(1);
});
it('uses the shared loading ellipsis for the empty archive loading state', async () => {
testState.hasMore = true;
await renderArchiveRoute({ root, element: createElement(Archive), initialEntry: '/mu/archive', routePath: '/:boardIdentifier/archive' });
expect(container.querySelector('[data-testid="loading-ellipsis"]')?.textContent).toBe('loading_archive');
});
it('renders the shared archive table and mobile nav actions when mobile hook is set', async () => {
testState.isMobile = true;
testState.feed = [
+3 -1
View File
@@ -216,7 +216,9 @@ const Archive = () => {
<hr className={styles.desktopDivider} />
<ArchiveDesktopTopControls communityAddress={communityAddress} />
<hr className={styles.divider} />
<h4 className={styles.archiveSummary}>{t('loading_archive')}</h4>
<h4 className={styles.archiveSummary}>
<LoadingEllipsis string={t('loading_archive')} />
</h4>
<PageFooterDesktop firstRow={<ArchiveDesktopFooterControls communityAddress={communityAddress} />} styleRow={<ThreadFooterStyleRow />} />
<PageFooterMobile>
<ArchiveMobileFooterControls communityAddress={communityAddress} />