@dynamix-layout/solid 1.0.1 → 1.0.3

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/index.es.js CHANGED
@@ -1,15 +1,15 @@
1
- import { spread as _, mergeProps as k, insert as R, memo as xe, effect as Pe, template as F, createComponent as N, use as We } from "solid-js/web";
2
- import { DynamixLayoutCore as P, Node as C } from "@dynamix-layout/core";
3
- import { splitProps as Ie, createMemo as ve, createSignal as Z, onMount as Le, onCleanup as _e, For as ee } from "solid-js";
4
- var X = F("<div>"), ke = F("<div><div>"), Ae = F('<svg xmlns=http://www.w3.org/2000/svg width=24 height=24 viewBox="0 0 24 24"fill=none stroke=currentColor stroke-width=2 stroke-linecap=round stroke-linejoin=round class="lucide lucide-grip-vertical size-2.5"><circle cx=9 cy=12 r=1></circle><circle cx=9 cy=5 r=1></circle><circle cx=9 cy=19 r=1></circle><circle cx=15 cy=12 r=1></circle><circle cx=15 cy=5 r=1></circle><circle cx=15 cy=19 r=1>'), Be = F('<svg xmlns=http://www.w3.org/2000/svg width=24 height=24 viewBox="0 0 24 24"fill=none stroke=currentColor stroke-width=2 stroke-linecap=round stroke-linejoin=round><circle cx=9 cy=12 r=1></circle><circle cx=9 cy=5 r=1></circle><circle cx=9 cy=19 r=1></circle><circle cx=15 cy=12 r=1></circle><circle cx=15 cy=5 r=1></circle><circle cx=15 cy=19 r=1>');
5
- const Me = (n) => (() => {
6
- var o = X();
7
- return _(o, k(n, {
1
+ import { spread as T, mergeProps as $, insert as y, memo as ie, effect as Ee, setStyleProperty as De, template as H, createComponent as v, use as Te } from "solid-js/web";
2
+ import { DynamixLayoutCore as D, Node as x, setElementRect as Y, createFrameScheduler as $e, getTabBodyRect as Se, getNavbarDropPreview as Ne, getRootSplitPreview as Re, isSameDropPreview as ze, getTabsetDropPreview as Oe } from "@dynamix-layout/core";
3
+ import { splitProps as He, createMemo as se, createSignal as W, onMount as Pe, onCleanup as Ce, For as L } from "solid-js";
4
+ var P = H("<div>"), _e = H("<div><div style=display:flex;align-items:center;gap:4px;height:100%>"), Ie = H('<svg xmlns=http://www.w3.org/2000/svg width=24 height=24 viewBox="0 0 24 24"fill=none stroke=currentColor stroke-width=2 stroke-linecap=round stroke-linejoin=round class="lucide lucide-grip-vertical size-2.5"><circle cx=9 cy=12 r=1></circle><circle cx=9 cy=5 r=1></circle><circle cx=9 cy=19 r=1></circle><circle cx=15 cy=12 r=1></circle><circle cx=15 cy=5 r=1></circle><circle cx=15 cy=19 r=1>'), We = H('<svg xmlns=http://www.w3.org/2000/svg width=24 height=24 viewBox="0 0 24 24"fill=none stroke=currentColor stroke-width=2 stroke-linecap=round stroke-linejoin=round style=transform:rotate(90deg)><circle cx=9 cy=12 r=1></circle><circle cx=9 cy=5 r=1></circle><circle cx=9 cy=19 r=1></circle><circle cx=15 cy=12 r=1></circle><circle cx=15 cy=5 r=1></circle><circle cx=15 cy=19 r=1>');
5
+ const Le = (e) => (() => {
6
+ var a = P();
7
+ return T(a, $(e, {
8
8
  get class() {
9
- return `DefaultWrapTabLabel ${n.class || ""}`;
9
+ return `DefaultWrapTabLabel ${e.class || ""}`;
10
10
  },
11
11
  get "data-state"() {
12
- return n.active ? "active" : "inactive";
12
+ return e.active ? "active" : "inactive";
13
13
  },
14
14
  get style() {
15
15
  return {
@@ -18,15 +18,15 @@ const Me = (n) => (() => {
18
18
  "box-sizing": "border-box",
19
19
  "font-size": "14px",
20
20
  "border-radius": "4px",
21
- ...n.style
21
+ ...e.style
22
22
  };
23
23
  }
24
- }), !1, !0), R(o, () => n.children), o;
25
- })(), je = (n) => (() => {
26
- var o = X();
27
- return _(o, k(n, {
24
+ }), !1, !0), y(a, () => e.children), a;
25
+ })(), ke = (e) => (() => {
26
+ var a = P();
27
+ return T(a, $(e, {
28
28
  get class() {
29
- return `DefaultWrapTabBody hide-scrollbar ${n.class || ""}`;
29
+ return `DefaultWrapTabBody hide-scrollbar ${e.class || ""}`;
30
30
  },
31
31
  get style() {
32
32
  return {
@@ -37,15 +37,15 @@ const Me = (n) => (() => {
37
37
  overflow: "auto",
38
38
  "scrollbar-width": "none",
39
39
  "-ms-overflow-style": "none",
40
- ...n.style
40
+ ...e.style
41
41
  };
42
42
  }
43
- }), !1, !0), R(o, () => n.children), o;
44
- })(), Ue = (n) => (() => {
45
- var o = X();
46
- return _(o, k(n, {
43
+ }), !1, !0), y(a, () => e.children), a;
44
+ })(), Be = (e) => (() => {
45
+ var a = P();
46
+ return T(a, $(e, {
47
47
  get class() {
48
- return `DefaultWrapTabHead hide-scrollbar ${n.class || ""}`;
48
+ return `DefaultWrapTabHead hide-scrollbar ${e.class || ""}`;
49
49
  },
50
50
  get style() {
51
51
  return {
@@ -63,15 +63,15 @@ const Me = (n) => (() => {
63
63
  "background-color": "#dfdfdf",
64
64
  "scrollbar-width": "none",
65
65
  "-ms-overflow-style": "none",
66
- ...n.style
66
+ ...e.style
67
67
  };
68
68
  }
69
- }), !1, !0), R(o, () => n.children), o;
70
- })(), Fe = (n) => (() => {
71
- var o = X();
72
- return _(o, k(n, {
69
+ }), !1, !0), y(a, () => e.children), a;
70
+ })(), Me = (e) => (() => {
71
+ var a = P();
72
+ return T(a, $(e, {
73
73
  get class() {
74
- return `DefaultWrapTabPanel ${n.class || ""}`;
74
+ return `DefaultWrapTabPanel ${e.class || ""}`;
75
75
  },
76
76
  get style() {
77
77
  return {
@@ -81,15 +81,15 @@ const Me = (n) => (() => {
81
81
  "box-sizing": "border-box",
82
82
  position: "absolute",
83
83
  "border-radius": "8px",
84
- ...n.style
84
+ ...e.style
85
85
  };
86
86
  }
87
- }), !1, !0), R(o, () => n.children), o;
88
- })(), Xe = (n) => (() => {
89
- var o = X();
90
- return _(o, k(n, {
87
+ }), !1, !0), y(a, () => e.children), a;
88
+ })(), Ae = (e) => (() => {
89
+ var a = P();
90
+ return T(a, $(e, {
91
91
  get class() {
92
- return `DefaultHoverElement ${n.class || ""}`;
92
+ return `DefaultHoverElement ${e.class || ""}`;
93
93
  },
94
94
  get style() {
95
95
  return {
@@ -105,15 +105,15 @@ const Me = (n) => (() => {
105
105
  "border-radius": "10px",
106
106
  transition: "all 0.2s ease",
107
107
  border: "2px dashed rgb(0, 196, 42)",
108
- ...n.style
108
+ ...e.style
109
109
  };
110
110
  }
111
- }), !1, !0), R(o, () => n.children), o;
112
- })(), qe = (n) => (() => {
113
- var o = ke(), m = o.firstChild;
114
- return _(o, k(n, {
111
+ }), !1, !0), y(a, () => e.children), a;
112
+ })(), je = (e) => (() => {
113
+ var a = _e(), h = a.firstChild;
114
+ return T(a, $(e, {
115
115
  get class() {
116
- return `DefaultSliderElement ${n.class || ""}`;
116
+ return `DefaultSliderElement ${e.class || ""}`;
117
117
  },
118
118
  get style() {
119
119
  return {
@@ -124,53 +124,50 @@ const Me = (n) => (() => {
124
124
  "background-color": "white",
125
125
  "z-index": 9,
126
126
  cursor: "grab",
127
- ...n.style
127
+ ...e.style
128
128
  };
129
129
  }
130
- }), !1, !0), m.style.setProperty("display", "flex"), m.style.setProperty("align-items", "center"), m.style.setProperty("gap", "4px"), m.style.setProperty("height", "100%"), R(m, (() => {
131
- var y = xe(() => !n.direction);
132
- return () => y() ? Ae() : (() => {
133
- var d = Be();
134
- return d.style.setProperty("transform", "rotate(90deg)"), d;
135
- })();
136
- })()), R(o, () => n.children, null), Pe((y) => (y = n.direction ? "column" : "row") != null ? m.style.setProperty("flex-direction", y) : m.style.removeProperty("flex-direction")), o;
137
- })(), Ye = (n) => {
138
- const [o, m] = Ie(n, ["area", "size", "gap", "class", "style", "children"]), y = ve(() => {
139
- const d = o.size || {
130
+ }), !1, !0), y(h, (() => {
131
+ var g = ie(() => !e.direction);
132
+ return () => g() ? Ie() : We();
133
+ })()), y(a, () => e.children, null), Ee((g) => De(h, "flex-direction", e.direction ? "column" : "row")), a;
134
+ })(), Fe = (e) => {
135
+ const [a, h] = He(e, ["area", "size", "gap", "class", "style", "children"]), g = se(() => {
136
+ const s = a.size || {
140
137
  h: "20%",
141
138
  w: "6px"
142
- }, E = o.gap || "0px", h = {};
143
- return o.area === "left" ? (Object.assign(h, {
139
+ }, b = a.gap || "0px", u = {};
140
+ return a.area === "left" ? (Object.assign(u, {
144
141
  "border-top-right-radius": "16px",
145
142
  "border-bottom-right-radius": "16px",
146
- height: d.h,
147
- left: E,
148
- width: d.w
149
- }), h.top = `calc(50% - ${d.h} / 2)`) : o.area === "top" ? (Object.assign(h, {
143
+ height: s.h,
144
+ left: b,
145
+ width: s.w
146
+ }), u.top = `calc(50% - ${s.h} / 2)`) : a.area === "top" ? (Object.assign(u, {
150
147
  "border-bottom-left-radius": "16px",
151
148
  "border-bottom-right-radius": "16px",
152
- width: d.h,
153
- top: E,
154
- height: d.w
155
- }), h.left = `calc(50% - ${d.h} / 2)`) : o.area === "right" ? (Object.assign(h, {
149
+ width: s.h,
150
+ top: b,
151
+ height: s.w
152
+ }), u.left = `calc(50% - ${s.h} / 2)`) : a.area === "right" ? (Object.assign(u, {
156
153
  "border-top-left-radius": "16px",
157
154
  "border-bottom-left-radius": "16px",
158
- height: d.h,
159
- right: E,
160
- width: d.w
161
- }), h.top = `calc(50% - ${d.h} / 2)`) : o.area === "bottom" && (Object.assign(h, {
155
+ height: s.h,
156
+ right: b,
157
+ width: s.w
158
+ }), u.top = `calc(50% - ${s.h} / 2)`) : a.area === "bottom" && (Object.assign(u, {
162
159
  "border-top-left-radius": "16px",
163
160
  "border-top-right-radius": "16px",
164
- width: d.h,
165
- bottom: E,
166
- height: d.w
167
- }), h.left = `calc(50% - ${d.h} / 2)`), h;
161
+ width: s.h,
162
+ bottom: b,
163
+ height: s.w
164
+ }), u.left = `calc(50% - ${s.h} / 2)`), u;
168
165
  });
169
166
  return (() => {
170
- var d = X();
171
- return _(d, k(m, {
167
+ var s = P();
168
+ return T(s, $(h, {
172
169
  get class() {
173
- return `RootSplitterHoverEl ${o.class || ""}`;
170
+ return `RootSplitterHoverEl ${a.class || ""}`;
174
171
  },
175
172
  get style() {
176
173
  return {
@@ -180,382 +177,359 @@ const Me = (n) => (() => {
180
177
  "box-sizing": "border-box",
181
178
  "background-color": "#0081f9",
182
179
  cursor: "grab",
183
- ...o.style,
184
- ...y()
180
+ ...a.style,
181
+ ...g()
185
182
  };
186
183
  }
187
- }), !1, !0), R(d, () => o.children), d;
184
+ }), !1, !0), y(s, () => a.children), s;
188
185
  })();
189
- }, Je = ({
190
- tabOutput: n,
191
- rootId: o,
192
- layoutTree: m,
193
- updateJSON: y,
194
- dimensions: d,
195
- tabHeadHeight: E,
196
- enableTabbar: h,
197
- bondWidth: se,
198
- minTabHeight: le,
199
- minTabWidth: M,
200
- sliderUpdateTimeout: de,
201
- windowResizeTimeout: te,
202
- disableSliderTimeout: q,
203
- disableResizeTimeout: Y
186
+ }, Ue = ({
187
+ tabOutput: e,
188
+ rootId: a,
189
+ layoutTree: h,
190
+ updateJSON: g,
191
+ dimensions: s,
192
+ tabHeadHeight: b,
193
+ enableTabbar: u,
194
+ bondWidth: J,
195
+ minTabHeight: k,
196
+ minTabWidth: R,
197
+ sliderUpdateTimeout: K,
198
+ windowResizeTimeout: B,
199
+ disableSliderTimeout: C,
200
+ disableResizeTimeout: _
204
201
  }) => {
205
- const j = /* @__PURE__ */ new Map(), J = /* @__PURE__ */ new Map(), U = /* @__PURE__ */ new Map(), ne = /* @__PURE__ */ new Map(), z = { current: void 0 }, K = [], [re, ce] = Z(
206
- m
207
- ), [ae, A] = Z(
202
+ const z = /* @__PURE__ */ new Map(), M = /* @__PURE__ */ new Map(), O = /* @__PURE__ */ new Map(), A = /* @__PURE__ */ new Map(), w = { current: void 0 }, I = [], [j, G] = W(
203
+ h
204
+ ), [F, S] = W(
208
205
  /* @__PURE__ */ new Map()
209
- ), [ue, oe] = Z(
206
+ ), [Q, U] = W(
210
207
  /* @__PURE__ */ new Map()
211
- ), [ge, H] = Z(!1);
212
- let O = null;
213
- const [fe, w] = Z(!1), i = {
208
+ ), [V, p] = W(!1);
209
+ let E = null;
210
+ const [Z, m] = W(!1), o = {
214
211
  src: void 0,
215
212
  des: void 0,
216
213
  area: void 0,
217
214
  drag: !1
218
- }, a = {
215
+ }, n = {
219
216
  sliderId: void 0,
220
217
  isSliding: !1
221
- }, c = new P({
222
- tabs: n.keys,
223
- tree: re(),
224
- minW: M,
225
- minH: le,
226
- bond: se,
227
- uqid: o,
228
- tabsIds: n.name
229
- }), p = (r) => {
230
- const e = new Map(r);
231
- A(e);
232
- }, me = (r) => {
233
- const e = new Map(r);
234
- oe(e);
235
- }, G = () => {
236
- C.cache.tabOpts.get().forEach((e, s) => {
237
- const t = ne.get(s);
238
- t && (t.style.width = `${e.nodDims.w}px`, t.style.height = h ? `${e.nodDims.h - E}px` : `${e.nodDims.h}px`, t.style.left = `${e.nodDims.x}px`, t.style.top = h ? `${e.nodDims.y + E}px` : `${e.nodDims.y}px`, t.style.display = e.nodOpen ? "block" : "none");
218
+ }, d = u ? Math.max(k, b) : k, c = new D({
219
+ tabs: e.keys,
220
+ tree: j(),
221
+ minW: R,
222
+ minH: d,
223
+ bond: J,
224
+ uqid: a,
225
+ tabsIds: e.name
226
+ }), ne = (t) => {
227
+ const r = new Map(t);
228
+ S(r);
229
+ }, ae = (t) => {
230
+ const r = new Map(t);
231
+ U(r);
232
+ }, q = () => {
233
+ const t = u ? b : 0;
234
+ x.cache.tabOpts.get().forEach((r, l) => {
235
+ const i = A.get(l);
236
+ if (!i) return;
237
+ const f = Se(r.nodDims, t);
238
+ Y(i, f), i.style.display = r.nodOpen && f.h > 0 ? "block" : "none";
239
239
  });
240
- }, we = () => {
241
- C.cache.bndOpts.get().forEach((e, s) => {
242
- const t = J.get(s);
243
- t && (t.style.width = `${e.nodDims.w}px`, t.style.height = `${e.nodDims.h}px`, t.style.left = `${e.nodDims.x}px`, t.style.top = `${e.nodDims.y}px`);
244
- });
245
- };
246
- C.cache.nodOpts.onChange((r) => {
247
- r.forEach((e, s) => {
248
- const t = U.get(s);
249
- t && (t.style.width = `${e.nodDims.w}px`, t.style.height = `${e.nodDims.h}px`, t.style.left = `${e.nodDims.x}px`, t.style.top = `${e.nodDims.y}px`);
250
- const l = j.get(s);
251
- l && h && (l.style.width = `${e.nodDims.w}px`, l.style.height = h ? `${E}px` : "0px", l.style.left = `${e.nodDims.x}px`, l.style.top = `${e.nodDims.y}px`);
252
- });
253
- }), C.cache.bndOpts.onChange((r) => {
254
- r.forEach((e, s) => {
255
- const t = J.get(s);
256
- t && (t.style.width = `${e.nodDims.w}px`, t.style.height = `${e.nodDims.h}px`, t.style.left = `${e.nodDims.x}px`, t.style.top = `${e.nodDims.y}px`);
257
- });
258
- });
259
- const ye = (r) => {
260
- a.isSliding && (c.updateSlider(
261
- a.sliderId,
262
- {
263
- x: r.clientX,
264
- y: r.clientY
265
- },
266
- q,
267
- de
268
- ), we(), G());
269
- }, ie = (r) => {
270
- if (!a.isSliding) return;
271
- const e = r.currentTarget;
272
- a.isSliding = !1, a.sliderId = void 0, y && y(P._root.toJSON()), e.releasePointerCapture(r.pointerId), e.removeEventListener("pointermove", ye), e.removeEventListener("pointerup", ie), e.removeEventListener("pointercancel", ie);
273
- }, De = (r) => {
274
- r.preventDefault();
275
- const e = r.currentTarget;
276
- a.isSliding = !0, a.sliderId = e.id, e.setPointerCapture(r.pointerId), e.addEventListener("pointermove", ye), e.addEventListener("pointerup", ie), e.addEventListener("pointercancel", ie);
277
- }, f = {}, Te = (r, e, s) => {
278
- if (!z.current || !i || !s)
279
- return null;
280
- i.des = s;
281
- const t = s.getBoundingClientRect();
282
- if (!t) return null;
283
- const l = t.width, u = t.height, g = r - t.left, x = e - t.top;
284
- let b, D, $, v, S;
285
- g < l / 3 ? (b = "left", D = t.left, $ = t.top, v = l / 2, S = u) : g > 2 * l / 3 ? (b = "right", D = t.left + l / 2, $ = t.top, v = l / 2, S = u) : x < u / 3 ? (b = "top", D = t.left, $ = t.top, v = l, S = u / 2) : x > 2 * u / 3 ? (b = "bottom", D = t.left, $ = t.top + u / 2, v = l, S = u / 2) : (b = "contain", D = t.left + l * 0.1, $ = t.top + u * 0.1, v = l * 0.8, S = u * 0.8), (f.area !== b || f.left !== D || f.top !== $ || f.width !== v || f.height !== S) && (V(D, $, v, S, b), f.area = b, f.left = D, f.top = $, f.width = v, f.height = S), i.area = b;
286
- }, Ee = (r) => {
287
- r.preventDefault(), r.stopPropagation(), r.dataTransfer && (r.dataTransfer.dropEffect = "move");
288
- const e = r.currentTarget, s = Array.from(
289
- e.childNodes
290
- ), t = r.clientX, l = r.clientY;
291
- if (!z.current || !i || s.length === 0)
292
- return;
293
- const u = s[0].parentElement;
294
- if (!u) return;
295
- const g = u.getBoundingClientRect(), x = s[0], b = s[s.length - 1], D = x.getBoundingClientRect(), $ = b.getBoundingClientRect();
296
- let v = 6;
297
- if (l < g.top || l > g.bottom) return;
298
- if (t > $.right) {
299
- const T = $.right + 1, W = $.top, I = v - 2, L = $.height, B = "right";
300
- V(T, W, I, L, B), i.des = b, i.area = B;
301
- return;
302
- }
303
- if (t < D.left) {
304
- const T = D.left - v + 1, W = D.top, I = v - 2, L = D.height, B = "left";
305
- V(T, W, I, L, B), i.des = x, i.area = B;
306
- return;
307
- }
308
- let S = null, pe = 1 / 0, Q = !1, he = 0;
309
- for (let T = 0; T < s.length; T++) {
310
- const W = s[T].getBoundingClientRect(), I = W.left + W.width / 2, L = Math.abs(t - I);
311
- L < pe && (pe = L, S = s[T], Q = t < I, he = T);
240
+ }, le = x.cache.nodOpts.onChange(
241
+ (t) => {
242
+ t.forEach((r, l) => {
243
+ const i = O.get(l);
244
+ i && Y(i, r.nodDims);
245
+ const f = z.get(l);
246
+ f && u && Y(f, {
247
+ ...r.nodDims,
248
+ h: b
249
+ });
250
+ });
312
251
  }
313
- if (s.length > 1 && (Q && he > 0 || !Q && he < s.length - 1) && (v = s[1].getBoundingClientRect().left - D.right), S) {
314
- const T = S.getBoundingClientRect(), W = Q ? T.left - v + 1 : T.right + 1, I = T.top, L = v - 2, B = T.height, be = Q ? "left" : "right";
315
- V(W, I, L, B, be), i.des = S, i.area = be;
252
+ ), de = x.cache.tabOpts.onChange(() => q()), ce = x.cache.bndOpts.onChange(
253
+ (t) => {
254
+ t.forEach((r, l) => {
255
+ const i = M.get(l);
256
+ i && Y(i, r.nodDims);
257
+ });
316
258
  }
317
- }, $e = (r) => {
318
- r.preventDefault(), r.stopPropagation(), r.dataTransfer && (r.dataTransfer.dropEffect = "move");
319
- const e = r.currentTarget.dataset.area, s = r.currentTarget.dataset.uid;
320
- if (!e || !s || !z.current || !i)
259
+ ), ee = $e(
260
+ ({ id: t, point: r }) => c.updateSlider(
261
+ t,
262
+ r,
263
+ C,
264
+ K
265
+ )
266
+ ), oe = (t) => {
267
+ const r = n.sliderId;
268
+ !n.isSliding || !r || ee.schedule({ id: r, point: { x: t.clientX, y: t.clientY } });
269
+ }, X = (t) => {
270
+ if (!n.isSliding) return;
271
+ ee.flush();
272
+ const r = t.currentTarget;
273
+ n.isSliding = !1, n.sliderId = void 0, p(!1), g && g(D._root.toJSON()), r.releasePointerCapture(t.pointerId), r.removeEventListener("pointermove", oe), r.removeEventListener("pointerup", X), r.removeEventListener("pointercancel", X);
274
+ }, ue = (t) => {
275
+ t.preventDefault();
276
+ const r = t.currentTarget;
277
+ n.isSliding = !0, n.sliderId = r.id, p(!0), r.setPointerCapture(t.pointerId), r.addEventListener("pointermove", oe), r.addEventListener("pointerup", X), r.addEventListener("pointercancel", X);
278
+ };
279
+ let te = {};
280
+ const ge = (t, r, l) => {
281
+ if (!w.current || !o || !l)
282
+ return null;
283
+ const i = Oe(
284
+ l.getBoundingClientRect(),
285
+ t,
286
+ r
287
+ );
288
+ re(i), o.des = l, o.area = i.area;
289
+ }, fe = (t) => {
290
+ t.preventDefault(), t.stopPropagation(), t.dataTransfer && (t.dataTransfer.dropEffect = "move");
291
+ const r = t.currentTarget, l = Array.from(
292
+ r.childNodes
293
+ );
294
+ if (!w.current || !o) return;
295
+ const i = Ne(
296
+ r.getBoundingClientRect(),
297
+ l.map((f) => f.getBoundingClientRect()),
298
+ t.clientX,
299
+ t.clientY
300
+ );
301
+ i && (re(i), o.des = l[i.index], o.area = i.area);
302
+ }, me = (t) => {
303
+ t.preventDefault(), t.stopPropagation(), t.dataTransfer && (t.dataTransfer.dropEffect = "move");
304
+ const r = t.currentTarget, { area: l, uid: i } = r.dataset;
305
+ if (!l || !i || !w.current || !o)
321
306
  return;
322
- i.des = r.currentTarget, i.area = e;
323
- const t = d();
324
- let l = t.x, u = t.y, g = t.w, x = t.h;
325
- e === "left" ? (l = t.x, u = t.y, g = t.w / 2, x = t.h) : e === "right" ? (l = t.x + t.w / 2, u = t.y, g = t.w / 2, x = t.h) : e === "top" ? (l = t.x, u = t.y, g = t.w, x = t.h / 2) : e === "bottom" && (l = t.x, u = t.y + t.h / 2, g = t.w, x = t.h / 2), V(l, u, g, x, e);
326
- }, V = (r, e, s, t, l) => {
327
- if (f.area !== l || f.left !== r || f.top !== e || f.width !== s || f.height !== t) {
328
- const u = z.current;
329
- if (u) {
330
- const g = {};
331
- for (let x = 0; x < u.style.length; x++) {
332
- const b = u.style[x];
333
- b && (g[b] = u.style.getPropertyValue(b));
334
- }
335
- Object.assign(u.style, g, {
336
- left: `${r}px`,
337
- top: `${e}px`,
338
- width: `${s}px`,
339
- height: `${t}px`,
340
- display: "block",
341
- "z-index": "100"
342
- }), f.area = l, f.left = r, f.top = e, f.width = s, f.height = t;
343
- }
344
- }
345
- }, Se = (r) => {
346
- if (r.stopPropagation(), H(!0), document.body.style.cursor = "move", r.currentTarget) {
347
- if (r.dataTransfer) {
348
- r.dataTransfer.effectAllowed = "move";
349
- const e = document.createElement("div");
350
- e.style.width = "1px", e.style.height = "1px", e.style.backgroundColor = "transparent", e.style.position = "absolute", e.style.top = "-1000px", document.body.appendChild(e), r.dataTransfer.setDragImage(e, 0, 0), setTimeout(() => {
351
- e.parentNode && e.parentNode.removeChild(e);
307
+ const f = l;
308
+ o.des = r, o.area = f, re(Re(s(), f));
309
+ }, re = (t) => {
310
+ const r = w.current;
311
+ !r || ze(te, t) || (Object.assign(r.style, {
312
+ left: `${t.left}px`,
313
+ top: `${t.top}px`,
314
+ width: `${t.width}px`,
315
+ height: `${t.height}px`,
316
+ display: "block",
317
+ zIndex: "100"
318
+ }), te = t);
319
+ }, he = (t) => {
320
+ if (t.stopPropagation(), p(!0), document.body.style.cursor = "move", t.currentTarget) {
321
+ if (t.dataTransfer) {
322
+ t.dataTransfer.effectAllowed = "move";
323
+ const r = document.createElement("div");
324
+ r.style.width = "1px", r.style.height = "1px", r.style.backgroundColor = "transparent", r.style.position = "absolute", r.style.top = "-1000px", document.body.appendChild(r), t.dataTransfer.setDragImage(r, 0, 0), setTimeout(() => {
325
+ r.parentNode && r.parentNode.removeChild(r);
352
326
  }, 0);
353
327
  }
354
- K.forEach((e) => {
355
- e && (e.style.display = "block", e.style.zIndex = "99");
356
- }), U.forEach((e) => {
357
- e && (e.style.display = "block", e.style.zIndex = "95");
358
- }), i.src = r.currentTarget, i.drag = !0;
328
+ I.forEach((r) => {
329
+ r && (r.style.display = "block", r.style.zIndex = "99");
330
+ }), O.forEach((r) => {
331
+ r && (r.style.display = "block", r.style.zIndex = "95");
332
+ }), o.src = t.currentTarget, o.drag = !0;
359
333
  }
360
- }, Re = (r) => {
361
- if (r.preventDefault(), r.stopPropagation(), document.body.style.cursor = "move", r.dataTransfer && (r.dataTransfer.dropEffect = "move"), !i?.src)
334
+ }, be = (t) => {
335
+ if (t.preventDefault(), t.stopPropagation(), document.body.style.cursor = "move", t.dataTransfer && (t.dataTransfer.dropEffect = "move"), !o?.src)
362
336
  return;
363
- const e = r.currentTarget, s = r.clientX, t = r.clientY;
364
- O && cancelAnimationFrame(O), O = requestAnimationFrame(() => {
365
- Te(s, t, e);
337
+ const r = t.currentTarget, l = t.clientX, i = t.clientY;
338
+ E && cancelAnimationFrame(E), E = requestAnimationFrame(() => {
339
+ ge(l, i, r);
366
340
  });
367
- }, Ne = (r) => {
368
- if (document.body.style.cursor = "default", K.forEach((e) => {
369
- e && (e.style.display = "none", e.style.zIndex = "-1");
370
- }), O && (cancelAnimationFrame(O), O = null), z.current && (z.current.style.display = "none", z.current.style.zIndex = "-1"), Object.assign(f, {}), i.drag = !1, !i?.src || !i?.des) {
371
- i.area = void 0, i.src = void 0, i.des = void 0, H(!1);
341
+ }, ye = () => {
342
+ if (document.body.style.cursor = "default", I.forEach((t) => {
343
+ t && (t.style.display = "none", t.style.zIndex = "-1");
344
+ }), E && (cancelAnimationFrame(E), E = null), w.current && (w.current.style.display = "none", w.current.style.zIndex = "-1"), te = {}, o.drag = !1, !o?.src || !o?.des) {
345
+ o.area = void 0, o.src = void 0, o.des = void 0, p(!1);
372
346
  return;
373
347
  }
374
- if (i.src === i.des) {
375
- i.area = void 0, i.src = void 0, i.des = void 0, H(!1);
348
+ if (o.src === o.des) {
349
+ o.area = void 0, o.src = void 0, o.des = void 0, p(!1);
376
350
  return;
377
351
  }
378
- if (i.src && i.des) {
379
- if (!i.area) {
380
- console.warn("No area specified for drag and drop"), H(!1);
352
+ if (o.src && o.des) {
353
+ if (!o.area) {
354
+ console.warn("No area specified for drag and drop"), p(!1);
381
355
  return;
382
356
  }
383
357
  if (!c.updateTree(
384
- i.src.dataset.uid,
385
- i.des.dataset.uid,
386
- i.area || "contain"
358
+ o.src.dataset.uid,
359
+ o.des.dataset.uid,
360
+ o.area || "contain"
387
361
  )) {
388
- console.warn("Failed to update layout tree"), H(!1);
362
+ console.warn("Failed to update layout tree"), p(!1);
389
363
  return;
390
364
  }
391
365
  requestAnimationFrame(() => {
392
- p(C.cache.nodOpts.get()), me(C.cache.bndOpts.get()), G(), y && y(P._root.toJSON());
366
+ ne(x.cache.nodOpts.get()), ae(x.cache.bndOpts.get()), q(), g && g(D._root.toJSON());
393
367
  });
394
368
  }
395
- i.area = void 0, i.src = void 0, i.des = void 0, H(!1);
396
- }, Ce = (r) => {
397
- r.preventDefault(), r.stopPropagation(), r.dataTransfer && (r.dataTransfer.dropEffect = "move");
398
- }, ze = (r) => {
399
- r.preventDefault(), r.stopPropagation();
400
- }, Oe = (r) => {
401
- r.preventDefault(), r.stopPropagation(), r.dataTransfer && r.dataTransfer.getData("text/plain");
402
- }, He = (r) => {
403
- const e = r.currentTarget, s = e.dataset.uid;
404
- if (!s) return;
405
- const t = C.cache.mapElem.get(s);
406
- if (!(t instanceof C)) {
407
- console.warn(`Element with uid ${s} is not a Node instance`);
369
+ o.area = void 0, o.src = void 0, o.des = void 0, p(!1);
370
+ }, ve = (t) => {
371
+ t.preventDefault(), t.stopPropagation(), t.dataTransfer && (t.dataTransfer.dropEffect = "move");
372
+ }, pe = (t) => {
373
+ t.preventDefault(), t.stopPropagation();
374
+ }, xe = (t) => {
375
+ t.preventDefault(), t.stopPropagation(), t.dataTransfer && t.dataTransfer.getData("text/plain");
376
+ }, we = (t) => {
377
+ const r = t.currentTarget, l = r.dataset.uid;
378
+ if (!l) return;
379
+ const i = x.cache.mapElem.get(l);
380
+ if (!(i instanceof x)) {
381
+ console.warn(`Element with uid ${l} is not a Node instance`);
408
382
  return;
409
383
  }
410
- if (!t || !t.host || !t.host.unId) {
411
- console.warn(`Node with uid ${s} not found in mapNode`);
384
+ if (!i || !i.host || !i.host.unId) {
385
+ console.warn(`Node with uid ${l} not found in mapNode`);
412
386
  return;
413
387
  }
414
- if (t.host.open == t.name) {
415
- console.warn(`Node ${t.name} is already open`);
388
+ if (i.host.open == i.name) {
389
+ console.warn(`Node ${i.name} is already open`);
416
390
  return;
417
391
  }
418
- const l = C.cache.nodOpts.get().get(t.host.unId);
419
- if (!l || l.nodOpen && t?.open)
392
+ const f = x.cache.nodOpts.get().get(i.host.unId);
393
+ if (!f || f.nodOpen && i?.open)
420
394
  return;
421
- t.host.open = t.name, l.nodOpen = t.name, l.nodKids?.forEach((g) => {
422
- g.nodOpen = g.nodName === t.name;
423
- }), e?.parentElement?.childNodes?.forEach((g) => {
424
- g instanceof HTMLDivElement && g.dataset.uid !== s ? g.dataset.state = "inactive" : g.dataset.state = "active";
425
- }), G();
395
+ i.host.open = i.name, f.nodOpen = i.name, f.nodKids?.forEach((N) => {
396
+ N.nodOpen = N.nodName === i.name;
397
+ }), r?.parentElement?.childNodes?.forEach((N) => {
398
+ N instanceof HTMLDivElement && N.dataset.uid !== l ? N.dataset.state = "inactive" : N.dataset.state = "active";
399
+ }), q();
426
400
  };
427
- return Le(() => {
428
- const r = (s) => {
401
+ return Pe(() => {
402
+ const t = (l) => {
429
403
  c.updateDimension(
430
- d(),
431
- s,
432
- te
433
- ), G();
404
+ s(),
405
+ l,
406
+ B
407
+ );
434
408
  };
435
- r(!0);
436
- const e = () => r(Y ?? !1);
437
- window.addEventListener("resize", e), p(C.cache.nodOpts.get()), me(C.cache.bndOpts.get()), G(), y && y(P._root.toJSON()), _e(() => {
438
- window.removeEventListener("resize", e), O && cancelAnimationFrame(O);
409
+ t(!0);
410
+ const r = () => t(_ ?? !1);
411
+ window.addEventListener("resize", r), ne(x.cache.nodOpts.get()), ae(x.cache.bndOpts.get()), q(), g && g(D._root.toJSON()), Ce(() => {
412
+ window.removeEventListener("resize", r), le(), ce(), de(), ee.cancel(), E && cancelAnimationFrame(E);
439
413
  });
440
414
  }), {
441
- tabsets: ae,
442
- sliders: ue,
443
- tabsetsRef: j,
444
- panelsRef: U,
445
- tabsRef: ne,
446
- slidersRef: J,
447
- layoutJSON: re,
415
+ tabsets: F,
416
+ sliders: Q,
417
+ tabsetsRef: z,
418
+ panelsRef: O,
419
+ tabsRef: A,
420
+ slidersRef: M,
421
+ layoutJSON: j,
448
422
  layoutInstance: c,
449
- hoverElementRef: z,
450
- rootSplitHoverEl: K,
451
- dragging: ge,
452
- isUpdating: fe,
453
- setIsUpdating: w,
454
- setDragging: H,
455
- setTabsets: A,
456
- setSliders: oe,
457
- setLayoutJSON: ce,
458
- onDragStart: Se,
459
- onDragOver: Re,
460
- onDragEnd: Ne,
461
- onDragEnter: Ce,
462
- onDragLeave: ze,
463
- onDrop: Oe,
464
- onPointerDown: De,
465
- updateActiveTab: He,
466
- handleRootSplit: $e,
467
- handleNavbarDragOver: Ee
423
+ hoverElementRef: w,
424
+ rootSplitHoverEl: I,
425
+ dragging: V,
426
+ isUpdating: Z,
427
+ setIsUpdating: m,
428
+ setDragging: p,
429
+ setTabsets: S,
430
+ setSliders: U,
431
+ setLayoutJSON: G,
432
+ onDragStart: he,
433
+ onDragOver: be,
434
+ onDragEnd: ye,
435
+ onDragEnter: ve,
436
+ onDragLeave: pe,
437
+ onDrop: xe,
438
+ onPointerDown: ue,
439
+ updateActiveTab: we,
440
+ handleRootSplit: me,
441
+ handleNavbarDragOver: fe
468
442
  };
469
443
  };
470
- var Ke = F("<div>"), Ge = F('<div class="flex items-center justify-center h-full"><span class=text-gray-500>No content');
471
- const Ve = (n) => {
472
- const o = [], m = /* @__PURE__ */ new Map(), y = /* @__PURE__ */ new Map();
473
- for (const [d, E] of n) {
474
- const h = crypto.randomUUID();
475
- o.push(d), m.set(d, {
476
- uqid: h,
477
- name: d,
478
- node: E
479
- }), y.set(d, h);
444
+ var qe = H("<div>"), Xe = H('<div class="flex items-center justify-center h-full"><span class=text-gray-500>No content');
445
+ const Ye = (e) => {
446
+ const a = [], h = /* @__PURE__ */ new Map(), g = /* @__PURE__ */ new Map();
447
+ for (const [s, b] of e) {
448
+ const u = crypto.randomUUID();
449
+ a.push(s), h.set(s, {
450
+ uqid: u,
451
+ name: s,
452
+ node: b
453
+ }), g.set(s, u);
480
454
  }
481
455
  return {
482
- keys: o,
483
- maps: m,
484
- name: y
456
+ keys: a,
457
+ maps: h,
458
+ name: g
485
459
  };
486
- }, tt = (n) => {
487
- const o = ve(() => Ve(n.tabs));
488
- let m;
489
- const y = () => {
490
- const w = m;
491
- if (!w) return {
460
+ }, Ve = (e) => {
461
+ const a = se(() => Ye(e.tabs));
462
+ let h;
463
+ const g = () => {
464
+ const m = h;
465
+ if (!m) return {
492
466
  w: 0,
493
467
  h: 0,
494
468
  x: 0,
495
469
  y: 0
496
470
  };
497
- const i = w.getBoundingClientRect(), a = n.pad || {
471
+ const o = m.getBoundingClientRect(), n = e.pad || {
498
472
  t: 0,
499
473
  b: 0,
500
474
  l: 0,
501
475
  r: 0
502
476
  };
503
477
  return {
504
- w: i.width - (a.l + a.r),
505
- h: i.height - (a.t + a.b),
506
- x: i.left + a.l,
507
- y: i.top + a.t
478
+ w: o.width - (n.l + n.r),
479
+ h: o.height - (n.t + n.b),
480
+ x: o.left + n.l,
481
+ y: o.top + n.t
508
482
  };
509
483
  }, {
510
- tabsetsRef: d,
511
- slidersRef: E,
512
- sliders: h,
513
- tabsets: se,
514
- hoverElementRef: le,
515
- onDragEnd: M,
516
- onDragOver: de,
517
- onDragStart: te,
518
- onDragEnter: q,
519
- onDragLeave: Y,
520
- onDrop: j,
521
- dragging: J,
522
- panelsRef: U,
523
- onPointerDown: ne,
524
- handleNavbarDragOver: z,
525
- updateActiveTab: K,
526
- rootSplitHoverEl: re,
527
- handleRootSplit: ce,
528
- tabsRef: ae,
529
- isUpdating: A
530
- } = Je({
531
- tabOutput: o(),
532
- rootId: n.rootId || "dynamix-layout-root",
533
- updateJSON: n.updateJSON,
534
- enableTabbar: n.enableTabbar === void 0 ? !0 : n.enableTabbar,
535
- layoutTree: n.layoutTree,
536
- tabHeadHeight: n.tabHeadHeight || P._minH,
537
- dimensions: y,
538
- sliderUpdateTimeout: n.sliderUpdateTimeout || 2,
539
- windowResizeTimeout: n.windowResizeTimeout || 2,
540
- bondWidth: n.bondWidth || P._bond,
541
- minTabHeight: n.minTabHeight || P._minH,
542
- minTabWidth: n.minTabWidth || P._minW,
543
- disableSliderTimeout: n.disableSliderTimeout === void 0 ? !0 : n.disableSliderTimeout,
544
- disableResizeTimeout: n.disableResizeTimeout === void 0 ? !0 : n.disableResizeTimeout,
545
- hoverElementStyles: n.hoverElementStyles
546
- }), ue = n.WrapTabPanel || Fe, oe = n.WrapTabHead || Ue, ge = n.WrapTabLabel || Me, H = n.WrapTabBody || je, O = n.SliderElement || qe, fe = n.HoverElement || Xe;
484
+ tabsetsRef: s,
485
+ slidersRef: b,
486
+ sliders: u,
487
+ tabsets: J,
488
+ hoverElementRef: k,
489
+ onDragEnd: R,
490
+ onDragOver: K,
491
+ onDragStart: B,
492
+ onDragEnter: C,
493
+ onDragLeave: _,
494
+ onDrop: z,
495
+ dragging: M,
496
+ panelsRef: O,
497
+ onPointerDown: A,
498
+ handleNavbarDragOver: w,
499
+ updateActiveTab: I,
500
+ rootSplitHoverEl: j,
501
+ handleRootSplit: G,
502
+ tabsRef: F,
503
+ isUpdating: S
504
+ } = Ue({
505
+ tabOutput: a(),
506
+ rootId: e.rootId || "dynamix-layout-root",
507
+ updateJSON: e.updateJSON,
508
+ enableTabbar: e.enableTabbar === void 0 ? !0 : e.enableTabbar,
509
+ layoutTree: e.layoutTree,
510
+ tabHeadHeight: e.tabHeadHeight || D._minH,
511
+ dimensions: g,
512
+ sliderUpdateTimeout: e.sliderUpdateTimeout || 2,
513
+ windowResizeTimeout: e.windowResizeTimeout || 2,
514
+ bondWidth: e.bondWidth || D._bond,
515
+ minTabHeight: e.minTabHeight || D._minH,
516
+ minTabWidth: e.minTabWidth || D._minW,
517
+ disableSliderTimeout: e.disableSliderTimeout === void 0 ? !0 : e.disableSliderTimeout,
518
+ disableResizeTimeout: e.disableResizeTimeout === void 0 ? !0 : e.disableResizeTimeout,
519
+ hoverElementStyles: e.hoverElementStyles
520
+ }), Q = e.WrapTabPanel || Me, U = e.WrapTabHead || Be, V = e.WrapTabLabel || Le, p = e.WrapTabBody || ke, E = e.SliderElement || je, Z = e.HoverElement || Ae;
547
521
  return (() => {
548
- var w = Ke(), i = m;
549
- return typeof i == "function" ? We(i, w) : m = w, _(w, k({
522
+ var m = qe(), o = h;
523
+ return typeof o == "function" ? Te(o, m) : h = m, T(m, $({
550
524
  get id() {
551
- return n.rootId || "dynamix-layout-root";
525
+ return e.rootId || "dynamix-layout-root";
552
526
  }
553
- }, n, {
527
+ }, e, {
554
528
  get "data-testid"() {
555
- return n.rootId || "dynamix-layout-root";
529
+ return e.rootId || "dynamix-layout-root";
556
530
  },
557
531
  get class() {
558
- return J() ? "is-dragging" : "";
532
+ return M() ? "is-dragging" : "";
559
533
  },
560
534
  get style() {
561
535
  return {
@@ -563,224 +537,224 @@ const Ve = (n) => {
563
537
  width: "100%",
564
538
  height: "100%",
565
539
  overflow: "hidden",
566
- ...n.style
540
+ ...e.style
567
541
  };
568
542
  }
569
- }), !1, !0), R(w, N(ee, {
543
+ }), !1, !0), y(m, v(L, {
570
544
  get each() {
571
- return Array.from(se().values());
545
+ return Array.from(J().values());
572
546
  },
573
- children: (a) => [N(ue, {
574
- ref: (c) => {
575
- const p = a.uidNode;
576
- c ? U.set(p, c) : U.delete(p);
547
+ children: (n) => [v(Q, {
548
+ ref: (d) => {
549
+ const c = n.uidNode;
550
+ d ? O.set(c, d) : O.delete(c);
577
551
  },
578
- onDragEnd: M,
579
- onDragOver: de,
580
- onDragEnter: q,
581
- onDragLeave: Y,
582
- onDrop: j,
552
+ onDragEnd: R,
553
+ onDragOver: K,
554
+ onDragEnter: C,
555
+ onDragLeave: _,
556
+ onDrop: z,
583
557
  get "data-uid"() {
584
- return a.uidNode;
558
+ return n.uidNode;
585
559
  },
586
560
  get "data-type"() {
587
- return a.typNode;
561
+ return n.typNode;
588
562
  },
589
563
  get class() {
590
- return "hide-scrollbar DefaultWrapTabPanel " + (n.tabPanelElementClass || "");
564
+ return "hide-scrollbar DefaultWrapTabPanel " + (e.tabPanelElementClass || "");
591
565
  },
592
566
  get style() {
593
567
  return {
594
568
  position: "absolute",
595
- ...n.tabPanelElementStyles,
596
- width: `${a.nodDims.w}px`,
597
- height: `${a.nodDims.h}px`,
598
- left: `${a.nodDims.x}px`,
599
- top: `${a.nodDims.y}px`,
569
+ ...e.tabPanelElementStyles,
570
+ width: `${n.nodDims.w}px`,
571
+ height: `${n.nodDims.h}px`,
572
+ left: `${n.nodDims.x}px`,
573
+ top: `${n.nodDims.y}px`,
600
574
  "background-color": "transparent"
601
575
  };
602
576
  }
603
- }), N(oe, {
577
+ }), v(U, {
604
578
  get draggable() {
605
- return !A();
579
+ return !S();
606
580
  },
607
581
  get "data-uid"() {
608
- return a.uidNode;
582
+ return n.uidNode;
609
583
  },
610
584
  "data-type": "tabset",
611
- onDragOver: z,
612
- onDragStart: te,
613
- onDragEnd: M,
614
- onDragEnter: q,
615
- onDragLeave: Y,
616
- onDrop: j,
617
- ref: (c) => {
618
- const p = a.uidNode;
619
- c ? d.set(p, c) : d.delete(p);
585
+ onDragOver: w,
586
+ onDragStart: B,
587
+ onDragEnd: R,
588
+ onDragEnter: C,
589
+ onDragLeave: _,
590
+ onDrop: z,
591
+ ref: (d) => {
592
+ const c = n.uidNode;
593
+ d ? s.set(c, d) : s.delete(c);
620
594
  },
621
595
  get class() {
622
- return "hide-scrollbar " + (n.tabHeadElementClass || "");
596
+ return "hide-scrollbar " + (e.tabHeadElementClass || "");
623
597
  },
624
598
  get style() {
625
599
  return {
626
- ...n.tabHeadElementStyles,
600
+ ...e.tabHeadElementStyles,
627
601
  position: "absolute",
628
602
  "z-index": 99,
629
- width: `${a.nodDims.w}px`,
630
- height: `${n.tabHeadHeight || P._minH}px`,
631
- left: `${a.nodDims.x}px`,
632
- top: `${a.nodDims.y}px`,
633
- cursor: A() ? "wait" : "pointer"
603
+ width: `${n.nodDims.w}px`,
604
+ height: `${e.tabHeadHeight || D._minH}px`,
605
+ left: `${n.nodDims.x}px`,
606
+ top: `${n.nodDims.y}px`,
607
+ cursor: S() ? "wait" : "pointer"
634
608
  };
635
609
  },
636
610
  get children() {
637
- return N(ee, {
611
+ return v(L, {
638
612
  get each() {
639
- return a.nodKids;
613
+ return n.nodKids;
640
614
  },
641
- children: (c) => N(ge, {
615
+ children: (d) => v(V, {
642
616
  get "data-uid"() {
643
- return c.uidNode;
617
+ return d.uidNode;
644
618
  },
645
619
  "data-type": "tab",
646
- onDragStart: te,
647
- onDragEnd: M,
620
+ onDragStart: B,
621
+ onDragEnd: R,
648
622
  get draggable() {
649
- return !A();
623
+ return !S();
650
624
  },
651
625
  get active() {
652
- return !!c.nodOpen;
626
+ return !!d.nodOpen;
653
627
  },
654
628
  get class() {
655
- return "hide-scrollbar " + (n.tabLabelElementClass || "");
629
+ return "hide-scrollbar " + (e.tabLabelElementClass || "");
656
630
  },
657
631
  get style() {
658
632
  return {
659
- cursor: A() ? "wait" : "pointer",
660
- ...n.tabLabelElementStyles
633
+ cursor: S() ? "wait" : "pointer",
634
+ ...e.tabLabelElementStyles
661
635
  };
662
636
  },
663
- onClick: K,
637
+ onClick: I,
664
638
  get children() {
665
- return xe(() => !!n.tabNames)() && n.tabNames.get(c.nodName) || c.nodName;
639
+ return ie(() => !!e.tabNames)() && e.tabNames.get(d.nodName) || d.nodName;
666
640
  }
667
641
  })
668
642
  });
669
643
  }
670
644
  })]
671
- }), null), R(w, N(ee, {
645
+ }), null), y(m, v(L, {
672
646
  get each() {
673
- return o().keys;
647
+ return a().keys;
674
648
  },
675
- children: (a) => {
676
- const c = o().maps.get(a)?.uqid;
677
- return N(H, {
678
- id: c,
649
+ children: (n) => {
650
+ const d = a().maps.get(n)?.uqid;
651
+ return v(p, {
652
+ id: d,
679
653
  draggable: !1,
680
- "data-uid": c,
654
+ "data-uid": d,
681
655
  get class() {
682
- return "hide-scrollbar " + (n.tabBodyElementClass || "");
656
+ return "hide-scrollbar " + (e.tabBodyElementClass || "");
683
657
  },
684
658
  get style() {
685
659
  return {
686
660
  position: "absolute",
687
661
  "z-index": 90,
688
662
  "overscroll-behavior": "contain",
689
- ...n.tabBodyElementStyles
663
+ ...e.tabBodyElementStyles
690
664
  };
691
665
  },
692
- ref: (p) => {
693
- c && (p ? ae.set(c, p) : ae.delete(c));
666
+ ref: (c) => {
667
+ d && (c ? F.set(d, c) : F.delete(d));
694
668
  },
695
669
  get children() {
696
- return o().maps.get(a)?.node || Ge();
670
+ return a().maps.get(n)?.node || Xe();
697
671
  }
698
672
  });
699
673
  }
700
- }), null), R(w, N(ee, {
674
+ }), null), y(m, v(L, {
701
675
  get each() {
702
- return Array.from(h().values());
676
+ return Array.from(u().values());
703
677
  },
704
- children: (a) => N(O, {
678
+ children: (n) => v(E, {
705
679
  get id() {
706
- return a.uidNode;
680
+ return n.uidNode;
707
681
  },
708
682
  get "data-uid"() {
709
- return a.uidNode;
683
+ return n.uidNode;
710
684
  },
711
685
  get direction() {
712
- return a.nodeDir;
686
+ return n.nodeDir;
713
687
  },
714
- onPointerDown: ne,
688
+ onPointerDown: A,
715
689
  get class() {
716
- return "hide-scrollbar " + (n.sliderElementClass || "");
690
+ return "hide-scrollbar " + (e.sliderElementClass || "");
717
691
  },
718
- ref: (c) => {
719
- const p = a.uidNode;
720
- c ? E.set(p, c) : E.delete(p);
692
+ ref: (d) => {
693
+ const c = n.uidNode;
694
+ d ? b.set(c, d) : b.delete(c);
721
695
  },
722
696
  get style() {
723
697
  return {
724
- width: `${a.nodDims.w}px`,
725
- height: `${a.nodDims.h}px`,
726
- left: `${a.nodDims.x}px`,
727
- top: `${a.nodDims.y}px`,
728
- cursor: a.nodeDir ? "ns-resize" : "ew-resize",
729
- ...n.sliderElementStyles
698
+ width: `${n.nodDims.w}px`,
699
+ height: `${n.nodDims.h}px`,
700
+ left: `${n.nodDims.x}px`,
701
+ top: `${n.nodDims.y}px`,
702
+ cursor: n.nodeDir ? "ns-resize" : "ew-resize",
703
+ ...e.sliderElementStyles
730
704
  };
731
705
  }
732
706
  })
733
- }), null), R(w, N(fe, {
707
+ }), null), y(m, v(Z, {
734
708
  get class() {
735
- return "hide-scrollbar " + (n.hoverElementClass || "");
709
+ return "hide-scrollbar " + (e.hoverElementClass || "");
736
710
  },
737
711
  get style() {
738
712
  return {
739
- ...n.hoverElementStyles
713
+ ...e.hoverElementStyles
740
714
  };
741
715
  },
742
- ref: (a) => le.current = a
743
- }), null), R(w, N(ee, {
716
+ ref: (n) => k.current = n
717
+ }), null), y(m, v(L, {
744
718
  each: ["left", "right", "top", "bottom"],
745
- children: (a, c) => N(Ye, {
746
- onDragOver: ce,
747
- onDragEnd: M,
748
- onDragEnter: q,
749
- onDragLeave: Y,
750
- onDrop: j,
719
+ children: (n, d) => v(Fe, {
720
+ onDragOver: G,
721
+ onDragEnd: R,
722
+ onDragEnter: C,
723
+ onDragLeave: _,
724
+ onDrop: z,
751
725
  get "data-uid"() {
752
- return n.rootId || "dynamix-layout-root";
726
+ return e.rootId || "dynamix-layout-root";
753
727
  },
754
- "data-area": a,
728
+ "data-area": n,
755
729
  get class() {
756
- return "hide-scrollbar " + (n.RootSplitterHoverElClass || "");
730
+ return "hide-scrollbar " + (e.RootSplitterHoverElClass || "");
757
731
  },
758
- ref: (p) => {
759
- p && (re[c()] = p);
732
+ ref: (c) => {
733
+ c && (j[d()] = c);
760
734
  },
761
735
  get style() {
762
736
  return {
763
- ...n.RootSplitterHoverElStyles
737
+ ...e.RootSplitterHoverElStyles
764
738
  };
765
739
  },
766
- area: a,
740
+ area: n,
767
741
  size: {
768
742
  h: "25%",
769
743
  w: "8px"
770
744
  }
771
745
  })
772
- }), null), w;
746
+ }), null), m;
773
747
  })();
774
748
  };
775
749
  export {
776
- Xe as DefaultHoverElement,
777
- qe as DefaultSliderElement,
778
- je as DefaultWrapTabBody,
779
- Ue as DefaultWrapTabHead,
780
- Me as DefaultWrapTabLabel,
781
- Fe as DefaultWrapTabPanel,
782
- tt as DynamixLayout,
783
- Ye as RootSplitterHoverEl,
784
- Ve as getTabOutput,
785
- Je as useDynamixLayout
750
+ Ae as DefaultHoverElement,
751
+ je as DefaultSliderElement,
752
+ ke as DefaultWrapTabBody,
753
+ Be as DefaultWrapTabHead,
754
+ Le as DefaultWrapTabLabel,
755
+ Me as DefaultWrapTabPanel,
756
+ Ve as DynamixLayout,
757
+ Fe as RootSplitterHoverEl,
758
+ Ye as getTabOutput,
759
+ Ue as useDynamixLayout
786
760
  };