forked from SigNoz/signoz
-
Notifications
You must be signed in to change notification settings - Fork 0
/
app.ts
38 lines (36 loc) · 1.18 KB
/
app.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
import { QueryObserverBaseResult } from 'react-query';
import { PayloadProps as ConfigPayload } from 'types/api/dynamicConfigs/getDynamicConfigs';
import { FeatureFlagProps as FeatureFlagPayload } from 'types/api/features/getFeaturesFlags';
import { PayloadProps as OrgPayload } from 'types/api/user/getOrganization';
import { PayloadProps as UserPayload } from 'types/api/user/getUser';
import { UserFlags } from 'types/api/user/setFlags';
import { ROLES } from 'types/roles';
export interface User {
accessJwt: string;
refreshJwt: string;
userId: string;
email: UserPayload['email'];
name: UserPayload['name'];
profilePictureURL: UserPayload['profilePictureURL'];
}
export default interface AppReducer {
isLoggedIn: boolean;
isSideBarCollapsed: boolean;
currentVersion: string;
latestVersion: string;
isCurrentVersionError: boolean;
isLatestVersionError: boolean;
user: null | User;
isUserFetching: boolean;
isUserFetchingError: boolean;
role: ROLES | null;
org: OrgPayload | null;
configs: ConfigPayload;
userFlags: null | UserFlags;
ee: 'Y' | 'N';
setupCompleted: boolean;
featureResponse: {
data: FeatureFlagPayload[] | null;
refetch: QueryObserverBaseResult['refetch'];
};
}