@milaboratories/milaboratories.ui-examples.model 1.1.56 → 1.1.57

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/bundle.js CHANGED
@@ -35,7 +35,7 @@
35
35
  }, "");
36
36
  return `{${values}}`;
37
37
  };
38
- const Le = /* @__PURE__ */ getDefaultExportFromCjs(canonicalize);
38
+ const De = /* @__PURE__ */ getDefaultExportFromCjs(canonicalize);
39
39
  var util;
40
40
  (function(util2) {
41
41
  util2.assertEqual = (val) => val;
@@ -87,7 +87,7 @@
87
87
  return array.map((val) => typeof val === "string" ? `'${val}'` : val).join(separator);
88
88
  }
89
89
  util2.joinValues = joinValues;
90
- util2.jsonStringifyReplacer = (_2, value) => {
90
+ util2.jsonStringifyReplacer = (_, value) => {
91
91
  if (typeof value === "bigint") {
92
92
  return value.toString();
93
93
  }
@@ -3105,29 +3105,29 @@
3105
3105
  const params = { errorMap: ctx.common.contextualErrorMap };
3106
3106
  const fn = ctx.data;
3107
3107
  if (this._def.returns instanceof ZodPromise) {
3108
- const me = this;
3108
+ const me2 = this;
3109
3109
  return OK(async function(...args) {
3110
3110
  const error = new ZodError([]);
3111
- const parsedArgs = await me._def.args.parseAsync(args, params).catch((e) => {
3111
+ const parsedArgs = await me2._def.args.parseAsync(args, params).catch((e) => {
3112
3112
  error.addIssue(makeArgsIssue(args, e));
3113
3113
  throw error;
3114
3114
  });
3115
3115
  const result = await Reflect.apply(fn, this, parsedArgs);
3116
- const parsedReturns = await me._def.returns._def.type.parseAsync(result, params).catch((e) => {
3116
+ const parsedReturns = await me2._def.returns._def.type.parseAsync(result, params).catch((e) => {
3117
3117
  error.addIssue(makeReturnsIssue(result, e));
3118
3118
  throw error;
3119
3119
  });
3120
3120
  return parsedReturns;
3121
3121
  });
3122
3122
  } else {
3123
- const me = this;
3123
+ const me2 = this;
3124
3124
  return OK(function(...args) {
3125
- const parsedArgs = me._def.args.safeParse(args, params);
3125
+ const parsedArgs = me2._def.args.safeParse(args, params);
3126
3126
  if (!parsedArgs.success) {
3127
3127
  throw new ZodError([makeArgsIssue(args, parsedArgs.error)]);
3128
3128
  }
3129
3129
  const result = Reflect.apply(fn, this, parsedArgs.data);
3130
- const parsedReturns = me._def.returns.safeParse(result, params);
3130
+ const parsedReturns = me2._def.returns.safeParse(result, params);
3131
3131
  if (!parsedReturns.success) {
3132
3132
  throw new ZodError([makeReturnsIssue(result, parsedReturns.error)]);
3133
3133
  }
@@ -3999,7 +3999,7 @@
3999
3999
  }
4000
4000
  }
4001
4001
  }
4002
- function F(n2) {
4002
+ function F$1(n2) {
4003
4003
  if (!n2 || typeof n2 != "object")
4004
4004
  return false;
4005
4005
  const e = n2;
@@ -4017,7 +4017,7 @@
4017
4017
  }
4018
4018
  }
4019
4019
  function yn(n2) {
4020
- return F(n2) ? n2.type === "JsonPartitioned" || n2.type === "BinaryPartitioned" : false;
4020
+ return F$1(n2) ? n2.type === "JsonPartitioned" || n2.type === "BinaryPartitioned" : false;
4021
4021
  }
4022
4022
  function hn(n2) {
4023
4023
  switch (n2.type) {
@@ -4095,7 +4095,7 @@
4095
4095
  return n2.map(p$1);
4096
4096
  }
4097
4097
  function Jn(n2) {
4098
- return Le(p$1(n2));
4098
+ return De(p$1(n2));
4099
4099
  }
4100
4100
  function z$1(n2, e) {
4101
4101
  if (n2 === void 0) return e === void 0;
@@ -4143,10 +4143,10 @@
4143
4143
  }
4144
4144
  }
4145
4145
  function G$1(n2) {
4146
- return Le(n2);
4146
+ return De(n2);
4147
4147
  }
4148
4148
  function x(n2) {
4149
- return Le(p$1(n2));
4149
+ return De(p$1(n2));
4150
4150
  }
4151
4151
  function A(n2, e) {
4152
4152
  return JSON.stringify([n2, e]);
@@ -4304,11 +4304,11 @@
4304
4304
  function Y(n2) {
4305
4305
  return typeof n2 == "object" && "anchor" in n2;
4306
4306
  }
4307
- function f(n2) {
4307
+ function f$1(n2) {
4308
4308
  return n2.kind === "PColumn";
4309
4309
  }
4310
4310
  function Z(n2) {
4311
- return f(n2.spec);
4311
+ return f$1(n2.spec);
4312
4312
  }
4313
4313
  function jn(n2) {
4314
4314
  if (!Z(n2)) throw new Error(`not a PColumn (kind = ${n2.spec.kind})`);
@@ -4363,7 +4363,7 @@
4363
4363
  }
4364
4364
  return true;
4365
4365
  }
4366
- function N$1(n2, e) {
4366
+ function N(n2, e) {
4367
4367
  if (e.name !== void 0 && n2.name !== e.name || e.namePattern !== void 0 && !new RegExp(e.namePattern).test(n2.name))
4368
4368
  return false;
4369
4369
  if (e.type !== void 0) {
@@ -4410,14 +4410,14 @@
4410
4410
  return true;
4411
4411
  }
4412
4412
  function Kn(n2) {
4413
- return Array.isArray(n2) ? (e) => n2.some((t) => f(e) && N$1(e, t)) : (e) => f(e) && N$1(e, n2);
4413
+ return Array.isArray(n2) ? (e) => n2.some((t) => f$1(e) && N(e, t)) : (e) => f$1(e) && N(e, n2);
4414
4414
  }
4415
4415
  function Rn(n2) {
4416
4416
  const e = {
4417
4417
  kind: n2.kind,
4418
4418
  name: n2.name
4419
4419
  };
4420
- return n2.domain !== void 0 && (e.domain = n2.domain), f(n2) && (e.axesSpec = C(n2.axesSpec)), Le(e);
4420
+ return n2.domain !== void 0 && (e.domain = n2.domain), f$1(n2) && (e.axesSpec = C(n2.axesSpec)), De(e);
4421
4421
  }
4422
4422
  z$2.object({
4423
4423
  __isRef: z$2.literal(true).describe("Crucial marker for the block dependency tree reconstruction"),
@@ -4498,54 +4498,54 @@
4498
4498
  cause: z$2.lazy(() => n).optional(),
4499
4499
  errors: z$2.lazy(() => n.array()).optional()
4500
4500
  });
4501
- var We = Object.defineProperty;
4502
- var Ge = (t, e, n2) => e in t ? We(t, e, { enumerable: true, configurable: true, writable: true, value: n2 }) : t[e] = n2;
4503
- var T = (t, e, n2) => Ge(t, typeof e != "symbol" ? e + "" : e, n2);
4504
- function ee(t) {
4501
+ var ze = Object.defineProperty;
4502
+ var Ye = (t, e, n2) => e in t ? ze(t, e, { enumerable: true, configurable: true, writable: true, value: n2 }) : t[e] = n2;
4503
+ var F = (t, e, n2) => Ye(t, typeof e != "symbol" ? e + "" : e, n2);
4504
+ function ne(t) {
4505
4505
  return { type: "Immediate", value: t };
4506
4506
  }
4507
- function at() {
4507
+ function ct() {
4508
4508
  return typeof globalThis.getPlatforma < "u" || typeof globalThis.platforma < "u";
4509
4509
  }
4510
- function Ee(t) {
4510
+ function Oe(t) {
4511
4511
  if (t && typeof globalThis.getPlatforma == "function")
4512
4512
  return globalThis.getPlatforma(t);
4513
4513
  if (typeof globalThis.platforma < "u") return globalThis.platforma;
4514
4514
  throw new Error("Can't get platforma instance.");
4515
4515
  }
4516
- function lt() {
4516
+ function dt() {
4517
4517
  if (typeof globalThis.cfgRenderCtx < "u") return globalThis.cfgRenderCtx;
4518
4518
  }
4519
- function y() {
4519
+ function f() {
4520
4520
  if (typeof globalThis.cfgRenderCtx < "u") return globalThis.cfgRenderCtx;
4521
4521
  throw new Error("Not in config rendering context");
4522
4522
  }
4523
- function M(t, e) {
4524
- const n2 = lt();
4523
+ function G(t, e) {
4524
+ const n2 = dt();
4525
4525
  if (n2 === void 0) return false;
4526
4526
  if (t in n2.callbackRegistry) throw new Error(`Callback with key ${t} already registered.`);
4527
4527
  return n2.callbackRegistry[t] = e, true;
4528
4528
  }
4529
- const ae = /* @__PURE__ */ new Map();
4530
- function ut(t, e) {
4531
- t in y().callbackRegistry || (y().callbackRegistry[t] = (n2) => {
4532
- for (const r of ae.get(t))
4529
+ const ue = /* @__PURE__ */ new Map();
4530
+ function pt(t, e) {
4531
+ t in f().callbackRegistry || (f().callbackRegistry[t] = (n2) => {
4532
+ for (const r of ue.get(t))
4533
4533
  r(n2);
4534
- }, ae.set(t, [])), ae.get(t).push(e);
4534
+ }, ue.set(t, [])), ue.get(t).push(e);
4535
4535
  }
4536
- class _ {
4536
+ class I {
4537
4537
  constructor(e, n2 = (r) => r) {
4538
- T(this, "isResolved", false);
4539
- T(this, "resolvedValue");
4540
- this.handle = e, this.postProcess = n2, ut(e, (r) => {
4538
+ F(this, "isResolved", false);
4539
+ F(this, "resolvedValue");
4540
+ this.handle = e, this.postProcess = n2, pt(e, (r) => {
4541
4541
  this.resolvedValue = n2(r), this.isResolved = true;
4542
4542
  });
4543
4543
  }
4544
4544
  map(e) {
4545
- return new _(this.handle, (n2) => e(this.postProcess(n2)));
4545
+ return new I(this.handle, (n2) => e(this.postProcess(n2)));
4546
4546
  }
4547
4547
  mapDefined(e) {
4548
- return new _(this.handle, (n2) => {
4548
+ return new I(this.handle, (n2) => {
4549
4549
  const r = this.postProcess(n2);
4550
4550
  return r ? e(r) : void 0;
4551
4551
  });
@@ -4557,7 +4557,7 @@
4557
4557
  function pe(t, e) {
4558
4558
  return t === void 0 ? void 0 : e(t);
4559
4559
  }
4560
- class L {
4560
+ class E {
4561
4561
  constructor(e, n2) {
4562
4562
  this.handle = e, this.resolvePath = n2;
4563
4563
  }
@@ -4597,46 +4597,46 @@
4597
4597
  ...n2.map((i) => typeof i == "string" ? i : i.field)
4598
4598
  ];
4599
4599
  return pe(
4600
- y().resolveWithCommon(this.handle, e, ...n2),
4601
- (i) => new L(i, r)
4600
+ f().resolveWithCommon(this.handle, e, ...n2),
4601
+ (i) => new E(i, r)
4602
4602
  );
4603
4603
  }
4604
4604
  get resourceType() {
4605
- return y().getResourceType(this.handle);
4605
+ return f().getResourceType(this.handle);
4606
4606
  }
4607
4607
  getInputsLocked() {
4608
- return y().getInputsLocked(this.handle);
4608
+ return f().getInputsLocked(this.handle);
4609
4609
  }
4610
4610
  getOutputsLocked() {
4611
- return y().getOutputsLocked(this.handle);
4611
+ return f().getOutputsLocked(this.handle);
4612
4612
  }
4613
4613
  getIsReadyOrError() {
4614
- return y().getIsReadyOrError(this.handle);
4614
+ return f().getIsReadyOrError(this.handle);
4615
4615
  }
4616
4616
  getIsFinal() {
4617
- return y().getIsFinal(this.handle);
4617
+ return f().getIsFinal(this.handle);
4618
4618
  }
4619
4619
  getError() {
4620
4620
  const e = [...this.resolvePath, "error"];
4621
4621
  return pe(
4622
- y().getError(this.handle),
4623
- (n2) => new L(n2, e)
4622
+ f().getError(this.handle),
4623
+ (n2) => new E(n2, e)
4624
4624
  );
4625
4625
  }
4626
4626
  listInputFields() {
4627
- return y().listInputFields(this.handle);
4627
+ return f().listInputFields(this.handle);
4628
4628
  }
4629
4629
  listOutputFields() {
4630
- return y().listOutputFields(this.handle);
4630
+ return f().listOutputFields(this.handle);
4631
4631
  }
4632
4632
  listDynamicFields() {
4633
- return y().listDynamicFields(this.handle);
4633
+ return f().listDynamicFields(this.handle);
4634
4634
  }
4635
4635
  getKeyValueBase64(e) {
4636
- return y().getKeyValueBase64(this.handle, e);
4636
+ return f().getKeyValueBase64(this.handle, e);
4637
4637
  }
4638
4638
  getKeyValueAsString(e) {
4639
- return y().getKeyValueAsString(this.handle, e);
4639
+ return f().getKeyValueAsString(this.handle, e);
4640
4640
  }
4641
4641
  getKeyValueAsJson(e) {
4642
4642
  const n2 = this.getKeyValueAsString(e);
@@ -4644,10 +4644,10 @@
4644
4644
  return JSON.parse(n2);
4645
4645
  }
4646
4646
  getDataBase64() {
4647
- return y().getDataBase64(this.handle);
4647
+ return f().getDataBase64(this.handle);
4648
4648
  }
4649
4649
  getDataAsString() {
4650
- return y().getDataAsString(this.handle);
4650
+ return f().getDataAsString(this.handle);
4651
4651
  }
4652
4652
  getDataAsJson() {
4653
4653
  const e = this.getDataAsString();
@@ -4668,7 +4668,7 @@
4668
4668
  *
4669
4669
  */
4670
4670
  parsePObjectCollection(e = false, n2 = "") {
4671
- const r = y().parsePObjectCollection(
4671
+ const r = f().parsePObjectCollection(
4672
4672
  this.handle,
4673
4673
  e,
4674
4674
  n2,
@@ -4678,19 +4678,19 @@
4678
4678
  const i = {};
4679
4679
  for (const [s2, o] of Object.entries(r)) {
4680
4680
  const a = [...this.resolvePath, s2];
4681
- i[s2] = Fn(o, (l2) => new L(l2, a));
4681
+ i[s2] = Fn(o, (l2) => new E(l2, a));
4682
4682
  }
4683
4683
  return i;
4684
4684
  }
4685
4685
  getFileContentAsBase64() {
4686
- return new _(y().getBlobContentAsBase64(this.handle));
4686
+ return new I(f().getBlobContentAsBase64(this.handle));
4687
4687
  }
4688
4688
  getFileContentAsString() {
4689
- return new _(y().getBlobContentAsString(this.handle));
4689
+ return new I(f().getBlobContentAsString(this.handle));
4690
4690
  }
4691
4691
  getFileContentAsJson() {
4692
- return new _(
4693
- y().getBlobContentAsString(this.handle)
4692
+ return new I(
4693
+ f().getBlobContentAsString(this.handle)
4694
4694
  ).mapDefined((e) => JSON.parse(e));
4695
4695
  }
4696
4696
  /**
@@ -4709,7 +4709,7 @@
4709
4709
  * @returns downloaded file handle
4710
4710
  */
4711
4711
  getFileHandle() {
4712
- return new _(y().getDownloadedBlobContentHandle(this.handle));
4712
+ return new I(f().getDownloadedBlobContentHandle(this.handle));
4713
4713
  }
4714
4714
  /**
4715
4715
  * @deprecated use getFileHandle
@@ -4721,7 +4721,7 @@
4721
4721
  * @returns downloaded file handle
4722
4722
  */
4723
4723
  getRemoteFileHandle() {
4724
- return new _(y().getOnDemandBlobContentHandle(this.handle));
4724
+ return new I(f().getOnDemandBlobContentHandle(this.handle));
4725
4725
  }
4726
4726
  /**
4727
4727
  * @deprecated use getRemoteFileHandle
@@ -4733,22 +4733,22 @@
4733
4733
  * @returns the url to the extracted folder
4734
4734
  */
4735
4735
  extractArchiveAndGetURL(e) {
4736
- return new _(y().extractArchiveAndGetURL(this.handle, e));
4736
+ return new I(f().extractArchiveAndGetURL(this.handle, e));
4737
4737
  }
4738
4738
  getImportProgress() {
4739
- return new _(y().getImportProgress(this.handle));
4739
+ return new I(f().getImportProgress(this.handle));
4740
4740
  }
4741
4741
  getLastLogs(e) {
4742
- return new _(y().getLastLogs(this.handle, e));
4742
+ return new I(f().getLastLogs(this.handle, e));
4743
4743
  }
4744
4744
  getProgressLog(e) {
4745
- return new _(y().getProgressLog(this.handle, e));
4745
+ return new I(f().getProgressLog(this.handle, e));
4746
4746
  }
4747
4747
  getProgressLogWithInfo(e) {
4748
- return new _(y().getProgressLogWithInfo(this.handle, e));
4748
+ return new I(f().getProgressLogWithInfo(this.handle, e));
4749
4749
  }
4750
4750
  getLogHandle() {
4751
- return new _(y().getLogHandle(this.handle));
4751
+ return new I(f().getLogHandle(this.handle));
4752
4752
  }
4753
4753
  allFieldsResolved(e = "Input") {
4754
4754
  switch (e) {
@@ -4774,135 +4774,135 @@
4774
4774
  let l2 = (r === "Input" ? this.listInputFields() : r === "Output" ? this.listOutputFields() : this.listDynamicFields()).map(
4775
4775
  (u2) => [u2, this.resolve({ field: u2, assertFieldType: r })]
4776
4776
  );
4777
- return s2 && (l2 = l2.filter((u2) => u2[1] !== void 0)), l2.map(([u2, d]) => o(u2, d));
4777
+ return s2 && (l2 = l2.filter((u2) => u2[1] !== void 0)), l2.map(([u2, p2]) => o(u2, p2));
4778
4778
  }
4779
4779
  }
4780
- const Fe = "staging", Oe = "main";
4781
- const dt = "pl7.app/label", ft = "pl7.app/trace", ht = z$2.object({
4780
+ const Re = "staging", ke = "main";
4781
+ const gt = "pl7.app/label", mt = "pl7.app/trace", yt = z$2.object({
4782
4782
  type: z$2.string(),
4783
4783
  importance: z$2.number().optional(),
4784
4784
  id: z$2.string().optional(),
4785
4785
  label: z$2.string()
4786
- }), gt = z$2.array(ht), mt = 1e-3, yt = "__LABEL__", xe = "__LABEL__@1";
4787
- function Re(t, e, n2 = {}) {
4788
- const r = /* @__PURE__ */ new Map(), i = /* @__PURE__ */ new Map(), s2 = t.map((h2) => {
4789
- var O, U;
4790
- const c2 = e(h2);
4791
- let m2, b, A2;
4792
- "spec" in c2 && typeof c2.spec == "object" ? (m2 = c2.spec, b = c2.prefixTrace, A2 = c2.suffixTrace) : m2 = c2;
4793
- const p2 = (O = m2.annotations) == null ? void 0 : O[dt], g = (U = m2.annotations) == null ? void 0 : U[ft], w2 = (g ? gt.safeParse(JSON.parse(g)).data : void 0) ?? [], f2 = [
4794
- ...b ?? [],
4795
- ...w2,
4796
- ...A2 ?? []
4786
+ }), vt = z$2.array(yt), bt = 1e-3, wt = "__LABEL__", Ce = "__LABEL__@1";
4787
+ function Ve(t, e, n2 = {}) {
4788
+ const r = /* @__PURE__ */ new Map(), i = n2.forceTraceElements !== void 0 && n2.forceTraceElements.length > 0 ? new Set(n2.forceTraceElements) : void 0, s2 = /* @__PURE__ */ new Map(), o = t.map((g) => {
4789
+ var S, R;
4790
+ const m2 = e(g);
4791
+ let c2, y, d;
4792
+ "spec" in m2 && typeof m2.spec == "object" ? (c2 = m2.spec, y = m2.prefixTrace, d = m2.suffixTrace) : c2 = m2;
4793
+ const b = (S = c2.annotations) == null ? void 0 : S[gt], A2 = (R = c2.annotations) == null ? void 0 : R[mt], v = (A2 ? vt.safeParse(JSON.parse(A2)).data : void 0) ?? [], P = [
4794
+ ...y ?? [],
4795
+ ...v,
4796
+ ...d ?? []
4797
4797
  ];
4798
- if (p2 !== void 0) {
4799
- const F2 = { label: p2, type: yt, importance: -2 };
4800
- n2.addLabelAsSuffix ? f2.push(F2) : f2.splice(0, 0, F2);
4801
- }
4802
- const C2 = [], P = /* @__PURE__ */ new Map();
4803
- for (let F2 = f2.length - 1; F2 >= 0; --F2) {
4804
- const { type: D2 } = f2[F2], Y2 = f2[F2].importance ?? 0, V = (P.get(D2) ?? 0) + 1;
4805
- P.set(D2, V);
4806
- const R = `${D2}@${V}`;
4807
- i.set(R, (i.get(R) ?? 0) + 1), r.set(
4808
- R,
4798
+ if (b !== void 0) {
4799
+ const D2 = { label: b, type: wt, importance: -2 };
4800
+ n2.addLabelAsSuffix ? P.push(D2) : P.splice(0, 0, D2);
4801
+ }
4802
+ const x2 = [], T = /* @__PURE__ */ new Map();
4803
+ for (let D2 = P.length - 1; D2 >= 0; --D2) {
4804
+ const { type: M } = P[D2], j = P[D2].importance ?? 0, $2 = (T.get(M) ?? 0) + 1;
4805
+ T.set(M, $2);
4806
+ const k2 = `${M}@${$2}`;
4807
+ s2.set(k2, (s2.get(k2) ?? 0) + 1), r.set(
4808
+ k2,
4809
4809
  Math.max(
4810
- r.get(R) ?? Number.NEGATIVE_INFINITY,
4811
- Y2 - (f2.length - F2) * mt
4810
+ r.get(k2) ?? Number.NEGATIVE_INFINITY,
4811
+ j - (P.length - D2) * bt
4812
4812
  )
4813
- ), C2.push({ ...f2[F2], fullType: R, occurrenceIndex: V });
4813
+ ), x2.push({ ...P[D2], fullType: k2, occurrenceIndex: $2 });
4814
4814
  }
4815
- return C2.reverse(), {
4816
- value: h2,
4817
- spec: m2,
4818
- label: p2,
4819
- fullTrace: C2
4815
+ return x2.reverse(), {
4816
+ value: g,
4817
+ spec: c2,
4818
+ label: b,
4819
+ fullTrace: x2
4820
4820
  };
4821
- }), o = [], a = [], l2 = [...r];
4822
- l2.sort(([, h2], [, c2]) => c2 - h2);
4823
- for (const [h2] of l2)
4824
- h2.endsWith("@1") || i.get(h2) === t.length ? o.push(h2) : a.push(h2);
4825
- const u2 = (h2, c2 = false) => {
4826
- const m2 = [];
4827
- for (let b = 0; b < s2.length; b++) {
4828
- const A2 = s2[b], p2 = A2.fullTrace.filter((f2) => h2.has(f2.fullType));
4829
- if (p2.length === 0)
4830
- if (c2)
4831
- m2.push({
4821
+ }), a = [], l2 = [], u2 = [...r];
4822
+ u2.sort(([, g], [, m2]) => m2 - g);
4823
+ for (const [g] of u2)
4824
+ g.endsWith("@1") || s2.get(g) === t.length ? a.push(g) : l2.push(g);
4825
+ const p2 = (g, m2 = false) => {
4826
+ const c2 = [];
4827
+ for (let y = 0; y < o.length; y++) {
4828
+ const d = o[y], b = d.fullTrace.filter((P) => g.has(P.fullType) || i && i.has(P.type));
4829
+ if (b.length === 0)
4830
+ if (m2)
4831
+ c2.push({
4832
4832
  label: "Unlabeled",
4833
- value: A2.value
4833
+ value: d.value
4834
4834
  });
4835
4835
  else return;
4836
- const g = p2.map((f2) => f2.label), w2 = n2.separator ?? " / ";
4837
- m2.push({
4838
- label: g.join(w2),
4839
- value: A2.value
4836
+ const A2 = b.map((P) => P.label), v = n2.separator ?? " / ";
4837
+ c2.push({
4838
+ label: A2.join(v),
4839
+ value: d.value
4840
4840
  });
4841
4841
  }
4842
- return m2;
4842
+ return c2;
4843
4843
  };
4844
- if (o.length === 0) {
4845
- if (a.length !== 0) throw new Error("Non-empty secondary types list while main types list is empty.");
4846
- return u2(new Set(xe), true);
4847
- }
4848
- let d = 0, v = -1;
4849
- for (; d < o.length; ) {
4850
- const h2 = /* @__PURE__ */ new Set();
4851
- n2.includeNativeLabel && h2.add(xe);
4852
- for (let m2 = 0; m2 < d; ++m2) h2.add(o[m2]);
4853
- v >= 0 && h2.add(o[v]);
4854
- const c2 = u2(h2);
4855
- if (c2 !== void 0 && new Set(c2.map((m2) => m2.label)).size === t.length) return c2;
4856
- v++, v >= o.length && (d++, v = d);
4857
- }
4858
- return u2(/* @__PURE__ */ new Set([...o, ...a]), true);
4859
- }
4860
- const z = "PColumnData/", re = z + "ResourceMap", ie = z + "Partitioned/ResourceMap", W = z + "JsonPartitioned", N = z + "BinaryPartitioned", ke = z + "Partitioned/", se = ke + "JsonPartitioned", G = ke + "BinaryPartitioned";
4861
- const fe = (t) => {
4844
+ if (a.length === 0) {
4845
+ if (l2.length !== 0) throw new Error("Non-empty secondary types list while main types list is empty.");
4846
+ return p2(new Set(Ce), true);
4847
+ }
4848
+ let h2 = 0, w2 = -1;
4849
+ for (; h2 < a.length; ) {
4850
+ const g = /* @__PURE__ */ new Set();
4851
+ n2.includeNativeLabel && g.add(Ce);
4852
+ for (let c2 = 0; c2 < h2; ++c2) g.add(a[c2]);
4853
+ w2 >= 0 && g.add(a[w2]);
4854
+ const m2 = p2(g);
4855
+ if (m2 !== void 0 && new Set(m2.map((c2) => c2.label)).size === t.length) return m2;
4856
+ w2++, w2 >= a.length && (h2++, w2 = h2);
4857
+ }
4858
+ return p2(/* @__PURE__ */ new Set([...a, ...l2]), true);
4859
+ }
4860
+ const Q = "PColumnData/", se = Q + "ResourceMap", oe = Q + "Partitioned/ResourceMap", H = Q + "JsonPartitioned", B = Q + "BinaryPartitioned", Ke = Q + "Partitioned/", ae = Ke + "JsonPartitioned", q = Ke + "BinaryPartitioned";
4861
+ const he = (t) => {
4862
4862
  if (t.endsWith(".index"))
4863
4863
  return { baseKey: t.substring(0, t.length - 6), type: "index" };
4864
4864
  if (t.endsWith(".values"))
4865
4865
  return { baseKey: t.substring(0, t.length - 7), type: "values" };
4866
4866
  throw new Error(`key must ends on .index/.values for binary p-column, got: ${t}`);
4867
4867
  };
4868
- function vt(t) {
4868
+ function At(t) {
4869
4869
  if (!t) return;
4870
4870
  const e = t.resourceType.name, n2 = t.getDataAsJson(), r = [];
4871
4871
  let i = 0;
4872
4872
  switch (e) {
4873
- case re:
4873
+ case se:
4874
4874
  i = n2.keyLength;
4875
4875
  break;
4876
- case ie:
4876
+ case oe:
4877
4877
  i = n2.partitionKeyLength + n2.keyLength;
4878
4878
  break;
4879
- case W:
4880
- case N:
4879
+ case H:
4880
+ case B:
4881
4881
  i = n2.partitionKeyLength;
4882
4882
  break;
4883
- case G:
4884
- case se:
4883
+ case q:
4884
+ case ae:
4885
4885
  i = n2.superPartitionKeyLength + n2.partitionKeyLength;
4886
4886
  break;
4887
4887
  }
4888
4888
  switch (e) {
4889
- case re:
4890
- case W:
4891
- case N:
4889
+ case se:
4890
+ case H:
4891
+ case B:
4892
4892
  for (let s2 of t.listInputFields()) {
4893
- e === N && (s2 = fe(s2).baseKey);
4893
+ e === B && (s2 = he(s2).baseKey);
4894
4894
  const o = [...JSON.parse(s2)];
4895
4895
  r.push(o);
4896
4896
  }
4897
4897
  break;
4898
- case ie:
4899
- case G:
4900
- case se:
4898
+ case oe:
4899
+ case q:
4900
+ case ae:
4901
4901
  for (const s2 of t.listInputFields()) {
4902
4902
  const o = [...JSON.parse(s2)], a = t.resolve({ field: s2, assertFieldType: "Input" });
4903
4903
  if (a !== void 0)
4904
4904
  for (let l2 of a.listInputFields()) {
4905
- e === G && (l2 = fe(l2).baseKey);
4905
+ e === q && (l2 = he(l2).baseKey);
4906
4906
  const u2 = [...o, ...JSON.parse(l2)];
4907
4907
  r.push(u2);
4908
4908
  }
@@ -4911,7 +4911,7 @@
4911
4911
  }
4912
4912
  return { data: r, keyLength: i };
4913
4913
  }
4914
- function bt(t) {
4914
+ function xt(t) {
4915
4915
  if (t.type !== "JsonPartitioned" && t.type !== "BinaryPartitioned")
4916
4916
  throw new Error(`Splitting requires Partitioned DataInfoEntries, got ${t.type}`);
4917
4917
  const { parts: e, partitionKeyLength: n2 } = t, r = [];
@@ -4930,11 +4930,11 @@
4930
4930
  }
4931
4931
  return r.map((i) => Array.from(i.values()));
4932
4932
  }
4933
- function wt(t) {
4933
+ function Pt(t) {
4934
4934
  if (t === void 0) return;
4935
- if (F(t))
4936
- return bt(t);
4937
- const e = vt(t);
4935
+ if (F$1(t))
4936
+ return xt(t);
4937
+ const e = At(t);
4938
4938
  if (!e) return;
4939
4939
  const { data: n2, keyLength: r } = e, i = [];
4940
4940
  for (let s2 = 0; s2 < r; ++s2)
@@ -4947,16 +4947,16 @@
4947
4947
  }
4948
4948
  return i.map((s2) => Array.from(s2.values()));
4949
4949
  }
4950
- function he(t, e = []) {
4950
+ function ge(t, e = []) {
4951
4951
  if (t === void 0 || !t.getIsReadyOrError()) return;
4952
4952
  const n2 = t.resourceType.name, r = t.getDataAsJson();
4953
- if (e.length > 0 && (n2 === se || n2 === G))
4953
+ if (e.length > 0 && (n2 === ae || n2 === q))
4954
4954
  throw new Error(`Unexpected nested super-partitioned resource: ${n2}`);
4955
4955
  switch (n2) {
4956
- case re:
4957
- case ie:
4956
+ case se:
4957
+ case oe:
4958
4958
  throw new Error(`Only data columns are supported, got: ${n2}`);
4959
- case W: {
4959
+ case H: {
4960
4960
  if (typeof (r == null ? void 0 : r.partitionKeyLength) != "number")
4961
4961
  throw new Error(`Missing partitionKeyLength in metadata for ${n2}`);
4962
4962
  const i = [];
@@ -4972,12 +4972,12 @@
4972
4972
  parts: i
4973
4973
  };
4974
4974
  }
4975
- case N: {
4975
+ case B: {
4976
4976
  if (typeof (r == null ? void 0 : r.partitionKeyLength) != "number")
4977
4977
  throw new Error(`Missing partitionKeyLength in metadata for ${n2}`);
4978
4978
  const i = [], s2 = /* @__PURE__ */ new Map();
4979
4979
  for (const o of t.listInputFields()) {
4980
- const a = fe(o), l2 = t.resolve({ field: o, assertFieldType: "Input" });
4980
+ const a = he(o), l2 = t.resolve({ field: o, assertFieldType: "Input" });
4981
4981
  if (l2 === void 0) return;
4982
4982
  let u2 = s2.get(a.baseKey);
4983
4983
  u2 || (u2 = {}, s2.set(a.baseKey, u2)), a.type === "index" ? u2.index = l2 : u2.values = l2;
@@ -4999,16 +4999,16 @@
4999
4999
  parts: i
5000
5000
  };
5001
5001
  }
5002
- case se: {
5002
+ case ae: {
5003
5003
  if (typeof (r == null ? void 0 : r.superPartitionKeyLength) != "number" || typeof (r == null ? void 0 : r.partitionKeyLength) != "number")
5004
5004
  throw new Error(`Missing superPartitionKeyLength or partitionKeyLength in metadata for ${n2}`);
5005
5005
  const i = r.superPartitionKeyLength + r.partitionKeyLength, s2 = [];
5006
5006
  for (const o of t.listInputFields()) {
5007
5007
  const a = t.resolve({ field: o, assertFieldType: "Input" });
5008
5008
  if (a === void 0) return;
5009
- if (a.resourceType.name !== W)
5010
- throw new Error(`Expected ${W} inside ${n2}, but got ${a.resourceType.name}`);
5011
- const l2 = he(a, JSON.parse(o));
5009
+ if (a.resourceType.name !== H)
5010
+ throw new Error(`Expected ${H} inside ${n2}, but got ${a.resourceType.name}`);
5011
+ const l2 = ge(a, JSON.parse(o));
5012
5012
  if (l2 === void 0) return;
5013
5013
  if (l2.type !== "JsonPartitioned")
5014
5014
  throw new Error(`Unexpected inner result type for ${n2}: ${l2.type}`);
@@ -5020,16 +5020,16 @@
5020
5020
  parts: s2
5021
5021
  };
5022
5022
  }
5023
- case G: {
5023
+ case q: {
5024
5024
  if (typeof (r == null ? void 0 : r.superPartitionKeyLength) != "number" || typeof (r == null ? void 0 : r.partitionKeyLength) != "number")
5025
5025
  throw new Error(`Missing superPartitionKeyLength or partitionKeyLength in metadata for ${n2}`);
5026
5026
  const i = r.superPartitionKeyLength + r.partitionKeyLength, s2 = [];
5027
5027
  for (const o of t.listInputFields()) {
5028
5028
  const a = t.resolve({ field: o, assertFieldType: "Input" });
5029
5029
  if (a === void 0) return;
5030
- if (a.resourceType.name !== N)
5031
- throw new Error(`Expected ${N} inside ${n2}, but got ${a.resourceType.name}`);
5032
- const l2 = he(a, JSON.parse(o));
5030
+ if (a.resourceType.name !== B)
5031
+ throw new Error(`Expected ${B} inside ${n2}, but got ${a.resourceType.name}`);
5032
+ const l2 = ge(a, JSON.parse(o));
5033
5033
  if (l2 === void 0) return;
5034
5034
  if (l2.type !== "BinaryPartitioned")
5035
5035
  throw new Error(`Unexpected inner result type for ${n2}: ${l2.type}`);
@@ -5045,15 +5045,15 @@
5045
5045
  throw new Error(`Unknown resource type: ${n2}`);
5046
5046
  }
5047
5047
  }
5048
- function At(t) {
5048
+ function Ct(t) {
5049
5049
  if (t !== void 0) {
5050
- if (F(t)) return t;
5050
+ if (F$1(t)) return t;
5051
5051
  if (pn(t)) return hn(t);
5052
- if (t instanceof L) return he(t);
5052
+ if (t instanceof E) return ge(t);
5053
5053
  throw new Error(`Unexpected input type: ${typeof t}`);
5054
5054
  }
5055
5055
  }
5056
- function xt(t, e) {
5056
+ function St(t, e) {
5057
5057
  const n2 = [...e].sort((s2, o) => o[0] - s2[0]);
5058
5058
  if (t.type === "JsonPartitioned" || t.type === "BinaryPartitioned") {
5059
5059
  const { partitionKeyLength: s2 } = t;
@@ -5113,7 +5113,7 @@
5113
5113
  }
5114
5114
  }
5115
5115
  }
5116
- class Pt {
5116
+ class _t {
5117
5117
  constructor(e) {
5118
5118
  this.columns = e;
5119
5119
  }
@@ -5122,7 +5122,7 @@
5122
5122
  return this.columns.filter((r) => n2(r.spec));
5123
5123
  }
5124
5124
  }
5125
- function Ct(t) {
5125
+ function It(t) {
5126
5126
  if (t)
5127
5127
  return t.map((e) => ({
5128
5128
  type: `split:${Jn(e.axisId)}`,
@@ -5131,21 +5131,21 @@
5131
5131
  // High importance for split filters in labels
5132
5132
  }));
5133
5133
  }
5134
- function St(t) {
5134
+ function Tt(t) {
5135
5135
  if (t)
5136
5136
  return t.map((e) => [e.axisIdx, e.value]);
5137
5137
  }
5138
- function _t(t, e) {
5138
+ function Lt(t, e) {
5139
5139
  if (!e || e.length === 0) return t;
5140
5140
  const n2 = [...e].sort((r, i) => r[0] - i[0]);
5141
- return Le({ id: t, axisFilters: n2 });
5141
+ return De({ id: t, axisFilters: n2 });
5142
5142
  }
5143
- function It(t) {
5143
+ function Se(t) {
5144
5144
  if (!t || typeof t != "object") return false;
5145
5145
  const e = t, n2 = e.domain && typeof e.domain == "object" && Object.values(e.domain).some((i) => typeof i == "object" && i !== null && "anchor" in i), r = e.axes && Array.isArray(e.axes) && e.axes.some((i) => typeof i == "object" && i !== null && "anchor" in i);
5146
5146
  return !!e.domainAnchor || n2 || r;
5147
5147
  }
5148
- function Lt(t) {
5148
+ function Et(t) {
5149
5149
  if (typeof t != "object" || !("axes" in t) || t.axes === void 0)
5150
5150
  return [];
5151
5151
  const e = t.axes.map((n2, r) => typeof n2 == "object" && "split" in n2 && n2.split === true ? r : -1).filter((n2) => n2 !== -1);
@@ -5153,11 +5153,11 @@
5153
5153
  throw new Error("Axis splitting is not supported when `partialAxesMatch` is defined.");
5154
5154
  return e.sort((n2, r) => n2 - r), e;
5155
5155
  }
5156
- class ge {
5156
+ class me {
5157
5157
  constructor() {
5158
- T(this, "defaultProviderStore", []);
5159
- T(this, "providers", [new Pt(this.defaultProviderStore)]);
5160
- T(this, "axisLabelProviders", []);
5158
+ F(this, "defaultProviderStore", []);
5159
+ F(this, "providers", [new _t(this.defaultProviderStore)]);
5160
+ F(this, "axisLabelProviders", []);
5161
5161
  }
5162
5162
  addColumnProvider(e) {
5163
5163
  return this.providers.push(e), this;
@@ -5179,119 +5179,133 @@
5179
5179
  }
5180
5180
  }
5181
5181
  getUniversalEntries(e, n2) {
5182
- const { anchorCtx: r, labelOps: i, dontWaitAllData: s2 = false, overrideLabelAnnotation: o = false } = n2 ?? {}, a = {
5182
+ const { anchorCtx: r, labelOps: i, dontWaitAllData: s2 = false, overrideLabelAnnotation: o = false, exclude: a } = n2 ?? {}, l2 = {
5183
5183
  ...o && (i == null ? void 0 : i.includeNativeLabel) !== false ? { includeNativeLabel: true } : {},
5184
5184
  ...i ?? {}
5185
- }, l2 = typeof e == "function" ? [e] : Array.isArray(e) ? e : [e], u2 = [], d = /* @__PURE__ */ new Set();
5186
- for (const c2 of l2) {
5187
- const m2 = It(c2);
5188
- let b;
5189
- if (m2) {
5185
+ };
5186
+ let u2 = () => false;
5187
+ if (a) {
5188
+ const c2 = (Array.isArray(a) ? a : [a]).map((y) => {
5189
+ if (Se(y)) {
5190
+ if (!r)
5191
+ throw new Error("Anchored selectors in exclude require an AnchoredIdDeriver to be provided in options.");
5192
+ return Kn(Dn(r.anchors, y, n2));
5193
+ } else
5194
+ return Kn(y);
5195
+ });
5196
+ u2 = (y) => c2.some((d) => d(y));
5197
+ }
5198
+ const p2 = typeof e == "function" ? [e] : Array.isArray(e) ? e : [e], h2 = [], w2 = /* @__PURE__ */ new Set();
5199
+ for (const c2 of p2) {
5200
+ const y = Se(c2);
5201
+ let d;
5202
+ if (y) {
5190
5203
  if (!r)
5191
5204
  throw new Error("Anchored selectors require an AnchoredIdDeriver to be provided in options.");
5192
- b = Dn(r.anchors, c2, n2);
5205
+ d = Dn(r.anchors, c2, n2);
5193
5206
  } else
5194
- b = c2;
5195
- const A2 = /* @__PURE__ */ new Set(), p2 = [];
5196
- for (const f2 of this.providers) {
5197
- const C2 = f2.selectColumns(b);
5198
- for (const P of C2) {
5199
- if (A2.has(P.id))
5200
- throw new Error(`Duplicate column id ${P.id} in provider ${f2.constructor.name}`);
5201
- const O = Rn(P.spec);
5202
- d.has(O) || (A2.add(P.id), d.add(O), p2.push(P));
5207
+ d = c2;
5208
+ const b = /* @__PURE__ */ new Set(), A2 = [];
5209
+ for (const x2 of this.providers) {
5210
+ const T = x2.selectColumns(d);
5211
+ for (const S of T) {
5212
+ if (u2(S.spec)) continue;
5213
+ if (b.has(S.id))
5214
+ throw new Error(`Duplicate column id ${S.id} in provider ${x2.constructor.name}`);
5215
+ const R = Rn(S.spec);
5216
+ w2.has(R) || (b.add(S.id), w2.add(R), A2.push(S));
5203
5217
  }
5204
5218
  }
5205
- if (p2.length === 0) continue;
5206
- const g = Lt(c2), w2 = g.length > 0;
5207
- for (const f$1 of p2) {
5208
- if (!f(f$1.spec)) continue;
5209
- const C2 = f$1.spec;
5210
- if (w2) {
5211
- const P = At(f$1.data);
5212
- if (!P) {
5219
+ if (A2.length === 0) continue;
5220
+ const v = Et(c2), P = v.length > 0;
5221
+ for (const x2 of A2) {
5222
+ if (!f$1(x2.spec)) continue;
5223
+ const T = x2.spec;
5224
+ if (P) {
5225
+ const S = Ct(x2.data);
5226
+ if (!S) {
5213
5227
  if (s2) continue;
5214
5228
  return;
5215
5229
  }
5216
- if (!yn(P))
5217
- throw new Error(`Splitting requires Partitioned DataInfoEntries, but parsing resulted in ${P.type} for column ${f$1.id}`);
5218
- const O = wt(P), U = g[g.length - 1];
5219
- if (U >= P.partitionKeyLength)
5220
- throw new Error(`Not enough partition keys (${P.partitionKeyLength}) for requested split axes (max index ${U}) in column ${C2.name}`);
5221
- const F2 = g.map((S) => this.findLabels(p$1(C2.axesSpec[S]))), D2 = [], Y2 = (S, B) => {
5222
- if (B >= g.length) {
5223
- if (D2.push([...S]), D2.length > 1e4)
5230
+ if (!yn(S))
5231
+ throw new Error(`Splitting requires Partitioned DataInfoEntries, but parsing resulted in ${S.type} for column ${x2.id}`);
5232
+ const R = Pt(S), D2 = v[v.length - 1];
5233
+ if (D2 >= S.partitionKeyLength)
5234
+ throw new Error(`Not enough partition keys (${S.partitionKeyLength}) for requested split axes (max index ${D2}) in column ${T.name}`);
5235
+ const M = v.map((_) => this.findLabels(p$1(T.axesSpec[_]))), j = [], $2 = (_, W) => {
5236
+ if (W >= v.length) {
5237
+ if (j.push([..._]), j.length > 1e4)
5224
5238
  throw new Error("Too many key combinations, aborting.");
5225
5239
  return;
5226
5240
  }
5227
- const k2 = g[B];
5228
- if (k2 >= O.length)
5229
- throw new Error(`Axis index ${k2} out of bounds for unique keys array (length ${O.length}) during split key generation for column ${f$1.id}`);
5230
- const K = O[k2];
5231
- if (!K || K.length === 0) {
5232
- D2.length = 0;
5241
+ const V = v[W];
5242
+ if (V >= R.length)
5243
+ throw new Error(`Axis index ${V} out of bounds for unique keys array (length ${R.length}) during split key generation for column ${x2.id}`);
5244
+ const J = R[V];
5245
+ if (!J || J.length === 0) {
5246
+ j.length = 0;
5233
5247
  return;
5234
5248
  }
5235
- for (const X2 of K)
5236
- S.push(X2), Y2(S, B + 1), S.pop();
5249
+ for (const Z2 of J)
5250
+ _.push(Z2), $2(_, W + 1), _.pop();
5237
5251
  };
5238
- if (Y2([], 0), D2.length === 0)
5252
+ if ($2([], 0), j.length === 0)
5239
5253
  continue;
5240
- const V = [...C2.axesSpec], R = g.map((S) => S);
5241
- for (let S = g.length - 1; S >= 0; S--)
5242
- V.splice(g[S], 1);
5243
- const Ue = { ...C2, axesSpec: V };
5244
- for (const S of D2) {
5245
- const B = S.map((k2, K) => {
5246
- const X2 = R[K], Be = p$1(C2.axesSpec[X2]), oe = F2[K], Me = (oe == null ? void 0 : oe[k2]) ?? String(k2);
5247
- return { axisIdx: X2, axisId: Be, value: k2, label: Me };
5254
+ const k2 = [...T.axesSpec], We = v.map((_) => _);
5255
+ for (let _ = v.length - 1; _ >= 0; _--)
5256
+ k2.splice(v[_], 1);
5257
+ const Ge = { ...T, axesSpec: k2 };
5258
+ for (const _ of j) {
5259
+ const W = _.map((V, J) => {
5260
+ const Z2 = We[J], He = p$1(T.axesSpec[Z2]), le = M[J], qe = (le == null ? void 0 : le[V]) ?? String(V);
5261
+ return { axisIdx: Z2, axisId: He, value: V, label: qe };
5248
5262
  });
5249
- u2.push({
5263
+ h2.push({
5250
5264
  type: "split",
5251
- originalColumn: f$1,
5252
- spec: C2,
5253
- adjustedSpec: Ue,
5254
- dataEntries: P,
5255
- axisFilters: B
5265
+ originalColumn: x2,
5266
+ spec: T,
5267
+ adjustedSpec: Ge,
5268
+ dataEntries: S,
5269
+ axisFilters: W
5256
5270
  });
5257
5271
  }
5258
5272
  } else
5259
- u2.push({
5273
+ h2.push({
5260
5274
  type: "direct",
5261
- originalColumn: f$1,
5262
- spec: C2,
5263
- adjustedSpec: C2
5275
+ originalColumn: x2,
5276
+ spec: T,
5277
+ adjustedSpec: T
5264
5278
  });
5265
5279
  }
5266
5280
  }
5267
- if (u2.length === 0) return [];
5268
- const v = Re(
5269
- u2,
5281
+ if (h2.length === 0) return [];
5282
+ const g = Ve(
5283
+ h2,
5270
5284
  (c2) => ({
5271
5285
  spec: c2.spec,
5272
- suffixTrace: c2.type === "split" ? Ct(c2.axisFilters) : void 0
5286
+ suffixTrace: c2.type === "split" ? It(c2.axisFilters) : void 0
5273
5287
  }),
5274
- a
5275
- ), h2 = [];
5276
- for (const { value: c2, label: m2 } of v) {
5277
- const { originalColumn: b, spec: A2 } = c2, p2 = c2.type === "split" ? c2.axisFilters : void 0, g = St(p2);
5278
- let w2;
5279
- r ? w2 = r.deriveS(A2, g) : w2 = _t(b.id, g);
5280
- let f2 = { ...c2.adjustedSpec };
5281
- o && (f2 = {
5282
- ...f2,
5288
+ l2
5289
+ ), m2 = [];
5290
+ for (const { value: c2, label: y } of g) {
5291
+ const { originalColumn: d, spec: b } = c2, A2 = c2.type === "split" ? c2.axisFilters : void 0, v = Tt(A2);
5292
+ let P;
5293
+ r ? P = r.deriveS(b, v) : P = Lt(d.id, v);
5294
+ let x2 = { ...c2.adjustedSpec };
5295
+ o && (x2 = {
5296
+ ...x2,
5283
5297
  annotations: {
5284
- ...f2.annotations ?? {},
5285
- "pl7.app/label": m2
5298
+ ...x2.annotations ?? {},
5299
+ "pl7.app/label": y
5286
5300
  }
5287
- }), h2.push({
5288
- id: w2,
5289
- spec: f2,
5290
- data: () => c2.type === "split" ? gn(xt(c2.dataEntries, g)) : c2.originalColumn.data,
5291
- label: m2
5301
+ }), m2.push({
5302
+ id: P,
5303
+ spec: x2,
5304
+ data: () => c2.type === "split" ? gn(St(c2.dataEntries, v)) : c2.originalColumn.data,
5305
+ label: y
5292
5306
  });
5293
5307
  }
5294
- return h2;
5308
+ return m2;
5295
5309
  }
5296
5310
  getColumns(e, n2) {
5297
5311
  const r = this.getUniversalEntries(e, {
@@ -5316,19 +5330,19 @@
5316
5330
  return i;
5317
5331
  }
5318
5332
  }
5319
- function le(t, e) {
5333
+ function ce(t, e) {
5320
5334
  if (t === void 0) return e === void 0;
5321
5335
  if (e === void 0) return true;
5322
5336
  for (const n2 in e)
5323
5337
  if (t[n2] !== e[n2]) return false;
5324
5338
  return true;
5325
5339
  }
5326
- function Pe(t) {
5327
- return Fn(t, (e) => e instanceof L ? e.handle : pn(e) ? ln(e, (n2) => n2.handle) : e);
5340
+ function _e(t) {
5341
+ return Fn(t, (e) => e instanceof E ? e.handle : pn(e) ? ln(e, (n2) => n2.handle) : e);
5328
5342
  }
5329
- class Tt {
5343
+ class Dt {
5330
5344
  constructor() {
5331
- T(this, "ctx", y());
5345
+ F(this, "ctx", f());
5332
5346
  }
5333
5347
  /**
5334
5348
  * @deprecated use getOptions()
@@ -5339,7 +5353,7 @@
5339
5353
  getOptions(e, n2) {
5340
5354
  const r = typeof e == "function" ? e : Kn(e), i = this.getSpecs().entries.filter((a) => r(a.obj));
5341
5355
  let s2 = {}, o = false;
5342
- return typeof n2 < "u" && (typeof n2 == "function" ? s2 = n2 : typeof n2 == "object" && ("includeNativeLabel" in n2 || "separator" in n2 || "addLabelAsSuffix" in n2 ? s2 = n2 : (n2 = n2, s2 = n2.label ?? {}, o = n2.refsWithEnrichments ?? false))), typeof s2 == "object" ? Re(i, (a) => a.obj, s2 ?? {}).map(({ value: { ref: a }, label: l2 }) => ({
5356
+ return typeof n2 < "u" && (typeof n2 == "function" ? s2 = n2 : typeof n2 == "object" && ("includeNativeLabel" in n2 || "separator" in n2 || "addLabelAsSuffix" in n2 ? s2 = n2 : (n2 = n2, s2 = n2.label ?? {}, o = n2.refsWithEnrichments ?? false))), typeof s2 == "object" ? Ve(i, (a) => a.obj, s2 ?? {}).map(({ value: { ref: a }, label: l2 }) => ({
5343
5357
  ref: Hn(a, o),
5344
5358
  label: l2
5345
5359
  })) : i.map(({ ref: a, obj: l2 }) => ({
@@ -5371,7 +5385,7 @@
5371
5385
  getAnchoredPColumns(e, n2, r) {
5372
5386
  const i = this.resolveAnchorCtx(e);
5373
5387
  if (i)
5374
- return new ge().addColumnProvider(this).addAxisLabelProvider(this).getColumns(n2, {
5388
+ return new me().addColumnProvider(this).addAxisLabelProvider(this).getColumns(n2, {
5375
5389
  ...r,
5376
5390
  anchorCtx: i
5377
5391
  });
@@ -5408,7 +5422,7 @@
5408
5422
  getCanonicalOptions(e, n2, r) {
5409
5423
  const i = this.resolveAnchorCtx(e);
5410
5424
  if (!i) return;
5411
- const s2 = new ge().addColumnProvider(this).addAxisLabelProvider(this).getUniversalEntries(n2, {
5425
+ const s2 = new me().addColumnProvider(this).addAxisLabelProvider(this).getUniversalEntries(n2, {
5412
5426
  ...r,
5413
5427
  anchorCtx: i
5414
5428
  });
@@ -5432,7 +5446,7 @@
5432
5446
  ref: n2.ref,
5433
5447
  obj: {
5434
5448
  ...n2.obj,
5435
- data: new L(n2.obj.data, [n2.ref.blockId, n2.ref.name])
5449
+ data: new E(n2.obj.data, [n2.ref.blockId, n2.ref.name])
5436
5450
  }
5437
5451
  }))
5438
5452
  };
@@ -5453,7 +5467,7 @@
5453
5467
  ...n2.obj,
5454
5468
  data: Wn(
5455
5469
  n2.obj.data,
5456
- (r) => new L(r, [n2.ref.blockId, n2.ref.name])
5470
+ (r) => new E(r, [n2.ref.blockId, n2.ref.name])
5457
5471
  )
5458
5472
  }
5459
5473
  }))
@@ -5482,7 +5496,7 @@
5482
5496
  if (n2)
5483
5497
  return Fn(
5484
5498
  n2,
5485
- (i) => new L(i, [e.blockId, e.name])
5499
+ (i) => new E(i, [e.blockId, e.name])
5486
5500
  );
5487
5501
  }
5488
5502
  /**
@@ -5503,7 +5517,7 @@
5503
5517
  getPColumnSpecByRef(e) {
5504
5518
  const n2 = this.getSpecByRef(e);
5505
5519
  if (n2) {
5506
- if (!f(n2)) throw new Error(`not a PColumn spec (kind = ${n2.kind})`);
5520
+ if (!f$1(n2)) throw new Error(`not a PColumn spec (kind = ${n2.kind})`);
5507
5521
  return n2;
5508
5522
  }
5509
5523
  }
@@ -5522,13 +5536,13 @@
5522
5536
  findDataWithCompatibleSpec(e) {
5523
5537
  const n2 = [];
5524
5538
  e: for (const r of this.getData().entries) {
5525
- if (!f(r.obj.spec))
5539
+ if (!f$1(r.obj.spec))
5526
5540
  continue;
5527
5541
  const i = r.obj.spec;
5528
- if (e.name === i.name && e.valueType === i.valueType && e.axesSpec.length === i.axesSpec.length && le(e.domain, i.domain)) {
5542
+ if (e.name === i.name && e.valueType === i.valueType && e.axesSpec.length === i.axesSpec.length && ce(e.domain, i.domain)) {
5529
5543
  for (let s2 = 0; s2 < e.axesSpec.length; ++s2) {
5530
5544
  const o = e.axesSpec[s2], a = i.axesSpec[s2];
5531
- if (o.name !== a.name || o.type !== a.type || !le(o.domain, a.domain))
5545
+ if (o.name !== a.name || o.type !== a.type || !ce(o.domain, a.domain))
5532
5546
  continue e;
5533
5547
  }
5534
5548
  n2.push(r.obj);
@@ -5545,7 +5559,7 @@
5545
5559
  for (const r of n2.entries) {
5546
5560
  if (!Z(r.obj)) continue;
5547
5561
  const i = r.obj.spec;
5548
- if (i.name === "pl7.app/label" && i.axesSpec.length === 1 && i.axesSpec[0].name === e.name && i.axesSpec[0].type === e.type && le(e.domain, i.axesSpec[0].domain)) {
5562
+ if (i.name === "pl7.app/label" && i.axesSpec.length === 1 && i.axesSpec[0].name === e.name && i.axesSpec[0].type === e.type && ce(e.domain, i.axesSpec[0].domain)) {
5549
5563
  if (r.obj.data.resourceType.name !== "PColumnData/Json")
5550
5564
  throw Error(`Expected JSON column for labels, got: ${r.obj.data.resourceType.name}`);
5551
5565
  return Object.fromEntries(
@@ -5565,12 +5579,12 @@
5565
5579
  */
5566
5580
  selectColumns(e) {
5567
5581
  const n2 = typeof e == "function" ? e : Kn(e);
5568
- return this.getSpecs().entries.filter(({ obj: i }) => f(i) ? n2(i) : false).map(({ ref: i, obj: s2 }) => {
5582
+ return this.getSpecs().entries.filter(({ obj: i }) => f$1(i) ? n2(i) : false).map(({ ref: i, obj: s2 }) => {
5569
5583
  const o = s2;
5570
5584
  let a = null;
5571
5585
  const l2 = this;
5572
5586
  return {
5573
- id: Le(i),
5587
+ id: De(i),
5574
5588
  spec: o,
5575
5589
  get data() {
5576
5590
  var u2;
@@ -5595,14 +5609,14 @@
5595
5609
  return r;
5596
5610
  }
5597
5611
  }
5598
- class Q {
5612
+ class ee {
5599
5613
  constructor() {
5600
- T(this, "ctx");
5601
- T(this, "args");
5602
- T(this, "uiState");
5603
- T(this, "_activeArgsCache");
5604
- T(this, "resultPool", new Tt());
5605
- this.ctx = y(), this.args = JSON.parse(this.ctx.args), this.uiState = this.ctx.uiState !== void 0 ? JSON.parse(this.ctx.uiState) : {};
5614
+ F(this, "ctx");
5615
+ F(this, "args");
5616
+ F(this, "uiState");
5617
+ F(this, "_activeArgsCache");
5618
+ F(this, "resultPool", new Dt());
5619
+ this.ctx = f(), this.args = JSON.parse(this.ctx.args), this.uiState = this.ctx.uiState !== void 0 ? JSON.parse(this.ctx.uiState) : {};
5606
5620
  }
5607
5621
  /**
5608
5622
  * Returns args snapshot the block was executed for (i.e. when "Run" button was pressed).
@@ -5620,14 +5634,14 @@
5620
5634
  getNamedAccessor(e) {
5621
5635
  return pe(
5622
5636
  this.ctx.getAccessorHandleByName(e),
5623
- (n2) => new L(n2, [e])
5637
+ (n2) => new E(n2, [e])
5624
5638
  );
5625
5639
  }
5626
5640
  get prerun() {
5627
- return this.getNamedAccessor(Fe);
5641
+ return this.getNamedAccessor(Re);
5628
5642
  }
5629
5643
  get outputs() {
5630
- return this.getNamedAccessor(Oe);
5644
+ return this.getNamedAccessor(ke);
5631
5645
  }
5632
5646
  /**
5633
5647
  * Find labels data for a given axis id. It will search for a label column and return its data as a map.
@@ -5639,13 +5653,13 @@
5639
5653
  }
5640
5654
  verifyInlineAndExplicitColumnsSupport(e) {
5641
5655
  var i;
5642
- const n2 = e.some((s2) => !(s2.data instanceof L) || pn(s2.data)), r = ((i = this.ctx.featureFlags) == null ? void 0 : i.inlineColumnsSupport) === true;
5656
+ const n2 = e.some((s2) => !(s2.data instanceof E) || pn(s2.data)), r = ((i = this.ctx.featureFlags) == null ? void 0 : i.inlineColumnsSupport) === true;
5643
5657
  if (n2 && !r) throw Error("Inline or explicit columns not supported");
5644
5658
  }
5645
5659
  // TODO remove all non-PColumn fields
5646
5660
  createPFrame(e) {
5647
5661
  return this.verifyInlineAndExplicitColumnsSupport(e), this.ctx.createPFrame(
5648
- e.map((n2) => Pe(n2))
5662
+ e.map((n2) => _e(n2))
5649
5663
  );
5650
5664
  }
5651
5665
  createPTable(e) {
@@ -5658,7 +5672,7 @@
5658
5672
  filters: e.filters ?? [],
5659
5673
  sorting: e.sorting ?? []
5660
5674
  } : n2 = e, this.verifyInlineAndExplicitColumnsSupport(Un(n2.src)), this.ctx.createPTable(
5661
- On(n2, (r) => Pe(r))
5675
+ On(n2, (r) => _e(r))
5662
5676
  );
5663
5677
  }
5664
5678
  /** @deprecated scheduled for removal from SDK */
@@ -5669,26 +5683,26 @@
5669
5683
  return this.ctx.getCurrentUnstableMarker();
5670
5684
  }
5671
5685
  }
5672
- const H = "1.30.24";
5673
- function Et(t) {
5686
+ const z = "1.30.26";
5687
+ function Ft(t) {
5674
5688
  return t.__renderLambda === true;
5675
5689
  }
5676
- function ue(t) {
5690
+ function de(t) {
5677
5691
  if (t !== void 0)
5678
- return Et(t) ? t.handle : t;
5692
+ return Ft(t) ? t.handle : t;
5679
5693
  }
5680
- class I {
5694
+ class L {
5681
5695
  constructor(e, n2, r, i, s2, o, a, l2) {
5682
5696
  this._renderingMode = e, this._initialArgs = n2, this._initialUiState = r, this._outputs = i, this._inputsValid = s2, this._sections = o, this._title = a, this._enrichmentTargets = l2;
5683
5697
  }
5684
5698
  static create(e = "Heavy") {
5685
- return new I(
5699
+ return new L(
5686
5700
  e,
5687
5701
  void 0,
5688
5702
  {},
5689
5703
  {},
5690
- ee(true),
5691
- ee([]),
5704
+ ne(true),
5705
+ ne([]),
5692
5706
  void 0,
5693
5707
  void 0
5694
5708
  );
@@ -5696,7 +5710,7 @@
5696
5710
  output(e, n2, r = {}) {
5697
5711
  if (typeof n2 == "function") {
5698
5712
  const i = `output#${e}`;
5699
- return M(i, () => n2(new Q())), new I(
5713
+ return G(i, () => n2(new ee())), new L(
5700
5714
  this._renderingMode,
5701
5715
  this._initialArgs,
5702
5716
  this._initialUiState,
@@ -5714,7 +5728,7 @@
5714
5728
  this._enrichmentTargets
5715
5729
  );
5716
5730
  } else
5717
- return new I(
5731
+ return new L(
5718
5732
  this._renderingMode,
5719
5733
  this._initialArgs,
5720
5734
  this._initialUiState,
@@ -5733,7 +5747,7 @@
5733
5747
  return this.output(e, n2, { retentive: true });
5734
5748
  }
5735
5749
  argsValid(e) {
5736
- return typeof e == "function" ? (M("inputsValid", () => e(new Q())), new I(
5750
+ return typeof e == "function" ? (G("inputsValid", () => e(new ee())), new L(
5737
5751
  this._renderingMode,
5738
5752
  this._initialArgs,
5739
5753
  this._initialUiState,
@@ -5745,7 +5759,7 @@
5745
5759
  this._sections,
5746
5760
  this._title,
5747
5761
  this._enrichmentTargets
5748
- )) : new I(
5762
+ )) : new L(
5749
5763
  this._renderingMode,
5750
5764
  this._initialArgs,
5751
5765
  this._initialUiState,
@@ -5757,7 +5771,7 @@
5757
5771
  );
5758
5772
  }
5759
5773
  sections(e) {
5760
- return Array.isArray(e) ? this.sections(ee(e)) : typeof e == "function" ? (M("sections", () => e(new Q())), new I(
5774
+ return Array.isArray(e) ? this.sections(ne(e)) : typeof e == "function" ? (G("sections", () => e(new ee())), new L(
5761
5775
  this._renderingMode,
5762
5776
  this._initialArgs,
5763
5777
  this._initialUiState,
@@ -5766,7 +5780,7 @@
5766
5780
  { __renderLambda: true, handle: "sections" },
5767
5781
  this._title,
5768
5782
  this._enrichmentTargets
5769
- )) : new I(
5783
+ )) : new L(
5770
5784
  this._renderingMode,
5771
5785
  this._initialArgs,
5772
5786
  this._initialUiState,
@@ -5779,7 +5793,7 @@
5779
5793
  }
5780
5794
  /** Sets a rendering function to derive block title, shown for the block in the left blocks-overview panel. */
5781
5795
  title(e) {
5782
- return M("title", () => e(new Q())), new I(
5796
+ return G("title", () => e(new ee())), new L(
5783
5797
  this._renderingMode,
5784
5798
  this._initialArgs,
5785
5799
  this._initialUiState,
@@ -5795,7 +5809,7 @@
5795
5809
  * @deprecated use {@link withArgs}
5796
5810
  * */
5797
5811
  initialArgs(e) {
5798
- return new I(
5812
+ return new L(
5799
5813
  this._renderingMode,
5800
5814
  e,
5801
5815
  this._initialUiState,
@@ -5808,7 +5822,7 @@
5808
5822
  }
5809
5823
  /** Sets initial args for the block, this value must be specified. */
5810
5824
  withArgs(e) {
5811
- return new I(
5825
+ return new L(
5812
5826
  this._renderingMode,
5813
5827
  e,
5814
5828
  this._initialUiState,
@@ -5821,7 +5835,7 @@
5821
5835
  }
5822
5836
  /** Defines type and sets initial value for block UiState. */
5823
5837
  withUiState(e) {
5824
- return new I(
5838
+ return new L(
5825
5839
  this._renderingMode,
5826
5840
  this._initialArgs,
5827
5841
  e,
@@ -5837,7 +5851,7 @@
5837
5851
  * Influences dependency graph construction.
5838
5852
  */
5839
5853
  enriches(e) {
5840
- return M("enrichmentTargets", e), new I(
5854
+ return G("enrichmentTargets", e), new L(
5841
5855
  this._renderingMode,
5842
5856
  this._initialArgs,
5843
5857
  this._initialUiState,
@@ -5855,7 +5869,7 @@
5855
5869
  if (this._initialArgs === void 0) throw new Error("Initial arguments not set.");
5856
5870
  const e = {
5857
5871
  v3: {
5858
- sdkVersion: H,
5872
+ sdkVersion: z,
5859
5873
  renderingMode: this._renderingMode,
5860
5874
  initialArgs: this._initialArgs,
5861
5875
  initialUiState: this._initialUiState,
@@ -5866,70 +5880,70 @@
5866
5880
  enrichmentTargets: this._enrichmentTargets
5867
5881
  },
5868
5882
  // fields below are added to allow previous desktop versions read generated configs
5869
- sdkVersion: H,
5883
+ sdkVersion: z,
5870
5884
  renderingMode: this._renderingMode,
5871
5885
  initialArgs: this._initialArgs,
5872
- inputsValid: ue(this._inputsValid),
5873
- sections: ue(this._sections),
5886
+ inputsValid: de(this._inputsValid),
5887
+ sections: de(this._sections),
5874
5888
  outputs: Object.fromEntries(
5875
- Object.entries(this._outputs).map(([n2, r]) => [n2, ue(r)])
5889
+ Object.entries(this._outputs).map(([n2, r]) => [n2, de(r)])
5876
5890
  )
5877
5891
  };
5878
- return at() ? Ee({ sdkVersion: H }) : { config: e };
5892
+ return ct() ? Oe({ sdkVersion: z }) : { config: e };
5879
5893
  }
5880
5894
  }
5881
- function Ft(t) {
5895
+ function Ot(t) {
5882
5896
  return JSON.parse(t);
5883
5897
  }
5884
- function Ot(t) {
5898
+ function Rt(t) {
5885
5899
  return t.axesSpec.length === 1 && t.name === "pl7.app/label";
5886
5900
  }
5887
- function Ve(t) {
5888
- return new ge().addAxisLabelProvider(t).addColumnProvider(t).getColumns({
5901
+ function Je(t) {
5902
+ return new me().addAxisLabelProvider(t).addColumnProvider(t).getColumns({
5889
5903
  name: "pl7.app/label",
5890
5904
  axes: [{}]
5891
5905
  // exactly one axis
5892
5906
  }, { dontWaitAllData: true });
5893
5907
  }
5894
- function Ke(t, e) {
5908
+ function Ne(t, e) {
5895
5909
  const n2 = [], r = [];
5896
5910
  for (const a of t)
5897
- Ot(a.spec) ? n2.push(a) : r.push(a);
5911
+ Rt(a.spec) ? n2.push(a) : r.push(a);
5898
5912
  const i = [];
5899
5913
  for (const a of r)
5900
5914
  for (const l2 of a.spec.axesSpec) {
5901
5915
  const u2 = p$1(l2);
5902
- i.some((d) => X(d, u2)) || i.push(u2);
5916
+ i.some((p2) => X(p2, u2)) || i.push(u2);
5903
5917
  }
5904
5918
  for (const a of n2) {
5905
- const l2 = p$1(a.spec.axesSpec[0]), u2 = i.findIndex((d) => X(d, l2));
5919
+ const l2 = p$1(a.spec.axesSpec[0]), u2 = i.findIndex((p2) => X(p2, l2));
5906
5920
  u2 !== -1 && i.splice(u2, 1);
5907
5921
  }
5908
5922
  const s2 = (a, l2) => {
5909
5923
  let u2 = a.toString();
5910
5924
  if (l2)
5911
- for (const d in l2)
5912
- u2 += d, u2 += l2[d];
5925
+ for (const p2 in l2)
5926
+ u2 += p2, u2 += l2[p2];
5913
5927
  return u2;
5914
5928
  }, o = [];
5915
5929
  for (const a of e) {
5916
- const l2 = a.spec.axesSpec[0], u2 = p$1(l2), d = i.findIndex((v) => X(v, u2));
5917
- if (d !== -1) {
5918
- const v = i[d], h2 = Object.keys(v.domain ?? {}).length, c2 = Object.keys(l2.domain ?? {}).length;
5919
- h2 > c2 ? o.push({
5920
- id: s2(a.id, v.domain),
5930
+ const l2 = a.spec.axesSpec[0], u2 = p$1(l2), p2 = i.findIndex((h2) => X(h2, u2));
5931
+ if (p2 !== -1) {
5932
+ const h2 = i[p2], w2 = Object.keys(h2.domain ?? {}).length, g = Object.keys(l2.domain ?? {}).length;
5933
+ w2 > g ? o.push({
5934
+ id: s2(a.id, h2.domain),
5921
5935
  spec: {
5922
5936
  ...a.spec,
5923
- axesSpec: [{ ...v, annotations: l2.annotations }]
5937
+ axesSpec: [{ ...h2, annotations: l2.annotations }]
5924
5938
  },
5925
5939
  data: a.data
5926
- }) : o.push(a), i.splice(d, 1);
5940
+ }) : o.push(a), i.splice(p2, 1);
5927
5941
  }
5928
5942
  }
5929
5943
  return o;
5930
5944
  }
5931
- function $e(t) {
5932
- const e = (i) => Array.isArray(i), n2 = (i) => i instanceof L, r = (i) => typeof i == "object" && "type" in i;
5945
+ function Ue(t) {
5946
+ const e = (i) => Array.isArray(i), n2 = (i) => i instanceof E, r = (i) => typeof i == "object" && "type" in i;
5933
5947
  return t.map((i) => i.data).every((i) => {
5934
5948
  if (e(i))
5935
5949
  return true;
@@ -5948,7 +5962,7 @@
5948
5962
  throw Error(`unsupported column data type: ${i}`);
5949
5963
  });
5950
5964
  }
5951
- function Je(t, e, n2, r, i, s2) {
5965
+ function Be(t, e, n2, r, i, s2) {
5952
5966
  let o = t;
5953
5967
  const a = [];
5954
5968
  if (s2) {
@@ -5969,52 +5983,52 @@
5969
5983
  sorting: i
5970
5984
  };
5971
5985
  }
5972
- function _n(t, e, n2, r) {
5973
- var u2, d;
5986
+ function Tn(t, e, n2, r) {
5987
+ var u2, p2;
5974
5988
  Array.isArray(r) && (r = { filters: r });
5975
- const i = (r == null ? void 0 : r.coreJoinType) ?? "full", s2 = [...(r == null ? void 0 : r.filters) ?? [], ...((u2 = n2 == null ? void 0 : n2.pTableParams) == null ? void 0 : u2.filters) ?? []], o = ((d = n2 == null ? void 0 : n2.pTableParams) == null ? void 0 : d.sorting) ?? [], a = Ve(t.resultPool);
5989
+ const i = (r == null ? void 0 : r.coreJoinType) ?? "full", s2 = [...(r == null ? void 0 : r.filters) ?? [], ...((u2 = n2 == null ? void 0 : n2.pTableParams) == null ? void 0 : u2.filters) ?? []], o = ((p2 = n2 == null ? void 0 : n2.pTableParams) == null ? void 0 : p2.sorting) ?? [], a = Je(t.resultPool);
5976
5990
  if (!a) return;
5977
- const l2 = Ke(e.map(Cn), a);
5978
- if ($e([...e, ...l2]))
5991
+ const l2 = Ne(e.map(Cn), a);
5992
+ if (Ue([...e, ...l2]))
5979
5993
  return t.createPTable(
5980
- Je(e, l2, i, s2, o, r == null ? void 0 : r.coreColumnPredicate)
5994
+ Be(e, l2, i, s2, o, r == null ? void 0 : r.coreColumnPredicate)
5981
5995
  );
5982
5996
  }
5983
- function Dt(t) {
5997
+ function kt(t) {
5984
5998
  var e;
5985
5999
  return ((e = t.annotations) == null ? void 0 : e["pl7.app/table/visibility"]) === "optional";
5986
6000
  }
5987
- function In(t, e, n2, r, i) {
5988
- var b, A2;
5989
- const s2 = (i == null ? void 0 : i.coreJoinType) ?? "full", o = [...(i == null ? void 0 : i.filters) ?? [], ...((b = r == null ? void 0 : r.pTableParams) == null ? void 0 : b.filters) ?? []], a = ((A2 = r == null ? void 0 : r.pTableParams) == null ? void 0 : A2.sorting) ?? [], l2 = e.find((p2) => n2(p2.spec));
6001
+ function Ln(t, e, n2, r, i) {
6002
+ var c2, y;
6003
+ const s2 = (i == null ? void 0 : i.coreJoinType) ?? "full", o = [...(i == null ? void 0 : i.filters) ?? [], ...((c2 = r == null ? void 0 : r.pTableParams) == null ? void 0 : c2.filters) ?? []], a = ((y = r == null ? void 0 : r.pTableParams) == null ? void 0 : y.sorting) ?? [], l2 = e.find((d) => n2(d.spec));
5990
6004
  if (!l2) return;
5991
- const u2 = Ve(t.resultPool);
6005
+ const u2 = Je(t.resultPool);
5992
6006
  if (!u2) return;
5993
- const d = new Set((() => {
5994
- var g, w2;
6007
+ const p2 = new Set((() => {
6008
+ var b, A2;
5995
6009
  if (s2 === "inner") return [];
5996
- const p2 = (w2 = (g = r == null ? void 0 : r.gridState.columnVisibility) == null ? void 0 : g.hiddenColIds) == null ? void 0 : w2.map(Ft).filter((f2) => f2.type === "column").map((f2) => f2.id);
5997
- return p2 || e.filter((f2) => Dt(f2.spec)).map((f2) => f2.id);
6010
+ const d = (A2 = (b = r == null ? void 0 : r.gridState.columnVisibility) == null ? void 0 : b.hiddenColIds) == null ? void 0 : A2.map(Ot).filter((v) => v.type === "column").map((v) => v.id);
6011
+ return d || e.filter((v) => kt(v.spec)).map((v) => v.id);
5998
6012
  })());
5999
- d.delete(l2.id), [...o.map((p2) => p2.column), ...a.map((p2) => p2.column)].filter((p2) => p2.type === "column").map((p2) => d.delete(p2.id));
6000
- const v = e.filter((p2) => !d.has(p2.id)), h2 = Ke(v.map(Cn), u2), c2 = [
6001
- ...l2.spec.axesSpec.map((p2) => ({
6013
+ p2.delete(l2.id), [...o.map((d) => d.column), ...a.map((d) => d.column)].filter((d) => d.type === "column").map((d) => p2.delete(d.id));
6014
+ const h2 = e.filter((d) => !p2.has(d.id)), w2 = Ne(h2.map(Cn), u2), g = [
6015
+ ...l2.spec.axesSpec.map((d) => ({
6002
6016
  type: "axis",
6003
- id: p$1(p2),
6004
- spec: p2
6017
+ id: p$1(d),
6018
+ spec: d
6005
6019
  })),
6006
- ...[...e, ...h2].map((p2) => ({
6020
+ ...[...e, ...w2].map((d) => ({
6007
6021
  type: "column",
6008
- id: p2.id,
6009
- spec: p2.spec
6022
+ id: d.id,
6023
+ spec: d.spec
6010
6024
  }))
6011
6025
  ];
6012
- if (!$e([...v, ...h2])) return;
6026
+ if (!Ue([...h2, ...w2])) return;
6013
6027
  const m2 = t.createPTable(
6014
- Je(e, h2, s2, o, a, i == null ? void 0 : i.coreColumnPredicate)
6028
+ Be(e, w2, s2, o, a, i == null ? void 0 : i.coreColumnPredicate)
6015
6029
  );
6016
6030
  return {
6017
- tableSpec: c2,
6031
+ tableSpec: g,
6018
6032
  tableHandle: m2
6019
6033
  };
6020
6034
  }
@@ -6041,7 +6055,7 @@
6041
6055
  numbers: z$2.array(z$2.coerce.number()),
6042
6056
  handles: z$2.array(ImportFileHandleSchema)
6043
6057
  });
6044
- const platforma = I.create("Heavy").withArgs({ numbers: [1, 2, 3, 4], tableNumRows: 100, handles: [] }).withUiState({ dataTableState: void 0, dynamicSections: [] }).argsValid((ctx) => {
6058
+ const platforma = L.create("Heavy").withArgs({ numbers: [1, 2, 3, 4], tableNumRows: 100, handles: [] }).withUiState({ dataTableState: void 0, dynamicSections: [] }).argsValid((ctx) => {
6045
6059
  if (ctx.args.numbers.length === 5) {
6046
6060
  throw new Error("argsValid: test error");
6047
6061
  }
@@ -6055,7 +6069,7 @@
6055
6069
  const progresses = m2 == null ? void 0 : m2.mapFields((name, val) => [name, val == null ? void 0 : val.getImportProgress()]);
6056
6070
  return Object.fromEntries(progresses ?? []);
6057
6071
  }).output("pt", (ctx) => {
6058
- var _a, _b, _c, _d, _e;
6072
+ var _a, _b, _c, _d, _e2;
6059
6073
  if (!((_c = (_b = (_a = ctx.uiState) == null ? void 0 : _a.dataTableState) == null ? void 0 : _b.tableState.pTableParams) == null ? void 0 : _c.filters)) return void 0;
6060
6074
  const data = times(ctx.args.tableNumRows ?? 0, (i) => {
6061
6075
  const v = i + 1;
@@ -6064,7 +6078,7 @@
6064
6078
  val: v.toString()
6065
6079
  };
6066
6080
  });
6067
- return _n(
6081
+ return Tn(
6068
6082
  ctx,
6069
6083
  [
6070
6084
  {
@@ -6103,12 +6117,12 @@
6103
6117
  {
6104
6118
  filters: [
6105
6119
  ...((_d = ctx.uiState.dataTableState.tableState.pTableParams) == null ? void 0 : _d.filters) ?? [],
6106
- ...((_e = ctx.uiState.dataTableState.filterModel) == null ? void 0 : _e.filters) ?? []
6120
+ ...((_e2 = ctx.uiState.dataTableState.filterModel) == null ? void 0 : _e2.filters) ?? []
6107
6121
  ]
6108
6122
  }
6109
6123
  );
6110
6124
  }).output("ptV2", (ctx) => {
6111
- var _a, _b, _c, _d, _e;
6125
+ var _a, _b, _c, _d, _e2;
6112
6126
  if (!((_c = (_b = (_a = ctx.uiState) == null ? void 0 : _a.dataTableState) == null ? void 0 : _b.tableState.pTableParams) == null ? void 0 : _c.filters)) return void 0;
6113
6127
  const data = times(ctx.args.tableNumRows ?? 0, (i) => {
6114
6128
  const v = i + 1;
@@ -6117,7 +6131,7 @@
6117
6131
  val: v.toString()
6118
6132
  };
6119
6133
  });
6120
- return In(
6134
+ return Ln(
6121
6135
  ctx,
6122
6136
  [
6123
6137
  {
@@ -6159,7 +6173,7 @@
6159
6173
  {
6160
6174
  filters: [
6161
6175
  ...((_d = ctx.uiState.dataTableState.tableState.pTableParams) == null ? void 0 : _d.filters) ?? [],
6162
- ...((_e = ctx.uiState.dataTableState.filterModel) == null ? void 0 : _e.filters) ?? []
6176
+ ...((_e2 = ctx.uiState.dataTableState.filterModel) == null ? void 0 : _e2.filters) ?? []
6163
6177
  ]
6164
6178
  }
6165
6179
  );