@lssm/example.analytics-dashboard 0.0.0-canary-20251216033905 → 0.0.0-canary-20251216062412
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/dist/dashboard/dashboard.contracts.js +119 -1
- package/dist/dashboard/dashboard.enum.js +42 -1
- package/dist/dashboard/dashboard.presentation.js +76 -0
- package/dist/dashboard/dashboard.schema.js +235 -1
- package/dist/dashboard/index.js +5 -1
- package/dist/dashboard.feature.js +164 -1
- package/dist/docs/analytics-dashboard.docblock.js +60 -5
- package/dist/docs/index.js +1 -1
- package/dist/events.js +112 -0
- package/dist/example.js +50 -1
- package/dist/index.js +8 -1
- package/dist/query/index.js +5 -1
- package/dist/query/query.contracts.js +65 -1
- package/dist/query/query.enum.js +15 -1
- package/dist/query/query.presentation.js +50 -0
- package/dist/query/query.schema.js +156 -1
- package/dist/query-engine/index.js +185 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +7 -1
|
@@ -1 +1,119 @@
|
|
|
1
|
-
import{AddWidgetInputModel
|
|
1
|
+
import { AddWidgetInputModel, CreateDashboardInputModel, DashboardModel, GetDashboardInputModel, ListDashboardsInputModel, ListDashboardsOutputModel, WidgetModel } from "./dashboard.schema.js";
|
|
2
|
+
import { defineCommand, defineQuery } from "@lssm/lib.contracts/spec";
|
|
3
|
+
|
|
4
|
+
//#region src/dashboard/dashboard.contracts.ts
|
|
5
|
+
const OWNERS = ["@example.analytics-dashboard"];
|
|
6
|
+
/**
|
|
7
|
+
* Create a new analytics dashboard.
|
|
8
|
+
*/
|
|
9
|
+
const CreateDashboardContract = defineCommand({
|
|
10
|
+
meta: {
|
|
11
|
+
name: "analytics.dashboard.create",
|
|
12
|
+
version: 1,
|
|
13
|
+
stability: "stable",
|
|
14
|
+
owners: [...OWNERS],
|
|
15
|
+
tags: [
|
|
16
|
+
"analytics",
|
|
17
|
+
"dashboard",
|
|
18
|
+
"create"
|
|
19
|
+
],
|
|
20
|
+
description: "Create a new analytics dashboard.",
|
|
21
|
+
goal: "Allow users to create custom dashboards.",
|
|
22
|
+
context: "Dashboard management."
|
|
23
|
+
},
|
|
24
|
+
io: {
|
|
25
|
+
input: CreateDashboardInputModel,
|
|
26
|
+
output: DashboardModel
|
|
27
|
+
},
|
|
28
|
+
policy: { auth: "user" },
|
|
29
|
+
sideEffects: {
|
|
30
|
+
emits: [{
|
|
31
|
+
name: "analytics.dashboard.created",
|
|
32
|
+
version: 1,
|
|
33
|
+
when: "Dashboard created",
|
|
34
|
+
payload: DashboardModel
|
|
35
|
+
}],
|
|
36
|
+
audit: ["analytics.dashboard.created"]
|
|
37
|
+
}
|
|
38
|
+
});
|
|
39
|
+
/**
|
|
40
|
+
* Add a widget to a dashboard.
|
|
41
|
+
*/
|
|
42
|
+
const AddWidgetContract = defineCommand({
|
|
43
|
+
meta: {
|
|
44
|
+
name: "analytics.widget.add",
|
|
45
|
+
version: 1,
|
|
46
|
+
stability: "stable",
|
|
47
|
+
owners: [...OWNERS],
|
|
48
|
+
tags: [
|
|
49
|
+
"analytics",
|
|
50
|
+
"widget",
|
|
51
|
+
"add"
|
|
52
|
+
],
|
|
53
|
+
description: "Add a widget to a dashboard.",
|
|
54
|
+
goal: "Allow users to add visualizations.",
|
|
55
|
+
context: "Dashboard editor."
|
|
56
|
+
},
|
|
57
|
+
io: {
|
|
58
|
+
input: AddWidgetInputModel,
|
|
59
|
+
output: WidgetModel
|
|
60
|
+
},
|
|
61
|
+
policy: { auth: "user" },
|
|
62
|
+
sideEffects: { emits: [{
|
|
63
|
+
name: "analytics.widget.added",
|
|
64
|
+
version: 1,
|
|
65
|
+
when: "Widget added",
|
|
66
|
+
payload: WidgetModel
|
|
67
|
+
}] }
|
|
68
|
+
});
|
|
69
|
+
/**
|
|
70
|
+
* List dashboards.
|
|
71
|
+
*/
|
|
72
|
+
const ListDashboardsContract = defineQuery({
|
|
73
|
+
meta: {
|
|
74
|
+
name: "analytics.dashboard.list",
|
|
75
|
+
version: 1,
|
|
76
|
+
stability: "stable",
|
|
77
|
+
owners: [...OWNERS],
|
|
78
|
+
tags: [
|
|
79
|
+
"analytics",
|
|
80
|
+
"dashboard",
|
|
81
|
+
"list"
|
|
82
|
+
],
|
|
83
|
+
description: "List dashboards.",
|
|
84
|
+
goal: "Browse available dashboards.",
|
|
85
|
+
context: "Dashboard listing."
|
|
86
|
+
},
|
|
87
|
+
io: {
|
|
88
|
+
input: ListDashboardsInputModel,
|
|
89
|
+
output: ListDashboardsOutputModel
|
|
90
|
+
},
|
|
91
|
+
policy: { auth: "user" }
|
|
92
|
+
});
|
|
93
|
+
/**
|
|
94
|
+
* Get a dashboard with widgets.
|
|
95
|
+
*/
|
|
96
|
+
const GetDashboardContract = defineQuery({
|
|
97
|
+
meta: {
|
|
98
|
+
name: "analytics.dashboard.get",
|
|
99
|
+
version: 1,
|
|
100
|
+
stability: "stable",
|
|
101
|
+
owners: [...OWNERS],
|
|
102
|
+
tags: [
|
|
103
|
+
"analytics",
|
|
104
|
+
"dashboard",
|
|
105
|
+
"get"
|
|
106
|
+
],
|
|
107
|
+
description: "Get a dashboard with widgets.",
|
|
108
|
+
goal: "Load dashboard for viewing.",
|
|
109
|
+
context: "Dashboard view."
|
|
110
|
+
},
|
|
111
|
+
io: {
|
|
112
|
+
input: GetDashboardInputModel,
|
|
113
|
+
output: DashboardModel
|
|
114
|
+
},
|
|
115
|
+
policy: { auth: "anonymous" }
|
|
116
|
+
});
|
|
117
|
+
|
|
118
|
+
//#endregion
|
|
119
|
+
export { AddWidgetContract, CreateDashboardContract, GetDashboardContract, ListDashboardsContract };
|
|
@@ -1 +1,42 @@
|
|
|
1
|
-
import{defineEnum
|
|
1
|
+
import { defineEnum } from "@lssm/lib.schema";
|
|
2
|
+
|
|
3
|
+
//#region src/dashboard/dashboard.enum.ts
|
|
4
|
+
/**
|
|
5
|
+
* Dashboard status enum.
|
|
6
|
+
*/
|
|
7
|
+
const DashboardStatusEnum = defineEnum("DashboardStatus", [
|
|
8
|
+
"DRAFT",
|
|
9
|
+
"PUBLISHED",
|
|
10
|
+
"ARCHIVED"
|
|
11
|
+
]);
|
|
12
|
+
/**
|
|
13
|
+
* Widget type enum.
|
|
14
|
+
*/
|
|
15
|
+
const WidgetTypeEnum = defineEnum("WidgetType", [
|
|
16
|
+
"LINE_CHART",
|
|
17
|
+
"BAR_CHART",
|
|
18
|
+
"PIE_CHART",
|
|
19
|
+
"AREA_CHART",
|
|
20
|
+
"SCATTER_PLOT",
|
|
21
|
+
"METRIC",
|
|
22
|
+
"TABLE",
|
|
23
|
+
"HEATMAP",
|
|
24
|
+
"FUNNEL",
|
|
25
|
+
"MAP",
|
|
26
|
+
"TEXT",
|
|
27
|
+
"EMBED"
|
|
28
|
+
]);
|
|
29
|
+
/**
|
|
30
|
+
* Refresh interval enum.
|
|
31
|
+
*/
|
|
32
|
+
const RefreshIntervalEnum = defineEnum("RefreshInterval", [
|
|
33
|
+
"NONE",
|
|
34
|
+
"MINUTE",
|
|
35
|
+
"FIVE_MINUTES",
|
|
36
|
+
"FIFTEEN_MINUTES",
|
|
37
|
+
"HOUR",
|
|
38
|
+
"DAY"
|
|
39
|
+
]);
|
|
40
|
+
|
|
41
|
+
//#endregion
|
|
42
|
+
export { DashboardStatusEnum, RefreshIntervalEnum, WidgetTypeEnum };
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import { DashboardModel } from "./dashboard.schema.js";
|
|
2
|
+
|
|
3
|
+
//#region src/dashboard/dashboard.presentation.ts
|
|
4
|
+
const DashboardsListPresentation = {
|
|
5
|
+
meta: {
|
|
6
|
+
name: "analytics.dashboard.list",
|
|
7
|
+
version: 1,
|
|
8
|
+
description: "List of analytics dashboards",
|
|
9
|
+
domain: "analytics",
|
|
10
|
+
owners: ["@analytics-dashboard"],
|
|
11
|
+
tags: [
|
|
12
|
+
"analytics",
|
|
13
|
+
"dashboards",
|
|
14
|
+
"list"
|
|
15
|
+
]
|
|
16
|
+
},
|
|
17
|
+
source: {
|
|
18
|
+
type: "component",
|
|
19
|
+
framework: "react",
|
|
20
|
+
componentKey: "DashboardsList",
|
|
21
|
+
props: DashboardModel
|
|
22
|
+
},
|
|
23
|
+
targets: [
|
|
24
|
+
"react",
|
|
25
|
+
"markdown",
|
|
26
|
+
"application/json"
|
|
27
|
+
],
|
|
28
|
+
policy: { flags: ["analytics.dashboards.enabled"] }
|
|
29
|
+
};
|
|
30
|
+
const DashboardViewPresentation = {
|
|
31
|
+
meta: {
|
|
32
|
+
name: "analytics.dashboard.view",
|
|
33
|
+
version: 1,
|
|
34
|
+
description: "View a single dashboard with widgets",
|
|
35
|
+
domain: "analytics",
|
|
36
|
+
owners: ["@analytics-dashboard"],
|
|
37
|
+
tags: [
|
|
38
|
+
"analytics",
|
|
39
|
+
"dashboard",
|
|
40
|
+
"view"
|
|
41
|
+
]
|
|
42
|
+
},
|
|
43
|
+
source: {
|
|
44
|
+
type: "component",
|
|
45
|
+
framework: "react",
|
|
46
|
+
componentKey: "DashboardView",
|
|
47
|
+
props: DashboardModel
|
|
48
|
+
},
|
|
49
|
+
targets: ["react", "markdown"],
|
|
50
|
+
policy: { flags: ["analytics.dashboards.enabled"] }
|
|
51
|
+
};
|
|
52
|
+
const DashboardEditorPresentation = {
|
|
53
|
+
meta: {
|
|
54
|
+
name: "analytics.dashboard.editor",
|
|
55
|
+
version: 1,
|
|
56
|
+
description: "Edit dashboard configuration and widgets",
|
|
57
|
+
domain: "analytics",
|
|
58
|
+
owners: ["@analytics-dashboard"],
|
|
59
|
+
tags: [
|
|
60
|
+
"analytics",
|
|
61
|
+
"dashboard",
|
|
62
|
+
"editor"
|
|
63
|
+
]
|
|
64
|
+
},
|
|
65
|
+
source: {
|
|
66
|
+
type: "component",
|
|
67
|
+
framework: "react",
|
|
68
|
+
componentKey: "DashboardEditor",
|
|
69
|
+
props: DashboardModel
|
|
70
|
+
},
|
|
71
|
+
targets: ["react"],
|
|
72
|
+
policy: { flags: ["analytics.dashboards.enabled"] }
|
|
73
|
+
};
|
|
74
|
+
|
|
75
|
+
//#endregion
|
|
76
|
+
export { DashboardEditorPresentation, DashboardViewPresentation, DashboardsListPresentation };
|
|
@@ -1 +1,235 @@
|
|
|
1
|
-
import{DashboardStatusEnum
|
|
1
|
+
import { DashboardStatusEnum, RefreshIntervalEnum, WidgetTypeEnum } from "./dashboard.enum.js";
|
|
2
|
+
import { ScalarTypeEnum, defineSchemaModel } from "@lssm/lib.schema";
|
|
3
|
+
|
|
4
|
+
//#region src/dashboard/dashboard.schema.ts
|
|
5
|
+
/**
|
|
6
|
+
* A dashboard widget.
|
|
7
|
+
*/
|
|
8
|
+
const WidgetModel = defineSchemaModel({
|
|
9
|
+
name: "WidgetModel",
|
|
10
|
+
fields: {
|
|
11
|
+
id: {
|
|
12
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
13
|
+
isOptional: false
|
|
14
|
+
},
|
|
15
|
+
dashboardId: {
|
|
16
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
17
|
+
isOptional: false
|
|
18
|
+
},
|
|
19
|
+
name: {
|
|
20
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
21
|
+
isOptional: false
|
|
22
|
+
},
|
|
23
|
+
type: {
|
|
24
|
+
type: WidgetTypeEnum,
|
|
25
|
+
isOptional: false
|
|
26
|
+
},
|
|
27
|
+
gridX: {
|
|
28
|
+
type: ScalarTypeEnum.Int_unsecure(),
|
|
29
|
+
isOptional: false
|
|
30
|
+
},
|
|
31
|
+
gridY: {
|
|
32
|
+
type: ScalarTypeEnum.Int_unsecure(),
|
|
33
|
+
isOptional: false
|
|
34
|
+
},
|
|
35
|
+
gridWidth: {
|
|
36
|
+
type: ScalarTypeEnum.Int_unsecure(),
|
|
37
|
+
isOptional: false
|
|
38
|
+
},
|
|
39
|
+
gridHeight: {
|
|
40
|
+
type: ScalarTypeEnum.Int_unsecure(),
|
|
41
|
+
isOptional: false
|
|
42
|
+
},
|
|
43
|
+
queryId: {
|
|
44
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
45
|
+
isOptional: true
|
|
46
|
+
},
|
|
47
|
+
config: {
|
|
48
|
+
type: ScalarTypeEnum.JSON(),
|
|
49
|
+
isOptional: true
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
});
|
|
53
|
+
/**
|
|
54
|
+
* An analytics dashboard.
|
|
55
|
+
*/
|
|
56
|
+
const DashboardModel = defineSchemaModel({
|
|
57
|
+
name: "DashboardModel",
|
|
58
|
+
fields: {
|
|
59
|
+
id: {
|
|
60
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
61
|
+
isOptional: false
|
|
62
|
+
},
|
|
63
|
+
name: {
|
|
64
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
65
|
+
isOptional: false
|
|
66
|
+
},
|
|
67
|
+
slug: {
|
|
68
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
69
|
+
isOptional: false
|
|
70
|
+
},
|
|
71
|
+
description: {
|
|
72
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
73
|
+
isOptional: true
|
|
74
|
+
},
|
|
75
|
+
status: {
|
|
76
|
+
type: DashboardStatusEnum,
|
|
77
|
+
isOptional: false
|
|
78
|
+
},
|
|
79
|
+
refreshInterval: {
|
|
80
|
+
type: RefreshIntervalEnum,
|
|
81
|
+
isOptional: false
|
|
82
|
+
},
|
|
83
|
+
isPublic: {
|
|
84
|
+
type: ScalarTypeEnum.Boolean(),
|
|
85
|
+
isOptional: false
|
|
86
|
+
},
|
|
87
|
+
widgets: {
|
|
88
|
+
type: WidgetModel,
|
|
89
|
+
isArray: true,
|
|
90
|
+
isOptional: true
|
|
91
|
+
},
|
|
92
|
+
createdAt: {
|
|
93
|
+
type: ScalarTypeEnum.DateTime(),
|
|
94
|
+
isOptional: false
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
});
|
|
98
|
+
/**
|
|
99
|
+
* Input for creating a dashboard.
|
|
100
|
+
*/
|
|
101
|
+
const CreateDashboardInputModel = defineSchemaModel({
|
|
102
|
+
name: "CreateDashboardInput",
|
|
103
|
+
fields: {
|
|
104
|
+
name: {
|
|
105
|
+
type: ScalarTypeEnum.NonEmptyString(),
|
|
106
|
+
isOptional: false
|
|
107
|
+
},
|
|
108
|
+
slug: {
|
|
109
|
+
type: ScalarTypeEnum.NonEmptyString(),
|
|
110
|
+
isOptional: false
|
|
111
|
+
},
|
|
112
|
+
description: {
|
|
113
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
114
|
+
isOptional: true
|
|
115
|
+
},
|
|
116
|
+
refreshInterval: {
|
|
117
|
+
type: RefreshIntervalEnum,
|
|
118
|
+
isOptional: true
|
|
119
|
+
},
|
|
120
|
+
dateRange: {
|
|
121
|
+
type: ScalarTypeEnum.JSON(),
|
|
122
|
+
isOptional: true
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
});
|
|
126
|
+
/**
|
|
127
|
+
* Input for adding a widget.
|
|
128
|
+
*/
|
|
129
|
+
const AddWidgetInputModel = defineSchemaModel({
|
|
130
|
+
name: "AddWidgetInput",
|
|
131
|
+
fields: {
|
|
132
|
+
dashboardId: {
|
|
133
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
134
|
+
isOptional: false
|
|
135
|
+
},
|
|
136
|
+
name: {
|
|
137
|
+
type: ScalarTypeEnum.NonEmptyString(),
|
|
138
|
+
isOptional: false
|
|
139
|
+
},
|
|
140
|
+
type: {
|
|
141
|
+
type: WidgetTypeEnum,
|
|
142
|
+
isOptional: false
|
|
143
|
+
},
|
|
144
|
+
gridX: {
|
|
145
|
+
type: ScalarTypeEnum.Int_unsecure(),
|
|
146
|
+
isOptional: true
|
|
147
|
+
},
|
|
148
|
+
gridY: {
|
|
149
|
+
type: ScalarTypeEnum.Int_unsecure(),
|
|
150
|
+
isOptional: true
|
|
151
|
+
},
|
|
152
|
+
gridWidth: {
|
|
153
|
+
type: ScalarTypeEnum.Int_unsecure(),
|
|
154
|
+
isOptional: true
|
|
155
|
+
},
|
|
156
|
+
gridHeight: {
|
|
157
|
+
type: ScalarTypeEnum.Int_unsecure(),
|
|
158
|
+
isOptional: true
|
|
159
|
+
},
|
|
160
|
+
queryId: {
|
|
161
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
162
|
+
isOptional: true
|
|
163
|
+
},
|
|
164
|
+
config: {
|
|
165
|
+
type: ScalarTypeEnum.JSON(),
|
|
166
|
+
isOptional: true
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
});
|
|
170
|
+
/**
|
|
171
|
+
* Input for listing dashboards.
|
|
172
|
+
*/
|
|
173
|
+
const ListDashboardsInputModel = defineSchemaModel({
|
|
174
|
+
name: "ListDashboardsInput",
|
|
175
|
+
fields: {
|
|
176
|
+
status: {
|
|
177
|
+
type: DashboardStatusEnum,
|
|
178
|
+
isOptional: true
|
|
179
|
+
},
|
|
180
|
+
search: {
|
|
181
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
182
|
+
isOptional: true
|
|
183
|
+
},
|
|
184
|
+
limit: {
|
|
185
|
+
type: ScalarTypeEnum.Int_unsecure(),
|
|
186
|
+
isOptional: true,
|
|
187
|
+
defaultValue: 20
|
|
188
|
+
},
|
|
189
|
+
offset: {
|
|
190
|
+
type: ScalarTypeEnum.Int_unsecure(),
|
|
191
|
+
isOptional: true,
|
|
192
|
+
defaultValue: 0
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
});
|
|
196
|
+
/**
|
|
197
|
+
* Output for listing dashboards.
|
|
198
|
+
*/
|
|
199
|
+
const ListDashboardsOutputModel = defineSchemaModel({
|
|
200
|
+
name: "ListDashboardsOutput",
|
|
201
|
+
fields: {
|
|
202
|
+
dashboards: {
|
|
203
|
+
type: DashboardModel,
|
|
204
|
+
isArray: true,
|
|
205
|
+
isOptional: false
|
|
206
|
+
},
|
|
207
|
+
total: {
|
|
208
|
+
type: ScalarTypeEnum.Int_unsecure(),
|
|
209
|
+
isOptional: false
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
});
|
|
213
|
+
/**
|
|
214
|
+
* Input for getting a dashboard.
|
|
215
|
+
*/
|
|
216
|
+
const GetDashboardInputModel = defineSchemaModel({
|
|
217
|
+
name: "GetDashboardInput",
|
|
218
|
+
fields: {
|
|
219
|
+
dashboardId: {
|
|
220
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
221
|
+
isOptional: true
|
|
222
|
+
},
|
|
223
|
+
slug: {
|
|
224
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
225
|
+
isOptional: true
|
|
226
|
+
},
|
|
227
|
+
shareToken: {
|
|
228
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
229
|
+
isOptional: true
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
});
|
|
233
|
+
|
|
234
|
+
//#endregion
|
|
235
|
+
export { AddWidgetInputModel, CreateDashboardInputModel, DashboardModel, GetDashboardInputModel, ListDashboardsInputModel, ListDashboardsOutputModel, WidgetModel };
|
package/dist/dashboard/index.js
CHANGED
|
@@ -1 +1,5 @@
|
|
|
1
|
-
import{DashboardStatusEnum
|
|
1
|
+
import { DashboardStatusEnum, RefreshIntervalEnum, WidgetTypeEnum } from "./dashboard.enum.js";
|
|
2
|
+
import { AddWidgetInputModel, CreateDashboardInputModel, DashboardModel, GetDashboardInputModel, ListDashboardsInputModel, ListDashboardsOutputModel, WidgetModel } from "./dashboard.schema.js";
|
|
3
|
+
import { AddWidgetContract, CreateDashboardContract, GetDashboardContract, ListDashboardsContract } from "./dashboard.contracts.js";
|
|
4
|
+
|
|
5
|
+
export { AddWidgetContract, AddWidgetInputModel, CreateDashboardContract, CreateDashboardInputModel, DashboardModel, DashboardStatusEnum, GetDashboardContract, GetDashboardInputModel, ListDashboardsContract, ListDashboardsInputModel, ListDashboardsOutputModel, RefreshIntervalEnum, WidgetModel, WidgetTypeEnum };
|
|
@@ -1 +1,164 @@
|
|
|
1
|
-
|
|
1
|
+
//#region src/dashboard.feature.ts
|
|
2
|
+
const AnalyticsDashboardFeature = {
|
|
3
|
+
meta: {
|
|
4
|
+
key: "analytics-dashboard",
|
|
5
|
+
title: "Analytics Dashboard",
|
|
6
|
+
description: "Analytics dashboards with customizable widgets and queries",
|
|
7
|
+
domain: "analytics",
|
|
8
|
+
owners: ["@analytics-dashboard"],
|
|
9
|
+
tags: [
|
|
10
|
+
"analytics",
|
|
11
|
+
"dashboards",
|
|
12
|
+
"widgets",
|
|
13
|
+
"queries"
|
|
14
|
+
],
|
|
15
|
+
stability: "experimental"
|
|
16
|
+
},
|
|
17
|
+
operations: [
|
|
18
|
+
{
|
|
19
|
+
name: "analytics.dashboard.create",
|
|
20
|
+
version: 1
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
name: "analytics.dashboard.list",
|
|
24
|
+
version: 1
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
name: "analytics.dashboard.get",
|
|
28
|
+
version: 1
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
name: "analytics.widget.add",
|
|
32
|
+
version: 1
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
name: "analytics.query.create",
|
|
36
|
+
version: 1
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
name: "analytics.query.execute",
|
|
40
|
+
version: 1
|
|
41
|
+
}
|
|
42
|
+
],
|
|
43
|
+
events: [
|
|
44
|
+
{
|
|
45
|
+
name: "analytics.dashboard.created",
|
|
46
|
+
version: 1
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
name: "analytics.widget.added",
|
|
50
|
+
version: 1
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
name: "analytics.query.created",
|
|
54
|
+
version: 1
|
|
55
|
+
}
|
|
56
|
+
],
|
|
57
|
+
presentations: [
|
|
58
|
+
{
|
|
59
|
+
name: "analytics.dashboard.list",
|
|
60
|
+
version: 1
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
name: "analytics.dashboard.view",
|
|
64
|
+
version: 1
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
name: "analytics.dashboard.editor",
|
|
68
|
+
version: 1
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
name: "analytics.query.list",
|
|
72
|
+
version: 1
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
name: "analytics.query.builder",
|
|
76
|
+
version: 1
|
|
77
|
+
}
|
|
78
|
+
],
|
|
79
|
+
opToPresentation: [
|
|
80
|
+
{
|
|
81
|
+
op: {
|
|
82
|
+
name: "analytics.dashboard.list",
|
|
83
|
+
version: 1
|
|
84
|
+
},
|
|
85
|
+
pres: {
|
|
86
|
+
name: "analytics.dashboard.list",
|
|
87
|
+
version: 1
|
|
88
|
+
}
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
op: {
|
|
92
|
+
name: "analytics.dashboard.get",
|
|
93
|
+
version: 1
|
|
94
|
+
},
|
|
95
|
+
pres: {
|
|
96
|
+
name: "analytics.dashboard.view",
|
|
97
|
+
version: 1
|
|
98
|
+
}
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
op: {
|
|
102
|
+
name: "analytics.dashboard.create",
|
|
103
|
+
version: 1
|
|
104
|
+
},
|
|
105
|
+
pres: {
|
|
106
|
+
name: "analytics.dashboard.editor",
|
|
107
|
+
version: 1
|
|
108
|
+
}
|
|
109
|
+
},
|
|
110
|
+
{
|
|
111
|
+
op: {
|
|
112
|
+
name: "analytics.query.create",
|
|
113
|
+
version: 1
|
|
114
|
+
},
|
|
115
|
+
pres: {
|
|
116
|
+
name: "analytics.query.builder",
|
|
117
|
+
version: 1
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
],
|
|
121
|
+
presentationsTargets: [
|
|
122
|
+
{
|
|
123
|
+
name: "analytics.dashboard.list",
|
|
124
|
+
version: 1,
|
|
125
|
+
targets: [
|
|
126
|
+
"react",
|
|
127
|
+
"markdown",
|
|
128
|
+
"application/json"
|
|
129
|
+
]
|
|
130
|
+
},
|
|
131
|
+
{
|
|
132
|
+
name: "analytics.dashboard.view",
|
|
133
|
+
version: 1,
|
|
134
|
+
targets: ["react", "markdown"]
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
name: "analytics.dashboard.editor",
|
|
138
|
+
version: 1,
|
|
139
|
+
targets: ["react"]
|
|
140
|
+
},
|
|
141
|
+
{
|
|
142
|
+
name: "analytics.query.builder",
|
|
143
|
+
version: 1,
|
|
144
|
+
targets: ["react"]
|
|
145
|
+
}
|
|
146
|
+
],
|
|
147
|
+
capabilities: { requires: [
|
|
148
|
+
{
|
|
149
|
+
key: "identity",
|
|
150
|
+
version: 1
|
|
151
|
+
},
|
|
152
|
+
{
|
|
153
|
+
key: "metering",
|
|
154
|
+
version: 1
|
|
155
|
+
},
|
|
156
|
+
{
|
|
157
|
+
key: "audit-trail",
|
|
158
|
+
version: 1
|
|
159
|
+
}
|
|
160
|
+
] }
|
|
161
|
+
};
|
|
162
|
+
|
|
163
|
+
//#endregion
|
|
164
|
+
export { AnalyticsDashboardFeature };
|