@platforma-sdk/model 1.31.17 → 1.33.2

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/index.mjs CHANGED
@@ -1,10 +1,10 @@
1
1
  var Xe = Object.defineProperty;
2
2
  var Qe = (t, e, n) => e in t ? Xe(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
3
- var R = (t, e, n) => Qe(t, typeof e != "symbol" ? e + "" : e, n);
4
- import { isPColumn as be, mapPObjectData as we, isDataInfoEntries as Ee, isDataInfo as Ae, dataInfoToEntries as Ze, selectorsToPredicate as X, resolveAnchors as xe, deriveNativeId as et, isPColumnSpec as ne, isPartitionedDataInfoEntries as tt, getAxisId as T, entriesToDataInfo as nt, canonicalizeAxisId as rt, withEnrichments as Ce, AnchoredIdDeriver as Pe, isPlRef as it, mapValueInVOE as st, ensurePColumn as ot, extractAllColumns as at, mapPTableDef as lt, mapDataInfo as ut, canonicalizeJson as F, parseJson as fe, matchAxisId as K, getPColumnSpecId as ue, getColumnIdAndSpec as Oe, isPTableAbsent as ct, PTableNA as pt } from "@milaboratories/pl-model-common";
3
+ var F = (t, e, n) => Qe(t, typeof e != "symbol" ? e + "" : e, n);
4
+ import { isPColumn as be, mapPObjectData as we, isDataInfoEntries as Ee, isDataInfo as Ae, dataInfoToEntries as Ze, selectorsToPredicate as X, resolveAnchors as xe, deriveNativeId as et, isPColumnSpec as ne, isPartitionedDataInfoEntries as tt, getAxisId as T, entriesToDataInfo as nt, canonicalizeAxisId as rt, withEnrichments as Ce, AnchoredIdDeriver as Pe, isPlRef as it, mapValueInVOE as st, ensurePColumn as ot, extractAllColumns as at, mapPTableDef as lt, mapDataInfo as ut, canonicalizeJson as D, parseJson as fe, matchAxisId as K, getPColumnSpecId as ue, getColumnIdAndSpec as Oe, isPTableAbsent as ct, PTableNA as pt } from "@milaboratories/pl-model-common";
5
5
  export * from "@milaboratories/pl-model-common";
6
6
  import ke from "canonicalize";
7
- import { z as U } from "zod";
7
+ import { z as M } from "zod";
8
8
  export * from "@milaboratories/pl-error-like";
9
9
  class dt extends Error {
10
10
  constructor(e, n) {
@@ -15,7 +15,7 @@ function ft(t) {
15
15
  if (!t.ok) throw new dt(t.errors, t.moreErrors);
16
16
  return t.value;
17
17
  }
18
- function tn(t) {
18
+ function en(t) {
19
19
  return new Proxy(t, {
20
20
  get(e, n) {
21
21
  return ft(e[n]);
@@ -28,17 +28,17 @@ function P(t) {
28
28
  function Q(t) {
29
29
  return { type: "GetFromCtx", variable: t };
30
30
  }
31
- function nn(t) {
31
+ function tn(t) {
32
32
  return {
33
33
  type: "Isolate",
34
34
  cfg: t
35
35
  };
36
36
  }
37
- const rn = Q("$args"), sn = Q("$it"), on = Q("$prod"), an = Q("$staging"), ln = Q("$ui");
37
+ const nn = Q("$args"), rn = Q("$it"), sn = Q("$prod"), on = Q("$staging"), an = Q("$ui");
38
38
  function re(t) {
39
39
  return { type: "Immediate", value: t };
40
40
  }
41
- function Re(t) {
41
+ function Fe(t) {
42
42
  const e = {};
43
43
  for (const [n, r] of Object.entries(t)) e[n] = P(r);
44
44
  return {
@@ -46,7 +46,7 @@ function Re(t) {
46
46
  template: e
47
47
  };
48
48
  }
49
- function un(...t) {
49
+ function ln(...t) {
50
50
  const e = [];
51
51
  for (const n of t) e.push(P(n));
52
52
  return {
@@ -61,7 +61,7 @@ function ie(t, e) {
61
61
  field: P(e)
62
62
  };
63
63
  }
64
- function cn(t, e, n = "$it") {
64
+ function un(t, e, n = "$it") {
65
65
  return {
66
66
  type: "MapRecordValues",
67
67
  source: t,
@@ -69,7 +69,7 @@ function cn(t, e, n = "$it") {
69
69
  itVar: n
70
70
  };
71
71
  }
72
- function pn(t, e, n = "$it") {
72
+ function cn(t, e, n = "$it") {
73
73
  return {
74
74
  type: "MapArrayValues",
75
75
  source: t,
@@ -77,46 +77,46 @@ function pn(t, e, n = "$it") {
77
77
  itVar: n
78
78
  };
79
79
  }
80
- function dn(t) {
80
+ function pn(t) {
81
81
  return {
82
82
  type: "Flatten",
83
83
  source: t
84
84
  };
85
85
  }
86
- function fn(t) {
86
+ function dn(t) {
87
87
  return {
88
88
  type: "IsEmpty",
89
89
  arg: t
90
90
  };
91
91
  }
92
- function hn(t) {
92
+ function fn(t) {
93
93
  return {
94
94
  type: "Not",
95
95
  operand: t
96
96
  };
97
97
  }
98
- function gn(t, e) {
98
+ function hn(t, e) {
99
99
  return {
100
100
  type: "And",
101
101
  operand1: t,
102
102
  operand2: e
103
103
  };
104
104
  }
105
- function mn(t, e) {
105
+ function gn(t, e) {
106
106
  return {
107
107
  type: "Or",
108
108
  operand1: t,
109
109
  operand2: e
110
110
  };
111
111
  }
112
- function yn(t, e) {
112
+ function mn(t, e) {
113
113
  return {
114
114
  type: "GetResourceField",
115
115
  source: P(t),
116
116
  field: P(e)
117
117
  };
118
118
  }
119
- function vn() {
119
+ function yn() {
120
120
  return function(t) {
121
121
  return {
122
122
  type: "GetResourceValueAsJson",
@@ -124,7 +124,7 @@ function vn() {
124
124
  };
125
125
  };
126
126
  }
127
- function bn(t, e, n = "$it") {
127
+ function vn(t, e, n = "$it") {
128
128
  return {
129
129
  type: "MapResourceFields",
130
130
  source: t,
@@ -132,21 +132,21 @@ function bn(t, e, n = "$it") {
132
132
  itVar: n
133
133
  };
134
134
  }
135
- function wn(t, e) {
135
+ function bn(t, e) {
136
136
  return {
137
137
  type: "GetBlobContent",
138
138
  range: e,
139
139
  source: P(t)
140
140
  };
141
141
  }
142
- function An(t, e) {
142
+ function wn(t, e) {
143
143
  return {
144
144
  type: "GetBlobContentAsString",
145
145
  range: e,
146
146
  source: P(t)
147
147
  };
148
148
  }
149
- function xn() {
149
+ function An() {
150
150
  return function(t, e) {
151
151
  return {
152
152
  type: "GetBlobContentAsJson",
@@ -155,53 +155,53 @@ function xn() {
155
155
  };
156
156
  };
157
157
  }
158
- function Cn(t) {
158
+ function xn(t) {
159
159
  return {
160
160
  type: "GetDownloadedBlobContent",
161
161
  source: P(t)
162
162
  };
163
163
  }
164
- function Pn(t) {
164
+ function Cn(t) {
165
165
  return {
166
166
  type: "GetOnDemandBlobContent",
167
167
  source: P(t)
168
168
  };
169
169
  }
170
- function Sn(t, e) {
170
+ function Pn(t, e) {
171
171
  return {
172
172
  type: "ExtractArchiveAndGetURL",
173
173
  format: e,
174
174
  source: P(t)
175
175
  };
176
176
  }
177
- function _n(t) {
177
+ function Sn(t) {
178
178
  return {
179
179
  type: "GetImportProgress",
180
180
  source: P(t)
181
181
  };
182
182
  }
183
- function In(t, e) {
183
+ function _n(t, e) {
184
184
  return {
185
185
  type: "GetLastLogs",
186
186
  source: P(t),
187
187
  lines: e
188
188
  };
189
189
  }
190
- function Tn(t, e) {
190
+ function In(t, e) {
191
191
  return {
192
192
  type: "GetProgressLog",
193
193
  source: P(t),
194
194
  patternToSearch: e
195
195
  };
196
196
  }
197
- function Ln(t, e) {
197
+ function Tn(t, e) {
198
198
  return {
199
199
  type: "GetProgressLogWithInfo",
200
200
  source: P(t),
201
201
  patternToSearch: e
202
202
  };
203
203
  }
204
- function En(t) {
204
+ function Ln(t) {
205
205
  return {
206
206
  type: "GetLogHandle",
207
207
  source: P(t)
@@ -210,7 +210,7 @@ function En(t) {
210
210
  function ht() {
211
211
  return typeof globalThis.getPlatforma < "u" || typeof globalThis.platforma < "u";
212
212
  }
213
- function De(t) {
213
+ function Re(t) {
214
214
  if (t && typeof globalThis.getPlatforma == "function")
215
215
  return globalThis.getPlatforma(t);
216
216
  if (typeof globalThis.platforma < "u") return globalThis.platforma;
@@ -238,8 +238,8 @@ function mt(t, e) {
238
238
  }
239
239
  class I {
240
240
  constructor(e, n = (r) => r) {
241
- R(this, "isResolved", !1);
242
- R(this, "resolvedValue");
241
+ F(this, "isResolved", !1);
242
+ F(this, "resolvedValue");
243
243
  this.handle = e, this.postProcess = n, mt(e, (r) => {
244
244
  this.resolvedValue = n(r), this.isResolved = !0;
245
245
  });
@@ -480,7 +480,7 @@ class O {
480
480
  return s && (l = l.filter((u) => u[1] !== void 0)), l.map(([u, d]) => o(u, d));
481
481
  }
482
482
  }
483
- const Fe = "staging", Ke = "main", yt = {
483
+ const De = "staging", Ke = "main", yt = {
484
484
  explicitColumnsSupport: !0,
485
485
  inlineColumnsSupport: !0,
486
486
  activeArgs: !0
@@ -502,26 +502,26 @@ function vt(t) {
502
502
  const e = /* @__PURE__ */ new Set();
503
503
  return ge(e, /* @__PURE__ */ new Set(), t), e;
504
504
  }
505
- const On = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
505
+ const En = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
506
506
  __proto__: null,
507
507
  GlobalCfgRenderCtxFeatureFlags: yt,
508
508
  MainAccessorName: Ke,
509
- StagingAccessorName: Fe,
509
+ StagingAccessorName: De,
510
510
  getAllFutureAwaits: vt,
511
511
  isFutureAwait: je
512
- }, Symbol.toStringTag, { value: "Module" })), bt = "pl7.app/label", wt = "pl7.app/trace", At = U.object({
513
- type: U.string(),
514
- importance: U.number().optional(),
515
- id: U.string().optional(),
516
- label: U.string()
517
- }), xt = U.array(At), Ct = 1e-3, Pt = "__LABEL__", Se = "__LABEL__@1";
512
+ }, Symbol.toStringTag, { value: "Module" })), bt = "pl7.app/label", wt = "pl7.app/trace", At = M.object({
513
+ type: M.string(),
514
+ importance: M.number().optional(),
515
+ id: M.string().optional(),
516
+ label: M.string()
517
+ }), xt = M.array(At), Ct = 1e-3, Pt = "__LABEL__", Se = "__LABEL__@1";
518
518
  function Ve(t, e, n = {}) {
519
519
  const r = /* @__PURE__ */ new Map(), i = n.forceTraceElements !== void 0 && n.forceTraceElements.length > 0 ? new Set(n.forceTraceElements) : void 0, s = /* @__PURE__ */ new Map(), o = t.map((f) => {
520
- var S, D;
520
+ var S, R;
521
521
  const w = e(f);
522
522
  let c, g, x;
523
523
  "spec" in w && typeof w.spec == "object" ? (c = w.spec, g = w.prefixTrace, x = w.suffixTrace) : c = w;
524
- const p = (S = c.annotations) == null ? void 0 : S[bt], A = (D = c.annotations) == null ? void 0 : D[wt], m = (A ? xt.safeParse(JSON.parse(A)).data : void 0) ?? [], v = [
524
+ const p = (S = c.annotations) == null ? void 0 : S[bt], A = (R = c.annotations) == null ? void 0 : R[wt], m = (A ? xt.safeParse(JSON.parse(A)).data : void 0) ?? [], v = [
525
525
  ...g ?? [],
526
526
  ...m,
527
527
  ...x ?? []
@@ -622,7 +622,7 @@ function Ne(t, e, n, r = [], i) {
622
622
  throw new Error(`Unknown resource type: ${t.resourceType.name}`);
623
623
  }
624
624
  }
625
- function kn(t, e, n = !1) {
625
+ function On(t, e, n = !1) {
626
626
  const r = [];
627
627
  return { isComplete: Ne(t, e, r, [], n), data: r };
628
628
  }
@@ -903,7 +903,7 @@ function kt(t) {
903
903
  if (t)
904
904
  return t.map((e) => [e.axisIdx, e.value]);
905
905
  }
906
- function Rt(t, e) {
906
+ function Ft(t, e) {
907
907
  if (!e || e.length === 0) return t;
908
908
  const n = [...e].sort((r, i) => r[0] - i[0]);
909
909
  return ke({ id: t, axisFilters: n });
@@ -913,7 +913,7 @@ function _e(t) {
913
913
  const e = t, n = e.domain && typeof e.domain == "object" && Object.values(e.domain).some((i) => typeof i == "object" && i !== null && "anchor" in i), r = e.axes && Array.isArray(e.axes) && e.axes.some((i) => typeof i == "object" && i !== null && "anchor" in i);
914
914
  return !!e.domainAnchor || n || r;
915
915
  }
916
- function Dt(t) {
916
+ function Rt(t) {
917
917
  if (typeof t != "object" || !("axes" in t) || t.axes === void 0)
918
918
  return [];
919
919
  const e = t.axes.map((n, r) => typeof n == "object" && "split" in n && n.split === !0 ? r : -1).filter((n) => n !== -1);
@@ -923,9 +923,9 @@ function Dt(t) {
923
923
  }
924
924
  class ve {
925
925
  constructor() {
926
- R(this, "defaultProviderStore", []);
927
- R(this, "providers", [new Et(this.defaultProviderStore)]);
928
- R(this, "axisLabelProviders", []);
926
+ F(this, "defaultProviderStore", []);
927
+ F(this, "providers", [new Et(this.defaultProviderStore)]);
928
+ F(this, "axisLabelProviders", []);
929
929
  }
930
930
  addColumnProvider(e) {
931
931
  return this.providers.push(e), this;
@@ -980,12 +980,12 @@ class ve {
980
980
  if (u(S.spec)) continue;
981
981
  if (p.has(S.id))
982
982
  throw new Error(`Duplicate column id ${S.id} in provider ${C.constructor.name}`);
983
- const D = et(S.spec);
984
- b.has(D) || (p.add(S.id), b.add(D), A.push(S));
983
+ const R = et(S.spec);
984
+ b.has(R) || (p.add(S.id), b.add(R), A.push(S));
985
985
  }
986
986
  }
987
987
  if (A.length === 0) continue;
988
- const m = Dt(c), v = m.length > 0;
988
+ const m = Rt(c), v = m.length > 0;
989
989
  for (const C of A) {
990
990
  if (!ne(C.spec)) continue;
991
991
  const L = C.spec;
@@ -997,7 +997,7 @@ class ve {
997
997
  }
998
998
  if (!tt(S))
999
999
  throw new Error(`Splitting requires Partitioned DataInfoEntries, but parsing resulted in ${S.type} for column ${C.id}`);
1000
- const D = It(S), k = m[m.length - 1];
1000
+ const R = It(S), k = m[m.length - 1];
1001
1001
  if (k >= S.partitionKeyLength)
1002
1002
  throw new Error(`Not enough partition keys (${S.partitionKeyLength}) for requested split axes (max index ${k}) in column ${L.name}`);
1003
1003
  const W = m.map((_) => this.findLabels(T(L.axesSpec[_]))), V = [], N = (_, G) => {
@@ -1007,9 +1007,9 @@ class ve {
1007
1007
  return;
1008
1008
  }
1009
1009
  const $ = m[G];
1010
- if ($ >= D.length)
1011
- throw new Error(`Axis index ${$} out of bounds for unique keys array (length ${D.length}) during split key generation for column ${C.id}`);
1012
- const J = D[$];
1010
+ if ($ >= R.length)
1011
+ throw new Error(`Axis index ${$} out of bounds for unique keys array (length ${R.length}) during split key generation for column ${C.id}`);
1012
+ const J = R[$];
1013
1013
  if (!J || J.length === 0) {
1014
1014
  V.length = 0;
1015
1015
  return;
@@ -1058,7 +1058,7 @@ class ve {
1058
1058
  for (const { value: c, label: g } of f) {
1059
1059
  const { originalColumn: x, spec: p } = c, A = c.type === "split" ? c.axisFilters : void 0, m = kt(A);
1060
1060
  let v;
1061
- r ? v = r.deriveS(p, m) : v = Rt(x.id, m);
1061
+ r ? v = r.deriveS(p, m) : v = Ft(x.id, m);
1062
1062
  let C = { ...c.adjustedSpec };
1063
1063
  o && (C = {
1064
1064
  ...C,
@@ -1108,9 +1108,9 @@ function pe(t, e) {
1108
1108
  function Ie(t) {
1109
1109
  return we(t, (e) => e instanceof O ? e.handle : Ae(e) ? ut(e, (n) => n.handle) : e);
1110
1110
  }
1111
- class Ft {
1111
+ class Dt {
1112
1112
  constructor() {
1113
- R(this, "ctx", h());
1113
+ F(this, "ctx", h());
1114
1114
  }
1115
1115
  /**
1116
1116
  * @deprecated use getOptions()
@@ -1379,12 +1379,12 @@ class Ft {
1379
1379
  }
1380
1380
  class te {
1381
1381
  constructor() {
1382
- R(this, "ctx");
1383
- R(this, "args");
1384
- R(this, "uiState");
1382
+ F(this, "ctx");
1383
+ F(this, "args");
1384
+ F(this, "uiState");
1385
1385
  // lazy rendering because this feature is rarely used
1386
- R(this, "_activeArgsCache");
1387
- R(this, "resultPool", new Ft());
1386
+ F(this, "_activeArgsCache");
1387
+ F(this, "resultPool", new Dt());
1388
1388
  this.ctx = h(), this.args = JSON.parse(this.ctx.args), this.uiState = this.ctx.uiState !== void 0 ? JSON.parse(this.ctx.uiState) : {};
1389
1389
  }
1390
1390
  /**
@@ -1407,7 +1407,7 @@ class te {
1407
1407
  );
1408
1408
  }
1409
1409
  get prerun() {
1410
- return this.getNamedAccessor(Fe);
1410
+ return this.getNamedAccessor(De);
1411
1411
  }
1412
1412
  get outputs() {
1413
1413
  return this.getNamedAccessor(Ke);
@@ -1451,8 +1451,17 @@ class te {
1451
1451
  getCurrentUnstableMarker() {
1452
1452
  return this.ctx.getCurrentUnstableMarker();
1453
1453
  }
1454
+ logInfo(e) {
1455
+ this.ctx.logInfo(e);
1456
+ }
1457
+ logWarn(e) {
1458
+ this.ctx.logWarn(e);
1459
+ }
1460
+ logError(e) {
1461
+ this.ctx.logError(e);
1462
+ }
1454
1463
  }
1455
- const Y = "1.31.17";
1464
+ const Y = "1.33.2";
1456
1465
  function Kt(t) {
1457
1466
  return t.__renderLambda === !0;
1458
1467
  }
@@ -1460,11 +1469,11 @@ function de(t) {
1460
1469
  if (t !== void 0)
1461
1470
  return Kt(t) ? t.handle : t;
1462
1471
  }
1463
- function M(t) {
1472
+ function U(t) {
1464
1473
  if (t !== void 0)
1465
1474
  return typeof t == "string" ? { __renderLambda: !0, handle: t, retentive: !1 } : t;
1466
1475
  }
1467
- function Rn(t) {
1476
+ function kn(t) {
1468
1477
  if (t.v3 !== void 0) {
1469
1478
  const {
1470
1479
  initialArgs: e,
@@ -1500,10 +1509,10 @@ function Rn(t) {
1500
1509
  renderingMode: n,
1501
1510
  initialArgs: o,
1502
1511
  outputs: Object.fromEntries(
1503
- Object.entries(r).map(([u, d]) => [u, M(d)])
1512
+ Object.entries(r).map(([u, d]) => [u, U(d)])
1504
1513
  ),
1505
- inputsValid: M(i),
1506
- sections: M(s),
1514
+ inputsValid: U(i),
1515
+ sections: U(s),
1507
1516
  initialUiState: void 0,
1508
1517
  code: a
1509
1518
  };
@@ -1518,10 +1527,10 @@ function Rn(t) {
1518
1527
  renderingMode: r,
1519
1528
  initialArgs: o,
1520
1529
  outputs: Object.fromEntries(
1521
- Object.entries(i).map(([u, d]) => [u, M(d)])
1530
+ Object.entries(i).map(([u, d]) => [u, U(d)])
1522
1531
  ),
1523
- inputsValid: M(n),
1524
- sections: M(s),
1532
+ inputsValid: U(n),
1533
+ sections: U(s),
1525
1534
  initialUiState: void 0,
1526
1535
  code: a
1527
1536
  };
@@ -1730,7 +1739,7 @@ class E {
1730
1739
  Object.entries(this._outputs).map(([n, r]) => [n, de(r)])
1731
1740
  )
1732
1741
  };
1733
- return ht() ? De({ sdkVersion: Y }) : { config: e };
1742
+ return ht() ? Re({ sdkVersion: Y }) : { config: e };
1734
1743
  }
1735
1744
  }
1736
1745
  const jt = (t, e) => {
@@ -1754,13 +1763,13 @@ function Vt(t) {
1754
1763
  }
1755
1764
  function $t(t) {
1756
1765
  var e;
1757
- return t.axesSpec.length === 2 && ((e = t.annotations) == null ? void 0 : e[Ut]) === "true";
1766
+ return t.axesSpec.length === 2 && ((e = t.annotations) == null ? void 0 : e[Mt]) === "true";
1758
1767
  }
1759
1768
  function Nt(t) {
1760
1769
  var n, r;
1761
1770
  const e = /* @__PURE__ */ new Map();
1762
1771
  for (const { id: i, spec: s } of t) {
1763
- const [o, a] = s.axesSpec.map(T).map(F);
1772
+ const [o, a] = s.axesSpec.map(T).map(D);
1764
1773
  e.has(o) || e.set(o, /* @__PURE__ */ new Map()), e.has(a) || e.set(a, /* @__PURE__ */ new Map()), (n = e.get(o)) == null || n.set(a, { columnId: i, spec: s }), (r = e.get(a)) == null || r.set(o, { columnId: i, spec: s });
1765
1774
  }
1766
1775
  return e;
@@ -1769,7 +1778,7 @@ function Je(t, e, n) {
1769
1778
  var l;
1770
1779
  const i = [...t.keys()].map(fe).find((u) => K(e, u));
1771
1780
  if (!i) return !1;
1772
- const s = F(T(i)), o = /* @__PURE__ */ new Set([s]);
1781
+ const s = D(T(i)), o = /* @__PURE__ */ new Set([s]);
1773
1782
  let a = [s];
1774
1783
  for (; a.length; ) {
1775
1784
  const u = [];
@@ -1787,16 +1796,16 @@ function Jt(t, e, n) {
1787
1796
  const r = t.axesSpec.map(T), i = e.axesSpec.map(T);
1788
1797
  return i.some((s) => r.some((o) => K(o, s) && K(s, o))) || !!n && i.some((s) => r.some((o) => Je(n, o, s)));
1789
1798
  }
1790
- function Me(t, e, n) {
1799
+ function Ue(t, e, n) {
1791
1800
  const r = t.axesSpec.map(T), i = e.axesSpec.map(T);
1792
1801
  return i.some((s) => r.some((o) => K(o, s))) || !!n && i.some((s) => r.some((o) => Je(n, o, s)));
1793
1802
  }
1794
- const Mt = "pl7.app/graph/isVirtual", Te = "pl7.app/label", Ut = "pl7.app/isLinkerColumn";
1803
+ const Ut = "pl7.app/graph/isVirtual", Te = "pl7.app/label", Mt = "pl7.app/isLinkerColumn";
1795
1804
  function Le(t, e, n) {
1796
1805
  const r = t.spec.axesSpec.map(T), i = e.spec.axesSpec.map(T);
1797
1806
  if (Jt(t.spec, e.spec, n))
1798
1807
  return [];
1799
- if (!Me(t.spec, e.spec, n))
1808
+ if (!Ue(t.spec, e.spec, n))
1800
1809
  return [];
1801
1810
  const a = i.map((b) => r.filter((f) => K(f, b))), l = Vt(a), u = /* @__PURE__ */ new Set(), d = /* @__PURE__ */ new Set(), y = l.map((b) => {
1802
1811
  const f = /* @__PURE__ */ new Set();
@@ -1822,7 +1831,7 @@ function Le(t, e, n) {
1822
1831
  return (m = JSON.parse(A)) == null ? void 0 : m[1];
1823
1832
  }).join(" / "), x = {
1824
1833
  ...e.spec.annotations,
1825
- [Mt]: "true"
1834
+ [Ut]: "true"
1826
1835
  };
1827
1836
  return (c || g) && (x[Te] = c && g ? c + " / " + g : c + g), {
1828
1837
  id: w,
@@ -1838,7 +1847,7 @@ function Le(t, e, n) {
1838
1847
  };
1839
1848
  });
1840
1849
  }
1841
- function Bt(t, e = /* @__PURE__ */ new Map()) {
1850
+ function Fn(t, e = /* @__PURE__ */ new Map()) {
1842
1851
  const n = [];
1843
1852
  for (let r = 0; r < t.length; r++)
1844
1853
  for (let i = r + 1; i < t.length; i++) {
@@ -1850,18 +1859,18 @@ function Bt(t, e = /* @__PURE__ */ new Map()) {
1850
1859
  }
1851
1860
  return n;
1852
1861
  }
1853
- function Wt(t, e, n = [], r = /* @__PURE__ */ new Map()) {
1862
+ function Bt(t, e, n = [], r = /* @__PURE__ */ new Map()) {
1854
1863
  const i = /* @__PURE__ */ new Set(), s = /* @__PURE__ */ new Map();
1855
1864
  t.forEach((a) => {
1856
- i.add(a.id), s.set(F(ue(a.spec)), a);
1865
+ i.add(a.id), s.set(D(ue(a.spec)), a);
1857
1866
  });
1858
1867
  const o = /* @__PURE__ */ new Map();
1859
1868
  for (const a of e) {
1860
1869
  if (i.has(a.id)) continue;
1861
- const l = F(ue(a.spec));
1870
+ const l = D(ue(a.spec));
1862
1871
  if (!s.has(l)) {
1863
1872
  for (const u of s.values())
1864
- if (Me(u.spec, a.spec, r)) {
1873
+ if (Ue(u.spec, a.spec, r)) {
1865
1874
  o.set(l, a);
1866
1875
  break;
1867
1876
  }
@@ -1869,34 +1878,34 @@ function Wt(t, e, n = [], r = /* @__PURE__ */ new Map()) {
1869
1878
  }
1870
1879
  for (const a of n) {
1871
1880
  if (i.has(a.id)) continue;
1872
- const l = F(ue(a.spec));
1881
+ const l = D(ue(a.spec));
1873
1882
  s.has(l) || o.has(l) || (i.add(a.id), s.set(l, a));
1874
1883
  }
1875
1884
  return [...s.values(), ...o.values()];
1876
1885
  }
1877
- function Dn(t, e) {
1886
+ function Rn(t, e) {
1878
1887
  if (!e) return;
1879
- const n = t.resultPool.getData().entries.map((l) => l.obj).filter(be), i = [...e, ...n].filter((l) => $t(l.spec)), s = Nt(i), o = Wt(e, n, i, s), a = [...o, ...Bt(o, s)];
1888
+ const n = t.resultPool.getData().entries.map((l) => l.obj).filter(be), i = [...e, ...n].filter((l) => $t(l.spec)), s = Nt(i), a = [...Bt(e, n, i, s)];
1880
1889
  if (!a.some(
1881
1890
  (l) => l.data instanceof O && !l.data.getIsReadyOrError()
1882
1891
  ))
1883
1892
  return t.createPFrame(a);
1884
1893
  }
1885
- function Fn(t) {
1894
+ function Dn(t) {
1886
1895
  const e = t.type;
1887
1896
  switch (e) {
1888
1897
  case "axis":
1889
- return F(t);
1898
+ return D(t);
1890
1899
  case "column":
1891
- return F(t);
1900
+ return D(t);
1892
1901
  default:
1893
1902
  throw Error(`unsupported column type: ${e}`);
1894
1903
  }
1895
1904
  }
1896
- function Gt(t) {
1905
+ function Wt(t) {
1897
1906
  return t.axesSpec.length === 1 && t.name === "pl7.app/label";
1898
1907
  }
1899
- function Ue(t) {
1908
+ function Me(t) {
1900
1909
  return new ve().addAxisLabelProvider(t).addColumnProvider(t).getColumns({
1901
1910
  name: "pl7.app/label",
1902
1911
  axes: [{}]
@@ -1906,7 +1915,7 @@ function Ue(t) {
1906
1915
  function Be(t, e) {
1907
1916
  const n = [], r = [];
1908
1917
  for (const a of t)
1909
- Gt(a.spec) ? n.push(a) : r.push(a);
1918
+ Wt(a.spec) ? n.push(a) : r.push(a);
1910
1919
  const i = [];
1911
1920
  for (const a of r)
1912
1921
  for (const l of a.spec.axesSpec) {
@@ -1984,7 +1993,7 @@ function Ge(t, e, n, r, i, s) {
1984
1993
  function Kn(t, e, n, r) {
1985
1994
  var u, d;
1986
1995
  Array.isArray(r) && (r = { filters: r });
1987
- const i = (r == null ? void 0 : r.coreJoinType) ?? "full", s = [...(r == null ? void 0 : r.filters) ?? [], ...((u = n == null ? void 0 : n.pTableParams) == null ? void 0 : u.filters) ?? []], o = ((d = n == null ? void 0 : n.pTableParams) == null ? void 0 : d.sorting) ?? [], a = Ue(t.resultPool);
1996
+ const i = (r == null ? void 0 : r.coreJoinType) ?? "full", s = [...(r == null ? void 0 : r.filters) ?? [], ...((u = n == null ? void 0 : n.pTableParams) == null ? void 0 : u.filters) ?? []], o = ((d = n == null ? void 0 : n.pTableParams) == null ? void 0 : d.sorting) ?? [], a = Me(t.resultPool);
1988
1997
  if (!a) return;
1989
1998
  const l = Be(e.map(Oe), a);
1990
1999
  if (We([...e, ...l]))
@@ -1992,25 +2001,25 @@ function Kn(t, e, n, r) {
1992
2001
  Ge(e, l, i, s, o, r == null ? void 0 : r.coreColumnPredicate)
1993
2002
  );
1994
2003
  }
1995
- function Ht(t) {
2004
+ function Gt(t) {
1996
2005
  var e;
1997
2006
  return ((e = t.annotations) == null ? void 0 : e["pl7.app/table/visibility"]) === "hidden";
1998
2007
  }
1999
- function qt(t) {
2008
+ function Ht(t) {
2000
2009
  var e;
2001
2010
  return ((e = t.annotations) == null ? void 0 : e["pl7.app/table/visibility"]) === "optional";
2002
2011
  }
2003
2012
  function jn(t, e, n, r, i) {
2004
2013
  var g, x;
2005
- const s = (i == null ? void 0 : i.coreJoinType) ?? "full", o = [...(i == null ? void 0 : i.filters) ?? [], ...((g = r == null ? void 0 : r.pTableParams) == null ? void 0 : g.filters) ?? []], a = ((x = r == null ? void 0 : r.pTableParams) == null ? void 0 : x.sorting) ?? [], l = e.filter((p) => !Ht(p.spec)), u = l.find((p) => n(p.spec));
2014
+ const s = (i == null ? void 0 : i.coreJoinType) ?? "full", o = [...(i == null ? void 0 : i.filters) ?? [], ...((g = r == null ? void 0 : r.pTableParams) == null ? void 0 : g.filters) ?? []], a = ((x = r == null ? void 0 : r.pTableParams) == null ? void 0 : x.sorting) ?? [], l = e.filter((p) => !Gt(p.spec)), u = l.find((p) => n(p.spec));
2006
2015
  if (!u) return;
2007
- const d = Ue(t.resultPool);
2016
+ const d = Me(t.resultPool);
2008
2017
  if (!d) return;
2009
2018
  const y = new Set((() => {
2010
2019
  var A, m;
2011
2020
  if (s === "inner") return [];
2012
2021
  const p = (m = (A = r == null ? void 0 : r.gridState.columnVisibility) == null ? void 0 : A.hiddenColIds) == null ? void 0 : m.map(fe).filter((v) => v.type === "column").map((v) => v.id);
2013
- return p || l.filter((v) => qt(v.spec)).map((v) => v.id);
2022
+ return p || l.filter((v) => Ht(v.spec)).map((v) => v.id);
2014
2023
  })());
2015
2024
  y.delete(u.id), [...o.map((p) => p.column), ...a.map((p) => p.column)].filter((p) => p.type === "column").map((p) => y.delete(p.id));
2016
2025
  const b = l.filter((p) => !y.has(p.id)), f = Be(b.map(Oe), d), w = [
@@ -2049,9 +2058,9 @@ function $n(t) {
2049
2058
  const e = t.type;
2050
2059
  switch (e) {
2051
2060
  case "axis":
2052
- return F(t);
2061
+ return D(t);
2053
2062
  case "column":
2054
- return F(t);
2063
+ return D(t);
2055
2064
  default:
2056
2065
  throw Error(`unsupported column type: ${e}`);
2057
2066
  }
@@ -2077,7 +2086,7 @@ function Nn(t, e, n, r) {
2077
2086
  function Jn(t) {
2078
2087
  return t === pt ? (console.error("Axis value can never be N/A"), "") : t;
2079
2088
  }
2080
- class Mn {
2089
+ class Un {
2081
2090
  constructor(e) {
2082
2091
  this.handle = e;
2083
2092
  }
@@ -2097,28 +2106,28 @@ class Mn {
2097
2106
  return await platforma.pFrameDriver.getUniqueValues(this.handle, e);
2098
2107
  }
2099
2108
  }
2100
- function zt(t) {
2101
- return Re({
2109
+ function qt(t) {
2110
+ return Fe({
2102
2111
  __isRef: !0,
2103
2112
  blockId: ie(t, "blockId"),
2104
2113
  name: ie(t, "name")
2105
2114
  });
2106
2115
  }
2107
- function Un(t) {
2108
- return Re({
2109
- ref: zt(ie(t, "ref")),
2116
+ function Mn(t) {
2117
+ return Fe({
2118
+ ref: qt(ie(t, "ref")),
2110
2119
  label: ie(t, "label")
2111
2120
  });
2112
2121
  }
2113
2122
  const Bn = {
2114
2123
  sdkVersion: Y
2115
2124
  };
2116
- function Yt() {
2117
- return De({ sdkVersion: Y });
2125
+ function zt() {
2126
+ return Re({ sdkVersion: Y });
2118
2127
  }
2119
2128
  function Wn(t) {
2120
2129
  try {
2121
- return Yt();
2130
+ return zt();
2122
2131
  } catch {
2123
2132
  return t;
2124
2133
  }
@@ -2128,21 +2137,21 @@ function Gn(t) {
2128
2137
  return globalThis.getEnvironmentValue(t);
2129
2138
  }
2130
2139
  export {
2131
- rn as Args,
2140
+ nn as Args,
2132
2141
  E as BlockModel,
2133
2142
  Bn as CurrentSdkInfo,
2134
2143
  I as FutureRef,
2135
- Mt as IS_VIRTUAL_COLUMN,
2136
- sn as It,
2137
- On as JsRenderInternal,
2144
+ Ut as IS_VIRTUAL_COLUMN,
2145
+ rn as It,
2146
+ En as JsRenderInternal,
2138
2147
  Te as LABEL_ANNOTATION,
2139
- Ut as LINKER_COLUMN_ANNOTATION,
2140
- on as MainOutputs,
2148
+ Mt as LINKER_COLUMN_ANNOTATION,
2149
+ sn as MainOutputs,
2141
2150
  dt as OutputError,
2142
2151
  bt as PAnnotationLabel,
2143
2152
  wt as PAnnotationTrace,
2144
2153
  ve as PColumnCollection,
2145
- Mn as PFrameImpl,
2154
+ Un as PFrameImpl,
2146
2155
  B as RT_BINARY_PARTITIONED,
2147
2156
  z as RT_BINARY_SUPER_PARTITIONED,
2148
2157
  q as RT_JSON_PARTITIONED,
@@ -2150,75 +2159,75 @@ export {
2150
2159
  se as RT_RESOURCE_MAP,
2151
2160
  oe as RT_RESOURCE_MAP_PARTITIONED,
2152
2161
  te as RenderCtx,
2153
- Ft as ResultPool,
2154
- an as StagingOutputs,
2162
+ Dt as ResultPool,
2163
+ on as StagingOutputs,
2155
2164
  xt as Trace,
2156
2165
  At as TraceEntry,
2157
2166
  O as TreeNodeAccessor,
2158
- ln as UiState,
2167
+ an as UiState,
2159
2168
  We as allColumnsComputed,
2160
- gn as and,
2169
+ hn as and,
2161
2170
  Tt as convertOrParsePColumnData,
2162
- Dn as createPFrameForGraphs,
2171
+ Rn as createPFrameForGraphs,
2163
2172
  Kn as createPlDataTable,
2164
2173
  Vn as createPlDataTableSheet,
2165
2174
  jn as createPlDataTableV2,
2166
2175
  Nn as createRowSelectionColumn,
2167
2176
  Ve as deriveLabels,
2168
2177
  de as downgradeCfgOrLambda,
2169
- Wt as enrichColumnsWithCompatible,
2170
- Sn as extractArchiveAndGetURL,
2171
- Rn as extractConfig,
2178
+ Bt as enrichColumnsWithCompatible,
2179
+ Pn as extractArchiveAndGetURL,
2180
+ kn as extractConfig,
2172
2181
  Lt as filterDataInfoEntries,
2173
- dn as flatten,
2174
- Un as fromPlOption,
2175
- zt as fromPlRef,
2176
- Bt as getAdditionalColumns,
2177
- Ue as getAllLabelColumns,
2178
- wn as getBlobContent,
2179
- xn as getBlobContentAsJson,
2180
- An as getBlobContentAsString,
2181
- Cn as getDownloadedBlobContent,
2182
+ pn as flatten,
2183
+ Mn as fromPlOption,
2184
+ qt as fromPlRef,
2185
+ Fn as getAdditionalColumns,
2186
+ Me as getAllLabelColumns,
2187
+ bn as getBlobContent,
2188
+ An as getBlobContentAsJson,
2189
+ wn as getBlobContentAsString,
2190
+ xn as getDownloadedBlobContent,
2182
2191
  Gn as getEnvironmentValue,
2183
2192
  Q as getFromCfg,
2184
2193
  re as getImmediate,
2185
- _n as getImportProgress,
2194
+ Sn as getImportProgress,
2186
2195
  ie as getJsonField,
2187
- In as getLastLogs,
2196
+ _n as getLastLogs,
2188
2197
  Nt as getLinkerColumnsMap,
2189
- En as getLogHandle,
2198
+ Ln as getLogHandle,
2190
2199
  Be as getMatchingLabelColumns,
2191
- Pn as getOnDemandBlobContent,
2200
+ Cn as getOnDemandBlobContent,
2192
2201
  St as getPartitionKeysList,
2193
2202
  Wn as getPlatformaOrDefault,
2194
- Tn as getProgressLog,
2195
- Ln as getProgressLogWithInfo,
2196
- Yt as getRawPlatformaInstance,
2197
- yn as getResourceField,
2198
- vn as getResourceValueAsJson,
2203
+ In as getProgressLog,
2204
+ Tn as getProgressLogWithInfo,
2205
+ zt as getRawPlatformaInstance,
2206
+ mn as getResourceField,
2207
+ yn as getResourceValueAsJson,
2199
2208
  It as getUniquePartitionKeys,
2200
2209
  Je as hasPathWithLinkerColumns,
2201
2210
  he as ifDef,
2202
- Ht as isColumnHidden,
2203
- qt as isColumnOptional,
2211
+ Gt as isColumnHidden,
2212
+ Ht as isColumnOptional,
2204
2213
  Kt as isConfigLambda,
2205
- fn as isEmpty,
2206
- Gt as isLabelColumn,
2214
+ dn as isEmpty,
2215
+ Wt as isLabelColumn,
2207
2216
  $t as isLinkerColumn,
2208
- nn as isolate,
2209
- un as makeArray,
2210
- Re as makeObject,
2211
- pn as mapArrayValues,
2217
+ tn as isolate,
2218
+ ln as makeArray,
2219
+ Fe as makeObject,
2220
+ cn as mapArrayValues,
2212
2221
  Jn as mapPTableValueToAxisKey,
2213
- cn as mapRecordValues,
2214
- bn as mapResourceFields,
2215
- hn as not,
2216
- mn as or,
2222
+ un as mapRecordValues,
2223
+ vn as mapResourceFields,
2224
+ fn as not,
2225
+ gn as or,
2217
2226
  ye as parsePColumnData,
2218
- kn as parseResourceMap,
2227
+ On as parseResourceMap,
2219
2228
  ft as readOutput,
2220
2229
  $n as stringifyPTableColumnId,
2221
- Fn as stringifyPTableColumnSpec,
2222
- tn as wrapOutputs
2230
+ Dn as stringifyPTableColumnSpec,
2231
+ en as wrapOutputs
2223
2232
  };
2224
2233
  //# sourceMappingURL=index.mjs.map