Wrapstodon: Load report data only on display (#37269)

This commit is contained in:
Echo authored and GitHub committed 2025-12-16 13:00:40 +00:00
1 parent 9e97ad04d8
commit a9c84529b2
8 files changed
+33 -42

No files matched your search

+6 -5
View File
@@ -1,12 +1,8 @@
import type { ApiAnnualReportState } from './api/annual_report';
import type { ApiAccountJSON } from './api_types/accounts';
type InitialStateLanguage = [code: string, name: string, localName: string];
interface InitialWrapstodonState {
year: number;
state: 'available' | 'generating' | 'eligible' | 'ineligible';
}
interface InitialStateMeta {
access_token: string;
advanced_layout?: boolean;
@@ -63,6 +59,11 @@ interface Role {
highlighted: boolean;
}
interface InitialWrapstodonState {
year: number;
state: ApiAnnualReportState;
}
export interface InitialState {
accounts: Record<string, ApiAccountJSON>;
languages: InitialStateLanguage[];