react-semaphor 0.1.559 → 0.1.560
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/analytics-protocol/index.js +368 -361
- package/dist/assistant-context/index.js +1 -1
- package/dist/assistant-protocol/index.js +5 -5
- package/dist/brand-studio/index.js +9 -9
- package/dist/briefings/index.js +5 -5
- package/dist/chunks/analytics-base-schemas-CHLxsPfX.js +630 -0
- package/dist/chunks/{assistant-chat-B_4bVE6I.js → assistant-chat-Bu2fFm_I.js} +206 -207
- package/dist/chunks/{bookmark-state-ssqrs5oP.js → bookmark-state-BFY9oNmr.js} +3 -3
- package/dist/chunks/{braces-Rdxa3H-s.js → braces-Da41xfUd.js} +1 -1
- package/dist/chunks/{comparison-window-caption-CKzQ5LcF.js → comparison-window-caption-4FNkMrzE.js} +166 -166
- package/dist/chunks/{context-DVy4HOU0.js → context-BgPDzLHZ.js} +1 -1
- package/dist/chunks/{custom-visual-inputs-zVa9wX_o.js → custom-visual-inputs-Dz-enUNR.js} +1 -1
- package/dist/chunks/{dashboard-BziwOVpZ.js → dashboard-_MeBuy67.js} +1 -1
- package/dist/chunks/{dashboard-briefing-launcher-CbeNR-YI.js → dashboard-briefing-launcher-CEi4Pr_v.js} +1152 -1166
- package/dist/chunks/{dashboard-controls-RD6UJs1r.js → dashboard-controls-Bi7fyG-4.js} +98 -98
- package/dist/chunks/{dashboard-json-DGpv17vL.js → dashboard-json-B1mU_OMa.js} +5 -5
- package/dist/chunks/{document-dashboard-inputs-ChVkcBuu.js → document-dashboard-inputs-CkWfDB8c.js} +64 -64
- package/dist/chunks/{edit-dashboard-visual-AQ2pQkFp.js → edit-dashboard-visual-0CJN31Y3.js} +8375 -8615
- package/dist/chunks/filter-reach-copy-BF4w4kI2.js +3738 -0
- package/dist/chunks/{filter-value-text-B4l-xqJT.js → filter-value-text-CRC-K_l_.js} +3 -3
- package/dist/chunks/{global-date-filter-utils-DBzEOX9M.js → global-date-filter-utils-D8365uPH.js} +4068 -3401
- package/dist/chunks/{index-B1Xr7W24.js → index-DtHidOPV.js} +579 -604
- package/dist/chunks/{layout-grid-Bbz3zKif.js → layout-grid-BvsH4RY2.js} +1 -1
- package/dist/chunks/{list-filter-3sbH0Uy1.js → list-filter-Dg0otx5E.js} +1 -1
- package/dist/chunks/{matrix-analytical-definition-CEe3PGEo.js → matrix-analytical-definition-CM18W8w6.js} +4 -4
- package/dist/chunks/{matrix-card-BRNGb1C4.js → matrix-card-HPskLaPy.js} +3 -3
- package/dist/chunks/{matrix-member-presentation-CEegvTqg.js → matrix-member-presentation-Bbrfrke4.js} +1 -1
- package/dist/chunks/{matrix-operation-contract-COxrfQTS.js → matrix-operation-contract-WPv4R-H_.js} +110 -110
- package/dist/chunks/{metric-comparison-DQx-uX__.js → metric-comparison-ljMKYZKa.js} +2 -2
- package/dist/chunks/{model-change-CJEj3ZD6.js → model-change-Ccn1zaxl.js} +1 -1
- package/dist/chunks/{palette-DMJtp3Vn.js → palette-Bsh376zO.js} +1 -1
- package/dist/chunks/{pivot-result-contract-expectations-DOYhqeZb.js → pivot-result-contract-expectations-Bl5suy4-.js} +602 -696
- package/dist/chunks/{pivot-result-identity-CAj8SiRL.js → pivot-result-identity-vS9TSh4f.js} +1 -1
- package/dist/chunks/{raw-temporal-presentation-BmT7z6NH.js → raw-temporal-presentation-BHm7s-hz.js} +230 -274
- package/dist/chunks/{report-preferences-dialog-0sc8B1lh.js → report-preferences-dialog-BV8L0SeS.js} +55 -55
- package/dist/chunks/{report-runtime-context-bYoExeWr.js → report-runtime-context-BZQh9ywy.js} +2 -2
- package/dist/chunks/{resolve-dashboard-input-context-B_C_VAJH.js → resolve-dashboard-input-context-CAMiWvyR.js} +1749 -1989
- package/dist/chunks/{save-DSb1jTtG.js → save-B5EAsgQF.js} +1 -1
- package/dist/chunks/{saved-dashboard-context-BQWM3ldX.js → saved-dashboard-context-n2Wn11cV.js} +57 -57
- package/dist/chunks/{selection-reducer-DSzMWb4x.js → selection-reducer-D0YnaAD9.js} +1 -1
- package/dist/chunks/{semaphor-ready-indicator-Bz14Oma5.js → semaphor-ready-indicator-XLBLOJ2V.js} +38374 -39104
- package/dist/chunks/{shelf-drop-preview-context-DBHAkgch.js → shelf-drop-preview-context-DHMa54a-.js} +570 -570
- package/dist/chunks/{source-entity-resolution-BOrmNCEM.js → source-entity-resolution-dUG5VWRm.js} +1 -1
- package/dist/chunks/{switch-Dq8XPFpT.js → switch-ByxH4M7t.js} +3 -3
- package/dist/chunks/{table-export-sheet-C_RvEUyO.js → table-export-sheet-C_GdeTYU.js} +1 -1
- package/dist/chunks/{table-settings-DXj_zXwS.js → table-settings-Imz0FgWi.js} +6 -6
- package/dist/chunks/{temporal-input-presentation-AhLSkGPf.js → temporal-input-presentation-uvNK_tM0.js} +1109 -820
- package/dist/chunks/{token-types-LCYMJ3pa.js → token-types-CQtXUVMy.js} +1 -1
- package/dist/chunks/{upload-Dr_WAxHQ.js → upload-wbR-NVzq.js} +1 -1
- package/dist/chunks/{use-create-flow-overlay-state-BK3YFkfc.js → use-create-flow-overlay-state-CEBaLOKC.js} +6 -6
- package/dist/chunks/{validators-C87JPd-_.js → validators-CXTneCA4.js} +1206 -1579
- package/dist/chunks/{zoned-wall-clock-E35Frf9v.js → zoned-wall-clock-B1n_WjW3.js} +1 -1
- package/dist/dashboard/index.js +2 -2
- package/dist/dashboard-authoring/index.js +2207 -1497
- package/dist/data-app-sdk/index.js +5 -5
- package/dist/data-app-sdk-adapters/index.js +3 -3
- package/dist/data-app-sdk-validation/index.js +6 -6
- package/dist/format-utils/index.js +181 -176
- package/dist/index.js +22 -22
- package/dist/report-runtime-context/index.js +2 -2
- package/dist/style.css +1 -1
- package/dist/surfboard/index.js +2 -2
- package/dist/types/components/editor/editor-aside/utils.d.ts +1 -1
- package/dist/types/components/visual/data-table/types/data-table.d.ts +5 -20
- package/dist/types/index.js +6 -6
- package/dist/types/lib/formatters/canonical-format-adapter.d.ts +2 -29
- package/dist/types/lib/formatters/raw-temporal-presentation.d.ts +0 -2
- package/dist/types/lib/formatters/table-column-settings.d.ts +47 -0
- package/dist/types/lib/matrix-table/matrix-card-adapter.d.ts +10 -188
- package/dist/types/lib/matrix-table/matrix-delivery-policy.d.ts +1 -1
- package/dist/types/lib/matrix-table/matrix-delivery.d.ts +16 -372
- package/dist/types/lib/stores/dashboard-store.d.ts +0 -1
- package/dist/types/lib/stores/editor-store.d.ts +39 -9
- package/dist/types/lib/stores/table-actions.d.ts +9 -3
- package/dist/types/lib/table-formatting/index.d.ts +0 -2
- package/dist/types/lib/table-formatting/table-conditional-formatting-range-source.d.ts +3 -2
- package/dist/types/lib/table-formatting/table-conditional-formatting-range.d.ts +3 -2
- package/dist/types/lib/table-formatting/table-formatting-normalize.d.ts +1 -2
- package/dist/types/lib/table-formatting/table-formatting-render-model.d.ts +9 -0
- package/dist/types/lib/table-formatting/table-formatting-types.d.ts +5 -95
- package/dist/types/lib/table-formatting/table-presentation-fields.d.ts +35 -0
- package/dist/types/lib/types/common-types.d.ts +40 -47
- package/dist/types/lib/types/explorer-types.d.ts +11 -43
- package/dist/types/lib/utils/card-config-utils.d.ts +8 -0
- package/dist/types/lib/utils/card-definition.d.ts +9 -187
- package/dist/types/shared/analytics-protocol/analytics-base-schemas.d.ts +159 -513
- package/dist/types/shared/analytics-protocol/contracts.d.ts +32 -9
- package/dist/types/shared/analytics-protocol/execution-input-schemas.d.ts +108 -980
- package/dist/types/shared/analytics-protocol/field-validation.d.ts +1 -0
- package/dist/types/shared/analytics-protocol/matrix-definition-contract.d.ts +281 -4624
- package/dist/types/shared/analytics-protocol/matrix-operation-contract.d.ts +20 -20
- package/dist/types/shared/analytics-protocol/matrix-operation-request.d.ts +18 -18
- package/dist/types/shared/analytics-protocol/matrix-path-contract.d.ts +40 -40
- package/dist/types/shared/analytics-protocol/matrix-window-contract.d.ts +3 -203
- package/dist/types/shared/analytics-protocol/scalar-value.d.ts +8 -8
- package/dist/types/shared/assistant-context/saved-dashboard-context.d.ts +8 -0
- package/dist/types/shared/assistant-protocol/context.d.ts +69 -69
- package/dist/types/shared/dashboard-authoring/canonical-result-keys.d.ts +13 -0
- package/dist/types/shared/dashboard-authoring/card-export-request.d.ts +4 -1
- package/dist/types/shared/dashboard-authoring/card-formats/sql-date-pattern.d.ts +10 -0
- package/dist/types/shared/dashboard-authoring/card-formats/upgrade-card-formats.d.ts +57 -0
- package/dist/types/shared/dashboard-authoring/changes/dashboard-change.d.ts +24 -24
- package/dist/types/shared/dashboard-authoring/conditional-formatting/editable.d.ts +14 -0
- package/dist/types/shared/dashboard-authoring/conditional-formatting/evaluate.d.ts +16 -0
- package/dist/types/shared/dashboard-authoring/conditional-formatting/index.d.ts +9 -0
- package/dist/types/shared/dashboard-authoring/conditional-formatting/kpi.d.ts +14 -0
- package/dist/types/shared/dashboard-authoring/conditional-formatting/resolve-card-column-ref.d.ts +17 -0
- package/dist/types/shared/dashboard-authoring/conditional-formatting/retain.d.ts +14 -0
- package/dist/types/shared/dashboard-authoring/conditional-formatting/schema.d.ts +4499 -0
- package/dist/types/shared/dashboard-authoring/conditional-formatting/store.d.ts +12 -0
- package/dist/types/shared/dashboard-authoring/conditional-formatting/types.d.ts +151 -0
- package/dist/types/shared/dashboard-authoring/conditional-formatting/upgrade.d.ts +35 -0
- package/dist/types/shared/dashboard-authoring/control-execution-contract.d.ts +62 -62
- package/dist/types/shared/dashboard-authoring/index.d.ts +5 -0
- package/dist/types/shared/dashboard-authoring/matrix-authoring.d.ts +4 -5
- package/dist/types/shared/dashboard-authoring/matrix-delivery.d.ts +24 -736
- package/dist/types/shared/dashboard-authoring/retired-presentation-fields.d.ts +31 -0
- package/dist/types/shared/dashboard-authoring/upgrade-card-presentation.d.ts +14 -0
- package/dist/types/shared/format-utils/formatters/matrix-formatter.d.ts +5 -1
- package/dist/types/shared/format-utils/formatters/number-formatter.d.ts +16 -0
- package/dist/types/shared/format-utils/index.d.ts +2 -0
- package/dist/types/shared/format-utils/matrix-export-presentation.d.ts +10 -366
- package/dist/types/shared/format-utils/raw-temporal.d.ts +15 -1
- package/dist/types/shared/format-utils/resolve-column-format.d.ts +43 -0
- package/dist/types/shared/format-utils/retired-format-adapters.d.ts +68 -0
- package/dist/types/shared/format-utils/semantic-format.d.ts +5 -1
- package/dist/types/shared/format-utils/stored-value-format.d.ts +16 -0
- package/dist/types/shared/format-utils/types/format-types.d.ts +10 -12
- package/package.json +1 -1
- package/dist/chunks/analytics-base-schemas-BUFUoO6G.js +0 -472
- package/dist/chunks/editor-draft-sync-BN5qYHPF.js +0 -15
- package/dist/chunks/filter-reach-copy-B5Y7FHzg.js +0 -3411
- package/dist/types/lib/table-formatting/table-conditional-formatting-evaluator.d.ts +0 -9
- package/dist/types/lib/table-formatting/table-formatting-validation.d.ts +0 -12
package/dist/chunks/{raw-temporal-presentation-BmT7z6NH.js → raw-temporal-presentation-BHm7s-hz.js}
RENAMED
|
@@ -1,164 +1,163 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import
|
|
3
|
-
import { r as
|
|
4
|
-
import "./validators-
|
|
5
|
-
import "./matrix-operation-contract-
|
|
6
|
-
import { v as
|
|
1
|
+
import { r as R, n as S, a as k } from "./global-date-filter-utils-D8365uPH.js";
|
|
2
|
+
import "./analytics-base-schemas-CHLxsPfX.js";
|
|
3
|
+
import { r as E } from "./pivot-result-identity-vS9TSh4f.js";
|
|
4
|
+
import "./validators-CXTneCA4.js";
|
|
5
|
+
import "./matrix-operation-contract-WPv4R-H_.js";
|
|
6
|
+
import { v as x } from "./zoned-wall-clock-B1n_WjW3.js";
|
|
7
7
|
import "zod";
|
|
8
|
-
import { DEFAULT_RESOLVED_VALUE_FORMAT_PREFERENCES as
|
|
9
|
-
import { f as
|
|
10
|
-
const
|
|
11
|
-
function
|
|
8
|
+
import { DEFAULT_RESOLVED_VALUE_FORMAT_PREFERENCES as O } from "../value-format-preferences/index.js";
|
|
9
|
+
import { f as P, M as q, p as h, r as b, c as z, R as L, s as $, v as N } from "./temporal-input-presentation-uvNK_tM0.js";
|
|
10
|
+
const j = "SEMAPHOR_CALCULATED_FIELD";
|
|
11
|
+
function F(e, a, t) {
|
|
12
12
|
if (t && (a === "groupby" || a === "pivotby"))
|
|
13
13
|
return t;
|
|
14
14
|
if (a === "metric" && e.name === "*" && !e.expression)
|
|
15
15
|
return e.alias || "count";
|
|
16
16
|
if (e.alias) return e.alias;
|
|
17
|
-
const
|
|
17
|
+
const n = e.entityName && e.entityName !== j ? e.entityName : void 0;
|
|
18
18
|
if (e.role === "metric") {
|
|
19
19
|
let o = e.aggregate || "metric";
|
|
20
20
|
if (e.expression) {
|
|
21
|
-
const
|
|
21
|
+
const r = e.expression.match(
|
|
22
22
|
/^(COUNT|SUM|AVG|MIN|MAX|MEDIAN|DISTINCT)\s*\(/i
|
|
23
23
|
);
|
|
24
|
-
o =
|
|
24
|
+
o = r ? r[1].toLowerCase() : "expr";
|
|
25
25
|
} else
|
|
26
26
|
o = o.toLowerCase();
|
|
27
|
-
return
|
|
27
|
+
return n && n !== e.name ? `${n}_${e.name}_${o}` : `${e.name}_${o}`;
|
|
28
28
|
}
|
|
29
|
-
return
|
|
30
|
-
}
|
|
31
|
-
function ne(e) {
|
|
32
|
-
return j(e, "detail");
|
|
29
|
+
return n && n !== e.name ? `${n}_${e.name}` : e.name;
|
|
33
30
|
}
|
|
34
31
|
function se(e) {
|
|
32
|
+
return F(e, "detail");
|
|
33
|
+
}
|
|
34
|
+
function B(e) {
|
|
35
35
|
const a = e.label;
|
|
36
36
|
return a && e.labelCount === 1 && (a === e.rawKey || !e.rawKeys.has(a)) ? a : e.rawKey;
|
|
37
37
|
}
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
38
|
+
function ie(e) {
|
|
39
|
+
const a = [
|
|
40
|
+
...(e.groupByColumns ?? []).map((r) => ({ field: r, role: "groupby" })),
|
|
41
|
+
...(e.metricColumns ?? []).map((r) => ({ field: r, role: "metric" })),
|
|
42
|
+
...(e.pivotByColumns ?? []).map((r) => ({ field: r, role: "pivotby" })),
|
|
43
|
+
...(e.detailColumns ?? []).map((r) => ({ field: r, role: "detail" }))
|
|
44
|
+
], t = new Map(a.map(({ field: r, role: i }) => [r, F(r, i)])), n = new Set(t.values()), o = /* @__PURE__ */ new Map();
|
|
45
|
+
for (const { field: r } of a)
|
|
46
|
+
r.label && o.set(r.label, (o.get(r.label) ?? 0) + 1);
|
|
47
|
+
return new Map(
|
|
48
|
+
a.map(({ field: r }) => [
|
|
49
|
+
r,
|
|
50
|
+
B({
|
|
51
|
+
label: r.label,
|
|
52
|
+
labelCount: r.label ? o.get(r.label) ?? 0 : 0,
|
|
53
|
+
rawKey: t.get(r),
|
|
54
|
+
rawKeys: n
|
|
55
|
+
})
|
|
56
|
+
])
|
|
57
|
+
);
|
|
58
|
+
}
|
|
59
|
+
class l extends Error {
|
|
60
|
+
constructor(a, t, n) {
|
|
61
|
+
super(`${a}: ${t}`), this.code = a, this.context = n, Object.setPrototypeOf(this, l.prototype), this.name = "RawTemporalPresentationBoundaryError";
|
|
41
62
|
}
|
|
42
63
|
}
|
|
43
|
-
function
|
|
64
|
+
function I() {
|
|
44
65
|
return { type: "raw_temporal", presentation: { mode: "auto" } };
|
|
45
66
|
}
|
|
46
|
-
function
|
|
67
|
+
function U(e) {
|
|
47
68
|
if (e.locale || e.relative || e.timezone && e.timezone !== "auto" || e.sourceTimezone && e.sourceTimezone !== "auto" || e.prefix || e.suffix)
|
|
48
|
-
throw new
|
|
69
|
+
throw new l(
|
|
49
70
|
"invalid_raw_temporal_format",
|
|
50
71
|
"Activated raw temporal presentation contains unsupported locale, relative-time, timezone, prefix, or suffix settings."
|
|
51
72
|
);
|
|
52
73
|
}
|
|
53
|
-
function
|
|
74
|
+
function V(e) {
|
|
54
75
|
const a = e.format;
|
|
55
|
-
if ((a == null ? void 0 : a.type) === "date"
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
dialect: "semaphor_tokens",
|
|
61
|
-
pattern: a.pattern
|
|
62
|
-
}
|
|
63
|
-
};
|
|
76
|
+
if ((a == null ? void 0 : a.type) === "date") {
|
|
77
|
+
U(a);
|
|
78
|
+
const t = $(a);
|
|
79
|
+
if (t.mode !== "auto") return { type: "raw_temporal", presentation: t };
|
|
80
|
+
}
|
|
64
81
|
if (a)
|
|
65
|
-
throw new
|
|
82
|
+
throw new l(
|
|
66
83
|
"invalid_raw_temporal_format",
|
|
67
84
|
`Raw temporal detail field "${e.id}" has an incompatible authored format.`,
|
|
68
85
|
{ fieldId: e.id }
|
|
69
86
|
);
|
|
70
|
-
|
|
71
|
-
if (!e.customFormat)
|
|
72
|
-
throw new m(
|
|
73
|
-
"invalid_raw_temporal_format",
|
|
74
|
-
`Raw temporal detail field "${e.id}" selects a custom pattern but has no customFormat.`,
|
|
75
|
-
{ fieldId: e.id }
|
|
76
|
-
);
|
|
77
|
-
return {
|
|
78
|
-
type: "raw_temporal",
|
|
79
|
-
presentation: {
|
|
80
|
-
mode: "pattern",
|
|
81
|
-
dialect: "semaphor_tokens",
|
|
82
|
-
pattern: e.customFormat
|
|
83
|
-
}
|
|
84
|
-
};
|
|
85
|
-
}
|
|
86
|
-
return e.dateFormat ? {
|
|
87
|
-
type: "raw_temporal",
|
|
88
|
-
presentation: {
|
|
89
|
-
mode: "pattern",
|
|
90
|
-
dialect: "semaphor_tokens",
|
|
91
|
-
pattern: e.dateFormat
|
|
92
|
-
}
|
|
93
|
-
} : k();
|
|
87
|
+
return I();
|
|
94
88
|
}
|
|
95
89
|
function D(e) {
|
|
96
|
-
var
|
|
90
|
+
var i;
|
|
97
91
|
if (e != null && e.useRelativeTime) return;
|
|
98
|
-
if (!e) return
|
|
99
|
-
if (e.useCustomFormat && !((
|
|
100
|
-
throw new
|
|
92
|
+
if (!e) return I();
|
|
93
|
+
if (e.useCustomFormat && !((i = e.customFormat) != null && i.trim()))
|
|
94
|
+
throw new l(
|
|
101
95
|
"invalid_raw_temporal_format",
|
|
102
96
|
"Declared SQL temporal presentation selects a custom pattern but has no customFormat.",
|
|
103
97
|
{ reason: "missing_declared_sql_custom_date_format" }
|
|
104
98
|
);
|
|
105
|
-
const a = e.useCustomFormat && e.customFormat ? e.customFormat : e.format, t = e.timezone,
|
|
106
|
-
sourceTimezone:
|
|
99
|
+
const a = e.useCustomFormat && e.customFormat ? e.customFormat : e.format, t = e.timezone, n = e.sourceTimezone, o = t && t !== "auto" ? { timezone: t } : void 0, r = {
|
|
100
|
+
sourceTimezone: n && n !== "auto" ? n : "UTC"
|
|
107
101
|
};
|
|
108
|
-
return a ? {
|
|
102
|
+
return !a && e.preset ? {
|
|
103
|
+
type: "raw_temporal",
|
|
104
|
+
...o,
|
|
105
|
+
...r,
|
|
106
|
+
presentation: { mode: "preset", preset: e.preset }
|
|
107
|
+
} : a ? {
|
|
109
108
|
type: "raw_temporal",
|
|
110
109
|
...o,
|
|
111
|
-
...
|
|
110
|
+
...r,
|
|
112
111
|
presentation: {
|
|
113
112
|
mode: "pattern",
|
|
114
|
-
dialect: "date_fns",
|
|
113
|
+
dialect: e.useCustomFormat ? "date_fns" : e.dialect ?? "date_fns",
|
|
115
114
|
pattern: a
|
|
116
115
|
}
|
|
117
116
|
} : {
|
|
118
117
|
type: "raw_temporal",
|
|
119
118
|
...o,
|
|
120
|
-
...
|
|
119
|
+
...r,
|
|
121
120
|
presentation: { mode: "auto" }
|
|
122
121
|
};
|
|
123
122
|
}
|
|
124
|
-
function
|
|
123
|
+
function ce(e) {
|
|
125
124
|
return e === "instant" ? "yyyy-MM-dd'T'HH:mm:ssXXX" : e === "wall_datetime" ? "yyyy-MM-dd'T'HH:mm:ss" : "yyyy-MM-dd";
|
|
126
125
|
}
|
|
127
|
-
function
|
|
128
|
-
|
|
126
|
+
function me(e) {
|
|
127
|
+
N({
|
|
129
128
|
dialect: "date_fns",
|
|
130
129
|
pattern: e.pattern,
|
|
131
130
|
valueKind: e.valueKind
|
|
132
131
|
});
|
|
133
132
|
}
|
|
134
|
-
function
|
|
133
|
+
function Q(e) {
|
|
135
134
|
const a = D(e.settings);
|
|
136
135
|
if (!a)
|
|
137
|
-
throw new
|
|
136
|
+
throw new l(
|
|
138
137
|
"invalid_raw_temporal_format",
|
|
139
138
|
"Relative-time SQL presentation does not have an absolute date preview."
|
|
140
139
|
);
|
|
141
|
-
const t = e.valueKind ?? (a.presentation.mode === "pattern" ? "instant" : "date"),
|
|
140
|
+
const t = e.valueKind ?? (a.presentation.mode === "pattern" ? "instant" : "date"), n = {
|
|
142
141
|
kind: "raw_temporal",
|
|
143
142
|
valueKind: t
|
|
144
|
-
}, o = e.value ?? (t === "date" ? "2023-05-15" : t === "wall_datetime" ? "2023-05-15T14:30:45" : "2023-05-15T14:30:45Z"),
|
|
145
|
-
metadata:
|
|
143
|
+
}, o = e.value ?? (t === "date" ? "2023-05-15" : t === "wall_datetime" ? "2023-05-15T14:30:45" : "2023-05-15T14:30:45Z"), r = h({
|
|
144
|
+
metadata: n,
|
|
146
145
|
format: b({
|
|
147
146
|
format: a,
|
|
148
147
|
preferences: e.preferences,
|
|
149
148
|
calendar: { tz: e.calendarTimezone }
|
|
150
149
|
})
|
|
151
150
|
})(o);
|
|
152
|
-
if (!
|
|
153
|
-
throw new
|
|
151
|
+
if (!r.ok)
|
|
152
|
+
throw new l(
|
|
154
153
|
"invalid_raw_temporal_format",
|
|
155
|
-
|
|
154
|
+
r.diagnostic.message
|
|
156
155
|
);
|
|
157
|
-
return
|
|
156
|
+
return r.text;
|
|
158
157
|
}
|
|
159
|
-
function
|
|
158
|
+
function de(e) {
|
|
160
159
|
try {
|
|
161
|
-
return { ok: !0, text:
|
|
160
|
+
return { ok: !0, text: Q(e) };
|
|
162
161
|
} catch (a) {
|
|
163
162
|
return {
|
|
164
163
|
ok: !1,
|
|
@@ -166,54 +165,12 @@ function me(e) {
|
|
|
166
165
|
};
|
|
167
166
|
}
|
|
168
167
|
}
|
|
169
|
-
function
|
|
168
|
+
function H(e) {
|
|
170
169
|
var t;
|
|
171
170
|
const a = e.effectiveCardConfig ?? e.card.config;
|
|
172
|
-
return R(e.card, a) === "freeform" && !!((t = e.card.sql) != null && t.trim()) && !
|
|
173
|
-
}
|
|
174
|
-
function Q(e) {
|
|
175
|
-
var a, t;
|
|
176
|
-
return e.type !== "table" && e.type !== "detailTable" || !I({ card: e }) ? !1 : Object.values(
|
|
177
|
-
((t = (a = e.preferences) == null ? void 0 : a.tablePrefs) == null ? void 0 : t.columnSettingsMap) || {}
|
|
178
|
-
).some(
|
|
179
|
-
(r) => {
|
|
180
|
-
var o, n, s;
|
|
181
|
-
return r.type === "date" && ((o = r.dateFormat) == null ? void 0 : o.useRelativeTime) !== !0 && ((n = r.dateFormat) == null ? void 0 : n.useCustomFormat) === !0 && !((s = r.dateFormat.customFormat) != null && s.trim());
|
|
182
|
-
}
|
|
183
|
-
);
|
|
184
|
-
}
|
|
185
|
-
function ce(e) {
|
|
186
|
-
var t, r, o;
|
|
187
|
-
if (!Q(e)) return e;
|
|
188
|
-
const a = ((r = (t = e.preferences) == null ? void 0 : t.tablePrefs) == null ? void 0 : r.columnSettingsMap) || {};
|
|
189
|
-
return {
|
|
190
|
-
...e,
|
|
191
|
-
preferences: {
|
|
192
|
-
...e.preferences,
|
|
193
|
-
tablePrefs: {
|
|
194
|
-
...(o = e.preferences) == null ? void 0 : o.tablePrefs,
|
|
195
|
-
columnSettingsMap: Object.fromEntries(
|
|
196
|
-
Object.entries(a).map(([n, s]) => {
|
|
197
|
-
var l, p, i;
|
|
198
|
-
return [
|
|
199
|
-
n,
|
|
200
|
-
s.type === "date" && ((l = s.dateFormat) == null ? void 0 : l.useRelativeTime) !== !0 && ((p = s.dateFormat) == null ? void 0 : p.useCustomFormat) === !0 && !((i = s.dateFormat.customFormat) != null && i.trim()) ? {
|
|
201
|
-
...s,
|
|
202
|
-
dateFormat: {
|
|
203
|
-
...s.dateFormat,
|
|
204
|
-
format: "",
|
|
205
|
-
useCustomFormat: !1,
|
|
206
|
-
customFormat: ""
|
|
207
|
-
}
|
|
208
|
-
} : s
|
|
209
|
-
];
|
|
210
|
-
})
|
|
211
|
-
)
|
|
212
|
-
}
|
|
213
|
-
}
|
|
214
|
-
};
|
|
171
|
+
return R(e.card, a) === "freeform" && !!((t = e.card.sql) != null && t.trim()) && !S(e.card.python || "").trim();
|
|
215
172
|
}
|
|
216
|
-
function
|
|
173
|
+
function X() {
|
|
217
174
|
return {
|
|
218
175
|
activatedColumnKeys: /* @__PURE__ */ new Set(),
|
|
219
176
|
byColumnKey: /* @__PURE__ */ new Map(),
|
|
@@ -223,118 +180,118 @@ function B() {
|
|
|
223
180
|
function T(e, a) {
|
|
224
181
|
return e === void 0 ? { kind: "invalid", error: a } : {
|
|
225
182
|
kind: "invalid",
|
|
226
|
-
error: e instanceof
|
|
183
|
+
error: e instanceof l ? e : e instanceof L ? new l(
|
|
227
184
|
e.code,
|
|
228
185
|
e.message,
|
|
229
186
|
a.context
|
|
230
|
-
) : new
|
|
187
|
+
) : new l(
|
|
231
188
|
a.code,
|
|
232
189
|
e instanceof Error ? e.message : a.message,
|
|
233
190
|
a.context
|
|
234
191
|
)
|
|
235
192
|
};
|
|
236
193
|
}
|
|
237
|
-
function
|
|
194
|
+
function G(e) {
|
|
238
195
|
var o;
|
|
239
196
|
if (e.cardType !== "detailTable" || e.resultOwner !== "config")
|
|
240
197
|
return { kind: "inactive" };
|
|
241
198
|
if (!e.result) return { kind: "loading" };
|
|
242
|
-
const { records: a, columns: t, columnKeyMap:
|
|
243
|
-
if (!Array.isArray(a) || !Array.isArray(t) || !
|
|
199
|
+
const { records: a, columns: t, columnKeyMap: n } = e.result;
|
|
200
|
+
if (!Array.isArray(a) || !Array.isArray(t) || !n)
|
|
244
201
|
return T(
|
|
245
202
|
void 0,
|
|
246
|
-
new
|
|
203
|
+
new l(
|
|
247
204
|
"missing_raw_temporal_result_contract",
|
|
248
205
|
"Activated raw temporal detail results require records, columns, and columnKeyMap atomically."
|
|
249
206
|
)
|
|
250
207
|
);
|
|
251
208
|
try {
|
|
252
|
-
const
|
|
253
|
-
if (
|
|
254
|
-
const
|
|
209
|
+
const r = t.filter((d) => d.rawTemporal);
|
|
210
|
+
if (r.length === 0) return { kind: "inactive" };
|
|
211
|
+
const i = new Map(
|
|
255
212
|
(((o = e.effectiveCardConfig) == null ? void 0 : o.detailColumns) || []).map((d) => [
|
|
256
213
|
d.id,
|
|
257
214
|
d
|
|
258
215
|
])
|
|
259
|
-
),
|
|
260
|
-
for (const d of
|
|
261
|
-
const _ = Array.from(
|
|
262
|
-
([
|
|
263
|
-
const
|
|
264
|
-
|
|
265
|
-
|
|
216
|
+
), c = /* @__PURE__ */ new Map(), v = /* @__PURE__ */ new Map();
|
|
217
|
+
for (const d of r) {
|
|
218
|
+
const _ = Array.from(i).flatMap(
|
|
219
|
+
([y, A]) => {
|
|
220
|
+
const g = E(
|
|
221
|
+
n,
|
|
222
|
+
y,
|
|
266
223
|
"detail"
|
|
267
224
|
);
|
|
268
|
-
return
|
|
225
|
+
return g && g.role === "detail" && (g.outputKey ?? g.rawKey) === d.key ? [{ field: A, binding: g }] : [];
|
|
269
226
|
}
|
|
270
|
-
),
|
|
271
|
-
if (!
|
|
272
|
-
throw new
|
|
227
|
+
), m = _.length === 1 ? _[0] : null;
|
|
228
|
+
if (!m || typeof m.binding.rawKey != "string" || m.binding.rawKey.trim().length === 0 || m.binding.outputKey !== void 0 && (typeof m.binding.outputKey != "string" || m.binding.outputKey.trim().length === 0))
|
|
229
|
+
throw new l(
|
|
273
230
|
"missing_raw_temporal_column_binding",
|
|
274
231
|
`Raw temporal result column "${d.key}" does not have one valid exact detail result binding.`,
|
|
275
232
|
{ columnKey: d.key }
|
|
276
233
|
);
|
|
277
|
-
const { field: u, binding:
|
|
234
|
+
const { field: u, binding: C } = m, f = C.outputKey ?? C.rawKey, p = x(d, {
|
|
278
235
|
metadataRequired: !0
|
|
279
236
|
});
|
|
280
|
-
if (!
|
|
281
|
-
throw new
|
|
237
|
+
if (!p)
|
|
238
|
+
throw new l(
|
|
282
239
|
"invalid_raw_temporal_metadata",
|
|
283
240
|
`Raw temporal result column "${f}" has no metadata.`,
|
|
284
241
|
{ fieldId: u.id, columnKey: f }
|
|
285
242
|
);
|
|
286
|
-
const
|
|
287
|
-
format:
|
|
243
|
+
const w = b({
|
|
244
|
+
format: V(u),
|
|
288
245
|
preferences: e.preferences,
|
|
289
246
|
calendar: e.calendar
|
|
290
|
-
}),
|
|
247
|
+
}), K = {
|
|
291
248
|
fieldId: u.id,
|
|
292
249
|
columnKey: f,
|
|
293
|
-
metadata:
|
|
294
|
-
format:
|
|
295
|
-
formatValue:
|
|
250
|
+
metadata: p,
|
|
251
|
+
format: w,
|
|
252
|
+
formatValue: h({ metadata: p, format: w })
|
|
296
253
|
};
|
|
297
|
-
for (let
|
|
298
|
-
if (!Object.prototype.hasOwnProperty.call(a[
|
|
299
|
-
throw new
|
|
254
|
+
for (let y = 0; y < a.length; y += 1)
|
|
255
|
+
if (!Object.prototype.hasOwnProperty.call(a[y], f) || a[y][f] === void 0)
|
|
256
|
+
throw new l(
|
|
300
257
|
"missing_raw_temporal_result_contract",
|
|
301
|
-
`Raw temporal result row ${
|
|
258
|
+
`Raw temporal result row ${y} is missing column "${f}".`,
|
|
302
259
|
{ fieldId: u.id, columnKey: f }
|
|
303
260
|
);
|
|
304
|
-
|
|
261
|
+
c.set(f, K), v.set(u.id, K);
|
|
305
262
|
}
|
|
306
|
-
const
|
|
307
|
-
activatedColumnKeys: new Set(
|
|
308
|
-
byColumnKey:
|
|
309
|
-
byFieldId:
|
|
263
|
+
const s = {
|
|
264
|
+
activatedColumnKeys: new Set(c.keys()),
|
|
265
|
+
byColumnKey: c,
|
|
266
|
+
byFieldId: v
|
|
310
267
|
};
|
|
311
|
-
return a.length === 0 ? { kind: "loaded_empty", presentation:
|
|
312
|
-
} catch (
|
|
268
|
+
return a.length === 0 ? { kind: "loaded_empty", presentation: s } : { kind: "loaded_valid", presentation: s };
|
|
269
|
+
} catch (r) {
|
|
313
270
|
return T(
|
|
314
|
-
|
|
315
|
-
new
|
|
271
|
+
r,
|
|
272
|
+
new l(
|
|
316
273
|
"invalid_raw_temporal_metadata",
|
|
317
274
|
"Activated raw temporal result metadata is invalid."
|
|
318
275
|
)
|
|
319
276
|
);
|
|
320
277
|
}
|
|
321
278
|
}
|
|
322
|
-
function
|
|
323
|
-
var
|
|
279
|
+
function Y(e) {
|
|
280
|
+
var n;
|
|
324
281
|
const a = e.effectiveCardConfig ?? e.card.config, t = R(
|
|
325
282
|
e.card,
|
|
326
283
|
a
|
|
327
284
|
);
|
|
328
285
|
if (e.card.type === "detailTable" && t === "config") {
|
|
329
|
-
const
|
|
330
|
-
return
|
|
286
|
+
const o = !!((n = e.columns) != null && n.some((r) => r.rawTemporal));
|
|
287
|
+
return o && e.records !== void 0 && !e.columnKeyMap ? {
|
|
331
288
|
kind: "invalid",
|
|
332
|
-
error: new
|
|
289
|
+
error: new l(
|
|
333
290
|
"missing_raw_temporal_result_contract",
|
|
334
291
|
"Activated raw temporal detail results require records, columns, and columnKeyMap atomically."
|
|
335
292
|
)
|
|
336
|
-
} : e.records !== void 0 && !
|
|
337
|
-
|
|
293
|
+
} : e.records !== void 0 && !o ? { kind: "inactive" } : M(
|
|
294
|
+
G({
|
|
338
295
|
cardType: e.card.type,
|
|
339
296
|
resultOwner: t,
|
|
340
297
|
effectiveCardConfig: a,
|
|
@@ -349,51 +306,51 @@ function X(e) {
|
|
|
349
306
|
e
|
|
350
307
|
);
|
|
351
308
|
}
|
|
352
|
-
return
|
|
353
|
-
|
|
309
|
+
return M(
|
|
310
|
+
Z({
|
|
354
311
|
resultOwner: t,
|
|
355
312
|
sql: e.card.sql,
|
|
356
|
-
normalizedPython:
|
|
313
|
+
normalizedPython: S(
|
|
357
314
|
e.card.python || ""
|
|
358
315
|
),
|
|
359
316
|
records: e.records,
|
|
360
317
|
columns: e.columns,
|
|
361
|
-
columnSettings: (
|
|
318
|
+
columnSettings: k(e.card),
|
|
362
319
|
preferences: e.preferences,
|
|
363
320
|
calendar: e.calendar
|
|
364
321
|
}),
|
|
365
322
|
e
|
|
366
323
|
);
|
|
367
324
|
}
|
|
368
|
-
function
|
|
369
|
-
var
|
|
325
|
+
function ue(e) {
|
|
326
|
+
var n;
|
|
370
327
|
const a = e.effectiveCardConfig ?? e.card.config, t = R(
|
|
371
328
|
e.card,
|
|
372
329
|
a
|
|
373
330
|
);
|
|
374
|
-
return e.card.type === "detailTable" && t === "config" ? !!((
|
|
375
|
-
(
|
|
331
|
+
return e.card.type === "detailTable" && t === "config" ? !!((n = e.columns) != null && n.some((o) => o.rawTemporal)) : H(e) ? Object.values(
|
|
332
|
+
k(e.card)
|
|
376
333
|
).some(
|
|
377
|
-
(
|
|
378
|
-
var
|
|
379
|
-
return
|
|
334
|
+
(o) => {
|
|
335
|
+
var r;
|
|
336
|
+
return o.type === "date" && !((r = o.dateFormat) != null && r.useRelativeTime);
|
|
380
337
|
}
|
|
381
338
|
) : !1;
|
|
382
339
|
}
|
|
383
|
-
function
|
|
340
|
+
function M(e, a) {
|
|
384
341
|
if (!a.executionSnapshot || e.kind === "inactive" || e.kind === "loading" || e.kind === "invalid")
|
|
385
342
|
return e;
|
|
386
343
|
if (!a.dashboardId)
|
|
387
344
|
return {
|
|
388
345
|
kind: "invalid",
|
|
389
|
-
error: new
|
|
346
|
+
error: new l(
|
|
390
347
|
"missing_raw_temporal_result_contract",
|
|
391
348
|
"A dashboard ID is required to resolve the captured raw temporal presentation."
|
|
392
349
|
)
|
|
393
350
|
};
|
|
394
|
-
const t = /* @__PURE__ */ new Map(),
|
|
351
|
+
const t = /* @__PURE__ */ new Map(), n = /* @__PURE__ */ new Map();
|
|
395
352
|
for (const o of e.presentation.activatedColumnKeys) {
|
|
396
|
-
const
|
|
353
|
+
const r = P({
|
|
397
354
|
snapshot: a.executionSnapshot,
|
|
398
355
|
scope: {
|
|
399
356
|
dashboardId: a.dashboardId,
|
|
@@ -402,136 +359,136 @@ function K(e, a) {
|
|
|
402
359
|
},
|
|
403
360
|
target: { kind: "column", columnKey: o }
|
|
404
361
|
});
|
|
405
|
-
if (!
|
|
362
|
+
if (!r)
|
|
406
363
|
return {
|
|
407
364
|
kind: "invalid",
|
|
408
|
-
error: new
|
|
365
|
+
error: new q(o)
|
|
409
366
|
};
|
|
410
|
-
const
|
|
411
|
-
if (!
|
|
412
|
-
const
|
|
413
|
-
...
|
|
414
|
-
format:
|
|
415
|
-
formatValue:
|
|
416
|
-
metadata:
|
|
417
|
-
format:
|
|
367
|
+
const i = e.presentation.byColumnKey.get(o);
|
|
368
|
+
if (!i) continue;
|
|
369
|
+
const c = {
|
|
370
|
+
...i,
|
|
371
|
+
format: r,
|
|
372
|
+
formatValue: h({
|
|
373
|
+
metadata: i.metadata,
|
|
374
|
+
format: r
|
|
418
375
|
})
|
|
419
376
|
};
|
|
420
|
-
t.set(
|
|
377
|
+
t.set(i.columnKey, c), i.fieldId && n.set(i.fieldId, c);
|
|
421
378
|
}
|
|
422
379
|
return {
|
|
423
380
|
...e,
|
|
424
381
|
presentation: {
|
|
425
382
|
activatedColumnKeys: e.presentation.activatedColumnKeys,
|
|
426
383
|
byColumnKey: t,
|
|
427
|
-
byFieldId:
|
|
384
|
+
byFieldId: n
|
|
428
385
|
}
|
|
429
386
|
};
|
|
430
387
|
}
|
|
431
|
-
function
|
|
432
|
-
var t,
|
|
433
|
-
if (e.resultOwner !== "freeform" || !((t = e.sql) != null && t.trim()) || (
|
|
388
|
+
function Z(e) {
|
|
389
|
+
var t, n;
|
|
390
|
+
if (e.resultOwner !== "freeform" || !((t = e.sql) != null && t.trim()) || (n = e.normalizedPython) != null && n.trim())
|
|
434
391
|
return { kind: "inactive" };
|
|
435
392
|
const a = Object.entries(
|
|
436
393
|
e.columnSettings || {}
|
|
437
394
|
).filter(
|
|
438
395
|
([, o]) => {
|
|
439
|
-
var
|
|
440
|
-
return o.type === "date" && !((
|
|
396
|
+
var r;
|
|
397
|
+
return o.type === "date" && !((r = o.dateFormat) != null && r.useRelativeTime);
|
|
441
398
|
}
|
|
442
399
|
);
|
|
443
400
|
if (a.length === 0) return { kind: "inactive" };
|
|
444
401
|
if (!e.records) return { kind: "loading" };
|
|
445
402
|
try {
|
|
446
|
-
const o = /* @__PURE__ */ new Map(),
|
|
447
|
-
a.map(([
|
|
448
|
-
),
|
|
449
|
-
for (const [
|
|
403
|
+
const o = /* @__PURE__ */ new Map(), r = new Set(
|
|
404
|
+
a.map(([s]) => s)
|
|
405
|
+
), i = /* @__PURE__ */ new Map(), c = [...e.columns || []];
|
|
406
|
+
for (const [s, d] of a) {
|
|
450
407
|
const _ = D(
|
|
451
408
|
d.dateFormat
|
|
452
409
|
);
|
|
453
410
|
if (!_) continue;
|
|
454
|
-
const
|
|
455
|
-
columnKey:
|
|
456
|
-
values: e.records.map((
|
|
457
|
-
if (!Object.prototype.hasOwnProperty.call(
|
|
458
|
-
throw new
|
|
411
|
+
const m = z({
|
|
412
|
+
columnKey: s,
|
|
413
|
+
values: e.records.map((p) => {
|
|
414
|
+
if (!Object.prototype.hasOwnProperty.call(p, s))
|
|
415
|
+
throw new l(
|
|
459
416
|
"missing_raw_temporal_result_contract",
|
|
460
|
-
`Declared SQL temporal column "${
|
|
461
|
-
{ columnKey:
|
|
417
|
+
`Declared SQL temporal column "${s}" is absent from a physical result row.`,
|
|
418
|
+
{ columnKey: s }
|
|
462
419
|
);
|
|
463
|
-
const
|
|
464
|
-
return
|
|
420
|
+
const w = p[s];
|
|
421
|
+
return w === null || typeof w == "string" ? w : String(w);
|
|
465
422
|
})
|
|
466
423
|
});
|
|
467
|
-
if (
|
|
468
|
-
let u =
|
|
469
|
-
(
|
|
424
|
+
if (i.set(s, m), m.status !== "classified") continue;
|
|
425
|
+
let u = c.findIndex(
|
|
426
|
+
(p) => p.key === s
|
|
470
427
|
);
|
|
471
428
|
if (e.columns && u < 0)
|
|
472
|
-
throw new
|
|
429
|
+
throw new l(
|
|
473
430
|
"missing_raw_temporal_result_contract",
|
|
474
|
-
`Classified SQL temporal column "${
|
|
475
|
-
{ columnKey:
|
|
431
|
+
`Classified SQL temporal column "${s}" is absent from result columns.`,
|
|
432
|
+
{ columnKey: s }
|
|
476
433
|
);
|
|
477
|
-
u < 0 && (u =
|
|
478
|
-
key:
|
|
479
|
-
name:
|
|
480
|
-
label:
|
|
434
|
+
u < 0 && (u = c.length, c.push({
|
|
435
|
+
key: s,
|
|
436
|
+
name: s,
|
|
437
|
+
label: s,
|
|
481
438
|
role: "dimension",
|
|
482
439
|
dataType: "string"
|
|
483
440
|
}));
|
|
484
|
-
const
|
|
485
|
-
...
|
|
441
|
+
const C = {
|
|
442
|
+
...c[u],
|
|
486
443
|
role: "date",
|
|
487
|
-
dataType:
|
|
488
|
-
rawTemporal:
|
|
444
|
+
dataType: m.metadata.valueKind === "date" ? "date" : "datetime",
|
|
445
|
+
rawTemporal: m.metadata
|
|
489
446
|
};
|
|
490
|
-
|
|
447
|
+
x(C, {
|
|
491
448
|
metadataRequired: !0
|
|
492
|
-
}),
|
|
449
|
+
}), c[u] = C;
|
|
493
450
|
const f = b({
|
|
494
451
|
format: _,
|
|
495
452
|
preferences: e.preferences,
|
|
496
453
|
calendar: e.calendar
|
|
497
454
|
});
|
|
498
|
-
o.set(
|
|
499
|
-
columnKey:
|
|
500
|
-
metadata:
|
|
455
|
+
o.set(s, {
|
|
456
|
+
columnKey: s,
|
|
457
|
+
metadata: m.metadata,
|
|
501
458
|
format: f,
|
|
502
|
-
formatValue:
|
|
503
|
-
metadata:
|
|
459
|
+
formatValue: h({
|
|
460
|
+
metadata: m.metadata,
|
|
504
461
|
format: f
|
|
505
462
|
})
|
|
506
463
|
});
|
|
507
464
|
}
|
|
508
|
-
const
|
|
509
|
-
...
|
|
510
|
-
activatedColumnKeys:
|
|
465
|
+
const v = {
|
|
466
|
+
...X(),
|
|
467
|
+
activatedColumnKeys: r,
|
|
511
468
|
byColumnKey: o
|
|
512
469
|
};
|
|
513
470
|
return e.records.length === 0 ? {
|
|
514
471
|
kind: "loaded_empty",
|
|
515
|
-
presentation:
|
|
516
|
-
adaptedColumns:
|
|
517
|
-
sqlClassifications:
|
|
472
|
+
presentation: v,
|
|
473
|
+
adaptedColumns: c,
|
|
474
|
+
sqlClassifications: i
|
|
518
475
|
} : {
|
|
519
476
|
kind: "loaded_valid",
|
|
520
|
-
presentation:
|
|
521
|
-
adaptedColumns:
|
|
522
|
-
sqlClassifications:
|
|
477
|
+
presentation: v,
|
|
478
|
+
adaptedColumns: c,
|
|
479
|
+
sqlClassifications: i
|
|
523
480
|
};
|
|
524
481
|
} catch (o) {
|
|
525
482
|
return T(
|
|
526
483
|
o,
|
|
527
|
-
new
|
|
484
|
+
new l(
|
|
528
485
|
"invalid_raw_temporal_format",
|
|
529
486
|
"Declared SQL raw temporal presentation is invalid."
|
|
530
487
|
)
|
|
531
488
|
);
|
|
532
489
|
}
|
|
533
490
|
}
|
|
534
|
-
function
|
|
491
|
+
function fe(e) {
|
|
535
492
|
if (e.value !== null && typeof e.value != "string")
|
|
536
493
|
return {
|
|
537
494
|
value: e.value,
|
|
@@ -548,37 +505,36 @@ function ue(e) {
|
|
|
548
505
|
const a = e.presentation.formatValue(e.value);
|
|
549
506
|
return { value: e.value, label: a.text, result: a };
|
|
550
507
|
}
|
|
551
|
-
function
|
|
508
|
+
function pe(e) {
|
|
552
509
|
if (!e.result || typeof e.result != "object") return !1;
|
|
553
510
|
const a = e.result;
|
|
554
511
|
if (e.expectedResultOwner !== void 0 && a.resultOwner !== e.expectedResultOwner || !Array.isArray(a.records)) return !1;
|
|
555
|
-
const t =
|
|
512
|
+
const t = Y({
|
|
556
513
|
card: e.card,
|
|
557
514
|
effectiveCardConfig: e.effectiveCardConfig,
|
|
558
515
|
records: a.records,
|
|
559
516
|
columns: a.columns,
|
|
560
517
|
columnKeyMap: a.columnKeyMap,
|
|
561
|
-
preferences:
|
|
518
|
+
preferences: O,
|
|
562
519
|
calendar: { tz: "UTC" }
|
|
563
520
|
});
|
|
564
521
|
return t.kind === "inactive" || t.kind === "loaded_empty" || t.kind === "loaded_valid";
|
|
565
522
|
}
|
|
566
523
|
export {
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
ie as v
|
|
524
|
+
l as R,
|
|
525
|
+
V as a,
|
|
526
|
+
D as b,
|
|
527
|
+
F as c,
|
|
528
|
+
se as d,
|
|
529
|
+
B as e,
|
|
530
|
+
G as f,
|
|
531
|
+
Y as g,
|
|
532
|
+
ue as h,
|
|
533
|
+
pe as i,
|
|
534
|
+
ce as j,
|
|
535
|
+
de as k,
|
|
536
|
+
H as l,
|
|
537
|
+
fe as p,
|
|
538
|
+
ie as r,
|
|
539
|
+
me as v
|
|
584
540
|
};
|