fiboui 2.4.4 → 2.6.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/README.md +164 -70
- package/dist/Link-dHd4e7BS.js +50 -0
- package/dist/{PluginManager-D5-ApsSN.js → PluginManager-BRjgOLVa.js} +5 -6
- package/dist/client-C9ZVisXx.js +10565 -0
- package/dist/content.js +7 -8
- package/dist/core.js +60 -60
- package/dist/{effects-CnevV566.js → effects-D16XdB_d.js} +0 -1
- package/dist/index-BGRLxUem.js +608 -0
- package/dist/{index-BMIo5j9Y.js → index-BQ1MDC96.js} +1 -2
- package/dist/index-BsGBv5Ep.js +455 -0
- package/dist/{index-DRVdVimz.js → index-bzEYBKyp.js} +40 -43
- package/dist/{index-DGQVwcWx.js → index-eboXR8k_.js} +136 -362
- package/dist/index.d.ts +44224 -42913
- package/dist/index.js +1563 -1110
- package/dist/interactive.js +9 -9
- package/dist/layout.js +13 -13
- package/dist/mount-D2kCLLwq.js +135 -0
- package/dist/navigation.js +9 -10
- package/dist/{builder-B5cebEWZ.js → server.js} +4467 -967
- package/dist/structure.js +12 -13
- package/dist/style.css +1 -1
- package/dist/style.js +1 -1
- package/dist/theme.js +15 -17
- package/package.json +8 -3
- package/dist/FineGrain-CvcJ5OxF.js +0 -29
- package/dist/Link-ElmaMZB8.js +0 -89
- package/dist/Router-BwbaHooU.js +0 -398
- package/dist/bundle-mjs-wppB-TKB.js +0 -2760
- package/dist/index-BxH8dhoT.js +0 -1112
- package/dist/index-DbaNIwWW.js +0 -160
- package/dist/index-MeDbhMEg.js +0 -1031
- package/dist/index-orKQGpHl.js +0 -34
- package/dist/mount-DbMVakA4.js +0 -358
- package/dist/provider-BTNE3N5g.js +0 -44
- package/dist/themeData-Dtm0M_mF.js +0 -441
|
@@ -1,14 +1,12 @@
|
|
|
1
|
-
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
|
|
5
|
-
import
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
|
|
10
|
-
import { e as te, L as ie } from "./Link-ElmaMZB8.js";
|
|
11
|
-
class se extends b {
|
|
1
|
+
var T = Object.defineProperty;
|
|
2
|
+
var V = (o, s, e) => s in o ? T(o, s, { enumerable: !0, configurable: !0, writable: !0, value: e }) : o[s] = e;
|
|
3
|
+
var r = (o, s, e) => V(o, typeof s != "symbol" ? s + "" : s, e);
|
|
4
|
+
import i from "react";
|
|
5
|
+
import { at as u, au as m, aA as Z, av as X, P as q, as as G, $ as J } from "./client-C9ZVisXx.js";
|
|
6
|
+
import { P as M } from "./PluginManager-BRjgOLVa.js";
|
|
7
|
+
import { R as K, I as Q } from "./index-BQ1MDC96.js";
|
|
8
|
+
import { L as U } from "./Link-dHd4e7BS.js";
|
|
9
|
+
class ee extends m {
|
|
12
10
|
build() {
|
|
13
11
|
const e = [
|
|
14
12
|
"fibo-center",
|
|
@@ -16,7 +14,7 @@ class se extends b {
|
|
|
16
14
|
"items-center",
|
|
17
15
|
"justify-center",
|
|
18
16
|
...this._classNames
|
|
19
|
-
].filter(Boolean).join(" "), t = this.getStyle(),
|
|
17
|
+
].filter(Boolean).join(" "), t = this.getStyle(), n = this.processChildren();
|
|
20
18
|
return i.createElement(
|
|
21
19
|
"div",
|
|
22
20
|
{
|
|
@@ -24,12 +22,12 @@ class se extends b {
|
|
|
24
22
|
style: t,
|
|
25
23
|
...this._props
|
|
26
24
|
},
|
|
27
|
-
...
|
|
25
|
+
...n
|
|
28
26
|
);
|
|
29
27
|
}
|
|
30
28
|
}
|
|
31
|
-
const
|
|
32
|
-
class
|
|
29
|
+
const xe = u(ee);
|
|
30
|
+
class te extends m {
|
|
33
31
|
constructor() {
|
|
34
32
|
super(...arguments);
|
|
35
33
|
r(this, "_mainAxisAlignment", "start");
|
|
@@ -63,11 +61,11 @@ class re extends b {
|
|
|
63
61
|
center: "items-center",
|
|
64
62
|
end: "items-end",
|
|
65
63
|
stretch: "items-stretch"
|
|
66
|
-
},
|
|
64
|
+
}, n = {
|
|
67
65
|
small: "flex-[0.3]",
|
|
68
66
|
medium: "flex-1",
|
|
69
67
|
large: "flex-[1.5]"
|
|
70
|
-
},
|
|
68
|
+
}, l = [
|
|
71
69
|
"fibo-column",
|
|
72
70
|
"flex",
|
|
73
71
|
"flex-col",
|
|
@@ -75,24 +73,24 @@ class re extends b {
|
|
|
75
73
|
this.isHug() ? "w-auto self-auto" : "w-full min-w-0",
|
|
76
74
|
e[this._mainAxisAlignment],
|
|
77
75
|
t[this._crossAxisAlignment],
|
|
78
|
-
this._size ?
|
|
76
|
+
this._size ? n[this._size] : "",
|
|
79
77
|
...this._classNames
|
|
80
|
-
],
|
|
81
|
-
this._spacing && (typeof this._spacing == "number" ?
|
|
82
|
-
const
|
|
78
|
+
], a = this.getStyle();
|
|
79
|
+
this._spacing && (typeof this._spacing == "number" ? a.gap = `${this._spacing}px` : isNaN(Number(this._spacing)) ? a.gap = this._spacing : a.gap = `${Number(this._spacing) * 4}px`);
|
|
80
|
+
const c = l.filter(Boolean).join(" "), h = this.processChildren();
|
|
83
81
|
return i.createElement(
|
|
84
82
|
"div",
|
|
85
83
|
{
|
|
86
|
-
className:
|
|
87
|
-
style:
|
|
84
|
+
className: c,
|
|
85
|
+
style: a,
|
|
88
86
|
...this._props
|
|
89
87
|
},
|
|
90
|
-
...
|
|
88
|
+
...h
|
|
91
89
|
);
|
|
92
90
|
}
|
|
93
91
|
}
|
|
94
|
-
const
|
|
95
|
-
class
|
|
92
|
+
const ve = u(te);
|
|
93
|
+
class ie extends m {
|
|
96
94
|
build() {
|
|
97
95
|
const s = this.getClassName(), e = this.getStyle(), t = this.processChildren();
|
|
98
96
|
return i.createElement(
|
|
@@ -106,8 +104,8 @@ class ne extends b {
|
|
|
106
104
|
);
|
|
107
105
|
}
|
|
108
106
|
}
|
|
109
|
-
const
|
|
110
|
-
class
|
|
107
|
+
const we = u(ie);
|
|
108
|
+
class se extends m {
|
|
111
109
|
constructor() {
|
|
112
110
|
super(...arguments);
|
|
113
111
|
r(this, "_height");
|
|
@@ -137,23 +135,23 @@ class oe extends b {
|
|
|
137
135
|
});
|
|
138
136
|
}
|
|
139
137
|
}
|
|
140
|
-
const
|
|
138
|
+
const Be = u(se), re = i.memo((o) => {
|
|
141
139
|
const {
|
|
142
140
|
theme: s,
|
|
143
141
|
locale: e,
|
|
144
142
|
providers: t = {},
|
|
145
|
-
className:
|
|
146
|
-
style:
|
|
147
|
-
children:
|
|
148
|
-
overlays:
|
|
149
|
-
} =
|
|
150
|
-
s &&
|
|
151
|
-
|
|
143
|
+
className: n,
|
|
144
|
+
style: l,
|
|
145
|
+
children: a,
|
|
146
|
+
overlays: c = []
|
|
147
|
+
} = o, h = /* @__PURE__ */ new Map();
|
|
148
|
+
s && h.set("theme", s), e && h.set("locale", e), Object.entries(t).forEach(([g, p]) => {
|
|
149
|
+
h.set(g, p);
|
|
152
150
|
});
|
|
153
|
-
const
|
|
151
|
+
const f = i.createElement(
|
|
154
152
|
"div",
|
|
155
153
|
{
|
|
156
|
-
className: `fibo-scaffold ${
|
|
154
|
+
className: `fibo-scaffold ${n || ""}`,
|
|
157
155
|
style: {
|
|
158
156
|
height: "100vh",
|
|
159
157
|
overflow: "hidden",
|
|
@@ -161,20 +159,20 @@ const ze = _(oe), le = i.memo((n) => {
|
|
|
161
159
|
flexDirection: "column",
|
|
162
160
|
position: "relative",
|
|
163
161
|
// Ensure relative positioning for overlays
|
|
164
|
-
...
|
|
162
|
+
...l
|
|
165
163
|
}
|
|
166
164
|
},
|
|
167
|
-
[
|
|
165
|
+
[a, ...c]
|
|
168
166
|
);
|
|
169
|
-
return
|
|
170
|
-
|
|
167
|
+
return h.size > 0 ? i.createElement(
|
|
168
|
+
q,
|
|
171
169
|
{
|
|
172
|
-
providers:
|
|
173
|
-
children:
|
|
170
|
+
providers: h,
|
|
171
|
+
children: f
|
|
174
172
|
}
|
|
175
|
-
) :
|
|
173
|
+
) : f;
|
|
176
174
|
});
|
|
177
|
-
class
|
|
175
|
+
class oe extends m {
|
|
178
176
|
constructor() {
|
|
179
177
|
super(...arguments);
|
|
180
178
|
r(this, "_locale");
|
|
@@ -211,10 +209,10 @@ class ae extends b {
|
|
|
211
209
|
}
|
|
212
210
|
_normalizeBar(e) {
|
|
213
211
|
return this._isLayoutBarConfig(e) ? {
|
|
214
|
-
content: i.createElement(i.Fragment, null, ...
|
|
212
|
+
content: i.createElement(i.Fragment, null, ...Z(e.children)),
|
|
215
213
|
fixed: e.fixed ?? !1
|
|
216
214
|
} : {
|
|
217
|
-
content:
|
|
215
|
+
content: X(e),
|
|
218
216
|
fixed: !1
|
|
219
217
|
};
|
|
220
218
|
}
|
|
@@ -222,8 +220,8 @@ class ae extends b {
|
|
|
222
220
|
return !e || typeof e != "object" || i.isValidElement(e) || "build" in e && typeof e.build == "function" ? !1 : "children" in e && !("type" in e);
|
|
223
221
|
}
|
|
224
222
|
build() {
|
|
225
|
-
var
|
|
226
|
-
const e = this.processChildren(), t = this._structure,
|
|
223
|
+
var y, x, v, w, B, k, C, N, z, S, E, L, R, A, $, j, I, H, O, P, D, F;
|
|
224
|
+
const e = this.processChildren(), t = this._structure, n = this._headerBar && ((y = t.header) == null ? void 0 : y.visible) !== !1, l = this._footerBar && ((x = t.footer) == null ? void 0 : x.visible) !== !1, a = this._sideBarLeft && ((v = t.sidebarLeft) == null ? void 0 : v.visible) !== !1, c = this._sideBarRight && ((w = t.sidebarRight) == null ? void 0 : w.visible) !== !1, h = a && ((B = t.sidebarLeft) == null ? void 0 : B.fullHeight), f = c && ((k = t.sidebarRight) == null ? void 0 : k.fullHeight), g = i.createElement(
|
|
227
225
|
"div",
|
|
228
226
|
{
|
|
229
227
|
key: "scaffold-middle",
|
|
@@ -236,14 +234,14 @@ class ae extends b {
|
|
|
236
234
|
}
|
|
237
235
|
},
|
|
238
236
|
[
|
|
239
|
-
|
|
237
|
+
a && !h && i.createElement("div", {
|
|
240
238
|
key: "sidebar-left",
|
|
241
239
|
className: "z-20",
|
|
242
240
|
style: {
|
|
243
|
-
width: (
|
|
244
|
-
position: ((
|
|
245
|
-
top: ((
|
|
246
|
-
height: ((
|
|
241
|
+
width: (C = t.sidebarLeft) == null ? void 0 : C.width,
|
|
242
|
+
position: ((N = t.sidebarLeft) == null ? void 0 : N.mode) === "over" ? "absolute" : ((z = t.sidebarLeft) == null ? void 0 : z.behavior) === "fixed" || this._sideBarLeft.fixed ? "sticky" : void 0,
|
|
243
|
+
top: ((S = t.sidebarLeft) == null ? void 0 : S.behavior) === "fixed" || this._sideBarLeft.fixed ? 0 : void 0,
|
|
244
|
+
height: ((E = t.sidebarLeft) == null ? void 0 : E.behavior) === "fixed" || this._sideBarLeft.fixed ? "100%" : void 0,
|
|
247
245
|
overflowY: "auto",
|
|
248
246
|
borderRight: "1px solid var(--fibo-outline, #e0e0e0)",
|
|
249
247
|
backgroundColor: "var(--fibo-surface, #ffffff)"
|
|
@@ -259,39 +257,39 @@ class ae extends b {
|
|
|
259
257
|
position: "relative"
|
|
260
258
|
}
|
|
261
259
|
}, e),
|
|
262
|
-
|
|
260
|
+
c && !f && i.createElement("div", {
|
|
263
261
|
key: "sidebar-right",
|
|
264
262
|
className: "z-20",
|
|
265
263
|
style: {
|
|
266
|
-
width: (
|
|
267
|
-
position: ((
|
|
268
|
-
top: ((
|
|
269
|
-
height: ((
|
|
264
|
+
width: (L = t.sidebarRight) == null ? void 0 : L.width,
|
|
265
|
+
position: ((R = t.sidebarRight) == null ? void 0 : R.mode) === "over" ? "absolute" : ((A = t.sidebarRight) == null ? void 0 : A.behavior) === "fixed" || this._sideBarRight.fixed ? "sticky" : void 0,
|
|
266
|
+
top: (($ = t.sidebarRight) == null ? void 0 : $.behavior) === "fixed" || this._sideBarRight.fixed ? 0 : void 0,
|
|
267
|
+
height: ((j = t.sidebarRight) == null ? void 0 : j.behavior) === "fixed" || this._sideBarRight.fixed ? "100%" : void 0,
|
|
270
268
|
overflowY: "auto",
|
|
271
269
|
borderLeft: "1px solid var(--fibo-outline, #e0e0e0)",
|
|
272
270
|
backgroundColor: "var(--fibo-surface, #ffffff)"
|
|
273
271
|
}
|
|
274
272
|
}, this._sideBarRight.content)
|
|
275
273
|
].filter(Boolean)
|
|
276
|
-
),
|
|
277
|
-
|
|
274
|
+
), p = i.createElement(i.Fragment, null, [
|
|
275
|
+
n && i.createElement("div", {
|
|
278
276
|
key: "header-bar",
|
|
279
277
|
className: "z-30",
|
|
280
278
|
style: {
|
|
281
279
|
height: (I = t.header) == null ? void 0 : I.height,
|
|
282
|
-
position: ((
|
|
280
|
+
position: ((H = t.header) == null ? void 0 : H.position) || (this._headerBar.fixed ? "sticky" : "static"),
|
|
283
281
|
top: 0,
|
|
284
282
|
backgroundColor: "var(--fibo-surface, #ffffff)",
|
|
285
283
|
zIndex: 30,
|
|
286
284
|
borderBottom: "1px solid var(--fibo-outline, #e0e0e0)"
|
|
287
285
|
}
|
|
288
286
|
}, this._headerBar.content),
|
|
289
|
-
|
|
290
|
-
|
|
287
|
+
g,
|
|
288
|
+
l && i.createElement("div", {
|
|
291
289
|
key: "footer-bar",
|
|
292
290
|
className: "z-30",
|
|
293
291
|
style: {
|
|
294
|
-
height: (
|
|
292
|
+
height: (O = t.footer) == null ? void 0 : O.height,
|
|
295
293
|
position: ((P = t.footer) == null ? void 0 : P.position) || (this._footerBar.fixed ? "sticky" : "static"),
|
|
296
294
|
bottom: 0,
|
|
297
295
|
backgroundColor: "var(--fibo-surface, #ffffff)",
|
|
@@ -300,7 +298,7 @@ class ae extends b {
|
|
|
300
298
|
}
|
|
301
299
|
}, this._footerBar.content)
|
|
302
300
|
].filter(Boolean));
|
|
303
|
-
let
|
|
301
|
+
let d = i.createElement("div", {
|
|
304
302
|
key: "vertical-stack",
|
|
305
303
|
style: {
|
|
306
304
|
display: "flex",
|
|
@@ -310,31 +308,31 @@ class ae extends b {
|
|
|
310
308
|
height: "100%",
|
|
311
309
|
overflow: "hidden"
|
|
312
310
|
}
|
|
313
|
-
},
|
|
314
|
-
|
|
311
|
+
}, p);
|
|
312
|
+
h && (d = i.createElement("div", {
|
|
315
313
|
key: "full-height-left-wrapper",
|
|
316
314
|
style: { display: "flex", flexDirection: "row", flex: 1, height: "100%", overflow: "hidden" }
|
|
317
315
|
}, [
|
|
318
316
|
i.createElement("div", {
|
|
319
317
|
key: "sidebar-left-full",
|
|
320
318
|
style: {
|
|
321
|
-
width: (
|
|
319
|
+
width: (D = t.sidebarLeft) == null ? void 0 : D.width,
|
|
322
320
|
overflowY: "auto",
|
|
323
321
|
borderRight: "1px solid var(--fibo-outline, #e0e0e0)",
|
|
324
322
|
backgroundColor: "var(--fibo-surface, #ffffff)",
|
|
325
323
|
zIndex: 40
|
|
326
324
|
}
|
|
327
325
|
}, this._sideBarLeft.content),
|
|
328
|
-
|
|
329
|
-
])),
|
|
326
|
+
d
|
|
327
|
+
])), f && (d = i.createElement("div", {
|
|
330
328
|
key: "full-height-right-wrapper",
|
|
331
329
|
style: { display: "flex", flexDirection: "row", flex: 1, height: "100%", overflow: "hidden" }
|
|
332
330
|
}, [
|
|
333
|
-
|
|
331
|
+
d,
|
|
334
332
|
i.createElement("div", {
|
|
335
333
|
key: "sidebar-right-full",
|
|
336
334
|
style: {
|
|
337
|
-
width: (
|
|
335
|
+
width: (F = t.sidebarRight) == null ? void 0 : F.width,
|
|
338
336
|
overflowY: "auto",
|
|
339
337
|
borderLeft: "1px solid var(--fibo-outline, #e0e0e0)",
|
|
340
338
|
backgroundColor: "var(--fibo-surface, #ffffff)",
|
|
@@ -342,31 +340,31 @@ class ae extends b {
|
|
|
342
340
|
}
|
|
343
341
|
}, this._sideBarRight.content)
|
|
344
342
|
]));
|
|
345
|
-
const
|
|
343
|
+
const _ = M.getInstance().getOverlays().map((Y) => Y().build()), W = {
|
|
346
344
|
theme: this._theme,
|
|
347
345
|
locale: this._locale,
|
|
348
346
|
providers: this._customProviders,
|
|
349
347
|
className: this.getClassName(),
|
|
350
348
|
style: this.getStyle(),
|
|
351
|
-
children:
|
|
352
|
-
overlays:
|
|
349
|
+
children: d,
|
|
350
|
+
overlays: _
|
|
353
351
|
};
|
|
354
|
-
return i.createElement(
|
|
352
|
+
return i.createElement(re, W);
|
|
355
353
|
}
|
|
356
354
|
}
|
|
357
|
-
const
|
|
358
|
-
const { height: s = 64, sticky: e, className: t, style:
|
|
355
|
+
const ke = u(oe), ne = i.memo((o) => {
|
|
356
|
+
const { height: s = 64, sticky: e, className: t, style: n, children: l, ...a } = o;
|
|
359
357
|
return i.createElement(
|
|
360
358
|
"header",
|
|
361
359
|
{
|
|
362
360
|
className: `flex items-center px-6 border-b border-gray-200 bg-white/80 backdrop-blur-md z-10 w-full ${e ? "sticky top-0" : ""} ${t || ""}`,
|
|
363
|
-
style: { height: s, minHeight: s, ...
|
|
364
|
-
...
|
|
361
|
+
style: { height: s, minHeight: s, ...n },
|
|
362
|
+
...a
|
|
365
363
|
},
|
|
366
|
-
|
|
364
|
+
l
|
|
367
365
|
);
|
|
368
366
|
});
|
|
369
|
-
class
|
|
367
|
+
class le extends m {
|
|
370
368
|
constructor() {
|
|
371
369
|
super(...arguments);
|
|
372
370
|
r(this, "_height", 64);
|
|
@@ -392,8 +390,8 @@ class ce extends b {
|
|
|
392
390
|
this.publishStickyOffset(this._height);
|
|
393
391
|
return;
|
|
394
392
|
}
|
|
395
|
-
const
|
|
396
|
-
this.publishStickyOffset(`calc(${
|
|
393
|
+
const n = typeof t == "number" ? `${t}px` : t, l = typeof this._height == "number" ? `${this._height}px` : this._height;
|
|
394
|
+
this.publishStickyOffset(`calc(${n} + ${l})`);
|
|
397
395
|
}
|
|
398
396
|
build() {
|
|
399
397
|
const e = {
|
|
@@ -404,22 +402,22 @@ class ce extends b {
|
|
|
404
402
|
children: this.processChildren(),
|
|
405
403
|
...this._props
|
|
406
404
|
};
|
|
407
|
-
return i.createElement(
|
|
405
|
+
return i.createElement(ne, e);
|
|
408
406
|
}
|
|
409
407
|
}
|
|
410
|
-
const
|
|
411
|
-
const { width: s = 260, collapsed: e, className: t, style:
|
|
412
|
-
const
|
|
413
|
-
return i.createElement(
|
|
414
|
-
key: `plugin-item-${
|
|
415
|
-
to:
|
|
408
|
+
const Ce = u(le), ae = i.memo((o) => {
|
|
409
|
+
const { width: s = 260, collapsed: e, className: t, style: n, children: l, ...a } = o, c = G(), h = (c == null ? void 0 : c.currentPath) ?? "", f = e ? 80 : s, p = M.getInstance().getSidebarItems().map((d, b) => {
|
|
410
|
+
const _ = h === d.path;
|
|
411
|
+
return i.createElement(U, {
|
|
412
|
+
key: `plugin-item-${d.path || b}`,
|
|
413
|
+
to: d.path,
|
|
416
414
|
className: "no-underline block mb-1",
|
|
417
|
-
children:
|
|
415
|
+
children: K().padding(12).alignItems("center").gap(12).className(`
|
|
418
416
|
transition-colors duration-200 rounded-lg mx-2
|
|
419
|
-
${
|
|
417
|
+
${_ ? "bg-primary/10 text-primary" : "text-gray-600 hover:bg-gray-100"}
|
|
420
418
|
`).children([
|
|
421
|
-
|
|
422
|
-
e ? null :
|
|
419
|
+
d.icon ? Q(d.icon).size(20).build() : null,
|
|
420
|
+
e ? null : J(d.label).style({ fontSize: 14 }).weight(500).build()
|
|
423
421
|
].filter(Boolean)).build()
|
|
424
422
|
});
|
|
425
423
|
});
|
|
@@ -427,14 +425,14 @@ const Re = _(ce), de = i.memo((n) => {
|
|
|
427
425
|
"aside",
|
|
428
426
|
{
|
|
429
427
|
className: `flex flex-col border-r border-gray-200 bg-white transition-all duration-300 h-full ${t || ""}`,
|
|
430
|
-
style: { width:
|
|
431
|
-
...
|
|
428
|
+
style: { width: f, minWidth: f, ...n },
|
|
429
|
+
...a
|
|
432
430
|
},
|
|
433
|
-
|
|
434
|
-
|
|
431
|
+
l,
|
|
432
|
+
p
|
|
435
433
|
);
|
|
436
434
|
});
|
|
437
|
-
class
|
|
435
|
+
class he extends m {
|
|
438
436
|
constructor() {
|
|
439
437
|
super(...arguments);
|
|
440
438
|
r(this, "_width", 260);
|
|
@@ -455,87 +453,11 @@ class fe extends b {
|
|
|
455
453
|
children: this.processChildren(),
|
|
456
454
|
...this._props
|
|
457
455
|
};
|
|
458
|
-
return i.createElement(
|
|
459
|
-
}
|
|
460
|
-
}
|
|
461
|
-
const $e = _(fe), ue = i.memo((n) => {
|
|
462
|
-
const { sidebar: s, header: e, children: t, className: o, style: h, ...c } = n, [d, f] = V(!1);
|
|
463
|
-
return i.createElement(
|
|
464
|
-
"div",
|
|
465
|
-
{
|
|
466
|
-
className: `h-full w-full bg-[#0B0C15] overflow-hidden relative ${o || ""}`,
|
|
467
|
-
style: h,
|
|
468
|
-
...c
|
|
469
|
-
},
|
|
470
|
-
d && i.createElement("div", {
|
|
471
|
-
className: "fixed inset-0 z-40 bg-black/50 backdrop-blur-sm transition-opacity lg:hidden",
|
|
472
|
-
onClick: () => f(!1)
|
|
473
|
-
}),
|
|
474
|
-
i.createElement(
|
|
475
|
-
"button",
|
|
476
|
-
{
|
|
477
|
-
className: "lg:hidden fixed top-4 right-4 z-50 p-2 rounded-lg bg-[#1A1B23] border border-white/10 text-white shadow-lg",
|
|
478
|
-
onClick: () => f(!d)
|
|
479
|
-
},
|
|
480
|
-
i.createElement("div", { className: d ? "i-heroicons-x-mark w-6 h-6" : "i-heroicons-bars-3 w-6 h-6" })
|
|
481
|
-
),
|
|
482
|
-
i.createElement(
|
|
483
|
-
"div",
|
|
484
|
-
{
|
|
485
|
-
className: "grid h-full w-full lg:grid-cols-[260px_1fr] transition-all duration-300"
|
|
486
|
-
},
|
|
487
|
-
i.createElement(
|
|
488
|
-
"aside",
|
|
489
|
-
{
|
|
490
|
-
className: `
|
|
491
|
-
fixed inset-y-0 left-0 z-50 w-[260px] bg-[#0B0C15] border-r border-white/5 transition-transform duration-300 transform
|
|
492
|
-
lg:relative lg:translate-x-0
|
|
493
|
-
${d ? "translate-x-0 shadow-2xl" : "-translate-x-full"}
|
|
494
|
-
`
|
|
495
|
-
},
|
|
496
|
-
s
|
|
497
|
-
),
|
|
498
|
-
i.createElement(
|
|
499
|
-
"main",
|
|
500
|
-
{
|
|
501
|
-
className: "flex flex-col min-w-0 h-full overflow-hidden relative"
|
|
502
|
-
},
|
|
503
|
-
e && i.createElement("div", { className: "flex-shrink-0" }, e),
|
|
504
|
-
i.createElement(
|
|
505
|
-
"div",
|
|
506
|
-
{ className: "flex-1 overflow-y-auto scrollbar-hide p-4 lg:p-0" },
|
|
507
|
-
t
|
|
508
|
-
)
|
|
509
|
-
)
|
|
510
|
-
)
|
|
511
|
-
);
|
|
512
|
-
});
|
|
513
|
-
class me extends b {
|
|
514
|
-
constructor() {
|
|
515
|
-
super(...arguments);
|
|
516
|
-
r(this, "_sidebar");
|
|
517
|
-
r(this, "_header");
|
|
518
|
-
}
|
|
519
|
-
sidebar(e) {
|
|
520
|
-
return this._sidebar = F(e), this;
|
|
521
|
-
}
|
|
522
|
-
header(e) {
|
|
523
|
-
return this._header = F(e), this;
|
|
524
|
-
}
|
|
525
|
-
build() {
|
|
526
|
-
const e = {
|
|
527
|
-
sidebar: this._sidebar,
|
|
528
|
-
header: this._header,
|
|
529
|
-
className: this.getClassName(),
|
|
530
|
-
style: this.getStyle(),
|
|
531
|
-
children: this.processChildren(),
|
|
532
|
-
...this._props
|
|
533
|
-
};
|
|
534
|
-
return i.createElement(ue, e);
|
|
456
|
+
return i.createElement(ae, e);
|
|
535
457
|
}
|
|
536
458
|
}
|
|
537
|
-
const
|
|
538
|
-
class
|
|
459
|
+
const Ne = u(he);
|
|
460
|
+
class ce extends m {
|
|
539
461
|
constructor() {
|
|
540
462
|
super(...arguments);
|
|
541
463
|
r(this, "_alignment", "center");
|
|
@@ -544,7 +466,7 @@ class ge extends b {
|
|
|
544
466
|
return this._alignment = e, this;
|
|
545
467
|
}
|
|
546
468
|
build() {
|
|
547
|
-
const
|
|
469
|
+
const n = [
|
|
548
470
|
"grid",
|
|
549
471
|
"grid-cols-1",
|
|
550
472
|
"grid-rows-1",
|
|
@@ -562,20 +484,20 @@ class ge extends b {
|
|
|
562
484
|
bottomRight: "place-items-end"
|
|
563
485
|
}[this._alignment] || "place-items-center",
|
|
564
486
|
...this._classNames
|
|
565
|
-
].filter(Boolean).join(" "),
|
|
487
|
+
].filter(Boolean).join(" "), l = this.getStyle(), a = this.processChildren();
|
|
566
488
|
return i.createElement(
|
|
567
489
|
"div",
|
|
568
490
|
{
|
|
569
|
-
className:
|
|
570
|
-
style:
|
|
491
|
+
className: n,
|
|
492
|
+
style: l,
|
|
571
493
|
...this._props
|
|
572
494
|
},
|
|
573
|
-
...
|
|
495
|
+
...a
|
|
574
496
|
);
|
|
575
497
|
}
|
|
576
498
|
}
|
|
577
|
-
const
|
|
578
|
-
class
|
|
499
|
+
const ze = u(ce);
|
|
500
|
+
class de extends m {
|
|
579
501
|
constructor() {
|
|
580
502
|
super(...arguments);
|
|
581
503
|
r(this, "_sizeHeight");
|
|
@@ -584,28 +506,28 @@ class pe extends b {
|
|
|
584
506
|
return this._sizeHeight = e, this;
|
|
585
507
|
}
|
|
586
508
|
build() {
|
|
587
|
-
const t = ["fibo-line", "flex", "flex-row", ...this._classNames].filter(Boolean).join(" "),
|
|
588
|
-
this._sizeHeight && (
|
|
589
|
-
const
|
|
509
|
+
const t = ["fibo-line", "flex", "flex-row", ...this._classNames].filter(Boolean).join(" "), n = this.getStyle();
|
|
510
|
+
this._sizeHeight && (n.height = this._sizeHeight);
|
|
511
|
+
const l = this.processChildren();
|
|
590
512
|
return i.createElement(
|
|
591
513
|
"div",
|
|
592
514
|
{
|
|
593
515
|
className: t,
|
|
594
|
-
style:
|
|
516
|
+
style: n,
|
|
595
517
|
...this._props
|
|
596
518
|
},
|
|
597
|
-
...
|
|
519
|
+
...l
|
|
598
520
|
);
|
|
599
521
|
}
|
|
600
522
|
}
|
|
601
|
-
const
|
|
602
|
-
function
|
|
523
|
+
const Se = u(de);
|
|
524
|
+
function fe(...o) {
|
|
603
525
|
return (s) => {
|
|
604
|
-
for (const e of
|
|
526
|
+
for (const e of o)
|
|
605
527
|
e && (typeof e == "function" ? e(s) : e.current = s);
|
|
606
528
|
};
|
|
607
529
|
}
|
|
608
|
-
class
|
|
530
|
+
class ue extends m {
|
|
609
531
|
constructor() {
|
|
610
532
|
super(...arguments);
|
|
611
533
|
r(this, "_direction", "vertical");
|
|
@@ -638,182 +560,34 @@ class be extends b {
|
|
|
638
560
|
...this.getStyle()
|
|
639
561
|
}, t = [...this.getClassName().split(" ").filter(Boolean)];
|
|
640
562
|
this._scrollbar === "hidden" && (t.push("scrollbar-hide"), e.scrollbarWidth = "none", e.msOverflowStyle = "none");
|
|
641
|
-
const
|
|
642
|
-
(
|
|
643
|
-
|
|
563
|
+
const n = this._controller, l = this._props.ref, { ref: a, ...c } = this._props, h = fe(
|
|
564
|
+
(f) => {
|
|
565
|
+
n == null || n.attach(f);
|
|
644
566
|
},
|
|
645
|
-
|
|
567
|
+
l
|
|
646
568
|
);
|
|
647
569
|
return i.createElement(
|
|
648
570
|
"div",
|
|
649
571
|
{
|
|
650
572
|
className: t.join(" "),
|
|
651
573
|
style: e,
|
|
652
|
-
ref:
|
|
653
|
-
...
|
|
574
|
+
ref: h,
|
|
575
|
+
...c
|
|
654
576
|
},
|
|
655
577
|
...this.processChildren()
|
|
656
578
|
);
|
|
657
579
|
}
|
|
658
580
|
}
|
|
659
|
-
const
|
|
660
|
-
const {
|
|
661
|
-
children: s,
|
|
662
|
-
itemHeight: e,
|
|
663
|
-
estimatedItemHeight: t = 50,
|
|
664
|
-
measureItems: o = !1,
|
|
665
|
-
overscan: h = 5,
|
|
666
|
-
containerHeight: c = 500,
|
|
667
|
-
className: d,
|
|
668
|
-
style: f
|
|
669
|
-
} = n, [p, B] = V(0), w = D(null), u = D(/* @__PURE__ */ new Map()), k = D(/* @__PURE__ */ new Map()), x = s.length, v = e !== void 0, N = (l) => v ? e : k.current.get(l) ?? t, C = (l) => {
|
|
670
|
-
if (v)
|
|
671
|
-
return l * e;
|
|
672
|
-
let a = 0;
|
|
673
|
-
for (let m = 0; m < l; m++)
|
|
674
|
-
a += N(m);
|
|
675
|
-
return a;
|
|
676
|
-
}, z = () => {
|
|
677
|
-
if (v)
|
|
678
|
-
return x * e;
|
|
679
|
-
let l = 0;
|
|
680
|
-
for (let a = 0; a < x; a++)
|
|
681
|
-
l += N(a);
|
|
682
|
-
return l;
|
|
683
|
-
}, y = Math.max(0, ((l) => {
|
|
684
|
-
if (v)
|
|
685
|
-
return Math.floor(l / e);
|
|
686
|
-
let a = 0, m = x - 1;
|
|
687
|
-
for (; a < m; ) {
|
|
688
|
-
const g = Math.floor((a + m) / 2);
|
|
689
|
-
C(g) < l ? a = g + 1 : m = g;
|
|
690
|
-
}
|
|
691
|
-
return Math.max(0, a - 1);
|
|
692
|
-
})(p) - h);
|
|
693
|
-
let E;
|
|
694
|
-
if (v) {
|
|
695
|
-
const l = Math.ceil(c / e);
|
|
696
|
-
E = Math.min(x, y + l + h * 2);
|
|
697
|
-
} else {
|
|
698
|
-
let l = C(y), a = y;
|
|
699
|
-
for (; l < p + c + h * t && a < x; )
|
|
700
|
-
l += N(a), a++;
|
|
701
|
-
E = Math.min(x, a);
|
|
702
|
-
}
|
|
703
|
-
const S = s.slice(y, E), L = C(y), R = z(), [$, A] = V(0);
|
|
704
|
-
X(() => {
|
|
705
|
-
if (!o || v) return;
|
|
706
|
-
let l = !1;
|
|
707
|
-
S.forEach((a, m) => {
|
|
708
|
-
const g = y + m, I = u.current.get(g);
|
|
709
|
-
if (I) {
|
|
710
|
-
const H = I.getBoundingClientRect().height;
|
|
711
|
-
H > 0 && k.current.get(g) !== H && (k.current.set(g, H), l = !0);
|
|
712
|
-
}
|
|
713
|
-
}), l && A((a) => a + 1);
|
|
714
|
-
}, [S, y, o, v, $]);
|
|
715
|
-
const O = (l) => {
|
|
716
|
-
B(l.currentTarget.scrollTop);
|
|
717
|
-
};
|
|
718
|
-
return i.createElement(
|
|
719
|
-
"div",
|
|
720
|
-
{
|
|
721
|
-
ref: w,
|
|
722
|
-
className: `fibo-virtual-column ${d || ""}`,
|
|
723
|
-
style: {
|
|
724
|
-
height: `${c}px`,
|
|
725
|
-
overflowY: "auto",
|
|
726
|
-
position: "relative",
|
|
727
|
-
...f
|
|
728
|
-
},
|
|
729
|
-
onScroll: O
|
|
730
|
-
},
|
|
731
|
-
i.createElement("div", {
|
|
732
|
-
style: {
|
|
733
|
-
height: `${R}px`,
|
|
734
|
-
width: "1px",
|
|
735
|
-
position: "absolute",
|
|
736
|
-
top: 0,
|
|
737
|
-
left: 0,
|
|
738
|
-
visibility: "hidden",
|
|
739
|
-
pointerEvents: "none"
|
|
740
|
-
}
|
|
741
|
-
}),
|
|
742
|
-
i.createElement(
|
|
743
|
-
"div",
|
|
744
|
-
{
|
|
745
|
-
style: {
|
|
746
|
-
transform: `translateY(${L}px)`,
|
|
747
|
-
width: "100%"
|
|
748
|
-
}
|
|
749
|
-
},
|
|
750
|
-
S.map((l, a) => {
|
|
751
|
-
const m = y + a;
|
|
752
|
-
return i.createElement(
|
|
753
|
-
"div",
|
|
754
|
-
{
|
|
755
|
-
key: m,
|
|
756
|
-
ref: (g) => {
|
|
757
|
-
g && o && !v ? u.current.set(m, g) : g || u.current.delete(m);
|
|
758
|
-
},
|
|
759
|
-
style: { width: "100%" }
|
|
760
|
-
},
|
|
761
|
-
l
|
|
762
|
-
);
|
|
763
|
-
})
|
|
764
|
-
)
|
|
765
|
-
);
|
|
766
|
-
});
|
|
767
|
-
class xe extends b {
|
|
768
|
-
constructor() {
|
|
769
|
-
super(...arguments);
|
|
770
|
-
r(this, "_itemHeight");
|
|
771
|
-
r(this, "_estimatedItemHeight");
|
|
772
|
-
r(this, "_measureItems", !1);
|
|
773
|
-
r(this, "_overscan", 5);
|
|
774
|
-
r(this, "_containerHeight", 500);
|
|
775
|
-
}
|
|
776
|
-
itemHeight(e) {
|
|
777
|
-
return this._itemHeight = e, this;
|
|
778
|
-
}
|
|
779
|
-
estimatedItemHeight(e) {
|
|
780
|
-
return this._estimatedItemHeight = e, this;
|
|
781
|
-
}
|
|
782
|
-
measureItems(e = !0) {
|
|
783
|
-
return this._measureItems = e, this;
|
|
784
|
-
}
|
|
785
|
-
overscan(e) {
|
|
786
|
-
return this._overscan = e, this;
|
|
787
|
-
}
|
|
788
|
-
containerHeight(e) {
|
|
789
|
-
return this._containerHeight = e, this;
|
|
790
|
-
}
|
|
791
|
-
build() {
|
|
792
|
-
const t = {
|
|
793
|
-
children: this.processChildren(),
|
|
794
|
-
itemHeight: this._itemHeight,
|
|
795
|
-
estimatedItemHeight: this._estimatedItemHeight,
|
|
796
|
-
measureItems: this._measureItems,
|
|
797
|
-
overscan: this._overscan,
|
|
798
|
-
containerHeight: this._containerHeight,
|
|
799
|
-
className: this.getClassName(),
|
|
800
|
-
style: this.getStyle()
|
|
801
|
-
};
|
|
802
|
-
return i.createElement(ye, t);
|
|
803
|
-
}
|
|
804
|
-
}
|
|
805
|
-
const Pe = _(xe);
|
|
581
|
+
const Ee = u(ue);
|
|
806
582
|
export {
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
ze as
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
$e as d,
|
|
818
|
-
Me as e
|
|
583
|
+
xe as C,
|
|
584
|
+
Ce as H,
|
|
585
|
+
Se as L,
|
|
586
|
+
Be as S,
|
|
587
|
+
ze as Z,
|
|
588
|
+
ve as a,
|
|
589
|
+
we as b,
|
|
590
|
+
ke as c,
|
|
591
|
+
Ne as d,
|
|
592
|
+
Ee as e
|
|
819
593
|
};
|