@gardenfi/garden-book 0.3.0-beta.2 → 0.3.1
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/DataTable/DataTable.d.ts +0 -9
- package/dist/DataTable/index.js +44 -44
- package/dist/Footer/index.js +16 -10
- package/dist/InfoTooltip/InfoTooltip.d.ts +0 -10
- package/dist/InfoTooltip/index.js +79 -71
- package/dist/Logo/Code4renaLogo.d.ts +5 -0
- package/dist/Logo/Code4renaLogo.js +45 -0
- package/dist/Logo/index.d.ts +1 -0
- package/dist/Logo/index.js +10 -8
- package/dist/OTPInput/OTPInput.d.ts +2 -2
- package/dist/OTPInput/index.js +31 -31
- package/dist/SelectDropdown/SelectDropdown.d.ts +1 -1
- package/dist/SelectDropdown/index.js +34 -32
- package/dist/index.js +122 -120
- package/dist/node_modules/@radix-ui/react-visually-hidden/dist/index.js +12 -14
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/dist/node_modules/@radix-ui/react-tooltip/dist/index.js +0 -330
- package/dist/node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-slot/dist/index.js +0 -11
|
@@ -4,14 +4,10 @@ export type DataTableColumn<T> = {
|
|
|
4
4
|
key: string;
|
|
5
5
|
header: string;
|
|
6
6
|
align?: "left" | "right";
|
|
7
|
-
/** Tailwind width class (e.g. "gf-w-1/4"). Applies to the desktop column. */
|
|
8
7
|
width?: string;
|
|
9
8
|
cell: (row: T) => ReactNode;
|
|
10
|
-
/** Enables a clickable sort arrow in the column header. */
|
|
11
9
|
sortable?: boolean;
|
|
12
|
-
/** Current sort direction for this column. null = unsorted (neutral icon). */
|
|
13
10
|
sortDir?: "asc" | "desc" | null;
|
|
14
|
-
/** Called when the user clicks the column header to sort. */
|
|
15
11
|
onSort?: () => void;
|
|
16
12
|
};
|
|
17
13
|
export type DataTableBodyState = "loading" | "error" | "empty" | "data";
|
|
@@ -21,7 +17,6 @@ export type DataTableError = {
|
|
|
21
17
|
};
|
|
22
18
|
export type DataTableProps<T> = {
|
|
23
19
|
title?: string;
|
|
24
|
-
/** Optional content rendered to the right of the title (e.g. filter dropdowns). */
|
|
25
20
|
headerActions?: ReactNode;
|
|
26
21
|
rows: T[];
|
|
27
22
|
columns: DataTableColumn<T>[];
|
|
@@ -31,20 +26,16 @@ export type DataTableProps<T> = {
|
|
|
31
26
|
minWidth?: number;
|
|
32
27
|
emptyTitle?: string;
|
|
33
28
|
emptyDescription?: string;
|
|
34
|
-
/** Custom card renderer for the mobile view (<md). Falls back to label/value columns. */
|
|
35
29
|
renderMobileCard?: (row: T, index: number) => ReactNode;
|
|
36
30
|
renderExpanded?: (row: T, index: number) => ReactNode;
|
|
37
|
-
/** Called when a non-expandable row is clicked. Ignored when `renderExpanded` is set. */
|
|
38
31
|
onRowClick?: (row: T, index: number) => void;
|
|
39
32
|
loading?: boolean;
|
|
40
33
|
skeletonRowCount?: number;
|
|
41
34
|
error?: DataTableError | null;
|
|
42
35
|
onRetry?: () => void;
|
|
43
|
-
/** Extra content rendered below the table (e.g. pagination). */
|
|
44
36
|
footer?: ReactNode;
|
|
45
37
|
oddRowColor?: string;
|
|
46
38
|
evenRowColor?: string;
|
|
47
|
-
/** Defaults to `evenRowColor`. */
|
|
48
39
|
headerBgColor?: string;
|
|
49
40
|
};
|
|
50
41
|
export declare const DataTable: <T>({ title, headerActions, rows, columns, getKey, emptyMessage, emptyMinHeight, minWidth, emptyTitle, emptyDescription, renderMobileCard, renderExpanded, onRowClick, loading, skeletonRowCount, error, onRetry, footer, oddRowColor, evenRowColor, headerBgColor, }: DataTableProps<T>) => import("react/jsx-runtime").JSX.Element;
|
package/dist/DataTable/index.js
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as l, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import { useState as R, useRef as ee, Fragment as te } from "react";
|
|
3
3
|
import { motion as b, AnimatePresence as ae } from "framer-motion";
|
|
4
4
|
import { Typography as c } from "../Typography/index.js";
|
|
5
5
|
import { cn as h } from "../utils/index.js";
|
|
6
6
|
import { Table as re, TableHeader as ie, TableRow as T, TableHead as H, TableBody as ne, TableCell as x } from "./Table.js";
|
|
7
|
-
import { useAnimatedTable as
|
|
7
|
+
import { useAnimatedTable as le } from "./useAnimatedTable.js";
|
|
8
8
|
import { ErrorStateContent as O } from "../ErrorState/index.js";
|
|
9
9
|
import { EmptyStateContent as U } from "../EmptyState/index.js";
|
|
10
|
-
import { CardList as
|
|
11
|
-
import
|
|
12
|
-
import
|
|
10
|
+
import { CardList as fe } from "../CardList/index.js";
|
|
11
|
+
import se from "../node_modules/lucide-react/dist/esm/icons/arrow-up.js";
|
|
12
|
+
import ge from "../node_modules/lucide-react/dist/esm/icons/arrow-down.js";
|
|
13
13
|
import oe from "../node_modules/lucide-react/dist/esm/icons/arrow-up-down.js";
|
|
14
14
|
import de from "../node_modules/lucide-react/dist/esm/icons/chevron-down.js";
|
|
15
15
|
const he = b(T), Te = ({
|
|
16
16
|
title: p,
|
|
17
17
|
headerActions: N,
|
|
18
18
|
rows: m,
|
|
19
|
-
columns:
|
|
19
|
+
columns: f,
|
|
20
20
|
getKey: v,
|
|
21
21
|
emptyMessage: j,
|
|
22
22
|
emptyMinHeight: w = "40dvh",
|
|
@@ -25,23 +25,23 @@ const he = b(T), Te = ({
|
|
|
25
25
|
emptyDescription: z,
|
|
26
26
|
renderMobileCard: L,
|
|
27
27
|
renderExpanded: y,
|
|
28
|
-
onRowClick:
|
|
28
|
+
onRowClick: s,
|
|
29
29
|
loading: k = !1,
|
|
30
30
|
skeletonRowCount: C = 6,
|
|
31
|
-
error:
|
|
31
|
+
error: g = null,
|
|
32
32
|
onRetry: I,
|
|
33
33
|
footer: A,
|
|
34
34
|
oddRowColor: _ = "#f5f8fa",
|
|
35
35
|
evenRowColor: B = "#ebf0f5",
|
|
36
36
|
headerBgColor: q
|
|
37
37
|
}) => {
|
|
38
|
-
const r = !!y, J = m.length === 0, o = k ? "loading" :
|
|
38
|
+
const r = !!y, J = m.length === 0, o = k ? "loading" : g ? "error" : J ? "empty" : "data", [M, Q] = R(null), D = (t) => Q((a) => a === t ? null : t), V = `${o}-${m.length}`, { wrapperRef: W, animatedKeys: S, wasPreloaded: X, skeletonCount: Y } = le(k, m.length, C, V), K = ee(null);
|
|
39
39
|
o === "data" && K.current === "loading" && m.forEach((t, a) => S.current.add(v(t, a))), K.current = o;
|
|
40
40
|
const $ = q ?? B, E = (t) => ({
|
|
41
41
|
backgroundColor: t % 2 === 0 ? _ : B
|
|
42
|
-
}), Z =
|
|
43
|
-
return /* @__PURE__ */
|
|
44
|
-
(p || N) && /* @__PURE__ */
|
|
42
|
+
}), Z = f.length + (r ? 1 : 0);
|
|
43
|
+
return /* @__PURE__ */ l("div", { className: "gf-w-full gf-overflow-hidden gf-rounded-2xl gf-bg-white/70 gf-flex gf-flex-col [overflow-anchor:none]", children: [
|
|
44
|
+
(p || N) && /* @__PURE__ */ l(
|
|
45
45
|
"div",
|
|
46
46
|
{
|
|
47
47
|
className: "gf-flex gf-items-center gf-justify-between gf-gap-3 gf-px-6 gf-py-4",
|
|
@@ -53,27 +53,27 @@ const he = b(T), Te = ({
|
|
|
53
53
|
}
|
|
54
54
|
),
|
|
55
55
|
/* @__PURE__ */ e("div", { className: "md:gf-hidden", children: /* @__PURE__ */ e(
|
|
56
|
-
|
|
56
|
+
fe,
|
|
57
57
|
{
|
|
58
58
|
rows: m,
|
|
59
|
-
columns:
|
|
59
|
+
columns: f,
|
|
60
60
|
getKey: v,
|
|
61
61
|
emptyMinHeight: w,
|
|
62
62
|
loading: k,
|
|
63
63
|
skeletonRowCount: Math.max(3, Math.floor(C / 2)),
|
|
64
|
-
error:
|
|
64
|
+
error: g ? /* @__PURE__ */ e(
|
|
65
65
|
O,
|
|
66
66
|
{
|
|
67
|
-
status:
|
|
68
|
-
message:
|
|
67
|
+
status: g.status,
|
|
68
|
+
message: g.message,
|
|
69
69
|
onRetry: I
|
|
70
70
|
}
|
|
71
71
|
) : void 0,
|
|
72
72
|
empty: u ? /* @__PURE__ */ e(U, { title: u, description: z }) : /* @__PURE__ */ e(c, { size: "h5", weight: "regular", className: "gf-text-midGrey", children: j }),
|
|
73
73
|
renderCard: L,
|
|
74
74
|
renderExpanded: y,
|
|
75
|
-
onRowClick:
|
|
76
|
-
className: p
|
|
75
|
+
onRowClick: s,
|
|
76
|
+
className: p ? "gf-rounded-none" : void 0
|
|
77
77
|
}
|
|
78
78
|
) }),
|
|
79
79
|
/* @__PURE__ */ e(
|
|
@@ -81,18 +81,18 @@ const he = b(T), Te = ({
|
|
|
81
81
|
{
|
|
82
82
|
ref: W,
|
|
83
83
|
className: "gf-hidden md:gf-block gf-overflow-x-auto gf-overflow-y-hidden gf-no-scrollbar @container",
|
|
84
|
-
children: /* @__PURE__ */
|
|
85
|
-
/* @__PURE__ */ e(ie, { children: /* @__PURE__ */
|
|
86
|
-
|
|
84
|
+
children: /* @__PURE__ */ l(re, { className: "gf-table-fixed", style: { minWidth: F }, children: [
|
|
85
|
+
/* @__PURE__ */ e(ie, { children: /* @__PURE__ */ l(T, { style: { backgroundColor: $ }, children: [
|
|
86
|
+
f.map((t, a) => /* @__PURE__ */ e(
|
|
87
87
|
H,
|
|
88
88
|
{
|
|
89
89
|
className: h(
|
|
90
90
|
t.width,
|
|
91
91
|
a === 0 && "gf-pl-6",
|
|
92
|
-
!r && a ===
|
|
92
|
+
!r && a === f.length - 1 && "gf-pr-6",
|
|
93
93
|
t.align === "right" && "gf-text-right"
|
|
94
94
|
),
|
|
95
|
-
children: t.sortable ? /* @__PURE__ */
|
|
95
|
+
children: t.sortable ? /* @__PURE__ */ l(
|
|
96
96
|
"button",
|
|
97
97
|
{
|
|
98
98
|
type: "button",
|
|
@@ -103,7 +103,7 @@ const he = b(T), Te = ({
|
|
|
103
103
|
),
|
|
104
104
|
children: [
|
|
105
105
|
/* @__PURE__ */ e(c, { size: "h5", weight: "regular", children: t.header }),
|
|
106
|
-
t.sortDir === "asc" ? /* @__PURE__ */ e(
|
|
106
|
+
t.sortDir === "asc" ? /* @__PURE__ */ e(se, { className: "gf-h-3 gf-w-3 gf-text-primaryIris gf-shrink-0" }) : t.sortDir === "desc" ? /* @__PURE__ */ e(ge, { className: "gf-h-3 gf-w-3 gf-text-primaryIris gf-shrink-0" }) : /* @__PURE__ */ e(oe, { className: "gf-h-3 gf-w-3 gf-text-midGrey gf-shrink-0" })
|
|
107
107
|
]
|
|
108
108
|
}
|
|
109
109
|
) : /* @__PURE__ */ e(c, { size: "h5", weight: "regular", children: t.header })
|
|
@@ -112,19 +112,19 @@ const he = b(T), Te = ({
|
|
|
112
112
|
)),
|
|
113
113
|
r && /* @__PURE__ */ e(H, { className: "gf-w-12 gf-pl-0 gf-pr-6", "aria-hidden": !0 })
|
|
114
114
|
] }) }),
|
|
115
|
-
/* @__PURE__ */
|
|
116
|
-
o === "loading" && Array.from({ length: Y }).map((t, a) => /* @__PURE__ */
|
|
115
|
+
/* @__PURE__ */ l(ne, { children: [
|
|
116
|
+
o === "loading" && Array.from({ length: Y }).map((t, a) => /* @__PURE__ */ l(
|
|
117
117
|
T,
|
|
118
118
|
{
|
|
119
119
|
className: "gf-h-[42px] gf-pointer-events-none",
|
|
120
120
|
style: E(a),
|
|
121
121
|
children: [
|
|
122
|
-
|
|
122
|
+
f.map((n, d) => /* @__PURE__ */ e(
|
|
123
123
|
x,
|
|
124
124
|
{
|
|
125
125
|
className: h(
|
|
126
126
|
d === 0 && "gf-pl-6",
|
|
127
|
-
!r && d ===
|
|
127
|
+
!r && d === f.length - 1 && "gf-pr-6",
|
|
128
128
|
n.align === "right" && "gf-text-right"
|
|
129
129
|
),
|
|
130
130
|
children: /* @__PURE__ */ e(
|
|
@@ -146,34 +146,34 @@ const he = b(T), Te = ({
|
|
|
146
146
|
)),
|
|
147
147
|
o === "data" && m.map((t, a) => {
|
|
148
148
|
const n = v(t, a), d = r && M === n, G = !X.current && !S.current.has(n);
|
|
149
|
-
return G && S.current.add(n), /* @__PURE__ */
|
|
150
|
-
/* @__PURE__ */
|
|
149
|
+
return G && S.current.add(n), /* @__PURE__ */ l(te, { children: [
|
|
150
|
+
/* @__PURE__ */ l(
|
|
151
151
|
he,
|
|
152
152
|
{
|
|
153
153
|
className: h(
|
|
154
154
|
"gf-h-[42px]",
|
|
155
|
-
(r ||
|
|
155
|
+
(r || s) && "gf-cursor-pointer gf-transition-colors hover:!gf-bg-white/70"
|
|
156
156
|
),
|
|
157
157
|
style: E(a),
|
|
158
158
|
initial: G ? { opacity: 0 } : !1,
|
|
159
159
|
animate: { opacity: 1 },
|
|
160
160
|
transition: { duration: 0.15, ease: [0.4, 0, 0.2, 1] },
|
|
161
|
-
onClick: r ? () => D(n) :
|
|
162
|
-
role: r ||
|
|
163
|
-
tabIndex: r ||
|
|
161
|
+
onClick: r ? () => D(n) : s ? () => s(t, a) : void 0,
|
|
162
|
+
role: r || s ? "button" : void 0,
|
|
163
|
+
tabIndex: r || s ? 0 : void 0,
|
|
164
164
|
onKeyDown: r ? (i) => {
|
|
165
165
|
(i.key === "Enter" || i.key === " ") && (i.preventDefault(), D(n));
|
|
166
|
-
} :
|
|
167
|
-
(i.key === "Enter" || i.key === " ") && (i.preventDefault(),
|
|
166
|
+
} : s ? (i) => {
|
|
167
|
+
(i.key === "Enter" || i.key === " ") && (i.preventDefault(), s(t, a));
|
|
168
168
|
} : void 0,
|
|
169
169
|
"aria-expanded": r ? d : void 0,
|
|
170
170
|
children: [
|
|
171
|
-
|
|
171
|
+
f.map((i, P) => /* @__PURE__ */ e(
|
|
172
172
|
x,
|
|
173
173
|
{
|
|
174
174
|
className: h(
|
|
175
175
|
P === 0 && "gf-pl-6",
|
|
176
|
-
!r && P ===
|
|
176
|
+
!r && P === f.length - 1 && "gf-pr-6",
|
|
177
177
|
i.align === "right" && "gf-text-right"
|
|
178
178
|
),
|
|
179
179
|
children: /* @__PURE__ */ e(c, { size: "h5", weight: "medium", as: "span", children: i.cell(t) })
|
|
@@ -232,16 +232,16 @@ const he = b(T), Te = ({
|
|
|
232
232
|
] })
|
|
233
233
|
}
|
|
234
234
|
),
|
|
235
|
-
o === "error" &&
|
|
235
|
+
o === "error" && g && /* @__PURE__ */ e(
|
|
236
236
|
"div",
|
|
237
237
|
{
|
|
238
|
-
className: "gf-flex gf-items-center gf-justify-center gf-w-full
|
|
238
|
+
className: "gf-flex gf-items-center gf-justify-center gf-w-full",
|
|
239
239
|
style: { minHeight: w },
|
|
240
240
|
children: /* @__PURE__ */ e(
|
|
241
241
|
O,
|
|
242
242
|
{
|
|
243
|
-
status:
|
|
244
|
-
message:
|
|
243
|
+
status: g.status,
|
|
244
|
+
message: g.message,
|
|
245
245
|
onRetry: I
|
|
246
246
|
}
|
|
247
247
|
)
|
|
@@ -250,7 +250,7 @@ const he = b(T), Te = ({
|
|
|
250
250
|
o === "empty" && /* @__PURE__ */ e(
|
|
251
251
|
"div",
|
|
252
252
|
{
|
|
253
|
-
className: "gf-flex gf-items-center gf-justify-center gf-w-full
|
|
253
|
+
className: "gf-flex gf-items-center gf-justify-center gf-w-full",
|
|
254
254
|
style: { minHeight: w },
|
|
255
255
|
children: u ? /* @__PURE__ */ e(
|
|
256
256
|
U,
|
package/dist/Footer/index.js
CHANGED
|
@@ -4,9 +4,9 @@ import { GardenIcon as y } from "../Logo/GardenIcon.js";
|
|
|
4
4
|
import { CopyrightsIcon as A } from "../Icons/CopyrightsIcon.js";
|
|
5
5
|
import { DiscordIcon as U } from "../Icons/DiscordIcon.js";
|
|
6
6
|
import { XIcon as D } from "../Icons/XIcon.js";
|
|
7
|
-
import { YoutubeIcon as
|
|
8
|
-
import { cn as
|
|
9
|
-
import { FooterBackgroundAnimation as
|
|
7
|
+
import { YoutubeIcon as L } from "../Icons/YoutubeIcon.js";
|
|
8
|
+
import { cn as I } from "../utils/index.js";
|
|
9
|
+
import { FooterBackgroundAnimation as R } from "./FooterBackgroundAnimation.js";
|
|
10
10
|
import { FooterLinks as n } from "./FooterLink.js";
|
|
11
11
|
import j from "../assets/maskRect.svg.js";
|
|
12
12
|
import { useClientOnly as _ } from "../hooks/useClientOnly.js";
|
|
@@ -29,7 +29,7 @@ const $ = {
|
|
|
29
29
|
S(() => () => {
|
|
30
30
|
r.current && clearTimeout(r.current);
|
|
31
31
|
}, []);
|
|
32
|
-
const a = s && s === "testnet" ? "https://testnet.garden.finance" : "https://app.garden.finance", e = "https://garden.finance",
|
|
32
|
+
const a = s && s === "testnet" ? "https://testnet.garden.finance" : "https://app.garden.finance", e = "https://garden.finance", C = {
|
|
33
33
|
Products: {
|
|
34
34
|
swap: {
|
|
35
35
|
title: "Swap",
|
|
@@ -101,7 +101,7 @@ const $ = {
|
|
|
101
101
|
isExternal: !0
|
|
102
102
|
}
|
|
103
103
|
}
|
|
104
|
-
},
|
|
104
|
+
}, k = {
|
|
105
105
|
btcToSol: {
|
|
106
106
|
title: "BTC to SOL",
|
|
107
107
|
link: e + "/routes/bridge-btc-to-sol",
|
|
@@ -218,12 +218,18 @@ const $ = {
|
|
|
218
218
|
inputChain: "Ethereum",
|
|
219
219
|
chain: "Base",
|
|
220
220
|
isExternal: !0
|
|
221
|
+
},
|
|
222
|
+
btcToLtc: {
|
|
223
|
+
title: "BTC to LTC",
|
|
224
|
+
link: e + "/routes/bridge-btc-to-ltc",
|
|
225
|
+
isExternal: !0,
|
|
226
|
+
chain: "Litecoin"
|
|
221
227
|
}
|
|
222
|
-
}, o = { ...$, ...x }, { Products: E, Resources: u, Developers: B } =
|
|
228
|
+
}, o = { ...$, ...x }, { Products: E, Resources: u, Developers: B } = C;
|
|
223
229
|
return /* @__PURE__ */ i(
|
|
224
230
|
"footer",
|
|
225
231
|
{
|
|
226
|
-
className:
|
|
232
|
+
className: I(
|
|
227
233
|
"gf-z-10 gf-relative gf-mx-auto gf-flex gf-w-full gf-flex-col gf-items-center gf-justify-center gf-bg-white gf-px-6 gf-pb-10 gf-pt-20 md:gf-px-10",
|
|
228
234
|
m,
|
|
229
235
|
l ? "gf-text-white" : "gf-text-dark-grey"
|
|
@@ -268,7 +274,7 @@ const $ = {
|
|
|
268
274
|
}
|
|
269
275
|
),
|
|
270
276
|
/* @__PURE__ */ t(
|
|
271
|
-
|
|
277
|
+
L,
|
|
272
278
|
{
|
|
273
279
|
onClick: () => {
|
|
274
280
|
f && window.open(o.youtube, "_blank");
|
|
@@ -293,7 +299,7 @@ const $ = {
|
|
|
293
299
|
n,
|
|
294
300
|
{
|
|
295
301
|
title: "Routes",
|
|
296
|
-
links:
|
|
302
|
+
links: k,
|
|
297
303
|
hoveredIndex: w,
|
|
298
304
|
onHover: T,
|
|
299
305
|
className: "gf-flex gf-w-full gf-max-w-[400px] gf-flex-col gf-gap-3 md:gf-w-fit",
|
|
@@ -384,7 +390,7 @@ const $ = {
|
|
|
384
390
|
] })
|
|
385
391
|
] }),
|
|
386
392
|
/* @__PURE__ */ t(
|
|
387
|
-
|
|
393
|
+
R,
|
|
388
394
|
{
|
|
389
395
|
isMobile: !1,
|
|
390
396
|
isLogoHovered: l,
|
|
@@ -2,21 +2,11 @@ import { ReactNode } from 'react';
|
|
|
2
2
|
|
|
3
3
|
type Side = "top" | "right" | "bottom" | "left";
|
|
4
4
|
export type InfoTooltipProps = {
|
|
5
|
-
/** The element that opens the tooltip on hover/focus. */
|
|
6
5
|
trigger: ReactNode;
|
|
7
|
-
/** Tooltip body — typically a short description and a few label/value rows. */
|
|
8
6
|
children: ReactNode;
|
|
9
7
|
side?: Side;
|
|
10
8
|
delayDuration?: number;
|
|
11
9
|
className?: string;
|
|
12
10
|
};
|
|
13
|
-
/**
|
|
14
|
-
* Dashboard-standard rich tooltip — white pill with a soft drop-shadow and a
|
|
15
|
-
* rotated rounded-square notch. Radix's `Arrow` primitive handles positioning
|
|
16
|
-
* so the notch always points at the trigger, even after collision flips/shifts.
|
|
17
|
-
* Notch offset adapts to Radix's actual rendered side (read from `data-side`),
|
|
18
|
-
* so collision-flipped tooltips stay aligned. Collides against `<main>` so it
|
|
19
|
-
* never extends over the sidebar.
|
|
20
|
-
*/
|
|
21
11
|
export declare const InfoTooltip: ({ trigger, children, side, delayDuration, className, }: InfoTooltipProps) => import("react/jsx-runtime").JSX.Element;
|
|
22
12
|
export {};
|
|
@@ -1,81 +1,89 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { cn as
|
|
5
|
-
const
|
|
6
|
-
top: "
|
|
7
|
-
bottom: "
|
|
8
|
-
left: "
|
|
9
|
-
right: "
|
|
10
|
-
},
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
1
|
+
import { jsxs as s, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { AnimatePresence as d, motion as h } from "framer-motion";
|
|
3
|
+
import { useState as b, useRef as y } from "react";
|
|
4
|
+
import { cn as T } from "../utils/index.js";
|
|
5
|
+
const e = 10, I = {
|
|
6
|
+
top: { position: "absolute", bottom: "100%", left: "50%", transform: "translateX(-50%)", marginBottom: `${e}px`, zIndex: 50 },
|
|
7
|
+
bottom: { position: "absolute", top: "100%", left: "50%", transform: "translateX(-50%)", marginTop: `${e}px`, zIndex: 50 },
|
|
8
|
+
left: { position: "absolute", right: "100%", top: "50%", transform: "translateY(-50%)", marginRight: `${e}px`, zIndex: 50 },
|
|
9
|
+
right: { position: "absolute", left: "100%", top: "50%", transform: "translateY(-50%)", marginLeft: `${e}px`, zIndex: 50 }
|
|
10
|
+
}, v = {
|
|
11
|
+
top: { position: "absolute", bottom: -5, left: "50%", transform: "translateX(-50%) rotate(45deg)" },
|
|
12
|
+
bottom: { position: "absolute", top: -5, left: "50%", transform: "translateX(-50%) rotate(45deg)" },
|
|
13
|
+
left: { position: "absolute", right: -5, top: "50%", transform: "translateY(-50%) rotate(45deg)" },
|
|
14
|
+
right: { position: "absolute", left: -5, top: "50%", transform: "translateY(-50%) rotate(45deg)" }
|
|
15
|
+
}, l = {
|
|
16
|
+
top: { y: 6 },
|
|
17
|
+
bottom: { y: -6 },
|
|
18
|
+
left: { x: 6 },
|
|
19
|
+
right: { x: -6 }
|
|
20
|
+
}, N = ({
|
|
21
|
+
trigger: p,
|
|
22
|
+
children: f,
|
|
23
|
+
side: t = "top",
|
|
24
|
+
delayDuration: m = 150,
|
|
25
|
+
className: g
|
|
26
|
+
}) => {
|
|
27
|
+
const [c, r] = b(!1), a = y(null), n = () => {
|
|
28
|
+
a.current = setTimeout(() => r(!0), m);
|
|
29
|
+
}, i = () => {
|
|
30
|
+
a.current && clearTimeout(a.current), r(!1);
|
|
31
|
+
};
|
|
32
|
+
return /* @__PURE__ */ s(
|
|
33
|
+
"div",
|
|
24
34
|
{
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
"gf-text-primaryIris",
|
|
34
|
-
i
|
|
35
|
-
),
|
|
35
|
+
className: "gf-relative gf-inline-flex gf-items-center",
|
|
36
|
+
onMouseEnter: n,
|
|
37
|
+
onMouseLeave: i,
|
|
38
|
+
onFocus: n,
|
|
39
|
+
onBlur: i,
|
|
40
|
+
onTouchStart: (x) => {
|
|
41
|
+
x.stopPropagation(), r((u) => !u);
|
|
42
|
+
},
|
|
36
43
|
children: [
|
|
37
|
-
|
|
38
|
-
/* @__PURE__ */
|
|
39
|
-
|
|
44
|
+
p,
|
|
45
|
+
/* @__PURE__ */ o(d, { children: c && /* @__PURE__ */ o("div", { style: I[t], children: /* @__PURE__ */ s(
|
|
46
|
+
h.div,
|
|
40
47
|
{
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
48
|
+
initial: { opacity: 0, scale: 0.92, ...l[t] },
|
|
49
|
+
animate: { opacity: 1, scale: 1, x: 0, y: 0 },
|
|
50
|
+
exit: { opacity: 0, scale: 0.92, ...l[t] },
|
|
51
|
+
transition: { duration: 0.15, ease: "easeInOut" },
|
|
52
|
+
style: { position: "relative" },
|
|
53
|
+
children: [
|
|
54
|
+
/* @__PURE__ */ o(
|
|
55
|
+
"div",
|
|
56
|
+
{
|
|
57
|
+
"aria-hidden": !0,
|
|
58
|
+
style: {
|
|
59
|
+
...v[t],
|
|
60
|
+
width: 12,
|
|
61
|
+
height: 12,
|
|
62
|
+
borderRadius: 3,
|
|
63
|
+
backgroundColor: "white",
|
|
64
|
+
boxShadow: "0 4px 12px -4px rgba(85,75,106,0.14)"
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
),
|
|
68
|
+
/* @__PURE__ */ o(
|
|
69
|
+
"div",
|
|
70
|
+
{
|
|
71
|
+
className: T(
|
|
72
|
+
"gf-w-max gf-max-w-[220px] gf-rounded-2xl gf-bg-white gf-px-4 gf-py-3",
|
|
73
|
+
"gf-shadow-[0_4px_12px_-4px_rgba(85,75,106,0.14)]",
|
|
74
|
+
"gf-text-primaryIris gf-text-xs",
|
|
75
|
+
g
|
|
76
|
+
),
|
|
77
|
+
children: f
|
|
78
|
+
}
|
|
79
|
+
)
|
|
80
|
+
]
|
|
46
81
|
}
|
|
47
|
-
)
|
|
82
|
+
) }) })
|
|
48
83
|
]
|
|
49
84
|
}
|
|
50
85
|
);
|
|
51
|
-
}, B = ({
|
|
52
|
-
trigger: r,
|
|
53
|
-
children: i,
|
|
54
|
-
side: a = "top",
|
|
55
|
-
delayDuration: g = 150,
|
|
56
|
-
className: n
|
|
57
|
-
}) => {
|
|
58
|
-
const [c, l] = u(null), [t, o] = u(!1);
|
|
59
|
-
return d(() => {
|
|
60
|
-
l(document.querySelector("main"));
|
|
61
|
-
}, []), d(() => {
|
|
62
|
-
if (!t) return;
|
|
63
|
-
const e = () => o(!1);
|
|
64
|
-
return document.addEventListener("touchstart", e, { passive: !0 }), () => document.removeEventListener("touchstart", e);
|
|
65
|
-
}, [t]), /* @__PURE__ */ f(h, { delayDuration: g, children: /* @__PURE__ */ m(x, { open: t, onOpenChange: o, children: [
|
|
66
|
-
/* @__PURE__ */ f(
|
|
67
|
-
v,
|
|
68
|
-
{
|
|
69
|
-
asChild: !0,
|
|
70
|
-
onTouchStart: (e) => {
|
|
71
|
-
e.stopPropagation(), o((s) => !s);
|
|
72
|
-
},
|
|
73
|
-
children: r
|
|
74
|
-
}
|
|
75
|
-
),
|
|
76
|
-
/* @__PURE__ */ f(O, { side: a, className: n, collisionBoundary: c, children: i })
|
|
77
|
-
] }) });
|
|
78
86
|
};
|
|
79
87
|
export {
|
|
80
|
-
|
|
88
|
+
N as InfoTooltip
|
|
81
89
|
};
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { jsxs as t, jsx as C } from "react/jsx-runtime";
|
|
2
|
+
const e = (l) => /* @__PURE__ */ t(
|
|
3
|
+
"svg",
|
|
4
|
+
{
|
|
5
|
+
width: "32",
|
|
6
|
+
height: "32",
|
|
7
|
+
viewBox: "0 0 224 220",
|
|
8
|
+
...l,
|
|
9
|
+
fill: "none",
|
|
10
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
11
|
+
children: [
|
|
12
|
+
/* @__PURE__ */ C(
|
|
13
|
+
"path",
|
|
14
|
+
{
|
|
15
|
+
d: "M223.791 131.053L210.241 65.6732C211.461 71.5832 205.411 78.7032 198.531 84.3532C198.091 84.7532 197.621 85.1432 197.111 85.5532L191.621 89.8932C170.011 106.893 135.751 132.373 126.081 137.673C125.441 138.043 124.801 138.393 124.151 138.713C124.011 138.783 123.871 138.843 123.731 138.913C123.221 139.163 122.721 139.403 122.211 139.633C122.081 139.693 121.951 139.733 121.831 139.793C121.311 140.013 120.781 140.233 120.261 140.423C120.171 140.453 120.071 140.483 119.981 140.523C119.421 140.723 118.861 140.913 118.301 141.073C118.241 141.093 118.181 141.103 118.121 141.123C117.521 141.293 116.931 141.443 116.341 141.573C116.311 141.573 116.281 141.583 116.261 141.593C115.641 141.733 115.011 141.843 114.401 141.933C114.401 141.933 114.391 141.933 114.381 141.933C113.101 142.113 111.831 142.193 110.581 142.173V219.993C118.281 219.793 125.791 217.643 132.411 213.743C142.361 208.263 168.841 187.203 199.871 162.233L212.041 152.453C220.131 145.993 224.011 139.583 223.921 132.823C223.951 132.223 223.921 131.623 223.821 131.033L223.791 131.053Z",
|
|
16
|
+
fill: "#908aad"
|
|
17
|
+
}
|
|
18
|
+
),
|
|
19
|
+
/* @__PURE__ */ C(
|
|
20
|
+
"path",
|
|
21
|
+
{
|
|
22
|
+
d: "M13.7511 65.8332C13.7511 65.8332 13.7511 65.8232 13.7511 65.8132L13.7311 65.9332C13.7311 65.9332 13.7511 65.8632 13.7611 65.8332H13.7511Z",
|
|
23
|
+
fill: "#6e6889"
|
|
24
|
+
}
|
|
25
|
+
),
|
|
26
|
+
/* @__PURE__ */ C(
|
|
27
|
+
"path",
|
|
28
|
+
{
|
|
29
|
+
d: "M97.6411 137.773C97.6411 137.773 23.8911 83.4332 22.4111 82.3332C14.9611 76.5432 12.9211 71.2932 13.4711 67.1632L0.191068 132.103C0.0510678 132.823 -0.00893219 133.553 0.00106781 134.283C0.241068 143.493 8.15107 149.943 9.96107 151.293L89.9111 212.723C95.8911 217.193 103.181 219.563 110.651 219.473V142.193C106.081 142.143 101.681 140.733 97.6411 137.783V137.773Z",
|
|
30
|
+
fill: "#6e6889"
|
|
31
|
+
}
|
|
32
|
+
),
|
|
33
|
+
/* @__PURE__ */ C(
|
|
34
|
+
"path",
|
|
35
|
+
{
|
|
36
|
+
d: "M206.191 60.1633C206.051 60.0633 205.921 59.9533 205.791 59.8433C203.281 57.7333 153.721 23.9333 124.401 3.97327C120.531 1.31327 115.911 -0.0767307 111.191 0.00326935C106.481 0.0832693 101.911 1.63327 98.1211 4.42327L94.5311 7.11327C88.3111 11.7533 76.7611 20.3533 62.8211 30.2033C46.8411 41.5133 32.1511 51.3533 19.0711 59.1533C13.5211 62.4633 8.38106 71.4133 22.4011 82.3233C23.8811 83.4233 97.6311 137.763 97.6311 137.763C106.101 143.953 116.121 143.403 126.061 137.673C135.741 132.363 170.001 106.893 191.601 89.8933L197.091 85.5533C197.601 85.1433 198.071 84.7433 198.511 84.3533C207.741 76.7733 215.481 66.5433 206.171 60.1533L206.191 60.1633Z",
|
|
37
|
+
fill: "#b0abc8"
|
|
38
|
+
}
|
|
39
|
+
)
|
|
40
|
+
]
|
|
41
|
+
}
|
|
42
|
+
);
|
|
43
|
+
export {
|
|
44
|
+
e as Code4renaLogo
|
|
45
|
+
};
|
package/dist/Logo/index.d.ts
CHANGED
|
@@ -35,3 +35,4 @@ export { GardenLogoMarkDark } from './GardenLogoMarkDark';
|
|
|
35
35
|
export { GardenLogoMarkLight } from './GardenLogoMarkLight';
|
|
36
36
|
export { GardenLogoDark } from './GardenLogoDark';
|
|
37
37
|
export { GardenLogoLight } from './GardenLogoLight';
|
|
38
|
+
export { Code4renaLogo } from './Code4renaLogo';
|
package/dist/Logo/index.js
CHANGED
|
@@ -3,9 +3,9 @@ import { BTCLogo as m } from "./BTCLogo.js";
|
|
|
3
3
|
import { CatalogLogo as p } from "./CatalogLogo.js";
|
|
4
4
|
import { Coinbase as a } from "./Coinbase.js";
|
|
5
5
|
import { EthereumLogo as g } from "./EthereumLogo.js";
|
|
6
|
-
import { GardenExplorer as
|
|
6
|
+
import { GardenExplorer as L } from "./GardenExplorer.js";
|
|
7
7
|
import { GardenFullLogo as G } from "./GardenFullLogo.js";
|
|
8
|
-
import { GardenLogo as
|
|
8
|
+
import { GardenLogo as C } from "./GardenLogo.js";
|
|
9
9
|
import { GardenLogoText as T } from "./GardenLogoText.js";
|
|
10
10
|
import { GardenStrokeIcon as D } from "./GardenStrokeIcon.js";
|
|
11
11
|
import { GMXLogo as I } from "./GMXLogo.js";
|
|
@@ -30,16 +30,18 @@ import { GardenIcon as mo } from "./GardenIcon.js";
|
|
|
30
30
|
import { GardenIconOutline as po } from "./GardenIconOutline.js";
|
|
31
31
|
import { NFTIcon as ao } from "./NFTIcon.js";
|
|
32
32
|
import { GardenExplorerAlt as go } from "./GardenExplorerAlt.js";
|
|
33
|
-
import { GardenDocs as
|
|
33
|
+
import { GardenDocs as lo } from "./GardenDocs.js";
|
|
34
34
|
import { GardenLogoMarkDark as io } from "./GardenLogoMarkDark.js";
|
|
35
|
-
import { GardenLogoMarkLight as
|
|
35
|
+
import { GardenLogoMarkLight as co } from "./GardenLogoMarkLight.js";
|
|
36
36
|
import { GardenLogoDark as ko } from "./GardenLogoDark.js";
|
|
37
37
|
import { GardenLogoLight as uo } from "./GardenLogoLight.js";
|
|
38
|
+
import { Code4renaLogo as ho } from "./Code4renaLogo.js";
|
|
38
39
|
export {
|
|
39
40
|
e as ArbitrumLogo,
|
|
40
41
|
m as BTCLogo,
|
|
41
42
|
q as Camelot,
|
|
42
43
|
p as CatalogLogo,
|
|
44
|
+
ho as Code4renaLogo,
|
|
43
45
|
a as Coinbase,
|
|
44
46
|
v as DLCBTC,
|
|
45
47
|
V as Debridge,
|
|
@@ -47,17 +49,17 @@ export {
|
|
|
47
49
|
g as EthereumLogo,
|
|
48
50
|
H as GMX,
|
|
49
51
|
I as GMXLogo,
|
|
50
|
-
|
|
51
|
-
|
|
52
|
+
lo as GardenDocs,
|
|
53
|
+
L as GardenExplorer,
|
|
52
54
|
go as GardenExplorerAlt,
|
|
53
55
|
G as GardenFullLogo,
|
|
54
56
|
mo as GardenIcon,
|
|
55
57
|
po as GardenIconOutline,
|
|
56
|
-
|
|
58
|
+
C as GardenLogo,
|
|
57
59
|
ko as GardenLogoDark,
|
|
58
60
|
uo as GardenLogoLight,
|
|
59
61
|
io as GardenLogoMarkDark,
|
|
60
|
-
|
|
62
|
+
co as GardenLogoMarkLight,
|
|
61
63
|
T as GardenLogoText,
|
|
62
64
|
D as GardenStrokeIcon,
|
|
63
65
|
ao as NFTIcon,
|