@milaboratories/milaboratories.pool-explorer.model 1.0.61 → 1.0.63
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/.turbo/turbo-build.log +7 -7
- package/CHANGELOG.md +15 -0
- package/dist/bundle.js +613 -539
- package/dist/bundle.js.map +1 -1
- package/dist/model.json +1 -1
- package/package.json +3 -3
package/dist/bundle.js
CHANGED
|
@@ -53,7 +53,7 @@
|
|
|
53
53
|
return array.map((val) => typeof val === "string" ? `'${val}'` : val).join(separator);
|
|
54
54
|
}
|
|
55
55
|
util2.joinValues = joinValues;
|
|
56
|
-
util2.jsonStringifyReplacer = (
|
|
56
|
+
util2.jsonStringifyReplacer = (_2, value) => {
|
|
57
57
|
if (typeof value === "bigint") {
|
|
58
58
|
return value.toString();
|
|
59
59
|
}
|
|
@@ -391,7 +391,7 @@
|
|
|
391
391
|
overrideMap,
|
|
392
392
|
overrideMap === errorMap ? void 0 : errorMap
|
|
393
393
|
// then global default map
|
|
394
|
-
].filter((
|
|
394
|
+
].filter((x2) => !!x2)
|
|
395
395
|
});
|
|
396
396
|
ctx.common.issues.push(issue);
|
|
397
397
|
}
|
|
@@ -454,15 +454,15 @@
|
|
|
454
454
|
});
|
|
455
455
|
const DIRTY = (value) => ({ status: "dirty", value });
|
|
456
456
|
const OK = (value) => ({ status: "valid", value });
|
|
457
|
-
const isAborted = (
|
|
458
|
-
const isDirty = (
|
|
459
|
-
const isValid = (
|
|
460
|
-
const isAsync = (
|
|
461
|
-
function __classPrivateFieldGet(receiver, state, kind,
|
|
457
|
+
const isAborted = (x2) => x2.status === "aborted";
|
|
458
|
+
const isDirty = (x2) => x2.status === "dirty";
|
|
459
|
+
const isValid = (x2) => x2.status === "valid";
|
|
460
|
+
const isAsync = (x2) => typeof Promise !== "undefined" && x2 instanceof Promise;
|
|
461
|
+
function __classPrivateFieldGet(receiver, state, kind, f) {
|
|
462
462
|
if (typeof state === "function" ? receiver !== state || true : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
463
463
|
return state.get(receiver);
|
|
464
464
|
}
|
|
465
|
-
function __classPrivateFieldSet(receiver, state, value, kind,
|
|
465
|
+
function __classPrivateFieldSet(receiver, state, value, kind, f) {
|
|
466
466
|
if (typeof state === "function" ? receiver !== state || true : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
|
|
467
467
|
return state.set(receiver, value), value;
|
|
468
468
|
}
|
|
@@ -2787,7 +2787,7 @@
|
|
|
2787
2787
|
if (!schema)
|
|
2788
2788
|
return null;
|
|
2789
2789
|
return schema._parse(new ParseInputLazyPath(ctx, item, ctx.path, itemIndex));
|
|
2790
|
-
}).filter((
|
|
2790
|
+
}).filter((x2) => !!x2);
|
|
2791
2791
|
if (ctx.common.async) {
|
|
2792
2792
|
return Promise.all(items).then((results) => {
|
|
2793
2793
|
return ParseStatus.mergeArray(status, results);
|
|
@@ -3045,7 +3045,7 @@
|
|
|
3045
3045
|
ctx.schemaErrorMap,
|
|
3046
3046
|
getErrorMap(),
|
|
3047
3047
|
errorMap
|
|
3048
|
-
].filter((
|
|
3048
|
+
].filter((x2) => !!x2),
|
|
3049
3049
|
issueData: {
|
|
3050
3050
|
code: ZodIssueCode.invalid_arguments,
|
|
3051
3051
|
argumentsError: error
|
|
@@ -3061,7 +3061,7 @@
|
|
|
3061
3061
|
ctx.schemaErrorMap,
|
|
3062
3062
|
getErrorMap(),
|
|
3063
3063
|
errorMap
|
|
3064
|
-
].filter((
|
|
3064
|
+
].filter((x2) => !!x2),
|
|
3065
3065
|
issueData: {
|
|
3066
3066
|
code: ZodIssueCode.invalid_return_type,
|
|
3067
3067
|
returnTypeError: error
|
|
@@ -3914,8 +3914,8 @@
|
|
|
3914
3914
|
quotelessJson,
|
|
3915
3915
|
ZodError
|
|
3916
3916
|
});
|
|
3917
|
-
function getDefaultExportFromCjs(
|
|
3918
|
-
return
|
|
3917
|
+
function getDefaultExportFromCjs(x2) {
|
|
3918
|
+
return x2 && x2.__esModule && Object.prototype.hasOwnProperty.call(x2, "default") ? x2["default"] : x2;
|
|
3919
3919
|
}
|
|
3920
3920
|
var canonicalize;
|
|
3921
3921
|
var hasRequiredCanonicalize;
|
|
@@ -3955,233 +3955,233 @@
|
|
|
3955
3955
|
return canonicalize;
|
|
3956
3956
|
}
|
|
3957
3957
|
var canonicalizeExports = requireCanonicalize();
|
|
3958
|
-
const
|
|
3959
|
-
var
|
|
3960
|
-
var
|
|
3961
|
-
var l$1 = (
|
|
3958
|
+
const Re = /* @__PURE__ */ getDefaultExportFromCjs(canonicalizeExports);
|
|
3959
|
+
var D$1 = Object.defineProperty;
|
|
3960
|
+
var L = (e, n2, t) => n2 in e ? D$1(e, n2, { enumerable: true, configurable: true, writable: true, value: t }) : e[n2] = t;
|
|
3961
|
+
var l$1 = (e, n2, t) => L(e, typeof n2 != "symbol" ? n2 + "" : n2, t);
|
|
3962
3962
|
z$1.object({
|
|
3963
3963
|
/** Included left border. */
|
|
3964
3964
|
from: z$1.number(),
|
|
3965
3965
|
/** Excluded right border. */
|
|
3966
3966
|
to: z$1.number()
|
|
3967
3967
|
});
|
|
3968
|
-
function
|
|
3969
|
-
throw new Error("Unexpected object: " +
|
|
3968
|
+
function A(e) {
|
|
3969
|
+
throw new Error("Unexpected object: " + e);
|
|
3970
3970
|
}
|
|
3971
|
-
function
|
|
3972
|
-
if (!
|
|
3971
|
+
function Oe(e) {
|
|
3972
|
+
if (!e || typeof e != "object")
|
|
3973
3973
|
return false;
|
|
3974
|
-
const
|
|
3975
|
-
if (!("type" in
|
|
3974
|
+
const n2 = e;
|
|
3975
|
+
if (!("type" in n2))
|
|
3976
3976
|
return false;
|
|
3977
|
-
switch (
|
|
3977
|
+
switch (n2.type) {
|
|
3978
3978
|
case "Json":
|
|
3979
|
-
return typeof
|
|
3979
|
+
return typeof n2.keyLength == "number" && n2.data !== void 0 && typeof n2.data == "object";
|
|
3980
3980
|
case "JsonPartitioned":
|
|
3981
|
-
return typeof
|
|
3981
|
+
return typeof n2.partitionKeyLength == "number" && n2.parts !== void 0 && typeof n2.parts == "object";
|
|
3982
3982
|
case "BinaryPartitioned":
|
|
3983
|
-
return typeof
|
|
3983
|
+
return typeof n2.partitionKeyLength == "number" && n2.parts !== void 0 && typeof n2.parts == "object";
|
|
3984
3984
|
default:
|
|
3985
3985
|
return false;
|
|
3986
3986
|
}
|
|
3987
3987
|
}
|
|
3988
|
-
function
|
|
3989
|
-
if (
|
|
3990
|
-
switch (
|
|
3988
|
+
function Ce(e, n2) {
|
|
3989
|
+
if (e !== void 0)
|
|
3990
|
+
switch (e.type) {
|
|
3991
3991
|
case "Json":
|
|
3992
|
-
return
|
|
3992
|
+
return e;
|
|
3993
3993
|
case "JsonPartitioned": {
|
|
3994
3994
|
const t = {};
|
|
3995
|
-
for (const [r, o] of Object.entries(
|
|
3996
|
-
t[r] =
|
|
3995
|
+
for (const [r, o] of Object.entries(e.parts))
|
|
3996
|
+
t[r] = n2(o);
|
|
3997
3997
|
return {
|
|
3998
|
-
...
|
|
3998
|
+
...e,
|
|
3999
3999
|
parts: t
|
|
4000
4000
|
};
|
|
4001
4001
|
}
|
|
4002
4002
|
case "BinaryPartitioned": {
|
|
4003
4003
|
const t = {};
|
|
4004
|
-
for (const [r, o] of Object.entries(
|
|
4004
|
+
for (const [r, o] of Object.entries(e.parts))
|
|
4005
4005
|
t[r] = {
|
|
4006
|
-
index:
|
|
4007
|
-
values:
|
|
4006
|
+
index: n2(o.index),
|
|
4007
|
+
values: n2(o.values)
|
|
4008
4008
|
};
|
|
4009
4009
|
return {
|
|
4010
|
-
...
|
|
4010
|
+
...e,
|
|
4011
4011
|
parts: t
|
|
4012
4012
|
};
|
|
4013
4013
|
}
|
|
4014
4014
|
}
|
|
4015
4015
|
}
|
|
4016
|
-
function
|
|
4017
|
-
if (!
|
|
4016
|
+
function _(e) {
|
|
4017
|
+
if (!e || typeof e != "object")
|
|
4018
4018
|
return false;
|
|
4019
|
-
const
|
|
4020
|
-
if (!("type" in
|
|
4019
|
+
const n2 = e;
|
|
4020
|
+
if (!("type" in n2))
|
|
4021
4021
|
return false;
|
|
4022
|
-
switch (
|
|
4022
|
+
switch (n2.type) {
|
|
4023
4023
|
case "Json":
|
|
4024
|
-
return typeof
|
|
4024
|
+
return typeof n2.keyLength == "number" && Array.isArray(n2.data);
|
|
4025
4025
|
case "JsonPartitioned":
|
|
4026
|
-
return typeof
|
|
4026
|
+
return typeof n2.partitionKeyLength == "number" && Array.isArray(n2.parts);
|
|
4027
4027
|
case "BinaryPartitioned":
|
|
4028
|
-
return typeof
|
|
4028
|
+
return typeof n2.partitionKeyLength == "number" && Array.isArray(n2.parts);
|
|
4029
4029
|
default:
|
|
4030
4030
|
return false;
|
|
4031
4031
|
}
|
|
4032
4032
|
}
|
|
4033
|
-
function
|
|
4034
|
-
return
|
|
4033
|
+
function $e$1(e) {
|
|
4034
|
+
return _(e) ? e.type === "JsonPartitioned" || e.type === "BinaryPartitioned" : false;
|
|
4035
4035
|
}
|
|
4036
|
-
function
|
|
4037
|
-
switch (
|
|
4036
|
+
function Ve$1(e) {
|
|
4037
|
+
switch (e.type) {
|
|
4038
4038
|
case "Json": {
|
|
4039
|
-
const
|
|
4039
|
+
const n2 = Object.entries(e.data).map(([t, r]) => ({ key: JSON.parse(t), value: r }));
|
|
4040
4040
|
return {
|
|
4041
4041
|
type: "Json",
|
|
4042
|
-
keyLength:
|
|
4043
|
-
data:
|
|
4042
|
+
keyLength: e.keyLength,
|
|
4043
|
+
data: n2
|
|
4044
4044
|
};
|
|
4045
4045
|
}
|
|
4046
4046
|
case "JsonPartitioned": {
|
|
4047
|
-
const
|
|
4047
|
+
const n2 = Object.entries(e.parts).map(([t, r]) => ({ key: JSON.parse(t), value: r }));
|
|
4048
4048
|
return {
|
|
4049
4049
|
type: "JsonPartitioned",
|
|
4050
|
-
partitionKeyLength:
|
|
4051
|
-
parts:
|
|
4050
|
+
partitionKeyLength: e.partitionKeyLength,
|
|
4051
|
+
parts: n2
|
|
4052
4052
|
};
|
|
4053
4053
|
}
|
|
4054
4054
|
case "BinaryPartitioned": {
|
|
4055
|
-
const
|
|
4055
|
+
const n2 = Object.entries(e.parts).map(([t, r]) => ({ key: JSON.parse(t), value: r }));
|
|
4056
4056
|
return {
|
|
4057
4057
|
type: "BinaryPartitioned",
|
|
4058
|
-
partitionKeyLength:
|
|
4059
|
-
parts:
|
|
4058
|
+
partitionKeyLength: e.partitionKeyLength,
|
|
4059
|
+
parts: n2
|
|
4060
4060
|
};
|
|
4061
4061
|
}
|
|
4062
4062
|
}
|
|
4063
4063
|
}
|
|
4064
|
-
function
|
|
4065
|
-
switch (
|
|
4064
|
+
function Ie$1(e) {
|
|
4065
|
+
switch (e.type) {
|
|
4066
4066
|
case "Json": {
|
|
4067
|
-
const
|
|
4068
|
-
for (const t of
|
|
4069
|
-
|
|
4067
|
+
const n2 = {};
|
|
4068
|
+
for (const t of e.data)
|
|
4069
|
+
n2[JSON.stringify(t.key)] = t.value;
|
|
4070
4070
|
return {
|
|
4071
4071
|
type: "Json",
|
|
4072
|
-
keyLength:
|
|
4073
|
-
data:
|
|
4072
|
+
keyLength: e.keyLength,
|
|
4073
|
+
data: n2
|
|
4074
4074
|
};
|
|
4075
4075
|
}
|
|
4076
4076
|
case "JsonPartitioned": {
|
|
4077
|
-
const
|
|
4078
|
-
for (const t of
|
|
4079
|
-
|
|
4077
|
+
const n2 = {};
|
|
4078
|
+
for (const t of e.parts)
|
|
4079
|
+
n2[JSON.stringify(t.key)] = t.value;
|
|
4080
4080
|
return {
|
|
4081
4081
|
type: "JsonPartitioned",
|
|
4082
|
-
partitionKeyLength:
|
|
4083
|
-
parts:
|
|
4082
|
+
partitionKeyLength: e.partitionKeyLength,
|
|
4083
|
+
parts: n2
|
|
4084
4084
|
};
|
|
4085
4085
|
}
|
|
4086
4086
|
case "BinaryPartitioned": {
|
|
4087
|
-
const
|
|
4088
|
-
for (const t of
|
|
4089
|
-
|
|
4087
|
+
const n2 = {};
|
|
4088
|
+
for (const t of e.parts)
|
|
4089
|
+
n2[JSON.stringify(t.key)] = t.value;
|
|
4090
4090
|
return {
|
|
4091
4091
|
type: "BinaryPartitioned",
|
|
4092
|
-
partitionKeyLength:
|
|
4093
|
-
parts:
|
|
4092
|
+
partitionKeyLength: e.partitionKeyLength,
|
|
4093
|
+
parts: n2
|
|
4094
4094
|
};
|
|
4095
4095
|
}
|
|
4096
4096
|
}
|
|
4097
4097
|
}
|
|
4098
|
-
function
|
|
4099
|
-
const { type:
|
|
4098
|
+
function y(e) {
|
|
4099
|
+
const { type: n2, name: t, domain: r } = e, o = { type: n2, name: t };
|
|
4100
4100
|
return r && Object.entries(r).length > 0 && Object.assign(o, { domain: r }), o;
|
|
4101
4101
|
}
|
|
4102
|
-
function
|
|
4103
|
-
return
|
|
4102
|
+
function C(e) {
|
|
4103
|
+
return e.map(y);
|
|
4104
4104
|
}
|
|
4105
|
-
function
|
|
4106
|
-
return
|
|
4105
|
+
function _e$1(e) {
|
|
4106
|
+
return Re(y(e));
|
|
4107
4107
|
}
|
|
4108
|
-
function
|
|
4109
|
-
if (
|
|
4110
|
-
if (
|
|
4111
|
-
for (const t in
|
|
4112
|
-
if (
|
|
4108
|
+
function ee$1(e, n2) {
|
|
4109
|
+
if (e === void 0) return n2 === void 0;
|
|
4110
|
+
if (n2 === void 0) return true;
|
|
4111
|
+
for (const t in n2)
|
|
4112
|
+
if (e[t] !== n2[t]) return false;
|
|
4113
4113
|
return true;
|
|
4114
4114
|
}
|
|
4115
|
-
function
|
|
4116
|
-
return
|
|
4115
|
+
function ne$1(e, n2) {
|
|
4116
|
+
return e.name === n2.name && ee$1(e.domain, n2.domain);
|
|
4117
4117
|
}
|
|
4118
|
-
function
|
|
4119
|
-
return { ...
|
|
4118
|
+
function qe(e, n2) {
|
|
4119
|
+
return { ...e, src: g(e.src, n2) };
|
|
4120
4120
|
}
|
|
4121
|
-
function
|
|
4122
|
-
switch (
|
|
4121
|
+
function g(e, n2) {
|
|
4122
|
+
switch (e.type) {
|
|
4123
4123
|
case "column":
|
|
4124
4124
|
return {
|
|
4125
4125
|
type: "column",
|
|
4126
|
-
column: e
|
|
4126
|
+
column: n2(e.column)
|
|
4127
4127
|
};
|
|
4128
4128
|
case "slicedColumn":
|
|
4129
4129
|
return {
|
|
4130
4130
|
type: "slicedColumn",
|
|
4131
|
-
column: e
|
|
4132
|
-
newId:
|
|
4133
|
-
axisFilters:
|
|
4131
|
+
column: n2(e.column),
|
|
4132
|
+
newId: e.newId,
|
|
4133
|
+
axisFilters: e.axisFilters
|
|
4134
4134
|
};
|
|
4135
4135
|
case "inlineColumn":
|
|
4136
|
-
return
|
|
4136
|
+
return e;
|
|
4137
4137
|
case "inner":
|
|
4138
4138
|
case "full":
|
|
4139
4139
|
return {
|
|
4140
|
-
type:
|
|
4141
|
-
entries:
|
|
4140
|
+
type: e.type,
|
|
4141
|
+
entries: e.entries.map((t) => g(t, n2))
|
|
4142
4142
|
};
|
|
4143
4143
|
case "outer":
|
|
4144
4144
|
return {
|
|
4145
4145
|
type: "outer",
|
|
4146
|
-
primary:
|
|
4147
|
-
secondary:
|
|
4146
|
+
primary: g(e.primary, n2),
|
|
4147
|
+
secondary: e.secondary.map((t) => g(t, n2))
|
|
4148
4148
|
};
|
|
4149
4149
|
default:
|
|
4150
|
-
|
|
4150
|
+
A(e);
|
|
4151
4151
|
}
|
|
4152
4152
|
}
|
|
4153
|
-
function
|
|
4154
|
-
return
|
|
4153
|
+
function te(e) {
|
|
4154
|
+
return Re(e);
|
|
4155
4155
|
}
|
|
4156
|
-
function P(
|
|
4157
|
-
return
|
|
4156
|
+
function P(e) {
|
|
4157
|
+
return Re(y(e));
|
|
4158
4158
|
}
|
|
4159
|
-
function
|
|
4160
|
-
return JSON.stringify([
|
|
4159
|
+
function E(e, n2) {
|
|
4160
|
+
return JSON.stringify([e, n2]);
|
|
4161
4161
|
}
|
|
4162
|
-
class
|
|
4162
|
+
class He {
|
|
4163
4163
|
/**
|
|
4164
4164
|
* Creates a new anchor context from a set of anchor column specifications
|
|
4165
4165
|
* @param anchors Record of anchor column specifications indexed by anchor ID
|
|
4166
4166
|
*/
|
|
4167
|
-
constructor(
|
|
4167
|
+
constructor(n2) {
|
|
4168
4168
|
l$1(this, "domains", /* @__PURE__ */ new Map());
|
|
4169
4169
|
l$1(this, "axes", /* @__PURE__ */ new Map());
|
|
4170
4170
|
l$1(this, "domainPacks", []);
|
|
4171
4171
|
l$1(this, "domainPackToAnchor", /* @__PURE__ */ new Map());
|
|
4172
|
-
this.anchors =
|
|
4173
|
-
const t = Object.entries(
|
|
4172
|
+
this.anchors = n2;
|
|
4173
|
+
const t = Object.entries(n2);
|
|
4174
4174
|
t.sort((r, o) => r[0].localeCompare(o[0]));
|
|
4175
4175
|
for (const [r, o] of t) {
|
|
4176
|
-
for (let
|
|
4177
|
-
const a = o.axesSpec[
|
|
4178
|
-
this.axes.set(
|
|
4176
|
+
for (let i = 0; i < o.axesSpec.length; i++) {
|
|
4177
|
+
const a = o.axesSpec[i], s2 = P(a);
|
|
4178
|
+
this.axes.set(s2, { anchor: r, idx: i });
|
|
4179
4179
|
}
|
|
4180
4180
|
if (o.domain !== void 0) {
|
|
4181
|
-
const
|
|
4182
|
-
|
|
4183
|
-
for (const [a,
|
|
4184
|
-
const u2 =
|
|
4181
|
+
const i = Object.entries(o.domain);
|
|
4182
|
+
i.sort((a, s2) => a[0].localeCompare(s2[0])), this.domainPackToAnchor.set(JSON.stringify(i), r), this.domainPacks.push(i.map(([a]) => a));
|
|
4183
|
+
for (const [a, s2] of i) {
|
|
4184
|
+
const u2 = E(a, s2);
|
|
4185
4185
|
this.domains.set(u2, r);
|
|
4186
4186
|
}
|
|
4187
4187
|
}
|
|
@@ -4190,57 +4190,57 @@
|
|
|
4190
4190
|
/**
|
|
4191
4191
|
* Implementation of derive method
|
|
4192
4192
|
*/
|
|
4193
|
-
derive(
|
|
4193
|
+
derive(n2, t) {
|
|
4194
4194
|
const r = {
|
|
4195
|
-
name:
|
|
4195
|
+
name: n2.name,
|
|
4196
4196
|
axes: []
|
|
4197
4197
|
};
|
|
4198
4198
|
let o;
|
|
4199
|
-
if (
|
|
4200
|
-
|
|
4199
|
+
if (n2.domain !== void 0)
|
|
4200
|
+
e:
|
|
4201
4201
|
for (const a of this.domainPacks) {
|
|
4202
|
-
const
|
|
4202
|
+
const s2 = [];
|
|
4203
4203
|
for (const c2 of a) {
|
|
4204
|
-
const
|
|
4205
|
-
if (
|
|
4206
|
-
|
|
4204
|
+
const f = n2.domain[c2];
|
|
4205
|
+
if (f !== void 0)
|
|
4206
|
+
s2.push([c2, f]);
|
|
4207
4207
|
else
|
|
4208
|
-
break
|
|
4208
|
+
break e;
|
|
4209
4209
|
}
|
|
4210
|
-
const u2 = this.domainPackToAnchor.get(JSON.stringify(
|
|
4210
|
+
const u2 = this.domainPackToAnchor.get(JSON.stringify(s2));
|
|
4211
4211
|
if (u2 !== void 0) {
|
|
4212
4212
|
r.domainAnchor = u2, o = new Set(a);
|
|
4213
4213
|
break;
|
|
4214
4214
|
}
|
|
4215
4215
|
}
|
|
4216
|
-
for (const [a,
|
|
4216
|
+
for (const [a, s2] of Object.entries(n2.domain ?? {})) {
|
|
4217
4217
|
if (o !== void 0 && o.has(a))
|
|
4218
4218
|
continue;
|
|
4219
|
-
const u2 =
|
|
4220
|
-
r.domain ?? (r.domain = {}), r.domain[a] = c2 ? { anchor: c2 } :
|
|
4219
|
+
const u2 = E(a, s2), c2 = this.domains.get(u2);
|
|
4220
|
+
r.domain ?? (r.domain = {}), r.domain[a] = c2 ? { anchor: c2 } : s2;
|
|
4221
4221
|
}
|
|
4222
|
-
if (r.axes =
|
|
4223
|
-
const
|
|
4224
|
-
return u2 === void 0 ?
|
|
4222
|
+
if (r.axes = n2.axesSpec.map((a) => {
|
|
4223
|
+
const s2 = P(a), u2 = this.axes.get(s2);
|
|
4224
|
+
return u2 === void 0 ? y(a) : u2;
|
|
4225
4225
|
}), !t || t.length === 0)
|
|
4226
4226
|
return r;
|
|
4227
|
-
const
|
|
4227
|
+
const i = [];
|
|
4228
4228
|
for (const a of t) {
|
|
4229
|
-
const [
|
|
4230
|
-
if (typeof
|
|
4231
|
-
if (
|
|
4232
|
-
throw new Error(`Axis index ${
|
|
4233
|
-
|
|
4229
|
+
const [s2, u2] = a;
|
|
4230
|
+
if (typeof s2 == "number") {
|
|
4231
|
+
if (s2 < 0 || s2 >= n2.axesSpec.length)
|
|
4232
|
+
throw new Error(`Axis index ${s2} is out of bounds (0-${n2.axesSpec.length - 1})`);
|
|
4233
|
+
i.push([s2, u2]);
|
|
4234
4234
|
} else {
|
|
4235
|
-
const c2 =
|
|
4235
|
+
const c2 = n2.axesSpec.findIndex((f) => f.name === s2);
|
|
4236
4236
|
if (c2 === -1)
|
|
4237
|
-
throw new Error(`Axis with name "${
|
|
4238
|
-
|
|
4237
|
+
throw new Error(`Axis with name "${s2}" not found in the column specification`);
|
|
4238
|
+
i.push([c2, u2]);
|
|
4239
4239
|
}
|
|
4240
4240
|
}
|
|
4241
|
-
return
|
|
4241
|
+
return i.sort((a, s2) => a[0] - s2[0]), {
|
|
4242
4242
|
source: r,
|
|
4243
|
-
axisFilters:
|
|
4243
|
+
axisFilters: i
|
|
4244
4244
|
};
|
|
4245
4245
|
}
|
|
4246
4246
|
/**
|
|
@@ -4249,58 +4249,58 @@
|
|
|
4249
4249
|
* @param axisFilters Optional axis filters to apply to the column
|
|
4250
4250
|
* @returns A canonicalized string representation of the anchored column identifier
|
|
4251
4251
|
*/
|
|
4252
|
-
deriveS(
|
|
4253
|
-
return
|
|
4252
|
+
deriveS(n2, t) {
|
|
4253
|
+
return te(this.derive(n2, t));
|
|
4254
4254
|
}
|
|
4255
4255
|
}
|
|
4256
|
-
function
|
|
4257
|
-
const r = { ...
|
|
4256
|
+
function We(e, n2, t) {
|
|
4257
|
+
const r = { ...n2 }, o = (t == null ? void 0 : t.ignoreMissingDomains) ?? false;
|
|
4258
4258
|
if (r.domainAnchor !== void 0) {
|
|
4259
|
-
const
|
|
4260
|
-
if (!
|
|
4259
|
+
const i = e[r.domainAnchor];
|
|
4260
|
+
if (!i)
|
|
4261
4261
|
throw new Error(`Anchor "${r.domainAnchor}" not found`);
|
|
4262
|
-
const a =
|
|
4262
|
+
const a = i.domain || {};
|
|
4263
4263
|
r.domain = { ...a, ...r.domain }, delete r.domainAnchor;
|
|
4264
4264
|
}
|
|
4265
4265
|
if (r.domain) {
|
|
4266
|
-
const
|
|
4267
|
-
for (const [a,
|
|
4268
|
-
if (typeof
|
|
4269
|
-
|
|
4266
|
+
const i = {};
|
|
4267
|
+
for (const [a, s2] of Object.entries(r.domain))
|
|
4268
|
+
if (typeof s2 == "string")
|
|
4269
|
+
i[a] = s2;
|
|
4270
4270
|
else {
|
|
4271
|
-
const u2 =
|
|
4271
|
+
const u2 = e[s2.anchor];
|
|
4272
4272
|
if (!u2)
|
|
4273
|
-
throw new Error(`Anchor "${
|
|
4273
|
+
throw new Error(`Anchor "${s2.anchor}" not found for domain key "${a}"`);
|
|
4274
4274
|
if (!u2.domain || u2.domain[a] === void 0) {
|
|
4275
4275
|
if (!o)
|
|
4276
|
-
throw new Error(`Domain key "${a}" not found in anchor "${
|
|
4276
|
+
throw new Error(`Domain key "${a}" not found in anchor "${s2.anchor}"`);
|
|
4277
4277
|
continue;
|
|
4278
4278
|
}
|
|
4279
|
-
|
|
4279
|
+
i[a] = u2.domain[a];
|
|
4280
4280
|
}
|
|
4281
|
-
r.domain =
|
|
4281
|
+
r.domain = i;
|
|
4282
4282
|
}
|
|
4283
|
-
return r.axes && (r.axes = r.axes.map((
|
|
4283
|
+
return r.axes && (r.axes = r.axes.map((i) => re(e, i))), r;
|
|
4284
4284
|
}
|
|
4285
|
-
function
|
|
4286
|
-
if (!
|
|
4287
|
-
return
|
|
4288
|
-
const t =
|
|
4285
|
+
function re(e, n2) {
|
|
4286
|
+
if (!oe$1(n2))
|
|
4287
|
+
return n2;
|
|
4288
|
+
const t = n2.anchor, r = e[t];
|
|
4289
4289
|
if (!r)
|
|
4290
4290
|
throw new Error(`Anchor "${t}" not found for axis reference`);
|
|
4291
|
-
if ("idx" in
|
|
4292
|
-
if (
|
|
4293
|
-
throw new Error(`Axis index ${
|
|
4294
|
-
return r.axesSpec[
|
|
4295
|
-
} else if ("name" in
|
|
4296
|
-
const o = r.axesSpec.filter((
|
|
4291
|
+
if ("idx" in n2) {
|
|
4292
|
+
if (n2.idx < 0 || n2.idx >= r.axesSpec.length)
|
|
4293
|
+
throw new Error(`Axis index ${n2.idx} out of bounds for anchor "${t}"`);
|
|
4294
|
+
return r.axesSpec[n2.idx];
|
|
4295
|
+
} else if ("name" in n2) {
|
|
4296
|
+
const o = r.axesSpec.filter((i) => i.name === n2.name);
|
|
4297
4297
|
if (o.length > 1)
|
|
4298
|
-
throw new Error(`Multiple axes with name "${
|
|
4298
|
+
throw new Error(`Multiple axes with name "${n2.name}" found in anchor "${t}"`);
|
|
4299
4299
|
if (o.length === 0)
|
|
4300
|
-
throw new Error(`Axis with name "${
|
|
4300
|
+
throw new Error(`Axis with name "${n2.name}" not found in anchor "${t}"`);
|
|
4301
4301
|
return o[0];
|
|
4302
|
-
} else if ("id" in
|
|
4303
|
-
const o = r.axesSpec.filter((
|
|
4302
|
+
} else if ("id" in n2) {
|
|
4303
|
+
const o = r.axesSpec.filter((i) => ne$1(n2.id, y(i)));
|
|
4304
4304
|
if (o.length > 1)
|
|
4305
4305
|
throw new Error(`Multiple matching axes found for matcher in anchor "${t}"`);
|
|
4306
4306
|
if (o.length === 0)
|
|
@@ -4309,33 +4309,33 @@
|
|
|
4309
4309
|
}
|
|
4310
4310
|
throw new Error("Unsupported axis reference type");
|
|
4311
4311
|
}
|
|
4312
|
-
function
|
|
4313
|
-
return typeof
|
|
4312
|
+
function oe$1(e) {
|
|
4313
|
+
return typeof e == "object" && "anchor" in e;
|
|
4314
4314
|
}
|
|
4315
|
-
function
|
|
4316
|
-
return
|
|
4315
|
+
function d(e) {
|
|
4316
|
+
return e.kind === "PColumn";
|
|
4317
4317
|
}
|
|
4318
|
-
function
|
|
4319
|
-
return
|
|
4318
|
+
function ie$1(e) {
|
|
4319
|
+
return d(e.spec);
|
|
4320
4320
|
}
|
|
4321
|
-
function
|
|
4322
|
-
if (!
|
|
4323
|
-
return
|
|
4321
|
+
function Ye$1(e) {
|
|
4322
|
+
if (!ie$1(e)) throw new Error(`not a PColumn (kind = ${e.spec.kind})`);
|
|
4323
|
+
return e;
|
|
4324
4324
|
}
|
|
4325
|
-
function
|
|
4326
|
-
return
|
|
4327
|
-
...
|
|
4328
|
-
data: e
|
|
4325
|
+
function Ze(e, n2) {
|
|
4326
|
+
return e === void 0 ? void 0 : {
|
|
4327
|
+
...e,
|
|
4328
|
+
data: n2(e.data)
|
|
4329
4329
|
};
|
|
4330
4330
|
}
|
|
4331
|
-
function
|
|
4332
|
-
const
|
|
4331
|
+
function en(e) {
|
|
4332
|
+
const n2 = /* @__PURE__ */ new Map(), t = (r) => {
|
|
4333
4333
|
switch (r.type) {
|
|
4334
4334
|
case "column":
|
|
4335
|
-
|
|
4335
|
+
n2.set(r.column.id, r.column);
|
|
4336
4336
|
return;
|
|
4337
4337
|
case "slicedColumn":
|
|
4338
|
-
|
|
4338
|
+
n2.set(r.column.id, r.column);
|
|
4339
4339
|
return;
|
|
4340
4340
|
case "inlineColumn":
|
|
4341
4341
|
return;
|
|
@@ -4348,84 +4348,84 @@
|
|
|
4348
4348
|
for (const o of r.secondary) t(o);
|
|
4349
4349
|
return;
|
|
4350
4350
|
default:
|
|
4351
|
-
|
|
4351
|
+
A(r);
|
|
4352
4352
|
}
|
|
4353
4353
|
};
|
|
4354
|
-
return t(
|
|
4354
|
+
return t(e), [...n2.values()];
|
|
4355
4355
|
}
|
|
4356
|
-
function
|
|
4357
|
-
if (
|
|
4356
|
+
function S(e, n2) {
|
|
4357
|
+
if (e.name !== void 0 && e.name !== n2.name)
|
|
4358
4358
|
return false;
|
|
4359
|
-
if (
|
|
4360
|
-
if (Array.isArray(
|
|
4361
|
-
if (!
|
|
4359
|
+
if (e.type !== void 0) {
|
|
4360
|
+
if (Array.isArray(e.type)) {
|
|
4361
|
+
if (!e.type.includes(n2.type))
|
|
4362
4362
|
return false;
|
|
4363
|
-
} else if (
|
|
4363
|
+
} else if (e.type !== n2.type)
|
|
4364
4364
|
return false;
|
|
4365
4365
|
}
|
|
4366
|
-
if (
|
|
4367
|
-
const t =
|
|
4368
|
-
for (const [r, o] of Object.entries(
|
|
4366
|
+
if (e.domain !== void 0) {
|
|
4367
|
+
const t = n2.domain || {};
|
|
4368
|
+
for (const [r, o] of Object.entries(e.domain))
|
|
4369
4369
|
if (t[r] !== o)
|
|
4370
4370
|
return false;
|
|
4371
4371
|
}
|
|
4372
4372
|
return true;
|
|
4373
4373
|
}
|
|
4374
|
-
function
|
|
4375
|
-
if (
|
|
4374
|
+
function v$1(e, n2) {
|
|
4375
|
+
if (n2.name !== void 0 && e.name !== n2.name || n2.namePattern !== void 0 && !new RegExp(n2.namePattern).test(e.name))
|
|
4376
4376
|
return false;
|
|
4377
|
-
if (
|
|
4378
|
-
if (Array.isArray(
|
|
4379
|
-
if (!
|
|
4377
|
+
if (n2.type !== void 0) {
|
|
4378
|
+
if (Array.isArray(n2.type)) {
|
|
4379
|
+
if (!n2.type.includes(e.valueType))
|
|
4380
4380
|
return false;
|
|
4381
|
-
} else if (
|
|
4381
|
+
} else if (n2.type !== e.valueType)
|
|
4382
4382
|
return false;
|
|
4383
4383
|
}
|
|
4384
|
-
if (
|
|
4385
|
-
const t =
|
|
4386
|
-
for (const [r, o] of Object.entries(
|
|
4384
|
+
if (n2.domain !== void 0) {
|
|
4385
|
+
const t = e.domain || {};
|
|
4386
|
+
for (const [r, o] of Object.entries(n2.domain))
|
|
4387
4387
|
if (t[r] !== o)
|
|
4388
4388
|
return false;
|
|
4389
4389
|
}
|
|
4390
|
-
if (
|
|
4391
|
-
const t =
|
|
4392
|
-
if (
|
|
4393
|
-
for (const r of
|
|
4394
|
-
if (!t.some((o) =>
|
|
4390
|
+
if (n2.axes !== void 0) {
|
|
4391
|
+
const t = e.axesSpec.map(y);
|
|
4392
|
+
if (n2.partialAxesMatch) {
|
|
4393
|
+
for (const r of n2.axes)
|
|
4394
|
+
if (!t.some((o) => S(r, o)))
|
|
4395
4395
|
return false;
|
|
4396
4396
|
} else {
|
|
4397
|
-
if (t.length !==
|
|
4397
|
+
if (t.length !== n2.axes.length)
|
|
4398
4398
|
return false;
|
|
4399
|
-
for (let r = 0; r <
|
|
4400
|
-
if (!
|
|
4399
|
+
for (let r = 0; r < n2.axes.length; r++)
|
|
4400
|
+
if (!S(n2.axes[r], t[r]))
|
|
4401
4401
|
return false;
|
|
4402
4402
|
}
|
|
4403
4403
|
}
|
|
4404
|
-
if (
|
|
4405
|
-
const t =
|
|
4406
|
-
for (const [r, o] of Object.entries(
|
|
4404
|
+
if (n2.annotations !== void 0) {
|
|
4405
|
+
const t = e.annotations || {};
|
|
4406
|
+
for (const [r, o] of Object.entries(n2.annotations))
|
|
4407
4407
|
if (t[r] !== o)
|
|
4408
4408
|
return false;
|
|
4409
4409
|
}
|
|
4410
|
-
if (
|
|
4411
|
-
const t =
|
|
4412
|
-
for (const [r, o] of Object.entries(
|
|
4413
|
-
const
|
|
4414
|
-
if (
|
|
4410
|
+
if (n2.annotationPatterns !== void 0) {
|
|
4411
|
+
const t = e.annotations || {};
|
|
4412
|
+
for (const [r, o] of Object.entries(n2.annotationPatterns)) {
|
|
4413
|
+
const i = t[r];
|
|
4414
|
+
if (i === void 0 || !new RegExp(o).test(i))
|
|
4415
4415
|
return false;
|
|
4416
4416
|
}
|
|
4417
4417
|
}
|
|
4418
4418
|
return true;
|
|
4419
4419
|
}
|
|
4420
|
-
function
|
|
4421
|
-
return Array.isArray(
|
|
4420
|
+
function nn(e) {
|
|
4421
|
+
return Array.isArray(e) ? (n2) => e.some((t) => d(n2) && v$1(n2, t)) : (n2) => d(n2) && v$1(n2, e);
|
|
4422
4422
|
}
|
|
4423
|
-
function
|
|
4424
|
-
const
|
|
4425
|
-
kind:
|
|
4426
|
-
name:
|
|
4423
|
+
function tn(e) {
|
|
4424
|
+
const n2 = {
|
|
4425
|
+
kind: e.kind,
|
|
4426
|
+
name: e.name
|
|
4427
4427
|
};
|
|
4428
|
-
return
|
|
4428
|
+
return e.domain !== void 0 && (n2.domain = e.domain), d(e) && (n2.axesSpec = C(e.axesSpec)), Re(n2);
|
|
4429
4429
|
}
|
|
4430
4430
|
z$1.object({
|
|
4431
4431
|
__isRef: z$1.literal(true).describe("Crucial marker for the block dependency tree reconstruction"),
|
|
@@ -4435,25 +4435,25 @@
|
|
|
4435
4435
|
}).describe(
|
|
4436
4436
|
"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."
|
|
4437
4437
|
).readonly();
|
|
4438
|
-
function
|
|
4439
|
-
return typeof
|
|
4438
|
+
function sn(e) {
|
|
4439
|
+
return typeof e == "object" && e !== null && "__isRef" in e && e.__isRef === true && "blockId" in e && "name" in e;
|
|
4440
4440
|
}
|
|
4441
|
-
function
|
|
4442
|
-
if (
|
|
4441
|
+
function un(e, n2 = true) {
|
|
4442
|
+
if (n2)
|
|
4443
4443
|
return {
|
|
4444
|
-
...
|
|
4444
|
+
...e,
|
|
4445
4445
|
requireEnrichments: true
|
|
4446
4446
|
};
|
|
4447
4447
|
{
|
|
4448
|
-
const { requireEnrichments: t, ...r } =
|
|
4448
|
+
const { requireEnrichments: t, ...r } = e;
|
|
4449
4449
|
return r;
|
|
4450
4450
|
}
|
|
4451
4451
|
}
|
|
4452
|
-
function
|
|
4453
|
-
return
|
|
4452
|
+
function fn(e, n2) {
|
|
4453
|
+
return e.ok ? { ok: true, value: n2(e.value) } : e;
|
|
4454
4454
|
}
|
|
4455
|
-
const
|
|
4456
|
-
z$1.string().length(
|
|
4455
|
+
const de = 24;
|
|
4456
|
+
z$1.string().length(de).regex(/[ABCDEFGHIJKLMNOPQRSTUVWXYZ234567]/).brand("PlId");
|
|
4457
4457
|
var stringify = { exports: {} };
|
|
4458
4458
|
var hasRequiredStringify;
|
|
4459
4459
|
function requireStringify() {
|
|
@@ -4513,54 +4513,54 @@
|
|
|
4513
4513
|
cause: z$1.lazy(() => n).optional(),
|
|
4514
4514
|
errors: z$1.lazy(() => n.array()).optional()
|
|
4515
4515
|
});
|
|
4516
|
-
var
|
|
4517
|
-
var
|
|
4518
|
-
var
|
|
4519
|
-
function
|
|
4516
|
+
var ze = Object.defineProperty;
|
|
4517
|
+
var Ye = (t, e, n2) => e in t ? ze(t, e, { enumerable: true, configurable: true, writable: true, value: n2 }) : t[e] = n2;
|
|
4518
|
+
var k = (t, e, n2) => Ye(t, typeof e != "symbol" ? e + "" : e, n2);
|
|
4519
|
+
function ne(t) {
|
|
4520
4520
|
return { type: "Immediate", value: t };
|
|
4521
4521
|
}
|
|
4522
|
-
function
|
|
4522
|
+
function ht() {
|
|
4523
4523
|
return typeof globalThis.getPlatforma < "u" || typeof globalThis.platforma < "u";
|
|
4524
4524
|
}
|
|
4525
|
-
function
|
|
4525
|
+
function Ne(t) {
|
|
4526
4526
|
if (t && typeof globalThis.getPlatforma == "function")
|
|
4527
4527
|
return globalThis.getPlatforma(t);
|
|
4528
4528
|
if (typeof globalThis.platforma < "u") return globalThis.platforma;
|
|
4529
4529
|
throw new Error("Can't get platforma instance.");
|
|
4530
4530
|
}
|
|
4531
|
-
function
|
|
4531
|
+
function gt() {
|
|
4532
4532
|
if (typeof globalThis.cfgRenderCtx < "u") return globalThis.cfgRenderCtx;
|
|
4533
4533
|
}
|
|
4534
4534
|
function v() {
|
|
4535
4535
|
if (typeof globalThis.cfgRenderCtx < "u") return globalThis.cfgRenderCtx;
|
|
4536
4536
|
throw new Error("Not in config rendering context");
|
|
4537
4537
|
}
|
|
4538
|
-
function
|
|
4539
|
-
const n2 =
|
|
4538
|
+
function G(t, e) {
|
|
4539
|
+
const n2 = gt();
|
|
4540
4540
|
if (n2 === void 0) return false;
|
|
4541
4541
|
if (t in n2.callbackRegistry) throw new Error(`Callback with key ${t} already registered.`);
|
|
4542
4542
|
return n2.callbackRegistry[t] = e, true;
|
|
4543
4543
|
}
|
|
4544
|
-
const
|
|
4545
|
-
function
|
|
4544
|
+
const ue = /* @__PURE__ */ new Map();
|
|
4545
|
+
function mt(t, e) {
|
|
4546
4546
|
t in v().callbackRegistry || (v().callbackRegistry[t] = (n2) => {
|
|
4547
|
-
for (const r of
|
|
4547
|
+
for (const r of ue.get(t))
|
|
4548
4548
|
r(n2);
|
|
4549
|
-
},
|
|
4549
|
+
}, ue.set(t, [])), ue.get(t).push(e);
|
|
4550
4550
|
}
|
|
4551
|
-
class
|
|
4551
|
+
class F {
|
|
4552
4552
|
constructor(e, n2 = (r) => r) {
|
|
4553
|
-
|
|
4554
|
-
|
|
4555
|
-
this.handle = e, this.postProcess = n2,
|
|
4553
|
+
k(this, "isResolved", false);
|
|
4554
|
+
k(this, "resolvedValue");
|
|
4555
|
+
this.handle = e, this.postProcess = n2, mt(e, (r) => {
|
|
4556
4556
|
this.resolvedValue = n2(r), this.isResolved = true;
|
|
4557
4557
|
});
|
|
4558
4558
|
}
|
|
4559
4559
|
map(e) {
|
|
4560
|
-
return new
|
|
4560
|
+
return new F(this.handle, (n2) => e(this.postProcess(n2)));
|
|
4561
4561
|
}
|
|
4562
4562
|
mapDefined(e) {
|
|
4563
|
-
return new
|
|
4563
|
+
return new F(this.handle, (n2) => {
|
|
4564
4564
|
const r = this.postProcess(n2);
|
|
4565
4565
|
return r ? e(r) : void 0;
|
|
4566
4566
|
});
|
|
@@ -4569,7 +4569,7 @@
|
|
|
4569
4569
|
return this.isResolved ? this.resolvedValue : { __awaited_futures__: [this.handle] };
|
|
4570
4570
|
}
|
|
4571
4571
|
}
|
|
4572
|
-
function
|
|
4572
|
+
function fe(t, e) {
|
|
4573
4573
|
return t === void 0 ? void 0 : e(t);
|
|
4574
4574
|
}
|
|
4575
4575
|
class D {
|
|
@@ -4611,7 +4611,7 @@
|
|
|
4611
4611
|
...this.resolvePath,
|
|
4612
4612
|
...n2.map((i) => typeof i == "string" ? i : i.field)
|
|
4613
4613
|
];
|
|
4614
|
-
return
|
|
4614
|
+
return fe(
|
|
4615
4615
|
v().resolveWithCommon(this.handle, e, ...n2),
|
|
4616
4616
|
(i) => new D(i, r)
|
|
4617
4617
|
);
|
|
@@ -4633,7 +4633,7 @@
|
|
|
4633
4633
|
}
|
|
4634
4634
|
getError() {
|
|
4635
4635
|
const e = [...this.resolvePath, "error"];
|
|
4636
|
-
return
|
|
4636
|
+
return fe(
|
|
4637
4637
|
v().getError(this.handle),
|
|
4638
4638
|
(n2) => new D(n2, e)
|
|
4639
4639
|
);
|
|
@@ -4675,7 +4675,7 @@
|
|
|
4675
4675
|
getPColumns(e = false, n2 = "") {
|
|
4676
4676
|
const r = this.parsePObjectCollection(e, n2);
|
|
4677
4677
|
return r === void 0 ? void 0 : Object.entries(r).map(([, s2]) => {
|
|
4678
|
-
if (!
|
|
4678
|
+
if (!ie$1(s2)) throw new Error(`not a PColumn (kind = ${s2.spec.kind})`);
|
|
4679
4679
|
return s2;
|
|
4680
4680
|
});
|
|
4681
4681
|
}
|
|
@@ -4693,18 +4693,18 @@
|
|
|
4693
4693
|
const i = {};
|
|
4694
4694
|
for (const [s2, o] of Object.entries(r)) {
|
|
4695
4695
|
const a = [...this.resolvePath, s2];
|
|
4696
|
-
i[s2] =
|
|
4696
|
+
i[s2] = Ze(o, (l2) => new D(l2, a));
|
|
4697
4697
|
}
|
|
4698
4698
|
return i;
|
|
4699
4699
|
}
|
|
4700
4700
|
getFileContentAsBase64(e) {
|
|
4701
|
-
return new
|
|
4701
|
+
return new F(v().getBlobContentAsBase64(this.handle, e));
|
|
4702
4702
|
}
|
|
4703
4703
|
getFileContentAsString(e) {
|
|
4704
|
-
return new
|
|
4704
|
+
return new F(v().getBlobContentAsString(this.handle, e));
|
|
4705
4705
|
}
|
|
4706
4706
|
getFileContentAsJson(e) {
|
|
4707
|
-
return new
|
|
4707
|
+
return new F(
|
|
4708
4708
|
v().getBlobContentAsString(this.handle, e)
|
|
4709
4709
|
).mapDefined((n2) => JSON.parse(n2));
|
|
4710
4710
|
}
|
|
@@ -4724,7 +4724,7 @@
|
|
|
4724
4724
|
* @returns downloaded file handle
|
|
4725
4725
|
*/
|
|
4726
4726
|
getFileHandle() {
|
|
4727
|
-
return new
|
|
4727
|
+
return new F(v().getDownloadedBlobContentHandle(this.handle));
|
|
4728
4728
|
}
|
|
4729
4729
|
/**
|
|
4730
4730
|
* @deprecated use getFileHandle
|
|
@@ -4736,7 +4736,7 @@
|
|
|
4736
4736
|
* @returns downloaded file handle
|
|
4737
4737
|
*/
|
|
4738
4738
|
getRemoteFileHandle() {
|
|
4739
|
-
return new
|
|
4739
|
+
return new F(v().getOnDemandBlobContentHandle(this.handle));
|
|
4740
4740
|
}
|
|
4741
4741
|
/**
|
|
4742
4742
|
* @deprecated use getRemoteFileHandle
|
|
@@ -4748,22 +4748,22 @@
|
|
|
4748
4748
|
* @returns the url to the extracted folder
|
|
4749
4749
|
*/
|
|
4750
4750
|
extractArchiveAndGetURL(e) {
|
|
4751
|
-
return new
|
|
4751
|
+
return new F(v().extractArchiveAndGetURL(this.handle, e));
|
|
4752
4752
|
}
|
|
4753
4753
|
getImportProgress() {
|
|
4754
|
-
return new
|
|
4754
|
+
return new F(v().getImportProgress(this.handle));
|
|
4755
4755
|
}
|
|
4756
4756
|
getLastLogs(e) {
|
|
4757
|
-
return new
|
|
4757
|
+
return new F(v().getLastLogs(this.handle, e));
|
|
4758
4758
|
}
|
|
4759
4759
|
getProgressLog(e) {
|
|
4760
|
-
return new
|
|
4760
|
+
return new F(v().getProgressLog(this.handle, e));
|
|
4761
4761
|
}
|
|
4762
4762
|
getProgressLogWithInfo(e) {
|
|
4763
|
-
return new
|
|
4763
|
+
return new F(v().getProgressLogWithInfo(this.handle, e));
|
|
4764
4764
|
}
|
|
4765
4765
|
getLogHandle() {
|
|
4766
|
-
return new
|
|
4766
|
+
return new F(v().getLogHandle(this.handle));
|
|
4767
4767
|
}
|
|
4768
4768
|
allFieldsResolved(e = "Input") {
|
|
4769
4769
|
switch (e) {
|
|
@@ -4789,135 +4789,135 @@
|
|
|
4789
4789
|
let l2 = (r === "Input" ? this.listInputFields() : r === "Output" ? this.listOutputFields() : this.listDynamicFields()).map(
|
|
4790
4790
|
(u2) => [u2, this.resolve({ field: u2, assertFieldType: r })]
|
|
4791
4791
|
);
|
|
4792
|
-
return s2 && (l2 = l2.filter((u2) => u2[1] !== void 0)), l2.map(([u2,
|
|
4792
|
+
return s2 && (l2 = l2.filter((u2) => u2[1] !== void 0)), l2.map(([u2, h]) => o(u2, h));
|
|
4793
4793
|
}
|
|
4794
4794
|
}
|
|
4795
|
-
const
|
|
4796
|
-
const
|
|
4795
|
+
const Ve = "staging", je = "main";
|
|
4796
|
+
const vt = "pl7.app/label", St = "pl7.app/trace", Ct = z$1.object({
|
|
4797
4797
|
type: z$1.string(),
|
|
4798
4798
|
importance: z$1.number().optional(),
|
|
4799
4799
|
id: z$1.string().optional(),
|
|
4800
4800
|
label: z$1.string()
|
|
4801
|
-
}), wt = z$1.array(
|
|
4802
|
-
function
|
|
4801
|
+
}), wt = z$1.array(Ct), At = 1e-3, Pt = "__LABEL__", _e = "__LABEL__@1";
|
|
4802
|
+
function Me(t, e, n2 = {}) {
|
|
4803
4803
|
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((p2) => {
|
|
4804
4804
|
var c2, m2;
|
|
4805
4805
|
const b = e(p2);
|
|
4806
|
-
let
|
|
4807
|
-
"spec" in b && typeof b.spec == "object" ? (
|
|
4808
|
-
const E2 = (c2 =
|
|
4809
|
-
...
|
|
4810
|
-
...
|
|
4811
|
-
...
|
|
4806
|
+
let d2, y2, S2;
|
|
4807
|
+
"spec" in b && typeof b.spec == "object" ? (d2 = b.spec, y2 = b.prefixTrace, S2 = b.suffixTrace) : d2 = b;
|
|
4808
|
+
const E2 = (c2 = d2.annotations) == null ? void 0 : c2[vt], _2 = (m2 = d2.annotations) == null ? void 0 : m2[St], w = (_2 ? wt.safeParse(JSON.parse(_2)).data : void 0) ?? [], A2 = [
|
|
4809
|
+
...y2 ?? [],
|
|
4810
|
+
...w,
|
|
4811
|
+
...S2 ?? []
|
|
4812
4812
|
];
|
|
4813
4813
|
if (E2 !== void 0) {
|
|
4814
|
-
const
|
|
4815
|
-
n2.addLabelAsSuffix ?
|
|
4816
|
-
}
|
|
4817
|
-
const
|
|
4818
|
-
for (let
|
|
4819
|
-
const { type:
|
|
4820
|
-
I.set(
|
|
4821
|
-
const
|
|
4822
|
-
s2.set(
|
|
4823
|
-
|
|
4814
|
+
const T = { label: E2, type: Pt, importance: -2 };
|
|
4815
|
+
n2.addLabelAsSuffix ? A2.push(T) : A2.splice(0, 0, T);
|
|
4816
|
+
}
|
|
4817
|
+
const C2 = [], I = /* @__PURE__ */ new Map();
|
|
4818
|
+
for (let T = A2.length - 1; T >= 0; --T) {
|
|
4819
|
+
const { type: U } = A2[T], V = A2[T].importance ?? 0, J = (I.get(U) ?? 0) + 1;
|
|
4820
|
+
I.set(U, J);
|
|
4821
|
+
const K = `${U}@${J}`;
|
|
4822
|
+
s2.set(K, (s2.get(K) ?? 0) + 1), r.set(
|
|
4823
|
+
K,
|
|
4824
4824
|
Math.max(
|
|
4825
|
-
r.get(
|
|
4826
|
-
|
|
4825
|
+
r.get(K) ?? Number.NEGATIVE_INFINITY,
|
|
4826
|
+
V - (A2.length - T) * At
|
|
4827
4827
|
)
|
|
4828
|
-
),
|
|
4828
|
+
), C2.push({ ...A2[T], fullType: K, occurrenceIndex: J });
|
|
4829
4829
|
}
|
|
4830
|
-
return
|
|
4830
|
+
return C2.reverse(), {
|
|
4831
4831
|
value: p2,
|
|
4832
|
-
spec:
|
|
4832
|
+
spec: d2,
|
|
4833
4833
|
label: E2,
|
|
4834
|
-
fullTrace:
|
|
4834
|
+
fullTrace: C2
|
|
4835
4835
|
};
|
|
4836
4836
|
}), a = [], l2 = [], u2 = [...r];
|
|
4837
4837
|
u2.sort(([, p2], [, b]) => b - p2);
|
|
4838
4838
|
for (const [p2] of u2)
|
|
4839
4839
|
p2.endsWith("@1") || s2.get(p2) === t.length ? a.push(p2) : l2.push(p2);
|
|
4840
|
-
const
|
|
4841
|
-
const
|
|
4842
|
-
for (let
|
|
4843
|
-
const
|
|
4840
|
+
const h = (p2, b = false) => {
|
|
4841
|
+
const d2 = [];
|
|
4842
|
+
for (let y2 = 0; y2 < o.length; y2++) {
|
|
4843
|
+
const S2 = o[y2], E2 = S2.fullTrace.filter((A2) => p2.has(A2.fullType) || i && i.has(A2.type));
|
|
4844
4844
|
if (E2.length === 0)
|
|
4845
4845
|
if (b)
|
|
4846
|
-
|
|
4846
|
+
d2.push({
|
|
4847
4847
|
label: "Unlabeled",
|
|
4848
|
-
value:
|
|
4848
|
+
value: S2.value
|
|
4849
4849
|
});
|
|
4850
4850
|
else return;
|
|
4851
|
-
const
|
|
4852
|
-
|
|
4853
|
-
label:
|
|
4854
|
-
value:
|
|
4851
|
+
const _2 = E2.map((A2) => A2.label), w = n2.separator ?? " / ";
|
|
4852
|
+
d2.push({
|
|
4853
|
+
label: _2.join(w),
|
|
4854
|
+
value: S2.value
|
|
4855
4855
|
});
|
|
4856
4856
|
}
|
|
4857
|
-
return
|
|
4857
|
+
return d2;
|
|
4858
4858
|
};
|
|
4859
4859
|
if (a.length === 0) {
|
|
4860
4860
|
if (l2.length !== 0) throw new Error("Non-empty secondary types list while main types list is empty.");
|
|
4861
|
-
return
|
|
4861
|
+
return h(new Set(_e), true);
|
|
4862
4862
|
}
|
|
4863
|
-
let
|
|
4864
|
-
for (;
|
|
4863
|
+
let f = 0, g2 = -1;
|
|
4864
|
+
for (; f < a.length; ) {
|
|
4865
4865
|
const p2 = /* @__PURE__ */ new Set();
|
|
4866
|
-
n2.includeNativeLabel && p2.add(
|
|
4867
|
-
for (let
|
|
4868
|
-
|
|
4869
|
-
const b =
|
|
4870
|
-
if (b !== void 0 && new Set(b.map((
|
|
4871
|
-
|
|
4872
|
-
}
|
|
4873
|
-
return
|
|
4866
|
+
n2.includeNativeLabel && p2.add(_e);
|
|
4867
|
+
for (let d2 = 0; d2 < f; ++d2) p2.add(a[d2]);
|
|
4868
|
+
g2 >= 0 && p2.add(a[g2]);
|
|
4869
|
+
const b = h(p2);
|
|
4870
|
+
if (b !== void 0 && new Set(b.map((d2) => d2.label)).size === t.length) return b;
|
|
4871
|
+
g2++, g2 >= a.length && (f++, g2 = f);
|
|
4872
|
+
}
|
|
4873
|
+
return h(/* @__PURE__ */ new Set([...a, ...l2]), true);
|
|
4874
4874
|
}
|
|
4875
|
-
const
|
|
4876
|
-
const
|
|
4875
|
+
const Q = "PColumnData/", ie = Q + "ResourceMap", se = Q + "Partitioned/ResourceMap", H = Q + "JsonPartitioned", B = Q + "BinaryPartitioned", $e = Q + "Partitioned/", oe = $e + "JsonPartitioned", q = $e + "BinaryPartitioned";
|
|
4876
|
+
const ge = (t) => {
|
|
4877
4877
|
if (t.endsWith(".index"))
|
|
4878
4878
|
return { baseKey: t.substring(0, t.length - 6), type: "index" };
|
|
4879
4879
|
if (t.endsWith(".values"))
|
|
4880
4880
|
return { baseKey: t.substring(0, t.length - 7), type: "values" };
|
|
4881
4881
|
throw new Error(`key must ends on .index/.values for binary p-column, got: ${t}`);
|
|
4882
4882
|
};
|
|
4883
|
-
function
|
|
4883
|
+
function xt(t) {
|
|
4884
4884
|
if (!t) return;
|
|
4885
4885
|
const e = t.resourceType.name, n2 = t.getDataAsJson(), r = [];
|
|
4886
4886
|
let i = 0;
|
|
4887
4887
|
switch (e) {
|
|
4888
|
-
case
|
|
4888
|
+
case ie:
|
|
4889
4889
|
i = n2.keyLength;
|
|
4890
4890
|
break;
|
|
4891
|
-
case
|
|
4891
|
+
case se:
|
|
4892
4892
|
i = n2.partitionKeyLength + n2.keyLength;
|
|
4893
4893
|
break;
|
|
4894
|
-
case
|
|
4894
|
+
case H:
|
|
4895
4895
|
case B:
|
|
4896
4896
|
i = n2.partitionKeyLength;
|
|
4897
4897
|
break;
|
|
4898
|
-
case
|
|
4899
|
-
case
|
|
4898
|
+
case q:
|
|
4899
|
+
case oe:
|
|
4900
4900
|
i = n2.superPartitionKeyLength + n2.partitionKeyLength;
|
|
4901
4901
|
break;
|
|
4902
4902
|
}
|
|
4903
4903
|
switch (e) {
|
|
4904
|
-
case
|
|
4905
|
-
case
|
|
4904
|
+
case ie:
|
|
4905
|
+
case H:
|
|
4906
4906
|
case B:
|
|
4907
4907
|
for (let s2 of t.listInputFields()) {
|
|
4908
|
-
e === B && (s2 =
|
|
4908
|
+
e === B && (s2 = ge(s2).baseKey);
|
|
4909
4909
|
const o = [...JSON.parse(s2)];
|
|
4910
4910
|
r.push(o);
|
|
4911
4911
|
}
|
|
4912
4912
|
break;
|
|
4913
|
+
case se:
|
|
4914
|
+
case q:
|
|
4913
4915
|
case oe:
|
|
4914
|
-
case z:
|
|
4915
|
-
case ae:
|
|
4916
4916
|
for (const s2 of t.listInputFields()) {
|
|
4917
4917
|
const o = [...JSON.parse(s2)], a = t.resolve({ field: s2, assertFieldType: "Input" });
|
|
4918
4918
|
if (a !== void 0)
|
|
4919
4919
|
for (let l2 of a.listInputFields()) {
|
|
4920
|
-
e ===
|
|
4920
|
+
e === q && (l2 = ge(l2).baseKey);
|
|
4921
4921
|
const u2 = [...o, ...JSON.parse(l2)];
|
|
4922
4922
|
r.push(u2);
|
|
4923
4923
|
}
|
|
@@ -4926,7 +4926,7 @@
|
|
|
4926
4926
|
}
|
|
4927
4927
|
return { data: r, keyLength: i };
|
|
4928
4928
|
}
|
|
4929
|
-
function
|
|
4929
|
+
function _t(t) {
|
|
4930
4930
|
if (t.type !== "JsonPartitioned" && t.type !== "BinaryPartitioned")
|
|
4931
4931
|
throw new Error(`Splitting requires Partitioned DataInfoEntries, got ${t.type}`);
|
|
4932
4932
|
const { parts: e, partitionKeyLength: n2 } = t, r = [];
|
|
@@ -4945,11 +4945,11 @@
|
|
|
4945
4945
|
}
|
|
4946
4946
|
return r.map((i) => Array.from(i.values()));
|
|
4947
4947
|
}
|
|
4948
|
-
function
|
|
4948
|
+
function It(t) {
|
|
4949
4949
|
if (t === void 0) return;
|
|
4950
|
-
if (
|
|
4951
|
-
return
|
|
4952
|
-
const e =
|
|
4950
|
+
if (_(t))
|
|
4951
|
+
return _t(t);
|
|
4952
|
+
const e = xt(t);
|
|
4953
4953
|
if (!e) return;
|
|
4954
4954
|
const { data: n2, keyLength: r } = e, i = [];
|
|
4955
4955
|
for (let s2 = 0; s2 < r; ++s2)
|
|
@@ -4962,16 +4962,16 @@
|
|
|
4962
4962
|
}
|
|
4963
4963
|
return i.map((s2) => Array.from(s2.values()));
|
|
4964
4964
|
}
|
|
4965
|
-
function
|
|
4965
|
+
function me(t, e = []) {
|
|
4966
4966
|
if (t === void 0 || !t.getIsReadyOrError()) return;
|
|
4967
4967
|
const n2 = t.resourceType.name, r = t.getDataAsJson();
|
|
4968
|
-
if (e.length > 0 && (n2 ===
|
|
4968
|
+
if (e.length > 0 && (n2 === oe || n2 === q))
|
|
4969
4969
|
throw new Error(`Unexpected nested super-partitioned resource: ${n2}`);
|
|
4970
4970
|
switch (n2) {
|
|
4971
|
+
case ie:
|
|
4971
4972
|
case se:
|
|
4972
|
-
case oe:
|
|
4973
4973
|
throw new Error(`Only data columns are supported, got: ${n2}`);
|
|
4974
|
-
case
|
|
4974
|
+
case H: {
|
|
4975
4975
|
if (typeof (r == null ? void 0 : r.partitionKeyLength) != "number")
|
|
4976
4976
|
throw new Error(`Missing partitionKeyLength in metadata for ${n2}`);
|
|
4977
4977
|
const i = [];
|
|
@@ -4992,7 +4992,7 @@
|
|
|
4992
4992
|
throw new Error(`Missing partitionKeyLength in metadata for ${n2}`);
|
|
4993
4993
|
const i = [], s2 = /* @__PURE__ */ new Map();
|
|
4994
4994
|
for (const o of t.listInputFields()) {
|
|
4995
|
-
const a =
|
|
4995
|
+
const a = ge(o), l2 = t.resolve({ field: o, assertFieldType: "Input" });
|
|
4996
4996
|
if (l2 === void 0) return;
|
|
4997
4997
|
let u2 = s2.get(a.baseKey);
|
|
4998
4998
|
u2 || (u2 = {}, s2.set(a.baseKey, u2)), a.type === "index" ? u2.index = l2 : u2.values = l2;
|
|
@@ -5014,16 +5014,16 @@
|
|
|
5014
5014
|
parts: i
|
|
5015
5015
|
};
|
|
5016
5016
|
}
|
|
5017
|
-
case
|
|
5017
|
+
case oe: {
|
|
5018
5018
|
if (typeof (r == null ? void 0 : r.superPartitionKeyLength) != "number" || typeof (r == null ? void 0 : r.partitionKeyLength) != "number")
|
|
5019
5019
|
throw new Error(`Missing superPartitionKeyLength or partitionKeyLength in metadata for ${n2}`);
|
|
5020
5020
|
const i = r.superPartitionKeyLength + r.partitionKeyLength, s2 = [];
|
|
5021
5021
|
for (const o of t.listInputFields()) {
|
|
5022
5022
|
const a = t.resolve({ field: o, assertFieldType: "Input" });
|
|
5023
5023
|
if (a === void 0) return;
|
|
5024
|
-
if (a.resourceType.name !==
|
|
5025
|
-
throw new Error(`Expected ${
|
|
5026
|
-
const l2 =
|
|
5024
|
+
if (a.resourceType.name !== H)
|
|
5025
|
+
throw new Error(`Expected ${H} inside ${n2}, but got ${a.resourceType.name}`);
|
|
5026
|
+
const l2 = me(a, JSON.parse(o));
|
|
5027
5027
|
if (l2 === void 0) return;
|
|
5028
5028
|
if (l2.type !== "JsonPartitioned")
|
|
5029
5029
|
throw new Error(`Unexpected inner result type for ${n2}: ${l2.type}`);
|
|
@@ -5035,7 +5035,7 @@
|
|
|
5035
5035
|
parts: s2
|
|
5036
5036
|
};
|
|
5037
5037
|
}
|
|
5038
|
-
case
|
|
5038
|
+
case q: {
|
|
5039
5039
|
if (typeof (r == null ? void 0 : r.superPartitionKeyLength) != "number" || typeof (r == null ? void 0 : r.partitionKeyLength) != "number")
|
|
5040
5040
|
throw new Error(`Missing superPartitionKeyLength or partitionKeyLength in metadata for ${n2}`);
|
|
5041
5041
|
const i = r.superPartitionKeyLength + r.partitionKeyLength, s2 = [];
|
|
@@ -5044,7 +5044,7 @@
|
|
|
5044
5044
|
if (a === void 0) return;
|
|
5045
5045
|
if (a.resourceType.name !== B)
|
|
5046
5046
|
throw new Error(`Expected ${B} inside ${n2}, but got ${a.resourceType.name}`);
|
|
5047
|
-
const l2 =
|
|
5047
|
+
const l2 = me(a, JSON.parse(o));
|
|
5048
5048
|
if (l2 === void 0) return;
|
|
5049
5049
|
if (l2.type !== "BinaryPartitioned")
|
|
5050
5050
|
throw new Error(`Unexpected inner result type for ${n2}: ${l2.type}`);
|
|
@@ -5060,15 +5060,15 @@
|
|
|
5060
5060
|
throw new Error(`Unknown resource type: ${n2}`);
|
|
5061
5061
|
}
|
|
5062
5062
|
}
|
|
5063
|
-
function
|
|
5063
|
+
function Tt(t) {
|
|
5064
5064
|
if (t !== void 0) {
|
|
5065
|
-
if (
|
|
5066
|
-
if (
|
|
5067
|
-
if (t instanceof D) return
|
|
5065
|
+
if (_(t)) return t;
|
|
5066
|
+
if (Oe(t)) return Ve$1(t);
|
|
5067
|
+
if (t instanceof D) return me(t);
|
|
5068
5068
|
throw new Error(`Unexpected input type: ${typeof t}`);
|
|
5069
5069
|
}
|
|
5070
5070
|
}
|
|
5071
|
-
function
|
|
5071
|
+
function Lt(t, e) {
|
|
5072
5072
|
const n2 = [...e].sort((s2, o) => o[0] - s2[0]);
|
|
5073
5073
|
if (t.type === "JsonPartitioned" || t.type === "BinaryPartitioned") {
|
|
5074
5074
|
const { partitionKeyLength: s2 } = t;
|
|
@@ -5128,45 +5128,45 @@
|
|
|
5128
5128
|
}
|
|
5129
5129
|
}
|
|
5130
5130
|
}
|
|
5131
|
-
function
|
|
5131
|
+
function Ft(t) {
|
|
5132
5132
|
if (!Array.isArray(t)) return false;
|
|
5133
5133
|
if (t.length === 0) return true;
|
|
5134
5134
|
const e = t[0];
|
|
5135
5135
|
return typeof e == "object" && e !== null && "key" in e && "val" in e;
|
|
5136
5136
|
}
|
|
5137
|
-
class
|
|
5137
|
+
class Et {
|
|
5138
5138
|
constructor(e) {
|
|
5139
5139
|
this.columns = e;
|
|
5140
5140
|
}
|
|
5141
5141
|
selectColumns(e) {
|
|
5142
|
-
const n2 = typeof e == "function" ? e :
|
|
5142
|
+
const n2 = typeof e == "function" ? e : nn(e);
|
|
5143
5143
|
return this.columns.filter((r) => n2(r.spec));
|
|
5144
5144
|
}
|
|
5145
5145
|
}
|
|
5146
|
-
function
|
|
5146
|
+
function kt(t) {
|
|
5147
5147
|
if (t)
|
|
5148
5148
|
return t.map((e) => ({
|
|
5149
|
-
type: `split:${
|
|
5149
|
+
type: `split:${_e$1(e.axisId)}`,
|
|
5150
5150
|
label: e.label,
|
|
5151
5151
|
importance: 1e6
|
|
5152
5152
|
// High importance for split filters in labels
|
|
5153
5153
|
}));
|
|
5154
5154
|
}
|
|
5155
|
-
function
|
|
5155
|
+
function Dt(t) {
|
|
5156
5156
|
if (t)
|
|
5157
5157
|
return t.map((e) => [e.axisIdx, e.value]);
|
|
5158
5158
|
}
|
|
5159
|
-
function
|
|
5159
|
+
function Ot(t, e) {
|
|
5160
5160
|
if (!e || e.length === 0) return t;
|
|
5161
5161
|
const n2 = [...e].sort((r, i) => r[0] - i[0]);
|
|
5162
|
-
return
|
|
5162
|
+
return Re({ id: t, axisFilters: n2 });
|
|
5163
5163
|
}
|
|
5164
|
-
function
|
|
5164
|
+
function Ie(t) {
|
|
5165
5165
|
if (!t || typeof t != "object") return false;
|
|
5166
5166
|
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);
|
|
5167
5167
|
return !!e.domainAnchor || n2 || r;
|
|
5168
5168
|
}
|
|
5169
|
-
function
|
|
5169
|
+
function Rt(t) {
|
|
5170
5170
|
if (typeof t != "object" || !("axes" in t) || t.axes === void 0)
|
|
5171
5171
|
return [];
|
|
5172
5172
|
const e = t.axes.map((n2, r) => typeof n2 == "object" && "split" in n2 && n2.split === true ? r : -1).filter((n2) => n2 !== -1);
|
|
@@ -5174,11 +5174,11 @@
|
|
|
5174
5174
|
throw new Error("Axis splitting is not supported when `partialAxesMatch` is defined.");
|
|
5175
5175
|
return e.sort((n2, r) => n2 - r), e;
|
|
5176
5176
|
}
|
|
5177
|
-
class
|
|
5177
|
+
class ae {
|
|
5178
5178
|
constructor() {
|
|
5179
|
-
|
|
5180
|
-
|
|
5181
|
-
|
|
5179
|
+
k(this, "defaultProviderStore", []);
|
|
5180
|
+
k(this, "providers", [new Et(this.defaultProviderStore)]);
|
|
5181
|
+
k(this, "axisLabelProviders", []);
|
|
5182
5182
|
}
|
|
5183
5183
|
addColumnProvider(e) {
|
|
5184
5184
|
return this.providers.push(e), this;
|
|
@@ -5206,126 +5206,126 @@
|
|
|
5206
5206
|
};
|
|
5207
5207
|
let u2 = () => false;
|
|
5208
5208
|
if (a) {
|
|
5209
|
-
const
|
|
5210
|
-
if (
|
|
5209
|
+
const d2 = (Array.isArray(a) ? a : [a]).map((y2) => {
|
|
5210
|
+
if (Ie(y2)) {
|
|
5211
5211
|
if (!r)
|
|
5212
5212
|
throw new Error("Anchored selectors in exclude require an AnchoredIdDeriver to be provided in options.");
|
|
5213
|
-
return
|
|
5213
|
+
return nn(We(r.anchors, y2, n2));
|
|
5214
5214
|
} else
|
|
5215
|
-
return
|
|
5215
|
+
return nn(y2);
|
|
5216
5216
|
});
|
|
5217
|
-
u2 = (
|
|
5217
|
+
u2 = (y2) => d2.some((S2) => S2(y2));
|
|
5218
5218
|
}
|
|
5219
|
-
const
|
|
5220
|
-
for (const
|
|
5221
|
-
const y =
|
|
5222
|
-
let
|
|
5223
|
-
if (y) {
|
|
5219
|
+
const h = typeof e == "function" ? [e] : Array.isArray(e) ? e : [e], f = [], g2 = /* @__PURE__ */ new Set();
|
|
5220
|
+
for (const d$1 of h) {
|
|
5221
|
+
const y$1 = Ie(d$1);
|
|
5222
|
+
let S2;
|
|
5223
|
+
if (y$1) {
|
|
5224
5224
|
if (!r)
|
|
5225
5225
|
throw new Error("Anchored selectors require an AnchoredIdDeriver to be provided in options.");
|
|
5226
|
-
|
|
5226
|
+
S2 = We(r.anchors, d$1, n2);
|
|
5227
5227
|
} else
|
|
5228
|
-
|
|
5229
|
-
const E2 = /* @__PURE__ */ new Set(),
|
|
5230
|
-
for (const
|
|
5231
|
-
const I =
|
|
5228
|
+
S2 = d$1;
|
|
5229
|
+
const E2 = /* @__PURE__ */ new Set(), _2 = [];
|
|
5230
|
+
for (const C2 of this.providers) {
|
|
5231
|
+
const I = C2.selectColumns(S2);
|
|
5232
5232
|
for (const c2 of I) {
|
|
5233
5233
|
if (u2(c2.spec)) continue;
|
|
5234
5234
|
if (E2.has(c2.id))
|
|
5235
|
-
throw new Error(`Duplicate column id ${c2.id} in provider ${
|
|
5236
|
-
const m2 =
|
|
5237
|
-
|
|
5235
|
+
throw new Error(`Duplicate column id ${c2.id} in provider ${C2.constructor.name}`);
|
|
5236
|
+
const m2 = tn(c2.spec);
|
|
5237
|
+
g2.has(m2) || (E2.add(c2.id), g2.add(m2), _2.push(c2));
|
|
5238
5238
|
}
|
|
5239
5239
|
}
|
|
5240
|
-
if (
|
|
5241
|
-
const
|
|
5242
|
-
for (const
|
|
5243
|
-
if (!
|
|
5244
|
-
const I =
|
|
5245
|
-
if (
|
|
5246
|
-
if (
|
|
5247
|
-
throw new Error(`Splitting is not supported for PColumns with PColumnValues data format. Column id: ${
|
|
5248
|
-
const c2 =
|
|
5240
|
+
if (_2.length === 0) continue;
|
|
5241
|
+
const w = Rt(d$1), A2 = w.length > 0;
|
|
5242
|
+
for (const C2 of _2) {
|
|
5243
|
+
if (!d(C2.spec)) continue;
|
|
5244
|
+
const I = C2.spec;
|
|
5245
|
+
if (A2) {
|
|
5246
|
+
if (Ft(C2.data))
|
|
5247
|
+
throw new Error(`Splitting is not supported for PColumns with PColumnValues data format. Column id: ${C2.id}`);
|
|
5248
|
+
const c2 = Tt(C2.data);
|
|
5249
5249
|
if (!c2) {
|
|
5250
5250
|
if (s2) continue;
|
|
5251
5251
|
return;
|
|
5252
5252
|
}
|
|
5253
|
-
if (
|
|
5254
|
-
throw new Error(`Splitting requires Partitioned DataInfoEntries, but parsing resulted in ${c2.type} for column ${
|
|
5255
|
-
const m2 =
|
|
5256
|
-
if (
|
|
5257
|
-
throw new Error(`Not enough partition keys (${c2.partitionKeyLength}) for requested split axes (max index ${
|
|
5258
|
-
const
|
|
5259
|
-
if (
|
|
5260
|
-
if (
|
|
5253
|
+
if (!$e$1(c2))
|
|
5254
|
+
throw new Error(`Splitting requires Partitioned DataInfoEntries, but parsing resulted in ${c2.type} for column ${C2.id}`);
|
|
5255
|
+
const m2 = It(c2), T = w[w.length - 1];
|
|
5256
|
+
if (T >= c2.partitionKeyLength)
|
|
5257
|
+
throw new Error(`Not enough partition keys (${c2.partitionKeyLength}) for requested split axes (max index ${T}) in column ${I.name}`);
|
|
5258
|
+
const U = w.map((L2) => this.findLabels(y(I.axesSpec[L2]))), V = [], J = (L2, W) => {
|
|
5259
|
+
if (W >= w.length) {
|
|
5260
|
+
if (V.push([...L2]), V.length > 1e4)
|
|
5261
5261
|
throw new Error("Too many key combinations, aborting.");
|
|
5262
5262
|
return;
|
|
5263
5263
|
}
|
|
5264
|
-
const
|
|
5265
|
-
if (
|
|
5266
|
-
throw new Error(`Axis index ${
|
|
5267
|
-
const
|
|
5268
|
-
if (!
|
|
5269
|
-
|
|
5264
|
+
const j = w[W];
|
|
5265
|
+
if (j >= m2.length)
|
|
5266
|
+
throw new Error(`Axis index ${j} out of bounds for unique keys array (length ${m2.length}) during split key generation for column ${C2.id}`);
|
|
5267
|
+
const M = m2[j];
|
|
5268
|
+
if (!M || M.length === 0) {
|
|
5269
|
+
V.length = 0;
|
|
5270
5270
|
return;
|
|
5271
5271
|
}
|
|
5272
|
-
for (const
|
|
5273
|
-
|
|
5272
|
+
for (const Z of M)
|
|
5273
|
+
L2.push(Z), J(L2, W + 1), L2.pop();
|
|
5274
5274
|
};
|
|
5275
|
-
if (
|
|
5275
|
+
if (J([], 0), V.length === 0)
|
|
5276
5276
|
continue;
|
|
5277
|
-
const
|
|
5278
|
-
for (let
|
|
5279
|
-
|
|
5280
|
-
const
|
|
5281
|
-
for (const
|
|
5282
|
-
const
|
|
5283
|
-
const
|
|
5284
|
-
return { axisIdx:
|
|
5277
|
+
const K = [...I.axesSpec], We2 = w.map((L2) => L2);
|
|
5278
|
+
for (let L2 = w.length - 1; L2 >= 0; L2--)
|
|
5279
|
+
K.splice(w[L2], 1);
|
|
5280
|
+
const Ge = { ...I, axesSpec: K };
|
|
5281
|
+
for (const L2 of V) {
|
|
5282
|
+
const W = L2.map((j, M) => {
|
|
5283
|
+
const Z = We2[M], He2 = y(I.axesSpec[Z]), le = U[M], qe2 = (le == null ? void 0 : le[j]) ?? String(j);
|
|
5284
|
+
return { axisIdx: Z, axisId: He2, value: j, label: qe2 };
|
|
5285
5285
|
});
|
|
5286
|
-
|
|
5286
|
+
f.push({
|
|
5287
5287
|
type: "split",
|
|
5288
|
-
originalColumn:
|
|
5288
|
+
originalColumn: C2,
|
|
5289
5289
|
spec: I,
|
|
5290
|
-
adjustedSpec:
|
|
5290
|
+
adjustedSpec: Ge,
|
|
5291
5291
|
dataEntries: c2,
|
|
5292
|
-
axisFilters:
|
|
5292
|
+
axisFilters: W
|
|
5293
5293
|
});
|
|
5294
5294
|
}
|
|
5295
5295
|
} else
|
|
5296
|
-
|
|
5296
|
+
f.push({
|
|
5297
5297
|
type: "direct",
|
|
5298
|
-
originalColumn:
|
|
5298
|
+
originalColumn: C2,
|
|
5299
5299
|
spec: I,
|
|
5300
5300
|
adjustedSpec: I
|
|
5301
5301
|
});
|
|
5302
5302
|
}
|
|
5303
5303
|
}
|
|
5304
|
-
if (
|
|
5305
|
-
const p2 =
|
|
5306
|
-
|
|
5307
|
-
(
|
|
5308
|
-
spec:
|
|
5309
|
-
suffixTrace:
|
|
5304
|
+
if (f.length === 0) return [];
|
|
5305
|
+
const p2 = Me(
|
|
5306
|
+
f,
|
|
5307
|
+
(d2) => ({
|
|
5308
|
+
spec: d2.spec,
|
|
5309
|
+
suffixTrace: d2.type === "split" ? kt(d2.axisFilters) : void 0
|
|
5310
5310
|
}),
|
|
5311
5311
|
l2
|
|
5312
5312
|
), b = [];
|
|
5313
|
-
for (const { value:
|
|
5314
|
-
const { originalColumn:
|
|
5315
|
-
let
|
|
5316
|
-
r ?
|
|
5317
|
-
let
|
|
5318
|
-
o && (
|
|
5319
|
-
...
|
|
5313
|
+
for (const { value: d2, label: y2 } of p2) {
|
|
5314
|
+
const { originalColumn: S2, spec: E2 } = d2, _2 = d2.type === "split" ? d2.axisFilters : void 0, w = Dt(_2);
|
|
5315
|
+
let A2;
|
|
5316
|
+
r ? A2 = r.deriveS(E2, w) : A2 = Ot(S2.id, w);
|
|
5317
|
+
let C2 = { ...d2.adjustedSpec };
|
|
5318
|
+
o && (C2 = {
|
|
5319
|
+
...C2,
|
|
5320
5320
|
annotations: {
|
|
5321
|
-
...
|
|
5322
|
-
"pl7.app/label":
|
|
5321
|
+
...C2.annotations ?? {},
|
|
5322
|
+
"pl7.app/label": y2
|
|
5323
5323
|
}
|
|
5324
5324
|
}), b.push({
|
|
5325
|
-
id:
|
|
5326
|
-
spec:
|
|
5327
|
-
data: () =>
|
|
5328
|
-
label:
|
|
5325
|
+
id: A2,
|
|
5326
|
+
spec: C2,
|
|
5327
|
+
data: () => d2.type === "split" ? Ie$1(Lt(d2.dataEntries, w)) : d2.originalColumn.data,
|
|
5328
|
+
label: y2
|
|
5329
5329
|
});
|
|
5330
5330
|
}
|
|
5331
5331
|
return b;
|
|
@@ -5353,7 +5353,40 @@
|
|
|
5353
5353
|
return i;
|
|
5354
5354
|
}
|
|
5355
5355
|
}
|
|
5356
|
-
function
|
|
5356
|
+
function ye(t) {
|
|
5357
|
+
const e = (i) => i.operator !== "InSet" ? i : {
|
|
5358
|
+
operator: "Or",
|
|
5359
|
+
operands: i.references.map((s2) => ({
|
|
5360
|
+
operator: "Equal",
|
|
5361
|
+
reference: s2
|
|
5362
|
+
}))
|
|
5363
|
+
}, n2 = (i, s2) => {
|
|
5364
|
+
switch (i.operator) {
|
|
5365
|
+
case "And":
|
|
5366
|
+
return {
|
|
5367
|
+
...i,
|
|
5368
|
+
operands: i.operands.map((a) => n2(a, s2))
|
|
5369
|
+
};
|
|
5370
|
+
case "Or":
|
|
5371
|
+
return {
|
|
5372
|
+
...i,
|
|
5373
|
+
operands: i.operands.map((a) => n2(a, s2))
|
|
5374
|
+
};
|
|
5375
|
+
case "Not":
|
|
5376
|
+
return {
|
|
5377
|
+
...i,
|
|
5378
|
+
operand: n2(i.operand, s2)
|
|
5379
|
+
};
|
|
5380
|
+
default:
|
|
5381
|
+
return s2(i);
|
|
5382
|
+
}
|
|
5383
|
+
}, r = (i, s2) => ({
|
|
5384
|
+
...i,
|
|
5385
|
+
predicate: n2(i.predicate, s2)
|
|
5386
|
+
});
|
|
5387
|
+
return t.map((i) => r(i, e));
|
|
5388
|
+
}
|
|
5389
|
+
function ce(t, e) {
|
|
5357
5390
|
if (t === void 0) return e === void 0;
|
|
5358
5391
|
if (e === void 0) return true;
|
|
5359
5392
|
for (const n2 in e)
|
|
@@ -5361,11 +5394,11 @@
|
|
|
5361
5394
|
return true;
|
|
5362
5395
|
}
|
|
5363
5396
|
function Te(t) {
|
|
5364
|
-
return
|
|
5397
|
+
return Ze(t, (e) => e instanceof D ? e.handle : Oe(e) ? Ce(e, (n2) => n2.handle) : e);
|
|
5365
5398
|
}
|
|
5366
|
-
class
|
|
5399
|
+
class Kt {
|
|
5367
5400
|
constructor() {
|
|
5368
|
-
|
|
5401
|
+
k(this, "ctx", v());
|
|
5369
5402
|
}
|
|
5370
5403
|
/**
|
|
5371
5404
|
* @deprecated use getOptions()
|
|
@@ -5374,28 +5407,28 @@
|
|
|
5374
5407
|
return this.ctx.calculateOptions(e);
|
|
5375
5408
|
}
|
|
5376
5409
|
getOptions(e, n2) {
|
|
5377
|
-
const r = typeof e == "function" ? e :
|
|
5410
|
+
const r = typeof e == "function" ? e : nn(e), i = this.getSpecs().entries.filter((a) => r(a.obj));
|
|
5378
5411
|
let s2 = {}, o = false;
|
|
5379
|
-
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" ?
|
|
5380
|
-
ref:
|
|
5412
|
+
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" ? Me(i, (a) => a.obj, s2 ?? {}).map(({ value: { ref: a }, label: l2 }) => ({
|
|
5413
|
+
ref: un(a, o),
|
|
5381
5414
|
label: l2
|
|
5382
5415
|
})) : i.map(({ ref: a, obj: l2 }) => ({
|
|
5383
|
-
ref:
|
|
5416
|
+
ref: un(a, o),
|
|
5384
5417
|
label: s2(l2, a)
|
|
5385
5418
|
}));
|
|
5386
5419
|
}
|
|
5387
5420
|
resolveAnchorCtx(e) {
|
|
5388
|
-
if (e instanceof
|
|
5421
|
+
if (e instanceof He) return e;
|
|
5389
5422
|
const n2 = {};
|
|
5390
5423
|
for (const [r, i] of Object.entries(e))
|
|
5391
|
-
if (
|
|
5424
|
+
if (sn(i)) {
|
|
5392
5425
|
const s2 = this.getPColumnSpecByRef(i);
|
|
5393
5426
|
if (!s2)
|
|
5394
5427
|
return;
|
|
5395
5428
|
n2[r] = s2;
|
|
5396
5429
|
} else
|
|
5397
5430
|
n2[r] = i;
|
|
5398
|
-
return new
|
|
5431
|
+
return new He(n2);
|
|
5399
5432
|
}
|
|
5400
5433
|
/**
|
|
5401
5434
|
* Returns columns that match the provided anchors and selectors. It applies axis filters and label derivation.
|
|
@@ -5408,7 +5441,7 @@
|
|
|
5408
5441
|
getAnchoredPColumns(e, n2, r) {
|
|
5409
5442
|
const i = this.resolveAnchorCtx(e);
|
|
5410
5443
|
if (i)
|
|
5411
|
-
return new
|
|
5444
|
+
return new ae().addColumnProvider(this).addAxisLabelProvider(this).getColumns(n2, {
|
|
5412
5445
|
...r,
|
|
5413
5446
|
anchorCtx: i
|
|
5414
5447
|
});
|
|
@@ -5445,7 +5478,7 @@
|
|
|
5445
5478
|
getCanonicalOptions(e, n2, r) {
|
|
5446
5479
|
const i = this.resolveAnchorCtx(e);
|
|
5447
5480
|
if (!i) return;
|
|
5448
|
-
const s2 = new
|
|
5481
|
+
const s2 = new ae().addColumnProvider(this).addAxisLabelProvider(this).getUniversalEntries(n2, {
|
|
5449
5482
|
...r,
|
|
5450
5483
|
anchorCtx: i
|
|
5451
5484
|
});
|
|
@@ -5488,7 +5521,7 @@
|
|
|
5488
5521
|
ref: n2.ref,
|
|
5489
5522
|
obj: {
|
|
5490
5523
|
...n2.obj,
|
|
5491
|
-
data:
|
|
5524
|
+
data: fn(
|
|
5492
5525
|
n2.obj.data,
|
|
5493
5526
|
(r) => new D(r, [n2.ref.blockId, n2.ref.name])
|
|
5494
5527
|
)
|
|
@@ -5517,7 +5550,7 @@
|
|
|
5517
5550
|
)) == null ? void 0 : r.obj;
|
|
5518
5551
|
const n2 = this.ctx.getDataFromResultPoolByRef(e.blockId, e.name);
|
|
5519
5552
|
if (n2)
|
|
5520
|
-
return
|
|
5553
|
+
return Ze(
|
|
5521
5554
|
n2,
|
|
5522
5555
|
(i) => new D(i, [e.blockId, e.name])
|
|
5523
5556
|
);
|
|
@@ -5530,7 +5563,7 @@
|
|
|
5530
5563
|
getPColumnByRef(e) {
|
|
5531
5564
|
const n2 = this.getDataByRef(e);
|
|
5532
5565
|
if (n2)
|
|
5533
|
-
return
|
|
5566
|
+
return Ye$1(n2);
|
|
5534
5567
|
}
|
|
5535
5568
|
/**
|
|
5536
5569
|
* Returns spec associated with the ref ensuring that it is a p-column spec.
|
|
@@ -5540,7 +5573,7 @@
|
|
|
5540
5573
|
getPColumnSpecByRef(e) {
|
|
5541
5574
|
const n2 = this.getSpecByRef(e);
|
|
5542
5575
|
if (n2) {
|
|
5543
|
-
if (!
|
|
5576
|
+
if (!d(n2)) throw new Error(`not a PColumn spec (kind = ${n2.kind})`);
|
|
5544
5577
|
return n2;
|
|
5545
5578
|
}
|
|
5546
5579
|
}
|
|
@@ -5559,13 +5592,13 @@
|
|
|
5559
5592
|
findDataWithCompatibleSpec(e) {
|
|
5560
5593
|
const n2 = [];
|
|
5561
5594
|
e: for (const r of this.getData().entries) {
|
|
5562
|
-
if (!
|
|
5595
|
+
if (!d(r.obj.spec))
|
|
5563
5596
|
continue;
|
|
5564
5597
|
const i = r.obj.spec;
|
|
5565
|
-
if (e.name === i.name && e.valueType === i.valueType && e.axesSpec.length === i.axesSpec.length &&
|
|
5598
|
+
if (e.name === i.name && e.valueType === i.valueType && e.axesSpec.length === i.axesSpec.length && ce(e.domain, i.domain)) {
|
|
5566
5599
|
for (let s2 = 0; s2 < e.axesSpec.length; ++s2) {
|
|
5567
5600
|
const o = e.axesSpec[s2], a = i.axesSpec[s2];
|
|
5568
|
-
if (o.name !== a.name || o.type !== a.type || !
|
|
5601
|
+
if (o.name !== a.name || o.type !== a.type || !ce(o.domain, a.domain))
|
|
5569
5602
|
continue e;
|
|
5570
5603
|
}
|
|
5571
5604
|
n2.push(r.obj);
|
|
@@ -5580,9 +5613,9 @@
|
|
|
5580
5613
|
findLabels(e) {
|
|
5581
5614
|
const n2 = this.getData();
|
|
5582
5615
|
for (const r of n2.entries) {
|
|
5583
|
-
if (!
|
|
5616
|
+
if (!ie$1(r.obj)) continue;
|
|
5584
5617
|
const i = r.obj.spec;
|
|
5585
|
-
if (i.name === "pl7.app/label" && i.axesSpec.length === 1 && i.axesSpec[0].name === e.name && i.axesSpec[0].type === e.type &&
|
|
5618
|
+
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)) {
|
|
5586
5619
|
if (r.obj.data.resourceType.name !== "PColumnData/Json")
|
|
5587
5620
|
throw Error(`Expected JSON column for labels, got: ${r.obj.data.resourceType.name}`);
|
|
5588
5621
|
return Object.fromEntries(
|
|
@@ -5601,13 +5634,13 @@
|
|
|
5601
5634
|
* @returns An array of PColumn objects matching the selectors. Data is loaded on first access.
|
|
5602
5635
|
*/
|
|
5603
5636
|
selectColumns(e) {
|
|
5604
|
-
const n2 = typeof e == "function" ? e :
|
|
5605
|
-
return this.getSpecs().entries.filter(({ obj: i }) =>
|
|
5637
|
+
const n2 = typeof e == "function" ? e : nn(e);
|
|
5638
|
+
return this.getSpecs().entries.filter(({ obj: i }) => d(i) ? n2(i) : false).map(({ ref: i, obj: s2 }) => {
|
|
5606
5639
|
const o = s2;
|
|
5607
5640
|
let a = null;
|
|
5608
5641
|
const l2 = this;
|
|
5609
5642
|
return {
|
|
5610
|
-
id:
|
|
5643
|
+
id: Re(i),
|
|
5611
5644
|
spec: o,
|
|
5612
5645
|
get data() {
|
|
5613
5646
|
var u2;
|
|
@@ -5632,36 +5665,54 @@
|
|
|
5632
5665
|
return r;
|
|
5633
5666
|
}
|
|
5634
5667
|
}
|
|
5635
|
-
class
|
|
5668
|
+
class ee {
|
|
5636
5669
|
constructor() {
|
|
5637
|
-
|
|
5638
|
-
|
|
5639
|
-
|
|
5640
|
-
|
|
5641
|
-
|
|
5642
|
-
this.ctx = v()
|
|
5670
|
+
k(this, "ctx");
|
|
5671
|
+
k(this, "_argsCache");
|
|
5672
|
+
k(this, "_uiStateCache");
|
|
5673
|
+
k(this, "_activeArgsCache");
|
|
5674
|
+
k(this, "resultPool", new Kt());
|
|
5675
|
+
this.ctx = v();
|
|
5676
|
+
}
|
|
5677
|
+
get args() {
|
|
5678
|
+
if (this._argsCache === void 0) {
|
|
5679
|
+
const e = this.ctx.args, n2 = typeof e == "function" ? e() : e;
|
|
5680
|
+
this._argsCache = { v: JSON.parse(n2) };
|
|
5681
|
+
}
|
|
5682
|
+
return this._argsCache.v;
|
|
5683
|
+
}
|
|
5684
|
+
get uiState() {
|
|
5685
|
+
if (this._uiStateCache === void 0) {
|
|
5686
|
+
const e = this.ctx.uiState, n2 = typeof e == "function" ? e() : e;
|
|
5687
|
+
this._uiStateCache = { v: n2 ? JSON.parse(n2) : {} };
|
|
5688
|
+
}
|
|
5689
|
+
return this._uiStateCache.v;
|
|
5643
5690
|
}
|
|
5644
5691
|
/**
|
|
5645
5692
|
* Returns args snapshot the block was executed for (i.e. when "Run" button was pressed).
|
|
5646
5693
|
* Returns undefined, if block was never executed or stopped mid-way execution, so that the result was cleared.
|
|
5647
5694
|
* */
|
|
5648
5695
|
get activeArgs() {
|
|
5649
|
-
|
|
5650
|
-
|
|
5651
|
-
|
|
5696
|
+
if (this._activeArgsCache === void 0) {
|
|
5697
|
+
const e = this.ctx.activeArgs, n2 = typeof e == "function" ? e() : e;
|
|
5698
|
+
this._activeArgsCache = {
|
|
5699
|
+
v: n2 ? JSON.parse(n2) : void 0
|
|
5700
|
+
};
|
|
5701
|
+
}
|
|
5702
|
+
return this._activeArgsCache.v;
|
|
5652
5703
|
}
|
|
5653
5704
|
// /** Can be used to determine features provided by the desktop instance. */
|
|
5654
5705
|
// public get featureFlags() {
|
|
5655
5706
|
// return this.ctx.featureFlags;
|
|
5656
5707
|
// }
|
|
5657
5708
|
getNamedAccessor(e) {
|
|
5658
|
-
return
|
|
5709
|
+
return fe(
|
|
5659
5710
|
this.ctx.getAccessorHandleByName(e),
|
|
5660
5711
|
(n2) => new D(n2, [e])
|
|
5661
5712
|
);
|
|
5662
5713
|
}
|
|
5663
5714
|
get prerun() {
|
|
5664
|
-
return this.getNamedAccessor(
|
|
5715
|
+
return this.getNamedAccessor(Ve);
|
|
5665
5716
|
}
|
|
5666
5717
|
get outputs() {
|
|
5667
5718
|
return this.getNamedAccessor(je);
|
|
@@ -5676,16 +5727,20 @@
|
|
|
5676
5727
|
}
|
|
5677
5728
|
verifyInlineAndExplicitColumnsSupport(e) {
|
|
5678
5729
|
var i;
|
|
5679
|
-
const n2 = e.some((s2) => !(s2.data instanceof D) ||
|
|
5730
|
+
const n2 = e.some((s2) => !(s2.data instanceof D) || Oe(s2.data)), r = ((i = this.ctx.featureFlags) == null ? void 0 : i.inlineColumnsSupport) === true;
|
|
5680
5731
|
if (n2 && !r) throw Error("Inline or explicit columns not supported");
|
|
5681
5732
|
}
|
|
5682
5733
|
patchPTableDef(e) {
|
|
5683
|
-
var n2;
|
|
5684
|
-
return (n2 = this.ctx.featureFlags) != null && n2.pTablePartitionFiltersSupport
|
|
5734
|
+
var n2, r;
|
|
5735
|
+
return (n2 = this.ctx.featureFlags) != null && n2.pTablePartitionFiltersSupport || (e = {
|
|
5685
5736
|
...e,
|
|
5686
5737
|
partitionFilters: [],
|
|
5687
5738
|
filters: [...e.partitionFilters, ...e.filters]
|
|
5688
|
-
}
|
|
5739
|
+
}), (r = this.ctx.featureFlags) != null && r.pFrameInSetFilterSupport || (e = {
|
|
5740
|
+
...e,
|
|
5741
|
+
partitionFilters: ye(e.partitionFilters),
|
|
5742
|
+
filters: ye(e.filters)
|
|
5743
|
+
}), e;
|
|
5689
5744
|
}
|
|
5690
5745
|
// TODO remove all non-PColumn fields
|
|
5691
5746
|
createPFrame(e) {
|
|
@@ -5703,8 +5758,8 @@
|
|
|
5703
5758
|
partitionFilters: e.filters ?? [],
|
|
5704
5759
|
filters: [],
|
|
5705
5760
|
sorting: e.sorting ?? []
|
|
5706
|
-
}) : n2 = this.patchPTableDef(e), this.verifyInlineAndExplicitColumnsSupport(
|
|
5707
|
-
|
|
5761
|
+
}) : n2 = this.patchPTableDef(e), this.verifyInlineAndExplicitColumnsSupport(en(n2.src)), this.ctx.createPTable(
|
|
5762
|
+
qe(n2, (r) => Te(r))
|
|
5708
5763
|
);
|
|
5709
5764
|
}
|
|
5710
5765
|
/** @deprecated scheduled for removal from SDK */
|
|
@@ -5724,34 +5779,35 @@
|
|
|
5724
5779
|
this.ctx.logError(e);
|
|
5725
5780
|
}
|
|
5726
5781
|
}
|
|
5727
|
-
const
|
|
5728
|
-
function
|
|
5782
|
+
const z = "1.39.6";
|
|
5783
|
+
function Nt(t) {
|
|
5729
5784
|
return t.__renderLambda === true;
|
|
5730
5785
|
}
|
|
5731
5786
|
function pe(t) {
|
|
5732
5787
|
if (t !== void 0)
|
|
5733
|
-
return
|
|
5788
|
+
return Nt(t) ? t.handle : t;
|
|
5734
5789
|
}
|
|
5735
|
-
class
|
|
5736
|
-
constructor(e, n2, r, i, s2, o, a, l2) {
|
|
5737
|
-
this._renderingMode = e, this._initialArgs = n2, this._initialUiState = r, this._outputs = i, this._inputsValid = s2, this._sections = o, this._title = a, this._enrichmentTargets = l2;
|
|
5790
|
+
const x = class x2 {
|
|
5791
|
+
constructor(e, n2, r, i, s2, o, a, l2, u2) {
|
|
5792
|
+
this._renderingMode = e, this._initialArgs = n2, this._initialUiState = r, this._outputs = i, this._inputsValid = s2, this._sections = o, this._title = a, this._enrichmentTargets = l2, this._featureFlags = u2;
|
|
5738
5793
|
}
|
|
5739
5794
|
static create(e = "Heavy") {
|
|
5740
|
-
return new
|
|
5795
|
+
return new x2(
|
|
5741
5796
|
e,
|
|
5742
5797
|
void 0,
|
|
5743
5798
|
{},
|
|
5744
5799
|
{},
|
|
5745
|
-
|
|
5746
|
-
|
|
5800
|
+
ne(true),
|
|
5801
|
+
ne([]),
|
|
5802
|
+
void 0,
|
|
5747
5803
|
void 0,
|
|
5748
|
-
|
|
5804
|
+
{ ...x2.INITIAL_BLOCK_FEATURE_FLAGS }
|
|
5749
5805
|
);
|
|
5750
5806
|
}
|
|
5751
5807
|
output(e, n2, r = {}) {
|
|
5752
5808
|
if (typeof n2 == "function") {
|
|
5753
5809
|
const i = `output#${e}`;
|
|
5754
|
-
return
|
|
5810
|
+
return G(i, () => n2(new ee())), new x2(
|
|
5755
5811
|
this._renderingMode,
|
|
5756
5812
|
this._initialArgs,
|
|
5757
5813
|
this._initialUiState,
|
|
@@ -5766,10 +5822,11 @@
|
|
|
5766
5822
|
this._inputsValid,
|
|
5767
5823
|
this._sections,
|
|
5768
5824
|
this._title,
|
|
5769
|
-
this._enrichmentTargets
|
|
5825
|
+
this._enrichmentTargets,
|
|
5826
|
+
this._featureFlags
|
|
5770
5827
|
);
|
|
5771
5828
|
} else
|
|
5772
|
-
return new
|
|
5829
|
+
return new x2(
|
|
5773
5830
|
this._renderingMode,
|
|
5774
5831
|
this._initialArgs,
|
|
5775
5832
|
this._initialUiState,
|
|
@@ -5780,7 +5837,8 @@
|
|
|
5780
5837
|
this._inputsValid,
|
|
5781
5838
|
this._sections,
|
|
5782
5839
|
this._title,
|
|
5783
|
-
this._enrichmentTargets
|
|
5840
|
+
this._enrichmentTargets,
|
|
5841
|
+
this._featureFlags
|
|
5784
5842
|
);
|
|
5785
5843
|
}
|
|
5786
5844
|
/** Shortcut for {@link output} with retentive flag set to true. */
|
|
@@ -5788,7 +5846,7 @@
|
|
|
5788
5846
|
return this.output(e, n2, { retentive: true });
|
|
5789
5847
|
}
|
|
5790
5848
|
argsValid(e) {
|
|
5791
|
-
return typeof e == "function" ? (
|
|
5849
|
+
return typeof e == "function" ? (G("inputsValid", () => e(new ee())), new x2(
|
|
5792
5850
|
this._renderingMode,
|
|
5793
5851
|
this._initialArgs,
|
|
5794
5852
|
this._initialUiState,
|
|
@@ -5799,8 +5857,9 @@
|
|
|
5799
5857
|
},
|
|
5800
5858
|
this._sections,
|
|
5801
5859
|
this._title,
|
|
5802
|
-
this._enrichmentTargets
|
|
5803
|
-
|
|
5860
|
+
this._enrichmentTargets,
|
|
5861
|
+
this._featureFlags
|
|
5862
|
+
)) : new x2(
|
|
5804
5863
|
this._renderingMode,
|
|
5805
5864
|
this._initialArgs,
|
|
5806
5865
|
this._initialUiState,
|
|
@@ -5808,11 +5867,12 @@
|
|
|
5808
5867
|
e,
|
|
5809
5868
|
this._sections,
|
|
5810
5869
|
this._title,
|
|
5811
|
-
this._enrichmentTargets
|
|
5870
|
+
this._enrichmentTargets,
|
|
5871
|
+
this._featureFlags
|
|
5812
5872
|
);
|
|
5813
5873
|
}
|
|
5814
5874
|
sections(e) {
|
|
5815
|
-
return Array.isArray(e) ? this.sections(
|
|
5875
|
+
return Array.isArray(e) ? this.sections(ne(e)) : typeof e == "function" ? (G("sections", () => e(new ee())), new x2(
|
|
5816
5876
|
this._renderingMode,
|
|
5817
5877
|
this._initialArgs,
|
|
5818
5878
|
this._initialUiState,
|
|
@@ -5820,8 +5880,9 @@
|
|
|
5820
5880
|
this._inputsValid,
|
|
5821
5881
|
{ __renderLambda: true, handle: "sections" },
|
|
5822
5882
|
this._title,
|
|
5823
|
-
this._enrichmentTargets
|
|
5824
|
-
|
|
5883
|
+
this._enrichmentTargets,
|
|
5884
|
+
this._featureFlags
|
|
5885
|
+
)) : new x2(
|
|
5825
5886
|
this._renderingMode,
|
|
5826
5887
|
this._initialArgs,
|
|
5827
5888
|
this._initialUiState,
|
|
@@ -5829,12 +5890,13 @@
|
|
|
5829
5890
|
this._inputsValid,
|
|
5830
5891
|
e,
|
|
5831
5892
|
this._title,
|
|
5832
|
-
this._enrichmentTargets
|
|
5893
|
+
this._enrichmentTargets,
|
|
5894
|
+
this._featureFlags
|
|
5833
5895
|
);
|
|
5834
5896
|
}
|
|
5835
5897
|
/** Sets a rendering function to derive block title, shown for the block in the left blocks-overview panel. */
|
|
5836
5898
|
title(e) {
|
|
5837
|
-
return
|
|
5899
|
+
return G("title", () => e(new ee())), new x2(
|
|
5838
5900
|
this._renderingMode,
|
|
5839
5901
|
this._initialArgs,
|
|
5840
5902
|
this._initialUiState,
|
|
@@ -5842,7 +5904,8 @@
|
|
|
5842
5904
|
this._inputsValid,
|
|
5843
5905
|
this._sections,
|
|
5844
5906
|
{ __renderLambda: true, handle: "title" },
|
|
5845
|
-
this._enrichmentTargets
|
|
5907
|
+
this._enrichmentTargets,
|
|
5908
|
+
this._featureFlags
|
|
5846
5909
|
);
|
|
5847
5910
|
}
|
|
5848
5911
|
/**
|
|
@@ -5850,7 +5913,7 @@
|
|
|
5850
5913
|
* @deprecated use {@link withArgs}
|
|
5851
5914
|
* */
|
|
5852
5915
|
initialArgs(e) {
|
|
5853
|
-
return new
|
|
5916
|
+
return new x2(
|
|
5854
5917
|
this._renderingMode,
|
|
5855
5918
|
e,
|
|
5856
5919
|
this._initialUiState,
|
|
@@ -5858,12 +5921,13 @@
|
|
|
5858
5921
|
this._inputsValid,
|
|
5859
5922
|
this._sections,
|
|
5860
5923
|
this._title,
|
|
5861
|
-
this._enrichmentTargets
|
|
5924
|
+
this._enrichmentTargets,
|
|
5925
|
+
this._featureFlags
|
|
5862
5926
|
);
|
|
5863
5927
|
}
|
|
5864
5928
|
/** Sets initial args for the block, this value must be specified. */
|
|
5865
5929
|
withArgs(e) {
|
|
5866
|
-
return new
|
|
5930
|
+
return new x2(
|
|
5867
5931
|
this._renderingMode,
|
|
5868
5932
|
e,
|
|
5869
5933
|
this._initialUiState,
|
|
@@ -5871,12 +5935,13 @@
|
|
|
5871
5935
|
this._inputsValid,
|
|
5872
5936
|
this._sections,
|
|
5873
5937
|
this._title,
|
|
5874
|
-
this._enrichmentTargets
|
|
5938
|
+
this._enrichmentTargets,
|
|
5939
|
+
this._featureFlags
|
|
5875
5940
|
);
|
|
5876
5941
|
}
|
|
5877
5942
|
/** Defines type and sets initial value for block UiState. */
|
|
5878
5943
|
withUiState(e) {
|
|
5879
|
-
return new
|
|
5944
|
+
return new x2(
|
|
5880
5945
|
this._renderingMode,
|
|
5881
5946
|
this._initialArgs,
|
|
5882
5947
|
e,
|
|
@@ -5884,7 +5949,8 @@
|
|
|
5884
5949
|
this._inputsValid,
|
|
5885
5950
|
this._sections,
|
|
5886
5951
|
this._title,
|
|
5887
|
-
this._enrichmentTargets
|
|
5952
|
+
this._enrichmentTargets,
|
|
5953
|
+
this._featureFlags
|
|
5888
5954
|
);
|
|
5889
5955
|
}
|
|
5890
5956
|
/**
|
|
@@ -5892,7 +5958,7 @@
|
|
|
5892
5958
|
* Influences dependency graph construction.
|
|
5893
5959
|
*/
|
|
5894
5960
|
enriches(e) {
|
|
5895
|
-
return
|
|
5961
|
+
return G("enrichmentTargets", e), new x2(
|
|
5896
5962
|
this._renderingMode,
|
|
5897
5963
|
this._initialArgs,
|
|
5898
5964
|
this._initialUiState,
|
|
@@ -5900,7 +5966,8 @@
|
|
|
5900
5966
|
this._inputsValid,
|
|
5901
5967
|
this._sections,
|
|
5902
5968
|
this._title,
|
|
5903
|
-
{ __renderLambda: true, handle: "enrichmentTargets" }
|
|
5969
|
+
{ __renderLambda: true, handle: "enrichmentTargets" },
|
|
5970
|
+
this._featureFlags
|
|
5904
5971
|
);
|
|
5905
5972
|
}
|
|
5906
5973
|
/** Renders all provided block settings into a pre-configured platforma API
|
|
@@ -5910,7 +5977,7 @@
|
|
|
5910
5977
|
if (this._initialArgs === void 0) throw new Error("Initial arguments not set.");
|
|
5911
5978
|
const e = {
|
|
5912
5979
|
v3: {
|
|
5913
|
-
sdkVersion:
|
|
5980
|
+
sdkVersion: z,
|
|
5914
5981
|
renderingMode: this._renderingMode,
|
|
5915
5982
|
initialArgs: this._initialArgs,
|
|
5916
5983
|
initialUiState: this._initialUiState,
|
|
@@ -5918,10 +5985,11 @@
|
|
|
5918
5985
|
sections: this._sections,
|
|
5919
5986
|
title: this._title,
|
|
5920
5987
|
outputs: this._outputs,
|
|
5921
|
-
enrichmentTargets: this._enrichmentTargets
|
|
5988
|
+
enrichmentTargets: this._enrichmentTargets,
|
|
5989
|
+
featureFlags: this._featureFlags
|
|
5922
5990
|
},
|
|
5923
5991
|
// fields below are added to allow previous desktop versions read generated configs
|
|
5924
|
-
sdkVersion:
|
|
5992
|
+
sdkVersion: z,
|
|
5925
5993
|
renderingMode: this._renderingMode,
|
|
5926
5994
|
initialArgs: this._initialArgs,
|
|
5927
5995
|
inputsValid: pe(this._inputsValid),
|
|
@@ -5930,10 +5998,16 @@
|
|
|
5930
5998
|
Object.entries(this._outputs).map(([n2, r]) => [n2, pe(r)])
|
|
5931
5999
|
)
|
|
5932
6000
|
};
|
|
5933
|
-
return
|
|
6001
|
+
return ht() ? Ne({ sdkVersion: z }) : { config: e };
|
|
5934
6002
|
}
|
|
5935
|
-
}
|
|
5936
|
-
|
|
6003
|
+
};
|
|
6004
|
+
k(x, "INITIAL_BLOCK_FEATURE_FLAGS", {
|
|
6005
|
+
supportsLazyState: true,
|
|
6006
|
+
requiresUIAPIVersion: 1,
|
|
6007
|
+
requiresModelAPIVersion: 1
|
|
6008
|
+
});
|
|
6009
|
+
let Le = x;
|
|
6010
|
+
const platforma = Le.create("Heavy").withArgs({ titleArg: "The title" }).output("allSpecs", (ctx) => ctx.resultPool.getSpecs()).sections((ctx) => {
|
|
5937
6011
|
return [{ type: "link", href: "/", label: "Main" }];
|
|
5938
6012
|
}).title((ctx) => "Pool explorer").done();
|
|
5939
6013
|
exports2.platforma = platforma;
|