@platforma-sdk/ui-vue 1.42.15 → 1.42.18
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 +29 -28
- package/.turbo/turbo-type-check.log +1 -1
- package/CHANGELOG.md +8 -0
- package/dist/components/PlAgDataTable/PlAgDataTableSheets.vue2.js +5 -5
- package/dist/components/PlAgDataTable/PlAgDataTableV2.vue2.js +21 -21
- package/dist/components/PlAgDataTable/sources/table-source-v2.d.ts.map +1 -1
- package/dist/components/PlAgDataTable/sources/table-source-v2.js +124 -125
- package/dist/components/PlAgDataTable/sources/table-source-v2.js.map +1 -1
- package/dist/components/PlAgDataTable/sources/table-state-v2.js +3 -3
- package/dist/components/PlAgDataTable/sources/value-rendering.d.ts.map +1 -1
- package/dist/components/PlAgDataTable/sources/value-rendering.js +24 -25
- package/dist/components/PlAgDataTable/sources/value-rendering.js.map +1 -1
- package/dist/components/PlAnnotations/components/DynamicForm.vue2.js +12 -12
- package/dist/components/PlAnnotations/components/FilterSidebar.vue2.js +2 -2
- package/dist/components/PlAppErrorNotificationAlert/PlAppErrorNotificationAlert.vue.d.ts.map +1 -1
- package/dist/components/PlAppErrorNotificationAlert/PlAppErrorNotificationAlert.vue.js +21 -20
- package/dist/components/PlAppErrorNotificationAlert/PlAppErrorNotificationAlert.vue.js.map +1 -1
- package/dist/components/PlMultiSequenceAlignment/data.d.ts.map +1 -1
- package/dist/components/PlMultiSequenceAlignment/data.js +170 -185
- package/dist/components/PlMultiSequenceAlignment/data.js.map +1 -1
- package/dist/components/PlTableFilters/filters-state.js +8 -8
- package/dist/components/PlTableFilters/filters_logic.d.ts.map +1 -1
- package/dist/components/PlTableFilters/filters_logic.js +67 -77
- package/dist/components/PlTableFilters/filters_logic.js.map +1 -1
- package/dist/defineApp.js +20 -20
- package/dist/internal/UpdateSerializer.js +3 -3
- package/dist/lib/model/common/dist/index.js +523 -414
- package/dist/lib/model/common/dist/index.js.map +1 -1
- package/dist/lib/ui/uikit/dist/components/DataTable/TableComponent.vue.js +1 -1
- package/dist/lib/ui/uikit/dist/components/PlAccordion/{ExpandTransition.vue.js → ExpandTransition.vue2.js} +1 -1
- package/dist/lib/ui/uikit/dist/components/PlAccordion/ExpandTransition.vue2.js.map +1 -0
- package/dist/lib/ui/uikit/dist/components/PlAccordion/PlAccordionSection.vue2.js +1 -1
- package/dist/lib/ui/uikit/dist/components/PlAutocomplete/PlAutocomplete.vue.js +1 -1
- package/dist/lib/ui/uikit/dist/components/PlDropdown/PlDropdown.vue.js +1 -1
- package/dist/lib/ui/uikit/dist/components/PlDropdownLegacy/PlDropdownLegacy.vue.js +1 -1
- package/dist/lib/ui/uikit/dist/components/PlDropdownMulti/PlDropdownMulti.vue.js +1 -1
- package/dist/lib/ui/uikit/dist/components/PlFileDialog/Local.vue.js +6 -6
- package/dist/lib/ui/uikit/dist/components/PlFileInput/PlFileInput.vue.js +28 -28
- package/dist/lib/ui/uikit/dist/components/PlFileInput/PlFileInput.vue.js.map +1 -1
- package/dist/lib/ui/uikit/dist/components/PlLogView/PlLogView.vue.js +89 -63
- package/dist/lib/ui/uikit/dist/components/PlLogView/PlLogView.vue.js.map +1 -1
- package/dist/lib/ui/uikit/dist/components/PlSlideModal/PlPureSlideModal.vue.js +1 -1
- package/dist/lib/ui/uikit/dist/components/PlTextArea/PlTextArea.vue.js +1 -1
- package/dist/lib/ui/uikit/dist/components/PlTextField/PlTextField.vue.js +1 -1
- package/dist/lib/ui/uikit/dist/generated/components/svg/images/{SvgRequired.vue.js → SvgRequired.vue2.js} +1 -1
- package/dist/lib/ui/uikit/dist/generated/components/svg/images/SvgRequired.vue2.js.map +1 -0
- package/dist/lib/ui/uikit/dist/helpers/dom.js.map +1 -1
- package/dist/lib/ui/uikit/dist/helpers/downloadContent.js +32 -0
- package/dist/lib/ui/uikit/dist/helpers/downloadContent.js.map +1 -0
- package/dist/lib/ui/uikit/dist/lib/model/common/dist/index.js +201 -159
- package/dist/lib/ui/uikit/dist/lib/model/common/dist/index.js.map +1 -1
- package/dist/lib/ui/uikit/dist/sdk/model/dist/index.js +521 -517
- package/dist/lib/ui/uikit/dist/sdk/model/dist/index.js.map +1 -1
- package/dist/lib.js +52 -50
- package/dist/lib.js.map +1 -1
- package/dist/sdk/model/dist/index.js +410 -406
- package/dist/sdk/model/dist/index.js.map +1 -1
- package/package.json +4 -4
- package/src/components/PlAgDataTable/sources/table-source-v2.ts +20 -16
- package/src/components/PlAgDataTable/sources/value-rendering.ts +15 -7
- package/src/components/PlAppErrorNotificationAlert/PlAppErrorNotificationAlert.vue +1 -0
- package/src/components/PlMultiSequenceAlignment/data.ts +12 -12
- package/src/components/PlTableFilters/filters_logic.ts +18 -15
- package/dist/lib/ui/uikit/dist/components/PlAccordion/ExpandTransition.vue.js.map +0 -1
- package/dist/lib/ui/uikit/dist/generated/components/svg/images/SvgRequired.vue.js.map +0 -1
|
@@ -1,89 +1,89 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
var
|
|
4
|
-
|
|
1
|
+
import o from "../../../../node_modules/.pnpm/zod@3.23.8/node_modules/zod/lib/index.js";
|
|
2
|
+
import g from "../../../../_virtual/canonicalize.js";
|
|
3
|
+
var J = Object.defineProperty, I = (n, t, e) => t in n ? J(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e, y = (n, t, e) => I(n, typeof t != "symbol" ? t + "" : t, e);
|
|
4
|
+
o.object({
|
|
5
5
|
/** Included left border. */
|
|
6
|
-
from:
|
|
6
|
+
from: o.number(),
|
|
7
7
|
/** Excluded right border. */
|
|
8
|
-
to:
|
|
8
|
+
to: o.number()
|
|
9
9
|
});
|
|
10
|
-
function
|
|
11
|
-
throw new Error("Unexpected object: " +
|
|
10
|
+
function w(n) {
|
|
11
|
+
throw new Error("Unexpected object: " + n);
|
|
12
12
|
}
|
|
13
|
-
function
|
|
14
|
-
if (!
|
|
13
|
+
function cn(n) {
|
|
14
|
+
if (!n || typeof n != "object")
|
|
15
15
|
return !1;
|
|
16
|
-
const
|
|
17
|
-
if (!("type" in
|
|
16
|
+
const t = n;
|
|
17
|
+
if (!("type" in t))
|
|
18
18
|
return !1;
|
|
19
|
-
switch (
|
|
19
|
+
switch (t.type) {
|
|
20
20
|
case "Json":
|
|
21
|
-
return typeof
|
|
21
|
+
return typeof t.keyLength == "number" && t.data !== void 0 && typeof t.data == "object";
|
|
22
22
|
case "JsonPartitioned":
|
|
23
23
|
case "BinaryPartitioned":
|
|
24
24
|
case "ParquetPartitioned":
|
|
25
|
-
return typeof
|
|
25
|
+
return typeof t.partitionKeyLength == "number" && t.parts !== void 0 && typeof t.parts == "object";
|
|
26
26
|
default:
|
|
27
27
|
return !1;
|
|
28
28
|
}
|
|
29
29
|
}
|
|
30
|
-
function
|
|
31
|
-
if (
|
|
32
|
-
switch (
|
|
30
|
+
function un(n, t) {
|
|
31
|
+
if (n !== void 0)
|
|
32
|
+
switch (n.type) {
|
|
33
33
|
case "Json":
|
|
34
|
-
return
|
|
34
|
+
return n;
|
|
35
35
|
case "JsonPartitioned": {
|
|
36
|
-
const
|
|
37
|
-
for (const [r, a] of Object.entries(
|
|
38
|
-
|
|
36
|
+
const e = {};
|
|
37
|
+
for (const [r, a] of Object.entries(n.parts))
|
|
38
|
+
e[r] = t(a);
|
|
39
39
|
return {
|
|
40
|
-
...
|
|
41
|
-
parts:
|
|
40
|
+
...n,
|
|
41
|
+
parts: e
|
|
42
42
|
};
|
|
43
43
|
}
|
|
44
44
|
case "BinaryPartitioned": {
|
|
45
|
-
const
|
|
46
|
-
for (const [r, a] of Object.entries(
|
|
47
|
-
|
|
48
|
-
index:
|
|
49
|
-
values:
|
|
45
|
+
const e = {};
|
|
46
|
+
for (const [r, a] of Object.entries(n.parts))
|
|
47
|
+
e[r] = {
|
|
48
|
+
index: t(a.index),
|
|
49
|
+
values: t(a.values)
|
|
50
50
|
};
|
|
51
51
|
return {
|
|
52
|
-
...
|
|
53
|
-
parts:
|
|
52
|
+
...n,
|
|
53
|
+
parts: e
|
|
54
54
|
};
|
|
55
55
|
}
|
|
56
56
|
case "ParquetPartitioned": {
|
|
57
|
-
const
|
|
58
|
-
for (const [r, a] of Object.entries(
|
|
59
|
-
|
|
57
|
+
const e = {};
|
|
58
|
+
for (const [r, a] of Object.entries(n.parts))
|
|
59
|
+
e[r] = t(a);
|
|
60
60
|
return {
|
|
61
|
-
...
|
|
62
|
-
parts:
|
|
61
|
+
...n,
|
|
62
|
+
parts: e
|
|
63
63
|
};
|
|
64
64
|
}
|
|
65
65
|
}
|
|
66
66
|
}
|
|
67
|
-
function
|
|
68
|
-
if (!
|
|
67
|
+
function j(n) {
|
|
68
|
+
if (!n || typeof n != "object")
|
|
69
69
|
return !1;
|
|
70
|
-
const
|
|
71
|
-
if (!("type" in
|
|
70
|
+
const t = n;
|
|
71
|
+
if (!("type" in t))
|
|
72
72
|
return !1;
|
|
73
|
-
switch (
|
|
73
|
+
switch (t.type) {
|
|
74
74
|
case "Json":
|
|
75
|
-
return typeof
|
|
75
|
+
return typeof t.keyLength == "number" && Array.isArray(t.data);
|
|
76
76
|
case "JsonPartitioned":
|
|
77
77
|
case "BinaryPartitioned":
|
|
78
78
|
case "ParquetPartitioned":
|
|
79
|
-
return typeof
|
|
79
|
+
return typeof t.partitionKeyLength == "number" && Array.isArray(t.parts);
|
|
80
80
|
default:
|
|
81
81
|
return !1;
|
|
82
82
|
}
|
|
83
83
|
}
|
|
84
|
-
function
|
|
85
|
-
if (!
|
|
86
|
-
switch (
|
|
84
|
+
function fn(n) {
|
|
85
|
+
if (!j(n)) return !1;
|
|
86
|
+
switch (n.type) {
|
|
87
87
|
case "JsonPartitioned":
|
|
88
88
|
case "BinaryPartitioned":
|
|
89
89
|
case "ParquetPartitioned":
|
|
@@ -92,237 +92,365 @@ function tt(t) {
|
|
|
92
92
|
return !1;
|
|
93
93
|
}
|
|
94
94
|
}
|
|
95
|
-
function
|
|
96
|
-
switch (
|
|
95
|
+
function ln(n) {
|
|
96
|
+
switch (n.type) {
|
|
97
97
|
case "Json":
|
|
98
98
|
return {
|
|
99
99
|
type: "Json",
|
|
100
|
-
keyLength:
|
|
101
|
-
data: Object.entries(
|
|
100
|
+
keyLength: n.keyLength,
|
|
101
|
+
data: Object.entries(n.data).map(([t, e]) => ({ key: JSON.parse(t), value: e }))
|
|
102
102
|
};
|
|
103
103
|
case "JsonPartitioned":
|
|
104
104
|
return {
|
|
105
105
|
type: "JsonPartitioned",
|
|
106
|
-
partitionKeyLength:
|
|
107
|
-
parts: Object.entries(
|
|
106
|
+
partitionKeyLength: n.partitionKeyLength,
|
|
107
|
+
parts: Object.entries(n.parts).map(([t, e]) => ({ key: JSON.parse(t), value: e }))
|
|
108
108
|
};
|
|
109
109
|
case "BinaryPartitioned":
|
|
110
110
|
return {
|
|
111
111
|
type: "BinaryPartitioned",
|
|
112
|
-
partitionKeyLength:
|
|
113
|
-
parts: Object.entries(
|
|
112
|
+
partitionKeyLength: n.partitionKeyLength,
|
|
113
|
+
parts: Object.entries(n.parts).map(([t, e]) => ({ key: JSON.parse(t), value: e }))
|
|
114
114
|
};
|
|
115
115
|
case "ParquetPartitioned":
|
|
116
116
|
return {
|
|
117
117
|
type: "ParquetPartitioned",
|
|
118
|
-
partitionKeyLength:
|
|
119
|
-
parts: Object.entries(
|
|
118
|
+
partitionKeyLength: n.partitionKeyLength,
|
|
119
|
+
parts: Object.entries(n.parts).map(([t, e]) => ({ key: JSON.parse(t), value: e }))
|
|
120
120
|
};
|
|
121
121
|
default:
|
|
122
|
-
|
|
122
|
+
w(n);
|
|
123
123
|
}
|
|
124
124
|
}
|
|
125
|
-
function
|
|
126
|
-
switch (
|
|
125
|
+
function pn(n) {
|
|
126
|
+
switch (n.type) {
|
|
127
127
|
case "Json":
|
|
128
128
|
return {
|
|
129
129
|
type: "Json",
|
|
130
|
-
keyLength:
|
|
130
|
+
keyLength: n.keyLength,
|
|
131
131
|
data: Object.fromEntries(
|
|
132
|
-
|
|
132
|
+
n.data.map(({ key: t, value: e }) => [JSON.stringify(t), e])
|
|
133
133
|
)
|
|
134
134
|
};
|
|
135
135
|
case "JsonPartitioned":
|
|
136
136
|
return {
|
|
137
137
|
type: "JsonPartitioned",
|
|
138
|
-
partitionKeyLength:
|
|
138
|
+
partitionKeyLength: n.partitionKeyLength,
|
|
139
139
|
parts: Object.fromEntries(
|
|
140
|
-
|
|
140
|
+
n.parts.map(({ key: t, value: e }) => [JSON.stringify(t), e])
|
|
141
141
|
)
|
|
142
142
|
};
|
|
143
143
|
case "BinaryPartitioned":
|
|
144
144
|
return {
|
|
145
145
|
type: "BinaryPartitioned",
|
|
146
|
-
partitionKeyLength:
|
|
146
|
+
partitionKeyLength: n.partitionKeyLength,
|
|
147
147
|
parts: Object.fromEntries(
|
|
148
|
-
|
|
148
|
+
n.parts.map(({ key: t, value: e }) => [JSON.stringify(t), e])
|
|
149
149
|
)
|
|
150
150
|
};
|
|
151
151
|
case "ParquetPartitioned":
|
|
152
152
|
return {
|
|
153
153
|
type: "ParquetPartitioned",
|
|
154
|
-
partitionKeyLength:
|
|
154
|
+
partitionKeyLength: n.partitionKeyLength,
|
|
155
155
|
parts: Object.fromEntries(
|
|
156
|
-
|
|
156
|
+
n.parts.map(({ key: t, value: e }) => [JSON.stringify(t), e])
|
|
157
157
|
)
|
|
158
158
|
};
|
|
159
159
|
default:
|
|
160
|
-
|
|
160
|
+
w(n);
|
|
161
161
|
}
|
|
162
162
|
}
|
|
163
|
-
function
|
|
164
|
-
|
|
165
|
-
|
|
163
|
+
function N(n) {
|
|
164
|
+
return n instanceof Error ? n.name === "AbortError" || N(n.cause) : !1;
|
|
165
|
+
}
|
|
166
|
+
function L(n) {
|
|
167
|
+
if (typeof n == "string")
|
|
168
|
+
return `String value was thrown: ${n}`;
|
|
169
|
+
if (n && typeof n == "object")
|
|
170
|
+
try {
|
|
171
|
+
return `Plain object was thrown: ${JSON.stringify(n)}`;
|
|
172
|
+
} catch (t) {
|
|
173
|
+
return `Non-serializable object was thrown (JSON.stringify failed: ${t instanceof Error ? t.message : String(t)}): ${String(n)}`;
|
|
174
|
+
}
|
|
175
|
+
return `Non-Error value (${typeof n}) was thrown: ${n}`;
|
|
166
176
|
}
|
|
167
|
-
function
|
|
168
|
-
return
|
|
177
|
+
function T(n) {
|
|
178
|
+
return n instanceof Error ? n : new Error(L(n));
|
|
169
179
|
}
|
|
170
|
-
function
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
180
|
+
function E(n) {
|
|
181
|
+
const t = n.cause ? E(n.cause) : void 0, e = new Error(n.message, t !== void 0 ? { cause: t } : void 0);
|
|
182
|
+
return e.name = n.name || "Error", e.stack = n.stack, e;
|
|
183
|
+
}
|
|
184
|
+
function dn(n) {
|
|
185
|
+
if (n.error)
|
|
186
|
+
throw n.error instanceof Error ? n.error : E(n.error);
|
|
187
|
+
return n.value;
|
|
188
|
+
}
|
|
189
|
+
function mn(n) {
|
|
190
|
+
return JSON.stringify(n);
|
|
191
|
+
}
|
|
192
|
+
function C(n) {
|
|
193
|
+
return g(n);
|
|
194
|
+
}
|
|
195
|
+
function yn(n) {
|
|
196
|
+
return JSON.parse(n);
|
|
197
|
+
}
|
|
198
|
+
const l = {
|
|
199
|
+
Int: "Int",
|
|
200
|
+
Long: "Long",
|
|
201
|
+
Float: "Float",
|
|
202
|
+
Double: "Double",
|
|
203
|
+
String: "String",
|
|
204
|
+
Bytes: "Bytes"
|
|
205
|
+
};
|
|
206
|
+
function v(n, t) {
|
|
207
|
+
return n == null ? void 0 : n[t];
|
|
208
|
+
}
|
|
209
|
+
function $(n, t, e, r = "readMetadataJsonOrThrow") {
|
|
210
|
+
const a = v(n, e);
|
|
211
|
+
if (a === void 0) return;
|
|
212
|
+
const c = t[e];
|
|
213
|
+
try {
|
|
214
|
+
const i = JSON.parse(a);
|
|
215
|
+
return c.parse(i);
|
|
216
|
+
} catch (i) {
|
|
217
|
+
throw new Error(
|
|
218
|
+
`${r} failed, key: ${String(e)}, value: ${a}, error: ${T(i)}`
|
|
219
|
+
);
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
function D(n, t, e) {
|
|
223
|
+
try {
|
|
224
|
+
return $(n, t, e);
|
|
225
|
+
} catch {
|
|
226
|
+
return;
|
|
227
|
+
}
|
|
228
|
+
}
|
|
229
|
+
const hn = {
|
|
230
|
+
Alphabet: "pl7.app/alphabet"
|
|
231
|
+
};
|
|
232
|
+
function bn(n, t) {
|
|
233
|
+
return v(n == null ? void 0 : n.domain, t);
|
|
234
|
+
}
|
|
235
|
+
const p = {
|
|
236
|
+
Alphabet: "pl7.app/alphabet",
|
|
237
|
+
DiscreteValues: "pl7.app/discreteValues",
|
|
238
|
+
Format: "pl7.app/format",
|
|
239
|
+
Graph: {
|
|
240
|
+
IsVirtual: "pl7.app/graph/isVirtual"
|
|
241
|
+
},
|
|
242
|
+
HideDataFromUi: "pl7.app/hideDataFromUi",
|
|
243
|
+
IsLinkerColumn: "pl7.app/isLinkerColumn",
|
|
244
|
+
Label: "pl7.app/label",
|
|
245
|
+
Max: "pl7.app/max",
|
|
246
|
+
Min: "pl7.app/min",
|
|
247
|
+
Parents: "pl7.app/parents",
|
|
248
|
+
Sequence: {
|
|
249
|
+
Annotation: {
|
|
250
|
+
Mapping: "pl7.app/sequence/annotation/mapping"
|
|
251
|
+
},
|
|
252
|
+
IsAnnotation: "pl7.app/sequence/isAnnotation"
|
|
253
|
+
},
|
|
254
|
+
Table: {
|
|
255
|
+
FontFamily: "pl7.app/table/fontFamily",
|
|
256
|
+
OrderPriority: "pl7.app/table/orderPriority",
|
|
257
|
+
Visibility: "pl7.app/table/visibility"
|
|
258
|
+
},
|
|
259
|
+
Trace: "pl7.app/trace"
|
|
260
|
+
}, F = o.object({
|
|
261
|
+
type: o.nativeEnum(l),
|
|
262
|
+
name: o.string(),
|
|
263
|
+
domain: o.record(o.string(), o.string()).optional(),
|
|
264
|
+
annotations: o.record(o.string(), o.string()).optional(),
|
|
265
|
+
parentAxes: o.array(o.number()).optional()
|
|
266
|
+
}).passthrough(), M = {
|
|
267
|
+
[p.DiscreteValues]: o.array(o.string()).or(o.array(o.number())),
|
|
268
|
+
[p.Graph.IsVirtual]: o.boolean(),
|
|
269
|
+
[p.HideDataFromUi]: o.boolean(),
|
|
270
|
+
[p.IsLinkerColumn]: o.boolean(),
|
|
271
|
+
[p.Max]: o.number(),
|
|
272
|
+
[p.Min]: o.number(),
|
|
273
|
+
[p.Parents]: o.array(F),
|
|
274
|
+
[p.Sequence.Annotation.Mapping]: o.record(o.string(), o.string()),
|
|
275
|
+
[p.Sequence.IsAnnotation]: o.boolean(),
|
|
276
|
+
[p.Table.OrderPriority]: o.number(),
|
|
277
|
+
[p.Trace]: o.record(o.string(), o.unknown())
|
|
278
|
+
};
|
|
279
|
+
function gn(n, t) {
|
|
280
|
+
return v(n == null ? void 0 : n.annotations, t);
|
|
281
|
+
}
|
|
282
|
+
function wn(n, t) {
|
|
283
|
+
return D(n == null ? void 0 : n.annotations, M, t);
|
|
284
|
+
}
|
|
285
|
+
const vn = {
|
|
286
|
+
Label: "pl7.app/label",
|
|
287
|
+
Table: {
|
|
288
|
+
RowSelection: "pl7.app/table/row-selection"
|
|
289
|
+
}
|
|
290
|
+
};
|
|
291
|
+
function m(n) {
|
|
292
|
+
const { type: t, name: e, domain: r } = n, a = { type: t, name: e };
|
|
293
|
+
return r && Object.entries(r).length > 0 && Object.assign(a, { domain: r }), a;
|
|
294
|
+
}
|
|
295
|
+
function B(n) {
|
|
296
|
+
return n.map(m);
|
|
297
|
+
}
|
|
298
|
+
function Pn(n) {
|
|
299
|
+
return C(m(n));
|
|
300
|
+
}
|
|
301
|
+
function R(n, t) {
|
|
302
|
+
if (n === void 0) return t === void 0;
|
|
303
|
+
if (t === void 0) return !0;
|
|
304
|
+
for (const e in t)
|
|
305
|
+
if (n[e] !== t[e]) return !1;
|
|
306
|
+
return !0;
|
|
307
|
+
}
|
|
308
|
+
function V(n, t) {
|
|
309
|
+
return n.name === t.name && R(n.domain, t.domain);
|
|
310
|
+
}
|
|
311
|
+
function S(n, t) {
|
|
312
|
+
const e = Math.floor(t / 8), r = 1 << 7 - t % 8;
|
|
313
|
+
return (n[e] & r) > 0;
|
|
314
|
+
}
|
|
315
|
+
function q(n, t) {
|
|
316
|
+
return S(n.absent, t);
|
|
317
|
+
}
|
|
318
|
+
function U(n, t) {
|
|
319
|
+
if (n.isNA) return S(n.isNA, t);
|
|
320
|
+
const e = n.type, r = n.data[t];
|
|
321
|
+
switch (e) {
|
|
322
|
+
case l.Int:
|
|
175
323
|
return r === -2147483648;
|
|
176
|
-
case
|
|
324
|
+
case l.Long:
|
|
177
325
|
return r === -9007199254740991n;
|
|
178
|
-
case
|
|
326
|
+
case l.Float:
|
|
179
327
|
return Number.isNaN(r);
|
|
180
|
-
case
|
|
328
|
+
case l.Double:
|
|
181
329
|
return Number.isNaN(r);
|
|
182
|
-
case
|
|
330
|
+
case l.String:
|
|
183
331
|
return r === null;
|
|
184
|
-
case
|
|
332
|
+
case l.Bytes:
|
|
185
333
|
return r === null;
|
|
186
334
|
default:
|
|
187
|
-
throw Error(`unsupported data type: ${
|
|
335
|
+
throw Error(`unsupported data type: ${e}`);
|
|
188
336
|
}
|
|
189
337
|
}
|
|
190
|
-
const
|
|
191
|
-
function
|
|
192
|
-
return typeof
|
|
338
|
+
const K = { type: "absent" };
|
|
339
|
+
function xn(n) {
|
|
340
|
+
return typeof n == "object" && n !== null && "type" in n && n.type === "absent";
|
|
193
341
|
}
|
|
194
|
-
const
|
|
195
|
-
function
|
|
196
|
-
return
|
|
342
|
+
const O = null;
|
|
343
|
+
function G(n) {
|
|
344
|
+
return n === O;
|
|
197
345
|
}
|
|
198
|
-
function
|
|
199
|
-
return !
|
|
346
|
+
function An(n, t) {
|
|
347
|
+
return !G(n);
|
|
200
348
|
}
|
|
201
|
-
function
|
|
202
|
-
const r =
|
|
203
|
-
if (r ===
|
|
349
|
+
function H(n, t, e) {
|
|
350
|
+
const r = n.type;
|
|
351
|
+
if (r === l.Bytes)
|
|
204
352
|
throw Error("Bytes not yet supported");
|
|
205
|
-
if (
|
|
206
|
-
throw Error(`expected column of type ${
|
|
207
|
-
if (
|
|
208
|
-
return (
|
|
209
|
-
if (
|
|
210
|
-
return (
|
|
211
|
-
const a =
|
|
353
|
+
if (e && "dataType" in e && e.dataType !== void 0 && e.dataType !== r)
|
|
354
|
+
throw Error(`expected column of type ${e.dataType}, got ${r}`);
|
|
355
|
+
if (q(n, t))
|
|
356
|
+
return (e == null ? void 0 : e.absent) !== void 0 ? e.absent : K;
|
|
357
|
+
if (U(n, t))
|
|
358
|
+
return (e == null ? void 0 : e.na) !== void 0 ? e.na : O;
|
|
359
|
+
const a = n.data[t];
|
|
212
360
|
switch (r) {
|
|
213
|
-
case
|
|
361
|
+
case l.Int:
|
|
214
362
|
return a;
|
|
215
|
-
case
|
|
363
|
+
case l.Long:
|
|
216
364
|
return Number(a);
|
|
217
|
-
case
|
|
365
|
+
case l.Float:
|
|
218
366
|
return a;
|
|
219
|
-
case
|
|
367
|
+
case l.Double:
|
|
220
368
|
return a;
|
|
221
|
-
case
|
|
369
|
+
case l.String:
|
|
222
370
|
return a;
|
|
223
371
|
}
|
|
224
372
|
}
|
|
225
|
-
function
|
|
226
|
-
return
|
|
227
|
-
}
|
|
228
|
-
function l(t) {
|
|
229
|
-
const { type: e, name: n, domain: r } = t, a = { type: e, name: n };
|
|
230
|
-
return r && Object.entries(r).length > 0 && Object.assign(a, { domain: r }), a;
|
|
231
|
-
}
|
|
232
|
-
function $(t) {
|
|
233
|
-
return t.map(l);
|
|
234
|
-
}
|
|
235
|
-
function it(t) {
|
|
236
|
-
return p(l(t));
|
|
237
|
-
}
|
|
238
|
-
function L(t, e) {
|
|
239
|
-
if (t === void 0) return e === void 0;
|
|
240
|
-
if (e === void 0) return !0;
|
|
241
|
-
for (const n in e)
|
|
242
|
-
if (t[n] !== e[n]) return !1;
|
|
243
|
-
return !0;
|
|
373
|
+
function kn(n, t, e) {
|
|
374
|
+
return H(n, t, e);
|
|
244
375
|
}
|
|
245
|
-
function
|
|
246
|
-
return
|
|
376
|
+
function En(n, t) {
|
|
377
|
+
return { ...n, src: h(n.src, t) };
|
|
247
378
|
}
|
|
248
|
-
function
|
|
249
|
-
|
|
250
|
-
}
|
|
251
|
-
function y(t, e) {
|
|
252
|
-
switch (t.type) {
|
|
379
|
+
function h(n, t) {
|
|
380
|
+
switch (n.type) {
|
|
253
381
|
case "column":
|
|
254
382
|
return {
|
|
255
383
|
type: "column",
|
|
256
|
-
column:
|
|
384
|
+
column: t(n.column)
|
|
257
385
|
};
|
|
258
386
|
case "slicedColumn":
|
|
259
387
|
return {
|
|
260
388
|
type: "slicedColumn",
|
|
261
|
-
column:
|
|
262
|
-
newId:
|
|
263
|
-
axisFilters:
|
|
389
|
+
column: t(n.column),
|
|
390
|
+
newId: n.newId,
|
|
391
|
+
axisFilters: n.axisFilters
|
|
264
392
|
};
|
|
265
393
|
case "inlineColumn":
|
|
266
|
-
return
|
|
394
|
+
return n;
|
|
267
395
|
case "inner":
|
|
268
396
|
case "full":
|
|
269
397
|
return {
|
|
270
|
-
type:
|
|
271
|
-
entries:
|
|
398
|
+
type: n.type,
|
|
399
|
+
entries: n.entries.map((e) => h(e, t))
|
|
272
400
|
};
|
|
273
401
|
case "outer":
|
|
274
402
|
return {
|
|
275
403
|
type: "outer",
|
|
276
|
-
primary:
|
|
277
|
-
secondary:
|
|
404
|
+
primary: h(n.primary, t),
|
|
405
|
+
secondary: n.secondary.map((e) => h(e, t))
|
|
278
406
|
};
|
|
279
407
|
default:
|
|
280
|
-
|
|
408
|
+
w(n);
|
|
281
409
|
}
|
|
282
410
|
}
|
|
283
|
-
function
|
|
284
|
-
switch (
|
|
411
|
+
function Sn(n) {
|
|
412
|
+
switch (n.type) {
|
|
285
413
|
case "axis":
|
|
286
414
|
return {
|
|
287
415
|
type: "axis",
|
|
288
|
-
id:
|
|
416
|
+
id: n.id
|
|
289
417
|
};
|
|
290
418
|
case "column":
|
|
291
419
|
return {
|
|
292
420
|
type: "column",
|
|
293
|
-
id:
|
|
421
|
+
id: n.id
|
|
294
422
|
};
|
|
295
423
|
}
|
|
296
424
|
}
|
|
297
|
-
function
|
|
298
|
-
return
|
|
425
|
+
function _(n) {
|
|
426
|
+
return g(n);
|
|
299
427
|
}
|
|
300
|
-
function
|
|
301
|
-
return
|
|
428
|
+
function P(n) {
|
|
429
|
+
return g(m(n));
|
|
302
430
|
}
|
|
303
|
-
function
|
|
304
|
-
return JSON.stringify([
|
|
431
|
+
function x(n, t) {
|
|
432
|
+
return JSON.stringify([n, t]);
|
|
305
433
|
}
|
|
306
|
-
class
|
|
434
|
+
class On {
|
|
307
435
|
/**
|
|
308
436
|
* Creates a new anchor context from a set of anchor column specifications
|
|
309
437
|
* @param anchors Record of anchor column specifications indexed by anchor ID
|
|
310
438
|
*/
|
|
311
|
-
constructor(
|
|
312
|
-
|
|
313
|
-
const
|
|
314
|
-
|
|
315
|
-
for (const [r, a] of
|
|
316
|
-
for (let
|
|
317
|
-
const i = a.axesSpec[
|
|
318
|
-
this.axes.set(
|
|
439
|
+
constructor(t) {
|
|
440
|
+
y(this, "domains", /* @__PURE__ */ new Map()), y(this, "axes", /* @__PURE__ */ new Map()), y(this, "domainPacks", []), y(this, "domainPackToAnchor", /* @__PURE__ */ new Map()), this.anchors = t;
|
|
441
|
+
const e = Object.entries(t);
|
|
442
|
+
e.sort((r, a) => r[0].localeCompare(a[0]));
|
|
443
|
+
for (const [r, a] of e) {
|
|
444
|
+
for (let c = 0; c < a.axesSpec.length; c++) {
|
|
445
|
+
const i = a.axesSpec[c], s = P(i);
|
|
446
|
+
this.axes.set(s, { anchor: r, idx: c });
|
|
319
447
|
}
|
|
320
448
|
if (a.domain !== void 0) {
|
|
321
|
-
const
|
|
322
|
-
|
|
323
|
-
for (const [i,
|
|
324
|
-
const
|
|
325
|
-
this.domains.set(
|
|
449
|
+
const c = Object.entries(a.domain);
|
|
450
|
+
c.sort((i, s) => i[0].localeCompare(s[0])), this.domainPackToAnchor.set(JSON.stringify(c), r), this.domainPacks.push(c.map(([i]) => i));
|
|
451
|
+
for (const [i, s] of c) {
|
|
452
|
+
const u = x(i, s);
|
|
453
|
+
this.domains.set(u, r);
|
|
326
454
|
}
|
|
327
455
|
}
|
|
328
456
|
}
|
|
@@ -330,57 +458,57 @@ class ut {
|
|
|
330
458
|
/**
|
|
331
459
|
* Implementation of derive method
|
|
332
460
|
*/
|
|
333
|
-
derive(
|
|
461
|
+
derive(t, e) {
|
|
334
462
|
const r = {
|
|
335
|
-
name:
|
|
463
|
+
name: t.name,
|
|
336
464
|
axes: []
|
|
337
465
|
};
|
|
338
466
|
let a;
|
|
339
|
-
if (
|
|
340
|
-
|
|
467
|
+
if (t.domain !== void 0)
|
|
468
|
+
n:
|
|
341
469
|
for (const i of this.domainPacks) {
|
|
342
|
-
const
|
|
343
|
-
for (const
|
|
344
|
-
const d =
|
|
470
|
+
const s = [];
|
|
471
|
+
for (const f of i) {
|
|
472
|
+
const d = t.domain[f];
|
|
345
473
|
if (d !== void 0)
|
|
346
|
-
|
|
474
|
+
s.push([f, d]);
|
|
347
475
|
else
|
|
348
|
-
break
|
|
476
|
+
break n;
|
|
349
477
|
}
|
|
350
|
-
const
|
|
351
|
-
if (
|
|
352
|
-
r.domainAnchor =
|
|
478
|
+
const u = this.domainPackToAnchor.get(JSON.stringify(s));
|
|
479
|
+
if (u !== void 0) {
|
|
480
|
+
r.domainAnchor = u, a = new Set(i);
|
|
353
481
|
break;
|
|
354
482
|
}
|
|
355
483
|
}
|
|
356
|
-
for (const [i,
|
|
484
|
+
for (const [i, s] of Object.entries(t.domain ?? {})) {
|
|
357
485
|
if (a !== void 0 && a.has(i))
|
|
358
486
|
continue;
|
|
359
|
-
const
|
|
360
|
-
r.domain ?? (r.domain = {}), r.domain[i] =
|
|
487
|
+
const u = x(i, s), f = this.domains.get(u);
|
|
488
|
+
r.domain ?? (r.domain = {}), r.domain[i] = f ? { anchor: f } : s;
|
|
361
489
|
}
|
|
362
|
-
if (r.axes =
|
|
363
|
-
const
|
|
364
|
-
return
|
|
365
|
-
}), !
|
|
490
|
+
if (r.axes = t.axesSpec.map((i) => {
|
|
491
|
+
const s = P(i), u = this.axes.get(s);
|
|
492
|
+
return u === void 0 ? m(i) : u;
|
|
493
|
+
}), !e || e.length === 0)
|
|
366
494
|
return r;
|
|
367
|
-
const
|
|
368
|
-
for (const i of
|
|
369
|
-
const [
|
|
370
|
-
if (typeof
|
|
371
|
-
if (
|
|
372
|
-
throw new Error(`Axis index ${
|
|
373
|
-
|
|
495
|
+
const c = [];
|
|
496
|
+
for (const i of e) {
|
|
497
|
+
const [s, u] = i;
|
|
498
|
+
if (typeof s == "number") {
|
|
499
|
+
if (s < 0 || s >= t.axesSpec.length)
|
|
500
|
+
throw new Error(`Axis index ${s} is out of bounds (0-${t.axesSpec.length - 1})`);
|
|
501
|
+
c.push([s, u]);
|
|
374
502
|
} else {
|
|
375
|
-
const
|
|
376
|
-
if (
|
|
377
|
-
throw new Error(`Axis with name "${
|
|
378
|
-
|
|
503
|
+
const f = t.axesSpec.findIndex((d) => d.name === s);
|
|
504
|
+
if (f === -1)
|
|
505
|
+
throw new Error(`Axis with name "${s}" not found in the column specification`);
|
|
506
|
+
c.push([f, u]);
|
|
379
507
|
}
|
|
380
508
|
}
|
|
381
|
-
return
|
|
509
|
+
return c.sort((i, s) => i[0] - s[0]), {
|
|
382
510
|
source: r,
|
|
383
|
-
axisFilters:
|
|
511
|
+
axisFilters: c
|
|
384
512
|
};
|
|
385
513
|
}
|
|
386
514
|
/**
|
|
@@ -389,326 +517,307 @@ class ut {
|
|
|
389
517
|
* @param axisFilters Optional axis filters to apply to the column
|
|
390
518
|
* @returns A canonicalized string representation of the anchored column identifier
|
|
391
519
|
*/
|
|
392
|
-
deriveS(
|
|
393
|
-
return
|
|
520
|
+
deriveS(t, e) {
|
|
521
|
+
return _(this.derive(t, e));
|
|
394
522
|
}
|
|
395
523
|
}
|
|
396
|
-
function
|
|
397
|
-
const r = { ...
|
|
524
|
+
function Jn(n, t, e) {
|
|
525
|
+
const r = { ...t }, a = (e == null ? void 0 : e.ignoreMissingDomains) ?? !1;
|
|
398
526
|
if (r.domainAnchor !== void 0) {
|
|
399
|
-
const
|
|
400
|
-
if (!
|
|
527
|
+
const c = n[r.domainAnchor];
|
|
528
|
+
if (!c)
|
|
401
529
|
throw new Error(`Anchor "${r.domainAnchor}" not found`);
|
|
402
|
-
const i =
|
|
530
|
+
const i = c.domain || {};
|
|
403
531
|
r.domain = { ...i, ...r.domain }, delete r.domainAnchor;
|
|
404
532
|
}
|
|
405
533
|
if (r.domain) {
|
|
406
|
-
const
|
|
407
|
-
for (const [i,
|
|
408
|
-
if (typeof
|
|
409
|
-
|
|
534
|
+
const c = {};
|
|
535
|
+
for (const [i, s] of Object.entries(r.domain))
|
|
536
|
+
if (typeof s == "string")
|
|
537
|
+
c[i] = s;
|
|
410
538
|
else {
|
|
411
|
-
const
|
|
412
|
-
if (!
|
|
413
|
-
throw new Error(`Anchor "${
|
|
414
|
-
if (!
|
|
539
|
+
const u = n[s.anchor];
|
|
540
|
+
if (!u)
|
|
541
|
+
throw new Error(`Anchor "${s.anchor}" not found for domain key "${i}"`);
|
|
542
|
+
if (!u.domain || u.domain[i] === void 0) {
|
|
415
543
|
if (!a)
|
|
416
|
-
throw new Error(`Domain key "${i}" not found in anchor "${
|
|
544
|
+
throw new Error(`Domain key "${i}" not found in anchor "${s.anchor}"`);
|
|
417
545
|
continue;
|
|
418
546
|
}
|
|
419
|
-
|
|
547
|
+
c[i] = u.domain[i];
|
|
420
548
|
}
|
|
421
|
-
r.domain =
|
|
549
|
+
r.domain = c;
|
|
422
550
|
}
|
|
423
|
-
return r.axes && (r.axes = r.axes.map((
|
|
551
|
+
return r.axes && (r.axes = r.axes.map((c) => z(n, c))), r;
|
|
424
552
|
}
|
|
425
|
-
function
|
|
426
|
-
if (!
|
|
427
|
-
return
|
|
428
|
-
const
|
|
553
|
+
function z(n, t) {
|
|
554
|
+
if (!X(t))
|
|
555
|
+
return t;
|
|
556
|
+
const e = t.anchor, r = n[e];
|
|
429
557
|
if (!r)
|
|
430
|
-
throw new Error(`Anchor "${
|
|
431
|
-
if ("idx" in
|
|
432
|
-
if (
|
|
433
|
-
throw new Error(`Axis index ${
|
|
434
|
-
return r.axesSpec[
|
|
435
|
-
} else if ("name" in
|
|
436
|
-
const a = r.axesSpec.filter((
|
|
558
|
+
throw new Error(`Anchor "${e}" not found for axis reference`);
|
|
559
|
+
if ("idx" in t) {
|
|
560
|
+
if (t.idx < 0 || t.idx >= r.axesSpec.length)
|
|
561
|
+
throw new Error(`Axis index ${t.idx} out of bounds for anchor "${e}"`);
|
|
562
|
+
return r.axesSpec[t.idx];
|
|
563
|
+
} else if ("name" in t) {
|
|
564
|
+
const a = r.axesSpec.filter((c) => c.name === t.name);
|
|
437
565
|
if (a.length > 1)
|
|
438
|
-
throw new Error(`Multiple axes with name "${
|
|
566
|
+
throw new Error(`Multiple axes with name "${t.name}" found in anchor "${e}"`);
|
|
439
567
|
if (a.length === 0)
|
|
440
|
-
throw new Error(`Axis with name "${
|
|
568
|
+
throw new Error(`Axis with name "${t.name}" not found in anchor "${e}"`);
|
|
441
569
|
return a[0];
|
|
442
|
-
} else if ("id" in
|
|
443
|
-
const a = r.axesSpec.filter((
|
|
570
|
+
} else if ("id" in t) {
|
|
571
|
+
const a = r.axesSpec.filter((c) => V(t.id, m(c)));
|
|
444
572
|
if (a.length > 1)
|
|
445
|
-
throw new Error(`Multiple matching axes found for matcher in anchor "${
|
|
573
|
+
throw new Error(`Multiple matching axes found for matcher in anchor "${e}"`);
|
|
446
574
|
if (a.length === 0)
|
|
447
|
-
throw new Error(`No matching axis found for matcher in anchor "${
|
|
575
|
+
throw new Error(`No matching axis found for matcher in anchor "${e}"`);
|
|
448
576
|
return a[0];
|
|
449
577
|
}
|
|
450
578
|
throw new Error("Unsupported axis reference type");
|
|
451
579
|
}
|
|
452
|
-
function
|
|
453
|
-
return typeof
|
|
580
|
+
function X(n) {
|
|
581
|
+
return typeof n == "object" && "anchor" in n;
|
|
454
582
|
}
|
|
455
|
-
function
|
|
456
|
-
return
|
|
583
|
+
function b(n) {
|
|
584
|
+
return n.kind === "PColumn";
|
|
457
585
|
}
|
|
458
|
-
function
|
|
459
|
-
return
|
|
586
|
+
function Q(n) {
|
|
587
|
+
return b(n.spec);
|
|
460
588
|
}
|
|
461
|
-
function
|
|
462
|
-
if (!
|
|
463
|
-
return
|
|
589
|
+
function In(n) {
|
|
590
|
+
if (!Q(n)) throw new Error(`not a PColumn (kind = ${n.spec.kind})`);
|
|
591
|
+
return n;
|
|
464
592
|
}
|
|
465
|
-
function
|
|
466
|
-
return
|
|
467
|
-
...
|
|
468
|
-
data:
|
|
593
|
+
function jn(n, t) {
|
|
594
|
+
return n === void 0 ? void 0 : {
|
|
595
|
+
...n,
|
|
596
|
+
data: t(n.data)
|
|
469
597
|
};
|
|
470
598
|
}
|
|
471
|
-
function
|
|
472
|
-
const
|
|
599
|
+
function Nn(n) {
|
|
600
|
+
const t = /* @__PURE__ */ new Map(), e = (r) => {
|
|
473
601
|
switch (r.type) {
|
|
474
602
|
case "column":
|
|
475
|
-
|
|
603
|
+
t.set(r.column.id, r.column);
|
|
476
604
|
return;
|
|
477
605
|
case "slicedColumn":
|
|
478
|
-
|
|
606
|
+
t.set(r.column.id, r.column);
|
|
479
607
|
return;
|
|
480
608
|
case "inlineColumn":
|
|
481
609
|
return;
|
|
482
610
|
case "full":
|
|
483
611
|
case "inner":
|
|
484
|
-
for (const a of r.entries)
|
|
612
|
+
for (const a of r.entries) e(a);
|
|
485
613
|
return;
|
|
486
614
|
case "outer":
|
|
487
|
-
|
|
488
|
-
for (const a of r.secondary)
|
|
615
|
+
e(r.primary);
|
|
616
|
+
for (const a of r.secondary) e(a);
|
|
489
617
|
return;
|
|
490
618
|
default:
|
|
491
|
-
|
|
619
|
+
w(r);
|
|
492
620
|
}
|
|
493
621
|
};
|
|
494
|
-
return n
|
|
622
|
+
return e(n), [...t.values()];
|
|
495
623
|
}
|
|
496
|
-
function
|
|
497
|
-
if (
|
|
624
|
+
function A(n, t) {
|
|
625
|
+
if (n.name !== void 0 && n.name !== t.name)
|
|
498
626
|
return !1;
|
|
499
|
-
if (
|
|
500
|
-
if (Array.isArray(
|
|
501
|
-
if (!
|
|
627
|
+
if (n.type !== void 0) {
|
|
628
|
+
if (Array.isArray(n.type)) {
|
|
629
|
+
if (!n.type.includes(t.type))
|
|
502
630
|
return !1;
|
|
503
|
-
} else if (
|
|
631
|
+
} else if (n.type !== t.type)
|
|
504
632
|
return !1;
|
|
505
633
|
}
|
|
506
|
-
if (
|
|
507
|
-
const
|
|
508
|
-
for (const [r, a] of Object.entries(
|
|
509
|
-
if (
|
|
634
|
+
if (n.domain !== void 0) {
|
|
635
|
+
const e = t.domain || {};
|
|
636
|
+
for (const [r, a] of Object.entries(n.domain))
|
|
637
|
+
if (e[r] !== a)
|
|
510
638
|
return !1;
|
|
511
639
|
}
|
|
512
640
|
return !0;
|
|
513
641
|
}
|
|
514
|
-
function
|
|
515
|
-
if (
|
|
642
|
+
function k(n, t) {
|
|
643
|
+
if (t.name !== void 0 && n.name !== t.name || t.namePattern !== void 0 && !new RegExp(t.namePattern).test(n.name))
|
|
516
644
|
return !1;
|
|
517
|
-
if (
|
|
518
|
-
if (Array.isArray(
|
|
519
|
-
if (!
|
|
645
|
+
if (t.type !== void 0) {
|
|
646
|
+
if (Array.isArray(t.type)) {
|
|
647
|
+
if (!t.type.includes(n.valueType))
|
|
520
648
|
return !1;
|
|
521
|
-
} else if (
|
|
649
|
+
} else if (t.type !== n.valueType)
|
|
522
650
|
return !1;
|
|
523
651
|
}
|
|
524
|
-
if (
|
|
525
|
-
const
|
|
526
|
-
for (const [r, a] of Object.entries(
|
|
527
|
-
if (
|
|
652
|
+
if (t.domain !== void 0) {
|
|
653
|
+
const e = n.domain || {};
|
|
654
|
+
for (const [r, a] of Object.entries(t.domain))
|
|
655
|
+
if (e[r] !== a)
|
|
528
656
|
return !1;
|
|
529
657
|
}
|
|
530
|
-
if (
|
|
531
|
-
const
|
|
532
|
-
if (
|
|
533
|
-
for (const r of
|
|
534
|
-
if (!
|
|
658
|
+
if (t.axes !== void 0) {
|
|
659
|
+
const e = n.axesSpec.map(m);
|
|
660
|
+
if (t.partialAxesMatch) {
|
|
661
|
+
for (const r of t.axes)
|
|
662
|
+
if (!e.some((a) => A(r, a)))
|
|
535
663
|
return !1;
|
|
536
664
|
} else {
|
|
537
|
-
if (
|
|
665
|
+
if (e.length !== t.axes.length)
|
|
538
666
|
return !1;
|
|
539
|
-
for (let r = 0; r <
|
|
540
|
-
if (!
|
|
667
|
+
for (let r = 0; r < t.axes.length; r++)
|
|
668
|
+
if (!A(t.axes[r], e[r]))
|
|
541
669
|
return !1;
|
|
542
670
|
}
|
|
543
671
|
}
|
|
544
|
-
if (
|
|
545
|
-
const
|
|
546
|
-
for (const [r, a] of Object.entries(
|
|
547
|
-
if (
|
|
672
|
+
if (t.annotations !== void 0) {
|
|
673
|
+
const e = n.annotations || {};
|
|
674
|
+
for (const [r, a] of Object.entries(t.annotations))
|
|
675
|
+
if (e[r] !== a)
|
|
548
676
|
return !1;
|
|
549
677
|
}
|
|
550
|
-
if (
|
|
551
|
-
const
|
|
552
|
-
for (const [r, a] of Object.entries(
|
|
553
|
-
const
|
|
554
|
-
if (
|
|
678
|
+
if (t.annotationPatterns !== void 0) {
|
|
679
|
+
const e = n.annotations || {};
|
|
680
|
+
for (const [r, a] of Object.entries(t.annotationPatterns)) {
|
|
681
|
+
const c = e[r];
|
|
682
|
+
if (c === void 0 || !new RegExp(a).test(c))
|
|
555
683
|
return !1;
|
|
556
684
|
}
|
|
557
685
|
}
|
|
558
686
|
return !0;
|
|
559
687
|
}
|
|
560
|
-
function
|
|
561
|
-
return Array.isArray(
|
|
688
|
+
function Ln(n) {
|
|
689
|
+
return Array.isArray(n) ? (t) => n.some((e) => b(t) && k(t, e)) : (t) => b(t) && k(t, n);
|
|
562
690
|
}
|
|
563
|
-
function
|
|
564
|
-
const
|
|
565
|
-
kind:
|
|
566
|
-
name:
|
|
691
|
+
function Tn(n) {
|
|
692
|
+
const t = {
|
|
693
|
+
kind: n.kind,
|
|
694
|
+
name: n.name
|
|
567
695
|
};
|
|
568
|
-
return
|
|
696
|
+
return n.domain !== void 0 && (t.domain = n.domain), b(n) && (t.axesSpec = B(n.axesSpec)), g(t);
|
|
569
697
|
}
|
|
570
|
-
|
|
571
|
-
__isRef:
|
|
572
|
-
blockId:
|
|
573
|
-
name:
|
|
574
|
-
requireEnrichments:
|
|
698
|
+
o.object({
|
|
699
|
+
__isRef: o.literal(!0).describe("Crucial marker for the block dependency tree reconstruction"),
|
|
700
|
+
blockId: o.string().describe("Upstream block id"),
|
|
701
|
+
name: o.string().describe("Name of the output provided to the upstream block's output context"),
|
|
702
|
+
requireEnrichments: o.literal(!0).optional().describe("True if current block that stores this reference in its args, may need enrichments for the references value originating from the blocks in between current and referenced block")
|
|
575
703
|
}).describe(
|
|
576
704
|
"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."
|
|
577
705
|
).readonly();
|
|
578
|
-
function
|
|
579
|
-
return typeof
|
|
706
|
+
function Cn(n) {
|
|
707
|
+
return typeof n == "object" && n !== null && "__isRef" in n && n.__isRef === !0 && "blockId" in n && "name" in n;
|
|
580
708
|
}
|
|
581
|
-
function
|
|
582
|
-
if (
|
|
709
|
+
function $n(n, t = !0) {
|
|
710
|
+
if (t)
|
|
583
711
|
return {
|
|
584
|
-
...
|
|
712
|
+
...n,
|
|
585
713
|
requireEnrichments: !0
|
|
586
714
|
};
|
|
587
715
|
{
|
|
588
|
-
const { requireEnrichments:
|
|
716
|
+
const { requireEnrichments: e, ...r } = n;
|
|
589
717
|
return r;
|
|
590
718
|
}
|
|
591
719
|
}
|
|
592
|
-
function
|
|
593
|
-
return
|
|
720
|
+
function Dn(n, t) {
|
|
721
|
+
return n.ok ? { ok: !0, value: t(n.value) } : n;
|
|
594
722
|
}
|
|
595
|
-
function
|
|
596
|
-
if (
|
|
597
|
-
return new DataView(
|
|
598
|
-
if (
|
|
723
|
+
function Y(n) {
|
|
724
|
+
if (n instanceof Int8Array || n instanceof Uint8Array || n instanceof Uint8ClampedArray)
|
|
725
|
+
return new DataView(n.buffer, n.byteOffset, n.byteLength);
|
|
726
|
+
if (n instanceof ArrayBuffer) return new DataView(n);
|
|
599
727
|
throw new TypeError(
|
|
600
728
|
"Expected `data` to be an ArrayBuffer, Buffer, Int8Array, Uint8Array or Uint8ClampedArray"
|
|
601
729
|
);
|
|
602
730
|
}
|
|
603
|
-
const
|
|
604
|
-
function
|
|
605
|
-
|
|
731
|
+
const Z = "ABCDEFGHIJKLMNOPQRSTUVWXYZ234567", W = "0123456789ABCDEFGHIJKLMNOPQRSTUV", nn = "0123456789ABCDEFGHJKMNPQRSTVWXYZ";
|
|
732
|
+
function tn(n, t, e) {
|
|
733
|
+
e = e || {};
|
|
606
734
|
let r, a;
|
|
607
|
-
switch (
|
|
735
|
+
switch (t) {
|
|
608
736
|
case "RFC3548":
|
|
609
737
|
case "RFC4648":
|
|
610
|
-
r =
|
|
738
|
+
r = Z, a = !0;
|
|
611
739
|
break;
|
|
612
740
|
case "RFC4648-HEX":
|
|
613
|
-
r =
|
|
741
|
+
r = W, a = !0;
|
|
614
742
|
break;
|
|
615
743
|
case "Crockford":
|
|
616
|
-
r =
|
|
744
|
+
r = nn, a = !1;
|
|
617
745
|
break;
|
|
618
746
|
default:
|
|
619
|
-
throw new Error("Unknown base32 variant: " + String(
|
|
747
|
+
throw new Error("Unknown base32 variant: " + String(t));
|
|
620
748
|
}
|
|
621
|
-
const
|
|
622
|
-
let
|
|
749
|
+
const c = e.padding !== void 0 ? e.padding : a, i = Y(n);
|
|
750
|
+
let s = 0, u = 0, f = "";
|
|
623
751
|
for (let d = 0; d < i.byteLength; d++)
|
|
624
|
-
for (
|
|
625
|
-
|
|
626
|
-
if (
|
|
627
|
-
for (;
|
|
628
|
-
|
|
629
|
-
return
|
|
630
|
-
}
|
|
631
|
-
const
|
|
632
|
-
function
|
|
633
|
-
const
|
|
634
|
-
return crypto.getRandomValues(
|
|
635
|
-
}
|
|
636
|
-
function vt(t) {
|
|
637
|
-
return p(t);
|
|
638
|
-
}
|
|
639
|
-
function Pt(t) {
|
|
640
|
-
return JSON.parse(t);
|
|
641
|
-
}
|
|
642
|
-
function H(t) {
|
|
643
|
-
return t instanceof Error ? t.name === "AbortError" || H(t.cause) : !1;
|
|
644
|
-
}
|
|
645
|
-
function Q(t) {
|
|
646
|
-
if (typeof t == "string")
|
|
647
|
-
return `String value was thrown: ${t}`;
|
|
648
|
-
if (t && typeof t == "object")
|
|
649
|
-
try {
|
|
650
|
-
return `Plain object was thrown: ${JSON.stringify(t)}`;
|
|
651
|
-
} catch (e) {
|
|
652
|
-
return `Non-serializable object was thrown (JSON.stringify failed: ${e instanceof Error ? e.message : String(e)}): ${String(t)}`;
|
|
653
|
-
}
|
|
654
|
-
return `Non-Error value (${typeof t}) was thrown: ${t}`;
|
|
655
|
-
}
|
|
656
|
-
function xt(t) {
|
|
657
|
-
return t instanceof Error ? t : new Error(Q(t));
|
|
658
|
-
}
|
|
659
|
-
function E(t) {
|
|
660
|
-
const e = t.cause ? E(t.cause) : void 0, n = new Error(t.message, e !== void 0 ? { cause: e } : void 0);
|
|
661
|
-
return n.name = t.name || "Error", n.stack = t.stack, n;
|
|
662
|
-
}
|
|
663
|
-
function At(t) {
|
|
664
|
-
if (t.error)
|
|
665
|
-
throw t.error instanceof Error ? t.error : E(t.error);
|
|
666
|
-
return t.value;
|
|
752
|
+
for (u = u << 8 | i.getUint8(d), s += 8; s >= 5; )
|
|
753
|
+
f += r[u >>> s - 5 & 31], s -= 5;
|
|
754
|
+
if (s > 0 && (f += r[u << 5 - s & 31]), c)
|
|
755
|
+
for (; f.length % 8 !== 0; )
|
|
756
|
+
f += "=";
|
|
757
|
+
return f;
|
|
758
|
+
}
|
|
759
|
+
const en = 15, rn = 24, an = o.string().length(rn).regex(/[ABCDEFGHIJKLMNOPQRSTUVWXYZ234567]/).brand("PlId");
|
|
760
|
+
function Fn() {
|
|
761
|
+
const n = new Uint8Array(en);
|
|
762
|
+
return crypto.getRandomValues(n), an.parse(tn(n, "RFC4648"));
|
|
667
763
|
}
|
|
668
764
|
export {
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
765
|
+
On as AnchoredIdDeriver,
|
|
766
|
+
p as Annotation,
|
|
767
|
+
M as AnnotationJson,
|
|
768
|
+
F as AxisSpec,
|
|
769
|
+
hn as Domain,
|
|
770
|
+
vn as PColumnName,
|
|
771
|
+
K as PTableAbsent,
|
|
772
|
+
O as PTableNA,
|
|
773
|
+
an as PlId,
|
|
774
|
+
en as PlIdBytes,
|
|
775
|
+
rn as PlIdLength,
|
|
776
|
+
l as ValueType,
|
|
777
|
+
Pn as canonicalizeAxisId,
|
|
778
|
+
C as canonicalizeJson,
|
|
779
|
+
ln as dataInfoToEntries,
|
|
780
|
+
Tn as deriveNativeId,
|
|
679
781
|
E as deserializeError,
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
782
|
+
T as ensureError,
|
|
783
|
+
In as ensurePColumn,
|
|
784
|
+
pn as entriesToDataInfo,
|
|
785
|
+
Nn as extractAllColumns,
|
|
786
|
+
B as getAxesId,
|
|
787
|
+
m as getAxisId,
|
|
788
|
+
Sn as getPTableColumnId,
|
|
789
|
+
N as hasAbortError,
|
|
790
|
+
cn as isDataInfo,
|
|
791
|
+
j as isDataInfoEntries,
|
|
792
|
+
Q as isPColumn,
|
|
793
|
+
b as isPColumnSpec,
|
|
794
|
+
xn as isPTableAbsent,
|
|
795
|
+
G as isPTableNA,
|
|
796
|
+
An as isPTableValueAxis,
|
|
797
|
+
fn as isPartitionedDataInfoEntries,
|
|
798
|
+
Cn as isPlRef,
|
|
799
|
+
un as mapDataInfo,
|
|
800
|
+
h as mapJoinEntry,
|
|
801
|
+
jn as mapPObjectData,
|
|
802
|
+
En as mapPTableDef,
|
|
803
|
+
Dn as mapValueInVOE,
|
|
804
|
+
A as matchAxis,
|
|
805
|
+
V as matchAxisId,
|
|
806
|
+
k as matchPColumn,
|
|
807
|
+
kn as pTableValue,
|
|
808
|
+
yn as parseJson,
|
|
809
|
+
gn as readAnnotation,
|
|
810
|
+
wn as readAnnotationJson,
|
|
811
|
+
bn as readDomain,
|
|
812
|
+
v as readMetadata,
|
|
813
|
+
D as readMetadataJson,
|
|
814
|
+
$ as readMetadataJsonOrThrow,
|
|
815
|
+
Jn as resolveAnchors,
|
|
816
|
+
Ln as selectorsToPredicate,
|
|
817
|
+
_ as stringifyColumnId,
|
|
818
|
+
mn as stringifyJson,
|
|
819
|
+
Fn as uniquePlId,
|
|
820
|
+
dn as unwrapResult,
|
|
821
|
+
$n as withEnrichments
|
|
713
822
|
};
|
|
714
823
|
//# sourceMappingURL=index.js.map
|