@platforma-sdk/ui-vue 1.42.14 → 1.42.18

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.
Files changed (56) hide show
  1. package/.turbo/turbo-build.log +25 -24
  2. package/.turbo/turbo-type-check.log +1 -1
  3. package/CHANGELOG.md +16 -0
  4. package/dist/components/PlAgDataTable/PlAgDataTableSheets.vue2.js +5 -5
  5. package/dist/components/PlAgDataTable/PlAgDataTableV2.vue2.js +21 -21
  6. package/dist/components/PlAgDataTable/sources/table-source-v2.d.ts.map +1 -1
  7. package/dist/components/PlAgDataTable/sources/table-source-v2.js +122 -123
  8. package/dist/components/PlAgDataTable/sources/table-source-v2.js.map +1 -1
  9. package/dist/components/PlAgDataTable/sources/table-state-v2.js +9 -9
  10. package/dist/components/PlAgDataTable/sources/value-rendering.d.ts.map +1 -1
  11. package/dist/components/PlAgDataTable/sources/value-rendering.js +24 -25
  12. package/dist/components/PlAgDataTable/sources/value-rendering.js.map +1 -1
  13. package/dist/components/PlAnnotations/components/DynamicForm.vue2.js +12 -12
  14. package/dist/components/PlAnnotations/components/FilterSidebar.vue2.js +2 -2
  15. package/dist/components/PlAppErrorNotificationAlert/PlAppErrorNotificationAlert.vue.d.ts.map +1 -1
  16. package/dist/components/PlAppErrorNotificationAlert/PlAppErrorNotificationAlert.vue.js +21 -20
  17. package/dist/components/PlAppErrorNotificationAlert/PlAppErrorNotificationAlert.vue.js.map +1 -1
  18. package/dist/components/PlMultiSequenceAlignment/data.d.ts.map +1 -1
  19. package/dist/components/PlMultiSequenceAlignment/data.js +169 -184
  20. package/dist/components/PlMultiSequenceAlignment/data.js.map +1 -1
  21. package/dist/components/PlTableFilters/filters-state.js +8 -8
  22. package/dist/components/PlTableFilters/filters_logic.d.ts.map +1 -1
  23. package/dist/components/PlTableFilters/filters_logic.js +67 -77
  24. package/dist/components/PlTableFilters/filters_logic.js.map +1 -1
  25. package/dist/defineApp.js +20 -20
  26. package/dist/internal/UpdateSerializer.js +3 -3
  27. package/dist/lib/model/common/dist/index.js +576 -444
  28. package/dist/lib/model/common/dist/index.js.map +1 -1
  29. package/dist/lib/ui/uikit/dist/components/DataTable/TableComponent.vue.js +1 -1
  30. package/dist/lib/ui/uikit/dist/components/PlAccordion/PlAccordionSection.vue2.js +1 -1
  31. package/dist/lib/ui/uikit/dist/components/PlFileDialog/Local.vue.js +6 -6
  32. package/dist/lib/ui/uikit/dist/components/PlFileInput/PlFileInput.vue.js +17 -17
  33. package/dist/lib/ui/uikit/dist/components/PlFileInput/PlFileInput.vue.js.map +1 -1
  34. package/dist/lib/ui/uikit/dist/components/PlLogView/PlLogView.vue.js +89 -63
  35. package/dist/lib/ui/uikit/dist/components/PlLogView/PlLogView.vue.js.map +1 -1
  36. package/dist/lib/ui/uikit/dist/components/PlSlideModal/PlPureSlideModal.vue.js +1 -1
  37. package/dist/lib/ui/uikit/dist/helpers/dom.js.map +1 -1
  38. package/dist/lib/ui/uikit/dist/helpers/downloadContent.js +32 -0
  39. package/dist/lib/ui/uikit/dist/helpers/downloadContent.js.map +1 -0
  40. package/dist/lib/ui/uikit/dist/lib/model/common/dist/index.js +257 -192
  41. package/dist/lib/ui/uikit/dist/lib/model/common/dist/index.js.map +1 -1
  42. package/dist/lib/ui/uikit/dist/sdk/model/dist/index.js +473 -457
  43. package/dist/lib/ui/uikit/dist/sdk/model/dist/index.js.map +1 -1
  44. package/dist/lib.js +52 -50
  45. package/dist/lib.js.map +1 -1
  46. package/dist/sdk/model/dist/index.js +542 -526
  47. package/dist/sdk/model/dist/index.js.map +1 -1
  48. package/package.json +3 -3
  49. package/src/components/PlAgDataTable/sources/table-source-v2.ts +20 -16
  50. package/src/components/PlAgDataTable/sources/value-rendering.ts +15 -7
  51. package/src/components/PlAppErrorNotificationAlert/PlAppErrorNotificationAlert.vue +1 -0
  52. package/src/components/PlMultiSequenceAlignment/data.ts +12 -12
  53. package/src/components/PlTableFilters/filters_logic.ts +18 -15
  54. package/.turbo/turbo-test.log +0 -565
  55. package/dist/lib/ui/uikit/dist/components/PlAccordion/ExpandTransition.vue.js +0 -27
  56. package/dist/lib/ui/uikit/dist/components/PlAccordion/ExpandTransition.vue.js.map +0 -1
@@ -1,52 +1,52 @@
1
- import { isPTableAbsent as ke, uniquePlId as Ne, isDataInfo as ue, extractAllColumns as De, mapPTableDef as Re, selectorsToPredicate as W, withEnrichments as ce, AnchoredIdDeriver as fe, isPlRef as Ue, mapValueInVOE as $e, mapPObjectData as pe, ensurePColumn as Ke, isPColumnSpec as Y, isPColumn as Ce, resolveAnchors as he, deriveNativeId as je, isPartitionedDataInfoEntries as Be, getAxisId as ge, entriesToDataInfo as Je, isDataInfoEntries as _e, dataInfoToEntries as Me, canonicalizeAxisId as qe, mapDataInfo as We } from "../../../lib/model/common/dist/index.js";
2
- import { PTableAbsent as $t, PTableNA as Kt, PlId as jt, PlIdBytes as Bt, PlIdLength as Jt, canonicalizeJson as Mt, deserializeError as qt, ensureError as Wt, getAxesId as Ht, getPTableColumnId as Xt, hasAbortError as zt, isPTableNA as Gt, isPTableValueAxis as Yt, mapJoinEntry as Qt, matchAxis as Zt, matchAxisId as en, matchPColumn as tn, pTableValue as nn, parseJson as rn, stringifyColumnId as sn, unwrapResult as an } from "../../../lib/model/common/dist/index.js";
3
- import Se from "../../../_virtual/canonicalize.js";
1
+ import { PColumnName as ue, readAnnotation as M, readAnnotationJson as Ne, isPTableAbsent as Re, stringifyJson as $e, ValueType as Ke, uniquePlId as Be, Annotation as O, isDataInfo as de, extractAllColumns as je, mapPTableDef as Je, selectorsToPredicate as q, withEnrichments as ge, AnchoredIdDeriver as me, isPlRef as Me, mapValueInVOE as qe, mapPObjectData as pe, ensurePColumn as We, isPColumnSpec as Y, isPColumn as _e, parseJson as He, resolveAnchors as ye, deriveNativeId as Xe, isPartitionedDataInfoEntries as ze, getAxisId as be, entriesToDataInfo as Ge, isDataInfoEntries as Ae, dataInfoToEntries as Ye, canonicalizeAxisId as Qe, mapDataInfo as Ze } from "../../../lib/model/common/dist/index.js";
2
+ import { AnnotationJson as Jt, AxisSpec as Mt, Domain as qt, PTableAbsent as Wt, PTableNA as Ht, PlId as Xt, PlIdBytes as zt, PlIdLength as Gt, canonicalizeJson as Yt, deserializeError as Qt, ensureError as Zt, getAxesId as en, getPTableColumnId as tn, hasAbortError as nn, isPTableNA as rn, isPTableValueAxis as sn, mapJoinEntry as an, matchAxis as on, matchAxisId as ln, matchPColumn as un, pTableValue as dn, readDomain as pn, readMetadata as cn, readMetadataJson as fn, readMetadataJsonOrThrow as hn, stringifyColumnId as gn, unwrapResult as mn } from "../../../lib/model/common/dist/index.js";
3
+ import Ie from "../../../_virtual/canonicalize.js";
4
4
  import U from "../../../node_modules/.pnpm/zod@3.23.8/node_modules/zod/lib/index.js";
5
- import { BasePlErrorLike as ln, ErrorLike as un, PlErrorLike as pn, StandardErrorLike as dn, ensureErrorLike as cn } from "../../../lib/model/pl-error-like/dist/index.js";
6
- var He = Object.defineProperty, Xe = (n, e, t) => e in n ? He(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, w = (n, e, t) => Xe(n, typeof e != "symbol" ? e + "" : e, t);
5
+ import { BasePlErrorLike as bn, ErrorLike as vn, PlErrorLike as Tn, StandardErrorLike as Pn, ensureErrorLike as Cn } from "../../../lib/model/pl-error-like/dist/index.js";
6
+ var et = Object.defineProperty, tt = (n, e, t) => e in n ? et(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t, S = (n, e, t) => tt(n, typeof e != "symbol" ? e + "" : e, t);
7
7
  function ee(n) {
8
8
  return { type: "Immediate", value: n };
9
9
  }
10
- function ze() {
10
+ function nt() {
11
11
  return typeof globalThis.getPlatforma < "u" || typeof globalThis.platforma < "u";
12
12
  }
13
- function we(n) {
13
+ function xe(n) {
14
14
  if (n && typeof globalThis.getPlatforma == "function")
15
15
  return globalThis.getPlatforma(n);
16
16
  if (typeof globalThis.platforma < "u") return globalThis.platforma;
17
17
  throw new Error("Can't get platforma instance.");
18
18
  }
19
- function Ge() {
19
+ function rt() {
20
20
  if (typeof globalThis.cfgRenderCtx < "u") return globalThis.cfgRenderCtx;
21
21
  }
22
- function p() {
22
+ function d() {
23
23
  if (typeof globalThis.cfgRenderCtx < "u") return globalThis.cfgRenderCtx;
24
24
  throw new Error("Not in config rendering context");
25
25
  }
26
- function J(n, e) {
27
- const t = Ge();
26
+ function B(n, e) {
27
+ const t = rt();
28
28
  if (t === void 0) return !1;
29
29
  if (n in t.callbackRegistry) throw new Error(`Callback with key ${n} already registered.`);
30
30
  return t.callbackRegistry[n] = e, !0;
31
31
  }
32
32
  const te = /* @__PURE__ */ new Map();
33
- function Ye(n, e) {
34
- n in p().callbackRegistry || (p().callbackRegistry[n] = (t) => {
33
+ function it(n, e) {
34
+ n in d().callbackRegistry || (d().callbackRegistry[n] = (t) => {
35
35
  for (const r of te.get(n))
36
36
  r(t);
37
37
  }, te.set(n, [])), te.get(n).push(e);
38
38
  }
39
- class P {
39
+ class C {
40
40
  constructor(e, t = (r) => r) {
41
- w(this, "isResolved", !1), w(this, "resolvedValue"), this.handle = e, this.postProcess = t, Ye(e, (r) => {
41
+ S(this, "isResolved", !1), S(this, "resolvedValue"), this.handle = e, this.postProcess = t, it(e, (r) => {
42
42
  this.resolvedValue = t(r), this.isResolved = !0;
43
43
  });
44
44
  }
45
45
  map(e) {
46
- return new P(this.handle, (t) => e(this.postProcess(t)));
46
+ return new C(this.handle, (t) => e(this.postProcess(t)));
47
47
  }
48
48
  mapDefined(e) {
49
- return new P(this.handle, (t) => {
49
+ return new C(this.handle, (t) => {
50
50
  const r = this.postProcess(t);
51
51
  return r ? e(r) : void 0;
52
52
  });
@@ -98,46 +98,46 @@ class I {
98
98
  ...t.map((i) => typeof i == "string" ? i : i.field)
99
99
  ];
100
100
  return ie(
101
- p().resolveWithCommon(this.handle, e, ...t),
101
+ d().resolveWithCommon(this.handle, e, ...t),
102
102
  (i) => new I(i, r)
103
103
  );
104
104
  }
105
105
  get resourceType() {
106
- return p().getResourceType(this.handle);
106
+ return d().getResourceType(this.handle);
107
107
  }
108
108
  getInputsLocked() {
109
- return p().getInputsLocked(this.handle);
109
+ return d().getInputsLocked(this.handle);
110
110
  }
111
111
  getOutputsLocked() {
112
- return p().getOutputsLocked(this.handle);
112
+ return d().getOutputsLocked(this.handle);
113
113
  }
114
114
  getIsReadyOrError() {
115
- return p().getIsReadyOrError(this.handle);
115
+ return d().getIsReadyOrError(this.handle);
116
116
  }
117
117
  getIsFinal() {
118
- return p().getIsFinal(this.handle);
118
+ return d().getIsFinal(this.handle);
119
119
  }
120
120
  getError() {
121
121
  const e = [...this.resolvePath, "error"];
122
122
  return ie(
123
- p().getError(this.handle),
123
+ d().getError(this.handle),
124
124
  (t) => new I(t, e)
125
125
  );
126
126
  }
127
127
  listInputFields() {
128
- return p().listInputFields(this.handle);
128
+ return d().listInputFields(this.handle);
129
129
  }
130
130
  listOutputFields() {
131
- return p().listOutputFields(this.handle);
131
+ return d().listOutputFields(this.handle);
132
132
  }
133
133
  listDynamicFields() {
134
- return p().listDynamicFields(this.handle);
134
+ return d().listDynamicFields(this.handle);
135
135
  }
136
136
  getKeyValueBase64(e) {
137
- return p().getKeyValueBase64(this.handle, e);
137
+ return d().getKeyValueBase64(this.handle, e);
138
138
  }
139
139
  getKeyValueAsString(e) {
140
- return p().getKeyValueAsString(this.handle, e);
140
+ return d().getKeyValueAsString(this.handle, e);
141
141
  }
142
142
  getKeyValueAsJson(e) {
143
143
  const t = this.getKeyValueAsString(e);
@@ -145,10 +145,10 @@ class I {
145
145
  return JSON.parse(t);
146
146
  }
147
147
  getDataBase64() {
148
- return p().getDataBase64(this.handle);
148
+ return d().getDataBase64(this.handle);
149
149
  }
150
150
  getDataAsString() {
151
- return p().getDataAsString(this.handle);
151
+ return d().getDataAsString(this.handle);
152
152
  }
153
153
  getDataAsJson() {
154
154
  const e = this.getDataAsString();
@@ -161,7 +161,7 @@ class I {
161
161
  getPColumns(e = !1, t = "") {
162
162
  const r = this.parsePObjectCollection(e, t);
163
163
  return r === void 0 ? void 0 : Object.entries(r).map(([, i]) => {
164
- if (!Ce(i)) throw new Error(`not a PColumn (kind = ${i.spec.kind})`);
164
+ if (!_e(i)) throw new Error(`not a PColumn (kind = ${i.spec.kind})`);
165
165
  return i;
166
166
  });
167
167
  }
@@ -169,7 +169,7 @@ class I {
169
169
  *
170
170
  */
171
171
  parsePObjectCollection(e = !1, t = "") {
172
- const r = p().parsePObjectCollection(
172
+ const r = d().parsePObjectCollection(
173
173
  this.handle,
174
174
  e,
175
175
  t,
@@ -177,21 +177,21 @@ class I {
177
177
  );
178
178
  if (r === void 0) return;
179
179
  const i = {};
180
- for (const [s, a] of Object.entries(r)) {
181
- const o = [...this.resolvePath, s];
182
- i[s] = pe(a, (l) => new I(l, o));
180
+ for (const [a, s] of Object.entries(r)) {
181
+ const o = [...this.resolvePath, a];
182
+ i[a] = pe(s, (l) => new I(l, o));
183
183
  }
184
184
  return i;
185
185
  }
186
186
  getFileContentAsBase64(e) {
187
- return new P(p().getBlobContentAsBase64(this.handle, e));
187
+ return new C(d().getBlobContentAsBase64(this.handle, e));
188
188
  }
189
189
  getFileContentAsString(e) {
190
- return new P(p().getBlobContentAsString(this.handle, e));
190
+ return new C(d().getBlobContentAsString(this.handle, e));
191
191
  }
192
192
  getFileContentAsJson(e) {
193
- return new P(
194
- p().getBlobContentAsString(this.handle, e)
193
+ return new C(
194
+ d().getBlobContentAsString(this.handle, e)
195
195
  ).mapDefined((t) => JSON.parse(t));
196
196
  }
197
197
  /**
@@ -210,7 +210,7 @@ class I {
210
210
  * @returns downloaded file handle
211
211
  */
212
212
  getFileHandle() {
213
- return new P(p().getDownloadedBlobContentHandle(this.handle));
213
+ return new C(d().getDownloadedBlobContentHandle(this.handle));
214
214
  }
215
215
  /**
216
216
  * @deprecated use getFileHandle
@@ -222,7 +222,7 @@ class I {
222
222
  * @returns downloaded file handle
223
223
  */
224
224
  getRemoteFileHandle() {
225
- return new P(p().getOnDemandBlobContentHandle(this.handle));
225
+ return new C(d().getOnDemandBlobContentHandle(this.handle));
226
226
  }
227
227
  /**
228
228
  * @deprecated use getRemoteFileHandle
@@ -234,22 +234,22 @@ class I {
234
234
  * @returns the url to the extracted folder
235
235
  */
236
236
  extractArchiveAndGetURL(e) {
237
- return new P(p().extractArchiveAndGetURL(this.handle, e));
237
+ return new C(d().extractArchiveAndGetURL(this.handle, e));
238
238
  }
239
239
  getImportProgress() {
240
- return new P(p().getImportProgress(this.handle));
240
+ return new C(d().getImportProgress(this.handle));
241
241
  }
242
242
  getLastLogs(e) {
243
- return new P(p().getLastLogs(this.handle, e));
243
+ return new C(d().getLastLogs(this.handle, e));
244
244
  }
245
245
  getProgressLog(e) {
246
- return new P(p().getProgressLog(this.handle, e));
246
+ return new C(d().getProgressLog(this.handle, e));
247
247
  }
248
248
  getProgressLogWithInfo(e) {
249
- return new P(p().getProgressLogWithInfo(this.handle, e));
249
+ return new C(d().getProgressLogWithInfo(this.handle, e));
250
250
  }
251
251
  getLogHandle() {
252
- return new P(p().getLogHandle(this.handle));
252
+ return new C(d().getLogHandle(this.handle));
253
253
  }
254
254
  allFieldsResolved(e = "Input") {
255
255
  switch (e) {
@@ -264,107 +264,106 @@ class I {
264
264
  }
265
265
  }
266
266
  mapFields(e, t) {
267
- const { fieldType: r, requireLocked: i, skipUnresolved: s } = {
267
+ const { fieldType: r, requireLocked: i, skipUnresolved: a } = {
268
268
  fieldType: "Input",
269
269
  requireLocked: !0,
270
270
  skipUnresolved: !1,
271
271
  ...t
272
- }, a = e;
272
+ }, s = e;
273
273
  if (i && (r === "Input" && !this.getInputsLocked() || r === "Output" && !this.getOutputsLocked()))
274
274
  return;
275
275
  let o = (r === "Input" ? this.listInputFields() : r === "Output" ? this.listOutputFields() : this.listDynamicFields()).map(
276
276
  (l) => [l, this.resolve({ field: l, assertFieldType: r })]
277
277
  );
278
- return s && (o = o.filter((l) => l[1] !== void 0)), o.map(([l, y]) => a(l, y));
278
+ return a && (o = o.filter((l) => l[1] !== void 0)), o.map(([l, g]) => s(l, g));
279
279
  }
280
280
  }
281
- const Qe = "staging", Ze = "main", et = "pl7.app/label", tt = "pl7.app/trace", nt = U.object({
281
+ const st = "staging", at = "main", ot = U.object({
282
282
  type: U.string(),
283
283
  importance: U.number().optional(),
284
284
  id: U.string().optional(),
285
285
  label: U.string()
286
- }), rt = U.array(nt), it = 1e-3, st = "__LABEL__", me = "__LABEL__@1";
287
- function Ie(n, e, t = {}) {
288
- const r = /* @__PURE__ */ new Map(), i = t.forceTraceElements !== void 0 && t.forceTraceElements.length > 0 ? new Set(t.forceTraceElements) : void 0, s = /* @__PURE__ */ new Map(), a = n.map((h) => {
289
- var C, u;
290
- const d = e(h);
291
- let b, A, F;
292
- "spec" in d && typeof d.spec == "object" ? (b = d.spec, A = d.prefixTrace, F = d.suffixTrace) : b = d;
293
- const c = (C = b.annotations) == null ? void 0 : C[et], _ = (u = b.annotations) == null ? void 0 : u[tt], f = (_ ? rt.safeParse(JSON.parse(_)).data : void 0) ?? [], g = [
294
- ...A ?? [],
295
- ...f,
296
- ...F ?? []
286
+ }), lt = U.array(ot), ut = 1e-3, dt = "__LABEL__", ve = "__LABEL__@1";
287
+ function Fe(n, e, t = {}) {
288
+ const r = /* @__PURE__ */ new Map(), i = t.forceTraceElements !== void 0 && t.forceTraceElements.length > 0 ? new Set(t.forceTraceElements) : void 0, a = /* @__PURE__ */ new Map(), s = n.map((f) => {
289
+ const m = e(f);
290
+ let u, y, T;
291
+ "spec" in m && typeof m.spec == "object" ? (u = m.spec, y = m.prefixTrace, T = m.suffixTrace) : u = m;
292
+ const _ = M(u, O.Label), x = M(u, O.Trace), b = (x ? lt.safeParse(He(x)).data : void 0) ?? [], h = [
293
+ ...y ?? [],
294
+ ...b,
295
+ ...T ?? []
297
296
  ];
298
- if (c !== void 0) {
299
- const S = { label: c, type: st, importance: -2 };
300
- t.addLabelAsSuffix ? g.push(S) : g.splice(0, 0, S);
297
+ if (_ !== void 0) {
298
+ const p = { label: _, type: dt, importance: -2 };
299
+ t.addLabelAsSuffix ? h.push(p) : h.splice(0, 0, p);
301
300
  }
302
- const m = [], L = /* @__PURE__ */ new Map();
303
- for (let S = g.length - 1; S >= 0; --S) {
304
- const { type: j } = g[S], k = g[S].importance ?? 0, D = (L.get(j) ?? 0) + 1;
305
- L.set(j, D);
306
- const O = `${j}@${D}`;
307
- s.set(O, (s.get(O) ?? 0) + 1), r.set(
308
- O,
301
+ const c = [], w = /* @__PURE__ */ new Map();
302
+ for (let p = h.length - 1; p >= 0; --p) {
303
+ const { type: F } = h[p], H = h[p].importance ?? 0, $ = (w.get(F) ?? 0) + 1;
304
+ w.set(F, $);
305
+ const A = `${F}@${$}`;
306
+ a.set(A, (a.get(A) ?? 0) + 1), r.set(
307
+ A,
309
308
  Math.max(
310
- r.get(O) ?? Number.NEGATIVE_INFINITY,
311
- k - (g.length - S) * it
309
+ r.get(A) ?? Number.NEGATIVE_INFINITY,
310
+ H - (h.length - p) * ut
312
311
  )
313
- ), m.push({ ...g[S], fullType: O, occurrenceIndex: D });
312
+ ), c.push({ ...h[p], fullType: A, occurrenceIndex: $ });
314
313
  }
315
- return m.reverse(), {
316
- value: h,
317
- spec: b,
318
- label: c,
319
- fullTrace: m
314
+ return c.reverse(), {
315
+ value: f,
316
+ spec: u,
317
+ label: _,
318
+ fullTrace: c
320
319
  };
321
- }), o = [], l = [], y = [...r];
322
- y.sort(([, h], [, C]) => C - h);
323
- for (const [h] of y)
324
- h.endsWith("@1") || s.get(h) === n.length ? o.push(h) : l.push(h);
325
- const K = (h, C = !1) => {
320
+ }), o = [], l = [], g = [...r];
321
+ g.sort(([, f], [, m]) => m - f);
322
+ for (const [f] of g)
323
+ f.endsWith("@1") || a.get(f) === n.length ? o.push(f) : l.push(f);
324
+ const R = (f, m = !1) => {
326
325
  const u = [];
327
- for (let d = 0; d < a.length; d++) {
328
- const b = a[d], A = b.fullTrace.filter((_) => h.has(_.fullType) || i && i.has(_.type));
329
- if (A.length === 0)
330
- if (C)
326
+ for (let y = 0; y < s.length; y++) {
327
+ const T = s[y], _ = T.fullTrace.filter((h) => f.has(h.fullType) || i && i.has(h.type));
328
+ if (_.length === 0)
329
+ if (m)
331
330
  u.push({
332
331
  label: "Unlabeled",
333
- value: b.value
332
+ value: T.value
334
333
  });
335
334
  else return;
336
- const F = A.map((_) => _.label), c = t.separator ?? " / ";
335
+ const x = _.map((h) => h.label), b = t.separator ?? " / ";
337
336
  u.push({
338
- label: F.join(c),
339
- value: b.value
337
+ label: x.join(b),
338
+ value: T.value
340
339
  });
341
340
  }
342
341
  return u;
343
342
  };
344
343
  if (o.length === 0) {
345
344
  if (l.length !== 0) throw new Error("Non-empty secondary types list while main types list is empty.");
346
- return K(new Set(me), !0);
347
- }
348
- let E = 0, V = -1;
349
- for (; E < o.length; ) {
350
- const h = /* @__PURE__ */ new Set();
351
- t.includeNativeLabel && h.add(me);
352
- for (let u = 0; u < E; ++u) h.add(o[u]);
353
- V >= 0 && h.add(o[V]);
354
- const C = K(h);
355
- if (C !== void 0 && new Set(C.map((u) => u.label)).size === n.length) return C;
356
- V++, V >= o.length && (E++, V = E);
357
- }
358
- return K(/* @__PURE__ */ new Set([...o, ...l]), !0);
345
+ return R(new Set(ve), !0);
346
+ }
347
+ let L = 0, V = -1;
348
+ for (; L < o.length; ) {
349
+ const f = /* @__PURE__ */ new Set();
350
+ t.includeNativeLabel && f.add(ve);
351
+ for (let u = 0; u < L; ++u) f.add(o[u]);
352
+ V >= 0 && f.add(o[V]);
353
+ const m = R(f);
354
+ if (m !== void 0 && new Set(m.map((u) => u.label)).size === n.length) return m;
355
+ V++, V >= o.length && (L++, V = L);
356
+ }
357
+ return R(/* @__PURE__ */ new Set([...o, ...l]), !0);
359
358
  }
360
- const H = "PColumnData/", se = H + "ResourceMap", ae = H + "Partitioned/ResourceMap", M = H + "JsonPartitioned", $ = H + "BinaryPartitioned", Ae = H + "Partitioned/", Z = Ae + "JsonPartitioned", q = Ae + "BinaryPartitioned", oe = (n) => {
359
+ const W = "PColumnData/", se = W + "ResourceMap", ae = W + "Partitioned/ResourceMap", j = W + "JsonPartitioned", N = W + "BinaryPartitioned", Ee = W + "Partitioned/", Z = Ee + "JsonPartitioned", J = Ee + "BinaryPartitioned", oe = (n) => {
361
360
  if (n.endsWith(".index"))
362
361
  return { baseKey: n.substring(0, n.length - 6), type: "index" };
363
362
  if (n.endsWith(".values"))
364
363
  return { baseKey: n.substring(0, n.length - 7), type: "values" };
365
364
  throw new Error(`key must ends on .index/.values for binary p-column, got: ${n}`);
366
365
  };
367
- function at(n) {
366
+ function pt(n) {
368
367
  if (!n) return;
369
368
  const e = n.resourceType.name, t = n.getDataAsJson(), r = [];
370
369
  let i = 0;
@@ -375,95 +374,95 @@ function at(n) {
375
374
  case ae:
376
375
  i = t.partitionKeyLength + t.keyLength;
377
376
  break;
378
- case M:
379
- case $:
377
+ case j:
378
+ case N:
380
379
  i = t.partitionKeyLength;
381
380
  break;
382
- case q:
381
+ case J:
383
382
  case Z:
384
383
  i = t.superPartitionKeyLength + t.partitionKeyLength;
385
384
  break;
386
385
  }
387
386
  switch (e) {
388
387
  case se:
389
- case M:
390
- case $:
391
- for (let s of n.listInputFields()) {
392
- e === $ && (s = oe(s).baseKey);
393
- const a = [...JSON.parse(s)];
394
- r.push(a);
388
+ case j:
389
+ case N:
390
+ for (let a of n.listInputFields()) {
391
+ e === N && (a = oe(a).baseKey);
392
+ const s = [...JSON.parse(a)];
393
+ r.push(s);
395
394
  }
396
395
  break;
397
396
  case ae:
398
- case q:
397
+ case J:
399
398
  case Z:
400
- for (const s of n.listInputFields()) {
401
- const a = [...JSON.parse(s)], o = n.resolve({ field: s, assertFieldType: "Input" });
399
+ for (const a of n.listInputFields()) {
400
+ const s = [...JSON.parse(a)], o = n.resolve({ field: a, assertFieldType: "Input" });
402
401
  if (o !== void 0)
403
402
  for (let l of o.listInputFields()) {
404
- e === q && (l = oe(l).baseKey);
405
- const y = [...a, ...JSON.parse(l)];
406
- r.push(y);
403
+ e === J && (l = oe(l).baseKey);
404
+ const g = [...s, ...JSON.parse(l)];
405
+ r.push(g);
407
406
  }
408
407
  }
409
408
  break;
410
409
  }
411
410
  return { data: r, keyLength: i };
412
411
  }
413
- function ot(n) {
412
+ function ct(n) {
414
413
  if (n.type !== "JsonPartitioned" && n.type !== "BinaryPartitioned")
415
414
  throw new Error(`Splitting requires Partitioned DataInfoEntries, got ${n.type}`);
416
415
  const { parts: e, partitionKeyLength: t } = n, r = [];
417
416
  for (let i = 0; i < t; ++i)
418
417
  r.push(/* @__PURE__ */ new Set());
419
418
  for (const i of e) {
420
- const s = i.key;
421
- if (s.length !== t)
419
+ const a = i.key;
420
+ if (a.length !== t)
422
421
  throw new Error(
423
- `Key length (${s.length}) does not match partition length (${t}) for key: ${JSON.stringify(
424
- s
422
+ `Key length (${a.length}) does not match partition length (${t}) for key: ${JSON.stringify(
423
+ a
425
424
  )}`
426
425
  );
427
- for (let a = 0; a < t; ++a)
428
- r[a].add(s[a]);
426
+ for (let s = 0; s < t; ++s)
427
+ r[s].add(a[s]);
429
428
  }
430
429
  return r.map((i) => Array.from(i.values()));
431
430
  }
432
- function lt(n) {
431
+ function ft(n) {
433
432
  if (n === void 0) return;
434
- if (_e(n))
435
- return ot(n);
436
- const e = at(n);
433
+ if (Ae(n))
434
+ return ct(n);
435
+ const e = pt(n);
437
436
  if (!e) return;
438
437
  const { data: t, keyLength: r } = e, i = [];
439
- for (let s = 0; s < r; ++s)
438
+ for (let a = 0; a < r; ++a)
440
439
  i.push(/* @__PURE__ */ new Set());
441
- for (const s of t) {
442
- if (s.length !== r)
440
+ for (const a of t) {
441
+ if (a.length !== r)
443
442
  throw new Error("key length does not match partition length");
444
- for (let a = 0; a < r; ++a)
445
- i[a].add(s[a]);
443
+ for (let s = 0; s < r; ++s)
444
+ i[s].add(a[s]);
446
445
  }
447
- return i.map((s) => Array.from(s.values()));
446
+ return i.map((a) => Array.from(a.values()));
448
447
  }
449
448
  function le(n, e = []) {
450
449
  if (n === void 0 || !n.getIsReadyOrError()) return;
451
450
  const t = n.resourceType.name, r = n.getDataAsJson();
452
- if (e.length > 0 && (t === Z || t === q))
451
+ if (e.length > 0 && (t === Z || t === J))
453
452
  throw new Error(`Unexpected nested super-partitioned resource: ${t}`);
454
453
  switch (t) {
455
454
  case se:
456
455
  case ae:
457
456
  throw new Error(`Only data columns are supported, got: ${t}`);
458
- case M: {
457
+ case j: {
459
458
  if (typeof (r == null ? void 0 : r.partitionKeyLength) != "number")
460
459
  throw new Error(`Missing partitionKeyLength in metadata for ${t}`);
461
460
  const i = [];
462
- for (const s of n.listInputFields()) {
463
- const a = n.resolve({ field: s, assertFieldType: "Input" });
464
- if (a === void 0) return;
465
- const o = [...e, ...JSON.parse(s)];
466
- i.push({ key: o, value: a });
461
+ for (const a of n.listInputFields()) {
462
+ const s = n.resolve({ field: a, assertFieldType: "Input" });
463
+ if (s === void 0) return;
464
+ const o = [...e, ...JSON.parse(a)];
465
+ i.push({ key: o, value: s });
467
466
  }
468
467
  return {
469
468
  type: "JsonPartitioned",
@@ -471,19 +470,19 @@ function le(n, e = []) {
471
470
  parts: i
472
471
  };
473
472
  }
474
- case $: {
473
+ case N: {
475
474
  if (typeof (r == null ? void 0 : r.partitionKeyLength) != "number")
476
475
  throw new Error(`Missing partitionKeyLength in metadata for ${t}`);
477
- const i = [], s = /* @__PURE__ */ new Map();
478
- for (const a of n.listInputFields()) {
479
- const o = oe(a), l = n.resolve({ field: a, assertFieldType: "Input" });
476
+ const i = [], a = /* @__PURE__ */ new Map();
477
+ for (const s of n.listInputFields()) {
478
+ const o = oe(s), l = n.resolve({ field: s, assertFieldType: "Input" });
480
479
  if (l === void 0) return;
481
- let y = s.get(o.baseKey);
482
- y || (y = {}, s.set(o.baseKey, y)), o.type === "index" ? y.index = l : y.values = l;
480
+ let g = a.get(o.baseKey);
481
+ g || (g = {}, a.set(o.baseKey, g)), o.type === "index" ? g.index = l : g.values = l;
483
482
  }
484
- for (const [a, o] of s.entries()) {
483
+ for (const [s, o] of a.entries()) {
485
484
  if (!o.index || !o.values) return;
486
- const l = [...e, ...JSON.parse(a)];
485
+ const l = [...e, ...JSON.parse(s)];
487
486
  i.push({
488
487
  key: l,
489
488
  value: {
@@ -501,156 +500,168 @@ function le(n, e = []) {
501
500
  case Z: {
502
501
  if (typeof (r == null ? void 0 : r.superPartitionKeyLength) != "number" || typeof (r == null ? void 0 : r.partitionKeyLength) != "number")
503
502
  throw new Error(`Missing superPartitionKeyLength or partitionKeyLength in metadata for ${t}`);
504
- const i = r.superPartitionKeyLength + r.partitionKeyLength, s = [];
505
- for (const a of n.listInputFields()) {
506
- const o = n.resolve({ field: a, assertFieldType: "Input" });
503
+ const i = r.superPartitionKeyLength + r.partitionKeyLength, a = [];
504
+ for (const s of n.listInputFields()) {
505
+ const o = n.resolve({ field: s, assertFieldType: "Input" });
507
506
  if (o === void 0) return;
508
- if (o.resourceType.name !== M)
509
- throw new Error(`Expected ${M} inside ${t}, but got ${o.resourceType.name}`);
510
- const l = le(o, JSON.parse(a));
507
+ if (o.resourceType.name !== j)
508
+ throw new Error(`Expected ${j} inside ${t}, but got ${o.resourceType.name}`);
509
+ const l = le(o, JSON.parse(s));
511
510
  if (l === void 0) return;
512
511
  if (l.type !== "JsonPartitioned")
513
512
  throw new Error(`Unexpected inner result type for ${t}: ${l.type}`);
514
- s.push(...l.parts);
513
+ a.push(...l.parts);
515
514
  }
516
515
  return {
517
516
  type: "JsonPartitioned",
518
517
  partitionKeyLength: i,
519
- parts: s
518
+ parts: a
520
519
  };
521
520
  }
522
- case q: {
521
+ case J: {
523
522
  if (typeof (r == null ? void 0 : r.superPartitionKeyLength) != "number" || typeof (r == null ? void 0 : r.partitionKeyLength) != "number")
524
523
  throw new Error(`Missing superPartitionKeyLength or partitionKeyLength in metadata for ${t}`);
525
- const i = r.superPartitionKeyLength + r.partitionKeyLength, s = [];
526
- for (const a of n.listInputFields()) {
527
- const o = n.resolve({ field: a, assertFieldType: "Input" });
524
+ const i = r.superPartitionKeyLength + r.partitionKeyLength, a = [];
525
+ for (const s of n.listInputFields()) {
526
+ const o = n.resolve({ field: s, assertFieldType: "Input" });
528
527
  if (o === void 0) return;
529
- if (o.resourceType.name !== $)
530
- throw new Error(`Expected ${$} inside ${t}, but got ${o.resourceType.name}`);
531
- const l = le(o, JSON.parse(a));
528
+ if (o.resourceType.name !== N)
529
+ throw new Error(`Expected ${N} inside ${t}, but got ${o.resourceType.name}`);
530
+ const l = le(o, JSON.parse(s));
532
531
  if (l === void 0) return;
533
532
  if (l.type !== "BinaryPartitioned")
534
533
  throw new Error(`Unexpected inner result type for ${t}: ${l.type}`);
535
- s.push(...l.parts);
534
+ a.push(...l.parts);
536
535
  }
537
536
  return {
538
537
  type: "BinaryPartitioned",
539
538
  partitionKeyLength: i,
540
- parts: s
539
+ parts: a
541
540
  };
542
541
  }
543
542
  default:
544
543
  throw new Error(`Unknown resource type: ${t}`);
545
544
  }
546
545
  }
547
- function ut(n) {
546
+ function ht(n) {
548
547
  if (n !== void 0) {
549
- if (_e(n)) return n;
550
- if (ue(n)) return Me(n);
548
+ if (Ae(n)) return n;
549
+ if (de(n)) return Ye(n);
551
550
  if (n instanceof I) return le(n);
552
551
  throw new Error(`Unexpected input type: ${typeof n}`);
553
552
  }
554
553
  }
555
- function pt(n, e) {
556
- const t = [...e].sort((s, a) => a[0] - s[0]);
557
- if (n.type === "JsonPartitioned" || n.type === "BinaryPartitioned") {
558
- const { partitionKeyLength: s } = n;
559
- for (const [a] of e)
560
- if (a >= s)
561
- throw new Error(`Can't filter on non-partitioned axis ${a}. Must be >= ${s}`);
562
- } else if (n.type === "Json") {
563
- const { keyLength: s } = n;
564
- for (const [a] of e)
565
- if (a >= s)
566
- throw new Error(`Can't filter on non-data axis ${a}. Must be >= ${s}`);
567
- }
568
- const r = (s) => {
569
- for (const [a, o] of t)
570
- if (s[a] !== o)
554
+ function gt(n, e) {
555
+ const t = [...e].sort((s, o) => o[0] - s[0]), { type: r } = n;
556
+ switch (r) {
557
+ case "Json": {
558
+ const { keyLength: s } = n;
559
+ for (const [o] of e)
560
+ if (o >= s)
561
+ throw new Error(`Can't filter on non-data axis ${o}. Must be >= ${s}`);
562
+ break;
563
+ }
564
+ case "JsonPartitioned":
565
+ case "BinaryPartitioned":
566
+ case "ParquetPartitioned": {
567
+ const { partitionKeyLength: s } = n;
568
+ for (const [o] of e)
569
+ if (o >= s)
570
+ throw new Error(`Can't filter on non-partitioned axis ${o}. Must be >= ${s}`);
571
+ break;
572
+ }
573
+ default:
574
+ throw new Error(`Unsupported data info type: ${r}`);
575
+ }
576
+ const i = (s) => {
577
+ for (const [o, l] of t)
578
+ if (s[o] !== l)
571
579
  return !1;
572
580
  return !0;
573
- }, i = (s) => {
574
- const a = [...s];
575
- for (const [o] of t)
576
- a.splice(o, 1);
577
- return a;
581
+ }, a = (s) => {
582
+ const o = [...s];
583
+ for (const [l] of t)
584
+ o.splice(l, 1);
585
+ return o;
578
586
  };
579
587
  switch (n.type) {
580
- case "Json": {
581
- const s = n.data.filter((a) => r(a.key)).map((a) => ({
582
- key: i(a.key),
583
- value: a.value
584
- }));
588
+ case "Json":
585
589
  return {
586
590
  type: "Json",
587
591
  keyLength: n.keyLength - e.length,
588
- data: s
592
+ data: n.data.filter((s) => i(s.key)).map((s) => ({
593
+ key: a(s.key),
594
+ value: s.value
595
+ }))
589
596
  };
590
- }
591
- case "JsonPartitioned": {
592
- const s = n.parts.filter((a) => r(a.key)).map((a) => ({
593
- key: i(a.key),
594
- value: a.value
595
- }));
597
+ case "JsonPartitioned":
596
598
  return {
597
599
  type: "JsonPartitioned",
598
600
  partitionKeyLength: n.partitionKeyLength - e.length,
599
- parts: s
601
+ parts: n.parts.filter((s) => i(s.key)).map((s) => ({
602
+ key: a(s.key),
603
+ value: s.value
604
+ }))
600
605
  };
601
- }
602
- case "BinaryPartitioned": {
603
- const s = n.parts.filter((a) => r(a.key)).map((a) => ({
604
- key: i(a.key),
605
- value: a.value
606
- }));
606
+ case "BinaryPartitioned":
607
607
  return {
608
608
  type: "BinaryPartitioned",
609
609
  partitionKeyLength: n.partitionKeyLength - e.length,
610
- parts: s
610
+ parts: n.parts.filter((s) => i(s.key)).map((s) => ({
611
+ key: a(s.key),
612
+ value: s.value
613
+ }))
614
+ };
615
+ case "ParquetPartitioned":
616
+ return {
617
+ type: "ParquetPartitioned",
618
+ partitionKeyLength: n.partitionKeyLength - e.length,
619
+ parts: n.parts.filter((s) => i(s.key)).map((s) => ({
620
+ key: a(s.key),
621
+ value: s.value
622
+ }))
611
623
  };
612
- }
613
624
  }
614
625
  }
615
- function dt(n) {
626
+ function mt(n) {
616
627
  if (!Array.isArray(n)) return !1;
617
628
  if (n.length === 0) return !0;
618
629
  const e = n[0];
619
630
  return typeof e == "object" && e !== null && "key" in e && "val" in e;
620
631
  }
621
- class ct {
632
+ class yt {
622
633
  constructor(e) {
623
634
  this.columns = e;
624
635
  }
625
636
  selectColumns(e) {
626
- const t = typeof e == "function" ? e : W(e);
637
+ const t = typeof e == "function" ? e : q(e);
627
638
  return this.columns.filter((r) => t(r.spec));
628
639
  }
629
640
  }
630
- function ft(n) {
641
+ function bt(n) {
631
642
  if (n)
632
643
  return n.map((e) => ({
633
- type: `split:${qe(e.axisId)}`,
644
+ type: `split:${Qe(e.axisId)}`,
634
645
  label: e.label,
635
646
  importance: 1e6
636
647
  // High importance for split filters in labels
637
648
  }));
638
649
  }
639
- function ht(n) {
650
+ function vt(n) {
640
651
  if (n)
641
652
  return n.map((e) => [e.axisIdx, e.value]);
642
653
  }
643
- function gt(n, e) {
654
+ function Tt(n, e) {
644
655
  if (!e || e.length === 0) return n;
645
656
  const t = [...e].sort((r, i) => r[0] - i[0]);
646
- return Se({ id: n, axisFilters: t });
657
+ return Ie({ id: n, axisFilters: t });
647
658
  }
648
- function ye(n) {
659
+ function Te(n) {
649
660
  if (!n || typeof n != "object") return !1;
650
661
  const e = n, t = 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);
651
662
  return !!e.domainAnchor || t || r;
652
663
  }
653
- function mt(n) {
664
+ function Pt(n) {
654
665
  if (typeof n != "object" || !("axes" in n) || n.axes === void 0)
655
666
  return [];
656
667
  const e = n.axes.map((t, r) => typeof t == "object" && "split" in t && t.split === !0 ? r : -1).filter((t) => t !== -1);
@@ -658,9 +669,9 @@ function mt(n) {
658
669
  throw new Error("Axis splitting is not supported when `partialAxesMatch` is defined.");
659
670
  return e.sort((t, r) => t - r), e;
660
671
  }
661
- class be {
672
+ class Pe {
662
673
  constructor() {
663
- w(this, "defaultProviderStore", []), w(this, "providers", [new ct(this.defaultProviderStore)]), w(this, "axisLabelProviders", []);
674
+ S(this, "defaultProviderStore", []), S(this, "providers", [new yt(this.defaultProviderStore)]), S(this, "axisLabelProviders", []);
664
675
  }
665
676
  addColumnProvider(e) {
666
677
  return this.providers.push(e), this;
@@ -682,135 +693,135 @@ class be {
682
693
  }
683
694
  }
684
695
  getUniversalEntries(e, t) {
685
- const { anchorCtx: r, labelOps: i, dontWaitAllData: s = !1, overrideLabelAnnotation: a = !1, exclude: o } = t ?? {}, l = {
686
- ...a && (i == null ? void 0 : i.includeNativeLabel) !== !1 ? { includeNativeLabel: !0 } : {},
696
+ const { anchorCtx: r, labelOps: i, dontWaitAllData: a = !1, overrideLabelAnnotation: s = !1, exclude: o } = t ?? {}, l = {
697
+ ...s && (i == null ? void 0 : i.includeNativeLabel) !== !1 ? { includeNativeLabel: !0 } : {},
687
698
  ...i ?? {}
688
699
  };
689
- let y = () => !1;
700
+ let g = () => !1;
690
701
  if (o) {
691
- const u = (Array.isArray(o) ? o : [o]).map((d) => {
692
- if (ye(d)) {
702
+ const u = (Array.isArray(o) ? o : [o]).map((y) => {
703
+ if (Te(y)) {
693
704
  if (!r)
694
705
  throw new Error("Anchored selectors in exclude require an AnchoredIdDeriver to be provided in options.");
695
- return W(he(r.anchors, d, t));
706
+ return q(ye(r.anchors, y, t));
696
707
  } else
697
- return W(d);
708
+ return q(y);
698
709
  });
699
- y = (d) => u.some((b) => b(d));
710
+ g = (y) => u.some((T) => T(y));
700
711
  }
701
- const K = typeof e == "function" ? [e] : Array.isArray(e) ? e : [e], E = [], V = /* @__PURE__ */ new Set();
702
- for (const u of K) {
703
- const d = ye(u);
704
- let b;
705
- if (d) {
712
+ const R = typeof e == "function" ? [e] : Array.isArray(e) ? e : [e], L = [], V = /* @__PURE__ */ new Set();
713
+ for (const u of R) {
714
+ const y = Te(u);
715
+ let T;
716
+ if (y) {
706
717
  if (!r)
707
718
  throw new Error("Anchored selectors require an AnchoredIdDeriver to be provided in options.");
708
- b = he(r.anchors, u, t);
719
+ T = ye(r.anchors, u, t);
709
720
  } else
710
- b = u;
711
- const A = /* @__PURE__ */ new Set(), F = [];
712
- for (const f of this.providers) {
713
- const g = f.selectColumns(b);
714
- for (const m of g) {
715
- if (y(m.spec)) continue;
716
- if (A.has(m.id))
717
- throw new Error(`Duplicate column id ${m.id} in provider ${f.constructor.name}`);
718
- const L = je(m.spec);
719
- V.has(L) || (A.add(m.id), V.add(L), F.push(m));
721
+ T = u;
722
+ const _ = /* @__PURE__ */ new Set(), x = [];
723
+ for (const c of this.providers) {
724
+ const w = c.selectColumns(T);
725
+ for (const p of w) {
726
+ if (g(p.spec)) continue;
727
+ if (_.has(p.id))
728
+ throw new Error(`Duplicate column id ${p.id} in provider ${c.constructor.name}`);
729
+ const F = Xe(p.spec);
730
+ V.has(F) || (_.add(p.id), V.add(F), x.push(p));
720
731
  }
721
732
  }
722
- if (F.length === 0) continue;
723
- const c = mt(u), _ = c.length > 0;
724
- for (const f of F) {
725
- if (!Y(f.spec)) continue;
726
- const g = f.spec;
727
- if (_) {
728
- if (dt(f.data))
729
- throw new Error(`Splitting is not supported for PColumns with PColumnValues data format. Column id: ${f.id}`);
730
- const m = ut(f.data);
731
- if (!m) {
732
- if (s) continue;
733
+ if (x.length === 0) continue;
734
+ const b = Pt(u), h = b.length > 0;
735
+ for (const c of x) {
736
+ if (!Y(c.spec)) continue;
737
+ const w = c.spec;
738
+ if (h) {
739
+ if (mt(c.data))
740
+ throw new Error(`Splitting is not supported for PColumns with PColumnValues data format. Column id: ${c.id}`);
741
+ const p = ht(c.data);
742
+ if (!p) {
743
+ if (a) continue;
733
744
  return;
734
745
  }
735
- if (!Be(m))
736
- throw new Error(`Splitting requires Partitioned DataInfoEntries, but parsing resulted in ${m.type} for column ${f.id}`);
737
- const L = lt(m), S = c[c.length - 1];
738
- if (S >= m.partitionKeyLength)
739
- throw new Error(`Not enough partition keys (${m.partitionKeyLength}) for requested split axes (max index ${S}) in column ${g.name}`);
740
- const j = c.map((T) => this.findLabels(ge(g.axesSpec[T]))), k = [], D = (T, B) => {
741
- if (B >= c.length) {
742
- if (k.push([...T]), k.length > 1e4)
746
+ if (!ze(p))
747
+ throw new Error(`Splitting requires Partitioned DataInfoEntries, but parsing resulted in ${p.type} for column ${c.id}`);
748
+ const F = ft(p), H = b[b.length - 1];
749
+ if (H >= p.partitionKeyLength)
750
+ throw new Error(`Not enough partition keys (${p.partitionKeyLength}) for requested split axes (max index ${H}) in column ${w.name}`);
751
+ const $ = b.map((P) => this.findLabels(be(w.axesSpec[P]))), A = [], ce = (P, K) => {
752
+ if (K >= b.length) {
753
+ if (A.push([...P]), A.length > 1e4)
743
754
  throw new Error("Too many key combinations, aborting.");
744
755
  return;
745
756
  }
746
- const N = c[B];
747
- if (N >= L.length)
748
- throw new Error(`Axis index ${N} out of bounds for unique keys array (length ${L.length}) during split key generation for column ${f.id}`);
749
- const R = L[N];
750
- if (!R || R.length === 0) {
751
- k.length = 0;
757
+ const k = b[K];
758
+ if (k >= F.length)
759
+ throw new Error(`Axis index ${k} out of bounds for unique keys array (length ${F.length}) during split key generation for column ${c.id}`);
760
+ const D = F[k];
761
+ if (!D || D.length === 0) {
762
+ A.length = 0;
752
763
  return;
753
764
  }
754
- for (const X of R)
755
- T.push(X), D(T, B + 1), T.pop();
765
+ for (const X of D)
766
+ P.push(X), ce(P, K + 1), P.pop();
756
767
  };
757
- if (D([], 0), k.length === 0)
768
+ if (ce([], 0), A.length === 0)
758
769
  continue;
759
- const O = [...g.axesSpec], Ee = c.map((T) => T);
760
- for (let T = c.length - 1; T >= 0; T--)
761
- O.splice(c[T], 1);
762
- const Le = { ...g, axesSpec: O };
763
- for (const T of k) {
764
- const B = T.map((N, R) => {
765
- const X = Ee[R], Ve = ge(g.axesSpec[X]), de = j[R], Oe = (de == null ? void 0 : de[N]) ?? String(N);
766
- return { axisIdx: X, axisId: Ve, value: N, label: Oe };
770
+ const fe = [...w.axesSpec], Oe = b.map((P) => P);
771
+ for (let P = b.length - 1; P >= 0; P--)
772
+ fe.splice(b[P], 1);
773
+ const ke = { ...w, axesSpec: fe };
774
+ for (const P of A) {
775
+ const K = P.map((k, D) => {
776
+ const X = Oe[D], De = be(w.axesSpec[X]), he = $[D], Ue = (he == null ? void 0 : he[k]) ?? String(k);
777
+ return { axisIdx: X, axisId: De, value: k, label: Ue };
767
778
  });
768
- E.push({
779
+ L.push({
769
780
  type: "split",
770
- originalColumn: f,
771
- spec: g,
772
- adjustedSpec: Le,
773
- dataEntries: m,
774
- axisFilters: B
781
+ originalColumn: c,
782
+ spec: w,
783
+ adjustedSpec: ke,
784
+ dataEntries: p,
785
+ axisFilters: K
775
786
  });
776
787
  }
777
788
  } else
778
- E.push({
789
+ L.push({
779
790
  type: "direct",
780
- originalColumn: f,
781
- spec: g,
782
- adjustedSpec: g
791
+ originalColumn: c,
792
+ spec: w,
793
+ adjustedSpec: w
783
794
  });
784
795
  }
785
796
  }
786
- if (E.length === 0) return [];
787
- const h = Ie(
788
- E,
797
+ if (L.length === 0) return [];
798
+ const f = Fe(
799
+ L,
789
800
  (u) => ({
790
801
  spec: u.spec,
791
- suffixTrace: u.type === "split" ? ft(u.axisFilters) : void 0
802
+ suffixTrace: u.type === "split" ? bt(u.axisFilters) : void 0
792
803
  }),
793
804
  l
794
- ), C = [];
795
- for (const { value: u, label: d } of h) {
796
- const { originalColumn: b, spec: A } = u, F = u.type === "split" ? u.axisFilters : void 0, c = ht(F);
797
- let _;
798
- r ? _ = r.deriveS(A, c) : _ = gt(b.id, c);
799
- let f = { ...u.adjustedSpec };
800
- a && (f = {
801
- ...f,
805
+ ), m = [];
806
+ for (const { value: u, label: y } of f) {
807
+ const { originalColumn: T, spec: _ } = u, x = u.type === "split" ? u.axisFilters : void 0, b = vt(x);
808
+ let h;
809
+ r ? h = r.deriveS(_, b) : h = Tt(T.id, b);
810
+ let c = { ...u.adjustedSpec };
811
+ s && (c = {
812
+ ...c,
802
813
  annotations: {
803
- ...f.annotations ?? {},
804
- "pl7.app/label": d
814
+ ...c.annotations ?? {},
815
+ [O.Label]: y
805
816
  }
806
- }), C.push({
807
- id: _,
808
- spec: f,
809
- data: () => u.type === "split" ? Je(pt(u.dataEntries, c)) : u.originalColumn.data,
810
- label: d
817
+ }), m.push({
818
+ id: h,
819
+ spec: c,
820
+ data: () => u.type === "split" ? Ge(gt(u.dataEntries, b)) : u.originalColumn.data,
821
+ label: y
811
822
  });
812
823
  }
813
- return C;
824
+ return m;
814
825
  }
815
826
  getColumns(e, t) {
816
827
  const r = this.getUniversalEntries(e, {
@@ -820,51 +831,51 @@ class be {
820
831
  });
821
832
  if (!r) return;
822
833
  const i = [];
823
- for (const s of r) {
824
- const a = s.data();
825
- if (!a) {
834
+ for (const a of r) {
835
+ const s = a.data();
836
+ if (!s) {
826
837
  if (t != null && t.dontWaitAllData) continue;
827
838
  return;
828
839
  }
829
840
  i.push({
830
- id: s.id,
831
- spec: s.spec,
832
- data: a
841
+ id: a.id,
842
+ spec: a.spec,
843
+ data: s
833
844
  });
834
845
  }
835
846
  return i;
836
847
  }
837
848
  }
838
- function ve(n) {
849
+ function Ce(n) {
839
850
  const e = (i) => i.operator !== "InSet" ? i : {
840
851
  operator: "Or",
841
- operands: i.references.map((s) => ({
852
+ operands: i.references.map((a) => ({
842
853
  operator: "Equal",
843
- reference: s
854
+ reference: a
844
855
  }))
845
- }, t = (i, s) => {
856
+ }, t = (i, a) => {
846
857
  switch (i.operator) {
847
858
  case "And":
848
859
  return {
849
860
  ...i,
850
- operands: i.operands.map((a) => t(a, s))
861
+ operands: i.operands.map((s) => t(s, a))
851
862
  };
852
863
  case "Or":
853
864
  return {
854
865
  ...i,
855
- operands: i.operands.map((a) => t(a, s))
866
+ operands: i.operands.map((s) => t(s, a))
856
867
  };
857
868
  case "Not":
858
869
  return {
859
870
  ...i,
860
- operand: t(i.operand, s)
871
+ operand: t(i.operand, a)
861
872
  };
862
873
  default:
863
- return s(i);
874
+ return a(i);
864
875
  }
865
- }, r = (i, s) => ({
876
+ }, r = (i, a) => ({
866
877
  ...i,
867
- predicate: t(i.predicate, s)
878
+ predicate: t(i.predicate, a)
868
879
  });
869
880
  return n.map((i) => r(i, e));
870
881
  }
@@ -875,12 +886,12 @@ function ne(n, e) {
875
886
  if (n[t] !== e[t]) return !1;
876
887
  return !0;
877
888
  }
878
- function Te(n) {
879
- return pe(n, (e) => e instanceof I ? e.handle : ue(e) ? We(e, (t) => t.handle) : e);
889
+ function we(n) {
890
+ return pe(n, (e) => e instanceof I ? e.handle : de(e) ? Ze(e, (t) => t.handle) : e);
880
891
  }
881
- class yt {
892
+ class Ct {
882
893
  constructor() {
883
- w(this, "ctx", p());
894
+ S(this, "ctx", d());
884
895
  }
885
896
  /**
886
897
  * @deprecated use getOptions()
@@ -889,28 +900,28 @@ class yt {
889
900
  return this.ctx.calculateOptions(e);
890
901
  }
891
902
  getOptions(e, t) {
892
- const r = typeof e == "function" ? e : W(e), i = this.getSpecs().entries.filter((o) => r(o.obj));
893
- let s = {}, a = !1;
894
- return typeof t < "u" && (typeof t == "function" ? s = t : typeof t == "object" && ("includeNativeLabel" in t || "separator" in t || "addLabelAsSuffix" in t ? s = t : (t = t, s = t.label ?? {}, a = t.refsWithEnrichments ?? !1))), typeof s == "object" ? Ie(i, (o) => o.obj, s ?? {}).map(({ value: { ref: o }, label: l }) => ({
895
- ref: ce(o, a),
903
+ const r = typeof e == "function" ? e : q(e), i = this.getSpecs().entries.filter((o) => r(o.obj));
904
+ let a = {}, s = !1;
905
+ return typeof t < "u" && (typeof t == "function" ? a = t : typeof t == "object" && ("includeNativeLabel" in t || "separator" in t || "addLabelAsSuffix" in t ? a = t : (t = t, a = t.label ?? {}, s = t.refsWithEnrichments ?? !1))), typeof a == "object" ? Fe(i, (o) => o.obj, a ?? {}).map(({ value: { ref: o }, label: l }) => ({
906
+ ref: ge(o, s),
896
907
  label: l
897
908
  })) : i.map(({ ref: o, obj: l }) => ({
898
- ref: ce(o, a),
899
- label: s(l, o)
909
+ ref: ge(o, s),
910
+ label: a(l, o)
900
911
  }));
901
912
  }
902
913
  resolveAnchorCtx(e) {
903
- if (e instanceof fe) return e;
914
+ if (e instanceof me) return e;
904
915
  const t = {};
905
916
  for (const [r, i] of Object.entries(e))
906
- if (Ue(i)) {
907
- const s = this.getPColumnSpecByRef(i);
908
- if (!s)
917
+ if (Me(i)) {
918
+ const a = this.getPColumnSpecByRef(i);
919
+ if (!a)
909
920
  return;
910
- t[r] = s;
921
+ t[r] = a;
911
922
  } else
912
923
  t[r] = i;
913
- return new fe(t);
924
+ return new me(t);
914
925
  }
915
926
  /**
916
927
  * Returns columns that match the provided anchors and selectors. It applies axis filters and label derivation.
@@ -923,7 +934,7 @@ class yt {
923
934
  getAnchoredPColumns(e, t, r) {
924
935
  const i = this.resolveAnchorCtx(e);
925
936
  if (i)
926
- return new be().addColumnProvider(this).addAxisLabelProvider(this).getColumns(t, {
937
+ return new Pe().addColumnProvider(this).addAxisLabelProvider(this).getColumns(t, {
927
938
  ...r,
928
939
  anchorCtx: i
929
940
  });
@@ -960,14 +971,14 @@ class yt {
960
971
  getCanonicalOptions(e, t, r) {
961
972
  const i = this.resolveAnchorCtx(e);
962
973
  if (!i) return;
963
- const s = new be().addColumnProvider(this).addAxisLabelProvider(this).getUniversalEntries(t, {
974
+ const a = new Pe().addColumnProvider(this).addAxisLabelProvider(this).getUniversalEntries(t, {
964
975
  ...r,
965
976
  anchorCtx: i
966
977
  });
967
- if (s)
968
- return s.map((a) => ({
969
- value: a.id,
970
- label: a.label
978
+ if (a)
979
+ return a.map((s) => ({
980
+ value: s.id,
981
+ label: s.label
971
982
  }));
972
983
  }
973
984
  /**
@@ -1003,7 +1014,7 @@ class yt {
1003
1014
  ref: t.ref,
1004
1015
  obj: {
1005
1016
  ...t.obj,
1006
- data: $e(
1017
+ data: qe(
1007
1018
  t.obj.data,
1008
1019
  (r) => new I(r, [t.ref.blockId, t.ref.name])
1009
1020
  )
@@ -1045,7 +1056,7 @@ class yt {
1045
1056
  getPColumnByRef(e) {
1046
1057
  const t = this.getDataByRef(e);
1047
1058
  if (t)
1048
- return Ke(t);
1059
+ return We(t);
1049
1060
  }
1050
1061
  /**
1051
1062
  * Returns spec associated with the ref ensuring that it is a p-column spec.
@@ -1078,9 +1089,9 @@ class yt {
1078
1089
  continue;
1079
1090
  const i = r.obj.spec;
1080
1091
  if (e.name === i.name && e.valueType === i.valueType && e.axesSpec.length === i.axesSpec.length && ne(e.domain, i.domain)) {
1081
- for (let s = 0; s < e.axesSpec.length; ++s) {
1082
- const a = e.axesSpec[s], o = i.axesSpec[s];
1083
- if (a.name !== o.name || a.type !== o.type || !ne(a.domain, o.domain))
1092
+ for (let a = 0; a < e.axesSpec.length; ++a) {
1093
+ const s = e.axesSpec[a], o = i.axesSpec[a];
1094
+ if (s.name !== o.name || s.type !== o.type || !ne(s.domain, o.domain))
1084
1095
  continue e;
1085
1096
  }
1086
1097
  t.push(r.obj);
@@ -1095,15 +1106,15 @@ class yt {
1095
1106
  findLabels(e) {
1096
1107
  const t = this.getData();
1097
1108
  for (const r of t.entries) {
1098
- if (!Ce(r.obj)) continue;
1109
+ if (!_e(r.obj)) continue;
1099
1110
  const i = r.obj.spec;
1100
- if (i.name === "pl7.app/label" && i.axesSpec.length === 1 && i.axesSpec[0].name === e.name && i.axesSpec[0].type === e.type && ne(e.domain, i.axesSpec[0].domain)) {
1111
+ if (i.name === ue.Label && i.axesSpec.length === 1 && i.axesSpec[0].name === e.name && i.axesSpec[0].type === e.type && ne(e.domain, i.axesSpec[0].domain)) {
1101
1112
  if (r.obj.data.resourceType.name !== "PColumnData/Json")
1102
1113
  throw Error(`Expected JSON column for labels, got: ${r.obj.data.resourceType.name}`);
1103
1114
  return Object.fromEntries(
1104
1115
  Object.entries(
1105
1116
  r.obj.data.getDataAsJson().data
1106
- ).map((s) => [JSON.parse(s[0])[0], s[1]])
1117
+ ).map((a) => [JSON.parse(a[0])[0], a[1]])
1107
1118
  );
1108
1119
  }
1109
1120
  }
@@ -1116,17 +1127,17 @@ class yt {
1116
1127
  * @returns An array of PColumn objects matching the selectors. Data is loaded on first access.
1117
1128
  */
1118
1129
  selectColumns(e) {
1119
- const t = typeof e == "function" ? e : W(e);
1130
+ const t = typeof e == "function" ? e : q(e);
1120
1131
  return this.getSpecs().entries.filter(({ obj: r }) => Y(r) ? t(r) : !1).map(({ ref: r, obj: i }) => {
1121
- const s = i;
1122
- let a = null;
1132
+ const a = i;
1133
+ let s = null;
1123
1134
  const o = this;
1124
1135
  return {
1125
- id: Se(r),
1126
- spec: s,
1136
+ id: Ie(r),
1137
+ spec: a,
1127
1138
  get data() {
1128
1139
  var l;
1129
- return a !== null || (a = (l = o.getPColumnByRef(r)) == null ? void 0 : l.data), a;
1140
+ return s !== null || (s = (l = o.getPColumnByRef(r)) == null ? void 0 : l.data), s;
1130
1141
  }
1131
1142
  };
1132
1143
  });
@@ -1136,20 +1147,19 @@ class yt {
1136
1147
  * @returns a map of axis value => label
1137
1148
  */
1138
1149
  findLabelsForColumnAxis(e, t) {
1139
- var r;
1140
- const i = this.findLabels(e.axesSpec[t]);
1141
- if (!i) return;
1142
- const s = (r = e.annotations) == null ? void 0 : r["pl7.app/axisKeys/" + t];
1143
- if (s !== void 0) {
1144
- const a = JSON.parse(s);
1145
- return Object.fromEntries(a.map((o) => [o, i[o] ?? "Unlabelled"]));
1150
+ const r = this.findLabels(e.axesSpec[t]);
1151
+ if (!r) return;
1152
+ const i = M(e, `pl7.app/axisKeys/${t}`);
1153
+ if (i !== void 0) {
1154
+ const a = JSON.parse(i);
1155
+ return Object.fromEntries(a.map((s) => [s, r[s] ?? "Unlabelled"]));
1146
1156
  } else
1147
- return i;
1157
+ return r;
1148
1158
  }
1149
1159
  }
1150
1160
  class z {
1151
1161
  constructor() {
1152
- w(this, "ctx"), w(this, "_argsCache"), w(this, "_uiStateCache"), w(this, "_activeArgsCache"), w(this, "resultPool", new yt()), this.ctx = p();
1162
+ S(this, "ctx"), S(this, "_argsCache"), S(this, "_uiStateCache"), S(this, "_activeArgsCache"), S(this, "resultPool", new Ct()), this.ctx = d();
1153
1163
  }
1154
1164
  get args() {
1155
1165
  if (this._argsCache === void 0) {
@@ -1189,10 +1199,10 @@ class z {
1189
1199
  );
1190
1200
  }
1191
1201
  get prerun() {
1192
- return this.getNamedAccessor(Qe);
1202
+ return this.getNamedAccessor(st);
1193
1203
  }
1194
1204
  get outputs() {
1195
- return this.getNamedAccessor(Ze);
1205
+ return this.getNamedAccessor(at);
1196
1206
  }
1197
1207
  /**
1198
1208
  * Find labels data for a given axis id. It will search for a label column and return its data as a map.
@@ -1204,7 +1214,7 @@ class z {
1204
1214
  }
1205
1215
  verifyInlineAndExplicitColumnsSupport(e) {
1206
1216
  var t;
1207
- const r = e.some((s) => !(s.data instanceof I) || ue(s.data)), i = ((t = this.ctx.featureFlags) == null ? void 0 : t.inlineColumnsSupport) === !0;
1217
+ const r = e.some((a) => !(a.data instanceof I) || de(a.data)), i = ((t = this.ctx.featureFlags) == null ? void 0 : t.inlineColumnsSupport) === !0;
1208
1218
  if (r && !i) throw Error("Inline or explicit columns not supported");
1209
1219
  }
1210
1220
  patchPTableDef(e) {
@@ -1215,14 +1225,14 @@ class z {
1215
1225
  filters: [...e.partitionFilters, ...e.filters]
1216
1226
  }), (r = this.ctx.featureFlags) != null && r.pFrameInSetFilterSupport || (e = {
1217
1227
  ...e,
1218
- partitionFilters: ve(e.partitionFilters),
1219
- filters: ve(e.filters)
1228
+ partitionFilters: Ce(e.partitionFilters),
1229
+ filters: Ce(e.filters)
1220
1230
  }), e;
1221
1231
  }
1222
1232
  // TODO remove all non-PColumn fields
1223
1233
  createPFrame(e) {
1224
1234
  return this.verifyInlineAndExplicitColumnsSupport(e), this.ctx.createPFrame(
1225
- e.map((t) => Te(t))
1235
+ e.map((t) => we(t))
1226
1236
  );
1227
1237
  }
1228
1238
  createPTable(e) {
@@ -1235,8 +1245,8 @@ class z {
1235
1245
  partitionFilters: e.filters ?? [],
1236
1246
  filters: [],
1237
1247
  sorting: e.sorting ?? []
1238
- }) : t = this.patchPTableDef(e), this.verifyInlineAndExplicitColumnsSupport(De(t.src)), this.ctx.createPTable(
1239
- Re(t, (r) => Te(r))
1248
+ }) : t = this.patchPTableDef(e), this.verifyInlineAndExplicitColumnsSupport(je(t.src)), this.ctx.createPTable(
1249
+ Je(t, (r) => we(r))
1240
1250
  );
1241
1251
  }
1242
1252
  /** @deprecated scheduled for removal from SDK */
@@ -1256,17 +1266,17 @@ class z {
1256
1266
  this.ctx.logError(e);
1257
1267
  }
1258
1268
  }
1259
- const bt = "1.42.10", Q = bt;
1260
- function vt(n) {
1269
+ const wt = "1.42.16", Q = wt;
1270
+ function St(n) {
1261
1271
  return n.__renderLambda === !0;
1262
1272
  }
1263
1273
  function re(n) {
1264
1274
  if (n !== void 0)
1265
- return vt(n) ? n.handle : n;
1275
+ return St(n) ? n.handle : n;
1266
1276
  }
1267
- const Tt = class v {
1268
- constructor(e, t, r, i, s, a, o, l, y) {
1269
- this._renderingMode = e, this._initialArgs = t, this._initialUiState = r, this._outputs = i, this._inputsValid = s, this._sections = a, this._title = o, this._enrichmentTargets = l, this._featureFlags = y;
1277
+ const _t = class v {
1278
+ constructor(e, t, r, i, a, s, o, l, g) {
1279
+ this._renderingMode = e, this._initialArgs = t, this._initialUiState = r, this._outputs = i, this._inputsValid = a, this._sections = s, this._title = o, this._enrichmentTargets = l, this._featureFlags = g;
1270
1280
  }
1271
1281
  static create(e = "Heavy") {
1272
1282
  return new v(
@@ -1284,7 +1294,7 @@ const Tt = class v {
1284
1294
  output(e, t, r = {}) {
1285
1295
  if (typeof t == "function") {
1286
1296
  const i = `output#${e}`;
1287
- return J(i, () => t(new z())), new v(
1297
+ return B(i, () => t(new z())), new v(
1288
1298
  this._renderingMode,
1289
1299
  this._initialArgs,
1290
1300
  this._initialUiState,
@@ -1323,7 +1333,7 @@ const Tt = class v {
1323
1333
  return this.output(e, t, { retentive: !0 });
1324
1334
  }
1325
1335
  argsValid(e) {
1326
- return typeof e == "function" ? (J("inputsValid", () => e(new z())), new v(
1336
+ return typeof e == "function" ? (B("inputsValid", () => e(new z())), new v(
1327
1337
  this._renderingMode,
1328
1338
  this._initialArgs,
1329
1339
  this._initialUiState,
@@ -1349,7 +1359,7 @@ const Tt = class v {
1349
1359
  );
1350
1360
  }
1351
1361
  sections(e) {
1352
- return Array.isArray(e) ? this.sections(ee(e)) : typeof e == "function" ? (J("sections", () => e(new z())), new v(
1362
+ return Array.isArray(e) ? this.sections(ee(e)) : typeof e == "function" ? (B("sections", () => e(new z())), new v(
1353
1363
  this._renderingMode,
1354
1364
  this._initialArgs,
1355
1365
  this._initialUiState,
@@ -1373,7 +1383,7 @@ const Tt = class v {
1373
1383
  }
1374
1384
  /** Sets a rendering function to derive block title, shown for the block in the left blocks-overview panel. */
1375
1385
  title(e) {
1376
- return J("title", () => e(new z())), new v(
1386
+ return B("title", () => e(new z())), new v(
1377
1387
  this._renderingMode,
1378
1388
  this._initialArgs,
1379
1389
  this._initialUiState,
@@ -1449,7 +1459,7 @@ const Tt = class v {
1449
1459
  * Influences dependency graph construction.
1450
1460
  */
1451
1461
  enriches(e) {
1452
- return J("enrichmentTargets", e), new v(
1462
+ return B("enrichmentTargets", e), new v(
1453
1463
  this._renderingMode,
1454
1464
  this._initialArgs,
1455
1465
  this._initialUiState,
@@ -1496,15 +1506,15 @@ const Tt = class v {
1496
1506
  Object.entries(this._outputs).map(([r, i]) => [r, re(i)])
1497
1507
  )
1498
1508
  };
1499
- return globalThis.platformaApiVersion = e, ze() ? we({ sdkVersion: Q, apiVersion: platformaApiVersion }) : { config: t };
1509
+ return globalThis.platformaApiVersion = e, nt() ? xe({ sdkVersion: Q, apiVersion: platformaApiVersion }) : { config: t };
1500
1510
  }
1501
1511
  };
1502
- w(Tt, "INITIAL_BLOCK_FEATURE_FLAGS", {
1512
+ S(_t, "INITIAL_BLOCK_FEATURE_FLAGS", {
1503
1513
  supportsLazyState: !0,
1504
1514
  requiresUIAPIVersion: 1,
1505
1515
  requiresModelAPIVersion: 1
1506
1516
  });
1507
- function Fe() {
1517
+ function Le() {
1508
1518
  return {
1509
1519
  sourceId: null,
1510
1520
  hiddenColIds: null,
@@ -1513,78 +1523,74 @@ function Fe() {
1513
1523
  sorting: []
1514
1524
  };
1515
1525
  }
1516
- function Pe() {
1526
+ function Se() {
1517
1527
  return {
1518
1528
  version: 4,
1519
1529
  stateCache: [],
1520
- pTableParams: Fe()
1530
+ pTableParams: Le()
1521
1531
  };
1522
1532
  }
1523
- function wt(n) {
1524
- return "version" in n || (n = Pe()), n.version === 2 && (n = {
1533
+ function Ft(n) {
1534
+ return "version" in n || (n = Se()), n.version === 2 && (n = {
1525
1535
  version: 3,
1526
1536
  stateCache: n.stateCache.map((e) => ({
1527
1537
  ...e,
1528
1538
  filtersState: []
1529
1539
  })),
1530
- pTableParams: Fe()
1531
- }), n.version === 3 && (n = Pe()), n;
1540
+ pTableParams: Le()
1541
+ }), n.version === 3 && (n = Se()), n;
1532
1542
  }
1533
- function It(n) {
1534
- return n.axesSpec.length === 1 && n.name === "pl7.app/label";
1543
+ function Et(n) {
1544
+ return n.axesSpec.length === 1 && n.name === ue.Label;
1535
1545
  }
1536
- function At(n) {
1537
- var e;
1538
- return ((e = n.annotations) == null ? void 0 : e["pl7.app/table/visibility"]) === "hidden";
1546
+ function Lt(n) {
1547
+ return M(n, O.Table.Visibility) === "hidden";
1539
1548
  }
1540
- function Ft(n) {
1541
- var e;
1542
- return ((e = n.annotations) == null ? void 0 : e["pl7.app/table/visibility"]) === "optional";
1549
+ function Vt(n) {
1550
+ return M(n, O.Table.Visibility) === "optional";
1543
1551
  }
1544
- function xt(n) {
1545
- var e;
1546
- return ((e = n.annotations) == null ? void 0 : e[Pt]) === "true";
1552
+ function Ot(n) {
1553
+ return !!Ne(n, O.IsLinkerColumn);
1547
1554
  }
1548
- const Pt = "pl7.app/isLinkerColumn";
1549
- function Et({
1555
+ function kt({
1550
1556
  selection: n,
1551
- columnId: e = Ne(),
1557
+ columnId: e = Be(),
1552
1558
  label: t = "Selection marker",
1553
1559
  domain: r
1554
1560
  }) {
1555
1561
  if (!(n != null && n.axesSpec.length))
1556
1562
  return;
1557
- const i = n.selectedKeys.filter((s) => s.every((a) => !ke(a))).map((s) => ({ key: s, val: 1 }));
1563
+ const i = n.selectedKeys.filter((a) => a.every((s) => !Re(s))).map((a) => ({ key: a, val: 1 }));
1558
1564
  if (i.length)
1559
1565
  return {
1560
1566
  id: e,
1561
1567
  spec: {
1562
1568
  kind: "PColumn",
1563
- valueType: "Int",
1564
- name: "pl7.app/table/row-selection",
1569
+ valueType: Ke.Int,
1570
+ name: ue.Table.RowSelection,
1565
1571
  axesSpec: n.axesSpec,
1566
1572
  ...r && Object.keys(r).length && { domain: r },
1567
1573
  annotations: {
1568
- "pl7.app/label": t,
1569
- "pl7.app/discreteValues": "[1]"
1574
+ [O.Label]: t,
1575
+ [O.DiscreteValues]: $e([1])
1570
1576
  }
1571
1577
  },
1572
1578
  data: i
1573
1579
  };
1574
1580
  }
1575
- function Lt() {
1581
+ function Dt() {
1576
1582
  return {
1577
1583
  axesSpec: [],
1578
1584
  selectedKeys: []
1579
1585
  };
1580
1586
  }
1581
- function x(n) {
1587
+ function E(n) {
1582
1588
  return n.valueType === "Int" || n.valueType === "Long" || n.valueType === "Float" || n.valueType === "Double";
1583
1589
  }
1584
1590
  function G(n) {
1585
1591
  return n.valueType === "String";
1586
1592
  }
1587
- const xe = {
1593
+ const Ve = {
1588
1594
  lessThan: {
1589
1595
  label: "Col < X (Less Than)",
1590
1596
  form: {
@@ -1605,7 +1611,7 @@ const xe = {
1605
1611
  defaultValue: () => 0
1606
1612
  }
1607
1613
  },
1608
- supportedFor: x
1614
+ supportedFor: E
1609
1615
  },
1610
1616
  greaterThan: {
1611
1617
  label: "Col > X (Greater Than)",
@@ -1627,7 +1633,7 @@ const xe = {
1627
1633
  defaultValue: () => 0
1628
1634
  }
1629
1635
  },
1630
- supportedFor: x
1636
+ supportedFor: E
1631
1637
  },
1632
1638
  lessThanOrEqual: {
1633
1639
  label: "Col ≤ X (Less Than or Equal)",
@@ -1649,7 +1655,7 @@ const xe = {
1649
1655
  defaultValue: () => 0
1650
1656
  }
1651
1657
  },
1652
- supportedFor: x
1658
+ supportedFor: E
1653
1659
  },
1654
1660
  greaterThanOrEqual: {
1655
1661
  label: "Col ≥ X (Greater Than or Equal)",
@@ -1671,7 +1677,7 @@ const xe = {
1671
1677
  defaultValue: () => 0
1672
1678
  }
1673
1679
  },
1674
- supportedFor: x
1680
+ supportedFor: E
1675
1681
  },
1676
1682
  lessThanColumn: {
1677
1683
  label: "Col₁ < Col₂ (Compare Columns)",
@@ -1700,7 +1706,7 @@ const xe = {
1700
1706
  }
1701
1707
  }
1702
1708
  },
1703
- supportedFor: (n, e) => x(n) && (e === void 0 || x(e))
1709
+ supportedFor: (n, e) => E(n) && (e === void 0 || E(e))
1704
1710
  },
1705
1711
  lessThanColumnOrEqual: {
1706
1712
  label: "Col₁ ≤ Col₂ (Compare Columns)",
@@ -1729,7 +1735,7 @@ const xe = {
1729
1735
  }
1730
1736
  }
1731
1737
  },
1732
- supportedFor: (n, e) => x(n) && (e === void 0 || x(e))
1738
+ supportedFor: (n, e) => E(n) && (e === void 0 || E(e))
1733
1739
  },
1734
1740
  topN: {
1735
1741
  label: "Top N",
@@ -1751,7 +1757,7 @@ const xe = {
1751
1757
  defaultValue: () => 10
1752
1758
  }
1753
1759
  },
1754
- supportedFor: x
1760
+ supportedFor: E
1755
1761
  },
1756
1762
  bottomN: {
1757
1763
  label: "Bottom N",
@@ -1773,7 +1779,7 @@ const xe = {
1773
1779
  defaultValue: () => 10
1774
1780
  }
1775
1781
  },
1776
- supportedFor: x
1782
+ supportedFor: E
1777
1783
  },
1778
1784
  patternContainSubsequence: {
1779
1785
  label: "Col ~ Seq (Contain Subsequence)",
@@ -1948,115 +1954,125 @@ const xe = {
1948
1954
  supportedFor: () => !1
1949
1955
  }
1950
1956
  };
1951
- function Vt(n) {
1952
- return n ? Object.entries(xe).filter(([e, t]) => t.supportedFor(n)).map(([e, t]) => ({
1957
+ function Ut(n) {
1958
+ return n ? Object.entries(Ve).filter(([e, t]) => t.supportedFor(n)).map(([e, t]) => ({
1953
1959
  label: t.label,
1954
1960
  value: e
1955
1961
  })) : [];
1956
1962
  }
1957
- function Ot(n) {
1958
- return xe[n];
1963
+ function Nt(n) {
1964
+ return Ve[n];
1959
1965
  }
1960
- function kt() {
1966
+ function Rt() {
1961
1967
  return platformaApiVersion ?? 1;
1962
1968
  }
1963
- function Nt() {
1964
- return we({ sdkVersion: Q, apiVersion: platformaApiVersion });
1969
+ function $t() {
1970
+ return xe({ sdkVersion: Q, apiVersion: platformaApiVersion });
1965
1971
  }
1966
- function Dt(n) {
1972
+ function Kt(n) {
1967
1973
  if (typeof globalThis.getEnvironmentValue == "function")
1968
1974
  return globalThis.getEnvironmentValue(n);
1969
1975
  }
1970
1976
  export {
1971
- fe as AnchoredIdDeriver,
1972
- ln as BasePlErrorLike,
1973
- un as ErrorLike,
1974
- P as FutureRef,
1975
- Pt as LINKER_COLUMN_ANNOTATION,
1976
- et as PAnnotationLabel,
1977
- tt as PAnnotationTrace,
1978
- be as PColumnCollection,
1979
- $t as PTableAbsent,
1980
- Kt as PTableNA,
1981
- pn as PlErrorLike,
1982
- jt as PlId,
1983
- Bt as PlIdBytes,
1984
- Jt as PlIdLength,
1985
- $ as RT_BINARY_PARTITIONED,
1986
- q as RT_BINARY_SUPER_PARTITIONED,
1987
- M as RT_JSON_PARTITIONED,
1977
+ me as AnchoredIdDeriver,
1978
+ O as Annotation,
1979
+ Jt as AnnotationJson,
1980
+ Mt as AxisSpec,
1981
+ bn as BasePlErrorLike,
1982
+ qt as Domain,
1983
+ vn as ErrorLike,
1984
+ C as FutureRef,
1985
+ Pe as PColumnCollection,
1986
+ ue as PColumnName,
1987
+ Wt as PTableAbsent,
1988
+ Ht as PTableNA,
1989
+ Tn as PlErrorLike,
1990
+ Xt as PlId,
1991
+ zt as PlIdBytes,
1992
+ Gt as PlIdLength,
1993
+ N as RT_BINARY_PARTITIONED,
1994
+ J as RT_BINARY_SUPER_PARTITIONED,
1995
+ j as RT_JSON_PARTITIONED,
1988
1996
  Z as RT_JSON_SUPER_PARTITIONED,
1989
1997
  se as RT_RESOURCE_MAP,
1990
1998
  ae as RT_RESOURCE_MAP_PARTITIONED,
1991
1999
  z as RenderCtx,
1992
- yt as ResultPool,
1993
- dn as StandardErrorLike,
1994
- rt as Trace,
1995
- nt as TraceEntry,
2000
+ Ct as ResultPool,
2001
+ Pn as StandardErrorLike,
2002
+ lt as Trace,
2003
+ ot as TraceEntry,
1996
2004
  I as TreeNodeAccessor,
1997
- qe as canonicalizeAxisId,
1998
- Mt as canonicalizeJson,
1999
- ut as convertOrParsePColumnData,
2000
- Pe as createPlDataTableStateV2,
2001
- Lt as createPlSelectionModel,
2002
- Et as createRowSelectionColumn,
2003
- Me as dataInfoToEntries,
2004
- Ie as deriveLabels,
2005
- je as deriveNativeId,
2006
- qt as deserializeError,
2005
+ Ke as ValueType,
2006
+ Qe as canonicalizeAxisId,
2007
+ Yt as canonicalizeJson,
2008
+ ht as convertOrParsePColumnData,
2009
+ Se as createPlDataTableStateV2,
2010
+ Dt as createPlSelectionModel,
2011
+ kt as createRowSelectionColumn,
2012
+ Ye as dataInfoToEntries,
2013
+ Fe as deriveLabels,
2014
+ Xe as deriveNativeId,
2015
+ Qt as deserializeError,
2007
2016
  re as downgradeCfgOrLambda,
2008
- Wt as ensureError,
2009
- cn as ensureErrorLike,
2010
- Ke as ensurePColumn,
2011
- Je as entriesToDataInfo,
2012
- De as extractAllColumns,
2013
- pt as filterDataInfoEntries,
2014
- xe as filterUiMetadata,
2015
- Ht as getAxesId,
2016
- ge as getAxisId,
2017
- Dt as getEnvironmentValue,
2018
- Ot as getFilterUiMetadata,
2019
- Vt as getFilterUiTypeOptions,
2017
+ Zt as ensureError,
2018
+ Cn as ensureErrorLike,
2019
+ We as ensurePColumn,
2020
+ Ge as entriesToDataInfo,
2021
+ je as extractAllColumns,
2022
+ gt as filterDataInfoEntries,
2023
+ Ve as filterUiMetadata,
2024
+ en as getAxesId,
2025
+ be as getAxisId,
2026
+ Kt as getEnvironmentValue,
2027
+ Nt as getFilterUiMetadata,
2028
+ Ut as getFilterUiTypeOptions,
2020
2029
  ee as getImmediate,
2021
- Xt as getPTableColumnId,
2022
- at as getPartitionKeysList,
2023
- kt as getPlatformaApiVersion,
2024
- Nt as getRawPlatformaInstance,
2025
- lt as getUniquePartitionKeys,
2026
- zt as hasAbortError,
2030
+ tn as getPTableColumnId,
2031
+ pt as getPartitionKeysList,
2032
+ Rt as getPlatformaApiVersion,
2033
+ $t as getRawPlatformaInstance,
2034
+ ft as getUniquePartitionKeys,
2035
+ nn as hasAbortError,
2027
2036
  ie as ifDef,
2028
- At as isColumnHidden,
2029
- Ft as isColumnOptional,
2030
- vt as isConfigLambda,
2031
- ue as isDataInfo,
2032
- _e as isDataInfoEntries,
2033
- It as isLabelColumn,
2034
- xt as isLinkerColumn,
2035
- Ce as isPColumn,
2037
+ Lt as isColumnHidden,
2038
+ Vt as isColumnOptional,
2039
+ St as isConfigLambda,
2040
+ de as isDataInfo,
2041
+ Ae as isDataInfoEntries,
2042
+ Et as isLabelColumn,
2043
+ Ot as isLinkerColumn,
2044
+ _e as isPColumn,
2036
2045
  Y as isPColumnSpec,
2037
- ke as isPTableAbsent,
2038
- Gt as isPTableNA,
2039
- Yt as isPTableValueAxis,
2040
- Be as isPartitionedDataInfoEntries,
2041
- Ue as isPlRef,
2042
- Fe as makeDefaultPTableParams,
2043
- We as mapDataInfo,
2044
- Qt as mapJoinEntry,
2046
+ Re as isPTableAbsent,
2047
+ rn as isPTableNA,
2048
+ sn as isPTableValueAxis,
2049
+ ze as isPartitionedDataInfoEntries,
2050
+ Me as isPlRef,
2051
+ Le as makeDefaultPTableParams,
2052
+ Ze as mapDataInfo,
2053
+ an as mapJoinEntry,
2045
2054
  pe as mapPObjectData,
2046
- Re as mapPTableDef,
2047
- $e as mapValueInVOE,
2048
- Zt as matchAxis,
2049
- en as matchAxisId,
2050
- tn as matchPColumn,
2051
- nn as pTableValue,
2052
- rn as parseJson,
2055
+ Je as mapPTableDef,
2056
+ qe as mapValueInVOE,
2057
+ on as matchAxis,
2058
+ ln as matchAxisId,
2059
+ un as matchPColumn,
2060
+ dn as pTableValue,
2061
+ He as parseJson,
2053
2062
  le as parsePColumnData,
2054
- he as resolveAnchors,
2055
- W as selectorsToPredicate,
2056
- sn as stringifyColumnId,
2057
- Ne as uniquePlId,
2058
- an as unwrapResult,
2059
- wt as upgradePlDataTableStateV2,
2060
- ce as withEnrichments
2063
+ M as readAnnotation,
2064
+ Ne as readAnnotationJson,
2065
+ pn as readDomain,
2066
+ cn as readMetadata,
2067
+ fn as readMetadataJson,
2068
+ hn as readMetadataJsonOrThrow,
2069
+ ye as resolveAnchors,
2070
+ q as selectorsToPredicate,
2071
+ gn as stringifyColumnId,
2072
+ $e as stringifyJson,
2073
+ Be as uniquePlId,
2074
+ mn as unwrapResult,
2075
+ Ft as upgradePlDataTableStateV2,
2076
+ ge as withEnrichments
2061
2077
  };
2062
2078
  //# sourceMappingURL=index.js.map