@contractspec/example.analytics-dashboard 0.0.0-canary-20260113170453
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/LICENSE +21 -0
- package/README.md +281 -0
- package/dist/dashboard/dashboard.enum.d.ts +18 -0
- package/dist/dashboard/dashboard.enum.d.ts.map +1 -0
- package/dist/dashboard/dashboard.enum.js +43 -0
- package/dist/dashboard/dashboard.enum.js.map +1 -0
- package/dist/dashboard/dashboard.operation.d.ts +537 -0
- package/dist/dashboard/dashboard.operation.d.ts.map +1 -0
- package/dist/dashboard/dashboard.operation.js +213 -0
- package/dist/dashboard/dashboard.operation.js.map +1 -0
- package/dist/dashboard/dashboard.presentation.d.ts +9 -0
- package/dist/dashboard/dashboard.presentation.d.ts.map +1 -0
- package/dist/dashboard/dashboard.presentation.js +90 -0
- package/dist/dashboard/dashboard.presentation.js.map +1 -0
- package/dist/dashboard/dashboard.schema.d.ts +333 -0
- package/dist/dashboard/dashboard.schema.d.ts.map +1 -0
- package/dist/dashboard/dashboard.schema.js +236 -0
- package/dist/dashboard/dashboard.schema.js.map +1 -0
- package/dist/dashboard/dashboard.test-spec.d.ts +10 -0
- package/dist/dashboard/dashboard.test-spec.d.ts.map +1 -0
- package/dist/dashboard/dashboard.test-spec.js +233 -0
- package/dist/dashboard/dashboard.test-spec.js.map +1 -0
- package/dist/dashboard/index.d.ts +4 -0
- package/dist/dashboard/index.js +5 -0
- package/dist/dashboard.feature.d.ts +17 -0
- package/dist/dashboard.feature.d.ts.map +1 -0
- package/dist/dashboard.feature.js +177 -0
- package/dist/dashboard.feature.js.map +1 -0
- package/dist/docs/analytics-dashboard.docblock.d.ts +1 -0
- package/dist/docs/analytics-dashboard.docblock.js +114 -0
- package/dist/docs/analytics-dashboard.docblock.js.map +1 -0
- package/dist/docs/index.d.ts +1 -0
- package/dist/docs/index.js +1 -0
- package/dist/events.d.ts +149 -0
- package/dist/events.d.ts.map +1 -0
- package/dist/events.js +128 -0
- package/dist/events.js.map +1 -0
- package/dist/example.d.ts +7 -0
- package/dist/example.d.ts.map +1 -0
- package/dist/example.js +58 -0
- package/dist/example.js.map +1 -0
- package/dist/handlers/analytics.handlers.d.ts +122 -0
- package/dist/handlers/analytics.handlers.d.ts.map +1 -0
- package/dist/handlers/analytics.handlers.js +310 -0
- package/dist/handlers/analytics.handlers.js.map +1 -0
- package/dist/handlers/index.d.ts +2 -0
- package/dist/handlers/index.js +3 -0
- package/dist/index.d.ts +12 -0
- package/dist/index.js +13 -0
- package/dist/query/index.d.ts +4 -0
- package/dist/query/index.js +5 -0
- package/dist/query/query.enum.d.ts +10 -0
- package/dist/query/query.enum.d.ts.map +1 -0
- package/dist/query/query.enum.js +16 -0
- package/dist/query/query.enum.js.map +1 -0
- package/dist/query/query.operation.d.ts +181 -0
- package/dist/query/query.operation.d.ts.map +1 -0
- package/dist/query/query.operation.js +113 -0
- package/dist/query/query.operation.js.map +1 -0
- package/dist/query/query.presentation.d.ts +8 -0
- package/dist/query/query.presentation.d.ts.map +1 -0
- package/dist/query/query.presentation.js +60 -0
- package/dist/query/query.presentation.js.map +1 -0
- package/dist/query/query.schema.d.ts +143 -0
- package/dist/query/query.schema.d.ts.map +1 -0
- package/dist/query/query.schema.js +157 -0
- package/dist/query/query.schema.js.map +1 -0
- package/dist/query/query.test-spec.d.ts +8 -0
- package/dist/query/query.test-spec.d.ts.map +1 -0
- package/dist/query/query.test-spec.js +124 -0
- package/dist/query/query.test-spec.js.map +1 -0
- package/dist/query-engine/index.d.ts +106 -0
- package/dist/query-engine/index.d.ts.map +1 -0
- package/dist/query-engine/index.js +189 -0
- package/dist/query-engine/index.js.map +1 -0
- package/dist/seeders/index.d.ts +10 -0
- package/dist/seeders/index.d.ts.map +1 -0
- package/dist/seeders/index.js +19 -0
- package/dist/seeders/index.js.map +1 -0
- package/dist/ui/AnalyticsDashboard.d.ts +7 -0
- package/dist/ui/AnalyticsDashboard.d.ts.map +1 -0
- package/dist/ui/AnalyticsDashboard.js +265 -0
- package/dist/ui/AnalyticsDashboard.js.map +1 -0
- package/dist/ui/hooks/index.d.ts +2 -0
- package/dist/ui/hooks/index.js +5 -0
- package/dist/ui/hooks/useAnalyticsData.d.ts +23 -0
- package/dist/ui/hooks/useAnalyticsData.d.ts.map +1 -0
- package/dist/ui/hooks/useAnalyticsData.js +73 -0
- package/dist/ui/hooks/useAnalyticsData.js.map +1 -0
- package/dist/ui/index.d.ts +6 -0
- package/dist/ui/index.js +6 -0
- package/dist/ui/renderers/analytics.markdown.d.ts +28 -0
- package/dist/ui/renderers/analytics.markdown.d.ts.map +1 -0
- package/dist/ui/renderers/analytics.markdown.js +264 -0
- package/dist/ui/renderers/analytics.markdown.js.map +1 -0
- package/dist/ui/renderers/index.d.ts +2 -0
- package/dist/ui/renderers/index.js +3 -0
- package/package.json +101 -0
|
@@ -0,0 +1,213 @@
|
|
|
1
|
+
import { AddWidgetInputModel, CreateDashboardInputModel, DashboardModel, GetDashboardInputModel, ListDashboardsInputModel, ListDashboardsOutputModel, WidgetModel } from "./dashboard.schema.js";
|
|
2
|
+
import { defineCommand, defineQuery } from "@contractspec/lib.contracts/operations";
|
|
3
|
+
|
|
4
|
+
//#region src/dashboard/dashboard.operation.ts
|
|
5
|
+
const OWNERS = ["@example.analytics-dashboard"];
|
|
6
|
+
/**
|
|
7
|
+
* Create a new analytics dashboard.
|
|
8
|
+
*/
|
|
9
|
+
const CreateDashboardContract = defineCommand({
|
|
10
|
+
meta: {
|
|
11
|
+
key: "analytics.dashboard.create",
|
|
12
|
+
version: "1.0.0",
|
|
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
|
+
key: "analytics.dashboard.created",
|
|
32
|
+
version: "1.0.0",
|
|
33
|
+
stability: "stable",
|
|
34
|
+
owners: [...OWNERS],
|
|
35
|
+
tags: [
|
|
36
|
+
"analytics",
|
|
37
|
+
"dashboard",
|
|
38
|
+
"created"
|
|
39
|
+
],
|
|
40
|
+
when: "Dashboard created",
|
|
41
|
+
payload: DashboardModel
|
|
42
|
+
}],
|
|
43
|
+
audit: ["analytics.dashboard.created"]
|
|
44
|
+
},
|
|
45
|
+
acceptance: {
|
|
46
|
+
scenarios: [{
|
|
47
|
+
key: "create-dashboard-happy-path",
|
|
48
|
+
given: ["User is authenticated"],
|
|
49
|
+
when: ["User submits valid dashboard configuration"],
|
|
50
|
+
then: ["Dashboard is created", "DashboardCreated event is emitted"]
|
|
51
|
+
}],
|
|
52
|
+
examples: [{
|
|
53
|
+
key: "create-basic",
|
|
54
|
+
input: {
|
|
55
|
+
name: "Revenue Dashboard",
|
|
56
|
+
description: "Monthly revenue metrics"
|
|
57
|
+
},
|
|
58
|
+
output: {
|
|
59
|
+
id: "dash-123",
|
|
60
|
+
name: "Revenue Dashboard",
|
|
61
|
+
widgets: []
|
|
62
|
+
}
|
|
63
|
+
}]
|
|
64
|
+
}
|
|
65
|
+
});
|
|
66
|
+
/**
|
|
67
|
+
* Add a widget to a dashboard.
|
|
68
|
+
*/
|
|
69
|
+
const AddWidgetContract = defineCommand({
|
|
70
|
+
meta: {
|
|
71
|
+
key: "analytics.widget.add",
|
|
72
|
+
version: "1.0.0",
|
|
73
|
+
stability: "stable",
|
|
74
|
+
owners: [...OWNERS],
|
|
75
|
+
tags: [
|
|
76
|
+
"analytics",
|
|
77
|
+
"widget",
|
|
78
|
+
"add"
|
|
79
|
+
],
|
|
80
|
+
description: "Add a widget to a dashboard.",
|
|
81
|
+
goal: "Allow users to add visualizations.",
|
|
82
|
+
context: "Dashboard editor."
|
|
83
|
+
},
|
|
84
|
+
io: {
|
|
85
|
+
input: AddWidgetInputModel,
|
|
86
|
+
output: WidgetModel
|
|
87
|
+
},
|
|
88
|
+
policy: { auth: "user" },
|
|
89
|
+
sideEffects: { emits: [{
|
|
90
|
+
key: "analytics.widget.added",
|
|
91
|
+
version: "1.0.0",
|
|
92
|
+
stability: "stable",
|
|
93
|
+
owners: [...OWNERS],
|
|
94
|
+
tags: [
|
|
95
|
+
"analytics",
|
|
96
|
+
"widget",
|
|
97
|
+
"added"
|
|
98
|
+
],
|
|
99
|
+
when: "Widget added",
|
|
100
|
+
payload: WidgetModel
|
|
101
|
+
}] },
|
|
102
|
+
acceptance: {
|
|
103
|
+
scenarios: [{
|
|
104
|
+
key: "add-widget-happy-path",
|
|
105
|
+
given: ["Dashboard exists"],
|
|
106
|
+
when: ["User adds widget to dashboard"],
|
|
107
|
+
then: ["Widget is created", "WidgetAdded event is emitted"]
|
|
108
|
+
}],
|
|
109
|
+
examples: [{
|
|
110
|
+
key: "add-chart-widget",
|
|
111
|
+
input: {
|
|
112
|
+
dashboardId: "dash-123",
|
|
113
|
+
type: "chart",
|
|
114
|
+
queryId: "query-456",
|
|
115
|
+
config: { chartType: "bar" }
|
|
116
|
+
},
|
|
117
|
+
output: {
|
|
118
|
+
id: "widget-789",
|
|
119
|
+
type: "chart",
|
|
120
|
+
dashboardId: "dash-123"
|
|
121
|
+
}
|
|
122
|
+
}]
|
|
123
|
+
}
|
|
124
|
+
});
|
|
125
|
+
/**
|
|
126
|
+
* List dashboards.
|
|
127
|
+
*/
|
|
128
|
+
const ListDashboardsContract = defineQuery({
|
|
129
|
+
meta: {
|
|
130
|
+
key: "analytics.dashboard.list",
|
|
131
|
+
version: "1.0.0",
|
|
132
|
+
stability: "stable",
|
|
133
|
+
owners: [...OWNERS],
|
|
134
|
+
tags: [
|
|
135
|
+
"analytics",
|
|
136
|
+
"dashboard",
|
|
137
|
+
"list"
|
|
138
|
+
],
|
|
139
|
+
description: "List dashboards.",
|
|
140
|
+
goal: "Browse available dashboards.",
|
|
141
|
+
context: "Dashboard listing."
|
|
142
|
+
},
|
|
143
|
+
io: {
|
|
144
|
+
input: ListDashboardsInputModel,
|
|
145
|
+
output: ListDashboardsOutputModel
|
|
146
|
+
},
|
|
147
|
+
policy: { auth: "user" },
|
|
148
|
+
acceptance: {
|
|
149
|
+
scenarios: [{
|
|
150
|
+
key: "list-dashboards-happy-path",
|
|
151
|
+
given: ["User has dashboards"],
|
|
152
|
+
when: ["User lists dashboards"],
|
|
153
|
+
then: ["Paginated list of dashboards is returned"]
|
|
154
|
+
}],
|
|
155
|
+
examples: [{
|
|
156
|
+
key: "list-basic",
|
|
157
|
+
input: {
|
|
158
|
+
limit: 10,
|
|
159
|
+
offset: 0
|
|
160
|
+
},
|
|
161
|
+
output: {
|
|
162
|
+
items: [],
|
|
163
|
+
total: 0,
|
|
164
|
+
hasMore: false
|
|
165
|
+
}
|
|
166
|
+
}]
|
|
167
|
+
}
|
|
168
|
+
});
|
|
169
|
+
/**
|
|
170
|
+
* Get a dashboard with widgets.
|
|
171
|
+
*/
|
|
172
|
+
const GetDashboardContract = defineQuery({
|
|
173
|
+
meta: {
|
|
174
|
+
key: "analytics.dashboard.get",
|
|
175
|
+
version: "1.0.0",
|
|
176
|
+
stability: "stable",
|
|
177
|
+
owners: [...OWNERS],
|
|
178
|
+
tags: [
|
|
179
|
+
"analytics",
|
|
180
|
+
"dashboard",
|
|
181
|
+
"get"
|
|
182
|
+
],
|
|
183
|
+
description: "Get a dashboard with widgets.",
|
|
184
|
+
goal: "Load dashboard for viewing.",
|
|
185
|
+
context: "Dashboard view."
|
|
186
|
+
},
|
|
187
|
+
io: {
|
|
188
|
+
input: GetDashboardInputModel,
|
|
189
|
+
output: DashboardModel
|
|
190
|
+
},
|
|
191
|
+
policy: { auth: "anonymous" },
|
|
192
|
+
acceptance: {
|
|
193
|
+
scenarios: [{
|
|
194
|
+
key: "get-dashboard-happy-path",
|
|
195
|
+
given: ["Dashboard exists"],
|
|
196
|
+
when: ["User requests dashboard by ID"],
|
|
197
|
+
then: ["Dashboard with widgets is returned"]
|
|
198
|
+
}],
|
|
199
|
+
examples: [{
|
|
200
|
+
key: "get-basic",
|
|
201
|
+
input: { dashboardId: "dash-123" },
|
|
202
|
+
output: {
|
|
203
|
+
id: "dash-123",
|
|
204
|
+
name: "Revenue Dashboard",
|
|
205
|
+
widgets: []
|
|
206
|
+
}
|
|
207
|
+
}]
|
|
208
|
+
}
|
|
209
|
+
});
|
|
210
|
+
|
|
211
|
+
//#endregion
|
|
212
|
+
export { AddWidgetContract, CreateDashboardContract, GetDashboardContract, ListDashboardsContract };
|
|
213
|
+
//# sourceMappingURL=dashboard.operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dashboard.operation.js","names":[],"sources":["../../src/dashboard/dashboard.operation.ts"],"sourcesContent":["import {\n defineCommand,\n defineQuery,\n} from '@contractspec/lib.contracts/operations';\nimport {\n DashboardModel,\n WidgetModel,\n CreateDashboardInputModel,\n AddWidgetInputModel,\n ListDashboardsInputModel,\n ListDashboardsOutputModel,\n GetDashboardInputModel,\n} from './dashboard.schema';\n\nconst OWNERS = ['@example.analytics-dashboard'] as const;\n\n/**\n * Create a new analytics dashboard.\n */\nexport const CreateDashboardContract = defineCommand({\n meta: {\n key: 'analytics.dashboard.create',\n version: '1.0.0',\n stability: 'stable',\n owners: [...OWNERS],\n tags: ['analytics', 'dashboard', 'create'],\n description: 'Create a new analytics dashboard.',\n goal: 'Allow users to create custom dashboards.',\n context: 'Dashboard management.',\n },\n io: { input: CreateDashboardInputModel, output: DashboardModel },\n policy: { auth: 'user' },\n sideEffects: {\n emits: [\n {\n key: 'analytics.dashboard.created',\n version: '1.0.0',\n stability: 'stable',\n owners: [...OWNERS],\n tags: ['analytics', 'dashboard', 'created'],\n when: 'Dashboard created',\n payload: DashboardModel,\n },\n ],\n audit: ['analytics.dashboard.created'],\n },\n acceptance: {\n scenarios: [\n {\n key: 'create-dashboard-happy-path',\n given: ['User is authenticated'],\n when: ['User submits valid dashboard configuration'],\n then: ['Dashboard is created', 'DashboardCreated event is emitted'],\n },\n ],\n examples: [\n {\n key: 'create-basic',\n input: {\n name: 'Revenue Dashboard',\n description: 'Monthly revenue metrics',\n },\n output: { id: 'dash-123', name: 'Revenue Dashboard', widgets: [] },\n },\n ],\n },\n});\n\n/**\n * Add a widget to a dashboard.\n */\nexport const AddWidgetContract = defineCommand({\n meta: {\n key: 'analytics.widget.add',\n version: '1.0.0',\n stability: 'stable',\n owners: [...OWNERS],\n tags: ['analytics', 'widget', 'add'],\n description: 'Add a widget to a dashboard.',\n goal: 'Allow users to add visualizations.',\n context: 'Dashboard editor.',\n },\n io: { input: AddWidgetInputModel, output: WidgetModel },\n policy: { auth: 'user' },\n sideEffects: {\n emits: [\n {\n key: 'analytics.widget.added',\n version: '1.0.0',\n stability: 'stable',\n owners: [...OWNERS],\n tags: ['analytics', 'widget', 'added'],\n when: 'Widget added',\n payload: WidgetModel,\n },\n ],\n },\n acceptance: {\n scenarios: [\n {\n key: 'add-widget-happy-path',\n given: ['Dashboard exists'],\n when: ['User adds widget to dashboard'],\n then: ['Widget is created', 'WidgetAdded event is emitted'],\n },\n ],\n examples: [\n {\n key: 'add-chart-widget',\n input: {\n dashboardId: 'dash-123',\n type: 'chart',\n queryId: 'query-456',\n config: { chartType: 'bar' },\n },\n output: { id: 'widget-789', type: 'chart', dashboardId: 'dash-123' },\n },\n ],\n },\n});\n\n/**\n * List dashboards.\n */\nexport const ListDashboardsContract = defineQuery({\n meta: {\n key: 'analytics.dashboard.list',\n version: '1.0.0',\n stability: 'stable',\n owners: [...OWNERS],\n tags: ['analytics', 'dashboard', 'list'],\n description: 'List dashboards.',\n goal: 'Browse available dashboards.',\n context: 'Dashboard listing.',\n },\n io: { input: ListDashboardsInputModel, output: ListDashboardsOutputModel },\n policy: { auth: 'user' },\n acceptance: {\n scenarios: [\n {\n key: 'list-dashboards-happy-path',\n given: ['User has dashboards'],\n when: ['User lists dashboards'],\n then: ['Paginated list of dashboards is returned'],\n },\n ],\n examples: [\n {\n key: 'list-basic',\n input: { limit: 10, offset: 0 },\n output: { items: [], total: 0, hasMore: false },\n },\n ],\n },\n});\n\n/**\n * Get a dashboard with widgets.\n */\nexport const GetDashboardContract = defineQuery({\n meta: {\n key: 'analytics.dashboard.get',\n version: '1.0.0',\n stability: 'stable',\n owners: [...OWNERS],\n tags: ['analytics', 'dashboard', 'get'],\n description: 'Get a dashboard with widgets.',\n goal: 'Load dashboard for viewing.',\n context: 'Dashboard view.',\n },\n io: { input: GetDashboardInputModel, output: DashboardModel },\n policy: { auth: 'anonymous' },\n acceptance: {\n scenarios: [\n {\n key: 'get-dashboard-happy-path',\n given: ['Dashboard exists'],\n when: ['User requests dashboard by ID'],\n then: ['Dashboard with widgets is returned'],\n },\n ],\n examples: [\n {\n key: 'get-basic',\n input: { dashboardId: 'dash-123' },\n output: { id: 'dash-123', name: 'Revenue Dashboard', widgets: [] },\n },\n ],\n },\n});\n"],"mappings":"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"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import * as _contractspec_lib_contracts6 from "@contractspec/lib.contracts";
|
|
2
|
+
|
|
3
|
+
//#region src/dashboard/dashboard.presentation.d.ts
|
|
4
|
+
declare const DashboardsListPresentation: _contractspec_lib_contracts6.PresentationSpec;
|
|
5
|
+
declare const DashboardViewPresentation: _contractspec_lib_contracts6.PresentationSpec;
|
|
6
|
+
declare const DashboardEditorPresentation: _contractspec_lib_contracts6.PresentationSpec;
|
|
7
|
+
//#endregion
|
|
8
|
+
export { DashboardEditorPresentation, DashboardViewPresentation, DashboardsListPresentation };
|
|
9
|
+
//# sourceMappingURL=dashboard.presentation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dashboard.presentation.d.ts","names":[],"sources":["../../src/dashboard/dashboard.presentation.ts"],"sourcesContent":[],"mappings":";;;cAGa,4BAuBX,4BAAA,CAvBqC;cAyB1B,2BAuBX,4BAAA,CAvBoC;cAyBzB,6BAuBX,4BAAA,CAvBsC"}
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
import { DashboardModel } from "./dashboard.schema.js";
|
|
2
|
+
import { StabilityEnum, definePresentation } from "@contractspec/lib.contracts";
|
|
3
|
+
|
|
4
|
+
//#region src/dashboard/dashboard.presentation.ts
|
|
5
|
+
const DashboardsListPresentation = definePresentation({
|
|
6
|
+
meta: {
|
|
7
|
+
key: "analytics.dashboard.list",
|
|
8
|
+
version: "1.0.0",
|
|
9
|
+
title: "Dashboards List",
|
|
10
|
+
description: "List of analytics dashboards",
|
|
11
|
+
domain: "analytics",
|
|
12
|
+
owners: ["@analytics-dashboard"],
|
|
13
|
+
tags: [
|
|
14
|
+
"analytics",
|
|
15
|
+
"dashboards",
|
|
16
|
+
"list"
|
|
17
|
+
],
|
|
18
|
+
stability: StabilityEnum.Experimental,
|
|
19
|
+
goal: "Show users available analytics dashboards.",
|
|
20
|
+
context: "The main dashboard management view."
|
|
21
|
+
},
|
|
22
|
+
source: {
|
|
23
|
+
type: "component",
|
|
24
|
+
framework: "react",
|
|
25
|
+
componentKey: "DashboardsList",
|
|
26
|
+
props: DashboardModel
|
|
27
|
+
},
|
|
28
|
+
targets: [
|
|
29
|
+
"react",
|
|
30
|
+
"markdown",
|
|
31
|
+
"application/json"
|
|
32
|
+
],
|
|
33
|
+
policy: { flags: ["analytics.dashboards.enabled"] }
|
|
34
|
+
});
|
|
35
|
+
const DashboardViewPresentation = definePresentation({
|
|
36
|
+
meta: {
|
|
37
|
+
key: "analytics.dashboard.view",
|
|
38
|
+
version: "1.0.0",
|
|
39
|
+
title: "Dashboard View",
|
|
40
|
+
description: "View a single dashboard with widgets",
|
|
41
|
+
domain: "analytics",
|
|
42
|
+
owners: ["@analytics-dashboard"],
|
|
43
|
+
tags: [
|
|
44
|
+
"analytics",
|
|
45
|
+
"dashboard",
|
|
46
|
+
"view"
|
|
47
|
+
],
|
|
48
|
+
stability: StabilityEnum.Experimental,
|
|
49
|
+
goal: "Render a dashboard with its visualizations and data.",
|
|
50
|
+
context: "The interactive viewing interface."
|
|
51
|
+
},
|
|
52
|
+
source: {
|
|
53
|
+
type: "component",
|
|
54
|
+
framework: "react",
|
|
55
|
+
componentKey: "DashboardView",
|
|
56
|
+
props: DashboardModel
|
|
57
|
+
},
|
|
58
|
+
targets: ["react", "markdown"],
|
|
59
|
+
policy: { flags: ["analytics.dashboards.enabled"] }
|
|
60
|
+
});
|
|
61
|
+
const DashboardEditorPresentation = definePresentation({
|
|
62
|
+
meta: {
|
|
63
|
+
key: "analytics.dashboard.editor",
|
|
64
|
+
version: "1.0.0",
|
|
65
|
+
title: "Dashboard Editor",
|
|
66
|
+
description: "Edit dashboard configuration and widgets",
|
|
67
|
+
domain: "analytics",
|
|
68
|
+
owners: ["@analytics-dashboard"],
|
|
69
|
+
tags: [
|
|
70
|
+
"analytics",
|
|
71
|
+
"dashboard",
|
|
72
|
+
"editor"
|
|
73
|
+
],
|
|
74
|
+
stability: StabilityEnum.Experimental,
|
|
75
|
+
goal: "Configure dashboard layout and widget settings.",
|
|
76
|
+
context: "Management tool for analysts."
|
|
77
|
+
},
|
|
78
|
+
source: {
|
|
79
|
+
type: "component",
|
|
80
|
+
framework: "react",
|
|
81
|
+
componentKey: "DashboardEditor",
|
|
82
|
+
props: DashboardModel
|
|
83
|
+
},
|
|
84
|
+
targets: ["react"],
|
|
85
|
+
policy: { flags: ["analytics.dashboards.enabled"] }
|
|
86
|
+
});
|
|
87
|
+
|
|
88
|
+
//#endregion
|
|
89
|
+
export { DashboardEditorPresentation, DashboardViewPresentation, DashboardsListPresentation };
|
|
90
|
+
//# sourceMappingURL=dashboard.presentation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dashboard.presentation.js","names":[],"sources":["../../src/dashboard/dashboard.presentation.ts"],"sourcesContent":["import { definePresentation, StabilityEnum } from '@contractspec/lib.contracts';\nimport { DashboardModel } from './dashboard.schema';\n\nexport const DashboardsListPresentation = definePresentation({\n meta: {\n key: 'analytics.dashboard.list',\n version: '1.0.0',\n title: 'Dashboards List',\n description: 'List of analytics dashboards',\n domain: 'analytics',\n owners: ['@analytics-dashboard'],\n tags: ['analytics', 'dashboards', 'list'],\n stability: StabilityEnum.Experimental,\n goal: 'Show users available analytics dashboards.',\n context: 'The main dashboard management view.',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'DashboardsList',\n props: DashboardModel,\n },\n targets: ['react', 'markdown', 'application/json'],\n policy: {\n flags: ['analytics.dashboards.enabled'],\n },\n});\n\nexport const DashboardViewPresentation = definePresentation({\n meta: {\n key: 'analytics.dashboard.view',\n version: '1.0.0',\n title: 'Dashboard View',\n description: 'View a single dashboard with widgets',\n domain: 'analytics',\n owners: ['@analytics-dashboard'],\n tags: ['analytics', 'dashboard', 'view'],\n stability: StabilityEnum.Experimental,\n goal: 'Render a dashboard with its visualizations and data.',\n context: 'The interactive viewing interface.',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'DashboardView',\n props: DashboardModel,\n },\n targets: ['react', 'markdown'],\n policy: {\n flags: ['analytics.dashboards.enabled'],\n },\n});\n\nexport const DashboardEditorPresentation = definePresentation({\n meta: {\n key: 'analytics.dashboard.editor',\n version: '1.0.0',\n title: 'Dashboard Editor',\n description: 'Edit dashboard configuration and widgets',\n domain: 'analytics',\n owners: ['@analytics-dashboard'],\n tags: ['analytics', 'dashboard', 'editor'],\n stability: StabilityEnum.Experimental,\n goal: 'Configure dashboard layout and widget settings.',\n context: 'Management tool for analysts.',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'DashboardEditor',\n props: DashboardModel,\n },\n targets: ['react'],\n policy: {\n flags: ['analytics.dashboards.enabled'],\n },\n});\n"],"mappings":";;;;AAGA,MAAa,6BAA6B,mBAAmB;CAC3D,MAAM;EACJ,KAAK;EACL,SAAS;EACT,OAAO;EACP,aAAa;EACb,QAAQ;EACR,QAAQ,CAAC,uBAAuB;EAChC,MAAM;GAAC;GAAa;GAAc;GAAO;EACzC,WAAW,cAAc;EACzB,MAAM;EACN,SAAS;EACV;CACD,QAAQ;EACN,MAAM;EACN,WAAW;EACX,cAAc;EACd,OAAO;EACR;CACD,SAAS;EAAC;EAAS;EAAY;EAAmB;CAClD,QAAQ,EACN,OAAO,CAAC,+BAA+B,EACxC;CACF,CAAC;AAEF,MAAa,4BAA4B,mBAAmB;CAC1D,MAAM;EACJ,KAAK;EACL,SAAS;EACT,OAAO;EACP,aAAa;EACb,QAAQ;EACR,QAAQ,CAAC,uBAAuB;EAChC,MAAM;GAAC;GAAa;GAAa;GAAO;EACxC,WAAW,cAAc;EACzB,MAAM;EACN,SAAS;EACV;CACD,QAAQ;EACN,MAAM;EACN,WAAW;EACX,cAAc;EACd,OAAO;EACR;CACD,SAAS,CAAC,SAAS,WAAW;CAC9B,QAAQ,EACN,OAAO,CAAC,+BAA+B,EACxC;CACF,CAAC;AAEF,MAAa,8BAA8B,mBAAmB;CAC5D,MAAM;EACJ,KAAK;EACL,SAAS;EACT,OAAO;EACP,aAAa;EACb,QAAQ;EACR,QAAQ,CAAC,uBAAuB;EAChC,MAAM;GAAC;GAAa;GAAa;GAAS;EAC1C,WAAW,cAAc;EACzB,MAAM;EACN,SAAS;EACV;CACD,QAAQ;EACN,MAAM;EACN,WAAW;EACX,cAAc;EACd,OAAO;EACR;CACD,SAAS,CAAC,QAAQ;CAClB,QAAQ,EACN,OAAO,CAAC,+BAA+B,EACxC;CACF,CAAC"}
|
|
@@ -0,0 +1,333 @@
|
|
|
1
|
+
import * as _contractspec_lib_schema40 from "@contractspec/lib.schema";
|
|
2
|
+
|
|
3
|
+
//#region src/dashboard/dashboard.schema.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* A dashboard widget.
|
|
6
|
+
*/
|
|
7
|
+
declare const WidgetModel: _contractspec_lib_schema40.SchemaModel<{
|
|
8
|
+
id: {
|
|
9
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
10
|
+
isOptional: false;
|
|
11
|
+
};
|
|
12
|
+
dashboardId: {
|
|
13
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
14
|
+
isOptional: false;
|
|
15
|
+
};
|
|
16
|
+
name: {
|
|
17
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
18
|
+
isOptional: false;
|
|
19
|
+
};
|
|
20
|
+
type: {
|
|
21
|
+
type: _contractspec_lib_schema40.EnumType<[string, string, string, string, string, string, string, string, string, string, string, string]>;
|
|
22
|
+
isOptional: false;
|
|
23
|
+
};
|
|
24
|
+
gridX: {
|
|
25
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
26
|
+
isOptional: false;
|
|
27
|
+
};
|
|
28
|
+
gridY: {
|
|
29
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
30
|
+
isOptional: false;
|
|
31
|
+
};
|
|
32
|
+
gridWidth: {
|
|
33
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
34
|
+
isOptional: false;
|
|
35
|
+
};
|
|
36
|
+
gridHeight: {
|
|
37
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
38
|
+
isOptional: false;
|
|
39
|
+
};
|
|
40
|
+
queryId: {
|
|
41
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
42
|
+
isOptional: true;
|
|
43
|
+
};
|
|
44
|
+
config: {
|
|
45
|
+
type: _contractspec_lib_schema40.FieldType<unknown, unknown>;
|
|
46
|
+
isOptional: true;
|
|
47
|
+
};
|
|
48
|
+
}>;
|
|
49
|
+
/**
|
|
50
|
+
* An analytics dashboard.
|
|
51
|
+
*/
|
|
52
|
+
declare const DashboardModel: _contractspec_lib_schema40.SchemaModel<{
|
|
53
|
+
id: {
|
|
54
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
55
|
+
isOptional: false;
|
|
56
|
+
};
|
|
57
|
+
name: {
|
|
58
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
59
|
+
isOptional: false;
|
|
60
|
+
};
|
|
61
|
+
slug: {
|
|
62
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
63
|
+
isOptional: false;
|
|
64
|
+
};
|
|
65
|
+
description: {
|
|
66
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
67
|
+
isOptional: true;
|
|
68
|
+
};
|
|
69
|
+
status: {
|
|
70
|
+
type: _contractspec_lib_schema40.EnumType<[string, string, string]>;
|
|
71
|
+
isOptional: false;
|
|
72
|
+
};
|
|
73
|
+
refreshInterval: {
|
|
74
|
+
type: _contractspec_lib_schema40.EnumType<[string, string, string, string, string, string]>;
|
|
75
|
+
isOptional: false;
|
|
76
|
+
};
|
|
77
|
+
isPublic: {
|
|
78
|
+
type: _contractspec_lib_schema40.FieldType<boolean, boolean>;
|
|
79
|
+
isOptional: false;
|
|
80
|
+
};
|
|
81
|
+
widgets: {
|
|
82
|
+
type: _contractspec_lib_schema40.SchemaModel<{
|
|
83
|
+
id: {
|
|
84
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
85
|
+
isOptional: false;
|
|
86
|
+
};
|
|
87
|
+
dashboardId: {
|
|
88
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
89
|
+
isOptional: false;
|
|
90
|
+
};
|
|
91
|
+
name: {
|
|
92
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
93
|
+
isOptional: false;
|
|
94
|
+
};
|
|
95
|
+
type: {
|
|
96
|
+
type: _contractspec_lib_schema40.EnumType<[string, string, string, string, string, string, string, string, string, string, string, string]>;
|
|
97
|
+
isOptional: false;
|
|
98
|
+
};
|
|
99
|
+
gridX: {
|
|
100
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
101
|
+
isOptional: false;
|
|
102
|
+
};
|
|
103
|
+
gridY: {
|
|
104
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
105
|
+
isOptional: false;
|
|
106
|
+
};
|
|
107
|
+
gridWidth: {
|
|
108
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
109
|
+
isOptional: false;
|
|
110
|
+
};
|
|
111
|
+
gridHeight: {
|
|
112
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
113
|
+
isOptional: false;
|
|
114
|
+
};
|
|
115
|
+
queryId: {
|
|
116
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
117
|
+
isOptional: true;
|
|
118
|
+
};
|
|
119
|
+
config: {
|
|
120
|
+
type: _contractspec_lib_schema40.FieldType<unknown, unknown>;
|
|
121
|
+
isOptional: true;
|
|
122
|
+
};
|
|
123
|
+
}>;
|
|
124
|
+
isArray: true;
|
|
125
|
+
isOptional: true;
|
|
126
|
+
};
|
|
127
|
+
createdAt: {
|
|
128
|
+
type: _contractspec_lib_schema40.FieldType<Date, string>;
|
|
129
|
+
isOptional: false;
|
|
130
|
+
};
|
|
131
|
+
}>;
|
|
132
|
+
/**
|
|
133
|
+
* Input for creating a dashboard.
|
|
134
|
+
*/
|
|
135
|
+
declare const CreateDashboardInputModel: _contractspec_lib_schema40.SchemaModel<{
|
|
136
|
+
name: {
|
|
137
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
138
|
+
isOptional: false;
|
|
139
|
+
};
|
|
140
|
+
slug: {
|
|
141
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
142
|
+
isOptional: false;
|
|
143
|
+
};
|
|
144
|
+
description: {
|
|
145
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
146
|
+
isOptional: true;
|
|
147
|
+
};
|
|
148
|
+
refreshInterval: {
|
|
149
|
+
type: _contractspec_lib_schema40.EnumType<[string, string, string, string, string, string]>;
|
|
150
|
+
isOptional: true;
|
|
151
|
+
};
|
|
152
|
+
dateRange: {
|
|
153
|
+
type: _contractspec_lib_schema40.FieldType<unknown, unknown>;
|
|
154
|
+
isOptional: true;
|
|
155
|
+
};
|
|
156
|
+
}>;
|
|
157
|
+
/**
|
|
158
|
+
* Input for adding a widget.
|
|
159
|
+
*/
|
|
160
|
+
declare const AddWidgetInputModel: _contractspec_lib_schema40.SchemaModel<{
|
|
161
|
+
dashboardId: {
|
|
162
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
163
|
+
isOptional: false;
|
|
164
|
+
};
|
|
165
|
+
name: {
|
|
166
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
167
|
+
isOptional: false;
|
|
168
|
+
};
|
|
169
|
+
type: {
|
|
170
|
+
type: _contractspec_lib_schema40.EnumType<[string, string, string, string, string, string, string, string, string, string, string, string]>;
|
|
171
|
+
isOptional: false;
|
|
172
|
+
};
|
|
173
|
+
gridX: {
|
|
174
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
175
|
+
isOptional: true;
|
|
176
|
+
};
|
|
177
|
+
gridY: {
|
|
178
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
179
|
+
isOptional: true;
|
|
180
|
+
};
|
|
181
|
+
gridWidth: {
|
|
182
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
183
|
+
isOptional: true;
|
|
184
|
+
};
|
|
185
|
+
gridHeight: {
|
|
186
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
187
|
+
isOptional: true;
|
|
188
|
+
};
|
|
189
|
+
queryId: {
|
|
190
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
191
|
+
isOptional: true;
|
|
192
|
+
};
|
|
193
|
+
config: {
|
|
194
|
+
type: _contractspec_lib_schema40.FieldType<unknown, unknown>;
|
|
195
|
+
isOptional: true;
|
|
196
|
+
};
|
|
197
|
+
}>;
|
|
198
|
+
/**
|
|
199
|
+
* Input for listing dashboards.
|
|
200
|
+
*/
|
|
201
|
+
declare const ListDashboardsInputModel: _contractspec_lib_schema40.SchemaModel<{
|
|
202
|
+
status: {
|
|
203
|
+
type: _contractspec_lib_schema40.EnumType<[string, string, string]>;
|
|
204
|
+
isOptional: true;
|
|
205
|
+
};
|
|
206
|
+
search: {
|
|
207
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
208
|
+
isOptional: true;
|
|
209
|
+
};
|
|
210
|
+
limit: {
|
|
211
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
212
|
+
isOptional: true;
|
|
213
|
+
defaultValue: number;
|
|
214
|
+
};
|
|
215
|
+
offset: {
|
|
216
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
217
|
+
isOptional: true;
|
|
218
|
+
defaultValue: number;
|
|
219
|
+
};
|
|
220
|
+
}>;
|
|
221
|
+
/**
|
|
222
|
+
* Output for listing dashboards.
|
|
223
|
+
*/
|
|
224
|
+
declare const ListDashboardsOutputModel: _contractspec_lib_schema40.SchemaModel<{
|
|
225
|
+
dashboards: {
|
|
226
|
+
type: _contractspec_lib_schema40.SchemaModel<{
|
|
227
|
+
id: {
|
|
228
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
229
|
+
isOptional: false;
|
|
230
|
+
};
|
|
231
|
+
name: {
|
|
232
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
233
|
+
isOptional: false;
|
|
234
|
+
};
|
|
235
|
+
slug: {
|
|
236
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
237
|
+
isOptional: false;
|
|
238
|
+
};
|
|
239
|
+
description: {
|
|
240
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
241
|
+
isOptional: true;
|
|
242
|
+
};
|
|
243
|
+
status: {
|
|
244
|
+
type: _contractspec_lib_schema40.EnumType<[string, string, string]>;
|
|
245
|
+
isOptional: false;
|
|
246
|
+
};
|
|
247
|
+
refreshInterval: {
|
|
248
|
+
type: _contractspec_lib_schema40.EnumType<[string, string, string, string, string, string]>;
|
|
249
|
+
isOptional: false;
|
|
250
|
+
};
|
|
251
|
+
isPublic: {
|
|
252
|
+
type: _contractspec_lib_schema40.FieldType<boolean, boolean>;
|
|
253
|
+
isOptional: false;
|
|
254
|
+
};
|
|
255
|
+
widgets: {
|
|
256
|
+
type: _contractspec_lib_schema40.SchemaModel<{
|
|
257
|
+
id: {
|
|
258
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
259
|
+
isOptional: false;
|
|
260
|
+
};
|
|
261
|
+
dashboardId: {
|
|
262
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
263
|
+
isOptional: false;
|
|
264
|
+
};
|
|
265
|
+
name: {
|
|
266
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
267
|
+
isOptional: false;
|
|
268
|
+
};
|
|
269
|
+
type: {
|
|
270
|
+
type: _contractspec_lib_schema40.EnumType<[string, string, string, string, string, string, string, string, string, string, string, string]>;
|
|
271
|
+
isOptional: false;
|
|
272
|
+
};
|
|
273
|
+
gridX: {
|
|
274
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
275
|
+
isOptional: false;
|
|
276
|
+
};
|
|
277
|
+
gridY: {
|
|
278
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
279
|
+
isOptional: false;
|
|
280
|
+
};
|
|
281
|
+
gridWidth: {
|
|
282
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
283
|
+
isOptional: false;
|
|
284
|
+
};
|
|
285
|
+
gridHeight: {
|
|
286
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
287
|
+
isOptional: false;
|
|
288
|
+
};
|
|
289
|
+
queryId: {
|
|
290
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
291
|
+
isOptional: true;
|
|
292
|
+
};
|
|
293
|
+
config: {
|
|
294
|
+
type: _contractspec_lib_schema40.FieldType<unknown, unknown>;
|
|
295
|
+
isOptional: true;
|
|
296
|
+
};
|
|
297
|
+
}>;
|
|
298
|
+
isArray: true;
|
|
299
|
+
isOptional: true;
|
|
300
|
+
};
|
|
301
|
+
createdAt: {
|
|
302
|
+
type: _contractspec_lib_schema40.FieldType<Date, string>;
|
|
303
|
+
isOptional: false;
|
|
304
|
+
};
|
|
305
|
+
}>;
|
|
306
|
+
isArray: true;
|
|
307
|
+
isOptional: false;
|
|
308
|
+
};
|
|
309
|
+
total: {
|
|
310
|
+
type: _contractspec_lib_schema40.FieldType<number, number>;
|
|
311
|
+
isOptional: false;
|
|
312
|
+
};
|
|
313
|
+
}>;
|
|
314
|
+
/**
|
|
315
|
+
* Input for getting a dashboard.
|
|
316
|
+
*/
|
|
317
|
+
declare const GetDashboardInputModel: _contractspec_lib_schema40.SchemaModel<{
|
|
318
|
+
dashboardId: {
|
|
319
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
320
|
+
isOptional: true;
|
|
321
|
+
};
|
|
322
|
+
slug: {
|
|
323
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
324
|
+
isOptional: true;
|
|
325
|
+
};
|
|
326
|
+
shareToken: {
|
|
327
|
+
type: _contractspec_lib_schema40.FieldType<string, string>;
|
|
328
|
+
isOptional: true;
|
|
329
|
+
};
|
|
330
|
+
}>;
|
|
331
|
+
//#endregion
|
|
332
|
+
export { AddWidgetInputModel, CreateDashboardInputModel, DashboardModel, GetDashboardInputModel, ListDashboardsInputModel, ListDashboardsOutputModel, WidgetModel };
|
|
333
|
+
//# sourceMappingURL=dashboard.schema.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dashboard.schema.d.ts","names":[],"sources":["../../src/dashboard/dashboard.schema.ts"],"sourcesContent":[],"mappings":";;;;;;AAUa,cAAA,WAcX,6BAdsB,WActB,CAAA;EAAA,EAAA,EAAA;UAAA,0BAAA,CAAA;;;;;;;;;;EAdsB,CAAA;EAmBX,IAAA,EAAA;IAaX,IAAA,qCAAA,CAAA,CAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,CAAA,CAAA;;;;;;;;;;;;;;;;;;;;8CAbyB,CAAA,MAAA,EAAA,MAAA,CAAA;IAAA,UAAA,EAAA,IAAA;EAkBd,CAAA;EASX,MAAA,EAAA;;;;;;;AAKF;AAaE,cA7CW,cA6CX,6BA7CyB,WA6CzB,CAAA;;UAhCA,0BAAA,CAAA;;;;;;;;IAmB8B,IAAA,sCAAA,CAAA,MAAA,EAAA,MAAA,CAAA;IAkBnB,UAAA,EAAA,KAAA;EAgBX,CAAA;;;;;EAhBmC,MAAA,EAAA;IAqBxB,IAAA,qCAMX,CAAA,CAAA,MAAA,EAAA,MAAA,EAAA,MAAA,CAAA,CAAA;IAAA,UAAA,EAAA,KAAA;;;;;;;;;;;;;;;;;;;;;;oBANoC,KAAA;MAAA,CAAA;MAWzB,IAAA,EAAA;QAOX,IAAA,qCAAA,CAAA,CAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,CAAA,CAAA;;;;QAPiC,IAAA,sCAAA,CAAA,MAAA,EAAA,MAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAhEtB,sDAAyB;;UASpC,0BAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;cAKW,gDAAmB;;UAa9B,0BAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAKW,qDAAwB;;UAgBnC,0BAAA,CAAA;;;;;;;;;;;;;;;;;;;;;cAKW,sDAAyB;;;;cAMpC,0BAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAKW,mDAAsB;;UAOjC,0BAAA,CAAA"}
|