@platforma-sdk/model 1.7.53 → 1.8.19

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,41 +1,41 @@
1
- var B = Object.defineProperty;
2
- var E = (e, t, n) => t in e ? B(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
- var l = (e, t, n) => E(e, typeof t != "symbol" ? t + "" : t, n);
4
- import { isPColumn as D, mapPObjectData as A, mapValueInVOE as L, mapPTableDef as j, getAxisId as F, matchAxisId as k } from "@milaboratories/pl-model-common";
1
+ var E = Object.defineProperty;
2
+ var j = (e, t, n) => t in e ? E(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
+ var c = (e, t, n) => j(e, typeof t != "symbol" ? t + "" : t, n);
4
+ import { isPColumn as v, mapPObjectData as A, mapValueInVOE as L, isPColumnSpec as k, mapPTableDef as H, getAxisId as P, matchAxisId as J } from "@milaboratories/pl-model-common";
5
5
  export * from "@milaboratories/pl-model-common";
6
- class H extends Error {
6
+ class G extends Error {
7
7
  constructor(t, n) {
8
8
  super(`${t.length}${n ? "+" : ""} errors, first error: ` + t[0]), this.errors = t, this.moreErrors = n;
9
9
  }
10
10
  }
11
- function J(e) {
12
- if (!e.ok) throw new H(e.errors, e.moreErrors);
11
+ function N(e) {
12
+ if (!e.ok) throw new G(e.errors, e.moreErrors);
13
13
  return e.value;
14
14
  }
15
- function q(e) {
15
+ function X(e) {
16
16
  return new Proxy(e, {
17
17
  get(t, n) {
18
- return J(t[n]);
18
+ return N(t[n]);
19
19
  }
20
20
  });
21
21
  }
22
22
  function o(e) {
23
23
  return typeof e == "string" || typeof e == "number" || typeof e == "boolean" || e === null ? f(e) : e;
24
24
  }
25
- function p(e) {
25
+ function h(e) {
26
26
  return { type: "GetFromCtx", variable: e };
27
27
  }
28
- function Q(e) {
28
+ function Y(e) {
29
29
  return {
30
30
  type: "Isolate",
31
31
  cfg: e
32
32
  };
33
33
  }
34
- const X = p("$args"), Y = p("$it"), Z = p("$prod"), tt = p("$staging"), et = p("$ui");
34
+ const Z = h("$args"), tt = h("$it"), et = h("$prod"), nt = h("$staging"), rt = h("$ui");
35
35
  function f(e) {
36
36
  return { type: "Immediate", value: e };
37
37
  }
38
- function v(e) {
38
+ function S(e) {
39
39
  const t = {};
40
40
  for (const [n, r] of Object.entries(e)) t[n] = o(r);
41
41
  return {
@@ -43,7 +43,7 @@ function v(e) {
43
43
  template: t
44
44
  };
45
45
  }
46
- function nt(...e) {
46
+ function st(...e) {
47
47
  const t = [];
48
48
  for (const n of e) t.push(o(n));
49
49
  return {
@@ -58,7 +58,7 @@ function m(e, t) {
58
58
  field: o(t)
59
59
  };
60
60
  }
61
- function rt(e, t, n = "$it") {
61
+ function it(e, t, n = "$it") {
62
62
  return {
63
63
  type: "MapRecordValues",
64
64
  source: e,
@@ -66,7 +66,7 @@ function rt(e, t, n = "$it") {
66
66
  itVar: n
67
67
  };
68
68
  }
69
- function st(e, t, n = "$it") {
69
+ function ot(e, t, n = "$it") {
70
70
  return {
71
71
  type: "MapArrayValues",
72
72
  source: e,
@@ -74,46 +74,46 @@ function st(e, t, n = "$it") {
74
74
  itVar: n
75
75
  };
76
76
  }
77
- function it(e) {
77
+ function at(e) {
78
78
  return {
79
79
  type: "Flatten",
80
80
  source: e
81
81
  };
82
82
  }
83
- function ot(e) {
83
+ function ut(e) {
84
84
  return {
85
85
  type: "IsEmpty",
86
86
  arg: e
87
87
  };
88
88
  }
89
- function at(e) {
89
+ function lt(e) {
90
90
  return {
91
91
  type: "Not",
92
92
  operand: e
93
93
  };
94
94
  }
95
- function ut(e, t) {
95
+ function ct(e, t) {
96
96
  return {
97
97
  type: "And",
98
98
  operand1: e,
99
99
  operand2: t
100
100
  };
101
101
  }
102
- function lt(e, t) {
102
+ function gt(e, t) {
103
103
  return {
104
104
  type: "Or",
105
105
  operand1: e,
106
106
  operand2: t
107
107
  };
108
108
  }
109
- function ct(e, t) {
109
+ function dt(e, t) {
110
110
  return {
111
111
  type: "GetResourceField",
112
112
  source: o(e),
113
113
  field: o(t)
114
114
  };
115
115
  }
116
- function gt() {
116
+ function pt() {
117
117
  return function(e) {
118
118
  return {
119
119
  type: "GetResourceValueAsJson",
@@ -121,7 +121,7 @@ function gt() {
121
121
  };
122
122
  };
123
123
  }
124
- function dt(e, t, n = "$it") {
124
+ function ht(e, t, n = "$it") {
125
125
  return {
126
126
  type: "MapResourceFields",
127
127
  source: e,
@@ -129,19 +129,19 @@ function dt(e, t, n = "$it") {
129
129
  itVar: n
130
130
  };
131
131
  }
132
- function pt(e) {
132
+ function ft(e) {
133
133
  return {
134
134
  type: "GetBlobContent",
135
135
  source: o(e)
136
136
  };
137
137
  }
138
- function ht(e) {
138
+ function mt(e) {
139
139
  return {
140
140
  type: "GetBlobContentAsString",
141
141
  source: o(e)
142
142
  };
143
143
  }
144
- function ft() {
144
+ function yt() {
145
145
  return function(e) {
146
146
  return {
147
147
  type: "GetBlobContentAsJson",
@@ -149,54 +149,54 @@ function ft() {
149
149
  };
150
150
  };
151
151
  }
152
- function mt(e) {
152
+ function bt(e) {
153
153
  return {
154
154
  type: "GetDownloadedBlobContent",
155
155
  source: o(e)
156
156
  };
157
157
  }
158
- function yt(e) {
158
+ function wt(e) {
159
159
  return {
160
160
  type: "GetOnDemandBlobContent",
161
161
  source: o(e)
162
162
  };
163
163
  }
164
- function bt(e) {
164
+ function At(e) {
165
165
  return {
166
166
  type: "GetImportProgress",
167
167
  source: o(e)
168
168
  };
169
169
  }
170
- function wt(e, t) {
170
+ function Ct(e, t) {
171
171
  return {
172
172
  type: "GetLastLogs",
173
173
  source: o(e),
174
174
  lines: t
175
175
  };
176
176
  }
177
- function At(e, t) {
177
+ function _t(e, t) {
178
178
  return {
179
179
  type: "GetProgressLog",
180
180
  source: o(e),
181
181
  patternToSearch: t
182
182
  };
183
183
  }
184
- function Ct(e) {
184
+ function Pt(e) {
185
185
  return {
186
186
  type: "GetLogHandle",
187
187
  source: o(e)
188
188
  };
189
189
  }
190
- function G() {
190
+ function $() {
191
191
  return typeof globalThis.getPlatforma < "u" || typeof globalThis.platforma < "u";
192
192
  }
193
- function R(e) {
193
+ function x(e) {
194
194
  if (e && typeof globalThis.getPlatforma == "function")
195
195
  return globalThis.getPlatforma(e);
196
196
  if (typeof globalThis.platforma < "u") return globalThis.platforma;
197
197
  throw new Error("Can't get platforma instance.");
198
198
  }
199
- function N() {
199
+ function M() {
200
200
  if (typeof globalThis.cfgRenderCtx < "u") return globalThis.cfgRenderCtx;
201
201
  }
202
202
  function s() {
@@ -204,31 +204,31 @@ function s() {
204
204
  throw new Error("Not in config rendering context");
205
205
  }
206
206
  function y(e, t) {
207
- const n = N();
207
+ const n = M();
208
208
  if (n === void 0) return !1;
209
209
  if (e in n.callbackRegistry) throw new Error(`Callback with key ${e} already registered.`);
210
210
  return n.callbackRegistry[e] = t, !0;
211
211
  }
212
212
  const b = /* @__PURE__ */ new Map();
213
- function $(e, t) {
213
+ function K(e, t) {
214
214
  e in s().callbackRegistry || (s().callbackRegistry[e] = (n) => {
215
215
  for (const r of b.get(e))
216
216
  r(n);
217
217
  }, b.set(e, [])), b.get(e).push(t);
218
218
  }
219
- class a {
219
+ class l {
220
220
  constructor(t, n = (r) => r) {
221
- l(this, "isResolved", !1);
222
- l(this, "resolvedValue");
223
- this.handle = t, this.postProcess = n, $(t, (r) => {
221
+ c(this, "isResolved", !1);
222
+ c(this, "resolvedValue");
223
+ this.handle = t, this.postProcess = n, K(t, (r) => {
224
224
  this.resolvedValue = n(r), this.isResolved = !0;
225
225
  });
226
226
  }
227
227
  map(t) {
228
- return new a(this.handle, (n) => t(this.postProcess(n)));
228
+ return new l(this.handle, (n) => t(this.postProcess(n)));
229
229
  }
230
230
  mapDefined(t) {
231
- return new a(this.handle, (n) => {
231
+ return new l(this.handle, (n) => {
232
232
  const r = this.postProcess(n);
233
233
  return r ? t(r) : void 0;
234
234
  });
@@ -237,10 +237,10 @@ class a {
237
237
  return this.isResolved ? this.resolvedValue : { __awaited_futures__: [this.handle] };
238
238
  }
239
239
  }
240
- function P(e) {
241
- return e === void 0 ? void 0 : new d(e);
240
+ function F(e) {
241
+ return e === void 0 ? void 0 : new p(e);
242
242
  }
243
- class d {
243
+ class p {
244
244
  constructor(t) {
245
245
  this.handle = t;
246
246
  }
@@ -248,7 +248,7 @@ class d {
248
248
  return this.resolveWithCommon({}, ...t);
249
249
  }
250
250
  resolveWithCommon(t, ...n) {
251
- return P(s().resolveWithCommon(this.handle, t, ...n));
251
+ return F(s().resolveWithCommon(this.handle, t, ...n));
252
252
  }
253
253
  get resourceType() {
254
254
  return s().getResourceType(this.handle);
@@ -266,7 +266,7 @@ class d {
266
266
  return s().getIsFinal(this.handle);
267
267
  }
268
268
  getError() {
269
- return P(s().getError(this.handle));
269
+ return F(s().getError(this.handle));
270
270
  }
271
271
  listInputFields() {
272
272
  return s().listInputFields(this.handle);
@@ -304,9 +304,9 @@ class d {
304
304
  */
305
305
  getPColumns(t = !1, n = "") {
306
306
  const r = this.parsePObjectCollection(t, n);
307
- return r === void 0 ? void 0 : Object.entries(r).map(([, u]) => {
308
- if (!D(u)) throw new Error(`not a PColumn (kind = ${u.spec.kind})`);
309
- return u;
307
+ return r === void 0 ? void 0 : Object.entries(r).map(([, a]) => {
308
+ if (!v(a)) throw new Error(`not a PColumn (kind = ${a.spec.kind})`);
309
+ return a;
310
310
  });
311
311
  }
312
312
  /**
@@ -320,18 +320,18 @@ class d {
320
320
  );
321
321
  if (r === void 0) return;
322
322
  const i = {};
323
- for (const [u, h] of Object.entries(r))
324
- i[u] = A(h, (g) => new d(g));
323
+ for (const [a, d] of Object.entries(r))
324
+ i[a] = A(d, (u) => new p(u));
325
325
  return i;
326
326
  }
327
327
  getFileContentAsBase64() {
328
- return new a(s().getBlobContentAsBase64(this.handle));
328
+ return new l(s().getBlobContentAsBase64(this.handle));
329
329
  }
330
330
  getFileContentAsString() {
331
- return new a(s().getBlobContentAsString(this.handle));
331
+ return new l(s().getBlobContentAsString(this.handle));
332
332
  }
333
333
  getFileContentAsJson() {
334
- return new a(
334
+ return new l(
335
335
  s().getBlobContentAsString(this.handle)
336
336
  ).mapDefined((t) => JSON.parse(t));
337
337
  }
@@ -351,7 +351,7 @@ class d {
351
351
  * @returns downloaded file handle
352
352
  */
353
353
  getFileHandle() {
354
- return new a(s().getDownloadedBlobContentHandle(this.handle));
354
+ return new l(s().getDownloadedBlobContentHandle(this.handle));
355
355
  }
356
356
  /**
357
357
  * @deprecated use getFileHandle
@@ -363,7 +363,7 @@ class d {
363
363
  * @returns downloaded file handle
364
364
  */
365
365
  getRemoteFileHandle() {
366
- return new a(s().getOnDemandBlobContentHandle(this.handle));
366
+ return new l(s().getOnDemandBlobContentHandle(this.handle));
367
367
  }
368
368
  /**
369
369
  * @deprecated use getRemoteFileHandle
@@ -372,47 +372,47 @@ class d {
372
372
  return this.getRemoteFileHandle();
373
373
  }
374
374
  getImportProgress() {
375
- return new a(s().getImportProgress(this.handle));
375
+ return new l(s().getImportProgress(this.handle));
376
376
  }
377
377
  getLastLogs(t) {
378
- return new a(s().getLastLogs(this.handle, t));
378
+ return new l(s().getLastLogs(this.handle, t));
379
379
  }
380
380
  getProgressLog(t) {
381
- return new a(s().getProgressLog(this.handle, t));
381
+ return new l(s().getProgressLog(this.handle, t));
382
382
  }
383
383
  getLogHandle() {
384
- return new a(s().getLogHandle(this.handle));
384
+ return new l(s().getLogHandle(this.handle));
385
385
  }
386
386
  }
387
- const V = "staging", I = "main";
388
- function S(e) {
387
+ const R = "staging", V = "main";
388
+ function I(e) {
389
389
  return typeof e == "object" && e !== null && "__awaited_futures__" in e;
390
390
  }
391
391
  function C(e, t, n) {
392
392
  if (t.has(n)) return;
393
393
  if (t.add(n), typeof n === "object")
394
- if (S(n)) n.__awaited_futures__.forEach((i) => e.add(i));
394
+ if (I(n)) n.__awaited_futures__.forEach((i) => e.add(i));
395
395
  else if (Array.isArray(n))
396
396
  for (const i of n) C(e, t, i);
397
397
  else
398
398
  for (const [, i] of Object.entries(n))
399
399
  i !== n && C(e, t, i);
400
400
  }
401
- function M(e) {
401
+ function W(e) {
402
402
  const t = /* @__PURE__ */ new Set();
403
403
  return C(t, /* @__PURE__ */ new Set(), e), t;
404
404
  }
405
- const _t = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
405
+ const Ft = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
406
406
  __proto__: null,
407
- MainAccessorName: I,
408
- StagingAccessorName: V,
409
- getAllFutureAwaits: M,
410
- isFutureAwait: S
407
+ MainAccessorName: V,
408
+ StagingAccessorName: R,
409
+ getAllFutureAwaits: W,
410
+ isFutureAwait: I
411
411
  }, Symbol.toStringTag, { value: "Module" }));
412
- class K {
412
+ class U {
413
413
  constructor() {
414
- l(this, "ctx", s());
415
- l(this, "defaultLabelFn", (t, n) => {
414
+ c(this, "ctx", s());
415
+ c(this, "defaultLabelFn", (t, n) => {
416
416
  var r;
417
417
  return ((r = t.annotations) == null ? void 0 : r["pl7.app/label"]) ?? "Unlabelled";
418
418
  });
@@ -443,7 +443,7 @@ class K {
443
443
  ref: n.ref,
444
444
  obj: {
445
445
  ...n.obj,
446
- data: new d(n.obj.data)
446
+ data: new p(n.obj.data)
447
447
  }
448
448
  }))
449
449
  };
@@ -462,7 +462,7 @@ class K {
462
462
  ref: n.ref,
463
463
  obj: {
464
464
  ...n.obj,
465
- data: L(n.obj.data, (r) => new d(r))
465
+ data: L(n.obj.data, (r) => new p(r))
466
466
  }
467
467
  }))
468
468
  };
@@ -482,7 +482,9 @@ class K {
482
482
  */
483
483
  getDataByRef(t) {
484
484
  var n;
485
- return (n = this.getData().entries.find((r) => r.ref.blockId === t.blockId && r.ref.name === t.name)) == null ? void 0 : n.obj;
485
+ return (n = this.getData().entries.find(
486
+ (r) => r.ref.blockId === t.blockId && r.ref.name === t.name
487
+ )) == null ? void 0 : n.obj;
486
488
  }
487
489
  /**
488
490
  * @param ref a Ref
@@ -490,23 +492,53 @@ class K {
490
492
  */
491
493
  getSpecByRef(t) {
492
494
  var n;
493
- return (n = this.getSpecs().entries.find((r) => r.ref.blockId === t.blockId && r.ref.name === t.name)) == null ? void 0 : n.obj;
495
+ return (n = this.getSpecs().entries.find(
496
+ (r) => r.ref.blockId === t.blockId && r.ref.name === t.name
497
+ )) == null ? void 0 : n.obj;
498
+ }
499
+ /**
500
+ * @param spec object specification
501
+ * @returns array of data objects with compatible specs
502
+ */
503
+ findDataWithCompatibleSpec(t) {
504
+ const n = [];
505
+ t: for (const r of this.getData().entries) {
506
+ if (!k(r.obj.spec))
507
+ continue;
508
+ const i = r.obj.spec;
509
+ if (t.name === i.name && t.valueType === i.valueType && t.axesSpec.length === i.axesSpec.length && D(t.domain, i.domain)) {
510
+ for (let a = 0; a < t.axesSpec.length; ++a) {
511
+ const d = t.axesSpec[a], u = i.axesSpec[a];
512
+ if (d.name !== u.name || d.type !== u.type || !D(d.domain, u.domain))
513
+ continue t;
514
+ }
515
+ n.push(r.obj);
516
+ }
517
+ }
518
+ return n;
494
519
  }
495
520
  }
521
+ function D(e, t) {
522
+ if (e === void 0) return t === void 0;
523
+ if (t === void 0) return !0;
524
+ for (const n in t)
525
+ if (e[n] !== t[n]) return !1;
526
+ return !0;
527
+ }
496
528
  class w {
497
529
  constructor() {
498
- l(this, "ctx");
499
- l(this, "args");
500
- l(this, "uiState");
501
- l(this, "resultPool", new K());
530
+ c(this, "ctx");
531
+ c(this, "args");
532
+ c(this, "uiState");
533
+ c(this, "resultPool", new U());
502
534
  this.ctx = s(), this.args = JSON.parse(this.ctx.args), this.uiState = this.ctx.uiState !== void 0 ? JSON.parse(this.ctx.uiState) : void 0;
503
535
  }
504
536
  getNamedAccessor(t) {
505
537
  const n = this.ctx.getAccessorHandleByName(t);
506
- return n ? new d(n) : void 0;
538
+ return n ? new p(n) : void 0;
507
539
  }
508
540
  get prerun() {
509
- return this.getNamedAccessor(V);
541
+ return this.getNamedAccessor(R);
510
542
  }
511
543
  /**
512
544
  * @deprecated use prerun
@@ -521,7 +553,7 @@ class w {
521
553
  return this.precalc;
522
554
  }
523
555
  get outputs() {
524
- return this.getNamedAccessor(I);
556
+ return this.getNamedAccessor(V);
525
557
  }
526
558
  /**
527
559
  * @deprecated use outputs
@@ -541,17 +573,17 @@ class w {
541
573
  },
542
574
  filters: t.filters ?? [],
543
575
  sorting: t.sorting ?? []
544
- } : n = t, this.ctx.createPTable(j(n, (r) => A(r, (i) => i.handle)));
576
+ } : n = t, this.ctx.createPTable(H(n, (r) => A(r, (i) => i.handle)));
545
577
  }
546
578
  getBlockLabel(t) {
547
579
  return this.ctx.getBlockLabel(t);
548
580
  }
549
581
  }
550
- const x = "1.7.53";
551
- function Ft(e) {
582
+ const O = "1.8.19";
583
+ function Dt(e) {
552
584
  return typeof e == "string";
553
585
  }
554
- function Pt(e) {
586
+ function vt(e) {
555
587
  if (e.inputsValid !== void 0) return e;
556
588
  {
557
589
  if (e.canRun === void 0)
@@ -560,13 +592,13 @@ function Pt(e) {
560
592
  return delete t.canRun, t;
561
593
  }
562
594
  }
563
- class c {
564
- constructor(t, n, r, i, u) {
565
- this._renderingMode = t, this._initialArgs = n, this._outputs = r, this._inputsValid = i, this._sections = u;
595
+ class g {
596
+ constructor(t, n, r, i, a) {
597
+ this._renderingMode = t, this._initialArgs = n, this._outputs = r, this._inputsValid = i, this._sections = a;
566
598
  }
567
599
  /** Initiates configuration builder */
568
600
  static create(t = "Heavy") {
569
- return new c(
601
+ return new g(
570
602
  t,
571
603
  void 0,
572
604
  {},
@@ -577,7 +609,7 @@ class c {
577
609
  output(t, n) {
578
610
  if (typeof n == "function") {
579
611
  const r = `output#${t}`;
580
- return y(r, () => n(new w())), new c(
612
+ return y(r, () => n(new w())), new g(
581
613
  this._renderingMode,
582
614
  this._initialArgs,
583
615
  {
@@ -588,7 +620,7 @@ class c {
588
620
  this._sections
589
621
  );
590
622
  } else
591
- return new c(
623
+ return new g(
592
624
  this._renderingMode,
593
625
  this._initialArgs,
594
626
  {
@@ -604,13 +636,13 @@ class c {
604
636
  return this.inputsValid(t);
605
637
  }
606
638
  argsValid(t) {
607
- return typeof t == "function" ? (y("inputsValid", () => t(new w())), new c(
639
+ return typeof t == "function" ? (y("inputsValid", () => t(new w())), new g(
608
640
  this._renderingMode,
609
641
  this._initialArgs,
610
642
  this._outputs,
611
643
  "inputsValid",
612
644
  this._sections
613
- )) : new c(
645
+ )) : new g(
614
646
  this._renderingMode,
615
647
  this._initialArgs,
616
648
  this._outputs,
@@ -622,13 +654,13 @@ class c {
622
654
  return this.argsValid(t);
623
655
  }
624
656
  sections(t) {
625
- return Array.isArray(t) ? this.sections(f(t)) : typeof t == "function" ? (y("sections", () => t(new w())), new c(
657
+ return Array.isArray(t) ? this.sections(f(t)) : typeof t == "function" ? (y("sections", () => t(new w())), new g(
626
658
  this._renderingMode,
627
659
  this._initialArgs,
628
660
  this._outputs,
629
661
  this._inputsValid,
630
662
  "sections"
631
- )) : new c(
663
+ )) : new g(
632
664
  this._renderingMode,
633
665
  this._initialArgs,
634
666
  this._outputs,
@@ -638,7 +670,7 @@ class c {
638
670
  }
639
671
  /** Sets initial args for the block, this value must be specified. */
640
672
  initialArgs(t) {
641
- return new c(
673
+ return new g(
642
674
  this._renderingMode,
643
675
  t,
644
676
  this._outputs,
@@ -652,32 +684,32 @@ class c {
652
684
  done() {
653
685
  if (this._initialArgs === void 0) throw new Error("Initial arguments not set.");
654
686
  const t = {
655
- sdkVersion: x,
687
+ sdkVersion: O,
656
688
  renderingMode: this._renderingMode,
657
689
  initialArgs: this._initialArgs,
658
690
  inputsValid: this._inputsValid,
659
691
  sections: this._sections,
660
692
  outputs: this._outputs
661
693
  };
662
- return G() ? R(t) : { config: t };
694
+ return $() ? x(t) : { config: t };
663
695
  }
664
696
  }
665
- function Dt(e, t, n) {
666
- var u, h;
667
- const r = e.resultPool.getData().entries.map((g) => g.obj).filter(D).filter((g) => g.spec.name === "pl7.app/label" && g.spec.axesSpec.length === 1), i = [];
668
- for (const g of t)
669
- for (const O of g.spec.axesSpec) {
670
- const T = F(O);
697
+ function St(e, t, n) {
698
+ var a, d;
699
+ const r = e.resultPool.getData().entries.map((u) => u.obj).filter(v).filter((u) => u.spec.name === "pl7.app/label" && u.spec.axesSpec.length === 1), i = [];
700
+ for (const u of t)
701
+ for (const T of u.spec.axesSpec) {
702
+ const B = P(T);
671
703
  for (const _ of r)
672
- k(T, F(_.spec.axesSpec[0])) && i.push(_);
704
+ J(B, P(_.spec.axesSpec[0])) && i.push(_);
673
705
  }
674
706
  return e.createPTable({
675
707
  columns: [...t, ...i],
676
- filters: (u = n == null ? void 0 : n.pTableParams) == null ? void 0 : u.filters,
677
- sorting: (h = n == null ? void 0 : n.pTableParams) == null ? void 0 : h.sorting
708
+ filters: (a = n == null ? void 0 : n.pTableParams) == null ? void 0 : a.filters,
709
+ sorting: (d = n == null ? void 0 : n.pTableParams) == null ? void 0 : d.sorting
678
710
  });
679
711
  }
680
- class vt {
712
+ class xt {
681
713
  constructor(t) {
682
714
  this.handle = t;
683
715
  }
@@ -697,77 +729,77 @@ class vt {
697
729
  return await platforma.pFrameDriver.getUniqueValues(this.handle, t);
698
730
  }
699
731
  }
700
- function W(e) {
701
- return v({
732
+ function z(e) {
733
+ return S({
702
734
  __isRef: !0,
703
735
  blockId: m(e, "blockId"),
704
736
  name: m(e, "name")
705
737
  });
706
738
  }
707
739
  function Rt(e) {
708
- return v({
709
- ref: W(m(e, "ref")),
740
+ return S({
741
+ ref: z(m(e, "ref")),
710
742
  label: m(e, "label")
711
743
  });
712
744
  }
713
745
  const Vt = {
714
- sdkVersion: x
746
+ sdkVersion: O
715
747
  };
716
748
  function It() {
717
- return R();
749
+ return x();
718
750
  }
719
- function St(e) {
751
+ function Ot(e) {
720
752
  if (typeof globalThis.getEnvironmentValue == "function")
721
753
  return globalThis.getEnvironmentValue(e);
722
754
  }
723
755
  export {
724
- X as Args,
725
- c as BlockModel,
756
+ Z as Args,
757
+ g as BlockModel,
726
758
  Vt as CurrentSdkInfo,
727
- a as FutureRef,
728
- Y as It,
729
- _t as JsRenderInternal,
730
- Z as MainOutputs,
731
- H as OutputError,
732
- vt as PFrameImpl,
759
+ l as FutureRef,
760
+ tt as It,
761
+ Ft as JsRenderInternal,
762
+ et as MainOutputs,
763
+ G as OutputError,
764
+ xt as PFrameImpl,
733
765
  w as RenderCtx,
734
- K as ResultPool,
735
- tt as StagingOutputs,
736
- d as TreeNodeAccessor,
737
- et as UiState,
738
- ut as and,
739
- Dt as createPlDataTable,
740
- it as flatten,
766
+ U as ResultPool,
767
+ nt as StagingOutputs,
768
+ p as TreeNodeAccessor,
769
+ rt as UiState,
770
+ ct as and,
771
+ St as createPlDataTable,
772
+ at as flatten,
741
773
  Rt as fromPlOption,
742
- W as fromPlRef,
743
- pt as getBlobContent,
744
- ft as getBlobContentAsJson,
745
- ht as getBlobContentAsString,
746
- mt as getDownloadedBlobContent,
747
- St as getEnvironmentValue,
748
- p as getFromCfg,
774
+ z as fromPlRef,
775
+ ft as getBlobContent,
776
+ yt as getBlobContentAsJson,
777
+ mt as getBlobContentAsString,
778
+ bt as getDownloadedBlobContent,
779
+ Ot as getEnvironmentValue,
780
+ h as getFromCfg,
749
781
  f as getImmediate,
750
- bt as getImportProgress,
782
+ At as getImportProgress,
751
783
  m as getJsonField,
752
- wt as getLastLogs,
753
- Ct as getLogHandle,
754
- yt as getOnDemandBlobContent,
755
- At as getProgressLog,
784
+ Ct as getLastLogs,
785
+ Pt as getLogHandle,
786
+ wt as getOnDemandBlobContent,
787
+ _t as getProgressLog,
756
788
  It as getRawPlatformaInstance,
757
- ct as getResourceField,
758
- gt as getResourceValueAsJson,
759
- ot as isEmpty,
760
- Ft as isFunctionHandle,
761
- Q as isolate,
762
- nt as makeArray,
763
- v as makeObject,
764
- st as mapArrayValues,
765
- rt as mapRecordValues,
766
- dt as mapResourceFields,
767
- Pt as normalizeBlockConfig,
768
- at as not,
769
- lt as or,
770
- J as readOutput,
771
- q as wrapOutputs
789
+ dt as getResourceField,
790
+ pt as getResourceValueAsJson,
791
+ ut as isEmpty,
792
+ Dt as isFunctionHandle,
793
+ Y as isolate,
794
+ st as makeArray,
795
+ S as makeObject,
796
+ ot as mapArrayValues,
797
+ it as mapRecordValues,
798
+ ht as mapResourceFields,
799
+ vt as normalizeBlockConfig,
800
+ lt as not,
801
+ gt as or,
802
+ N as readOutput,
803
+ X as wrapOutputs
772
804
  };
773
805
  //# sourceMappingURL=index.mjs.map