@centreon/ui-context 24.4.14 → 24.4.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/browserLocaleAtom.ts +3 -0
- package/src/defaults.ts +2 -1
- package/src/index.ts +7 -7
- package/src/isResourceStatusFullSearchEnabledAtom.ts +3 -0
- package/src/statisticsRefreshIntervalAtom.ts +7 -0
- package/src/types.ts +9 -29
- package/src/userPermissionsAtom.ts +7 -0
- package/src/additionalResources.ts +0 -5
- package/src/federatedModulesAndWidgetsAtoms.ts +0 -7
- package/src/isOnPublicPageAtom.ts +0 -3
package/package.json
CHANGED
package/src/defaults.ts
CHANGED
|
@@ -2,11 +2,12 @@ import { User, ThemeMode, ListingVariant } from './types';
|
|
|
2
2
|
|
|
3
3
|
const defaultUser: User = {
|
|
4
4
|
alias: '',
|
|
5
|
+
canManageApiTokens: false,
|
|
5
6
|
default_page: '/monitoring/resources',
|
|
6
7
|
id: undefined,
|
|
7
8
|
isAdmin: undefined,
|
|
8
9
|
isExportButtonEnabled: false,
|
|
9
|
-
locale:
|
|
10
|
+
locale: null,
|
|
10
11
|
name: '',
|
|
11
12
|
themeMode: ThemeMode.light,
|
|
12
13
|
timezone: Intl.DateTimeFormat().resolvedOptions().timeZone,
|
package/src/index.ts
CHANGED
|
@@ -2,21 +2,21 @@ export { default as userAtom } from './userAtom';
|
|
|
2
2
|
export { default as aclAtom } from './aclAtom';
|
|
3
3
|
export { default as downtimeAtom } from './downtimeAtom';
|
|
4
4
|
export { default as refreshIntervalAtom } from './refreshIntervalAtom';
|
|
5
|
+
export { default as statisticsRefreshIntervalAtom } from './statisticsRefreshIntervalAtom';
|
|
5
6
|
export { default as cloudServicesAtom } from './cloudServicesAtom';
|
|
6
7
|
export { default as acknowledgementAtom } from './acknowledgementAtom';
|
|
7
8
|
export { default as resourceStorageOptimizationModeAtom } from './resourceStorageOptimizationMode';
|
|
8
9
|
export { default as platformNameAtom } from './platformNameAtom';
|
|
10
|
+
export { default as userPermissionsAtom } from './userPermissionsAtom';
|
|
11
|
+
|
|
9
12
|
export { ThemeMode, ListingVariant, DashboardGlobalRole } from './types';
|
|
10
13
|
export {
|
|
11
14
|
platformFeaturesAtom,
|
|
12
15
|
featureFlagsDerivedAtom
|
|
13
16
|
} from './platformFeauresAtom';
|
|
14
|
-
|
|
15
|
-
export {
|
|
16
|
-
export {
|
|
17
|
-
federatedModulesAtom,
|
|
18
|
-
federatedWidgetsAtom
|
|
19
|
-
} from './federatedModulesAndWidgetsAtoms';
|
|
17
|
+
|
|
18
|
+
export { browserLocaleAtom } from './browserLocaleAtom';
|
|
19
|
+
export { isResourceStatusFullSearchEnabledAtom } from './isResourceStatusFullSearchEnabledAtom';
|
|
20
20
|
|
|
21
21
|
export type {
|
|
22
22
|
User,
|
|
@@ -30,5 +30,5 @@ export type {
|
|
|
30
30
|
DashboardRolesAndPermissions,
|
|
31
31
|
FeatureFlags,
|
|
32
32
|
PlatformFeatures,
|
|
33
|
-
|
|
33
|
+
UserPermissions
|
|
34
34
|
} from './types';
|
package/src/types.ts
CHANGED
|
@@ -20,12 +20,13 @@ export interface DashboardRolesAndPermissions {
|
|
|
20
20
|
|
|
21
21
|
export interface User {
|
|
22
22
|
alias: string;
|
|
23
|
+
canManageApiTokens: boolean;
|
|
23
24
|
dashboard?: DashboardRolesAndPermissions | null;
|
|
24
25
|
default_page?: string | null;
|
|
25
26
|
id?: number;
|
|
26
27
|
isAdmin?: boolean;
|
|
27
28
|
isExportButtonEnabled: boolean;
|
|
28
|
-
locale: string;
|
|
29
|
+
locale: string | null;
|
|
29
30
|
name: string;
|
|
30
31
|
themeMode?: ThemeMode;
|
|
31
32
|
timezone: string;
|
|
@@ -98,34 +99,13 @@ export interface PlatformFeatures {
|
|
|
98
99
|
isCloudPlatform: boolean;
|
|
99
100
|
}
|
|
100
101
|
|
|
101
|
-
export interface
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
resourceType: string;
|
|
102
|
+
export interface PlatformVersions {
|
|
103
|
+
modules: Record<string, Version>;
|
|
104
|
+
web: Version;
|
|
105
|
+
widgets: Record<string, Version | null>;
|
|
106
106
|
}
|
|
107
107
|
|
|
108
|
-
interface
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
panelMinWidth?: number;
|
|
112
|
-
path: string;
|
|
113
|
-
title?: string;
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
interface PageComponent {
|
|
117
|
-
children?: string;
|
|
118
|
-
component: string;
|
|
119
|
-
featureFlag?: string;
|
|
120
|
-
route: string;
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
export interface FederatedModule {
|
|
124
|
-
federatedComponentsConfiguration: Array<FederatedComponentsConfiguration>;
|
|
125
|
-
federatedPages: Array<PageComponent>;
|
|
126
|
-
moduleFederationName: string;
|
|
127
|
-
moduleName: string;
|
|
128
|
-
preloadScript?: string;
|
|
129
|
-
remoteEntry: string;
|
|
130
|
-
remoteUrl?: string;
|
|
108
|
+
export interface UserPermissions {
|
|
109
|
+
poller_statistics: boolean;
|
|
110
|
+
top_counter: boolean;
|
|
131
111
|
}
|