react-semaphor 0.1.568 → 0.1.570
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/README.md +0 -7
- package/dist/analytics-protocol/index.js +434 -454
- package/dist/appearance/index.js +6 -3
- package/dist/appearance-runtime/index.js +1 -1
- package/dist/assistant-context/index.js +1 -1
- package/dist/brand-studio/index.js +572 -436
- package/dist/briefings/index.js +4 -4
- package/dist/chunks/appearance-context-BwBp25ZG.js +162 -0
- package/dist/chunks/appearance-runtime-provider-BRHYELkC.js +80 -0
- package/dist/chunks/assistant-chat-B-Ddyy8b.js +5940 -0
- package/dist/chunks/{bookmark-impact-CJ-65omV.js → bookmark-impact-DCYD-6Fr.js} +2 -2
- package/dist/chunks/{bookmark-state-Du3s13_V.js → bookmark-state-CflS88gq.js} +251 -250
- package/dist/chunks/brand-B4BdpAB_.js +54 -0
- package/dist/chunks/{card-filter-builder-BBuB99GZ.js → card-filter-builder-0VvKmRst.js} +992 -991
- package/dist/chunks/{comparison-window-caption-CMLb3mut.js → comparison-window-caption-PtcDWvkN.js} +252 -253
- package/dist/chunks/{dashboard-YnWZC4dK.js → dashboard-DxGIr1vZ.js} +1 -1
- package/dist/chunks/{dashboard-briefing-launcher-BF89TU2h.js → dashboard-briefing-launcher-B-quOOOQ.js} +253 -253
- package/dist/chunks/{dashboard-controls-atHc1EjP.js → dashboard-controls-Caodx80b.js} +288 -285
- package/dist/chunks/dashboard-json-Ct-AGDHF.js +66 -0
- package/dist/chunks/{dates-CKO05ino.js → dates-B9mL8BHE.js} +16 -15
- package/dist/chunks/edit-Bpdh_P_a.js +226 -0
- package/dist/chunks/{edit-dashboard-visual-DdmTfn-J.js → edit-dashboard-visual-DeDTuYB5.js} +2257 -2270
- package/dist/chunks/{filter-reach-copy-jZGzK_IH.js → filter-reach-copy-BSY33ro5.js} +1440 -1301
- package/dist/chunks/filter-value-text-DvvSNlho.js +146 -0
- package/dist/chunks/index-BVKzKl5d.js +90 -0
- package/dist/chunks/{index-RNaTnE3m.js → index-CV_Kzou0.js} +233 -223
- package/dist/chunks/{index-CPNZW0mu.js → index-y3HUzRNk.js} +76 -77
- package/dist/chunks/{layout-grid-0hIlqEtk.js → layout-grid-8rR-LPTk.js} +1 -1
- package/dist/chunks/{list-filter-DkgoCeBm.js → list-filter-C1-uTgjR.js} +1 -1
- package/dist/chunks/matrix-analytical-definition-dkS8szLM.js +1253 -0
- package/dist/chunks/matrix-member-presentation-DRa-9e6Q.js +169 -0
- package/dist/chunks/{matrix-operation-contract-Eb6elidS.js → matrix-operation-contract-DCVinw1o.js} +122 -122
- package/dist/chunks/{metric-comparison-ChXUFaZu.js → metric-comparison-n9NsIa-2.js} +175 -128
- package/dist/chunks/paintbrush-aR17Z3C9.js +27 -0
- package/dist/chunks/{palette-4vf2BEEg.js → palette-a5FCZKFI.js} +1 -1
- package/dist/chunks/{_commonjsHelpers-DimLPMtv.js → pickers-DkqmtnTL.js} +352 -290
- package/dist/chunks/pivot-result-contract-expectations-C-HnUKYe.js +55 -0
- package/dist/chunks/{pivot-result-identity-BlbLrqaC.js → pivot-result-identity-B89X5xjb.js} +1 -1
- package/dist/chunks/raw-temporal-value-DdT0s47W.js +159 -0
- package/dist/chunks/{report-preferences-dialog-Mbd-I0wV.js → report-preferences-dialog-Yvhv3WX2.js} +95 -97
- package/dist/chunks/{report-runtime-context-DnA_PiKo.js → report-runtime-context-BhPzLTbS.js} +1 -1
- package/dist/chunks/{resolve-dashboard-input-context-Du0fjN3h.js → resolve-dashboard-input-context-Lkbwycwe.js} +5491 -5683
- package/dist/chunks/resolver-DG_tfEpt.js +156 -0
- package/dist/chunks/{save-D6pHmSSP.js → save-D985VvYp.js} +1 -1
- package/dist/chunks/{saved-dashboard-context-y8N6RvjS.js → saved-dashboard-context-DC_TEd6y.js} +6 -6
- package/dist/chunks/schema-C9NPiIru.js +2568 -0
- package/dist/chunks/{semaphor-ready-indicator-BSEdUq40.js → semaphor-ready-indicator-ByFvqHEO.js} +35916 -36001
- package/dist/chunks/{shelf-drop-preview-context-D7QqPl36.js → shelf-drop-preview-context-CjoVaK6J.js} +64 -66
- package/dist/chunks/{stored-dashboard-d3xQYxBD.js → stored-dashboard-C0hekXiI.js} +332 -333
- package/dist/chunks/{code-editor-DJNOsgJH.js → style-sheet-parts-C7qGZuH1.js} +2402 -2040
- package/dist/chunks/{table-export-sheet--DUKWk6o.js → table-export-sheet-CP8zSOhj.js} +1 -1
- package/dist/chunks/{temporal-input-presentation--2r9BLr0.js → temporal-input-presentation-CqbJjIuu.js} +18 -18
- package/dist/chunks/{token-types-C8JymO8s.js → token-types-iKMplaBL.js} +1 -1
- package/dist/chunks/{upload-Cf3wXZT8.js → upload-CiGNKJ_0.js} +1 -1
- package/dist/chunks/validators-B8fpdinG.js +3651 -0
- package/dist/chunks/{variable-draft-DOX03R4A.js → variable-draft-9-huI1h4.js} +4 -4
- package/dist/dashboard/index.js +2 -2
- package/dist/dashboard-authoring/index.js +1888 -1826
- package/dist/format-utils/index.js +230 -231
- package/dist/index.js +349 -353
- package/dist/layouts/index.js +1 -1
- package/dist/report-runtime-context/index.js +1 -1
- package/dist/style.css +1 -1
- package/dist/surfboard/index.js +2 -2
- package/dist/types/appearance/index.d.ts +1 -0
- package/dist/types/brand-studio/brand-studio-draft.d.ts +7 -0
- package/dist/types/brand-studio/index.d.ts +1 -1
- package/dist/types/components/briefings/briefing-author/run-model.d.ts +1 -2
- package/dist/types/components/providers/appearance-runtime-provider.d.ts +4 -1
- package/dist/types/components/sharing-and-management/hooks/use-resource-management.d.ts +0 -2
- package/dist/types/components/sharing-and-management/utils/types.d.ts +0 -72
- package/dist/types/components/surfboard/filter/types.d.ts +5 -4
- package/dist/types/components/ui-custom/date-range-presets.d.ts +1 -17
- package/dist/types/components/visual/data-table/hooks/use-data-table-logic.d.ts +0 -1
- package/dist/types/components/visual/data-table/types/data-table.d.ts +0 -9
- package/dist/types/components/visual/data-table/utils/pagination-utils.d.ts +0 -19
- package/dist/types/components/visual/shared/utils/table-column-order.d.ts +0 -1
- package/dist/types/index.js +9 -9
- package/dist/types/lib/appearance/aliases.d.ts +42 -0
- package/dist/types/lib/appearance/compiler.d.ts +6 -0
- package/dist/types/lib/appearance/defaults.d.ts +6 -0
- package/dist/types/lib/appearance/index.d.ts +2 -0
- package/dist/types/lib/appearance/normalize-organization.d.ts +17 -0
- package/dist/types/lib/appearance/resolver.d.ts +2 -2
- package/dist/types/lib/appearance/types.d.ts +38 -1
- package/dist/types/lib/charts/types.d.ts +6 -2
- package/dist/types/lib/dashboard/semantic-dataset-references.d.ts +0 -1
- package/dist/types/lib/dashboard-inputs/dashboard-input-values.d.ts +0 -2
- package/dist/types/lib/dashboard-variables/types.d.ts +1 -6
- package/dist/types/lib/download-pdf.d.ts +0 -1
- package/dist/types/lib/hooks/use-dashboard.d.ts +3 -4
- package/dist/types/lib/hooks/use-date-filter.d.ts +3 -3
- package/dist/types/lib/matrix-table/matrix-card-adapter.d.ts +1 -1
- package/dist/types/lib/stores/dashboard-store.d.ts +15 -6
- package/dist/types/lib/stores/editor-store.d.ts +0 -1
- package/dist/types/lib/stores/table-actions.d.ts +0 -1
- package/dist/types/lib/table-formatting/table-formatting-css.d.ts +0 -5
- package/dist/types/lib/types/common-types.d.ts +3 -2
- package/dist/types/lib/types/explorer-types.d.ts +2 -2
- package/dist/types/lib/types/index.d.ts +1 -1
- package/dist/types/lib/types/summary-types.d.ts +0 -5
- package/dist/types/lib/utils/card-definition.d.ts +7 -7
- package/dist/types/shared/analytics-protocol/agent-time-window.d.ts +84 -0
- package/dist/types/shared/analytics-protocol/analytics-base-schemas.d.ts +4 -4
- package/dist/types/shared/analytics-protocol/applied-constraints.d.ts +2 -2
- package/dist/types/shared/analytics-protocol/contracts.d.ts +8 -17
- package/dist/types/shared/analytics-protocol/execution-input-schemas.d.ts +10 -10
- package/dist/types/shared/analytics-protocol/fixtures.d.ts +3 -2
- package/dist/types/shared/analytics-protocol/index.d.ts +2 -4
- package/dist/types/shared/analytics-protocol/matrix-definition-contract.d.ts +72 -72
- package/dist/types/shared/analytics-protocol/relative-date/describe.d.ts +18 -0
- package/dist/types/shared/analytics-protocol/relative-date/index.d.ts +7 -0
- package/dist/types/shared/analytics-protocol/relative-date/limits.d.ts +3 -0
- package/dist/types/shared/analytics-protocol/relative-date/presets.d.ts +11 -0
- package/dist/types/shared/analytics-protocol/relative-date/resolve.d.ts +49 -0
- package/dist/types/shared/analytics-protocol/relative-date/schemas.d.ts +76 -0
- package/dist/types/shared/analytics-protocol/relative-date/traits.d.ts +51 -0
- package/dist/types/shared/analytics-protocol/relative-date/window.d.ts +111 -0
- package/dist/types/shared/analytics-protocol/selection-contract.d.ts +1 -1
- package/dist/types/shared/assistant-protocol/context.d.ts +30 -30
- package/dist/types/shared/dashboard-authoring/changes/card-query-part.d.ts +0 -2
- package/dist/types/shared/dashboard-authoring/changes/dashboard-change.d.ts +344 -1772
- package/dist/types/shared/dashboard-authoring/changes/diagnostics.d.ts +4 -1
- package/dist/types/shared/dashboard-authoring/changes/read-card-query.d.ts +8 -4
- package/dist/types/shared/dashboard-authoring/changes/resolve-dashboard-changes.d.ts +9 -0
- package/dist/types/shared/dashboard-authoring/conditional-formatting/schema.d.ts +104 -104
- package/dist/types/shared/dashboard-authoring/control-execution-contract.d.ts +20 -20
- package/dist/types/shared/dashboard-authoring/dashboard-style/bounds.d.ts +17 -0
- package/dist/types/shared/dashboard-authoring/dashboard-style/brand.d.ts +20 -0
- package/dist/types/shared/dashboard-authoring/dashboard-style/edit-words.d.ts +7 -0
- package/dist/types/shared/dashboard-authoring/dashboard-style/edit.d.ts +19 -0
- package/dist/types/shared/dashboard-authoring/dashboard-style/index.d.ts +15 -0
- package/dist/types/shared/dashboard-authoring/dashboard-style/layers.d.ts +19 -0
- package/dist/types/shared/dashboard-authoring/dashboard-style/legacy.d.ts +21 -0
- package/dist/types/shared/dashboard-authoring/dashboard-style/parse.d.ts +18 -0
- package/dist/types/shared/dashboard-authoring/dashboard-style/pickers.d.ts +12 -0
- package/dist/types/shared/dashboard-authoring/dashboard-style/types.d.ts +122 -0
- package/dist/types/shared/dashboard-authoring/dashboard-style/view.d.ts +10 -0
- package/dist/types/shared/dashboard-authoring/index.d.ts +1 -0
- package/dist/types/shared/dashboard-authoring/operations/operation-types.d.ts +11 -0
- package/dist/types/shared/dashboard-authoring/outline/outline-dashboard.d.ts +23 -0
- package/dist/types/shared/dashboard-authoring/outline/outline-filters.d.ts +10 -2
- package/dist/types/shared/format-utils/filter-detail.d.ts +2 -8
- package/dist/types/shared/format-utils/filter-line.d.ts +2 -2
- package/dist/types/shared/format-utils/matrix-continuation.d.ts +10 -10
- package/dist/types/shared/temporal/index.d.ts +0 -2
- package/dist/types/shared/temporal/temporal-parity-fixtures.d.ts +2 -2
- package/package.json +7 -26
- package/DATA_APP_SDK.md +0 -339
- package/dist/chunks/appearance-context-DEYtWinQ.js +0 -126
- package/dist/chunks/appearance-runtime-provider-B-M8gwlZ.js +0 -81
- package/dist/chunks/assistant-chat-BN5I8KuN.js +0 -8849
- package/dist/chunks/color-CJvdlFM_.js +0 -2162
- package/dist/chunks/dashboard-json-Cxp3inxd.js +0 -68
- package/dist/chunks/filter-value-text-7zhmth1S.js +0 -163
- package/dist/chunks/index-CLIro-EG.js +0 -425
- package/dist/chunks/index-CuHybtft.js +0 -51
- package/dist/chunks/matrix-analytical-definition-C9xB_T84.js +0 -717
- package/dist/chunks/matrix-card-BSUeSXpD.js +0 -42
- package/dist/chunks/matrix-member-presentation-DZNgQpUq.js +0 -105
- package/dist/chunks/operators-B3zZoskU.js +0 -66
- package/dist/chunks/pivot-result-contract-expectations-Ddh1rNz5.js +0 -56
- package/dist/chunks/raw-temporal-value-Bqz8wc7L.js +0 -242
- package/dist/chunks/selection-reducer-OaJ-N5uN.js +0 -46
- package/dist/chunks/source-entity-resolution-DF6GulDn.js +0 -607
- package/dist/chunks/validators-wtjw0aw6.js +0 -3332
- package/dist/data-app-sdk/index.js +0 -1412
- package/dist/data-app-sdk-adapters/index.js +0 -361
- package/dist/data-app-sdk-validation/index.js +0 -1031
- package/dist/types/components/sharing-and-management/utils/group-types.d.ts +0 -105
- package/dist/types/data-app-sdk/adapters.d.ts +0 -35
- package/dist/types/data-app-sdk/builders.d.ts +0 -62
- package/dist/types/data-app-sdk/contracts.d.ts +0 -419
- package/dist/types/data-app-sdk/executor.d.ts +0 -5
- package/dist/types/data-app-sdk/field-catalog-validation.d.ts +0 -29
- package/dist/types/data-app-sdk/hooks.d.ts +0 -11
- package/dist/types/data-app-sdk/index.d.ts +0 -9
- package/dist/types/data-app-sdk/provider.d.ts +0 -8
- package/dist/types/data-app-sdk/relationship-aware-field-policy.d.ts +0 -21
- package/dist/types/data-app-sdk/selection.d.ts +0 -2
- package/dist/types/data-app-sdk/validation.d.ts +0 -58
- package/dist/types/data-app-sdk-adapters.d.ts +0 -2
- package/dist/types/data-app-sdk-validation.d.ts +0 -2
- package/dist/types/data-app-sdk.d.ts +0 -2
- package/dist/types/shared/analytics-protocol/relative-date-filter.d.ts +0 -68
- package/dist/types/shared/analytics-protocol/relative-date-label.d.ts +0 -20
- package/dist/types/shared/analytics-protocol/time-window-schema.d.ts +0 -314
- package/dist/types/shared/analytics-protocol/time-window.d.ts +0 -52
- package/dist/types/shared/temporal/relative-date.d.ts +0 -21
- package/dist/types/shared/temporal/time-window-periods.d.ts +0 -21
- package/src/data-app-sdk/README.md +0 -402
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
import { j as p, r as y } from "./validators-B8fpdinG.js";
|
|
2
|
+
import { a as I } from "./metric-comparison-n9NsIa-2.js";
|
|
3
|
+
import "../value-format-preferences/index.js";
|
|
4
|
+
import { c as N } from "./raw-temporal-value-DdT0s47W.js";
|
|
5
|
+
import { a9 as k, a8 as T } from "./temporal-input-presentation-CqbJjIuu.js";
|
|
6
|
+
const d = { kind: "plain" }, g = { kind: "temporal" }, D = {
|
|
7
|
+
"=": "=",
|
|
8
|
+
"!=": "!=",
|
|
9
|
+
">": ">",
|
|
10
|
+
">=": ">=",
|
|
11
|
+
"<": "<",
|
|
12
|
+
"<=": "<=",
|
|
13
|
+
in: "in",
|
|
14
|
+
"not in": "not in",
|
|
15
|
+
between: "between",
|
|
16
|
+
"not between": "not between",
|
|
17
|
+
contains: "contains (ignoring case)",
|
|
18
|
+
startsWith: "starts with (ignoring case)",
|
|
19
|
+
endsWith: "ends with (ignoring case)",
|
|
20
|
+
like: "matches the LIKE pattern (ignoring case)",
|
|
21
|
+
"not like": "does not match the LIKE pattern (ignoring case)",
|
|
22
|
+
isNull: "is empty",
|
|
23
|
+
isNotNull: "is not empty"
|
|
24
|
+
}, L = { between: "in", "not between": "not in" };
|
|
25
|
+
function O(t, n = {}) {
|
|
26
|
+
const { operator: e, values: i, reading: r } = t, o = r.kind === "bucket" ? `${t.subject} (${k(r.bucket)})` : t.subject, s = D[e], l = t.shownAs ? ` (shown as ${JSON.stringify(t.shownAs)})` : "", u = (a, m = 0) => ({ text: a, omittedValues: m });
|
|
27
|
+
if (e === "isNull" || e === "isNotNull") return u(`${o} ${s}`);
|
|
28
|
+
if (t.latestValue)
|
|
29
|
+
return u(`${o} ${s} the latest value of this field (resolved at run time)`);
|
|
30
|
+
if (e === "between" || e === "not between") {
|
|
31
|
+
const a = i.length === 2 ? S(i[0], i[1], r, n.timeZone) : void 0;
|
|
32
|
+
if (t.relative)
|
|
33
|
+
return u(`${o} ${L[e]} ${V(t.relative, a)}`);
|
|
34
|
+
if (a) {
|
|
35
|
+
const m = a.wholeDaysIn ? ` (whole days in ${a.wholeDaysIn})` : "";
|
|
36
|
+
return u(`${o} ${s} ${a.from} and ${a.to}${m}${l}`);
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
return e === "in" || e === "not in" || i.length !== 1 ? u(
|
|
40
|
+
`${o} ${s} (${w(i, r, n.maxListedValues)})${l}`,
|
|
41
|
+
$(i.length, n.maxListedValues)
|
|
42
|
+
) : u(`${o} ${s} ${c(i[0], r)}${l}`);
|
|
43
|
+
}
|
|
44
|
+
function P(t, n = {}) {
|
|
45
|
+
return t == null ? { text: "no value", omittedValues: 0 } : Array.isArray(t) ? {
|
|
46
|
+
text: w(t, d, n.maxListedValues),
|
|
47
|
+
omittedValues: $(t.length, n.maxListedValues)
|
|
48
|
+
} : { text: c(t), omittedValues: 0 };
|
|
49
|
+
}
|
|
50
|
+
function c(t, n = d) {
|
|
51
|
+
if (n.kind !== "plain") {
|
|
52
|
+
const e = b(t, n);
|
|
53
|
+
if (e !== void 0) return e;
|
|
54
|
+
}
|
|
55
|
+
return t instanceof Date ? b(t, g) ?? JSON.stringify(String(t)) : t === void 0 ? "null" : typeof t == "number" || typeof t == "boolean" || t === null ? String(t) : JSON.stringify(t) ?? String(t);
|
|
56
|
+
}
|
|
57
|
+
function w(t, n = d, e = Number.POSITIVE_INFINITY) {
|
|
58
|
+
const i = t.slice(0, Number.isFinite(e) ? e : void 0).map((o) => c(o, n)).join(", "), r = $(t.length, e);
|
|
59
|
+
return r > 0 ? `${i}, and ${r} more values` : i;
|
|
60
|
+
}
|
|
61
|
+
function $(t, n = Number.POSITIVE_INFINITY) {
|
|
62
|
+
return Math.max(0, t - n);
|
|
63
|
+
}
|
|
64
|
+
function f(t) {
|
|
65
|
+
if (t instanceof Date)
|
|
66
|
+
return Number.isNaN(t.getTime()) ? void 0 : { kind: "instant", instant: t };
|
|
67
|
+
if (typeof t != "string") return;
|
|
68
|
+
const n = N(t);
|
|
69
|
+
return n === "instant" ? { kind: n, instant: new Date(t) } : n ? { kind: n, text: t } : void 0;
|
|
70
|
+
}
|
|
71
|
+
function b(t, n) {
|
|
72
|
+
if (n.kind === "bucket")
|
|
73
|
+
return typeof t == "string" && T(t, n.bucket).ok ? t : void 0;
|
|
74
|
+
const e = f(t);
|
|
75
|
+
if (e)
|
|
76
|
+
return e.kind === "instant" ? e.instant.toISOString() : e.text;
|
|
77
|
+
}
|
|
78
|
+
function S(t, n, e, i) {
|
|
79
|
+
const r = e.kind === "temporal" ? f(t) : void 0, o = e.kind === "temporal" ? f(n) : void 0;
|
|
80
|
+
if (i && (r == null ? void 0 : r.kind) === "instant" && (o == null ? void 0 : o.kind) === "instant") {
|
|
81
|
+
const s = h(r.instant, i), l = h(o.instant, i);
|
|
82
|
+
if (s && l && s.time === "00:00:00" && r.instant.getUTCMilliseconds() === 0 && l.time === "23:59:59" && [0, 999].includes(o.instant.getUTCMilliseconds()))
|
|
83
|
+
return { from: s.date, to: l.date, wholeDaysIn: i };
|
|
84
|
+
}
|
|
85
|
+
return { from: c(t, e), to: c(n, e) };
|
|
86
|
+
}
|
|
87
|
+
function h(t, n) {
|
|
88
|
+
try {
|
|
89
|
+
const e = Object.fromEntries(
|
|
90
|
+
new Intl.DateTimeFormat("en-CA", {
|
|
91
|
+
timeZone: n,
|
|
92
|
+
year: "numeric",
|
|
93
|
+
month: "2-digit",
|
|
94
|
+
day: "2-digit",
|
|
95
|
+
hour: "2-digit",
|
|
96
|
+
minute: "2-digit",
|
|
97
|
+
second: "2-digit",
|
|
98
|
+
hourCycle: "h23"
|
|
99
|
+
}).formatToParts(t).map((i) => [i.type, i.value])
|
|
100
|
+
);
|
|
101
|
+
return {
|
|
102
|
+
date: `${e.year}-${e.month}-${e.day}`,
|
|
103
|
+
time: `${e.hour}:${e.minute}:${e.second}`
|
|
104
|
+
};
|
|
105
|
+
} catch {
|
|
106
|
+
return;
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
function V(t, n) {
|
|
110
|
+
const { label: e, definition: i } = p(t), r = n && !I(t).dataAnchored ? `; last resolved here as ${n.from} to ${n.to}${n.wholeDaysIn ? `, whole days in ${n.wholeDaysIn}` : ""}` : "";
|
|
111
|
+
return `${e ? `${JSON.stringify(e)} ` : ""}(relative window: ${i}; resolved again at run time${r})`;
|
|
112
|
+
}
|
|
113
|
+
const A = {
|
|
114
|
+
"=": "=",
|
|
115
|
+
"!=": "!=",
|
|
116
|
+
">": ">",
|
|
117
|
+
">=": ">=",
|
|
118
|
+
"<": "<",
|
|
119
|
+
"<=": "<=",
|
|
120
|
+
in: "in",
|
|
121
|
+
"not in": "not in",
|
|
122
|
+
like: "like",
|
|
123
|
+
"not like": "not like",
|
|
124
|
+
between: "between",
|
|
125
|
+
"not between": "not between",
|
|
126
|
+
"is null": "isNull",
|
|
127
|
+
"is not null": "isNotNull"
|
|
128
|
+
};
|
|
129
|
+
function W(t, n, e = {}) {
|
|
130
|
+
const i = t.valueType === "date";
|
|
131
|
+
return O({
|
|
132
|
+
subject: n,
|
|
133
|
+
operator: A[t.operation],
|
|
134
|
+
values: t.values,
|
|
135
|
+
reading: i ? g : d,
|
|
136
|
+
...i ? { relative: y(t.relativeMeta) } : {}
|
|
137
|
+
}, e);
|
|
138
|
+
}
|
|
139
|
+
export {
|
|
140
|
+
d as P,
|
|
141
|
+
g as T,
|
|
142
|
+
O as a,
|
|
143
|
+
P as b,
|
|
144
|
+
W as d,
|
|
145
|
+
$ as o
|
|
146
|
+
};
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
import { S as A } from "./schema-C9NPiIru.js";
|
|
2
|
+
import { r as h, d as u, n as b, A as k } from "./resolver-DG_tfEpt.js";
|
|
3
|
+
const E = [
|
|
4
|
+
{ path: ["tokens", "spacing", "gridGap"], value: { light: 12, dark: 12 } },
|
|
5
|
+
{ path: ["tokens", "spacing", "dashboardPadding"], alias: ["components", "dashboard", "padding"], value: { light: 16, dark: 16 } },
|
|
6
|
+
{ path: ["tokens", "spacing", "cardPadding"], alias: ["components", "card", "padding"], value: { light: 16, dark: 16 } },
|
|
7
|
+
{ path: ["tokens", "radius", "card"], alias: ["components", "card", "borderRadius"], value: { light: 5, dark: 5 } },
|
|
8
|
+
{
|
|
9
|
+
path: ["components", "chart", "palette"],
|
|
10
|
+
value: {
|
|
11
|
+
light: ["#3b82f6", "#10b981", "#f59e0b", "#ef4444", "#8b5cf6", "#06b6d4", "#84cc16", "#f97316"],
|
|
12
|
+
dark: ["#3b82f6", "#10b981", "#f59e0b", "#ef4444", "#8b5cf6", "#06b6d4", "#84cc16", "#f97316"]
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
], p = ["pivotTable", "aggregateTable"], S = [
|
|
16
|
+
["tokens", "shadow", "card"],
|
|
17
|
+
["components", "card", "shadow"]
|
|
18
|
+
];
|
|
19
|
+
function N(e) {
|
|
20
|
+
const { schemes: t, changes: r } = v(e), i = {};
|
|
21
|
+
for (const c of ["light", "dark"]) {
|
|
22
|
+
const n = t[c];
|
|
23
|
+
if (!n) continue;
|
|
24
|
+
const o = A.schemes[c], { value: d, removed: s } = g(n, o, []);
|
|
25
|
+
for (const f of s) r.push(`${c}.${f}: equal to the default, removed`);
|
|
26
|
+
d && Object.keys(d).length > 0 && (i[c] = d);
|
|
27
|
+
}
|
|
28
|
+
const a = Object.keys(i).length > 0;
|
|
29
|
+
return !a && e.mode === void 0 ? { spec: null, changes: r } : {
|
|
30
|
+
spec: { version: e.version, ...e.mode !== void 0 ? { mode: e.mode } : {}, ...a ? { schemes: i } : {} },
|
|
31
|
+
changes: r
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
function R(e, t) {
|
|
35
|
+
return e ? v(e).schemes[t] : void 0;
|
|
36
|
+
}
|
|
37
|
+
function v(e) {
|
|
38
|
+
var a, c;
|
|
39
|
+
const t = [], r = {}, i = y(e);
|
|
40
|
+
for (const n of ["light", "dark"]) {
|
|
41
|
+
let o = (a = e.schemes) == null ? void 0 : a[n];
|
|
42
|
+
if (!o) continue;
|
|
43
|
+
for (const s of i ? S : [])
|
|
44
|
+
h(o, s) !== void 0 && (o = u(o, s), t.push(`${n}.${s.join(".")}: never rendered, removed`));
|
|
45
|
+
for (const s of i ? E : []) {
|
|
46
|
+
const f = h(o, s.path);
|
|
47
|
+
f === void 0 || !l(f, s.value[n]) || s.alias && h(o, s.alias) !== void 0 || (o = u(o, s.path), t.push(`${n}.${s.path.join(".")}: hidden legacy default removed`));
|
|
48
|
+
}
|
|
49
|
+
const d = (c = b({ version: e.version, schemes: { [n]: o } }).schemes) == null ? void 0 : c[n];
|
|
50
|
+
l(d, o) || t.push(`${n}: component aliases folded onto canonical paths`), o = d;
|
|
51
|
+
for (const s of p)
|
|
52
|
+
h(o, ["components", s]) !== void 0 && (o = u(o, ["components", s]), t.push(`${n}.components.${s}: retired card type removed`));
|
|
53
|
+
r[n] = o;
|
|
54
|
+
}
|
|
55
|
+
return { schemes: r, changes: t };
|
|
56
|
+
}
|
|
57
|
+
function y(e) {
|
|
58
|
+
return ["light", "dark"].some((t) => {
|
|
59
|
+
var i;
|
|
60
|
+
const r = (i = e.schemes) == null ? void 0 : i[t];
|
|
61
|
+
return r ? k.some(({ alias: a }) => h(r, a) !== void 0) || p.some((a) => h(r, ["components", a]) !== void 0) : !1;
|
|
62
|
+
});
|
|
63
|
+
}
|
|
64
|
+
function g(e, t, r) {
|
|
65
|
+
const i = [], a = {};
|
|
66
|
+
for (const [c, n] of Object.entries(e)) {
|
|
67
|
+
const o = m(t) ? t[c] : void 0;
|
|
68
|
+
if (m(n) && !Array.isArray(n)) {
|
|
69
|
+
const d = g(n, o, [...r, c]);
|
|
70
|
+
i.push(...d.removed), d.value && (a[c] = d.value);
|
|
71
|
+
continue;
|
|
72
|
+
}
|
|
73
|
+
if (o !== void 0 && l(n, o)) {
|
|
74
|
+
i.push([...r, c].join("."));
|
|
75
|
+
continue;
|
|
76
|
+
}
|
|
77
|
+
a[c] = n;
|
|
78
|
+
}
|
|
79
|
+
return { value: Object.keys(a).length > 0 ? a : void 0, removed: i };
|
|
80
|
+
}
|
|
81
|
+
function l(e, t) {
|
|
82
|
+
return JSON.stringify(e) === JSON.stringify(t);
|
|
83
|
+
}
|
|
84
|
+
function m(e) {
|
|
85
|
+
return typeof e == "object" && e !== null && !Array.isArray(e);
|
|
86
|
+
}
|
|
87
|
+
export {
|
|
88
|
+
N as n,
|
|
89
|
+
R as r
|
|
90
|
+
};
|