@platforma-sdk/model 1.24.11 → 1.26.0

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,65 +1,65 @@
1
- var ve = Object.defineProperty;
2
- var _e = (t, e, n) => e in t ? ve(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
3
- var P = (t, e, n) => _e(t, typeof e != "symbol" ? e + "" : e, n);
4
- import { isPColumn as B, mapPObjectData as N, selectorsToPredicate as te, AnchorIdDeriver as $, isPlRef as Ae, resolveAnchors as ne, isPColumnSpec as G, mapValueInVOE as Se, ensurePColumn as we, extractAllColumns as Ie, mapPTableDef as Pe, getAxisId as R, matchAxisId as D } from "@milaboratories/pl-model-common";
1
+ var _e = Object.defineProperty;
2
+ var Ie = (t, e, n) => e in t ? _e(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
3
+ var T = (t, e, n) => Ie(t, typeof e != "symbol" ? e + "" : e, n);
4
+ import { isPColumn as M, mapPObjectData as ue, selectorsToPredicate as ce, AnchoredIdDeriver as te, isPlRef as Ce, resolveAnchors as Le, isPColumnSpec as J, getAxisId as L, entriesToDataInfo as Te, mapValueInVOE as Fe, ensurePColumn as Re, isDataInfo as me, extractAllColumns as ke, mapPTableDef as De, mapDataInfo as Ee, canonicalizeAxisId as Oe, matchAxisId as G } from "@milaboratories/pl-model-common";
5
5
  export * from "@milaboratories/pl-model-common";
6
- import { z as T } from "zod";
7
- class Ce extends Error {
6
+ import { z as E } from "zod";
7
+ class je extends Error {
8
8
  constructor(e, n) {
9
9
  super(`${e.length}${n ? "+" : ""} errors, first error: ` + e[0]), this.errors = e, this.moreErrors = n;
10
10
  }
11
11
  }
12
- function Re(t) {
13
- if (!t.ok) throw new Ce(t.errors, t.moreErrors);
12
+ function Ve(t) {
13
+ if (!t.ok) throw new je(t.errors, t.moreErrors);
14
14
  return t.value;
15
15
  }
16
- function Ze(t) {
16
+ function ft(t) {
17
17
  return new Proxy(t, {
18
18
  get(e, n) {
19
- return Re(e[n]);
19
+ return Ve(e[n]);
20
20
  }
21
21
  });
22
22
  }
23
- function y(t) {
24
- return typeof t == "string" || typeof t == "number" || typeof t == "boolean" || t === null ? j(t) : t;
23
+ function b(t) {
24
+ return typeof t == "string" || typeof t == "number" || typeof t == "boolean" || t === null ? Y(t) : t;
25
25
  }
26
- function O(t) {
26
+ function W(t) {
27
27
  return { type: "GetFromCtx", variable: t };
28
28
  }
29
- function et(t) {
29
+ function ht(t) {
30
30
  return {
31
31
  type: "Isolate",
32
32
  cfg: t
33
33
  };
34
34
  }
35
- const tt = O("$args"), nt = O("$it"), st = O("$prod"), rt = O("$staging"), it = O("$ui");
36
- function j(t) {
35
+ const gt = W("$args"), mt = W("$it"), yt = W("$prod"), bt = W("$staging"), vt = W("$ui");
36
+ function Y(t) {
37
37
  return { type: "Immediate", value: t };
38
38
  }
39
- function ce(t) {
39
+ function ye(t) {
40
40
  const e = {};
41
- for (const [n, s] of Object.entries(t)) e[n] = y(s);
41
+ for (const [n, r] of Object.entries(t)) e[n] = b(r);
42
42
  return {
43
43
  type: "MakeObject",
44
44
  template: e
45
45
  };
46
46
  }
47
- function ot(...t) {
47
+ function wt(...t) {
48
48
  const e = [];
49
- for (const n of t) e.push(y(n));
49
+ for (const n of t) e.push(b(n));
50
50
  return {
51
51
  type: "MakeArray",
52
52
  template: e
53
53
  };
54
54
  }
55
- function U(t, e) {
55
+ function X(t, e) {
56
56
  return {
57
57
  type: "GetJsonField",
58
- source: y(t),
59
- field: y(e)
58
+ source: b(t),
59
+ field: b(e)
60
60
  };
61
61
  }
62
- function at(t, e, n = "$it") {
62
+ function xt(t, e, n = "$it") {
63
63
  return {
64
64
  type: "MapRecordValues",
65
65
  source: t,
@@ -67,7 +67,7 @@ function at(t, e, n = "$it") {
67
67
  itVar: n
68
68
  };
69
69
  }
70
- function lt(t, e, n = "$it") {
70
+ function At(t, e, n = "$it") {
71
71
  return {
72
72
  type: "MapArrayValues",
73
73
  source: t,
@@ -75,54 +75,54 @@ function lt(t, e, n = "$it") {
75
75
  itVar: n
76
76
  };
77
77
  }
78
- function ut(t) {
78
+ function St(t) {
79
79
  return {
80
80
  type: "Flatten",
81
81
  source: t
82
82
  };
83
83
  }
84
- function ct(t) {
84
+ function Pt(t) {
85
85
  return {
86
86
  type: "IsEmpty",
87
87
  arg: t
88
88
  };
89
89
  }
90
- function dt(t) {
90
+ function _t(t) {
91
91
  return {
92
92
  type: "Not",
93
93
  operand: t
94
94
  };
95
95
  }
96
- function pt(t, e) {
96
+ function It(t, e) {
97
97
  return {
98
98
  type: "And",
99
99
  operand1: t,
100
100
  operand2: e
101
101
  };
102
102
  }
103
- function ft(t, e) {
103
+ function Ct(t, e) {
104
104
  return {
105
105
  type: "Or",
106
106
  operand1: t,
107
107
  operand2: e
108
108
  };
109
109
  }
110
- function ht(t, e) {
110
+ function Lt(t, e) {
111
111
  return {
112
112
  type: "GetResourceField",
113
- source: y(t),
114
- field: y(e)
113
+ source: b(t),
114
+ field: b(e)
115
115
  };
116
116
  }
117
- function gt() {
117
+ function Tt() {
118
118
  return function(t) {
119
119
  return {
120
120
  type: "GetResourceValueAsJson",
121
- source: y(t)
121
+ source: b(t)
122
122
  };
123
123
  };
124
124
  }
125
- function mt(t, e, n = "$it") {
125
+ function Ft(t, e, n = "$it") {
126
126
  return {
127
127
  type: "MapResourceFields",
128
128
  source: t,
@@ -130,158 +130,158 @@ function mt(t, e, n = "$it") {
130
130
  itVar: n
131
131
  };
132
132
  }
133
- function yt(t) {
133
+ function Rt(t) {
134
134
  return {
135
135
  type: "GetBlobContent",
136
- source: y(t)
136
+ source: b(t)
137
137
  };
138
138
  }
139
- function bt(t) {
139
+ function kt(t) {
140
140
  return {
141
141
  type: "GetBlobContentAsString",
142
- source: y(t)
142
+ source: b(t)
143
143
  };
144
144
  }
145
- function vt() {
145
+ function Dt() {
146
146
  return function(t) {
147
147
  return {
148
148
  type: "GetBlobContentAsJson",
149
- source: y(t)
149
+ source: b(t)
150
150
  };
151
151
  };
152
152
  }
153
- function _t(t) {
153
+ function Et(t) {
154
154
  return {
155
155
  type: "GetDownloadedBlobContent",
156
- source: y(t)
156
+ source: b(t)
157
157
  };
158
158
  }
159
- function At(t) {
159
+ function Ot(t) {
160
160
  return {
161
161
  type: "GetOnDemandBlobContent",
162
- source: y(t)
162
+ source: b(t)
163
163
  };
164
164
  }
165
- function St(t, e) {
165
+ function jt(t, e) {
166
166
  return {
167
167
  type: "ExtractArchiveAndGetURL",
168
168
  format: e,
169
- source: y(t)
169
+ source: b(t)
170
170
  };
171
171
  }
172
- function wt(t) {
172
+ function Vt(t) {
173
173
  return {
174
174
  type: "GetImportProgress",
175
- source: y(t)
175
+ source: b(t)
176
176
  };
177
177
  }
178
- function It(t, e) {
178
+ function Kt(t, e) {
179
179
  return {
180
180
  type: "GetLastLogs",
181
- source: y(t),
181
+ source: b(t),
182
182
  lines: e
183
183
  };
184
184
  }
185
- function Pt(t, e) {
185
+ function $t(t, e) {
186
186
  return {
187
187
  type: "GetProgressLog",
188
- source: y(t),
188
+ source: b(t),
189
189
  patternToSearch: e
190
190
  };
191
191
  }
192
- function Ct(t, e) {
192
+ function Jt(t, e) {
193
193
  return {
194
194
  type: "GetProgressLogWithInfo",
195
- source: y(t),
195
+ source: b(t),
196
196
  patternToSearch: e
197
197
  };
198
198
  }
199
- function Rt(t) {
199
+ function Nt(t) {
200
200
  return {
201
201
  type: "GetLogHandle",
202
- source: y(t)
202
+ source: b(t)
203
203
  };
204
204
  }
205
- function Fe() {
205
+ function Ke() {
206
206
  return typeof globalThis.getPlatforma < "u" || typeof globalThis.platforma < "u";
207
207
  }
208
- function de(t) {
208
+ function be(t) {
209
209
  if (t && typeof globalThis.getPlatforma == "function")
210
210
  return globalThis.getPlatforma(t);
211
211
  if (typeof globalThis.platforma < "u") return globalThis.platforma;
212
212
  throw new Error("Can't get platforma instance.");
213
213
  }
214
- function Te() {
214
+ function $e() {
215
215
  if (typeof globalThis.cfgRenderCtx < "u") return globalThis.cfgRenderCtx;
216
216
  }
217
- function f() {
217
+ function h() {
218
218
  if (typeof globalThis.cfgRenderCtx < "u") return globalThis.cfgRenderCtx;
219
219
  throw new Error("Not in config rendering context");
220
220
  }
221
- function E(t, e) {
222
- const n = Te();
221
+ function q(t, e) {
222
+ const n = $e();
223
223
  if (n === void 0) return !1;
224
224
  if (t in n.callbackRegistry) throw new Error(`Callback with key ${t} already registered.`);
225
225
  return n.callbackRegistry[t] = e, !0;
226
226
  }
227
- const W = /* @__PURE__ */ new Map();
228
- function xe(t, e) {
229
- t in f().callbackRegistry || (f().callbackRegistry[t] = (n) => {
230
- for (const s of W.get(t))
231
- s(n);
232
- }, W.set(t, [])), W.get(t).push(e);
227
+ const ne = /* @__PURE__ */ new Map();
228
+ function Je(t, e) {
229
+ t in h().callbackRegistry || (h().callbackRegistry[t] = (n) => {
230
+ for (const r of ne.get(t))
231
+ r(n);
232
+ }, ne.set(t, [])), ne.get(t).push(e);
233
233
  }
234
- class _ {
235
- constructor(e, n = (s) => s) {
236
- P(this, "isResolved", !1);
237
- P(this, "resolvedValue");
238
- this.handle = e, this.postProcess = n, xe(e, (s) => {
239
- this.resolvedValue = n(s), this.isResolved = !0;
234
+ class S {
235
+ constructor(e, n = (r) => r) {
236
+ T(this, "isResolved", !1);
237
+ T(this, "resolvedValue");
238
+ this.handle = e, this.postProcess = n, Je(e, (r) => {
239
+ this.resolvedValue = n(r), this.isResolved = !0;
240
240
  });
241
241
  }
242
242
  map(e) {
243
- return new _(this.handle, (n) => e(this.postProcess(n)));
243
+ return new S(this.handle, (n) => e(this.postProcess(n)));
244
244
  }
245
245
  mapDefined(e) {
246
- return new _(this.handle, (n) => {
247
- const s = this.postProcess(n);
248
- return s ? e(s) : void 0;
246
+ return new S(this.handle, (n) => {
247
+ const r = this.postProcess(n);
248
+ return r ? e(r) : void 0;
249
249
  });
250
250
  }
251
251
  toJSON() {
252
252
  return this.isResolved ? this.resolvedValue : { __awaited_futures__: [this.handle] };
253
253
  }
254
254
  }
255
- function z(t, e) {
255
+ function ie(t, e) {
256
256
  return t === void 0 ? void 0 : e(t);
257
257
  }
258
- class S {
258
+ class I {
259
259
  constructor(e, n) {
260
260
  this.handle = e, this.resolvePath = n;
261
261
  }
262
262
  resolve(...e) {
263
263
  const n = e.map(
264
- (s) => ({
264
+ (r) => ({
265
265
  assertFieldType: "Input",
266
- ...typeof s == "string" ? { field: s } : s
266
+ ...typeof r == "string" ? { field: r } : r
267
267
  })
268
268
  );
269
269
  return this.resolveWithCommon({}, ...n);
270
270
  }
271
271
  resolveOutput(...e) {
272
272
  const n = e.map(
273
- (s) => ({
273
+ (r) => ({
274
274
  assertFieldType: "Output",
275
- ...typeof s == "string" ? { field: s } : s
275
+ ...typeof r == "string" ? { field: r } : r
276
276
  })
277
277
  );
278
278
  return this.resolveWithCommon({}, ...n);
279
279
  }
280
280
  resolveInput(...e) {
281
281
  const n = e.map(
282
- (s) => ({
282
+ (r) => ({
283
283
  assertFieldType: "Input",
284
- ...typeof s == "string" ? { field: s } : s
284
+ ...typeof r == "string" ? { field: r } : r
285
285
  })
286
286
  );
287
287
  return this.resolveWithCommon({}, ...n);
@@ -290,51 +290,51 @@ class S {
290
290
  return this.resolveWithCommon({}, ...e);
291
291
  }
292
292
  resolveWithCommon(e, ...n) {
293
- const s = [
293
+ const r = [
294
294
  ...this.resolvePath,
295
- ...n.map((r) => typeof r == "string" ? r : r.field)
295
+ ...n.map((i) => typeof i == "string" ? i : i.field)
296
296
  ];
297
- return z(
298
- f().resolveWithCommon(this.handle, e, ...n),
299
- (r) => new S(r, s)
297
+ return ie(
298
+ h().resolveWithCommon(this.handle, e, ...n),
299
+ (i) => new I(i, r)
300
300
  );
301
301
  }
302
302
  get resourceType() {
303
- return f().getResourceType(this.handle);
303
+ return h().getResourceType(this.handle);
304
304
  }
305
305
  getInputsLocked() {
306
- return f().getInputsLocked(this.handle);
306
+ return h().getInputsLocked(this.handle);
307
307
  }
308
308
  getOutputsLocked() {
309
- return f().getOutputsLocked(this.handle);
309
+ return h().getOutputsLocked(this.handle);
310
310
  }
311
311
  getIsReadyOrError() {
312
- return f().getIsReadyOrError(this.handle);
312
+ return h().getIsReadyOrError(this.handle);
313
313
  }
314
314
  getIsFinal() {
315
- return f().getIsFinal(this.handle);
315
+ return h().getIsFinal(this.handle);
316
316
  }
317
317
  getError() {
318
318
  const e = [...this.resolvePath, "error"];
319
- return z(
320
- f().getError(this.handle),
321
- (n) => new S(n, e)
319
+ return ie(
320
+ h().getError(this.handle),
321
+ (n) => new I(n, e)
322
322
  );
323
323
  }
324
324
  listInputFields() {
325
- return f().listInputFields(this.handle);
325
+ return h().listInputFields(this.handle);
326
326
  }
327
327
  listOutputFields() {
328
- return f().listOutputFields(this.handle);
328
+ return h().listOutputFields(this.handle);
329
329
  }
330
330
  listDynamicFields() {
331
- return f().listDynamicFields(this.handle);
331
+ return h().listDynamicFields(this.handle);
332
332
  }
333
333
  getKeyValueBase64(e) {
334
- return f().getKeyValueBase64(this.handle, e);
334
+ return h().getKeyValueBase64(this.handle, e);
335
335
  }
336
336
  getKeyValueAsString(e) {
337
- return f().getKeyValueAsString(this.handle, e);
337
+ return h().getKeyValueAsString(this.handle, e);
338
338
  }
339
339
  getKeyValueAsJson(e) {
340
340
  const n = this.getKeyValueAsString(e);
@@ -342,10 +342,10 @@ class S {
342
342
  return JSON.parse(n);
343
343
  }
344
344
  getDataBase64() {
345
- return f().getDataBase64(this.handle);
345
+ return h().getDataBase64(this.handle);
346
346
  }
347
347
  getDataAsString() {
348
- return f().getDataAsString(this.handle);
348
+ return h().getDataAsString(this.handle);
349
349
  }
350
350
  getDataAsJson() {
351
351
  const e = this.getDataAsString();
@@ -356,39 +356,39 @@ class S {
356
356
  *
357
357
  */
358
358
  getPColumns(e = !1, n = "") {
359
- const s = this.parsePObjectCollection(e, n);
360
- return s === void 0 ? void 0 : Object.entries(s).map(([, i]) => {
361
- if (!B(i)) throw new Error(`not a PColumn (kind = ${i.spec.kind})`);
362
- return i;
359
+ const r = this.parsePObjectCollection(e, n);
360
+ return r === void 0 ? void 0 : Object.entries(r).map(([, s]) => {
361
+ if (!M(s)) throw new Error(`not a PColumn (kind = ${s.spec.kind})`);
362
+ return s;
363
363
  });
364
364
  }
365
365
  /**
366
366
  *
367
367
  */
368
368
  parsePObjectCollection(e = !1, n = "") {
369
- const s = f().parsePObjectCollection(
369
+ const r = h().parsePObjectCollection(
370
370
  this.handle,
371
371
  e,
372
372
  n,
373
373
  ...this.resolvePath
374
374
  );
375
- if (s === void 0) return;
376
- const r = {};
377
- for (const [i, o] of Object.entries(s)) {
378
- const l = [...this.resolvePath, i];
379
- r[i] = N(o, (a) => new S(a, l));
375
+ if (r === void 0) return;
376
+ const i = {};
377
+ for (const [s, o] of Object.entries(r)) {
378
+ const a = [...this.resolvePath, s];
379
+ i[s] = ue(o, (c) => new I(c, a));
380
380
  }
381
- return r;
381
+ return i;
382
382
  }
383
383
  getFileContentAsBase64() {
384
- return new _(f().getBlobContentAsBase64(this.handle));
384
+ return new S(h().getBlobContentAsBase64(this.handle));
385
385
  }
386
386
  getFileContentAsString() {
387
- return new _(f().getBlobContentAsString(this.handle));
387
+ return new S(h().getBlobContentAsString(this.handle));
388
388
  }
389
389
  getFileContentAsJson() {
390
- return new _(
391
- f().getBlobContentAsString(this.handle)
390
+ return new S(
391
+ h().getBlobContentAsString(this.handle)
392
392
  ).mapDefined((e) => JSON.parse(e));
393
393
  }
394
394
  /**
@@ -407,7 +407,7 @@ class S {
407
407
  * @returns downloaded file handle
408
408
  */
409
409
  getFileHandle() {
410
- return new _(f().getDownloadedBlobContentHandle(this.handle));
410
+ return new S(h().getDownloadedBlobContentHandle(this.handle));
411
411
  }
412
412
  /**
413
413
  * @deprecated use getFileHandle
@@ -419,7 +419,7 @@ class S {
419
419
  * @returns downloaded file handle
420
420
  */
421
421
  getRemoteFileHandle() {
422
- return new _(f().getOnDemandBlobContentHandle(this.handle));
422
+ return new S(h().getOnDemandBlobContentHandle(this.handle));
423
423
  }
424
424
  /**
425
425
  * @deprecated use getRemoteFileHandle
@@ -431,22 +431,22 @@ class S {
431
431
  * @returns the url to the extracted folder
432
432
  */
433
433
  extractArchiveAndGetURL(e) {
434
- return new _(f().extractArchiveAndGetURL(this.handle, e));
434
+ return new S(h().extractArchiveAndGetURL(this.handle, e));
435
435
  }
436
436
  getImportProgress() {
437
- return new _(f().getImportProgress(this.handle));
437
+ return new S(h().getImportProgress(this.handle));
438
438
  }
439
439
  getLastLogs(e) {
440
- return new _(f().getLastLogs(this.handle, e));
440
+ return new S(h().getLastLogs(this.handle, e));
441
441
  }
442
442
  getProgressLog(e) {
443
- return new _(f().getProgressLog(this.handle, e));
443
+ return new S(h().getProgressLog(this.handle, e));
444
444
  }
445
445
  getProgressLogWithInfo(e) {
446
- return new _(f().getProgressLogWithInfo(this.handle, e));
446
+ return new S(h().getProgressLogWithInfo(this.handle, e));
447
447
  }
448
448
  getLogHandle() {
449
- return new _(f().getLogHandle(this.handle));
449
+ return new S(h().getLogHandle(this.handle));
450
450
  }
451
451
  allFieldsResolved(e = "Input") {
452
452
  switch (e) {
@@ -461,116 +461,405 @@ class S {
461
461
  }
462
462
  }
463
463
  mapFields(e, n) {
464
- const { fieldType: s, requireLocked: r, skipUnresolved: i } = {
464
+ const { fieldType: r, requireLocked: i, skipUnresolved: s } = {
465
465
  fieldType: "Input",
466
466
  requireLocked: !0,
467
467
  skipUnresolved: !1,
468
468
  ...n
469
469
  }, o = e;
470
- if (r && (s === "Input" && !this.getInputsLocked() || s === "Output" && !this.getOutputsLocked()))
470
+ if (i && (r === "Input" && !this.getInputsLocked() || r === "Output" && !this.getOutputsLocked()))
471
471
  return;
472
- let a = (s === "Input" ? this.listInputFields() : s === "Output" ? this.listOutputFields() : this.listDynamicFields()).map(
473
- (u) => [u, this.resolve({ field: u, assertFieldType: s })]
472
+ let c = (r === "Input" ? this.listInputFields() : r === "Output" ? this.listOutputFields() : this.listDynamicFields()).map(
473
+ (l) => [l, this.resolve({ field: l, assertFieldType: r })]
474
474
  );
475
- return i && (a = a.filter((u) => u[1] !== void 0)), a.map(([u, g]) => o(u, g));
475
+ return s && (c = c.filter((l) => l[1] !== void 0)), c.map(([l, m]) => o(l, m));
476
476
  }
477
477
  }
478
- const pe = "staging", fe = "main", Le = {
478
+ const ve = "staging", we = "main", Ne = {
479
+ explicitColumnsSupport: !0,
479
480
  inlineColumnsSupport: !0,
480
481
  activeArgs: !0
481
482
  };
482
- function he(t) {
483
+ function xe(t) {
483
484
  return typeof t == "object" && t !== null && "__awaited_futures__" in t;
484
485
  }
485
- function Y(t, e, n) {
486
+ function oe(t, e, n) {
486
487
  if (e.has(n)) return;
487
488
  if (e.add(n), typeof n === "object")
488
- if (he(n)) n.__awaited_futures__.forEach((r) => t.add(r));
489
+ if (xe(n)) n.__awaited_futures__.forEach((i) => t.add(i));
489
490
  else if (Array.isArray(n))
490
- for (const r of n) Y(t, e, r);
491
+ for (const i of n) oe(t, e, i);
491
492
  else
492
- for (const [, r] of Object.entries(n))
493
- r !== n && Y(t, e, r);
493
+ for (const [, i] of Object.entries(n))
494
+ i !== n && oe(t, e, i);
494
495
  }
495
- function De(t) {
496
+ function Be(t) {
496
497
  const e = /* @__PURE__ */ new Set();
497
- return Y(e, /* @__PURE__ */ new Set(), t), e;
498
+ return oe(e, /* @__PURE__ */ new Set(), t), e;
498
499
  }
499
- const Ft = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
500
+ const Bt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
500
501
  __proto__: null,
501
- GlobalCfgRenderCtxFeatureFlags: Le,
502
- MainAccessorName: fe,
503
- StagingAccessorName: pe,
504
- getAllFutureAwaits: De,
505
- isFutureAwait: he
506
- }, Symbol.toStringTag, { value: "Module" })), Oe = "pl7.app/label", ke = "pl7.app/trace", Ee = T.object({
507
- type: T.string(),
508
- importance: T.number().optional(),
509
- id: T.string().optional(),
510
- label: T.string()
511
- }), Ve = T.array(Ee), je = 1e-3, Ne = "__LABEL__", se = "__LABEL__@1";
512
- function re(t, e, n = {}) {
513
- const s = /* @__PURE__ */ new Map(), r = /* @__PURE__ */ new Map(), i = t.map((d) => {
514
- var A, ee;
515
- const h = e(d), p = (A = h.annotations) == null ? void 0 : A[Oe], b = (ee = h.annotations) == null ? void 0 : ee[ke], m = (b ? Ve.safeParse(JSON.parse(b)).data : void 0) ?? [];
516
- if (p) {
517
- const C = { label: p, type: Ne, importance: -2 };
518
- n.addLabelAsSuffix ? m.push(C) : m.splice(0, 0, C);
502
+ GlobalCfgRenderCtxFeatureFlags: Ne,
503
+ MainAccessorName: we,
504
+ StagingAccessorName: ve,
505
+ getAllFutureAwaits: Be,
506
+ isFutureAwait: xe
507
+ }, Symbol.toStringTag, { value: "Module" })), Ue = "pl7.app/label", Me = "pl7.app/trace", Ge = E.object({
508
+ type: E.string(),
509
+ importance: E.number().optional(),
510
+ id: E.string().optional(),
511
+ label: E.string()
512
+ }), We = E.array(Ge), He = 1e-3, qe = "__LABEL__", pe = "__LABEL__@1";
513
+ function de(t, e, n = {}) {
514
+ const r = /* @__PURE__ */ new Map(), i = /* @__PURE__ */ new Map(), s = t.map((f) => {
515
+ var R, k;
516
+ const p = e(f);
517
+ let d, y, g;
518
+ "spec" in p && typeof p.spec == "object" ? (d = p.spec, y = p.prefixTrace, g = p.suffixTrace) : d = p;
519
+ const v = (R = d.annotations) == null ? void 0 : R[Ue], w = (k = d.annotations) == null ? void 0 : k[Me], x = (w ? We.safeParse(JSON.parse(w)).data : void 0) ?? [], C = [
520
+ ...y ?? [],
521
+ ...x,
522
+ ...g ?? []
523
+ ];
524
+ if (v) {
525
+ const A = { label: v, type: qe, importance: -2 };
526
+ n.addLabelAsSuffix ? C.push(A) : C.splice(0, 0, A);
519
527
  }
520
- const I = [], v = /* @__PURE__ */ new Map();
521
- for (let C = m.length - 1; C >= 0; --C) {
522
- const { type: J } = m[C], be = m[C].importance ?? 0, M = (v.get(J) ?? 0) + 1;
523
- v.set(J, M);
524
- const x = `${J}@${M}`;
525
- r.set(x, (r.get(x) ?? 0) + 1), s.set(
526
- x,
528
+ const P = [], F = /* @__PURE__ */ new Map();
529
+ for (let A = C.length - 1; A >= 0; --A) {
530
+ const { type: j } = C[A], V = C[A].importance ?? 0, K = (F.get(j) ?? 0) + 1;
531
+ F.set(j, K);
532
+ const $ = `${j}@${K}`;
533
+ i.set($, (i.get($) ?? 0) + 1), r.set(
534
+ $,
527
535
  Math.max(
528
- s.get(x) ?? Number.NEGATIVE_INFINITY,
529
- be - (m.length - C) * je
536
+ r.get($) ?? Number.NEGATIVE_INFINITY,
537
+ V - (C.length - A) * He
530
538
  )
531
- ), I.push({ ...m[C], fullType: x, occurenceIndex: M });
539
+ ), P.push({ ...C[A], fullType: $, occurenceIndex: K });
532
540
  }
533
- return I.reverse(), {
534
- value: d,
535
- spec: h,
536
- label: p,
537
- fullTrace: I
541
+ return P.reverse(), {
542
+ value: f,
543
+ spec: d,
544
+ label: v,
545
+ fullTrace: P
538
546
  };
539
- }), o = [], l = [], a = [...s];
540
- a.sort(([, d], [, h]) => h - d);
541
- for (const [d] of a)
542
- d.endsWith("@1") || r.get(d) === t.length ? o.push(d) : l.push(d);
543
- const u = (d) => i.map((h) => {
544
- const p = h.fullTrace.filter((m) => d.has(m.fullType)).map((m) => m.label), b = n.separator ?? " / ";
547
+ }), o = [], a = [], c = [...r];
548
+ c.sort(([, f], [, p]) => p - f);
549
+ for (const [f] of c)
550
+ f.endsWith("@1") || i.get(f) === t.length ? o.push(f) : a.push(f);
551
+ const l = (f) => s.map((p) => {
552
+ const d = p.fullTrace.filter((g) => f.has(g.fullType)).map((g) => g.label), y = n.separator ?? " / ";
545
553
  return {
546
- label: p.join(b),
547
- value: h.value
554
+ label: d.join(y),
555
+ value: p.value
548
556
  };
549
557
  });
550
558
  if (o.length === 0) {
551
- if (l.length !== 0) throw new Error("Assertion error.");
552
- return u(new Set(se));
553
- }
554
- let g = 0, c = 0;
555
- for (; g < o.length; ) {
556
- const d = /* @__PURE__ */ new Set();
557
- n.includeNativeLabel && d.add(se);
558
- for (let p = 0; p < g; ++p) d.add(o[p]);
559
- d.add(o[c]);
560
- const h = u(d);
561
- if (new Set(h.map((p) => p.label)).size === t.length) return h;
562
- c++, c == o.length && (g++, c = g);
563
- }
564
- return u(/* @__PURE__ */ new Set([...o, ...l]));
565
- }
566
- class Ue {
559
+ if (a.length !== 0) throw new Error("Assertion error.");
560
+ return l(new Set(pe));
561
+ }
562
+ let m = 0, u = 0;
563
+ for (; m < o.length; ) {
564
+ const f = /* @__PURE__ */ new Set();
565
+ n.includeNativeLabel && f.add(pe);
566
+ for (let d = 0; d < m; ++d) f.add(o[d]);
567
+ f.add(o[u]);
568
+ const p = l(f);
569
+ if (new Set(p.map((d) => d.label)).size === t.length) return p;
570
+ u++, u == o.length && (m++, u = m);
571
+ }
572
+ return l(/* @__PURE__ */ new Set([...o, ...a]));
573
+ }
574
+ const H = "PColumnData/", Q = H + "ResourceMap", Z = H + "Partitioned/ResourceMap", N = H + "JsonPartitioned", O = H + "BinaryPartitioned", Ae = H + "Partitioned/", ee = Ae + "JsonPartitioned", B = Ae + "BinaryPartitioned";
575
+ function Se(t, e, n, r = [], i) {
576
+ if (t === void 0) return !1;
577
+ switch (t.resourceType.name) {
578
+ case Q: {
579
+ let s = t.getInputsLocked();
580
+ for (const o of t.listInputFields()) {
581
+ const a = t.resolve({ field: o, assertFieldType: "Input" }), c = [...r, ...JSON.parse(o)], l = a === void 0 ? void 0 : e(a);
582
+ l === void 0 && (s = !1), (l !== void 0 || i) && n.push({ key: c, value: l });
583
+ }
584
+ return s;
585
+ }
586
+ case Z: {
587
+ let s = t.getInputsLocked();
588
+ for (const o of t.listInputFields()) {
589
+ const a = t.resolve({ field: o, assertFieldType: "Input" });
590
+ if (a === void 0) s = !1;
591
+ else {
592
+ const c = [...r, ...JSON.parse(o)], l = Se(
593
+ a,
594
+ e,
595
+ n,
596
+ c,
597
+ i
598
+ );
599
+ s = s && l;
600
+ }
601
+ }
602
+ return s;
603
+ }
604
+ default:
605
+ throw new Error(`Unknown resource type: ${t.resourceType.name}`);
606
+ }
607
+ }
608
+ function Ut(t, e, n = !1) {
609
+ const r = [];
610
+ return { isComplete: Se(t, e, r, [], n), data: r };
611
+ }
612
+ const ae = (t) => {
613
+ if (t.endsWith(".index"))
614
+ return { baseKey: t.substring(0, t.length - 6), type: "index" };
615
+ if (t.endsWith(".values"))
616
+ return { baseKey: t.substring(0, t.length - 7), type: "values" };
617
+ throw new Error(`key must ends on .index/.values for binary p-column, got: ${t}`);
618
+ };
619
+ function ze(t) {
620
+ if (!t) return;
621
+ const e = t.resourceType.name, n = t.getDataAsJson(), r = [];
622
+ let i = 0;
623
+ switch (e) {
624
+ case Q:
625
+ i = n.keyLength;
626
+ break;
627
+ case Z:
628
+ i = n.partitionKeyLength + n.keyLength;
629
+ break;
630
+ case N:
631
+ case O:
632
+ i = n.partitionKeyLength;
633
+ break;
634
+ case B:
635
+ case ee:
636
+ i = n.superPartitionKeyLength + n.partitionKeyLength;
637
+ break;
638
+ }
639
+ switch (e) {
640
+ case Q:
641
+ case N:
642
+ case O:
643
+ for (let s of t.listInputFields()) {
644
+ e === O && (s = ae(s).baseKey);
645
+ const o = [...JSON.parse(s)];
646
+ r.push(o);
647
+ }
648
+ break;
649
+ case Z:
650
+ case B:
651
+ case ee:
652
+ for (const s of t.listInputFields()) {
653
+ const o = [...JSON.parse(s)], a = t.resolve({ field: s, assertFieldType: "Input" });
654
+ if (a !== void 0)
655
+ for (let c of a.listInputFields()) {
656
+ e === B && (c = ae(c).baseKey);
657
+ const l = [...o, ...JSON.parse(c)];
658
+ r.push(l);
659
+ }
660
+ }
661
+ break;
662
+ }
663
+ return { data: r, keyLength: i };
664
+ }
665
+ function Ye(t) {
666
+ const e = ze(t);
667
+ if (!e) return;
668
+ const { data: n, keyLength: r } = e, i = [];
669
+ for (let s = 0; s < r; ++s)
670
+ i.push(/* @__PURE__ */ new Set());
671
+ for (const s of n) {
672
+ if (s.length !== r)
673
+ throw new Error("key length does not match partition length");
674
+ for (let o = 0; o < r; ++o)
675
+ i[o].add(s[o]);
676
+ }
677
+ return i.map((s) => Array.from(s.values()));
678
+ }
679
+ function le(t, e = []) {
680
+ if (t === void 0) return;
681
+ const n = t.resourceType.name, r = t.getDataAsJson();
682
+ if (e.length > 0 && (n === ee || n === B))
683
+ throw new Error(`Unexpected nested super-partitioned resource: ${n}`);
684
+ switch (n) {
685
+ case Q:
686
+ case Z:
687
+ throw new Error(`Only data columns are supported, got: ${n}`);
688
+ case N: {
689
+ if (typeof (r == null ? void 0 : r.partitionKeyLength) != "number")
690
+ throw new Error(`Missing partitionKeyLength in metadata for ${n}`);
691
+ const i = [];
692
+ for (const s of t.listInputFields()) {
693
+ const o = t.resolve({ field: s, assertFieldType: "Input" });
694
+ if (o === void 0) return;
695
+ const a = [...e, ...JSON.parse(s)];
696
+ i.push({ key: a, value: o });
697
+ }
698
+ return {
699
+ type: "JsonPartitioned",
700
+ partitionKeyLength: r.partitionKeyLength,
701
+ parts: i
702
+ };
703
+ }
704
+ case O: {
705
+ if (typeof (r == null ? void 0 : r.partitionKeyLength) != "number")
706
+ throw new Error(`Missing partitionKeyLength in metadata for ${n}`);
707
+ const i = [], s = /* @__PURE__ */ new Map();
708
+ for (const o of t.listInputFields()) {
709
+ const a = ae(o), c = t.resolve({ field: o, assertFieldType: "Input" });
710
+ if (c === void 0) return;
711
+ let l = s.get(a.baseKey);
712
+ l || (l = {}, s.set(a.baseKey, l)), a.type === "index" ? l.index = c : l.values = c;
713
+ }
714
+ for (const [o, a] of s.entries()) {
715
+ if (!a.index || !a.values) return;
716
+ const c = [...e, ...JSON.parse(o)];
717
+ i.push({
718
+ key: c,
719
+ value: {
720
+ index: a.index,
721
+ values: a.values
722
+ }
723
+ });
724
+ }
725
+ return {
726
+ type: "BinaryPartitioned",
727
+ partitionKeyLength: r.partitionKeyLength,
728
+ parts: i
729
+ };
730
+ }
731
+ case ee: {
732
+ if (typeof (r == null ? void 0 : r.superPartitionKeyLength) != "number" || typeof (r == null ? void 0 : r.partitionKeyLength) != "number")
733
+ throw new Error(`Missing superPartitionKeyLength or partitionKeyLength in metadata for ${n}`);
734
+ const i = r.superPartitionKeyLength + r.partitionKeyLength, s = [];
735
+ for (const o of t.listInputFields()) {
736
+ const a = t.resolve({ field: o, assertFieldType: "Input" });
737
+ if (a === void 0) return;
738
+ if (a.resourceType.name !== N)
739
+ throw new Error(`Expected ${N} inside ${n}, but got ${a.resourceType.name}`);
740
+ const c = le(a, JSON.parse(o));
741
+ if (c === void 0) return;
742
+ if (c.type !== "JsonPartitioned")
743
+ throw new Error(`Unexpected inner result type for ${n}: ${c.type}`);
744
+ s.push(...c.parts);
745
+ }
746
+ return {
747
+ type: "JsonPartitioned",
748
+ partitionKeyLength: i,
749
+ parts: s
750
+ };
751
+ }
752
+ case B: {
753
+ if (typeof (r == null ? void 0 : r.superPartitionKeyLength) != "number" || typeof (r == null ? void 0 : r.partitionKeyLength) != "number")
754
+ throw new Error(`Missing superPartitionKeyLength or partitionKeyLength in metadata for ${n}`);
755
+ const i = r.superPartitionKeyLength + r.partitionKeyLength, s = [];
756
+ for (const o of t.listInputFields()) {
757
+ const a = t.resolve({ field: o, assertFieldType: "Input" });
758
+ if (a === void 0) return;
759
+ if (a.resourceType.name !== O)
760
+ throw new Error(`Expected ${O} inside ${n}, but got ${a.resourceType.name}`);
761
+ const c = le(a, JSON.parse(o));
762
+ if (c === void 0) return;
763
+ if (c.type !== "BinaryPartitioned")
764
+ throw new Error(`Unexpected inner result type for ${n}: ${c.type}`);
765
+ s.push(...c.parts);
766
+ }
767
+ return {
768
+ type: "BinaryPartitioned",
769
+ partitionKeyLength: i,
770
+ parts: s
771
+ };
772
+ }
773
+ default:
774
+ throw new Error(`Unknown resource type: ${n}`);
775
+ }
776
+ }
777
+ function Xe(t, e) {
778
+ const n = [...e].sort((s, o) => o[0] - s[0]);
779
+ if (t.type === "JsonPartitioned" || t.type === "BinaryPartitioned") {
780
+ const { partitionKeyLength: s } = t;
781
+ for (const [o] of e)
782
+ if (o >= s)
783
+ throw new Error(`Can't filter on non-partitioned axis ${o}. Must be >= ${s}`);
784
+ } else if (t.type === "Json") {
785
+ const { keyLength: s } = t;
786
+ for (const [o] of e)
787
+ if (o >= s)
788
+ throw new Error(`Can't filter on non-data axis ${o}. Must be >= ${s}`);
789
+ }
790
+ const r = (s) => {
791
+ for (const [o, a] of n)
792
+ if (s[o] !== a)
793
+ return !1;
794
+ return !0;
795
+ }, i = (s) => {
796
+ const o = [...s];
797
+ for (const [a] of n)
798
+ o.splice(a, 1);
799
+ return o;
800
+ };
801
+ switch (t.type) {
802
+ case "Json": {
803
+ const s = t.data.filter((o) => r(o.key)).map((o) => ({
804
+ key: i(o.key),
805
+ value: o.value
806
+ }));
807
+ return {
808
+ type: "Json",
809
+ keyLength: t.keyLength - e.length,
810
+ data: s
811
+ };
812
+ }
813
+ case "JsonPartitioned": {
814
+ const s = t.parts.filter((o) => r(o.key)).map((o) => ({
815
+ key: i(o.key),
816
+ value: o.value
817
+ }));
818
+ return {
819
+ type: "JsonPartitioned",
820
+ partitionKeyLength: t.partitionKeyLength - e.length,
821
+ parts: s
822
+ };
823
+ }
824
+ case "BinaryPartitioned": {
825
+ const s = t.parts.filter((o) => r(o.key)).map((o) => ({
826
+ key: i(o.key),
827
+ value: o.value
828
+ }));
829
+ return {
830
+ type: "BinaryPartitioned",
831
+ partitionKeyLength: t.partitionKeyLength - e.length,
832
+ parts: s
833
+ };
834
+ }
835
+ }
836
+ }
837
+ function re(t, e) {
838
+ if (t === void 0) return e === void 0;
839
+ if (e === void 0) return !0;
840
+ for (const n in e)
841
+ if (t[n] !== e[n]) return !1;
842
+ return !0;
843
+ }
844
+ function fe(t) {
845
+ return ue(t, (e) => e instanceof I ? e.handle : me(e) ? Ee(e, (n) => n.handle) : e);
846
+ }
847
+ function Qe(t) {
848
+ if (t)
849
+ return t.map((e) => ({
850
+ type: `split:${Oe(e.axisId)}`,
851
+ label: e.label,
852
+ importance: 1e6
853
+ // High importance for split filters in labels
854
+ }));
855
+ }
856
+ function Ze(t) {
857
+ if (t)
858
+ return t.map((e) => [e.axisIdx, e.value]);
859
+ }
860
+ class et {
567
861
  constructor() {
568
- P(this, "ctx", f());
569
- // @TODO: unused, what is this for?
570
- P(this, "defaultLabelFn", (e, n) => {
571
- var s;
572
- return ((s = e.annotations) == null ? void 0 : s["pl7.app/label"]) ?? "Unlabelled";
573
- });
862
+ T(this, "ctx", h());
574
863
  }
575
864
  /**
576
865
  * @deprecated use getOptions()
@@ -579,35 +868,199 @@ class Ue {
579
868
  return this.ctx.calculateOptions(e);
580
869
  }
581
870
  getOptions(e, n) {
582
- const s = typeof e == "function" ? e : te(e), r = this.getSpecs().entries.filter((i) => s(i.obj));
583
- return typeof n == "object" || typeof n > "u" ? re(r, (i) => i.obj, n ?? {}).map(({ value: { ref: i }, label: o }) => ({
584
- ref: i,
871
+ const r = typeof e == "function" ? e : ce(e), i = this.getSpecs().entries.filter((s) => r(s.obj));
872
+ return typeof n == "object" || typeof n > "u" ? de(i, (s) => s.obj, n ?? {}).map(({ value: { ref: s }, label: o }) => ({
873
+ ref: s,
585
874
  label: o
586
- })) : r.map((i) => ({
587
- ref: i.ref,
588
- label: n(i.obj, i.ref)
875
+ })) : i.map((s) => ({
876
+ ref: s.ref,
877
+ label: n(s.obj, s.ref)
589
878
  }));
590
879
  }
591
- // Implementation
592
- getCanonicalOptions(e, n, s) {
593
- const r = {};
594
- if (!(e instanceof $))
595
- for (const [a, u] of Object.entries(e))
596
- if (Ae(u)) {
597
- const g = this.getPColumnSpecByRef(u);
598
- if (!g)
880
+ /**
881
+ * Internal implementation that generates UniversalPColumnEntry objects from the provided
882
+ * anchors and selectors.
883
+ */
884
+ getUniversalPColumnEntries(e, n, r) {
885
+ const i = {};
886
+ if (!(e instanceof te))
887
+ for (const [l, m] of Object.entries(e))
888
+ if (Ce(m)) {
889
+ const u = this.getPColumnSpecByRef(m);
890
+ if (!u)
599
891
  return;
600
- r[a] = g;
892
+ i[l] = u;
601
893
  } else
602
- r[a] = u;
603
- const i = typeof n == "function" ? n : te(
604
- Array.isArray(n) ? n.map((a) => ne(r, a)) : ne(r, n)
605
- ), o = this.getSpecs().entries.filter(({ obj: a }) => G(a) ? i(a) : !1), l = e instanceof $ ? e : new $(r);
606
- return re(o, (a) => a.obj, s ?? {}).map(({ value: { obj: a }, label: u }) => ({
607
- value: l.deriveCanonical(a),
608
- label: u
894
+ i[l] = m;
895
+ const s = typeof n == "function" ? [n] : Array.isArray(n) ? n : [n], o = e instanceof te ? e : new te(i), a = [];
896
+ for (const l of s) {
897
+ const m = typeof l == "function" ? l : ce(Le(i, l)), u = this.getSpecs().entries.filter(({ obj: p }) => J(p) ? m(p) : !1);
898
+ if (u.length === 0)
899
+ continue;
900
+ const f = typeof l == "object" && "axes" in l && l.axes !== void 0 && l.partialAxesMatch === void 0 ? l.axes.map((p, d) => "split" in p && p.split === !0 ? d : -1).filter((p) => p !== -1) : [];
901
+ if (f.sort((p, d) => p - d), f.length > 0) {
902
+ const p = f[f.length - 1];
903
+ for (const { ref: d, obj: y } of u) {
904
+ if (!J(y)) throw new Error(`Assertion failed: expected PColumnSpec, got ${y.kind}`);
905
+ const g = this.getDataByRef(d);
906
+ if (!g) {
907
+ if (r != null && r.dontWaitAllData) continue;
908
+ return;
909
+ }
910
+ if (!M(g)) throw new Error(`Assertion failed: expected PColumn, got ${g.spec.kind}`);
911
+ const v = Ye(g.data);
912
+ if (!v) {
913
+ if (r != null && r.dontWaitAllData) continue;
914
+ return;
915
+ }
916
+ if (p >= v.length)
917
+ throw new Error(`Not enough partition keys for the requested split axes in column ${y.name}`);
918
+ const w = f.map((P) => this.findLabels(L(y.axesSpec[P]))), x = [], C = (P, F) => {
919
+ if (F >= f.length) {
920
+ x.push([...P]);
921
+ return;
922
+ }
923
+ const R = f[F], k = v[R];
924
+ for (const A of k)
925
+ P.push(A), C(P, F + 1), P.pop();
926
+ };
927
+ C([], 0);
928
+ for (const P of x) {
929
+ const F = P.map((R, k) => {
930
+ const A = f[k], j = L(y.axesSpec[A]), V = w[k], K = (V == null ? void 0 : V[R]) ?? String(R);
931
+ return { axisIdx: A, axisId: j, value: R, label: K };
932
+ });
933
+ a.push({
934
+ obj: y,
935
+ ref: d,
936
+ axisFilters: F
937
+ });
938
+ }
939
+ }
940
+ } else
941
+ for (const { ref: p, obj: d } of u)
942
+ J(d) && a.push({
943
+ obj: d,
944
+ ref: p
945
+ // No splitFilters needed here
946
+ });
947
+ }
948
+ return a.length === 0 ? [] : de(
949
+ a,
950
+ (l) => ({
951
+ spec: l.obj,
952
+ suffixTrace: Qe(l.axisFilters)
953
+ // Use helper function
954
+ }),
955
+ (r == null ? void 0 : r.labelOps) ?? {}
956
+ ).map((l) => ({
957
+ id: o.deriveS(
958
+ l.value.obj,
959
+ Ze(l.value.axisFilters)
960
+ // Use helper function
961
+ ),
962
+ obj: l.value.obj,
963
+ ref: l.value.ref,
964
+ axisFilters: l.value.axisFilters,
965
+ label: l.label
609
966
  }));
610
967
  }
968
+ /**
969
+ * Returns columns that match the provided anchors and selectors. It applies axis filters and label derivation.
970
+ *
971
+ * @param anchorsOrCtx - Anchor context for column selection (same as in getCanonicalOptions)
972
+ * @param predicateOrSelectors - Predicate or selectors for filtering columns (same as in getCanonicalOptions)
973
+ * @param opts - Optional configuration for label generation and data waiting
974
+ * @returns A PFrameHandle for the created PFrame, or undefined if any required data is missing
975
+ */
976
+ getAnchoredPColumns(e, n, r) {
977
+ const i = {
978
+ ...r,
979
+ labelOps: {
980
+ includeNativeLabel: !0,
981
+ ...(r == null ? void 0 : r.labelOps) || {}
982
+ }
983
+ }, s = this.getUniversalPColumnEntries(
984
+ e,
985
+ n,
986
+ i
987
+ );
988
+ if (!s || s.length === 0) return;
989
+ const o = [];
990
+ for (const a of s) {
991
+ const c = this.getPColumnByRef(a.ref);
992
+ if (!c) return;
993
+ const l = le(c.data);
994
+ if (!l) return;
995
+ let m = l, u = { ...c.spec };
996
+ if (a.axisFilters && a.axisFilters.length > 0) {
997
+ const p = a.axisFilters.map((g) => [
998
+ g.axisIdx,
999
+ g.value
1000
+ ]);
1001
+ m = Xe(l, p);
1002
+ const d = [...a.axisFilters].map((g) => g.axisIdx).sort((g, v) => v - g), y = [...u.axesSpec];
1003
+ for (const g of d)
1004
+ y.splice(g, 1);
1005
+ u = { ...u, axesSpec: y };
1006
+ }
1007
+ const f = Te(m);
1008
+ u.annotations ? u = {
1009
+ ...u,
1010
+ annotations: {
1011
+ ...u.annotations,
1012
+ "pl7.app/label": a.label
1013
+ }
1014
+ } : u = {
1015
+ ...u,
1016
+ annotations: {
1017
+ "pl7.app/label": a.label
1018
+ }
1019
+ }, o.push({
1020
+ id: a.id,
1021
+ spec: u,
1022
+ data: f
1023
+ });
1024
+ }
1025
+ return o;
1026
+ }
1027
+ /**
1028
+ * Calculates anchored identifier options for columns matching a given predicate and returns their
1029
+ * canonicalized representations.
1030
+ *
1031
+ * This function filters column specifications from the result pool that match the provided predicate,
1032
+ * creates a standardized AnchorCtx from the provided anchors, and generates a list of label-value
1033
+ * pairs for UI components (like dropdowns).
1034
+ *
1035
+ * @param anchorsOrCtx - Either:
1036
+ * - An existing AnchorCtx instance
1037
+ * - A record mapping anchor IDs to PColumnSpec objects
1038
+ * - A record mapping anchor IDs to PlRef objects (which will be resolved to PColumnSpec)
1039
+ * @param predicateOrSelectors - Either:
1040
+ * - A predicate function that takes a PColumnSpec and returns a boolean.
1041
+ * Only specs that return true will be included.
1042
+ * - An APColumnSelector object for declarative filtering, which will be
1043
+ * resolved against the provided anchors and matched using matchPColumn.
1044
+ * - An array of APColumnSelector objects - columns matching ANY selector
1045
+ * in the array will be included (OR operation).
1046
+ * @param opts - Optional configuration for label generation:
1047
+ * - labelOps: Optional configuration for label generation:
1048
+ * - includeNativeLabel: Whether to include native column labels
1049
+ * - separator: String to use between label parts (defaults to " / ")
1050
+ * - addLabelAsSuffix: Whether to add labels as suffix instead of prefix
1051
+ * - dontWaitAllData: Whether to skip columns that don't have all data (if not set, will return undefined,
1052
+ * if at least one column that requires splitting is missing data)
1053
+ * @returns An array of objects with `label` (display text) and `value` (anchored ID string) properties,
1054
+ * or undefined if any PlRef resolution fails.
1055
+ */
1056
+ getCanonicalOptions(e, n, r) {
1057
+ const i = this.getUniversalPColumnEntries(e, n, r);
1058
+ if (i)
1059
+ return i.map((s) => ({
1060
+ value: s.id,
1061
+ label: s.label
1062
+ }));
1063
+ }
611
1064
  /**
612
1065
  * @deprecated use getData()
613
1066
  */
@@ -622,7 +1075,7 @@ class Ue {
622
1075
  ref: n.ref,
623
1076
  obj: {
624
1077
  ...n.obj,
625
- data: new S(n.obj.data, [n.ref.blockId, n.ref.name])
1078
+ data: new I(n.obj.data, [n.ref.blockId, n.ref.name])
626
1079
  }
627
1080
  }))
628
1081
  };
@@ -641,9 +1094,9 @@ class Ue {
641
1094
  ref: n.ref,
642
1095
  obj: {
643
1096
  ...n.obj,
644
- data: Se(
1097
+ data: Fe(
645
1098
  n.obj.data,
646
- (s) => new S(s, [n.ref.blockId, n.ref.name])
1099
+ (r) => new I(r, [n.ref.blockId, n.ref.name])
647
1100
  )
648
1101
  }
649
1102
  }))
@@ -663,13 +1116,17 @@ class Ue {
663
1116
  * @returns data associated with the ref
664
1117
  */
665
1118
  getDataByRef(e) {
666
- var n;
667
- return typeof this.ctx.getDataFromResultPoolByRef > "u" ? (n = this.getData().entries.find(
668
- (s) => s.ref.blockId === e.blockId && s.ref.name === e.name
669
- )) == null ? void 0 : n.obj : N(
670
- this.ctx.getDataFromResultPoolByRef(e.blockId, e.name),
671
- (s) => new S(s, [e.blockId, e.name])
672
- );
1119
+ var r;
1120
+ if (typeof this.ctx.getDataFromResultPoolByRef > "u")
1121
+ return (r = this.getData().entries.find(
1122
+ (i) => i.ref.blockId === e.blockId && i.ref.name === e.name
1123
+ )) == null ? void 0 : r.obj;
1124
+ const n = this.ctx.getDataFromResultPoolByRef(e.blockId, e.name);
1125
+ if (n)
1126
+ return ue(
1127
+ n,
1128
+ (i) => new I(i, [e.blockId, e.name])
1129
+ );
673
1130
  }
674
1131
  /**
675
1132
  * Returns data associated with the ref ensuring that it is a p-column.
@@ -679,7 +1136,7 @@ class Ue {
679
1136
  getPColumnByRef(e) {
680
1137
  const n = this.getDataByRef(e);
681
1138
  if (n)
682
- return we(n);
1139
+ return Re(n);
683
1140
  }
684
1141
  /**
685
1142
  * Returns spec associated with the ref ensuring that it is a p-column spec.
@@ -689,7 +1146,7 @@ class Ue {
689
1146
  getPColumnSpecByRef(e) {
690
1147
  const n = this.getSpecByRef(e);
691
1148
  if (n) {
692
- if (!G(n)) throw new Error(`not a PColumn spec (kind = ${n.kind})`);
1149
+ if (!J(n)) throw new Error(`not a PColumn spec (kind = ${n.kind})`);
693
1150
  return n;
694
1151
  }
695
1152
  }
@@ -707,38 +1164,51 @@ class Ue {
707
1164
  */
708
1165
  findDataWithCompatibleSpec(e) {
709
1166
  const n = [];
710
- e: for (const s of this.getData().entries) {
711
- if (!G(s.obj.spec))
1167
+ e: for (const r of this.getData().entries) {
1168
+ if (!J(r.obj.spec))
712
1169
  continue;
713
- const r = s.obj.spec;
714
- if (e.name === r.name && e.valueType === r.valueType && e.axesSpec.length === r.axesSpec.length && X(e.domain, r.domain)) {
715
- for (let i = 0; i < e.axesSpec.length; ++i) {
716
- const o = e.axesSpec[i], l = r.axesSpec[i];
717
- if (o.name !== l.name || o.type !== l.type || !X(o.domain, l.domain))
1170
+ const i = r.obj.spec;
1171
+ if (e.name === i.name && e.valueType === i.valueType && e.axesSpec.length === i.axesSpec.length && re(e.domain, i.domain)) {
1172
+ for (let s = 0; s < e.axesSpec.length; ++s) {
1173
+ const o = e.axesSpec[s], a = i.axesSpec[s];
1174
+ if (o.name !== a.name || o.type !== a.type || !re(o.domain, a.domain))
718
1175
  continue e;
719
1176
  }
720
- n.push(s.obj);
1177
+ n.push(r.obj);
721
1178
  }
722
1179
  }
723
1180
  return n;
724
1181
  }
1182
+ /**
1183
+ * Find labels data for a given axis id. It will search for a label column and return its data as a map.
1184
+ * @returns a map of axis value => label
1185
+ */
1186
+ findLabels(e) {
1187
+ const n = this.getData();
1188
+ for (const r of n.entries) {
1189
+ if (!M(r.obj)) continue;
1190
+ const i = r.obj.spec;
1191
+ if (i.name === "pl7.app/label" && i.axesSpec.length === 1 && i.axesSpec[0].name === e.name && i.axesSpec[0].type === e.type && re(e.domain, i.axesSpec[0].domain)) {
1192
+ if (r.obj.data.resourceType.name !== "PColumnData/Json")
1193
+ throw Error(`Expected JSON column for labels, got: ${r.obj.data.resourceType.name}`);
1194
+ return Object.fromEntries(
1195
+ Object.entries(
1196
+ r.obj.data.getDataAsJson().data
1197
+ ).map((o) => [JSON.parse(o[0])[0], o[1]])
1198
+ );
1199
+ }
1200
+ }
1201
+ }
725
1202
  }
726
- function X(t, e) {
727
- if (t === void 0) return e === void 0;
728
- if (e === void 0) return !0;
729
- for (const n in e)
730
- if (t[n] !== e[n]) return !1;
731
- return !0;
732
- }
733
- class V {
1203
+ class z {
734
1204
  constructor() {
735
- P(this, "ctx");
736
- P(this, "args");
737
- P(this, "uiState");
1205
+ T(this, "ctx");
1206
+ T(this, "args");
1207
+ T(this, "uiState");
738
1208
  // lazy rendering because this feature is rarely used
739
- P(this, "_activeArgsCache");
740
- P(this, "resultPool", new Ue());
741
- this.ctx = f(), this.args = JSON.parse(this.ctx.args), this.uiState = this.ctx.uiState !== void 0 ? JSON.parse(this.ctx.uiState) : {};
1209
+ T(this, "_activeArgsCache");
1210
+ T(this, "resultPool", new et());
1211
+ this.ctx = h(), this.args = JSON.parse(this.ctx.args), this.uiState = this.ctx.uiState !== void 0 ? JSON.parse(this.ctx.uiState) : {};
742
1212
  }
743
1213
  /**
744
1214
  * Returns args snapshot the block was executed for (i.e. when "Run" button was pressed).
@@ -754,45 +1224,33 @@ class V {
754
1224
  // return this.ctx.featureFlags;
755
1225
  // }
756
1226
  getNamedAccessor(e) {
757
- return z(
1227
+ return ie(
758
1228
  this.ctx.getAccessorHandleByName(e),
759
- (n) => new S(n, [e])
1229
+ (n) => new I(n, [e])
760
1230
  );
761
1231
  }
762
1232
  get prerun() {
763
- return this.getNamedAccessor(pe);
1233
+ return this.getNamedAccessor(ve);
764
1234
  }
765
1235
  get outputs() {
766
- return this.getNamedAccessor(fe);
1236
+ return this.getNamedAccessor(we);
767
1237
  }
768
1238
  /**
769
1239
  * Find labels data for a given axis id. It will search for a label column and return its data as a map.
770
1240
  * @returns a map of axis value => label
1241
+ * @deprecated Use resultPool.findLabels instead
771
1242
  */
772
1243
  findLabels(e) {
773
- const n = this.resultPool.getData();
774
- for (const s of n.entries) {
775
- if (!B(s.obj)) continue;
776
- const r = s.obj.spec;
777
- if (r.name === "pl7.app/label" && r.axesSpec.length === 1 && r.axesSpec[0].name === e.name && r.axesSpec[0].type === e.type && X(e.domain, r.axesSpec[0].domain)) {
778
- if (s.obj.data.resourceType.name !== "PColumnData/Json")
779
- throw Error(`Expected JSON column for labels, got: ${s.obj.data.resourceType.name}`);
780
- return Object.fromEntries(
781
- Object.entries(
782
- s.obj.data.getDataAsJson().data
783
- ).map((o) => [JSON.parse(o[0])[0], o[1]])
784
- );
785
- }
786
- }
1244
+ return this.resultPool.findLabels(e);
787
1245
  }
788
- verifyInlineColumnsSupport(e) {
789
- var r;
790
- const n = e.some((i) => !(i.data instanceof S)), s = ((r = this.ctx.featureFlags) == null ? void 0 : r.inlineColumnsSupport) === !0;
791
- if (n && !s) throw Error("inline columns not supported");
1246
+ verifyInlineAndExplicitColumnsSupport(e) {
1247
+ var i;
1248
+ const n = e.some((s) => !(s.data instanceof I) || me(s.data)), r = ((i = this.ctx.featureFlags) == null ? void 0 : i.inlineColumnsSupport) === !0;
1249
+ if (n && !r) throw Error("Inline or explicit columns not supported");
792
1250
  }
793
1251
  createPFrame(e) {
794
- return this.verifyInlineColumnsSupport(e), this.ctx.createPFrame(
795
- e.map((n) => N(n, (s) => s instanceof S ? s.handle : s))
1252
+ return this.verifyInlineAndExplicitColumnsSupport(e), this.ctx.createPFrame(
1253
+ e.map((n) => fe(n))
796
1254
  );
797
1255
  }
798
1256
  createPTable(e) {
@@ -800,15 +1258,12 @@ class V {
800
1258
  return "columns" in e ? n = {
801
1259
  src: {
802
1260
  type: "full",
803
- entries: e.columns.map((s) => ({ type: "column", column: s }))
1261
+ entries: e.columns.map((r) => ({ type: "column", column: r }))
804
1262
  },
805
1263
  filters: e.filters ?? [],
806
1264
  sorting: e.sorting ?? []
807
- } : n = e, this.verifyInlineColumnsSupport(Ie(n.src)), this.ctx.createPTable(
808
- Pe(
809
- n,
810
- (s) => N(s, (r) => r instanceof S ? r.handle : r)
811
- )
1265
+ } : n = e, this.verifyInlineAndExplicitColumnsSupport(ke(n.src)), this.ctx.createPTable(
1266
+ De(n, (r) => fe(r))
812
1267
  );
813
1268
  }
814
1269
  /** @deprecated scheduled for removal from SDK */
@@ -820,189 +1275,76 @@ class V {
820
1275
  return this.ctx.getCurrentUnstableMarker();
821
1276
  }
822
1277
  }
823
- const k = "PColumnData/", Q = k + "ResourceMap", Z = k + "Partitioned/ResourceMap", ie = k + "JsonPartitioned", K = k + "BinaryPartitioned", ge = k + "Partitioned/", oe = ge + "JsonPartitioned", H = ge + "BinaryPartitioned";
824
- function me(t, e, n, s = [], r) {
825
- if (t === void 0) return !1;
826
- switch (t.resourceType.name) {
827
- case Q: {
828
- let i = t.getInputsLocked();
829
- for (const o of t.listInputFields()) {
830
- const l = t.resolve({ field: o, assertFieldType: "Input" }), a = [...s, ...JSON.parse(o)], u = l === void 0 ? void 0 : e(l);
831
- u === void 0 && (i = !1), (u !== void 0 || r) && n.push({ key: a, value: u });
832
- }
833
- return i;
834
- }
835
- case Z: {
836
- let i = t.getInputsLocked();
837
- for (const o of t.listInputFields()) {
838
- const l = t.resolve({ field: o, assertFieldType: "Input" });
839
- if (l === void 0) i = !1;
840
- else {
841
- const a = [...s, ...JSON.parse(o)], u = me(
842
- l,
843
- e,
844
- n,
845
- a,
846
- r
847
- );
848
- i = i && u;
849
- }
850
- }
851
- return i;
852
- }
853
- default:
854
- throw new Error(`Unknown resource type: ${t.resourceType.name}`);
855
- }
856
- }
857
- function Tt(t, e, n = !1) {
858
- const s = [];
859
- return { isComplete: me(t, e, s, [], n), data: s };
860
- }
861
- const ae = (t) => {
862
- if (!t.endsWith(".index")) {
863
- if (t.endsWith(".values"))
864
- return t.substring(0, t.length - 7);
865
- throw Error(`key must ends on .index/.values for binary p-column, got: ${t}`);
866
- }
867
- };
868
- function Be(t) {
869
- if (!t) return;
870
- const e = t.resourceType.name, n = t.getDataAsJson(), s = [];
871
- let r = 0;
872
- switch (e) {
873
- case Q:
874
- r = n.keyLength;
875
- break;
876
- case Z:
877
- r = n.partitionKeyLength + n.keyLength;
878
- break;
879
- case ie:
880
- case K:
881
- r = n.partitionKeyLength;
882
- break;
883
- case H:
884
- case oe:
885
- r = n.superPartitionKeyLength + n.partitionKeyLength;
886
- break;
887
- }
888
- switch (e) {
889
- case Q:
890
- case ie:
891
- case K:
892
- for (let i of t.listInputFields()) {
893
- if (e === K) {
894
- const l = ae(i);
895
- if (l) i = l;
896
- else continue;
897
- }
898
- const o = [...JSON.parse(i)];
899
- s.push(o);
900
- }
901
- break;
902
- case Z:
903
- case H:
904
- case oe:
905
- for (const i of t.listInputFields()) {
906
- const o = [...JSON.parse(i)], l = t.resolve({ field: i, assertFieldType: "Input" });
907
- if (l !== void 0)
908
- for (let a of l.listInputFields()) {
909
- if (e === H) {
910
- const g = ae(a);
911
- if (g) a = g;
912
- else continue;
913
- }
914
- const u = [...o, ...JSON.parse(a)];
915
- s.push(u);
916
- }
917
- }
918
- break;
919
- }
920
- return { data: s, keyLength: r };
921
- }
922
- function xt(t) {
923
- const e = Be(t);
924
- if (!e) return;
925
- const { data: n, keyLength: s } = e, r = [];
926
- for (let i = 0; i < s; ++i)
927
- r.push(/* @__PURE__ */ new Set());
928
- for (const i of n) {
929
- if (i.length !== s)
930
- throw new Error("key length does not match partition length");
931
- for (let o = 0; o < s; ++o)
932
- r[o].add(i[o]);
933
- }
934
- return r.map((i) => Array.from(i.values()));
935
- }
936
- const L = "1.24.11";
937
- function Je(t) {
1278
+ const U = "1.26.0";
1279
+ function tt(t) {
938
1280
  return t.__renderLambda === !0;
939
1281
  }
940
- function q(t) {
1282
+ function se(t) {
941
1283
  if (t !== void 0)
942
- return Je(t) ? t.handle : t;
1284
+ return tt(t) ? t.handle : t;
943
1285
  }
944
- function F(t) {
1286
+ function D(t) {
945
1287
  if (t !== void 0)
946
1288
  return typeof t == "string" ? { __renderLambda: !0, handle: t, retentive: !1 } : t;
947
1289
  }
948
- function Lt(t) {
1290
+ function Mt(t) {
949
1291
  if (t.v3 !== void 0) {
950
1292
  const {
951
1293
  initialArgs: e,
952
1294
  initialUiState: n,
953
- inputsValid: s,
954
- outputs: r,
955
- renderingMode: i,
1295
+ inputsValid: r,
1296
+ outputs: i,
1297
+ renderingMode: s,
956
1298
  sdkVersion: o,
957
- sections: l,
958
- title: a
959
- } = t.v3, { code: u } = t;
1299
+ sections: a,
1300
+ title: c
1301
+ } = t.v3, { code: l } = t;
960
1302
  return {
961
1303
  initialArgs: e,
962
1304
  initialUiState: n,
963
- inputsValid: s,
964
- outputs: r,
965
- renderingMode: i,
1305
+ inputsValid: r,
1306
+ outputs: i,
1307
+ renderingMode: s,
966
1308
  sdkVersion: o,
967
- sections: l,
968
- title: a,
969
- code: u
1309
+ sections: a,
1310
+ title: c,
1311
+ code: l
970
1312
  };
971
1313
  } else if (t.inputsValid !== void 0) {
972
- const { sdkVersion: e, renderingMode: n, outputs: s, inputsValid: r, sections: i, initialArgs: o, code: l } = t, a = Object.keys(t);
973
- if (e === void 0 || n === void 0 || s === void 0 || r === void 0 || i === void 0 || o === void 0)
1314
+ const { sdkVersion: e, renderingMode: n, outputs: r, inputsValid: i, sections: s, initialArgs: o, code: a } = t, c = Object.keys(t);
1315
+ if (e === void 0 || n === void 0 || r === void 0 || i === void 0 || s === void 0 || o === void 0)
974
1316
  throw new Error(
975
- `Malformed config v2. SDK version ${e}; Fields = ${a.join(", ")}`
1317
+ `Malformed config v2. SDK version ${e}; Fields = ${c.join(", ")}`
976
1318
  );
977
1319
  return {
978
1320
  sdkVersion: e,
979
1321
  renderingMode: n,
980
1322
  initialArgs: o,
981
1323
  outputs: Object.fromEntries(
982
- Object.entries(s).map(([u, g]) => [u, F(g)])
1324
+ Object.entries(r).map(([l, m]) => [l, D(m)])
983
1325
  ),
984
- inputsValid: F(r),
985
- sections: F(i),
1326
+ inputsValid: D(i),
1327
+ sections: D(s),
986
1328
  initialUiState: void 0,
987
- code: l
1329
+ code: a
988
1330
  };
989
1331
  } else if (t.renderingMode !== void 0) {
990
- const { sdkVersion: e, canRun: n, renderingMode: s, outputs: r, sections: i, initialArgs: o, code: l } = t, a = Object.keys(t);
991
- if (s === void 0 || r === void 0 || n === void 0 || i === void 0 || o === void 0)
1332
+ const { sdkVersion: e, canRun: n, renderingMode: r, outputs: i, sections: s, initialArgs: o, code: a } = t, c = Object.keys(t);
1333
+ if (r === void 0 || i === void 0 || n === void 0 || s === void 0 || o === void 0)
992
1334
  throw new Error(
993
- `Malformed config v1. SDK version ${e}; Fields = ${a.join(", ")}`
1335
+ `Malformed config v1. SDK version ${e}; Fields = ${c.join(", ")}`
994
1336
  );
995
1337
  return {
996
1338
  sdkVersion: e ?? "unknown",
997
- renderingMode: s,
1339
+ renderingMode: r,
998
1340
  initialArgs: o,
999
1341
  outputs: Object.fromEntries(
1000
- Object.entries(r).map(([u, g]) => [u, F(g)])
1342
+ Object.entries(i).map(([l, m]) => [l, D(m)])
1001
1343
  ),
1002
- inputsValid: F(n),
1003
- sections: F(i),
1344
+ inputsValid: D(n),
1345
+ sections: D(s),
1004
1346
  initialUiState: void 0,
1005
- code: l
1347
+ code: a
1006
1348
  };
1007
1349
  } else {
1008
1350
  const { sdkVersion: e } = t, n = Object.keys(t);
@@ -1011,25 +1353,25 @@ function Lt(t) {
1011
1353
  );
1012
1354
  }
1013
1355
  }
1014
- class w {
1015
- constructor(e, n, s, r, i, o, l) {
1016
- this._renderingMode = e, this._initialArgs = n, this._initialUiState = s, this._outputs = r, this._inputsValid = i, this._sections = o, this._title = l;
1356
+ class _ {
1357
+ constructor(e, n, r, i, s, o, a) {
1358
+ this._renderingMode = e, this._initialArgs = n, this._initialUiState = r, this._outputs = i, this._inputsValid = s, this._sections = o, this._title = a;
1017
1359
  }
1018
1360
  static create(e = "Heavy") {
1019
- return new w(
1361
+ return new _(
1020
1362
  e,
1021
1363
  void 0,
1022
1364
  {},
1023
1365
  {},
1024
- j(!0),
1025
- j([]),
1366
+ Y(!0),
1367
+ Y([]),
1026
1368
  void 0
1027
1369
  );
1028
1370
  }
1029
- output(e, n, s = {}) {
1371
+ output(e, n, r = {}) {
1030
1372
  if (typeof n == "function") {
1031
- const r = `output#${e}`;
1032
- return E(r, () => n(new V())), new w(
1373
+ const i = `output#${e}`;
1374
+ return q(i, () => n(new z())), new _(
1033
1375
  this._renderingMode,
1034
1376
  this._initialArgs,
1035
1377
  this._initialUiState,
@@ -1037,8 +1379,8 @@ class w {
1037
1379
  ...this._outputs,
1038
1380
  [e]: {
1039
1381
  __renderLambda: !0,
1040
- handle: r,
1041
- ...s
1382
+ handle: i,
1383
+ ...r
1042
1384
  }
1043
1385
  },
1044
1386
  this._inputsValid,
@@ -1046,7 +1388,7 @@ class w {
1046
1388
  this._title
1047
1389
  );
1048
1390
  } else
1049
- return new w(
1391
+ return new _(
1050
1392
  this._renderingMode,
1051
1393
  this._initialArgs,
1052
1394
  this._initialUiState,
@@ -1064,7 +1406,7 @@ class w {
1064
1406
  return this.output(e, n, { retentive: !0 });
1065
1407
  }
1066
1408
  argsValid(e) {
1067
- return typeof e == "function" ? (E("inputsValid", () => e(new V())), new w(
1409
+ return typeof e == "function" ? (q("inputsValid", () => e(new z())), new _(
1068
1410
  this._renderingMode,
1069
1411
  this._initialArgs,
1070
1412
  this._initialUiState,
@@ -1075,7 +1417,7 @@ class w {
1075
1417
  },
1076
1418
  this._sections,
1077
1419
  this._title
1078
- )) : new w(
1420
+ )) : new _(
1079
1421
  this._renderingMode,
1080
1422
  this._initialArgs,
1081
1423
  this._initialUiState,
@@ -1086,7 +1428,7 @@ class w {
1086
1428
  );
1087
1429
  }
1088
1430
  sections(e) {
1089
- return Array.isArray(e) ? this.sections(j(e)) : typeof e == "function" ? (E("sections", () => e(new V())), new w(
1431
+ return Array.isArray(e) ? this.sections(Y(e)) : typeof e == "function" ? (q("sections", () => e(new z())), new _(
1090
1432
  this._renderingMode,
1091
1433
  this._initialArgs,
1092
1434
  this._initialUiState,
@@ -1094,7 +1436,7 @@ class w {
1094
1436
  this._inputsValid,
1095
1437
  { __renderLambda: !0, handle: "sections" },
1096
1438
  this._title
1097
- )) : new w(
1439
+ )) : new _(
1098
1440
  this._renderingMode,
1099
1441
  this._initialArgs,
1100
1442
  this._initialUiState,
@@ -1106,7 +1448,7 @@ class w {
1106
1448
  }
1107
1449
  /** Sets a rendering function to derive block title, shown for the block in the left blocks-overview panel. */
1108
1450
  title(e) {
1109
- return E("title", () => e(new V())), new w(
1451
+ return q("title", () => e(new z())), new _(
1110
1452
  this._renderingMode,
1111
1453
  this._initialArgs,
1112
1454
  this._initialUiState,
@@ -1121,7 +1463,7 @@ class w {
1121
1463
  * @deprecated use {@link withArgs}
1122
1464
  * */
1123
1465
  initialArgs(e) {
1124
- return new w(
1466
+ return new _(
1125
1467
  this._renderingMode,
1126
1468
  e,
1127
1469
  this._initialUiState,
@@ -1133,7 +1475,7 @@ class w {
1133
1475
  }
1134
1476
  /** Sets initial args for the block, this value must be specified. */
1135
1477
  withArgs(e) {
1136
- return new w(
1478
+ return new _(
1137
1479
  this._renderingMode,
1138
1480
  e,
1139
1481
  this._initialUiState,
@@ -1145,7 +1487,7 @@ class w {
1145
1487
  }
1146
1488
  /** Defines type and sets initial value for block UiState. */
1147
1489
  withUiState(e) {
1148
- return new w(
1490
+ return new _(
1149
1491
  this._renderingMode,
1150
1492
  this._initialArgs,
1151
1493
  e,
@@ -1162,7 +1504,7 @@ class w {
1162
1504
  if (this._initialArgs === void 0) throw new Error("Initial arguments not set.");
1163
1505
  const e = {
1164
1506
  v3: {
1165
- sdkVersion: L,
1507
+ sdkVersion: U,
1166
1508
  renderingMode: this._renderingMode,
1167
1509
  initialArgs: this._initialArgs,
1168
1510
  initialUiState: this._initialUiState,
@@ -1172,185 +1514,185 @@ class w {
1172
1514
  outputs: this._outputs
1173
1515
  },
1174
1516
  // fields below are added to allow previous desktop versions read generated configs
1175
- sdkVersion: L,
1517
+ sdkVersion: U,
1176
1518
  renderingMode: this._renderingMode,
1177
1519
  initialArgs: this._initialArgs,
1178
- inputsValid: q(this._inputsValid),
1179
- sections: q(this._sections),
1520
+ inputsValid: se(this._inputsValid),
1521
+ sections: se(this._sections),
1180
1522
  outputs: Object.fromEntries(
1181
- Object.entries(this._outputs).map(([n, s]) => [n, q(s)])
1523
+ Object.entries(this._outputs).map(([n, r]) => [n, se(r)])
1182
1524
  )
1183
1525
  };
1184
- return Fe() ? de({ sdkVersion: L }) : { config: e };
1185
- }
1186
- }
1187
- function Dt(t, e, n, s) {
1188
- var u, g;
1189
- Array.isArray(s) && (s = { filters: s });
1190
- const r = t.resultPool.getData().entries.map((c) => c.obj).filter(B).filter((c) => c.spec.name === "pl7.app/label" && c.spec.axesSpec.length === 1), i = (c, d) => {
1191
- let h = c.toString();
1192
- if (d)
1193
- for (const p in d)
1194
- h += p, h += d[p];
1195
- return h;
1526
+ return Ke() ? be({ sdkVersion: U }) : { config: e };
1527
+ }
1528
+ }
1529
+ function Gt(t, e, n, r) {
1530
+ var l, m;
1531
+ Array.isArray(r) && (r = { filters: r });
1532
+ const i = t.resultPool.getData().entries.map((u) => u.obj).filter(M).filter((u) => u.spec.name === "pl7.app/label" && u.spec.axesSpec.length === 1), s = (u, f) => {
1533
+ let p = u.toString();
1534
+ if (f)
1535
+ for (const d in f)
1536
+ p += d, p += f[d];
1537
+ return p;
1196
1538
  }, o = /* @__PURE__ */ new Map();
1197
- for (const c of e)
1198
- for (const d of c.spec.axesSpec) {
1199
- const h = R(d);
1200
- for (const p of r) {
1201
- const b = p.spec.axesSpec[0], m = R(p.spec.axesSpec[0]);
1202
- if (D(h, m)) {
1203
- const I = Object.keys(h.domain ?? {}).length, v = Object.keys(m.domain ?? {}).length;
1204
- if (I > v) {
1205
- const A = i(p.id, h.domain);
1206
- o.set(A, {
1207
- id: A,
1539
+ for (const u of e)
1540
+ for (const f of u.spec.axesSpec) {
1541
+ const p = L(f);
1542
+ for (const d of i) {
1543
+ const y = d.spec.axesSpec[0], g = L(d.spec.axesSpec[0]);
1544
+ if (G(p, g)) {
1545
+ const v = Object.keys(p.domain ?? {}).length, w = Object.keys(g.domain ?? {}).length;
1546
+ if (v > w) {
1547
+ const x = s(d.id, p.domain);
1548
+ o.set(x, {
1549
+ id: x,
1208
1550
  spec: {
1209
- ...p.spec,
1210
- axesSpec: [{ ...h, annotations: b.annotations }]
1551
+ ...d.spec,
1552
+ axesSpec: [{ ...p, annotations: y.annotations }]
1211
1553
  },
1212
- data: p.data
1554
+ data: d.data
1213
1555
  });
1214
1556
  } else
1215
- o.set(i(p.id), p);
1557
+ o.set(s(d.id), d);
1216
1558
  }
1217
1559
  }
1218
1560
  }
1219
1561
  if ([...e, ...o.values()].some(
1220
- (c) => c.data instanceof S && !c.data.getIsReadyOrError()
1562
+ (u) => u.data instanceof I && !u.data.getIsReadyOrError()
1221
1563
  ))
1222
1564
  return;
1223
- let l = e;
1224
- const a = [];
1225
- if (s != null && s.coreColumnPredicate) {
1226
- l = [];
1227
- for (const c of e)
1228
- s.coreColumnPredicate(c.spec) ? l.push(c) : a.push(c);
1229
- }
1230
- return a.push(...o.values()), t.createPTable({
1565
+ let a = e;
1566
+ const c = [];
1567
+ if (r != null && r.coreColumnPredicate) {
1568
+ a = [];
1569
+ for (const u of e)
1570
+ r.coreColumnPredicate(u.spec) ? a.push(u) : c.push(u);
1571
+ }
1572
+ return c.push(...o.values()), t.createPTable({
1231
1573
  src: {
1232
1574
  type: "outer",
1233
1575
  primary: {
1234
- type: (s == null ? void 0 : s.coreJoinType) ?? "full",
1235
- entries: l.map((c) => ({ type: "column", column: c }))
1576
+ type: (r == null ? void 0 : r.coreJoinType) ?? "full",
1577
+ entries: a.map((u) => ({ type: "column", column: u }))
1236
1578
  },
1237
- secondary: a.map((c) => ({ type: "column", column: c }))
1579
+ secondary: c.map((u) => ({ type: "column", column: u }))
1238
1580
  },
1239
- filters: [...(s == null ? void 0 : s.filters) ?? [], ...((u = n == null ? void 0 : n.pTableParams) == null ? void 0 : u.filters) ?? []],
1240
- sorting: ((g = n == null ? void 0 : n.pTableParams) == null ? void 0 : g.sorting) ?? []
1581
+ filters: [...(r == null ? void 0 : r.filters) ?? [], ...((l = n == null ? void 0 : n.pTableParams) == null ? void 0 : l.filters) ?? []],
1582
+ sorting: ((m = n == null ? void 0 : n.pTableParams) == null ? void 0 : m.sorting) ?? []
1241
1583
  });
1242
1584
  }
1243
- function Ot(t, e, n) {
1244
- const s = t.findLabels(e);
1585
+ function Wt(t, e, n) {
1586
+ const r = t.resultPool.findLabels(e);
1245
1587
  return {
1246
1588
  axis: e,
1247
- options: n.map((r) => ({
1248
- value: r,
1249
- label: (s == null ? void 0 : s[r]) ?? r.toString()
1589
+ options: n.map((i) => ({
1590
+ value: i,
1591
+ label: (r == null ? void 0 : r[i]) ?? i.toString()
1250
1592
  })),
1251
1593
  defaultValue: n[0]
1252
1594
  };
1253
1595
  }
1254
- const Me = (t, e) => {
1596
+ const nt = (t, e) => {
1255
1597
  let n = t.toString();
1256
- return e == null || e.forEach((s) => {
1257
- if (s)
1258
- for (const [r, i] of Object.entries(s))
1259
- n += r, n += i;
1598
+ return e == null || e.forEach((r) => {
1599
+ if (r)
1600
+ for (const [i, s] of Object.entries(r))
1601
+ n += i, n += s;
1260
1602
  }), n;
1261
1603
  };
1262
- function $e(t) {
1604
+ function rt(t) {
1263
1605
  if (!t.length)
1264
1606
  return [];
1265
1607
  let e = [[]];
1266
1608
  return t.forEach((n) => {
1267
- const s = [];
1268
- n.forEach((r) => {
1269
- s.push(...e.map((i) => [...i, r]));
1270
- }), e = s;
1609
+ const r = [];
1610
+ n.forEach((i) => {
1611
+ r.push(...e.map((s) => [...s, i]));
1612
+ }), e = r;
1271
1613
  }), e;
1272
1614
  }
1273
- function Ge(t, e) {
1274
- const n = t.spec.axesSpec.map(R);
1275
- return e.spec.axesSpec.map(R).every((r) => n.some((i) => D(i, r) && D(r, i)));
1615
+ function st(t, e) {
1616
+ const n = t.spec.axesSpec.map(L);
1617
+ return e.spec.axesSpec.map(L).every((i) => n.some((s) => G(s, i) && G(i, s)));
1276
1618
  }
1277
- function ye(t, e) {
1278
- const n = t.spec.axesSpec.map(R);
1279
- return e.spec.axesSpec.map(R).every((r) => n.some((i) => D(i, r)));
1619
+ function Pe(t, e) {
1620
+ const n = t.spec.axesSpec.map(L);
1621
+ return e.spec.axesSpec.map(L).every((i) => n.some((s) => G(s, i)));
1280
1622
  }
1281
- const We = "pl7.app/graph/isVirtual", le = "pl7.app/label";
1282
- function ue(t, e) {
1283
- const n = t.spec.axesSpec.map(R), s = e.spec.axesSpec.map(R);
1284
- if (Ge(t, e))
1623
+ const it = "pl7.app/graph/isVirtual", he = "pl7.app/label";
1624
+ function ge(t, e) {
1625
+ const n = t.spec.axesSpec.map(L), r = e.spec.axesSpec.map(L);
1626
+ if (st(t, e))
1285
1627
  return [];
1286
- if (!ye(t, e))
1628
+ if (!Pe(t, e))
1287
1629
  return [];
1288
- const o = s.map((c) => n.filter((d) => D(d, c))), l = $e(o), a = /* @__PURE__ */ new Set(), u = /* @__PURE__ */ new Set(), g = l.map((c) => {
1289
- const d = /* @__PURE__ */ new Set();
1290
- return c.map((h, p) => {
1291
- const b = e.spec.axesSpec[p].domain, m = h.domain;
1292
- return Object.entries(m ?? {}).forEach(([I, v]) => {
1293
- if ((b == null ? void 0 : b[I]) === void 0) {
1294
- const A = JSON.stringify([I, v]);
1295
- d.add(A), a.add(A);
1630
+ const o = r.map((u) => n.filter((f) => G(f, u))), a = rt(o), c = /* @__PURE__ */ new Set(), l = /* @__PURE__ */ new Set(), m = a.map((u) => {
1631
+ const f = /* @__PURE__ */ new Set();
1632
+ return u.map((p, d) => {
1633
+ const y = e.spec.axesSpec[d].domain, g = p.domain;
1634
+ return Object.entries(g ?? {}).forEach(([v, w]) => {
1635
+ if ((y == null ? void 0 : y[v]) === void 0) {
1636
+ const x = JSON.stringify([v, w]);
1637
+ f.add(x), c.add(x);
1296
1638
  }
1297
1639
  }), {
1298
- ...h,
1299
- annotations: e.spec.axesSpec[p].annotations
1640
+ ...p,
1641
+ annotations: e.spec.axesSpec[d].annotations
1300
1642
  };
1301
- }), d;
1643
+ }), f;
1302
1644
  });
1303
- return [...a].forEach((c) => {
1304
- g.some((d) => !d.has(c)) && u.add(c);
1305
- }), l.map((c, d) => {
1306
- var I;
1307
- const h = Me(e.id, c.map((v) => v.domain)), p = ((I = e.spec.annotations) == null ? void 0 : I[le]) ?? "", b = [...g[d]].filter((v) => u.has(v)).sort().map((v) => {
1308
- var A;
1309
- return (A = JSON.parse(v)) == null ? void 0 : A[1];
1310
- }).join(" / "), m = {
1645
+ return [...c].forEach((u) => {
1646
+ m.some((f) => !f.has(u)) && l.add(u);
1647
+ }), a.map((u, f) => {
1648
+ var v;
1649
+ const p = nt(e.id, u.map((w) => w.domain)), d = ((v = e.spec.annotations) == null ? void 0 : v[he]) ?? "", y = [...m[f]].filter((w) => l.has(w)).sort().map((w) => {
1650
+ var x;
1651
+ return (x = JSON.parse(w)) == null ? void 0 : x[1];
1652
+ }).join(" / "), g = {
1311
1653
  ...e.spec.annotations,
1312
- [We]: "true"
1654
+ [it]: "true"
1313
1655
  };
1314
- return (p || b) && (m[le] = p && b ? p + " / " + b : p + b), {
1315
- id: h,
1656
+ return (d || y) && (g[he] = d && y ? d + " / " + y : d + y), {
1657
+ id: p,
1316
1658
  spec: {
1317
1659
  ...e.spec,
1318
- axesSpec: c.map((v, A) => ({
1319
- ...v,
1320
- annotations: e.spec.axesSpec[A].annotations
1660
+ axesSpec: u.map((w, x) => ({
1661
+ ...w,
1662
+ annotations: e.spec.axesSpec[x].annotations
1321
1663
  })),
1322
- annotations: m
1664
+ annotations: g
1323
1665
  },
1324
1666
  data: e.data
1325
1667
  };
1326
1668
  });
1327
1669
  }
1328
- function Ke(t) {
1670
+ function ot(t) {
1329
1671
  const e = [];
1330
1672
  for (let n = 0; n < t.length; n++)
1331
- for (let s = n + 1; s < t.length; s++) {
1332
- const r = t[n], i = t[s];
1673
+ for (let r = n + 1; r < t.length; r++) {
1674
+ const i = t[n], s = t[r];
1333
1675
  e.push(
1334
- ...ue(r, i),
1335
- ...ue(i, r)
1676
+ ...ge(i, s),
1677
+ ...ge(s, i)
1336
1678
  );
1337
1679
  }
1338
1680
  return e;
1339
1681
  }
1340
- function He(t, e) {
1682
+ function at(t, e) {
1341
1683
  const n = [...t];
1342
- for (const s of e)
1343
- for (const r of t) {
1344
- if (r.id === s.id)
1684
+ for (const r of e)
1685
+ for (const i of t) {
1686
+ if (i.id === r.id)
1345
1687
  break;
1346
- if (ye(r, s)) {
1347
- n.push(s);
1688
+ if (Pe(i, r)) {
1689
+ n.push(r);
1348
1690
  break;
1349
1691
  }
1350
1692
  }
1351
1693
  return n;
1352
1694
  }
1353
- const qe = [
1695
+ const lt = [
1354
1696
  "Int",
1355
1697
  "Long",
1356
1698
  "Float",
@@ -1358,15 +1700,15 @@ const qe = [
1358
1700
  "String",
1359
1701
  "Bytes"
1360
1702
  ];
1361
- function kt(t, e) {
1703
+ function Ht(t, e) {
1362
1704
  if (e === void 0) return;
1363
- const n = t.resultPool.getData().entries.map((i) => i.obj).filter(B).filter((i) => qe.includes(i.spec.valueType)), s = He(e, n), r = [...s, ...Ke(s)];
1364
- if (!r.some(
1365
- (i) => i.data instanceof S && !i.data.getIsReadyOrError()
1705
+ const n = t.resultPool.getData().entries.map((s) => s.obj).filter(M).filter((s) => lt.includes(s.spec.valueType)), r = at(e, n), i = [...r, ...ot(r)];
1706
+ if (!i.some(
1707
+ (s) => s.data instanceof I && !s.data.getIsReadyOrError()
1366
1708
  ))
1367
- return t.createPFrame(r);
1709
+ return t.createPFrame(i);
1368
1710
  }
1369
- class Et {
1711
+ class qt {
1370
1712
  constructor(e) {
1371
1713
  this.handle = e;
1372
1714
  }
@@ -1386,101 +1728,103 @@ class Et {
1386
1728
  return await platforma.pFrameDriver.getUniqueValues(this.handle, e);
1387
1729
  }
1388
1730
  }
1389
- function ze(t) {
1390
- return ce({
1731
+ function ut(t) {
1732
+ return ye({
1391
1733
  __isRef: !0,
1392
- blockId: U(t, "blockId"),
1393
- name: U(t, "name")
1734
+ blockId: X(t, "blockId"),
1735
+ name: X(t, "name")
1394
1736
  });
1395
1737
  }
1396
- function Vt(t) {
1397
- return ce({
1398
- ref: ze(U(t, "ref")),
1399
- label: U(t, "label")
1738
+ function zt(t) {
1739
+ return ye({
1740
+ ref: ut(X(t, "ref")),
1741
+ label: X(t, "label")
1400
1742
  });
1401
1743
  }
1402
- const jt = {
1403
- sdkVersion: L
1744
+ const Yt = {
1745
+ sdkVersion: U
1404
1746
  };
1405
- function Nt() {
1406
- return de({ sdkVersion: L });
1747
+ function Xt() {
1748
+ return be({ sdkVersion: U });
1407
1749
  }
1408
- function Ut(t) {
1750
+ function Qt(t) {
1409
1751
  if (typeof globalThis.getEnvironmentValue == "function")
1410
1752
  return globalThis.getEnvironmentValue(t);
1411
1753
  }
1412
1754
  export {
1413
- tt as Args,
1414
- w as BlockModel,
1415
- jt as CurrentSdkInfo,
1416
- _ as FutureRef,
1417
- We as IS_VIRTUAL_COLUMN,
1418
- nt as It,
1419
- Ft as JsRenderInternal,
1420
- le as LABEL_ANNOTATION,
1421
- st as MainOutputs,
1422
- Ce as OutputError,
1423
- Oe as PAnnotationLabel,
1424
- ke as PAnnotationTrace,
1425
- Et as PFrameImpl,
1426
- K as RT_BINARY_PARTITIONED,
1427
- H as RT_BINARY_SUPER_PARTITIONED,
1428
- ie as RT_JSON_PARTITIONED,
1429
- oe as RT_JSON_SUPER_PARTITIONED,
1755
+ gt as Args,
1756
+ _ as BlockModel,
1757
+ Yt as CurrentSdkInfo,
1758
+ S as FutureRef,
1759
+ it as IS_VIRTUAL_COLUMN,
1760
+ mt as It,
1761
+ Bt as JsRenderInternal,
1762
+ he as LABEL_ANNOTATION,
1763
+ yt as MainOutputs,
1764
+ je as OutputError,
1765
+ Ue as PAnnotationLabel,
1766
+ Me as PAnnotationTrace,
1767
+ qt as PFrameImpl,
1768
+ O as RT_BINARY_PARTITIONED,
1769
+ B as RT_BINARY_SUPER_PARTITIONED,
1770
+ N as RT_JSON_PARTITIONED,
1771
+ ee as RT_JSON_SUPER_PARTITIONED,
1430
1772
  Q as RT_RESOURCE_MAP,
1431
1773
  Z as RT_RESOURCE_MAP_PARTITIONED,
1432
- V as RenderCtx,
1433
- Ue as ResultPool,
1434
- rt as StagingOutputs,
1435
- Ve as Trace,
1436
- Ee as TraceEntry,
1437
- S as TreeNodeAccessor,
1438
- it as UiState,
1439
- pt as and,
1440
- kt as createPFrameForGraphs,
1441
- Dt as createPlDataTable,
1442
- Ot as createPlDataTableSheet,
1443
- re as deriveLabels,
1444
- q as downgradeCfgOrLambda,
1445
- He as enrichColumnsWithCompatible,
1446
- St as extractArchiveAndGetURL,
1447
- Lt as extractConfig,
1448
- ut as flatten,
1449
- Vt as fromPlOption,
1450
- ze as fromPlRef,
1451
- Ke as getAdditionalColumns,
1452
- yt as getBlobContent,
1453
- vt as getBlobContentAsJson,
1454
- bt as getBlobContentAsString,
1455
- _t as getDownloadedBlobContent,
1456
- Ut as getEnvironmentValue,
1457
- O as getFromCfg,
1458
- j as getImmediate,
1459
- wt as getImportProgress,
1460
- U as getJsonField,
1461
- It as getLastLogs,
1462
- Rt as getLogHandle,
1463
- At as getOnDemandBlobContent,
1464
- Be as getPartitionKeysList,
1465
- Pt as getProgressLog,
1466
- Ct as getProgressLogWithInfo,
1467
- Nt as getRawPlatformaInstance,
1468
- ht as getResourceField,
1469
- gt as getResourceValueAsJson,
1470
- xt as getUniquePartitionKeys,
1471
- z as ifDef,
1472
- Je as isConfigLambda,
1473
- ct as isEmpty,
1474
- et as isolate,
1475
- ot as makeArray,
1476
- ce as makeObject,
1477
- lt as mapArrayValues,
1478
- at as mapRecordValues,
1479
- mt as mapResourceFields,
1480
- dt as not,
1481
- ft as or,
1482
- Tt as parseResourceMap,
1483
- Re as readOutput,
1484
- Ze as wrapOutputs
1774
+ z as RenderCtx,
1775
+ et as ResultPool,
1776
+ bt as StagingOutputs,
1777
+ We as Trace,
1778
+ Ge as TraceEntry,
1779
+ I as TreeNodeAccessor,
1780
+ vt as UiState,
1781
+ It as and,
1782
+ Ht as createPFrameForGraphs,
1783
+ Gt as createPlDataTable,
1784
+ Wt as createPlDataTableSheet,
1785
+ de as deriveLabels,
1786
+ se as downgradeCfgOrLambda,
1787
+ at as enrichColumnsWithCompatible,
1788
+ jt as extractArchiveAndGetURL,
1789
+ Mt as extractConfig,
1790
+ Xe as filterDataInfoEntries,
1791
+ St as flatten,
1792
+ zt as fromPlOption,
1793
+ ut as fromPlRef,
1794
+ ot as getAdditionalColumns,
1795
+ Rt as getBlobContent,
1796
+ Dt as getBlobContentAsJson,
1797
+ kt as getBlobContentAsString,
1798
+ Et as getDownloadedBlobContent,
1799
+ Qt as getEnvironmentValue,
1800
+ W as getFromCfg,
1801
+ Y as getImmediate,
1802
+ Vt as getImportProgress,
1803
+ X as getJsonField,
1804
+ Kt as getLastLogs,
1805
+ Nt as getLogHandle,
1806
+ Ot as getOnDemandBlobContent,
1807
+ ze as getPartitionKeysList,
1808
+ $t as getProgressLog,
1809
+ Jt as getProgressLogWithInfo,
1810
+ Xt as getRawPlatformaInstance,
1811
+ Lt as getResourceField,
1812
+ Tt as getResourceValueAsJson,
1813
+ Ye as getUniquePartitionKeys,
1814
+ ie as ifDef,
1815
+ tt as isConfigLambda,
1816
+ Pt as isEmpty,
1817
+ ht as isolate,
1818
+ wt as makeArray,
1819
+ ye as makeObject,
1820
+ At as mapArrayValues,
1821
+ xt as mapRecordValues,
1822
+ Ft as mapResourceFields,
1823
+ _t as not,
1824
+ Ct as or,
1825
+ le as parsePColumnData,
1826
+ Ut as parseResourceMap,
1827
+ Ve as readOutput,
1828
+ ft as wrapOutputs
1485
1829
  };
1486
1830
  //# sourceMappingURL=index.mjs.map