@nubisco/ui 1.57.1 → 1.58.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Blueprint.vue.d.ts +9 -1
- package/dist/components/Blueprint.vue.d.ts.map +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +33 -29
- package/dist/index.mjs.map +1 -1
- package/dist/ui.css +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -23773,32 +23773,35 @@ var Y$t = {
|
|
|
23773
23773
|
function St(e) {
|
|
23774
23774
|
return r.animateConnections === "never" ? !1 : r.animateConnections === "always" ? !0 : r.animateConnections === "levels" ? !1 : e.active !== !1;
|
|
23775
23775
|
}
|
|
23776
|
-
function Ct() {
|
|
23777
|
-
let
|
|
23776
|
+
function Ct(e) {
|
|
23777
|
+
let t = Infinity, n = Infinity, i = -Infinity, a = -Infinity, o = e && e.length ? new Set(e) : null, s = 0;
|
|
23778
23778
|
if (r.cards) {
|
|
23779
23779
|
if (r.cards.length === 0) return null;
|
|
23780
|
-
for (let
|
|
23781
|
-
|
|
23782
|
-
|
|
23780
|
+
for (let e of r.cards) {
|
|
23781
|
+
if (o && !o.has(e.id)) continue;
|
|
23782
|
+
let { w: r, h: c } = bt(e);
|
|
23783
|
+
t = Math.min(t, e.x), n = Math.min(n, e.y), i = Math.max(i, e.x + r), a = Math.max(a, e.y + c), s++;
|
|
23783
23784
|
}
|
|
23784
|
-
return {
|
|
23785
|
-
minX:
|
|
23786
|
-
minY:
|
|
23787
|
-
maxX:
|
|
23788
|
-
maxY:
|
|
23789
|
-
};
|
|
23785
|
+
return s > 0 ? {
|
|
23786
|
+
minX: t,
|
|
23787
|
+
minY: n,
|
|
23788
|
+
maxX: i,
|
|
23789
|
+
maxY: a
|
|
23790
|
+
} : null;
|
|
23790
23791
|
}
|
|
23791
23792
|
if (!v.value) return null;
|
|
23792
|
-
let
|
|
23793
|
-
return
|
|
23794
|
-
let
|
|
23795
|
-
|
|
23796
|
-
|
|
23797
|
-
|
|
23798
|
-
|
|
23799
|
-
|
|
23800
|
-
|
|
23801
|
-
|
|
23793
|
+
let c = v.value.querySelectorAll("[data-card-id]");
|
|
23794
|
+
return c.length === 0 ? null : (c.forEach((e) => {
|
|
23795
|
+
let r = e;
|
|
23796
|
+
if (o && !o.has(r.getAttribute("data-card-id") ?? "")) return;
|
|
23797
|
+
let c = Fe(r), l = r.offsetWidth, u = r.offsetHeight;
|
|
23798
|
+
t = Math.min(t, c.x), n = Math.min(n, c.y), i = Math.max(i, c.x + l), a = Math.max(a, c.y + u), s++;
|
|
23799
|
+
}), s > 0 ? {
|
|
23800
|
+
minX: t,
|
|
23801
|
+
minY: n,
|
|
23802
|
+
maxX: i,
|
|
23803
|
+
maxY: a
|
|
23804
|
+
} : null);
|
|
23802
23805
|
}
|
|
23803
23806
|
function wt() {
|
|
23804
23807
|
if (k.value = 1, !v.value) return;
|
|
@@ -23810,20 +23813,21 @@ var Y$t = {
|
|
|
23810
23813
|
let t = v.value.getBoundingClientRect(), n = (e.minX + e.maxX) / 2, r = (e.minY + e.maxY) / 2;
|
|
23811
23814
|
w.value = t.width / 2 - n, D.value = t.height / 2 - r;
|
|
23812
23815
|
}
|
|
23813
|
-
function Tt(e = 40) {
|
|
23816
|
+
function Tt(e = 40, t) {
|
|
23814
23817
|
if (!v.value) return;
|
|
23815
|
-
let
|
|
23816
|
-
if (!
|
|
23818
|
+
let n = Ct(t);
|
|
23819
|
+
if (!n) {
|
|
23820
|
+
if (t && t.length) return;
|
|
23817
23821
|
Et();
|
|
23818
23822
|
return;
|
|
23819
23823
|
}
|
|
23820
|
-
let
|
|
23821
|
-
if (
|
|
23824
|
+
let r = v.value.getBoundingClientRect(), i = n.maxX - n.minX, a = n.maxY - n.minY;
|
|
23825
|
+
if (i <= 0 || a <= 0) {
|
|
23822
23826
|
wt();
|
|
23823
23827
|
return;
|
|
23824
23828
|
}
|
|
23825
|
-
let
|
|
23826
|
-
k.value =
|
|
23829
|
+
let o = r.width - e * 2, s = r.height - e * 2, c = o / i, l = s / a, u = Math.max(x9, Math.min(S9, Math.min(c, l))), d = (n.minX + n.maxX) / 2, f = (n.minY + n.maxY) / 2;
|
|
23830
|
+
k.value = u, w.value = r.width / 2 - d * u, D.value = r.height / 2 - f * u;
|
|
23827
23831
|
}
|
|
23828
23832
|
function Et() {
|
|
23829
23833
|
w.value = 0, D.value = 0, k.value = 1;
|
|
@@ -24152,7 +24156,7 @@ var Y$t = {
|
|
|
24152
24156
|
u("div", X$t, [A(t.$slots, "chrome", {}, void 0, !0)])
|
|
24153
24157
|
], 34));
|
|
24154
24158
|
}
|
|
24155
|
-
}), [["__scopeId", "data-v-
|
|
24159
|
+
}), [["__scopeId", "data-v-0dfaf0e3"]]);
|
|
24156
24160
|
//#endregion
|
|
24157
24161
|
//#region src/composables/useBlueprint.composable.ts
|
|
24158
24162
|
function E9() {
|