@milaboratories/milaboratories.ui-examples.model 1.1.6 → 1.1.7
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 +7 -0
- package/dist/bundle.js +45 -42
- package/dist/bundle.js.map +1 -1
- package/dist/model.json +1 -1
- package/package.json +3 -3
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
> @milaboratories/milaboratories.ui-examples.model@1.1.
|
|
2
|
+
> @milaboratories/milaboratories.ui-examples.model@1.1.7 build /home/runner/work/platforma/platforma/etc/blocks/ui-examples/model
|
|
3
3
|
> tsup && vite build && block-tools build-model
|
|
4
4
|
|
|
5
5
|
[34mCLI[39m Building entry: src/index.ts
|
|
@@ -12,12 +12,12 @@
|
|
|
12
12
|
[34mESM[39m Build start
|
|
13
13
|
[32mCJS[39m [1mdist/index.cjs [22m[32m2.53 KB[39m
|
|
14
14
|
[32mCJS[39m [1mdist/index.cjs.map [22m[32m5.88 KB[39m
|
|
15
|
-
[32mCJS[39m ⚡️ Build success in
|
|
15
|
+
[32mCJS[39m ⚡️ Build success in 71ms
|
|
16
16
|
[32mESM[39m [1mdist/index.js [22m[32m2.48 KB[39m
|
|
17
17
|
[32mESM[39m [1mdist/index.js.map [22m[32m5.84 KB[39m
|
|
18
|
-
[32mESM[39m ⚡️ Build success in
|
|
18
|
+
[32mESM[39m ⚡️ Build success in 71ms
|
|
19
19
|
[34mDTS[39m Build start
|
|
20
|
-
[32mDTS[39m ⚡️ Build success in
|
|
20
|
+
[32mDTS[39m ⚡️ Build success in 802ms
|
|
21
21
|
[32mDTS[39m [1mdist/index.d.cts [22m[32m1.30 KB[39m
|
|
22
22
|
[32mDTS[39m [1mdist/index.d.ts [22m[32m1.30 KB[39m
|
|
23
23
|
[36mvite v5.4.11 [32mbuilding for production...[36m[39m
|
|
@@ -25,6 +25,6 @@ transforming...
|
|
|
25
25
|
[32m✓[39m 4 modules transformed.
|
|
26
26
|
rendering chunks...
|
|
27
27
|
computing gzip size...
|
|
28
|
-
[2mdist/[22m[36mbundle.js [39m[1m[2m143.
|
|
29
|
-
[2mdist/[22m[36mbundle.js [39m[1m[2m154.
|
|
30
|
-
[32m✓ built in
|
|
28
|
+
[2mdist/[22m[36mbundle.js [39m[1m[2m143.95 kB[22m[1m[22m[2m │ gzip: 26.17 kB[22m[2m │ map: 313.62 kB[22m
|
|
29
|
+
[2mdist/[22m[36mbundle.js [39m[1m[2m154.14 kB[22m[1m[22m[2m │ gzip: 26.66 kB[22m[2m │ map: 314.75 kB[22m
|
|
30
|
+
[32m✓ built in 401ms[39m
|
package/CHANGELOG.md
CHANGED
package/dist/bundle.js
CHANGED
|
@@ -3914,27 +3914,27 @@
|
|
|
3914
3914
|
quotelessJson,
|
|
3915
3915
|
ZodError
|
|
3916
3916
|
});
|
|
3917
|
-
function
|
|
3917
|
+
function b$1(t) {
|
|
3918
3918
|
throw new Error("Unexpected object: " + t);
|
|
3919
3919
|
}
|
|
3920
|
-
function
|
|
3920
|
+
function J$1(t) {
|
|
3921
3921
|
const { type: n, name: e, domain: r } = t;
|
|
3922
3922
|
return { type: n, name: e, ...r && { domain: r } };
|
|
3923
3923
|
}
|
|
3924
|
-
function
|
|
3924
|
+
function _$1(t, n) {
|
|
3925
3925
|
if (t === void 0) return n === void 0;
|
|
3926
3926
|
if (n === void 0) return true;
|
|
3927
3927
|
for (const e in n)
|
|
3928
3928
|
if (t[e] !== n[e]) return false;
|
|
3929
3929
|
return true;
|
|
3930
3930
|
}
|
|
3931
|
-
function
|
|
3932
|
-
return t.name === n.name &&
|
|
3931
|
+
function ot$1(t, n) {
|
|
3932
|
+
return t.name === n.name && _$1(t.domain, n.domain);
|
|
3933
3933
|
}
|
|
3934
|
-
function
|
|
3935
|
-
return { ...t, src:
|
|
3934
|
+
function it$1(t, n) {
|
|
3935
|
+
return { ...t, src: f(t.src, n) };
|
|
3936
3936
|
}
|
|
3937
|
-
function
|
|
3937
|
+
function f(t, n) {
|
|
3938
3938
|
switch (t.type) {
|
|
3939
3939
|
case "column":
|
|
3940
3940
|
return {
|
|
@@ -3945,16 +3945,16 @@
|
|
|
3945
3945
|
case "full":
|
|
3946
3946
|
return {
|
|
3947
3947
|
type: t.type,
|
|
3948
|
-
entries: t.entries.map((e) =>
|
|
3948
|
+
entries: t.entries.map((e) => f(e, n))
|
|
3949
3949
|
};
|
|
3950
3950
|
case "outer":
|
|
3951
3951
|
return {
|
|
3952
3952
|
type: "outer",
|
|
3953
|
-
primary:
|
|
3954
|
-
secondary: t.secondary.map((e) =>
|
|
3953
|
+
primary: f(t.primary, n),
|
|
3954
|
+
secondary: t.secondary.map((e) => f(e, n))
|
|
3955
3955
|
};
|
|
3956
3956
|
default:
|
|
3957
|
-
|
|
3957
|
+
b$1(t);
|
|
3958
3958
|
}
|
|
3959
3959
|
}
|
|
3960
3960
|
z.object({
|
|
@@ -3967,20 +3967,20 @@
|
|
|
3967
3967
|
function i(t) {
|
|
3968
3968
|
return t.kind === "PColumn";
|
|
3969
3969
|
}
|
|
3970
|
-
function
|
|
3970
|
+
function W(t) {
|
|
3971
3971
|
return i(t.spec);
|
|
3972
3972
|
}
|
|
3973
|
-
function
|
|
3974
|
-
if (!
|
|
3973
|
+
function dt$1(t) {
|
|
3974
|
+
if (!W(t)) throw new Error(`not a PColumn (kind = ${t.spec.kind})`);
|
|
3975
3975
|
return t;
|
|
3976
3976
|
}
|
|
3977
|
-
function
|
|
3977
|
+
function lt(t, n) {
|
|
3978
3978
|
return t === void 0 ? void 0 : {
|
|
3979
3979
|
...t,
|
|
3980
3980
|
data: n(t.data)
|
|
3981
3981
|
};
|
|
3982
3982
|
}
|
|
3983
|
-
function
|
|
3983
|
+
function pt$1(t) {
|
|
3984
3984
|
const n = /* @__PURE__ */ new Map(), e = (r) => {
|
|
3985
3985
|
switch (r.type) {
|
|
3986
3986
|
case "column":
|
|
@@ -3995,14 +3995,16 @@
|
|
|
3995
3995
|
for (const o of r.secondary) e(o);
|
|
3996
3996
|
return;
|
|
3997
3997
|
default:
|
|
3998
|
-
|
|
3998
|
+
b$1(r);
|
|
3999
3999
|
}
|
|
4000
4000
|
};
|
|
4001
4001
|
return e(t), [...n.values()];
|
|
4002
4002
|
}
|
|
4003
|
-
function
|
|
4003
|
+
function mt(t, n) {
|
|
4004
4004
|
return t.ok ? { ok: true, value: n(t.value) } : t;
|
|
4005
4005
|
}
|
|
4006
|
+
const Q = 24;
|
|
4007
|
+
z.string().length(Q).regex(/[ABCDEFGHIJKLMNOPQRSTUVWXYZ234567]/).brand("PlId");
|
|
4006
4008
|
var dt = Object.defineProperty;
|
|
4007
4009
|
var pt = (e, t, n) => t in e ? dt(e, t, { enumerable: true, configurable: true, writable: true, value: n }) : e[t] = n;
|
|
4008
4010
|
var S = (e, t, n) => pt(e, typeof t != "symbol" ? t + "" : t, n);
|
|
@@ -4165,7 +4167,7 @@
|
|
|
4165
4167
|
getPColumns(t = false, n = "") {
|
|
4166
4168
|
const s = this.parsePObjectCollection(t, n);
|
|
4167
4169
|
return s === void 0 ? void 0 : Object.entries(s).map(([, r]) => {
|
|
4168
|
-
if (!
|
|
4170
|
+
if (!W(r)) throw new Error(`not a PColumn (kind = ${r.spec.kind})`);
|
|
4169
4171
|
return r;
|
|
4170
4172
|
});
|
|
4171
4173
|
}
|
|
@@ -4183,7 +4185,7 @@
|
|
|
4183
4185
|
const i2 = {};
|
|
4184
4186
|
for (const [r, o] of Object.entries(s)) {
|
|
4185
4187
|
const l = [...this.resolvePath, r];
|
|
4186
|
-
i2[r] =
|
|
4188
|
+
i2[r] = lt(o, (d) => new _(d, l));
|
|
4187
4189
|
}
|
|
4188
4190
|
return i2;
|
|
4189
4191
|
}
|
|
@@ -4288,10 +4290,10 @@
|
|
|
4288
4290
|
const w = { label: h, type: Ot, importance: -2 };
|
|
4289
4291
|
n.addLabelAsSuffix ? y.push(w) : y.splice(0, 0, w);
|
|
4290
4292
|
}
|
|
4291
|
-
const C = [],
|
|
4293
|
+
const C = [], q = /* @__PURE__ */ new Map();
|
|
4292
4294
|
for (let w = y.length - 1; w >= 0; --w) {
|
|
4293
|
-
const { type: V } = y[w], ct = y[w].importance ?? 0, j = (
|
|
4294
|
-
|
|
4295
|
+
const { type: V } = y[w], ct = y[w].importance ?? 0, j = (q.get(V) ?? 0) + 1;
|
|
4296
|
+
q.set(V, j);
|
|
4295
4297
|
const R = `${V}@${j}`;
|
|
4296
4298
|
i2.set(R, (i2.get(R) ?? 0) + 1), s.set(
|
|
4297
4299
|
R,
|
|
@@ -4391,7 +4393,7 @@
|
|
|
4391
4393
|
ref: n.ref,
|
|
4392
4394
|
obj: {
|
|
4393
4395
|
...n.obj,
|
|
4394
|
-
data:
|
|
4396
|
+
data: mt(
|
|
4395
4397
|
n.obj.data,
|
|
4396
4398
|
(s) => new _(s, [n.ref.blockId, n.ref.name])
|
|
4397
4399
|
)
|
|
@@ -4416,7 +4418,7 @@
|
|
|
4416
4418
|
var n;
|
|
4417
4419
|
return typeof this.ctx.getDataFromResultPoolByRef > "u" ? (n = this.getData().entries.find(
|
|
4418
4420
|
(s) => s.ref.blockId === t.blockId && s.ref.name === t.name
|
|
4419
|
-
)) == null ? void 0 : n.obj :
|
|
4421
|
+
)) == null ? void 0 : n.obj : lt(
|
|
4420
4422
|
this.ctx.getDataFromResultPoolByRef(t.blockId, t.name),
|
|
4421
4423
|
(s) => new _(s, [t.blockId, t.name])
|
|
4422
4424
|
);
|
|
@@ -4429,7 +4431,7 @@
|
|
|
4429
4431
|
getPColumnByRef(t) {
|
|
4430
4432
|
const n = this.getDataByRef(t);
|
|
4431
4433
|
if (n)
|
|
4432
|
-
return
|
|
4434
|
+
return dt$1(n);
|
|
4433
4435
|
}
|
|
4434
4436
|
/**
|
|
4435
4437
|
* Returns spec associated with the ref ensuring that it is a p-column spec.
|
|
@@ -4489,7 +4491,7 @@
|
|
|
4489
4491
|
S(this, "args");
|
|
4490
4492
|
S(this, "uiState");
|
|
4491
4493
|
S(this, "resultPool", new Dt());
|
|
4492
|
-
this.ctx = u(), this.args = JSON.parse(this.ctx.args), this.uiState = this.ctx.uiState !== void 0 ? JSON.parse(this.ctx.uiState) :
|
|
4494
|
+
this.ctx = u(), this.args = JSON.parse(this.ctx.args), this.uiState = this.ctx.uiState !== void 0 ? JSON.parse(this.ctx.uiState) : {};
|
|
4493
4495
|
}
|
|
4494
4496
|
getNamedAccessor(t) {
|
|
4495
4497
|
return J(
|
|
@@ -4528,7 +4530,7 @@
|
|
|
4528
4530
|
findLabels(t) {
|
|
4529
4531
|
const n = this.resultPool.getData();
|
|
4530
4532
|
for (const s of n.entries) {
|
|
4531
|
-
if (!
|
|
4533
|
+
if (!W(s.obj)) continue;
|
|
4532
4534
|
const i2 = s.obj.spec;
|
|
4533
4535
|
if (i2.name === "pl7.app/label" && i2.axesSpec.length === 1 && i2.axesSpec[0].name === t.name && i2.axesSpec[0].type === t.type && K(t.domain, i2.axesSpec[0].domain)) {
|
|
4534
4536
|
if (s.obj.data.resourceType.name !== "PColumnData/Json")
|
|
@@ -4547,10 +4549,9 @@
|
|
|
4547
4549
|
if (n && !s) throw Error("inline columns not supported");
|
|
4548
4550
|
}
|
|
4549
4551
|
createPFrame(t) {
|
|
4550
|
-
return this.verifyInlineColumnsSupport(t), this.ctx.createPFrame(
|
|
4551
|
-
n,
|
|
4552
|
-
|
|
4553
|
-
)));
|
|
4552
|
+
return this.verifyInlineColumnsSupport(t), this.ctx.createPFrame(
|
|
4553
|
+
t.map((n) => lt(n, (s) => s instanceof _ ? s.handle : s))
|
|
4554
|
+
);
|
|
4554
4555
|
}
|
|
4555
4556
|
createPTable(t) {
|
|
4556
4557
|
var n;
|
|
@@ -4561,10 +4562,12 @@
|
|
|
4561
4562
|
},
|
|
4562
4563
|
filters: t.filters ?? [],
|
|
4563
4564
|
sorting: t.sorting ?? []
|
|
4564
|
-
} : n = t, this.verifyInlineColumnsSupport(
|
|
4565
|
-
|
|
4566
|
-
|
|
4567
|
-
|
|
4565
|
+
} : n = t, this.verifyInlineColumnsSupport(pt$1(n.src)), this.ctx.createPTable(
|
|
4566
|
+
it$1(
|
|
4567
|
+
n,
|
|
4568
|
+
(s) => lt(s, (i2) => i2 instanceof _ ? i2.handle : i2)
|
|
4569
|
+
)
|
|
4570
|
+
);
|
|
4568
4571
|
}
|
|
4569
4572
|
/** @deprecated scheduled for removal from SDK */
|
|
4570
4573
|
getBlockLabel(t) {
|
|
@@ -4575,7 +4578,7 @@
|
|
|
4575
4578
|
return this.ctx.getCurrentUnstableMarker();
|
|
4576
4579
|
}
|
|
4577
4580
|
}
|
|
4578
|
-
const F = "1.20.
|
|
4581
|
+
const F = "1.20.27";
|
|
4579
4582
|
function xt(e) {
|
|
4580
4583
|
return e.__renderLambda === true;
|
|
4581
4584
|
}
|
|
@@ -4764,7 +4767,7 @@
|
|
|
4764
4767
|
}
|
|
4765
4768
|
function me(e, t, n, s) {
|
|
4766
4769
|
var l, d;
|
|
4767
|
-
const i2 = e.resultPool.getData().entries.map((a) => a.obj).filter(
|
|
4770
|
+
const i2 = e.resultPool.getData().entries.map((a) => a.obj).filter(W).filter((a) => a.spec.name === "pl7.app/label" && a.spec.axesSpec.length === 1), r = (a, p) => {
|
|
4768
4771
|
let g = a.toString();
|
|
4769
4772
|
if (p)
|
|
4770
4773
|
for (const c in p)
|
|
@@ -4773,10 +4776,10 @@
|
|
|
4773
4776
|
}, o = /* @__PURE__ */ new Map();
|
|
4774
4777
|
for (const a of t)
|
|
4775
4778
|
for (const p of a.spec.axesSpec) {
|
|
4776
|
-
const g =
|
|
4779
|
+
const g = J$1(p);
|
|
4777
4780
|
for (const c of i2) {
|
|
4778
|
-
const m = c.spec.axesSpec[0], h =
|
|
4779
|
-
if (
|
|
4781
|
+
const m = c.spec.axesSpec[0], h = J$1(c.spec.axesSpec[0]);
|
|
4782
|
+
if (ot$1(g, h)) {
|
|
4780
4783
|
const P = Object.keys(g.domain ?? {}).length, y = Object.keys(h.domain ?? {}).length;
|
|
4781
4784
|
if (P > y) {
|
|
4782
4785
|
const C = r(c.id, g.domain);
|