@milaboratories/milaboratories.ui-examples.model 1.1.22 → 1.1.24

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
@@ -2,6 +2,40 @@
2
2
  typeof exports === "object" && typeof module !== "undefined" ? factory(exports) : typeof define === "function" && define.amd ? define(["exports"], factory) : (global = typeof globalThis !== "undefined" ? globalThis : global || self, factory(global.model = {}));
3
3
  })(this, function(exports2) {
4
4
  "use strict";
5
+ function getDefaultExportFromCjs(x2) {
6
+ return x2 && x2.__esModule && Object.prototype.hasOwnProperty.call(x2, "default") ? x2["default"] : x2;
7
+ }
8
+ var canonicalize = function serialize(object) {
9
+ if (typeof object === "number" && isNaN(object)) {
10
+ throw new Error("NaN is not allowed");
11
+ }
12
+ if (typeof object === "number" && !isFinite(object)) {
13
+ throw new Error("Infinity is not allowed");
14
+ }
15
+ if (object === null || typeof object !== "object") {
16
+ return JSON.stringify(object);
17
+ }
18
+ if (object.toJSON instanceof Function) {
19
+ return serialize(object.toJSON());
20
+ }
21
+ if (Array.isArray(object)) {
22
+ const values2 = object.reduce((t, cv, ci) => {
23
+ const comma = ci === 0 ? "" : ",";
24
+ const value = cv === void 0 || typeof cv === "symbol" ? null : cv;
25
+ return `${t}${comma}${serialize(value)}`;
26
+ }, "");
27
+ return `[${values2}]`;
28
+ }
29
+ const values = Object.keys(object).sort().reduce((t, cv) => {
30
+ if (object[cv] === void 0 || typeof object[cv] === "symbol") {
31
+ return t;
32
+ }
33
+ const comma = t.length === 0 ? "" : ",";
34
+ return `${t}${comma}${serialize(cv)}:${serialize(object[cv])}`;
35
+ }, "");
36
+ return `{${values}}`;
37
+ };
38
+ const k = /* @__PURE__ */ getDefaultExportFromCjs(canonicalize);
5
39
  var util;
6
40
  (function(util2) {
7
41
  util2.assertEqual = (val) => val;
@@ -20,10 +54,10 @@
20
54
  return obj;
21
55
  };
22
56
  util2.getValidEnumValues = (obj) => {
23
- const validKeys = util2.objectKeys(obj).filter((k) => typeof obj[obj[k]] !== "number");
57
+ const validKeys = util2.objectKeys(obj).filter((k2) => typeof obj[obj[k2]] !== "number");
24
58
  const filtered = {};
25
- for (const k of validKeys) {
26
- filtered[k] = obj[k];
59
+ for (const k2 of validKeys) {
60
+ filtered[k2] = obj[k2];
27
61
  }
28
62
  return util2.objectValues(filtered);
29
63
  };
@@ -194,10 +228,10 @@
194
228
  fieldErrors._errors.push(mapper(issue));
195
229
  } else {
196
230
  let curr = fieldErrors;
197
- let i2 = 0;
198
- while (i2 < issue.path.length) {
199
- const el = issue.path[i2];
200
- const terminal = i2 === issue.path.length - 1;
231
+ let i = 0;
232
+ while (i < issue.path.length) {
233
+ const el = issue.path[i];
234
+ const terminal = i === issue.path.length - 1;
201
235
  if (!terminal) {
202
236
  curr[el] = curr[el] || { _errors: [] };
203
237
  } else {
@@ -205,7 +239,7 @@
205
239
  curr[el]._errors.push(mapper(issue));
206
240
  }
207
241
  curr = curr[el];
208
- i2++;
242
+ i++;
209
243
  }
210
244
  }
211
245
  }
@@ -391,7 +425,7 @@
391
425
  overrideMap,
392
426
  overrideMap === errorMap ? void 0 : errorMap
393
427
  // then global default map
394
- ].filter((x) => !!x)
428
+ ].filter((x2) => !!x2)
395
429
  });
396
430
  ctx.common.issues.push(issue);
397
431
  }
@@ -454,10 +488,10 @@
454
488
  });
455
489
  const DIRTY = (value) => ({ status: "dirty", value });
456
490
  const OK = (value) => ({ status: "valid", value });
457
- const isAborted = (x) => x.status === "aborted";
458
- const isDirty = (x) => x.status === "dirty";
459
- const isValid = (x) => x.status === "valid";
460
- const isAsync = (x) => typeof Promise !== "undefined" && x instanceof Promise;
491
+ const isAborted = (x2) => x2.status === "aborted";
492
+ const isDirty = (x2) => x2.status === "dirty";
493
+ const isValid = (x2) => x2.status === "valid";
494
+ const isAsync = (x2) => typeof Promise !== "undefined" && x2 instanceof Promise;
461
495
  function __classPrivateFieldGet(receiver, state, kind, f2) {
462
496
  if (typeof state === "function" ? receiver !== state || !f2 : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
463
497
  return state.get(receiver);
@@ -2051,14 +2085,14 @@
2051
2085
  }
2052
2086
  }
2053
2087
  if (ctx.common.async) {
2054
- return Promise.all([...ctx.data].map((item, i2) => {
2055
- return def.type._parseAsync(new ParseInputLazyPath(ctx, item, ctx.path, i2));
2088
+ return Promise.all([...ctx.data].map((item, i) => {
2089
+ return def.type._parseAsync(new ParseInputLazyPath(ctx, item, ctx.path, i));
2056
2090
  })).then((result2) => {
2057
2091
  return ParseStatus.mergeArray(status, result2);
2058
2092
  });
2059
2093
  }
2060
- const result = [...ctx.data].map((item, i2) => {
2061
- return def.type._parseSync(new ParseInputLazyPath(ctx, item, ctx.path, i2));
2094
+ const result = [...ctx.data].map((item, i) => {
2095
+ return def.type._parseSync(new ParseInputLazyPath(ctx, item, ctx.path, i));
2062
2096
  });
2063
2097
  return ParseStatus.mergeArray(status, result);
2064
2098
  }
@@ -2659,17 +2693,17 @@
2659
2693
  });
2660
2694
  }
2661
2695
  }
2662
- function mergeValues(a, b2) {
2696
+ function mergeValues(a, b) {
2663
2697
  const aType = getParsedType(a);
2664
- const bType = getParsedType(b2);
2665
- if (a === b2) {
2698
+ const bType = getParsedType(b);
2699
+ if (a === b) {
2666
2700
  return { valid: true, data: a };
2667
2701
  } else if (aType === ZodParsedType.object && bType === ZodParsedType.object) {
2668
- const bKeys = util.objectKeys(b2);
2702
+ const bKeys = util.objectKeys(b);
2669
2703
  const sharedKeys = util.objectKeys(a).filter((key) => bKeys.indexOf(key) !== -1);
2670
- const newObj = { ...a, ...b2 };
2704
+ const newObj = { ...a, ...b };
2671
2705
  for (const key of sharedKeys) {
2672
- const sharedValue = mergeValues(a[key], b2[key]);
2706
+ const sharedValue = mergeValues(a[key], b[key]);
2673
2707
  if (!sharedValue.valid) {
2674
2708
  return { valid: false };
2675
2709
  }
@@ -2677,13 +2711,13 @@
2677
2711
  }
2678
2712
  return { valid: true, data: newObj };
2679
2713
  } else if (aType === ZodParsedType.array && bType === ZodParsedType.array) {
2680
- if (a.length !== b2.length) {
2714
+ if (a.length !== b.length) {
2681
2715
  return { valid: false };
2682
2716
  }
2683
2717
  const newArray = [];
2684
2718
  for (let index = 0; index < a.length; index++) {
2685
2719
  const itemA = a[index];
2686
- const itemB = b2[index];
2720
+ const itemB = b[index];
2687
2721
  const sharedValue = mergeValues(itemA, itemB);
2688
2722
  if (!sharedValue.valid) {
2689
2723
  return { valid: false };
@@ -2691,7 +2725,7 @@
2691
2725
  newArray.push(sharedValue.data);
2692
2726
  }
2693
2727
  return { valid: true, data: newArray };
2694
- } else if (aType === ZodParsedType.date && bType === ZodParsedType.date && +a === +b2) {
2728
+ } else if (aType === ZodParsedType.date && bType === ZodParsedType.date && +a === +b) {
2695
2729
  return { valid: true, data: a };
2696
2730
  } else {
2697
2731
  return { valid: false };
@@ -2787,7 +2821,7 @@
2787
2821
  if (!schema)
2788
2822
  return null;
2789
2823
  return schema._parse(new ParseInputLazyPath(ctx, item, ctx.path, itemIndex));
2790
- }).filter((x) => !!x);
2824
+ }).filter((x2) => !!x2);
2791
2825
  if (ctx.common.async) {
2792
2826
  return Promise.all(items).then((results) => {
2793
2827
  return ParseStatus.mergeArray(status, results);
@@ -2986,7 +3020,7 @@
2986
3020
  }
2987
3021
  return { status: status.value, value: parsedSet };
2988
3022
  }
2989
- const elements = [...ctx.data.values()].map((item, i2) => valueType._parse(new ParseInputLazyPath(ctx, item, ctx.path, i2)));
3023
+ const elements = [...ctx.data.values()].map((item, i) => valueType._parse(new ParseInputLazyPath(ctx, item, ctx.path, i)));
2990
3024
  if (ctx.common.async) {
2991
3025
  return Promise.all(elements).then((elements2) => finalizeSet(elements2));
2992
3026
  } else {
@@ -3045,7 +3079,7 @@
3045
3079
  ctx.schemaErrorMap,
3046
3080
  getErrorMap(),
3047
3081
  errorMap
3048
- ].filter((x) => !!x),
3082
+ ].filter((x2) => !!x2),
3049
3083
  issueData: {
3050
3084
  code: ZodIssueCode.invalid_arguments,
3051
3085
  argumentsError: error
@@ -3061,7 +3095,7 @@
3061
3095
  ctx.schemaErrorMap,
3062
3096
  getErrorMap(),
3063
3097
  errorMap
3064
- ].filter((x) => !!x),
3098
+ ].filter((x2) => !!x2),
3065
3099
  issueData: {
3066
3100
  code: ZodIssueCode.invalid_return_type,
3067
3101
  returnTypeError: error
@@ -3662,10 +3696,10 @@
3662
3696
  }
3663
3697
  }
3664
3698
  }
3665
- static create(a, b2) {
3699
+ static create(a, b) {
3666
3700
  return new ZodPipeline({
3667
3701
  in: a,
3668
- out: b2,
3702
+ out: b,
3669
3703
  typeName: ZodFirstPartyTypeKind.ZodPipeline
3670
3704
  });
3671
3705
  }
@@ -3798,7 +3832,7 @@
3798
3832
  date: (arg) => ZodDate.create({ ...arg, coerce: true })
3799
3833
  };
3800
3834
  const NEVER = INVALID;
3801
- var z$1 = /* @__PURE__ */ Object.freeze({
3835
+ var z$2 = /* @__PURE__ */ Object.freeze({
3802
3836
  __proto__: null,
3803
3837
  defaultErrorMap: errorMap,
3804
3838
  setErrorMap,
@@ -3914,77 +3948,213 @@
3914
3948
  quotelessJson,
3915
3949
  ZodError
3916
3950
  });
3917
- function b$1(t) {
3918
- throw new Error("Unexpected object: " + t);
3951
+ var $ = Object.defineProperty;
3952
+ var F = (n, t, e) => t in n ? $(n, t, { enumerable: true, configurable: true, writable: true, value: e }) : n[t] = e;
3953
+ var d = (n, t, e) => F(n, typeof t != "symbol" ? t + "" : t, e);
3954
+ function g(n) {
3955
+ throw new Error("Unexpected object: " + n);
3919
3956
  }
3920
- function J(t) {
3921
- const { type: n, name: e, domain: r } = t;
3922
- return { type: n, name: e, ...r && { domain: r } };
3957
+ function h(n) {
3958
+ const { type: t, name: e, domain: r } = n;
3959
+ return { type: t, name: e, ...r && { domain: r } };
3923
3960
  }
3924
- function _$1(t, n) {
3925
- if (t === void 0) return n === void 0;
3926
- if (n === void 0) return true;
3927
- for (const e in n)
3928
- if (t[e] !== n[e]) return false;
3961
+ function Q(n, t) {
3962
+ if (n === void 0) return t === void 0;
3963
+ if (t === void 0) return true;
3964
+ for (const e in t)
3965
+ if (n[e] !== t[e]) return false;
3929
3966
  return true;
3930
3967
  }
3931
- function ot(t, n) {
3932
- return t.name === n.name && _$1(t.domain, n.domain);
3968
+ function z$1(n, t) {
3969
+ return n.name === t.name && Q(n.domain, t.domain);
3933
3970
  }
3934
- function it(t, n) {
3935
- return { ...t, src: f(t.src, n) };
3971
+ function gn(n, t) {
3972
+ return { ...n, src: l(n.src, t) };
3936
3973
  }
3937
- function f(t, n) {
3938
- switch (t.type) {
3974
+ function l(n, t) {
3975
+ switch (n.type) {
3939
3976
  case "column":
3940
3977
  return {
3941
3978
  type: "column",
3942
- column: n(t.column)
3979
+ column: t(n.column)
3943
3980
  };
3944
3981
  case "inner":
3945
3982
  case "full":
3946
3983
  return {
3947
- type: t.type,
3948
- entries: t.entries.map((e) => f(e, n))
3984
+ type: n.type,
3985
+ entries: n.entries.map((e) => l(e, t))
3949
3986
  };
3950
3987
  case "outer":
3951
3988
  return {
3952
3989
  type: "outer",
3953
- primary: f(t.primary, n),
3954
- secondary: t.secondary.map((e) => f(e, n))
3990
+ primary: l(n.primary, t),
3991
+ secondary: n.secondary.map((e) => l(e, t))
3955
3992
  };
3956
3993
  default:
3957
- b$1(t);
3994
+ g(n);
3958
3995
  }
3959
3996
  }
3960
- z$1.object({
3961
- __isRef: z$1.literal(true).describe("Crucial marker for the block dependency tree reconstruction"),
3962
- blockId: z$1.string().describe("Upstream block id"),
3963
- name: z$1.string().describe("Name of the output provided to the upstream block's output context")
3964
- }).describe(
3965
- "Universal reference type, allowing to set block connections. It is crucial that {@link __isRef} is present and equal to true, internal logic relies on this marker to build block dependency trees."
3966
- ).strict().readonly();
3967
- function i(t) {
3968
- return t.kind === "PColumn";
3997
+ function A(n) {
3998
+ return k(h(n));
3969
3999
  }
3970
- function W(t) {
3971
- return i(t.spec);
4000
+ function x(n, t) {
4001
+ return JSON.stringify([n, t]);
3972
4002
  }
3973
- function dt(t) {
3974
- if (!W(t)) throw new Error(`not a PColumn (kind = ${t.spec.kind})`);
3975
- return t;
4003
+ class wn {
4004
+ /**
4005
+ * Creates a new anchor context from a set of anchor column specifications
4006
+ * @param anchors Record of anchor column specifications indexed by anchor ID
4007
+ */
4008
+ constructor(t) {
4009
+ d(this, "domains", /* @__PURE__ */ new Map());
4010
+ d(this, "axes", /* @__PURE__ */ new Map());
4011
+ d(this, "domainPacks", []);
4012
+ d(this, "domainPackToAnchor", /* @__PURE__ */ new Map());
4013
+ this.anchors = t;
4014
+ const e = Object.entries(t);
4015
+ e.sort((r, o) => r[0].localeCompare(o[0]));
4016
+ for (const [r, o] of e) {
4017
+ for (let i = 0; i < o.axesSpec.length; i++) {
4018
+ const a = o.axesSpec[i], s = A(a);
4019
+ this.axes.set(s, { anchor: r, idx: i });
4020
+ }
4021
+ if (o.domain !== void 0) {
4022
+ const i = Object.entries(o.domain);
4023
+ i.sort((a, s) => a[0].localeCompare(s[0])), this.domainPackToAnchor.set(JSON.stringify(i), r), this.domainPacks.push(i.map(([a]) => a));
4024
+ for (const [a, s] of i) {
4025
+ const c = x(a, s);
4026
+ this.domains.set(c, r);
4027
+ }
4028
+ }
4029
+ }
4030
+ }
4031
+ /**
4032
+ * Derives an anchored column identifier from a column specification
4033
+ * Replaces domain values and axes with anchored references when possible
4034
+ * @param spec Column specification to anchor
4035
+ * @returns An anchored column identifier that can be used to identify columns similar to the input specification
4036
+ */
4037
+ derive(t) {
4038
+ const e = {
4039
+ name: t.name,
4040
+ axes: []
4041
+ };
4042
+ let r;
4043
+ if (t.domain !== void 0)
4044
+ n:
4045
+ for (const o of this.domainPacks) {
4046
+ const i = [];
4047
+ for (const s of o) {
4048
+ const c = t.domain[s];
4049
+ if (c !== void 0)
4050
+ i.push([s, c]);
4051
+ else
4052
+ break n;
4053
+ }
4054
+ const a = this.domainPackToAnchor.get(JSON.stringify(i));
4055
+ if (a !== void 0) {
4056
+ e.domainAnchor = a, r = new Set(o);
4057
+ break;
4058
+ }
4059
+ }
4060
+ for (const [o, i] of Object.entries(t.domain ?? {})) {
4061
+ if (r !== void 0 && r.has(o))
4062
+ continue;
4063
+ const a = x(o, i), s = this.domains.get(a);
4064
+ e.domain ?? (e.domain = {}), e.domain[o] = s ? { anchor: s } : i;
4065
+ }
4066
+ return e.axes = t.axesSpec.map((o) => {
4067
+ const i = A(o);
4068
+ return this.axes.get(i) ?? o;
4069
+ }), e;
4070
+ }
4071
+ /**
4072
+ * Derives a canonicalized string representation of an anchored column identifier, can be used as a unique identifier for the column
4073
+ * @param spec Column specification to anchor
4074
+ * @returns A canonicalized string representation of the anchored column identifier
4075
+ */
4076
+ deriveString(t) {
4077
+ const e = this.derive(t);
4078
+ return k(e);
4079
+ }
4080
+ }
4081
+ function An(n, t) {
4082
+ const e = { ...t };
4083
+ if (e.domainAnchor !== void 0) {
4084
+ const r = n[e.domainAnchor];
4085
+ if (!r)
4086
+ throw new Error(`Anchor "${e.domainAnchor}" not found`);
4087
+ const o = r.domain || {};
4088
+ e.domain = { ...o, ...e.domain }, delete e.domainAnchor;
4089
+ }
4090
+ if (e.domain) {
4091
+ const r = {};
4092
+ for (const [o, i] of Object.entries(e.domain))
4093
+ if (typeof i == "string")
4094
+ r[o] = i;
4095
+ else {
4096
+ const a = n[i.anchor];
4097
+ if (!a)
4098
+ throw new Error(`Anchor "${i.anchor}" not found for domain key "${o}"`);
4099
+ if (!a.domain || a.domain[o] === void 0)
4100
+ throw new Error(`Domain key "${o}" not found in anchor "${i.anchor}"`);
4101
+ r[o] = a.domain[o];
4102
+ }
4103
+ e.domain = r;
4104
+ }
4105
+ return e.axes && (e.axes = e.axes.map((r) => Y(n, r))), e;
4106
+ }
4107
+ function Y(n, t) {
4108
+ if (!Z(t))
4109
+ return t;
4110
+ const e = t.anchor, r = n[e];
4111
+ if (!r)
4112
+ throw new Error(`Anchor "${e}" not found for axis reference`);
4113
+ if ("idx" in t) {
4114
+ if (t.idx < 0 || t.idx >= r.axesSpec.length)
4115
+ throw new Error(`Axis index ${t.idx} out of bounds for anchor "${e}"`);
4116
+ return r.axesSpec[t.idx];
4117
+ } else if ("name" in t) {
4118
+ const o = r.axesSpec.filter((i) => i.name === t.name);
4119
+ if (o.length > 1)
4120
+ throw new Error(`Multiple axes with name "${t.name}" found in anchor "${e}"`);
4121
+ if (o.length === 0)
4122
+ throw new Error(`Axis with name "${t.name}" not found in anchor "${e}"`);
4123
+ return o[0];
4124
+ } else if ("id" in t) {
4125
+ const o = r.axesSpec.filter((i) => z$1(t.id, h(i)));
4126
+ if (o.length > 1)
4127
+ throw new Error(`Multiple matching axes found for matcher in anchor "${e}"`);
4128
+ if (o.length === 0)
4129
+ throw new Error(`No matching axis found for matcher in anchor "${e}"`);
4130
+ return o[0];
4131
+ }
4132
+ throw new Error("Unsupported axis reference type");
4133
+ }
4134
+ function Z(n) {
4135
+ return typeof n == "object" && "anchor" in n;
4136
+ }
4137
+ function f$1(n) {
4138
+ return n.kind === "PColumn";
3976
4139
  }
3977
- function lt(t, n) {
3978
- return t === void 0 ? void 0 : {
3979
- ...t,
3980
- data: n(t.data)
4140
+ function q$1(n) {
4141
+ return f$1(n.spec);
4142
+ }
4143
+ function En(n) {
4144
+ if (!q$1(n)) throw new Error(`not a PColumn (kind = ${n.spec.kind})`);
4145
+ return n;
4146
+ }
4147
+ function kn(n, t) {
4148
+ return n === void 0 ? void 0 : {
4149
+ ...n,
4150
+ data: t(n.data)
3981
4151
  };
3982
4152
  }
3983
- function pt(t) {
3984
- const n = /* @__PURE__ */ new Map(), e = (r) => {
4153
+ function In(n) {
4154
+ const t = /* @__PURE__ */ new Map(), e = (r) => {
3985
4155
  switch (r.type) {
3986
4156
  case "column":
3987
- n.set(r.column.id, r.column);
4157
+ t.set(r.column.id, r.column);
3988
4158
  return;
3989
4159
  case "full":
3990
4160
  case "inner":
@@ -3995,102 +4165,179 @@
3995
4165
  for (const o of r.secondary) e(o);
3996
4166
  return;
3997
4167
  default:
3998
- b$1(r);
4168
+ g(r);
3999
4169
  }
4000
4170
  };
4001
- return e(t), [...n.values()];
4171
+ return e(n), [...t.values()];
4172
+ }
4173
+ function P$1(n, t) {
4174
+ if (n.name !== void 0 && n.name !== t.name)
4175
+ return false;
4176
+ if (n.type !== void 0) {
4177
+ if (Array.isArray(n.type)) {
4178
+ if (!n.type.includes(t.type))
4179
+ return false;
4180
+ } else if (n.type !== t.type)
4181
+ return false;
4182
+ }
4183
+ if (n.domain !== void 0) {
4184
+ const e = t.domain || {};
4185
+ for (const [r, o] of Object.entries(n.domain))
4186
+ if (e[r] !== o)
4187
+ return false;
4188
+ }
4189
+ return true;
4190
+ }
4191
+ function E$1(n, t) {
4192
+ if (t.name !== void 0 && n.name !== t.name || t.namePattern !== void 0 && !new RegExp(t.namePattern).test(n.name))
4193
+ return false;
4194
+ if (t.type !== void 0) {
4195
+ if (Array.isArray(t.type)) {
4196
+ if (!t.type.includes(n.valueType))
4197
+ return false;
4198
+ } else if (t.type !== n.valueType)
4199
+ return false;
4200
+ }
4201
+ if (t.domain !== void 0) {
4202
+ const e = n.domain || {};
4203
+ for (const [r, o] of Object.entries(t.domain))
4204
+ if (e[r] !== o)
4205
+ return false;
4206
+ }
4207
+ if (t.axes !== void 0) {
4208
+ const e = n.axesSpec.map(h);
4209
+ if (t.partialAxesMatch) {
4210
+ for (const r of t.axes)
4211
+ if (!e.some((o) => P$1(r, o)))
4212
+ return false;
4213
+ } else {
4214
+ if (e.length !== t.axes.length)
4215
+ return false;
4216
+ for (let r = 0; r < t.axes.length; r++)
4217
+ if (!P$1(t.axes[r], e[r]))
4218
+ return false;
4219
+ }
4220
+ }
4221
+ if (t.annotations !== void 0) {
4222
+ const e = n.annotations || {};
4223
+ for (const [r, o] of Object.entries(t.annotations))
4224
+ if (e[r] !== o)
4225
+ return false;
4226
+ }
4227
+ if (t.annotationPatterns !== void 0) {
4228
+ const e = n.annotations || {};
4229
+ for (const [r, o] of Object.entries(t.annotationPatterns)) {
4230
+ const i = e[r];
4231
+ if (i === void 0 || !new RegExp(o).test(i))
4232
+ return false;
4233
+ }
4234
+ }
4235
+ return true;
4002
4236
  }
4003
- function mt(t, n) {
4004
- return t.ok ? { ok: true, value: n(t.value) } : t;
4237
+ function Nn(n) {
4238
+ return Array.isArray(n) ? (t) => n.some((e) => f$1(t) && E$1(t, e)) : (t) => f$1(t) && E$1(t, n);
4005
4239
  }
4006
- const Q = 24;
4007
- z$1.string().length(Q).regex(/[ABCDEFGHIJKLMNOPQRSTUVWXYZ234567]/).brand("PlId");
4008
- var he = Object.defineProperty;
4009
- var ge = (t, e, n) => e in t ? he(t, e, { enumerable: true, configurable: true, writable: true, value: n }) : t[e] = n;
4010
- var S = (t, e, n) => ge(t, typeof e != "symbol" ? e + "" : e, n);
4240
+ z$2.object({
4241
+ __isRef: z$2.literal(true).describe("Crucial marker for the block dependency tree reconstruction"),
4242
+ blockId: z$2.string().describe("Upstream block id"),
4243
+ name: z$2.string().describe("Name of the output provided to the upstream block's output context")
4244
+ }).describe(
4245
+ "Universal reference type, allowing to set block connections. It is crucial that {@link __isRef} is present and equal to true, internal logic relies on this marker to build block dependency trees."
4246
+ ).strict().readonly();
4247
+ function Vn(n) {
4248
+ return typeof n == "object" && n !== null && "__isRef" in n && n.__isRef === true && "blockId" in n && "name" in n;
4249
+ }
4250
+ function Fn(n, t) {
4251
+ return n.ok ? { ok: true, value: t(n.value) } : n;
4252
+ }
4253
+ const on = 24;
4254
+ z$2.string().length(on).regex(/[ABCDEFGHIJKLMNOPQRSTUVWXYZ234567]/).brand("PlId");
4255
+ var ve = Object.defineProperty;
4256
+ var _e = (t, e, n) => e in t ? ve(t, e, { enumerable: true, configurable: true, writable: true, value: n }) : t[e] = n;
4257
+ var P = (t, e, n) => _e(t, typeof e != "symbol" ? e + "" : e, n);
4011
4258
  function j(t) {
4012
4259
  return { type: "Immediate", value: t };
4013
4260
  }
4014
- function Ae() {
4261
+ function Fe() {
4015
4262
  return typeof globalThis.getPlatforma < "u" || typeof globalThis.platforma < "u";
4016
4263
  }
4017
- function oe(t) {
4264
+ function de(t) {
4018
4265
  if (t && typeof globalThis.getPlatforma == "function")
4019
4266
  return globalThis.getPlatforma(t);
4020
4267
  if (typeof globalThis.platforma < "u") return globalThis.platforma;
4021
4268
  throw new Error("Can't get platforma instance.");
4022
4269
  }
4023
- function we() {
4270
+ function Te() {
4024
4271
  if (typeof globalThis.cfgRenderCtx < "u") return globalThis.cfgRenderCtx;
4025
4272
  }
4026
- function c() {
4273
+ function f() {
4027
4274
  if (typeof globalThis.cfgRenderCtx < "u") return globalThis.cfgRenderCtx;
4028
4275
  throw new Error("Not in config rendering context");
4029
4276
  }
4030
4277
  function E(t, e) {
4031
- const n = we();
4278
+ const n = Te();
4032
4279
  if (n === void 0) return false;
4033
4280
  if (t in n.callbackRegistry) throw new Error(`Callback with key ${t} already registered.`);
4034
4281
  return n.callbackRegistry[t] = e, true;
4035
4282
  }
4036
- const $ = /* @__PURE__ */ new Map();
4037
- function Ie(t, e) {
4038
- t in c().callbackRegistry || (c().callbackRegistry[t] = (n) => {
4039
- for (const r of $.get(t))
4040
- r(n);
4041
- }, $.set(t, [])), $.get(t).push(e);
4283
+ const W = /* @__PURE__ */ new Map();
4284
+ function xe(t, e) {
4285
+ t in f().callbackRegistry || (f().callbackRegistry[t] = (n) => {
4286
+ for (const s of W.get(t))
4287
+ s(n);
4288
+ }, W.set(t, [])), W.get(t).push(e);
4042
4289
  }
4043
- class b {
4044
- constructor(e, n = (r) => r) {
4045
- S(this, "isResolved", false);
4046
- S(this, "resolvedValue");
4047
- this.handle = e, this.postProcess = n, Ie(e, (r) => {
4048
- this.resolvedValue = n(r), this.isResolved = true;
4290
+ class _ {
4291
+ constructor(e, n = (s) => s) {
4292
+ P(this, "isResolved", false);
4293
+ P(this, "resolvedValue");
4294
+ this.handle = e, this.postProcess = n, xe(e, (s) => {
4295
+ this.resolvedValue = n(s), this.isResolved = true;
4049
4296
  });
4050
4297
  }
4051
4298
  map(e) {
4052
- return new b(this.handle, (n) => e(this.postProcess(n)));
4299
+ return new _(this.handle, (n) => e(this.postProcess(n)));
4053
4300
  }
4054
4301
  mapDefined(e) {
4055
- return new b(this.handle, (n) => {
4056
- const r = this.postProcess(n);
4057
- return r ? e(r) : void 0;
4302
+ return new _(this.handle, (n) => {
4303
+ const s = this.postProcess(n);
4304
+ return s ? e(s) : void 0;
4058
4305
  });
4059
4306
  }
4060
4307
  toJSON() {
4061
4308
  return this.isResolved ? this.resolvedValue : { __awaited_futures__: [this.handle] };
4062
4309
  }
4063
4310
  }
4064
- function H(t, e) {
4311
+ function z(t, e) {
4065
4312
  return t === void 0 ? void 0 : e(t);
4066
4313
  }
4067
- class v {
4314
+ class S {
4068
4315
  constructor(e, n) {
4069
4316
  this.handle = e, this.resolvePath = n;
4070
4317
  }
4071
4318
  resolve(...e) {
4072
4319
  const n = e.map(
4073
- (r) => ({
4320
+ (s) => ({
4074
4321
  assertFieldType: "Input",
4075
- ...typeof r == "string" ? { field: r } : r
4322
+ ...typeof s == "string" ? { field: s } : s
4076
4323
  })
4077
4324
  );
4078
4325
  return this.resolveWithCommon({}, ...n);
4079
4326
  }
4080
4327
  resolveOutput(...e) {
4081
4328
  const n = e.map(
4082
- (r) => ({
4329
+ (s) => ({
4083
4330
  assertFieldType: "Output",
4084
- ...typeof r == "string" ? { field: r } : r
4331
+ ...typeof s == "string" ? { field: s } : s
4085
4332
  })
4086
4333
  );
4087
4334
  return this.resolveWithCommon({}, ...n);
4088
4335
  }
4089
4336
  resolveInput(...e) {
4090
4337
  const n = e.map(
4091
- (r) => ({
4338
+ (s) => ({
4092
4339
  assertFieldType: "Input",
4093
- ...typeof r == "string" ? { field: r } : r
4340
+ ...typeof s == "string" ? { field: s } : s
4094
4341
  })
4095
4342
  );
4096
4343
  return this.resolveWithCommon({}, ...n);
@@ -4099,51 +4346,51 @@
4099
4346
  return this.resolveWithCommon({}, ...e);
4100
4347
  }
4101
4348
  resolveWithCommon(e, ...n) {
4102
- const r = [
4349
+ const s = [
4103
4350
  ...this.resolvePath,
4104
- ...n.map((s) => typeof s == "string" ? s : s.field)
4351
+ ...n.map((r) => typeof r == "string" ? r : r.field)
4105
4352
  ];
4106
- return H(
4107
- c().resolveWithCommon(this.handle, e, ...n),
4108
- (s) => new v(s, r)
4353
+ return z(
4354
+ f().resolveWithCommon(this.handle, e, ...n),
4355
+ (r) => new S(r, s)
4109
4356
  );
4110
4357
  }
4111
4358
  get resourceType() {
4112
- return c().getResourceType(this.handle);
4359
+ return f().getResourceType(this.handle);
4113
4360
  }
4114
4361
  getInputsLocked() {
4115
- return c().getInputsLocked(this.handle);
4362
+ return f().getInputsLocked(this.handle);
4116
4363
  }
4117
4364
  getOutputsLocked() {
4118
- return c().getOutputsLocked(this.handle);
4365
+ return f().getOutputsLocked(this.handle);
4119
4366
  }
4120
4367
  getIsReadyOrError() {
4121
- return c().getIsReadyOrError(this.handle);
4368
+ return f().getIsReadyOrError(this.handle);
4122
4369
  }
4123
4370
  getIsFinal() {
4124
- return c().getIsFinal(this.handle);
4371
+ return f().getIsFinal(this.handle);
4125
4372
  }
4126
4373
  getError() {
4127
4374
  const e = [...this.resolvePath, "error"];
4128
- return H(
4129
- c().getError(this.handle),
4130
- (n) => new v(n, e)
4375
+ return z(
4376
+ f().getError(this.handle),
4377
+ (n) => new S(n, e)
4131
4378
  );
4132
4379
  }
4133
4380
  listInputFields() {
4134
- return c().listInputFields(this.handle);
4381
+ return f().listInputFields(this.handle);
4135
4382
  }
4136
4383
  listOutputFields() {
4137
- return c().listOutputFields(this.handle);
4384
+ return f().listOutputFields(this.handle);
4138
4385
  }
4139
4386
  listDynamicFields() {
4140
- return c().listDynamicFields(this.handle);
4387
+ return f().listDynamicFields(this.handle);
4141
4388
  }
4142
4389
  getKeyValueBase64(e) {
4143
- return c().getKeyValueBase64(this.handle, e);
4390
+ return f().getKeyValueBase64(this.handle, e);
4144
4391
  }
4145
4392
  getKeyValueAsString(e) {
4146
- return c().getKeyValueAsString(this.handle, e);
4393
+ return f().getKeyValueAsString(this.handle, e);
4147
4394
  }
4148
4395
  getKeyValueAsJson(e) {
4149
4396
  const n = this.getKeyValueAsString(e);
@@ -4151,10 +4398,10 @@
4151
4398
  return JSON.parse(n);
4152
4399
  }
4153
4400
  getDataBase64() {
4154
- return c().getDataBase64(this.handle);
4401
+ return f().getDataBase64(this.handle);
4155
4402
  }
4156
4403
  getDataAsString() {
4157
- return c().getDataAsString(this.handle);
4404
+ return f().getDataAsString(this.handle);
4158
4405
  }
4159
4406
  getDataAsJson() {
4160
4407
  const e = this.getDataAsString();
@@ -4165,39 +4412,39 @@
4165
4412
  *
4166
4413
  */
4167
4414
  getPColumns(e = false, n = "") {
4168
- const r = this.parsePObjectCollection(e, n);
4169
- return r === void 0 ? void 0 : Object.entries(r).map(([, i2]) => {
4170
- if (!W(i2)) throw new Error(`not a PColumn (kind = ${i2.spec.kind})`);
4171
- return i2;
4415
+ const s = this.parsePObjectCollection(e, n);
4416
+ return s === void 0 ? void 0 : Object.entries(s).map(([, i]) => {
4417
+ if (!q$1(i)) throw new Error(`not a PColumn (kind = ${i.spec.kind})`);
4418
+ return i;
4172
4419
  });
4173
4420
  }
4174
4421
  /**
4175
4422
  *
4176
4423
  */
4177
4424
  parsePObjectCollection(e = false, n = "") {
4178
- const r = c().parsePObjectCollection(
4425
+ const s = f().parsePObjectCollection(
4179
4426
  this.handle,
4180
4427
  e,
4181
4428
  n,
4182
4429
  ...this.resolvePath
4183
4430
  );
4184
- if (r === void 0) return;
4185
- const s = {};
4186
- for (const [i2, o] of Object.entries(r)) {
4187
- const a = [...this.resolvePath, i2];
4188
- s[i2] = lt(o, (l) => new v(l, a));
4431
+ if (s === void 0) return;
4432
+ const r = {};
4433
+ for (const [i, o] of Object.entries(s)) {
4434
+ const l2 = [...this.resolvePath, i];
4435
+ r[i] = kn(o, (a) => new S(a, l2));
4189
4436
  }
4190
- return s;
4437
+ return r;
4191
4438
  }
4192
4439
  getFileContentAsBase64() {
4193
- return new b(c().getBlobContentAsBase64(this.handle));
4440
+ return new _(f().getBlobContentAsBase64(this.handle));
4194
4441
  }
4195
4442
  getFileContentAsString() {
4196
- return new b(c().getBlobContentAsString(this.handle));
4443
+ return new _(f().getBlobContentAsString(this.handle));
4197
4444
  }
4198
4445
  getFileContentAsJson() {
4199
- return new b(
4200
- c().getBlobContentAsString(this.handle)
4446
+ return new _(
4447
+ f().getBlobContentAsString(this.handle)
4201
4448
  ).mapDefined((e) => JSON.parse(e));
4202
4449
  }
4203
4450
  /**
@@ -4216,7 +4463,7 @@
4216
4463
  * @returns downloaded file handle
4217
4464
  */
4218
4465
  getFileHandle() {
4219
- return new b(c().getDownloadedBlobContentHandle(this.handle));
4466
+ return new _(f().getDownloadedBlobContentHandle(this.handle));
4220
4467
  }
4221
4468
  /**
4222
4469
  * @deprecated use getFileHandle
@@ -4228,7 +4475,7 @@
4228
4475
  * @returns downloaded file handle
4229
4476
  */
4230
4477
  getRemoteFileHandle() {
4231
- return new b(c().getOnDemandBlobContentHandle(this.handle));
4478
+ return new _(f().getOnDemandBlobContentHandle(this.handle));
4232
4479
  }
4233
4480
  /**
4234
4481
  * @deprecated use getRemoteFileHandle
@@ -4240,22 +4487,22 @@
4240
4487
  * @returns the url to the extracted folder
4241
4488
  */
4242
4489
  extractArchiveAndGetURL(e) {
4243
- return new b(c().extractArchiveAndGetURL(this.handle, e));
4490
+ return new _(f().extractArchiveAndGetURL(this.handle, e));
4244
4491
  }
4245
4492
  getImportProgress() {
4246
- return new b(c().getImportProgress(this.handle));
4493
+ return new _(f().getImportProgress(this.handle));
4247
4494
  }
4248
4495
  getLastLogs(e) {
4249
- return new b(c().getLastLogs(this.handle, e));
4496
+ return new _(f().getLastLogs(this.handle, e));
4250
4497
  }
4251
4498
  getProgressLog(e) {
4252
- return new b(c().getProgressLog(this.handle, e));
4499
+ return new _(f().getProgressLog(this.handle, e));
4253
4500
  }
4254
4501
  getProgressLogWithInfo(e) {
4255
- return new b(c().getProgressLogWithInfo(this.handle, e));
4502
+ return new _(f().getProgressLogWithInfo(this.handle, e));
4256
4503
  }
4257
4504
  getLogHandle() {
4258
- return new b(c().getLogHandle(this.handle));
4505
+ return new _(f().getLogHandle(this.handle));
4259
4506
  }
4260
4507
  allFieldsResolved(e = "Input") {
4261
4508
  switch (e) {
@@ -4270,87 +4517,87 @@
4270
4517
  }
4271
4518
  }
4272
4519
  mapFields(e, n) {
4273
- const { fieldType: r, requireLocked: s, skipUnresolved: i2 } = {
4520
+ const { fieldType: s, requireLocked: r, skipUnresolved: i } = {
4274
4521
  fieldType: "Input",
4275
4522
  requireLocked: true,
4276
4523
  skipUnresolved: false,
4277
4524
  ...n
4278
4525
  }, o = e;
4279
- if (s && (r === "Input" && !this.getInputsLocked() || r === "Output" && !this.getOutputsLocked()))
4526
+ if (r && (s === "Input" && !this.getInputsLocked() || s === "Output" && !this.getOutputsLocked()))
4280
4527
  return;
4281
- let l = (r === "Input" ? this.listInputFields() : r === "Output" ? this.listOutputFields() : this.listDynamicFields()).map(
4282
- (u) => [u, this.resolve({ field: u, assertFieldType: r })]
4528
+ let a = (s === "Input" ? this.listInputFields() : s === "Output" ? this.listOutputFields() : this.listDynamicFields()).map(
4529
+ (u) => [u, this.resolve({ field: u, assertFieldType: s })]
4283
4530
  );
4284
- return i2 && (l = l.filter((u) => u[1] !== void 0)), l.map(([u, h]) => o(u, h));
4531
+ return i && (a = a.filter((u) => u[1] !== void 0)), a.map(([u, g2]) => o(u, g2));
4285
4532
  }
4286
4533
  }
4287
- const ae = "staging", le = "main";
4288
- const Fe = "pl7.app/label", Re = "pl7.app/trace", xe = z$1.object({
4289
- type: z$1.string(),
4290
- importance: z$1.number().optional(),
4291
- id: z$1.string().optional(),
4292
- label: z$1.string()
4293
- }), Te = z$1.array(xe), Oe = 1e-3, ke = "__LABEL__", ee = "__LABEL__@1";
4294
- function Le(t, e, n = {}) {
4295
- const r = /* @__PURE__ */ new Map(), s = /* @__PURE__ */ new Map(), i2 = t.map((p) => {
4296
- var R, Q2;
4297
- const g = e(p), f2 = (R = g.annotations) == null ? void 0 : R[Fe], I = (Q2 = g.annotations) == null ? void 0 : Q2[Re], y = (I ? Te.safeParse(JSON.parse(I)).data : void 0) ?? [];
4298
- if (f2) {
4299
- const A = { label: f2, type: ke, importance: -2 };
4300
- n.addLabelAsSuffix ? y.push(A) : y.splice(0, 0, A);
4534
+ const pe = "staging", fe = "main";
4535
+ const Oe = "pl7.app/label", ke = "pl7.app/trace", Ee = z$2.object({
4536
+ type: z$2.string(),
4537
+ importance: z$2.number().optional(),
4538
+ id: z$2.string().optional(),
4539
+ label: z$2.string()
4540
+ }), Ve = z$2.array(Ee), je = 1e-3, Ne = "__LABEL__", se = "__LABEL__@1";
4541
+ function re(t, e, n = {}) {
4542
+ const s = /* @__PURE__ */ new Map(), r = /* @__PURE__ */ new Map(), i = t.map((d2) => {
4543
+ var A2, ee;
4544
+ const h2 = e(d2), p = (A2 = h2.annotations) == null ? void 0 : A2[Oe], b = (ee = h2.annotations) == null ? void 0 : ee[ke], m = (b ? Ve.safeParse(JSON.parse(b)).data : void 0) ?? [];
4545
+ if (p) {
4546
+ const C = { label: p, type: Ne, importance: -2 };
4547
+ n.addLabelAsSuffix ? m.push(C) : m.splice(0, 0, C);
4301
4548
  }
4302
- const F = [], D = /* @__PURE__ */ new Map();
4303
- for (let A = y.length - 1; A >= 0; --A) {
4304
- const { type: M } = y[A], fe = y[A].importance ?? 0, J2 = (D.get(M) ?? 0) + 1;
4305
- D.set(M, J2);
4306
- const x = `${M}@${J2}`;
4307
- s.set(x, (s.get(x) ?? 0) + 1), r.set(
4308
- x,
4549
+ const I = [], v = /* @__PURE__ */ new Map();
4550
+ for (let C = m.length - 1; C >= 0; --C) {
4551
+ const { type: J } = m[C], be = m[C].importance ?? 0, M = (v.get(J) ?? 0) + 1;
4552
+ v.set(J, M);
4553
+ const x2 = `${J}@${M}`;
4554
+ r.set(x2, (r.get(x2) ?? 0) + 1), s.set(
4555
+ x2,
4309
4556
  Math.max(
4310
- r.get(x) ?? Number.NEGATIVE_INFINITY,
4311
- fe - (y.length - A) * Oe
4557
+ s.get(x2) ?? Number.NEGATIVE_INFINITY,
4558
+ be - (m.length - C) * je
4312
4559
  )
4313
- ), F.push({ ...y[A], fullType: x, occurenceIndex: J2 });
4560
+ ), I.push({ ...m[C], fullType: x2, occurenceIndex: M });
4314
4561
  }
4315
- return F.reverse(), {
4316
- value: p,
4317
- spec: g,
4318
- label: f2,
4319
- fullTrace: F
4562
+ return I.reverse(), {
4563
+ value: d2,
4564
+ spec: h2,
4565
+ label: p,
4566
+ fullTrace: I
4320
4567
  };
4321
- }), o = [], a = [], l = [...r];
4322
- l.sort(([, p], [, g]) => g - p);
4323
- for (const [p] of l)
4324
- p.endsWith("@1") || s.get(p) === t.length ? o.push(p) : a.push(p);
4325
- const u = (p) => i2.map((g) => {
4326
- const f2 = g.fullTrace.filter((y) => p.has(y.fullType)).map((y) => y.label), I = n.separator ?? " / ";
4568
+ }), o = [], l2 = [], a = [...s];
4569
+ a.sort(([, d2], [, h2]) => h2 - d2);
4570
+ for (const [d2] of a)
4571
+ d2.endsWith("@1") || r.get(d2) === t.length ? o.push(d2) : l2.push(d2);
4572
+ const u = (d2) => i.map((h2) => {
4573
+ const p = h2.fullTrace.filter((m) => d2.has(m.fullType)).map((m) => m.label), b = n.separator ?? " / ";
4327
4574
  return {
4328
- label: f2.join(I),
4329
- value: g.value
4575
+ label: p.join(b),
4576
+ value: h2.value
4330
4577
  };
4331
4578
  });
4332
4579
  if (o.length === 0) {
4333
- if (a.length !== 0) throw new Error("Assertion error.");
4334
- return u(new Set(ee));
4335
- }
4336
- let h = 0, d = 0;
4337
- for (; h < o.length; ) {
4338
- const p = /* @__PURE__ */ new Set();
4339
- n.includeNativeLabel && p.add(ee);
4340
- for (let f2 = 0; f2 < h; ++f2) p.add(o[f2]);
4341
- p.add(o[d]);
4342
- const g = u(p);
4343
- if (new Set(g.map((f2) => f2.label)).size === t.length) return g;
4344
- d++, d == o.length && (h++, d = h);
4345
- }
4346
- return u(/* @__PURE__ */ new Set([...o, ...a]));
4580
+ if (l2.length !== 0) throw new Error("Assertion error.");
4581
+ return u(new Set(se));
4582
+ }
4583
+ let g2 = 0, c = 0;
4584
+ for (; g2 < o.length; ) {
4585
+ const d2 = /* @__PURE__ */ new Set();
4586
+ n.includeNativeLabel && d2.add(se);
4587
+ for (let p = 0; p < g2; ++p) d2.add(o[p]);
4588
+ d2.add(o[c]);
4589
+ const h2 = u(d2);
4590
+ if (new Set(h2.map((p) => p.label)).size === t.length) return h2;
4591
+ c++, c == o.length && (g2++, c = g2);
4592
+ }
4593
+ return u(/* @__PURE__ */ new Set([...o, ...l2]));
4347
4594
  }
4348
- class De {
4595
+ class Ue {
4349
4596
  constructor() {
4350
- S(this, "ctx", c());
4351
- S(this, "defaultLabelFn", (e, n) => {
4352
- var r;
4353
- return ((r = e.annotations) == null ? void 0 : r["pl7.app/label"]) ?? "Unlabelled";
4597
+ P(this, "ctx", f());
4598
+ P(this, "defaultLabelFn", (e, n) => {
4599
+ var s;
4600
+ return ((s = e.annotations) == null ? void 0 : s["pl7.app/label"]) ?? "Unlabelled";
4354
4601
  });
4355
4602
  }
4356
4603
  /**
@@ -4360,13 +4607,33 @@
4360
4607
  return this.ctx.calculateOptions(e);
4361
4608
  }
4362
4609
  getOptions(e, n) {
4363
- const r = this.getSpecs().entries.filter((s) => e(s.obj));
4364
- return typeof n == "object" || typeof n > "u" ? Le(r, (s) => s.obj, n ?? {}).map(({ value: { ref: s }, label: i2 }) => ({
4365
- ref: s,
4366
- label: i2
4367
- })) : r.map((s) => ({
4368
- ref: s.ref,
4369
- label: n(s.obj, s.ref)
4610
+ const s = typeof e == "function" ? e : Nn(e), r = this.getSpecs().entries.filter((i) => s(i.obj));
4611
+ return typeof n == "object" || typeof n > "u" ? re(r, (i) => i.obj, n ?? {}).map(({ value: { ref: i }, label: o }) => ({
4612
+ ref: i,
4613
+ label: o
4614
+ })) : r.map((i) => ({
4615
+ ref: i.ref,
4616
+ label: n(i.obj, i.ref)
4617
+ }));
4618
+ }
4619
+ // Implementation
4620
+ getAnchoredOptions(e, n, s) {
4621
+ const r = {};
4622
+ if (!(e instanceof wn))
4623
+ for (const [a, u] of Object.entries(e))
4624
+ if (Vn(u)) {
4625
+ const g2 = this.getPColumnSpecByRef(u);
4626
+ if (!g2)
4627
+ return;
4628
+ r[a] = g2;
4629
+ } else
4630
+ r[a] = u;
4631
+ const i = typeof n == "function" ? n : Nn(
4632
+ Array.isArray(n) ? n.map((a) => An(r, a)) : An(r, n)
4633
+ ), o = this.getSpecs().entries.filter(({ obj: a }) => f$1(a) ? i(a) : false), l2 = e instanceof wn ? e : new wn(r);
4634
+ return re(o, (a) => a.obj, s ?? {}).map(({ value: { obj: a }, label: u }) => ({
4635
+ value: l2.deriveString(a),
4636
+ label: u
4370
4637
  }));
4371
4638
  }
4372
4639
  /**
@@ -4383,7 +4650,7 @@
4383
4650
  ref: n.ref,
4384
4651
  obj: {
4385
4652
  ...n.obj,
4386
- data: new v(n.obj.data, [n.ref.blockId, n.ref.name])
4653
+ data: new S(n.obj.data, [n.ref.blockId, n.ref.name])
4387
4654
  }
4388
4655
  }))
4389
4656
  };
@@ -4402,9 +4669,9 @@
4402
4669
  ref: n.ref,
4403
4670
  obj: {
4404
4671
  ...n.obj,
4405
- data: mt(
4672
+ data: Fn(
4406
4673
  n.obj.data,
4407
- (r) => new v(r, [n.ref.blockId, n.ref.name])
4674
+ (s) => new S(s, [n.ref.blockId, n.ref.name])
4408
4675
  )
4409
4676
  }
4410
4677
  }))
@@ -4426,10 +4693,10 @@
4426
4693
  getDataByRef(e) {
4427
4694
  var n;
4428
4695
  return typeof this.ctx.getDataFromResultPoolByRef > "u" ? (n = this.getData().entries.find(
4429
- (r) => r.ref.blockId === e.blockId && r.ref.name === e.name
4430
- )) == null ? void 0 : n.obj : lt(
4696
+ (s) => s.ref.blockId === e.blockId && s.ref.name === e.name
4697
+ )) == null ? void 0 : n.obj : kn(
4431
4698
  this.ctx.getDataFromResultPoolByRef(e.blockId, e.name),
4432
- (r) => new v(r, [e.blockId, e.name])
4699
+ (s) => new S(s, [e.blockId, e.name])
4433
4700
  );
4434
4701
  }
4435
4702
  /**
@@ -4440,7 +4707,7 @@
4440
4707
  getPColumnByRef(e) {
4441
4708
  const n = this.getDataByRef(e);
4442
4709
  if (n)
4443
- return dt(n);
4710
+ return En(n);
4444
4711
  }
4445
4712
  /**
4446
4713
  * Returns spec associated with the ref ensuring that it is a p-column spec.
@@ -4450,7 +4717,7 @@
4450
4717
  getPColumnSpecByRef(e) {
4451
4718
  const n = this.getSpecByRef(e);
4452
4719
  if (n) {
4453
- if (!i(n)) throw new Error(`not a PColumn spec (kind = ${n.kind})`);
4720
+ if (!f$1(n)) throw new Error(`not a PColumn spec (kind = ${n.kind})`);
4454
4721
  return n;
4455
4722
  }
4456
4723
  }
@@ -4459,10 +4726,7 @@
4459
4726
  * @returns object spec associated with the ref
4460
4727
  */
4461
4728
  getSpecByRef(e) {
4462
- var n;
4463
- return typeof this.ctx.getSpecFromResultPoolByRef > "u" ? (n = this.getSpecs().entries.find(
4464
- (r) => r.ref.blockId === e.blockId && r.ref.name === e.name
4465
- )) == null ? void 0 : n.obj : this.ctx.getSpecFromResultPoolByRef(e.blockId, e.name);
4729
+ return this.ctx.getSpecFromResultPoolByRef(e.blockId, e.name);
4466
4730
  }
4467
4731
  /**
4468
4732
  * @param spec object specification
@@ -4471,23 +4735,23 @@
4471
4735
  */
4472
4736
  findDataWithCompatibleSpec(e) {
4473
4737
  const n = [];
4474
- e: for (const r of this.getData().entries) {
4475
- if (!i(r.obj.spec))
4738
+ e: for (const s of this.getData().entries) {
4739
+ if (!f$1(s.obj.spec))
4476
4740
  continue;
4477
- const s = r.obj.spec;
4478
- if (e.name === s.name && e.valueType === s.valueType && e.axesSpec.length === s.axesSpec.length && z(e.domain, s.domain)) {
4479
- for (let i2 = 0; i2 < e.axesSpec.length; ++i2) {
4480
- const o = e.axesSpec[i2], a = s.axesSpec[i2];
4481
- if (o.name !== a.name || o.type !== a.type || !z(o.domain, a.domain))
4741
+ const r = s.obj.spec;
4742
+ if (e.name === r.name && e.valueType === r.valueType && e.axesSpec.length === r.axesSpec.length && X(e.domain, r.domain)) {
4743
+ for (let i = 0; i < e.axesSpec.length; ++i) {
4744
+ const o = e.axesSpec[i], l2 = r.axesSpec[i];
4745
+ if (o.name !== l2.name || o.type !== l2.type || !X(o.domain, l2.domain))
4482
4746
  continue e;
4483
4747
  }
4484
- n.push(r.obj);
4748
+ n.push(s.obj);
4485
4749
  }
4486
4750
  }
4487
4751
  return n;
4488
4752
  }
4489
4753
  }
4490
- function z(t, e) {
4754
+ function X(t, e) {
4491
4755
  if (t === void 0) return e === void 0;
4492
4756
  if (e === void 0) return true;
4493
4757
  for (const n in e)
@@ -4496,12 +4760,12 @@
4496
4760
  }
4497
4761
  class V {
4498
4762
  constructor() {
4499
- S(this, "ctx");
4500
- S(this, "args");
4501
- S(this, "uiState");
4502
- S(this, "_activeArgsCache");
4503
- S(this, "resultPool", new De());
4504
- this.ctx = c(), this.args = JSON.parse(this.ctx.args), this.uiState = this.ctx.uiState !== void 0 ? JSON.parse(this.ctx.uiState) : {};
4763
+ P(this, "ctx");
4764
+ P(this, "args");
4765
+ P(this, "uiState");
4766
+ P(this, "_activeArgsCache");
4767
+ P(this, "resultPool", new Ue());
4768
+ this.ctx = f(), this.args = JSON.parse(this.ctx.args), this.uiState = this.ctx.uiState !== void 0 ? JSON.parse(this.ctx.uiState) : {};
4505
4769
  }
4506
4770
  /**
4507
4771
  * Returns args snapshot the block was executed for (i.e. when "Run" button was pressed).
@@ -4517,16 +4781,16 @@
4517
4781
  // return this.ctx.featureFlags;
4518
4782
  // }
4519
4783
  getNamedAccessor(e) {
4520
- return H(
4784
+ return z(
4521
4785
  this.ctx.getAccessorHandleByName(e),
4522
- (n) => new v(n, [e])
4786
+ (n) => new S(n, [e])
4523
4787
  );
4524
4788
  }
4525
4789
  get prerun() {
4526
- return this.getNamedAccessor(ae);
4790
+ return this.getNamedAccessor(pe);
4527
4791
  }
4528
4792
  get outputs() {
4529
- return this.getNamedAccessor(le);
4793
+ return this.getNamedAccessor(fe);
4530
4794
  }
4531
4795
  /**
4532
4796
  * Find labels data for a given axis id. It will search for a label column and return its data as a map.
@@ -4534,43 +4798,43 @@
4534
4798
  */
4535
4799
  findLabels(e) {
4536
4800
  const n = this.resultPool.getData();
4537
- for (const r of n.entries) {
4538
- if (!W(r.obj)) continue;
4539
- const s = r.obj.spec;
4540
- if (s.name === "pl7.app/label" && s.axesSpec.length === 1 && s.axesSpec[0].name === e.name && s.axesSpec[0].type === e.type && z(e.domain, s.axesSpec[0].domain)) {
4541
- if (r.obj.data.resourceType.name !== "PColumnData/Json")
4542
- throw Error(`Expected JSON column for labels, got: ${r.obj.data.resourceType.name}`);
4801
+ for (const s of n.entries) {
4802
+ if (!q$1(s.obj)) continue;
4803
+ const r = s.obj.spec;
4804
+ 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)) {
4805
+ if (s.obj.data.resourceType.name !== "PColumnData/Json")
4806
+ throw Error(`Expected JSON column for labels, got: ${s.obj.data.resourceType.name}`);
4543
4807
  return Object.fromEntries(
4544
4808
  Object.entries(
4545
- r.obj.data.getDataAsJson().data
4809
+ s.obj.data.getDataAsJson().data
4546
4810
  ).map((o) => [JSON.parse(o[0])[0], o[1]])
4547
4811
  );
4548
4812
  }
4549
4813
  }
4550
4814
  }
4551
4815
  verifyInlineColumnsSupport(e) {
4552
- var s;
4553
- const n = e.some((i2) => !(i2.data instanceof v)), r = ((s = this.ctx.featureFlags) == null ? void 0 : s.inlineColumnsSupport) === true;
4554
- if (n && !r) throw Error("inline columns not supported");
4816
+ var r;
4817
+ const n = e.some((i) => !(i.data instanceof S)), s = ((r = this.ctx.featureFlags) == null ? void 0 : r.inlineColumnsSupport) === true;
4818
+ if (n && !s) throw Error("inline columns not supported");
4555
4819
  }
4556
4820
  createPFrame(e) {
4557
4821
  return this.verifyInlineColumnsSupport(e), this.ctx.createPFrame(
4558
- e.map((n) => lt(n, (r) => r instanceof v ? r.handle : r))
4822
+ e.map((n) => kn(n, (s) => s instanceof S ? s.handle : s))
4559
4823
  );
4560
4824
  }
4561
4825
  createPTable(e) {
4562
- var n;
4826
+ let n;
4563
4827
  return "columns" in e ? n = {
4564
4828
  src: {
4565
4829
  type: "full",
4566
- entries: e.columns.map((r) => ({ type: "column", column: r }))
4830
+ entries: e.columns.map((s) => ({ type: "column", column: s }))
4567
4831
  },
4568
4832
  filters: e.filters ?? [],
4569
4833
  sorting: e.sorting ?? []
4570
- } : n = e, this.verifyInlineColumnsSupport(pt(n.src)), this.ctx.createPTable(
4571
- it(
4834
+ } : n = e, this.verifyInlineColumnsSupport(In(n.src)), this.ctx.createPTable(
4835
+ gn(
4572
4836
  n,
4573
- (r) => lt(r, (s) => s instanceof v ? s.handle : s)
4837
+ (s) => kn(s, (r) => r instanceof S ? r.handle : r)
4574
4838
  )
4575
4839
  );
4576
4840
  }
@@ -4583,20 +4847,20 @@
4583
4847
  return this.ctx.getCurrentUnstableMarker();
4584
4848
  }
4585
4849
  }
4586
- const T = "1.22.97";
4587
- function Ve(t) {
4850
+ const L = "1.23.4";
4851
+ function Je(t) {
4588
4852
  return t.__renderLambda === true;
4589
4853
  }
4590
- function K(t) {
4854
+ function q(t) {
4591
4855
  if (t !== void 0)
4592
- return Ve(t) ? t.handle : t;
4856
+ return Je(t) ? t.handle : t;
4593
4857
  }
4594
- class _ {
4595
- constructor(e, n, r, s, i2, o, a) {
4596
- this._renderingMode = e, this._initialArgs = n, this._initialUiState = r, this._outputs = s, this._inputsValid = i2, this._sections = o, this._title = a;
4858
+ class w {
4859
+ constructor(e, n, s, r, i, o, l2) {
4860
+ this._renderingMode = e, this._initialArgs = n, this._initialUiState = s, this._outputs = r, this._inputsValid = i, this._sections = o, this._title = l2;
4597
4861
  }
4598
4862
  static create(e = "Heavy") {
4599
- return new _(
4863
+ return new w(
4600
4864
  e,
4601
4865
  void 0,
4602
4866
  {},
@@ -4606,10 +4870,10 @@
4606
4870
  void 0
4607
4871
  );
4608
4872
  }
4609
- output(e, n, r = {}) {
4873
+ output(e, n, s = {}) {
4610
4874
  if (typeof n == "function") {
4611
- const s = `output#${e}`;
4612
- return E(s, () => n(new V())), new _(
4875
+ const r = `output#${e}`;
4876
+ return E(r, () => n(new V())), new w(
4613
4877
  this._renderingMode,
4614
4878
  this._initialArgs,
4615
4879
  this._initialUiState,
@@ -4617,8 +4881,8 @@
4617
4881
  ...this._outputs,
4618
4882
  [e]: {
4619
4883
  __renderLambda: true,
4620
- handle: s,
4621
- ...r
4884
+ handle: r,
4885
+ ...s
4622
4886
  }
4623
4887
  },
4624
4888
  this._inputsValid,
@@ -4626,7 +4890,7 @@
4626
4890
  this._title
4627
4891
  );
4628
4892
  } else
4629
- return new _(
4893
+ return new w(
4630
4894
  this._renderingMode,
4631
4895
  this._initialArgs,
4632
4896
  this._initialUiState,
@@ -4644,7 +4908,7 @@
4644
4908
  return this.output(e, n, { retentive: true });
4645
4909
  }
4646
4910
  argsValid(e) {
4647
- return typeof e == "function" ? (E("inputsValid", () => e(new V())), new _(
4911
+ return typeof e == "function" ? (E("inputsValid", () => e(new V())), new w(
4648
4912
  this._renderingMode,
4649
4913
  this._initialArgs,
4650
4914
  this._initialUiState,
@@ -4655,7 +4919,7 @@
4655
4919
  },
4656
4920
  this._sections,
4657
4921
  this._title
4658
- )) : new _(
4922
+ )) : new w(
4659
4923
  this._renderingMode,
4660
4924
  this._initialArgs,
4661
4925
  this._initialUiState,
@@ -4666,7 +4930,7 @@
4666
4930
  );
4667
4931
  }
4668
4932
  sections(e) {
4669
- return Array.isArray(e) ? this.sections(j(e)) : typeof e == "function" ? (E("sections", () => e(new V())), new _(
4933
+ return Array.isArray(e) ? this.sections(j(e)) : typeof e == "function" ? (E("sections", () => e(new V())), new w(
4670
4934
  this._renderingMode,
4671
4935
  this._initialArgs,
4672
4936
  this._initialUiState,
@@ -4674,7 +4938,7 @@
4674
4938
  this._inputsValid,
4675
4939
  { __renderLambda: true, handle: "sections" },
4676
4940
  this._title
4677
- )) : new _(
4941
+ )) : new w(
4678
4942
  this._renderingMode,
4679
4943
  this._initialArgs,
4680
4944
  this._initialUiState,
@@ -4686,7 +4950,7 @@
4686
4950
  }
4687
4951
  /** Sets a rendering function to derive block title, shown for the block in the left blocks-overview panel. */
4688
4952
  title(e) {
4689
- return E("title", () => e(new V())), new _(
4953
+ return E("title", () => e(new V())), new w(
4690
4954
  this._renderingMode,
4691
4955
  this._initialArgs,
4692
4956
  this._initialUiState,
@@ -4701,7 +4965,7 @@
4701
4965
  * @deprecated use {@link withArgs}
4702
4966
  * */
4703
4967
  initialArgs(e) {
4704
- return new _(
4968
+ return new w(
4705
4969
  this._renderingMode,
4706
4970
  e,
4707
4971
  this._initialUiState,
@@ -4713,7 +4977,7 @@
4713
4977
  }
4714
4978
  /** Sets initial args for the block, this value must be specified. */
4715
4979
  withArgs(e) {
4716
- return new _(
4980
+ return new w(
4717
4981
  this._renderingMode,
4718
4982
  e,
4719
4983
  this._initialUiState,
@@ -4725,7 +4989,7 @@
4725
4989
  }
4726
4990
  /** Defines type and sets initial value for block UiState. */
4727
4991
  withUiState(e) {
4728
- return new _(
4992
+ return new w(
4729
4993
  this._renderingMode,
4730
4994
  this._initialArgs,
4731
4995
  e,
@@ -4742,7 +5006,7 @@
4742
5006
  if (this._initialArgs === void 0) throw new Error("Initial arguments not set.");
4743
5007
  const e = {
4744
5008
  v3: {
4745
- sdkVersion: T,
5009
+ sdkVersion: L,
4746
5010
  renderingMode: this._renderingMode,
4747
5011
  initialArgs: this._initialArgs,
4748
5012
  initialUiState: this._initialUiState,
@@ -4752,78 +5016,78 @@
4752
5016
  outputs: this._outputs
4753
5017
  },
4754
5018
  // fields below are added to allow previous desktop versions read generated configs
4755
- sdkVersion: T,
5019
+ sdkVersion: L,
4756
5020
  renderingMode: this._renderingMode,
4757
5021
  initialArgs: this._initialArgs,
4758
- inputsValid: K(this._inputsValid),
4759
- sections: K(this._sections),
5022
+ inputsValid: q(this._inputsValid),
5023
+ sections: q(this._sections),
4760
5024
  outputs: Object.fromEntries(
4761
- Object.entries(this._outputs).map(([n, r]) => [n, K(r)])
5025
+ Object.entries(this._outputs).map(([n, s]) => [n, q(s)])
4762
5026
  )
4763
5027
  };
4764
- return Ae() ? oe({ sdkVersion: T }) : { config: e };
5028
+ return Fe() ? de({ sdkVersion: L }) : { config: e };
4765
5029
  }
4766
5030
  }
4767
- function Ft(t, e, n, r) {
4768
- var u, h;
4769
- Array.isArray(r) && (r = { filters: r });
4770
- const s = t.resultPool.getData().entries.map((d) => d.obj).filter(W).filter((d) => d.spec.name === "pl7.app/label" && d.spec.axesSpec.length === 1), i2 = (d, p) => {
4771
- let g = d.toString();
4772
- if (p)
4773
- for (const f2 in p)
4774
- g += f2, g += p[f2];
4775
- return g;
5031
+ function Dt(t, e, n, s) {
5032
+ var u, g2;
5033
+ Array.isArray(s) && (s = { filters: s });
5034
+ const r = t.resultPool.getData().entries.map((c) => c.obj).filter(q$1).filter((c) => c.spec.name === "pl7.app/label" && c.spec.axesSpec.length === 1), i = (c, d2) => {
5035
+ let h2 = c.toString();
5036
+ if (d2)
5037
+ for (const p in d2)
5038
+ h2 += p, h2 += d2[p];
5039
+ return h2;
4776
5040
  }, o = /* @__PURE__ */ new Map();
4777
- for (const d of e)
4778
- for (const p of d.spec.axesSpec) {
4779
- const g = J(p);
4780
- for (const f2 of s) {
4781
- const I = f2.spec.axesSpec[0], y = J(f2.spec.axesSpec[0]);
4782
- if (ot(g, y)) {
4783
- const F = Object.keys(g.domain ?? {}).length, D = Object.keys(y.domain ?? {}).length;
4784
- if (F > D) {
4785
- const R = i2(f2.id, g.domain);
4786
- o.set(R, {
4787
- id: R,
5041
+ for (const c of e)
5042
+ for (const d2 of c.spec.axesSpec) {
5043
+ const h$1 = h(d2);
5044
+ for (const p of r) {
5045
+ const b = p.spec.axesSpec[0], m = h(p.spec.axesSpec[0]);
5046
+ if (z$1(h$1, m)) {
5047
+ const I = Object.keys(h$1.domain ?? {}).length, v = Object.keys(m.domain ?? {}).length;
5048
+ if (I > v) {
5049
+ const A2 = i(p.id, h$1.domain);
5050
+ o.set(A2, {
5051
+ id: A2,
4788
5052
  spec: {
4789
- ...f2.spec,
4790
- axesSpec: [{ ...g, annotations: I.annotations }]
5053
+ ...p.spec,
5054
+ axesSpec: [{ ...h$1, annotations: b.annotations }]
4791
5055
  },
4792
- data: f2.data
5056
+ data: p.data
4793
5057
  });
4794
5058
  } else
4795
- o.set(i2(f2.id), f2);
5059
+ o.set(i(p.id), p);
4796
5060
  }
4797
5061
  }
4798
5062
  }
4799
5063
  if ([...e, ...o.values()].some(
4800
- (d) => d.data instanceof v && !d.data.getIsReadyOrError()
5064
+ (c) => c.data instanceof S && !c.data.getIsReadyOrError()
4801
5065
  ))
4802
5066
  return;
4803
- let a = e;
4804
- const l = [];
4805
- if (r != null && r.coreColumnPredicate) {
4806
- a = [];
4807
- for (const d of e)
4808
- r.coreColumnPredicate(d.spec) ? a.push(d) : l.push(d);
4809
- }
4810
- return l.push(...o.values()), t.createPTable({
5067
+ let l2 = e;
5068
+ const a = [];
5069
+ if (s != null && s.coreColumnPredicate) {
5070
+ l2 = [];
5071
+ for (const c of e)
5072
+ s.coreColumnPredicate(c.spec) ? l2.push(c) : a.push(c);
5073
+ }
5074
+ return a.push(...o.values()), t.createPTable({
4811
5075
  src: {
4812
5076
  type: "outer",
4813
5077
  primary: {
4814
- type: (r == null ? void 0 : r.coreJoinType) ?? "full",
4815
- entries: a.map((d) => ({ type: "column", column: d }))
5078
+ type: (s == null ? void 0 : s.coreJoinType) ?? "full",
5079
+ entries: l2.map((c) => ({ type: "column", column: c }))
4816
5080
  },
4817
- secondary: l.map((d) => ({ type: "column", column: d }))
5081
+ secondary: a.map((c) => ({ type: "column", column: c }))
4818
5082
  },
4819
- filters: [...(r == null ? void 0 : r.filters) ?? [], ...((u = n == null ? void 0 : n.pTableParams) == null ? void 0 : u.filters) ?? []],
4820
- sorting: ((h = n == null ? void 0 : n.pTableParams) == null ? void 0 : h.sorting) ?? []
5083
+ filters: [...(s == null ? void 0 : s.filters) ?? [], ...((u = n == null ? void 0 : n.pTableParams) == null ? void 0 : u.filters) ?? []],
5084
+ sorting: ((g2 = n == null ? void 0 : n.pTableParams) == null ? void 0 : g2.sorting) ?? []
4821
5085
  });
4822
5086
  }
4823
- const $BlockArgs = z$1.object({
4824
- numbers: z$1.array(z$1.coerce.number())
5087
+ const $BlockArgs = z$2.object({
5088
+ numbers: z$2.array(z$2.coerce.number())
4825
5089
  });
4826
- const platforma = _.create("Heavy").withArgs({ numbers: [1, 2, 3, 4] }).withUiState({ dataTableState: void 0, dynamicSections: [] }).argsValid((ctx) => {
5090
+ const platforma = w.create("Heavy").withArgs({ numbers: [1, 2, 3, 4] }).withUiState({ dataTableState: void 0, dynamicSections: [] }).argsValid((ctx) => {
4827
5091
  if (ctx.args.numbers.length === 5) {
4828
5092
  throw new Error("argsValid: test error");
4829
5093
  }
@@ -4832,9 +5096,9 @@
4832
5096
  var _a, _b;
4833
5097
  return (_b = (_a = ctx.outputs) == null ? void 0 : _a.resolve("numbers")) == null ? void 0 : _b.getDataAsJson();
4834
5098
  }).output("pt", (ctx) => {
4835
- var _a, _b, _c, _d, _e;
5099
+ var _a, _b, _c, _d, _e2;
4836
5100
  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;
4837
- return Ft(
5101
+ return Dt(
4838
5102
  ctx,
4839
5103
  [
4840
5104
  {
@@ -4875,7 +5139,7 @@
4875
5139
  {
4876
5140
  filters: [
4877
5141
  ...((_d = ctx.uiState.dataTableState.tableState.pTableParams) == null ? void 0 : _d.filters) ?? [],
4878
- ...((_e = ctx.uiState.dataTableState.filterModel) == null ? void 0 : _e.filters) ?? []
5142
+ ...((_e2 = ctx.uiState.dataTableState.filterModel) == null ? void 0 : _e2.filters) ?? []
4879
5143
  ]
4880
5144
  }
4881
5145
  );
@@ -4885,12 +5149,12 @@
4885
5149
  }
4886
5150
  return "Ui Examples";
4887
5151
  }).sections((ctx) => {
4888
- const dynamicSections = (ctx.uiState.dynamicSections ?? []).map((it2) => ({
5152
+ const dynamicSections = (ctx.uiState.dynamicSections ?? []).map((it) => ({
4889
5153
  type: "link",
4890
- href: `/section?id=${it2.id}`,
4891
- label: it2.label
5154
+ href: `/section?id=${it.id}`,
5155
+ label: it.label
4892
5156
  }));
4893
- if (dynamicSections.some((it2) => it2.label === "Error")) {
5157
+ if (dynamicSections.some((it) => it.label === "Error")) {
4894
5158
  throw new Error("sections: test error");
4895
5159
  }
4896
5160
  return [