@datapos/datapos-shared 0.3.101 → 0.3.103
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.
|
@@ -1,8 +1,11 @@
|
|
|
1
|
-
const R = 0,
|
|
2
|
-
|
|
1
|
+
const R = 0, L = (e) => e, F = () => Date.now(), _ = {
|
|
2
|
+
cartesian_areaLine: { categoryId: "cartesian", typeId: "areaLine", label: { "en-gb": "Area Line" }, options: { highchartsType: "area" } },
|
|
3
|
+
cartesian_areaSpline: { categoryId: "cartesian", typeId: "areaSpline", label: { "en-gb": "Area Spline" }, options: { highchartsType: "area" } },
|
|
3
4
|
cartesian_bar: { categoryId: "cartesian", typeId: "bar", label: { "en-gb": "Bar" }, options: { highchartsType: "bar" } },
|
|
4
5
|
cartesian_column: { categoryId: "cartesian", typeId: "column", label: { "en-gb": "Column" }, options: { highchartsType: "column" } },
|
|
5
6
|
cartesian_line: { categoryId: "cartesian", typeId: "line", label: { "en-gb": "Line" }, options: { highchartsType: "line" } },
|
|
7
|
+
cartesian_pyramid: { categoryId: "cartesian", typeId: "line", label: { "en-gb": "Pyramid" }, options: { highchartsType: "line" } },
|
|
8
|
+
cartesian_spline: { categoryId: "cartesian", typeId: "line", label: { "en-gb": "Spline" }, options: { highchartsType: "line" } },
|
|
6
9
|
chordDiagram: { categoryId: "chordDiagram", label: { "en-gb": "Chord Diagram" }, options: {} },
|
|
7
10
|
polar_area: { categoryId: "polar", typeId: "area", label: { "en-gb": "Radar (Area)" }, options: { highchartsType: "area" } },
|
|
8
11
|
polar_column: { categoryId: "polar", typeId: "column", label: { "en-gb": "Radar (Column)" }, options: { highchartsType: "column" } },
|
|
@@ -25,17 +28,17 @@ class p extends I {
|
|
|
25
28
|
super(t, a, r), this.name = "ApplicationError";
|
|
26
29
|
}
|
|
27
30
|
}
|
|
28
|
-
class
|
|
31
|
+
class k extends p {
|
|
29
32
|
constructor(t, a, r) {
|
|
30
33
|
super(t, a, r), this.name = "APIError";
|
|
31
34
|
}
|
|
32
35
|
}
|
|
33
|
-
class
|
|
36
|
+
class O extends p {
|
|
34
37
|
constructor(t, a, r) {
|
|
35
38
|
super(t, a, r), this.name = "EngineError";
|
|
36
39
|
}
|
|
37
40
|
}
|
|
38
|
-
class
|
|
41
|
+
class T extends p {
|
|
39
42
|
body;
|
|
40
43
|
constructor(t, a, r, o) {
|
|
41
44
|
super(t, a, o), this.name = "FetchError", this.body = r;
|
|
@@ -65,7 +68,7 @@ class B extends I {
|
|
|
65
68
|
}
|
|
66
69
|
async function j(e, t, a) {
|
|
67
70
|
const r = `${t} Response status '${e.status}${e.statusText ? ` - ${e.statusText}` : ""}' received.`, o = await e.text();
|
|
68
|
-
return new
|
|
71
|
+
return new T(r, a, o);
|
|
69
72
|
}
|
|
70
73
|
function H(e) {
|
|
71
74
|
return e.map((t) => t.message).join(" ");
|
|
@@ -85,7 +88,7 @@ function z(e) {
|
|
|
85
88
|
for (; r && !t.has(r); ) {
|
|
86
89
|
t.add(r);
|
|
87
90
|
let o;
|
|
88
|
-
if (r instanceof
|
|
91
|
+
if (r instanceof T)
|
|
89
92
|
o = { body: r.body, locator: r.locator, message: r.message, name: r.name, stack: r.stack }, r = r.cause;
|
|
90
93
|
else if (r instanceof v)
|
|
91
94
|
o = { componentName: r.componentName, info: r.info, locator: r.locator, message: r.message, name: r.name, stack: r.stack }, r = r.cause;
|
|
@@ -99,13 +102,13 @@ function z(e) {
|
|
|
99
102
|
}
|
|
100
103
|
return a;
|
|
101
104
|
}
|
|
102
|
-
function
|
|
105
|
+
function P() {
|
|
103
106
|
function e(t, a, r) {
|
|
104
107
|
r.textContent = "Cytoscape.js diagram goes here...";
|
|
105
108
|
}
|
|
106
109
|
return { render: e };
|
|
107
110
|
}
|
|
108
|
-
function
|
|
111
|
+
function V() {
|
|
109
112
|
function e(t, a, r) {
|
|
110
113
|
r.textContent = "values table goes here...";
|
|
111
114
|
}
|
|
@@ -113,7 +116,7 @@ function X() {
|
|
|
113
116
|
}
|
|
114
117
|
const S = "https://cdn.jsdelivr.net/npm/highcharts@11.4.3/es-modules/masters/", E = "highcharts";
|
|
115
118
|
let b, w = !1;
|
|
116
|
-
function
|
|
119
|
+
function X() {
|
|
117
120
|
async function e(n, s, u, h) {
|
|
118
121
|
await r();
|
|
119
122
|
const l = [];
|
|
@@ -177,7 +180,7 @@ function G() {
|
|
|
177
180
|
}
|
|
178
181
|
return { renderCartesianChart: e, renderPolarChart: t, renderRangeChart: a };
|
|
179
182
|
}
|
|
180
|
-
const
|
|
183
|
+
const D = "en-US", y = {}, G = (e) => {
|
|
181
184
|
switch (e) {
|
|
182
185
|
case "Edm.Binary":
|
|
183
186
|
return "unknown";
|
|
@@ -226,7 +229,7 @@ const T = "en-US", y = {}, P = (e) => {
|
|
|
226
229
|
const t = e.lastIndexOf(".");
|
|
227
230
|
if (t > -1) return e.substring(t + 1);
|
|
228
231
|
}
|
|
229
|
-
}, i = (e, t = 2, a = t, r =
|
|
232
|
+
}, i = (e, t = 2, a = t, r = D) => {
|
|
230
233
|
if (e == null) return "";
|
|
231
234
|
const o = `${r}decimal${t}.${a}`;
|
|
232
235
|
let n = y[o];
|
|
@@ -238,7 +241,7 @@ const T = "en-US", y = {}, P = (e) => {
|
|
|
238
241
|
style: "decimal",
|
|
239
242
|
useGrouping: !0
|
|
240
243
|
}), y[o] = n), n.format(e);
|
|
241
|
-
}, q = (e) => e == null ? "" : e < 1e3 ? x(e) : e < 1e6 ? `${i(e / 1e3, 2, 0)}K` : e < 1e9 ? `${i(e / 1e6, 2, 0)}M` : e < 1e12 ? `${i(e / 1e9, 2, 0)}B` : `${i(e / 1e12, 2, 0)}T`, Q = (e) => e == null ? "" : e === 1 ? "1 byte" : e < 1024 ? `${x(e)} bytes` : e < 1048576 ? `${i(e / 1024, 2, 0)} KB` : e < 1073741824 ? `${i(e / 1048576, 2, 0)} MB` : e < 1099511627776 ? `${i(e / 1073741824, 2, 0)} GB` : `${i(e / 1099511627776, 2, 0)} TB`, Y = (e) => e == null ? "" : e < 1e3 ? `${x(e)} ms` : e === 1e3 ? `${x(e)} sec` : e < 6e4 ? `${i(e / 1e3, 2, 0)} secs` : e === 6e4 ? "1 min" : e < 36e5 ? `${i(e / 6e4, 2, 0)} mins` : e === 36e5 ? "1 hr" : e < 864e5 ? `${i(e / 36e5, 2, 0)} hrs` : e === 864e5 ? "1 day" : `${i(e / 864e5, 2, 0)} days`, x = (e, t =
|
|
244
|
+
}, q = (e) => e == null ? "" : e < 1e3 ? x(e) : e < 1e6 ? `${i(e / 1e3, 2, 0)}K` : e < 1e9 ? `${i(e / 1e6, 2, 0)}M` : e < 1e12 ? `${i(e / 1e9, 2, 0)}B` : `${i(e / 1e12, 2, 0)}T`, Q = (e) => e == null ? "" : e === 1 ? "1 byte" : e < 1024 ? `${x(e)} bytes` : e < 1048576 ? `${i(e / 1024, 2, 0)} KB` : e < 1073741824 ? `${i(e / 1048576, 2, 0)} MB` : e < 1099511627776 ? `${i(e / 1073741824, 2, 0)} GB` : `${i(e / 1099511627776, 2, 0)} TB`, Y = (e) => e == null ? "" : e < 1e3 ? `${x(e)} ms` : e === 1e3 ? `${x(e)} sec` : e < 6e4 ? `${i(e / 1e3, 2, 0)} secs` : e === 6e4 ? "1 min" : e < 36e5 ? `${i(e / 6e4, 2, 0)} mins` : e === 36e5 ? "1 hr" : e < 864e5 ? `${i(e / 36e5, 2, 0)} hrs` : e === 864e5 ? "1 day" : `${i(e / 864e5, 2, 0)} days`, x = (e, t = D) => {
|
|
242
245
|
if (e == null) return "";
|
|
243
246
|
const a = `${t}decimal0.0`;
|
|
244
247
|
let r = y[a];
|
|
@@ -319,20 +322,20 @@ const T = "en-US", y = {}, P = (e) => {
|
|
|
319
322
|
return a ? { ...a, label: a.label[t] || a.label[d] || e } : { id: e, color: "other", label: e };
|
|
320
323
|
}, d = "en-gb";
|
|
321
324
|
export {
|
|
322
|
-
|
|
325
|
+
k as APIError,
|
|
323
326
|
p as ApplicationError,
|
|
324
327
|
d as DEFAULT_LOCALE_CODE,
|
|
325
328
|
R as DefaultTimestamp,
|
|
326
|
-
|
|
327
|
-
|
|
329
|
+
O as EngineError,
|
|
330
|
+
T as FetchError,
|
|
328
331
|
B as OperationalError,
|
|
329
332
|
v as VueError,
|
|
330
333
|
U as WindowPromiseRejectionError,
|
|
331
334
|
M as WindowRuntimeError,
|
|
332
335
|
j as buildFetchError,
|
|
333
336
|
H as concatenateSerialisedErrorMessages,
|
|
334
|
-
|
|
335
|
-
|
|
337
|
+
L as convertMillisecondsToTimestamp,
|
|
338
|
+
G as convertODataTypeIdToUsageTypeId,
|
|
336
339
|
K as extractExtensionFromPath,
|
|
337
340
|
J as extractNameFromPath,
|
|
338
341
|
i as formatNumberAsDecimalNumber,
|
|
@@ -341,15 +344,15 @@ export {
|
|
|
341
344
|
Q as formatNumberAsStorageSize,
|
|
342
345
|
x as formatNumberAsWholeNumber,
|
|
343
346
|
ae as getComponentStatus,
|
|
344
|
-
|
|
347
|
+
F as getCurrentTimestamp,
|
|
345
348
|
ee as getDataFormats,
|
|
346
349
|
re as getRecordDelimiters,
|
|
347
350
|
te as getValueDelimiters,
|
|
348
351
|
Z as lookupMimeTypeForExtension,
|
|
349
352
|
W as normalizeToError,
|
|
350
|
-
|
|
353
|
+
_ as presentationViewTypeMap,
|
|
351
354
|
z as serialiseError,
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
+
P as useCytoscapeJS,
|
|
356
|
+
V as useDataTable,
|
|
357
|
+
X as useHighcharts
|
|
355
358
|
};
|
|
@@ -49,7 +49,7 @@ export interface PresentationVisualViewConfig {
|
|
|
49
49
|
}
|
|
50
50
|
export interface PresentationVisualCartesianViewConfig extends PresentationVisualViewConfig {
|
|
51
51
|
categoryId: 'cartesian';
|
|
52
|
-
typeId: '
|
|
52
|
+
typeId: 'areaLine' | 'areaSpline' | 'bar' | 'column' | 'line' | 'pyramid' | 'spline';
|
|
53
53
|
}
|
|
54
54
|
export interface PresentationVisualChordDiagramViewConfig extends PresentationVisualViewConfig {
|
|
55
55
|
categoryId: 'chordDiagram';
|
|
@@ -74,7 +74,7 @@ export interface PresentationVisualValuesViewConfig extends PresentationVisualVi
|
|
|
74
74
|
export type PresentationVisualViewType = PresentationVisualCartesianViewType | PresentationVisualChordViewType | PresentationVisualPolarViewType | PresentationVisualRangeViewType | PresentationVisualSankeyDiagramViewType | PresentationVisualStreamgraphViewType | PresentationVisualValuesViewType;
|
|
75
75
|
export type PresentationVisualCartesianViewType = {
|
|
76
76
|
categoryId: 'cartesian';
|
|
77
|
-
typeId: '
|
|
77
|
+
typeId: 'areaLine' | 'areaSpline' | 'bar' | 'column' | 'line' | 'pyramid' | 'spline';
|
|
78
78
|
label: Record<string, string>;
|
|
79
79
|
options: {
|
|
80
80
|
highchartsType: 'area' | 'bar' | 'column' | 'line';
|