-
Notifications
You must be signed in to change notification settings - Fork 0
/
dashboardData.js
114 lines (114 loc) · 2.89 KB
/
dashboardData.js
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
export const initialDashboardData = {
categories: [
{
id: 'cspm-executive-dashboard',
name: 'CSPM Executive Dashboard',
widgets: [
{
id: 'cloud-accounts',
name: 'Cloud Accounts',
type: 'doughnut',
total: 2,
data: {
labels: [`Connected`, 'Not Connected'],
datasets: [{
data: [2, 2],
backgroundColor: ['#4299e1', '#e2e8f0'],
borderWidth: 0,
spacing: 1,
hoverOffset: 5
}],
},
options: {
cutout: '65%',
plugins: {
legend: {
display: false,
},
},
},
},
{
id: 'cloud-account-risk',
name: 'Cloud Account Risk Assessment',
type: 'doughnut',
total: 9659,
data: {
labels: ['Failed', 'Warning', 'Not available', 'Passed'],
datasets: [{
data: [1689, 681, 36, 7253],
backgroundColor: ['#b11111', '#fdd94b', '#aaa', '#48bb78'],
borderWidth: 0,
spacing: 1,
hoverOffset: 5
}],
},
options: {
padding: '',
cutout: '65%',
plugins: {
legend: {
display: false,
},
},
},
},
]
},
{
id: 'cwpp-dashboard',
name: 'CWPP Dashboard',
widgets: [
{
id: 'namespace-alerts',
name: 'Top 5 Namespace Specific Alerts',
type: 'unknown',
data: {},
options: {}
},
{
id: 'workload-alerts',
name: 'Workload Alerts',
type: 'unknown',
data: {},
options: {}
},
]
},
{
id: 'registry-scan',
name: 'Registry Scan',
widgets: [
{
id: 'image-risk',
name: 'Image Risk Assessment',
type: 'horizontalBar',
title: 'Total Vulnerabilities', // 1470
data: {
total: 1470,
labels: ['Critical', 'High', 'Medium', 'Low'],
datasets: [{
data: [9, 150, 490, 695],
backgroundColor: ['#a11111', '#e21212', '#ed8936', '#fdd94b'],
}],
},
},
{
id: 'image-security',
name: 'Image Security Issues',
type: 'horizontalBar',
title: 'Total Images', // 2
data: {
total: 8,
labels: ['Critical', 'High', 'Medium', 'Low'],
datasets: [{
data: [2, 2, 2, 1],
backgroundColor: ['#a11111', '#e21212', '#ed8936', '#fdd94b'],
}],
},
},
]
},
// TODO - other dummy data will be added as text dynamically by the user input
]
};