@gearbox-protocol/permissionless-ui 1.22.0-next.16 → 1.22.0-next.18
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/cjs/components/checkbox/checkbox-labeled.cjs +1 -1
- package/dist/cjs/components/client-adapters/index.cjs +1 -1
- package/dist/cjs/components/client-adapters/styled-button/styled-button.cjs +1 -1
- package/dist/cjs/components/client-adapters/styled-dialog-container/index.cjs +1 -0
- package/dist/cjs/components/client-adapters/styled-dialog-container/styled-dialog-container.cjs +1 -0
- package/dist/cjs/components/client-adapters/styled-rounded-image/styled-rounded-image.cjs +1 -1
- package/dist/cjs/components/dialog/dialog-container.cjs +1 -1
- package/dist/cjs/components/dialog/dialog-modal-container.cjs +1 -1
- package/dist/cjs/components/dialog/index.cjs +1 -1
- package/dist/cjs/components/filter/filter-modal.cjs +1 -1
- package/dist/cjs/components/index.cjs +1 -1
- package/dist/cjs/components/modal/index.cjs +1 -0
- package/dist/cjs/components/modal/modal.cjs +1 -0
- package/dist/cjs/components/vertical-list/vertical-list.cjs +1 -1
- package/dist/cjs/index.cjs +1 -1
- package/dist/cjs/utils/z-index.cjs +1 -1
- package/dist/esm/components/checkbox/checkbox-labeled.js +2 -1
- package/dist/esm/components/client-adapters/index.js +4 -2
- package/dist/esm/components/client-adapters/styled-button/styled-button.js +22 -12
- package/dist/esm/components/client-adapters/styled-dialog-container/index.js +4 -0
- package/dist/esm/components/client-adapters/styled-dialog-container/styled-dialog-container.js +39 -0
- package/dist/esm/components/client-adapters/styled-rounded-image/styled-rounded-image.js +2 -1
- package/dist/esm/components/dialog/dialog-container.js +55 -21
- package/dist/esm/components/dialog/dialog-modal-container.js +38 -17
- package/dist/esm/components/dialog/index.js +18 -18
- package/dist/esm/components/filter/filter-modal.js +1 -1
- package/dist/esm/components/index.js +458 -456
- package/dist/esm/components/modal/index.js +4 -0
- package/dist/esm/components/modal/modal.js +108 -0
- package/dist/esm/components/vertical-list/vertical-list.js +27 -27
- package/dist/esm/index.js +596 -594
- package/dist/esm/utils/z-index.js +1 -1
- package/dist/globals.css +1 -1
- package/dist/types/components/client-adapters/index.d.ts +1 -0
- package/dist/types/components/client-adapters/styled-dialog-container/index.d.ts +1 -0
- package/dist/types/components/client-adapters/styled-dialog-container/styled-dialog-container.d.ts +13 -0
- package/dist/types/components/dialog/dialog-container.d.ts +8 -3
- package/dist/types/components/dialog/dialog-modal-container.d.ts +9 -3
- package/dist/types/components/dialog/index.d.ts +1 -1
- package/dist/types/components/index.d.ts +1 -0
- package/dist/types/components/modal/index.d.ts +1 -0
- package/dist/types/components/modal/modal.d.ts +33 -0
- package/dist/types/components/skeleton/skeleton.d.ts +1 -1
- package/dist/types/index.d.ts +1 -0
- package/dist/types/utils/z-index.d.ts +1 -1
- package/package.json +1 -1
- package/src/styles/base.css +9 -2
- package/src/styles/theme.css +19 -0
- package/dist/cjs/components/dialog/dialog-modal.cjs +0 -1
- package/dist/esm/components/dialog/dialog-modal.js +0 -70
- package/dist/types/components/dialog/dialog-modal.d.ts +0 -30
package/dist/esm/components/client-adapters/styled-dialog-container/styled-dialog-container.js
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { jsx as f } from "react/jsx-runtime";
|
|
2
|
+
import * as p from "react";
|
|
3
|
+
import { DialogContainer as d } from "../../dialog/dialog-container.js";
|
|
4
|
+
import { cn as c } from "../../../utils/cn.js";
|
|
5
|
+
import "sonner";
|
|
6
|
+
import "@gearbox-protocol/sdk";
|
|
7
|
+
const g = p.forwardRef(
|
|
8
|
+
({
|
|
9
|
+
$padding: o = "lg",
|
|
10
|
+
$width: r,
|
|
11
|
+
$minWidth: e,
|
|
12
|
+
$maxWidth: t,
|
|
13
|
+
$minHeight: i,
|
|
14
|
+
$colorTheme: a = "box",
|
|
15
|
+
className: m,
|
|
16
|
+
style: l,
|
|
17
|
+
...n
|
|
18
|
+
}, s) => /* @__PURE__ */ f(
|
|
19
|
+
d,
|
|
20
|
+
{
|
|
21
|
+
ref: s,
|
|
22
|
+
padding: o === "none" ? !1 : o === "lg" ? !0 : o,
|
|
23
|
+
colorTheme: a,
|
|
24
|
+
className: c(m),
|
|
25
|
+
...n,
|
|
26
|
+
style: {
|
|
27
|
+
...l,
|
|
28
|
+
width: r || void 0,
|
|
29
|
+
minWidth: e || void 0,
|
|
30
|
+
maxWidth: t || void 0,
|
|
31
|
+
minHeight: i || void 0
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
)
|
|
35
|
+
);
|
|
36
|
+
g.displayName = "StyledDialogContainer";
|
|
37
|
+
export {
|
|
38
|
+
g as StyledDialogContainer
|
|
39
|
+
};
|
|
@@ -32,6 +32,7 @@ import "../../checkbox/checkbox.js";
|
|
|
32
32
|
import "../../checkbox/checkbox-labeled.js";
|
|
33
33
|
import "../../checkbox-item/checkbox-item.js";
|
|
34
34
|
import "../styled-button/styled-button.js";
|
|
35
|
+
import "../styled-dialog-container/styled-dialog-container.js";
|
|
35
36
|
import "../../colored-text/colored-text.js";
|
|
36
37
|
import "../../input/input.js";
|
|
37
38
|
import "react-intl";
|
|
@@ -49,6 +50,7 @@ import "../../dropdown-menu/dropdown-menu-shortcut.js";
|
|
|
49
50
|
import "../../dropdown-menu/dropdown-menu-sub-content.js";
|
|
50
51
|
import "../../dropdown-menu/dropdown-menu-sub-trigger.js";
|
|
51
52
|
import "../../page-title/page-title.js";
|
|
53
|
+
import "../../modal/modal.js";
|
|
52
54
|
import "@radix-ui/react-dialog";
|
|
53
55
|
import "../../dialog/dialog-container.js";
|
|
54
56
|
import "../../dialog/dialog-content.js";
|
|
@@ -56,7 +58,6 @@ import "../../dialog/dialog-description.js";
|
|
|
56
58
|
import "../../dialog/dialog-footer.js";
|
|
57
59
|
import "../../dialog/dialog-header.js";
|
|
58
60
|
import "../../dialog/dialog-title.js";
|
|
59
|
-
import "../../dialog/dialog-modal.js";
|
|
60
61
|
import "../../dialog/dialog-modal-container.js";
|
|
61
62
|
import "../../dialog/dialog-overlay.js";
|
|
62
63
|
import "viem";
|
|
@@ -1,32 +1,66 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import { jsx as n } from "react/jsx-runtime";
|
|
2
|
+
import { cva as s } from "class-variance-authority";
|
|
3
|
+
import * as i from "react";
|
|
4
|
+
import { cn as p } from "../../utils/cn.js";
|
|
4
5
|
import "sonner";
|
|
5
6
|
import "@gearbox-protocol/sdk";
|
|
6
|
-
const x = {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
},
|
|
14
|
-
|
|
7
|
+
const x = s("", {
|
|
8
|
+
variants: {
|
|
9
|
+
padding: {
|
|
10
|
+
md: "p-5",
|
|
11
|
+
xl: "p-10",
|
|
12
|
+
true: "p-4 sm:p-6 lg:p-8",
|
|
13
|
+
false: ""
|
|
14
|
+
},
|
|
15
|
+
colorTheme: {
|
|
16
|
+
box: "bg-card border border-gray-10",
|
|
17
|
+
transparent: "bg-transparent border border-border",
|
|
18
|
+
modal: "bg-modal border border-gray-10 shadow-[0_4px_28px_4px_rgba(0,0,0,0.15)]",
|
|
19
|
+
default: "bg-card border border-border"
|
|
20
|
+
},
|
|
21
|
+
maxWidth: {
|
|
22
|
+
sm: "max-w-screen-sm",
|
|
23
|
+
md: "max-w-screen-md",
|
|
24
|
+
lg: "max-w-screen-lg",
|
|
25
|
+
xl: "max-w-screen-xl",
|
|
26
|
+
"2xl": "max-w-screen-2xl",
|
|
27
|
+
full: "max-w-full"
|
|
28
|
+
},
|
|
29
|
+
sticky: {
|
|
30
|
+
true: "sticky top-5 z-[1]",
|
|
31
|
+
false: ""
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
defaultVariants: {
|
|
35
|
+
padding: !0,
|
|
36
|
+
colorTheme: "default",
|
|
37
|
+
maxWidth: "full"
|
|
38
|
+
}
|
|
39
|
+
}), f = i.forwardRef(
|
|
40
|
+
({
|
|
41
|
+
maxWidth: r = "full",
|
|
42
|
+
padding: a = !0,
|
|
43
|
+
colorTheme: e = "default",
|
|
44
|
+
sticky: o = !1,
|
|
45
|
+
className: d,
|
|
46
|
+
children: l,
|
|
47
|
+
...t
|
|
48
|
+
}, m) => /* @__PURE__ */ n(
|
|
15
49
|
"div",
|
|
16
50
|
{
|
|
17
|
-
ref:
|
|
18
|
-
className:
|
|
19
|
-
"w-full
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
51
|
+
ref: m,
|
|
52
|
+
className: p(
|
|
53
|
+
"w-full",
|
|
54
|
+
"rounded-[10px] md:rounded-2xl",
|
|
55
|
+
x({ padding: a, colorTheme: e, maxWidth: r, sticky: o }),
|
|
56
|
+
d
|
|
23
57
|
),
|
|
24
|
-
...
|
|
58
|
+
...t,
|
|
25
59
|
children: l
|
|
26
60
|
}
|
|
27
61
|
)
|
|
28
62
|
);
|
|
29
|
-
|
|
63
|
+
f.displayName = "DialogContainer";
|
|
30
64
|
export {
|
|
31
|
-
|
|
65
|
+
f as DialogContainer
|
|
32
66
|
};
|
|
@@ -1,26 +1,47 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import { jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import { cva as f } from "class-variance-authority";
|
|
3
|
+
import * as c from "react";
|
|
4
|
+
import { cn as w } from "../../utils/cn.js";
|
|
4
5
|
import "sonner";
|
|
5
6
|
import "@gearbox-protocol/sdk";
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
const
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
7
|
+
import { Modal as g } from "../modal/modal.js";
|
|
8
|
+
import { DialogContainer as h } from "./dialog-container.js";
|
|
9
|
+
const u = f("", {
|
|
10
|
+
variants: {
|
|
11
|
+
width: {
|
|
12
|
+
default: "md:w-[640px]",
|
|
13
|
+
lg: "md:w-[720px]",
|
|
14
|
+
full: "md:w-full"
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
defaultVariants: {
|
|
18
|
+
width: "default"
|
|
19
|
+
}
|
|
20
|
+
}), x = c.forwardRef(({ show: o, onClickOutside: r, modal: i, dialog: l, children: t }, m) => {
|
|
21
|
+
const {
|
|
22
|
+
className: d,
|
|
23
|
+
colorTheme: e = "modal",
|
|
24
|
+
padding: n = "xl",
|
|
25
|
+
width: s,
|
|
26
|
+
...p
|
|
27
|
+
} = l || {};
|
|
28
|
+
return /* @__PURE__ */ a(g, { ...i, show: o, onClickOutside: r, children: /* @__PURE__ */ a(
|
|
29
|
+
h,
|
|
12
30
|
{
|
|
13
|
-
ref:
|
|
14
|
-
className:
|
|
15
|
-
"w-full
|
|
16
|
-
|
|
31
|
+
ref: m,
|
|
32
|
+
className: w(
|
|
33
|
+
"w-full sm:w-[440px] min-h-screen sm:min-h-0",
|
|
34
|
+
u({ width: s }),
|
|
35
|
+
d
|
|
17
36
|
),
|
|
18
|
-
|
|
19
|
-
|
|
37
|
+
colorTheme: e,
|
|
38
|
+
padding: n,
|
|
39
|
+
...p,
|
|
40
|
+
children: t
|
|
20
41
|
}
|
|
21
42
|
) });
|
|
22
43
|
});
|
|
23
|
-
|
|
44
|
+
x.displayName = "DialogModalContainer";
|
|
24
45
|
export {
|
|
25
|
-
|
|
46
|
+
x as DialogModalContainer
|
|
26
47
|
};
|
|
@@ -1,28 +1,28 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
1
|
+
import { Modal as e } from "../modal/modal.js";
|
|
2
|
+
import { Dialog as i, DialogPortal as t, DialogTrigger as l } from "./dialog.js";
|
|
3
|
+
import { DialogContainer as D } from "./dialog-container.js";
|
|
4
|
+
import { DialogContent as p } from "./dialog-content.js";
|
|
5
|
+
import { DialogDescription as x } from "./dialog-description.js";
|
|
6
|
+
import { DialogFooter as d } from "./dialog-footer.js";
|
|
7
|
+
import { DialogForm as F } from "./dialog-form.js";
|
|
8
|
+
import { DialogHeader as O } from "./dialog-header.js";
|
|
9
9
|
import { DialogModalContainer as c } from "./dialog-modal-container.js";
|
|
10
10
|
import { DialogOverlay as v } from "./dialog-overlay.js";
|
|
11
11
|
import { DialogTitle as H } from "./dialog-title.js";
|
|
12
12
|
import { OneFieldDialog as b } from "./one-field-dialog.js";
|
|
13
13
|
export {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
O as DialogModal,
|
|
14
|
+
i as Dialog,
|
|
15
|
+
D as DialogContainer,
|
|
16
|
+
p as DialogContent,
|
|
17
|
+
x as DialogDescription,
|
|
18
|
+
d as DialogFooter,
|
|
19
|
+
F as DialogForm,
|
|
20
|
+
O as DialogHeader,
|
|
22
21
|
c as DialogModalContainer,
|
|
23
22
|
v as DialogOverlay,
|
|
24
|
-
|
|
23
|
+
t as DialogPortal,
|
|
25
24
|
H as DialogTitle,
|
|
26
|
-
|
|
25
|
+
l as DialogTrigger,
|
|
26
|
+
e as Modal,
|
|
27
27
|
b as OneFieldDialog
|
|
28
28
|
};
|
|
@@ -12,6 +12,7 @@ import "@gearbox-protocol/sdk";
|
|
|
12
12
|
import { extractTextFromLabel as R, serializeValue as z } from "../../utils/react.js";
|
|
13
13
|
import "../buttons/tab-button/tab-button.js";
|
|
14
14
|
import { CheckboxItem as F } from "../checkbox-item/checkbox-item.js";
|
|
15
|
+
import "../modal/modal.js";
|
|
15
16
|
import { Dialog as P } from "../dialog/dialog.js";
|
|
16
17
|
import "../dialog/dialog-container.js";
|
|
17
18
|
import { DialogContent as U } from "../dialog/dialog-content.js";
|
|
@@ -19,7 +20,6 @@ import "../dialog/dialog-description.js";
|
|
|
19
20
|
import { DialogFooter as W } from "../dialog/dialog-footer.js";
|
|
20
21
|
import { DialogHeader as X } from "../dialog/dialog-header.js";
|
|
21
22
|
import { DialogTitle as Y } from "../dialog/dialog-title.js";
|
|
22
|
-
import "../dialog/dialog-modal.js";
|
|
23
23
|
import "../dialog/dialog-modal-container.js";
|
|
24
24
|
import "../dialog/dialog-overlay.js";
|
|
25
25
|
import "viem";
|