@coinbase/cdp-react 0.0.16 → 0.0.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/components/AuthButton/index.js +1 -1
- package/dist/components/OTP/index.js +4 -4
- package/dist/components/SendTransactionButton/index.js +1 -1
- package/dist/components/ServerError/index.js +4 -4
- package/dist/components/SignIn/SignInForm.js +43 -43
- package/dist/components/SignInModal/index.js +13 -12
- package/dist/components/SignOutButton/index.js +1 -1
- package/dist/index.js +49 -49
- package/package.json +5 -5
|
@@ -13,7 +13,7 @@ import '../../assets/AuthButton.css';const B = "AuthButton-module__loading___JpD
|
|
|
13
13
|
onSignOutSuccess: h,
|
|
14
14
|
...p
|
|
15
15
|
}) => {
|
|
16
|
-
const i = _(), u = v(), [m, s] = c(u), [t, d] = c(!1), [n, r] = c(void 0), o = w(!1), I = () => {
|
|
16
|
+
const { isInitialized: i } = _(), { isSignedIn: u } = v(), [m, s] = c(u), [t, d] = c(!1), [n, r] = c(void 0), o = w(!1), I = () => {
|
|
17
17
|
g?.(), r(S);
|
|
18
18
|
}, O = () => {
|
|
19
19
|
h?.(), s(!1);
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsxs as d, jsx as o } from "react/jsx-runtime";
|
|
2
2
|
import { OneTimePasswordField as _, OneTimePasswordFieldInput as f, OneTimePasswordFieldHiddenInput as P } from "@radix-ui/react-one-time-password-field";
|
|
3
3
|
import { forwardRef as O, useId as T, useRef as h, useEffect as y } from "react";
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
4
|
+
import { Input as I } from "../Input/index.js";
|
|
5
|
+
import { Error as v } from "../Error/index.js";
|
|
6
6
|
import '../../assets/OTP.css';const w = "OTP-module__otp___EUcSo", N = "OTP-module__input___MEBPV", r = {
|
|
7
7
|
otp: w,
|
|
8
8
|
"group-container": "OTP-module__group-container___rfrCo",
|
|
@@ -29,7 +29,7 @@ import '../../assets/OTP.css';const w = "OTP-module__otp___EUcSo", N = "OTP-modu
|
|
|
29
29
|
},
|
|
30
30
|
children: [
|
|
31
31
|
Array.from({ length: s }, (e, t) => /* @__PURE__ */ o("div", { className: r["input-container"], children: /* @__PURE__ */ o(f, { asChild: !0, children: /* @__PURE__ */ o(
|
|
32
|
-
|
|
32
|
+
I,
|
|
33
33
|
{
|
|
34
34
|
name: `${c.name || "otp"}-${t}`,
|
|
35
35
|
ref: (m) => p(m, t),
|
|
@@ -40,7 +40,7 @@ import '../../assets/OTP.css';const w = "OTP-module__otp___EUcSo", N = "OTP-modu
|
|
|
40
40
|
]
|
|
41
41
|
}
|
|
42
42
|
),
|
|
43
|
-
i && /* @__PURE__ */ o(
|
|
43
|
+
i && /* @__PURE__ */ o(v, { id: u, children: i })
|
|
44
44
|
] });
|
|
45
45
|
}
|
|
46
46
|
);
|
|
@@ -19,7 +19,7 @@ import '../../assets/SendTransactionButton.css';const P = {
|
|
|
19
19
|
variant: p = "primary",
|
|
20
20
|
...g
|
|
21
21
|
}) => {
|
|
22
|
-
const [h, c] = _(!1), m = y(), E = v(
|
|
22
|
+
const [h, c] = _(!1), { sendEvmTransaction: m } = y(), E = v(
|
|
23
23
|
async (d) => {
|
|
24
24
|
d.preventDefault(), o?.(d);
|
|
25
25
|
try {
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsx as s } from "react/jsx-runtime";
|
|
2
2
|
import "@coinbase/cdp-hooks";
|
|
3
3
|
import { forwardRef as t } from "react";
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
4
|
+
import { isApiError as p } from "../../utils/isApiError.js";
|
|
5
|
+
import { Error as f } from "../Error/index.js";
|
|
6
6
|
const a = t(
|
|
7
7
|
({ error: r, id: o, className: e = "" }, m) => {
|
|
8
|
-
const i =
|
|
9
|
-
return /* @__PURE__ */ s(
|
|
8
|
+
const i = p(r) ? r.errorMessage : r;
|
|
9
|
+
return /* @__PURE__ */ s(f, { ref: m, id: o, className: e, children: i });
|
|
10
10
|
}
|
|
11
11
|
);
|
|
12
12
|
a.displayName = "ServerError";
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as i, jsx as o, Fragment as A } from "react/jsx-runtime";
|
|
2
2
|
import { useSignInWithEmail as U, useVerifyEmailOTP as V } from "@coinbase/cdp-hooks";
|
|
3
3
|
import { Form as P, FormSubmit as R } from "@radix-ui/react-form";
|
|
4
4
|
import { useState as v, useEffect as y, useRef as B } from "react";
|
|
5
5
|
import { Button as C } from "../Button/index.js";
|
|
6
6
|
import { useAppConfig as k } from "../CDPReactProvider/index.js";
|
|
7
7
|
import { Field as x } from "../Field/index.js";
|
|
8
|
-
import {
|
|
9
|
-
import { OTP as D } from "../OTP/index.js";
|
|
8
|
+
import { OTP as q } from "../OTP/index.js";
|
|
10
9
|
import { ServerError as O } from "../ServerError/index.js";
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import { IconLock as Z } from "../../icons/IconLock.js";
|
|
10
|
+
import { IconCoinbaseWordmark as D } from "../../icons/IconCoinbaseWordmark.js";
|
|
11
|
+
import { IconLock as W } from "../../icons/IconLock.js";
|
|
14
12
|
import { isApiError as T } from "../../utils/isApiError.js";
|
|
15
|
-
import { isEmailInvalid as
|
|
13
|
+
import { isEmailInvalid as Q } from "../../utils/isEmailInvalid.js";
|
|
16
14
|
import { useSignInContext as E } from "./SignInProvider.js";
|
|
17
|
-
import { withValidityState as
|
|
15
|
+
import { withValidityState as Z } from "../Input/index.js";
|
|
16
|
+
import { LoadingSpinner as $ } from "../LoadingSpinner/index.js";
|
|
17
|
+
import { VisuallyHidden as j } from "../VisuallyHidden/index.js";
|
|
18
18
|
import '../../assets/SignInForm.css';const J = "SignInForm-module__form___8Mc3V", G = "SignInForm-module__footer___6Lo9w", H = "SignInForm-module__hr___fOcy4", X = "SignInForm-module__icon___qkJnq", n = {
|
|
19
19
|
"form-wrapper": "SignInForm-module__form-wrapper___SlQkZ",
|
|
20
20
|
form: J,
|
|
@@ -29,8 +29,8 @@ import '../../assets/SignInForm.css';const J = "SignInForm-module__form___8Mc3V"
|
|
|
29
29
|
hr: H,
|
|
30
30
|
icon: X
|
|
31
31
|
}, Y = ({ submit: _ }) => {
|
|
32
|
-
const { state:
|
|
33
|
-
return /* @__PURE__ */
|
|
32
|
+
const { state: s, dispatch: d } = E(), e = () => d({ type: "CLEAR_ERROR" }), u = (p) => (p.preventDefault(), _(s.email));
|
|
33
|
+
return /* @__PURE__ */ i(
|
|
34
34
|
P,
|
|
35
35
|
{
|
|
36
36
|
className: n.form,
|
|
@@ -45,36 +45,36 @@ import '../../assets/SignInForm.css';const J = "SignInForm-module__form___8Mc3V"
|
|
|
45
45
|
validators: [
|
|
46
46
|
["valueMissing", "Email is required"],
|
|
47
47
|
["typeMismatch", "Use a valid email address"],
|
|
48
|
-
[
|
|
48
|
+
[Q, "Use a valid email address"]
|
|
49
49
|
],
|
|
50
|
-
children:
|
|
50
|
+
children: Z({
|
|
51
51
|
autoComplete: "email",
|
|
52
52
|
type: "email",
|
|
53
53
|
placeholder: "name@example.com",
|
|
54
54
|
required: !0,
|
|
55
|
-
value:
|
|
55
|
+
value: s.email,
|
|
56
56
|
onChange: (p) => {
|
|
57
57
|
d({ type: "SET_EMAIL", payload: { email: p.target.value } });
|
|
58
58
|
}
|
|
59
59
|
})
|
|
60
60
|
}
|
|
61
61
|
),
|
|
62
|
-
|
|
63
|
-
/* @__PURE__ */ o(R, { asChild: !0, children: /* @__PURE__ */ o(C, { type: "submit", isPending:
|
|
62
|
+
s.error && /* @__PURE__ */ o(O, { error: s.error, className: n["server-error"] }),
|
|
63
|
+
/* @__PURE__ */ o(R, { asChild: !0, children: /* @__PURE__ */ o(C, { type: "submit", isPending: s.isPending, children: "Continue with email" }) })
|
|
64
64
|
]
|
|
65
65
|
}
|
|
66
66
|
);
|
|
67
67
|
}, z = ({
|
|
68
68
|
reset: _,
|
|
69
|
-
resetCountdown:
|
|
69
|
+
resetCountdown: s,
|
|
70
70
|
submit: d
|
|
71
71
|
}) => {
|
|
72
|
-
const { state: e, dispatch: u } = E(), p = () => u({ type: "CLEAR_ERROR" }), l = B([]), f = (c) => (c.preventDefault(), d(e.otp)),
|
|
72
|
+
const { state: e, dispatch: u } = E(), p = () => u({ type: "CLEAR_ERROR" }), l = B([]), f = (c) => (c.preventDefault(), d(e.otp)), h = () => {
|
|
73
73
|
_(), l.current[0]?.focus();
|
|
74
74
|
};
|
|
75
75
|
return y(() => {
|
|
76
76
|
e.step === "otp" && l.current[0]?.focus();
|
|
77
|
-
}, [e.step]), /* @__PURE__ */
|
|
77
|
+
}, [e.step]), /* @__PURE__ */ i(
|
|
78
78
|
P,
|
|
79
79
|
{
|
|
80
80
|
className: `${n.form}`,
|
|
@@ -82,7 +82,7 @@ import '../../assets/SignInForm.css';const J = "SignInForm-module__form___8Mc3V"
|
|
|
82
82
|
onSubmit: f,
|
|
83
83
|
children: [
|
|
84
84
|
/* @__PURE__ */ o(
|
|
85
|
-
|
|
85
|
+
q,
|
|
86
86
|
{
|
|
87
87
|
ref: l,
|
|
88
88
|
name: "otp",
|
|
@@ -96,32 +96,32 @@ import '../../assets/SignInForm.css';const J = "SignInForm-module__form___8Mc3V"
|
|
|
96
96
|
autoSubmit: !0
|
|
97
97
|
}
|
|
98
98
|
),
|
|
99
|
-
/* @__PURE__ */
|
|
100
|
-
(e.isPending && !e.canResetOTP || e.error) && /* @__PURE__ */
|
|
101
|
-
e.isPending && !e.canResetOTP && /* @__PURE__ */ o(
|
|
99
|
+
/* @__PURE__ */ i("div", { className: n["form-footer"], children: [
|
|
100
|
+
(e.isPending && !e.canResetOTP || e.error) && /* @__PURE__ */ i("div", { className: n["server-state-wrapper"], children: [
|
|
101
|
+
e.isPending && !e.canResetOTP && /* @__PURE__ */ o($, { className: n["loading-spinner"] }),
|
|
102
102
|
e.error && /* @__PURE__ */ o(O, { error: e.error, className: n["server-error"] })
|
|
103
103
|
] }),
|
|
104
|
-
/* @__PURE__ */
|
|
104
|
+
/* @__PURE__ */ i("div", { className: n["resend-wrapper"], children: [
|
|
105
105
|
e.canResetOTP && /* @__PURE__ */ o(R, { asChild: !0, children: /* @__PURE__ */ o(
|
|
106
106
|
C,
|
|
107
107
|
{
|
|
108
108
|
type: "button",
|
|
109
|
-
onClick:
|
|
109
|
+
onClick: h,
|
|
110
110
|
isPending: e.isPending,
|
|
111
111
|
variant: "linkPrimary",
|
|
112
112
|
children: "Resend code"
|
|
113
113
|
}
|
|
114
114
|
) }),
|
|
115
|
-
!e.canResetOTP && /* @__PURE__ */ o("div", { className: n["reset-timer"], children: /* @__PURE__ */
|
|
115
|
+
!e.canResetOTP && /* @__PURE__ */ o("div", { className: n["reset-timer"], children: /* @__PURE__ */ i("p", { children: [
|
|
116
116
|
"Resend code in ",
|
|
117
|
-
/* @__PURE__ */
|
|
118
|
-
|
|
117
|
+
/* @__PURE__ */ i("span", { "aria-hidden": "true", children: [
|
|
118
|
+
s,
|
|
119
119
|
"s"
|
|
120
120
|
] }),
|
|
121
|
-
/* @__PURE__ */
|
|
122
|
-
|
|
121
|
+
/* @__PURE__ */ i(j, { children: [
|
|
122
|
+
s,
|
|
123
123
|
" ",
|
|
124
|
-
|
|
124
|
+
s === 1 ? "second" : "seconds"
|
|
125
125
|
] })
|
|
126
126
|
] }) })
|
|
127
127
|
] })
|
|
@@ -129,20 +129,20 @@ import '../../assets/SignInForm.css';const J = "SignInForm-module__form___8Mc3V"
|
|
|
129
129
|
]
|
|
130
130
|
}
|
|
131
131
|
);
|
|
132
|
-
},
|
|
132
|
+
}, he = ({
|
|
133
133
|
as: _ = "div",
|
|
134
|
-
className:
|
|
134
|
+
className: s = "",
|
|
135
135
|
onSuccess: d,
|
|
136
136
|
...e
|
|
137
137
|
}) => {
|
|
138
|
-
const l = "An error occurred while signing in. Please try again.", [f,
|
|
139
|
-
|
|
138
|
+
const l = "An error occurred while signing in. Please try again.", [f, h] = v(0), [c, S] = v(!1), { signInWithEmail: w } = U(), { verifyEmailOTP: b } = V(), { state: a, dispatch: m } = E(), { showCoinbaseFooter: F } = k(), L = (t) => {
|
|
139
|
+
h(t), S(!0);
|
|
140
140
|
};
|
|
141
141
|
y(() => {
|
|
142
142
|
if (!c)
|
|
143
143
|
return;
|
|
144
144
|
const t = setInterval(() => {
|
|
145
|
-
|
|
145
|
+
h((r) => r > 1 ? r - 1 : (S(!1), 0));
|
|
146
146
|
}, 1e3);
|
|
147
147
|
return () => clearInterval(t);
|
|
148
148
|
}, [c]), y(() => {
|
|
@@ -179,24 +179,24 @@ import '../../assets/SignInForm.css';const J = "SignInForm-module__form___8Mc3V"
|
|
|
179
179
|
}
|
|
180
180
|
}
|
|
181
181
|
}, N = () => {
|
|
182
|
-
m({ type: "RESET_OTP" }),
|
|
182
|
+
m({ type: "RESET_OTP" }), S(!1), I(a.email);
|
|
183
183
|
};
|
|
184
|
-
return /* @__PURE__ */
|
|
184
|
+
return /* @__PURE__ */ i(_, { className: `${n["form-wrapper"]} ${s}`, ...e, children: [
|
|
185
185
|
a.step === "email" && /* @__PURE__ */ o(Y, { submit: I }),
|
|
186
186
|
a.step === "otp" && /* @__PURE__ */ o(z, { submit: M, reset: N, resetCountdown: f }),
|
|
187
|
-
F && /* @__PURE__ */
|
|
187
|
+
F && /* @__PURE__ */ i(A, { children: [
|
|
188
188
|
/* @__PURE__ */ o("hr", { className: n.hr }),
|
|
189
|
-
/* @__PURE__ */
|
|
190
|
-
/* @__PURE__ */ o(
|
|
191
|
-
/* @__PURE__ */
|
|
189
|
+
/* @__PURE__ */ i("div", { className: n.footer, children: [
|
|
190
|
+
/* @__PURE__ */ o(W, { className: n.icon }),
|
|
191
|
+
/* @__PURE__ */ i("p", { children: [
|
|
192
192
|
"Secured by",
|
|
193
193
|
" ",
|
|
194
|
-
/* @__PURE__ */ o(
|
|
194
|
+
/* @__PURE__ */ o(D, { className: n["coinbase-icon"], "aria-label": "Coinbase" })
|
|
195
195
|
] })
|
|
196
196
|
] })
|
|
197
197
|
] })
|
|
198
198
|
] });
|
|
199
199
|
};
|
|
200
200
|
export {
|
|
201
|
-
|
|
201
|
+
he as SignInForm
|
|
202
202
|
};
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import { jsxs as o, jsx as i } from "react/jsx-runtime";
|
|
2
|
-
import { Dialog as
|
|
2
|
+
import { Dialog as m, DialogTrigger as g, DialogPortal as _, DialogOverlay as d, DialogContent as c, DialogClose as p, DialogTitle as I, DialogDescription as u } from "@radix-ui/react-dialog";
|
|
3
3
|
import "react";
|
|
4
4
|
import { IconXMark as h } from "../../icons/IconXMark.js";
|
|
5
|
-
import { Button as
|
|
6
|
-
import {
|
|
7
|
-
import
|
|
5
|
+
import { Button as e } from "../Button/index.js";
|
|
6
|
+
import { SignIn as S } from "../SignIn/index.js";
|
|
7
|
+
import "@coinbase/cdp-hooks";
|
|
8
|
+
import { useTheme as f } from "../ThemeProvider/index.js";
|
|
8
9
|
import { SignInImage as M } from "../SignIn/SignInImage.js";
|
|
9
10
|
import { SignInTitle as D } from "../SignIn/SignInTitle.js";
|
|
10
11
|
import { SignInDescription as v } from "../SignIn/SignInDescription.js";
|
|
@@ -20,15 +21,15 @@ import '../../assets/SignInModal.css';const y = "SignInModal-module__trigger___I
|
|
|
20
21
|
"close-button": "SignInModal-module__close-button___k1I5Q",
|
|
21
22
|
overlay: x,
|
|
22
23
|
spacer: b
|
|
23
|
-
},
|
|
24
|
-
const { cssVariables: t } =
|
|
25
|
-
return /* @__PURE__ */ o(
|
|
26
|
-
/* @__PURE__ */ i(
|
|
24
|
+
}, H = ({ children: l, open: a, setIsOpen: s, onSuccess: r }) => {
|
|
25
|
+
const { cssVariables: t } = f();
|
|
26
|
+
return /* @__PURE__ */ o(m, { open: a, onOpenChange: s, children: [
|
|
27
|
+
/* @__PURE__ */ i(g, { asChild: !0, children: l || /* @__PURE__ */ i(e, { variant: "primary", className: n.trigger, children: "Sign In" }) }),
|
|
27
28
|
/* @__PURE__ */ i(_, { children: /* @__PURE__ */ o(d, { className: n.overlay, style: t, children: [
|
|
28
29
|
/* @__PURE__ */ i("div", { className: n.spacer }),
|
|
29
|
-
/* @__PURE__ */ i(c, { className: n.modal, children: /* @__PURE__ */ o(
|
|
30
|
+
/* @__PURE__ */ i(c, { className: n.modal, children: /* @__PURE__ */ o(S, { onSuccess: r, className: n["sign-in"], children: [
|
|
30
31
|
/* @__PURE__ */ i(p, { asChild: !0, children: /* @__PURE__ */ i(
|
|
31
|
-
|
|
32
|
+
e,
|
|
32
33
|
{
|
|
33
34
|
"aria-label": "Close",
|
|
34
35
|
variant: "transparentSecondary",
|
|
@@ -39,11 +40,11 @@ import '../../assets/SignInModal.css';const y = "SignInModal-module__trigger___I
|
|
|
39
40
|
/* @__PURE__ */ i("div", { className: n["sign-in-image"], children: /* @__PURE__ */ i(M, {}) }),
|
|
40
41
|
/* @__PURE__ */ i("div", { className: n["sign-in-title"], children: /* @__PURE__ */ i(I, { asChild: !0, children: /* @__PURE__ */ i(D, {}) }) }),
|
|
41
42
|
/* @__PURE__ */ i(u, { asChild: !0, children: /* @__PURE__ */ i(v, { className: n["sign-in-description"] }) }),
|
|
42
|
-
/* @__PURE__ */ i(N, { className: n["sign-in-form"], onSuccess:
|
|
43
|
+
/* @__PURE__ */ i(N, { className: n["sign-in-form"], onSuccess: r })
|
|
43
44
|
] }) })
|
|
44
45
|
] }) })
|
|
45
46
|
] });
|
|
46
47
|
};
|
|
47
48
|
export {
|
|
48
|
-
|
|
49
|
+
H as SignInModal
|
|
49
50
|
};
|
|
@@ -6,7 +6,7 @@ import "../../theme/theme.js";
|
|
|
6
6
|
import '../../assets/SignOutButton.css';const e = {
|
|
7
7
|
"sign-out-button": "SignOutButton-module__sign-out-button___qiybe"
|
|
8
8
|
}, O = ({ children: t, variant: o = "primary", onSuccess: n }) => {
|
|
9
|
-
const i = r(), u = async () => {
|
|
9
|
+
const { signOut: i } = r(), u = async () => {
|
|
10
10
|
await i(), n?.();
|
|
11
11
|
};
|
|
12
12
|
return /* @__PURE__ */ s(m, { variant: o, className: e["sign-out-button"], onClick: u, children: t || "Sign out" });
|
package/dist/index.js
CHANGED
|
@@ -1,58 +1,58 @@
|
|
|
1
1
|
import { CDPReactProvider as e, useAppConfig as t } from "./components/CDPReactProvider/index.js";
|
|
2
2
|
import { AuthButton as m } from "./components/AuthButton/index.js";
|
|
3
3
|
import { SendTransactionButton as f } from "./components/SendTransactionButton/index.js";
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
4
|
+
import { SignIn as x } from "./components/SignIn/index.js";
|
|
5
|
+
import { useSignInReducer as c } from "./components/SignIn/useSignInReducer.js";
|
|
6
|
+
import { SignOutButton as l } from "./components/SignOutButton/index.js";
|
|
7
|
+
import { SignInModal as g } from "./components/SignInModal/index.js";
|
|
8
|
+
import { ThemeProvider as u, useTheme as C } from "./components/ThemeProvider/index.js";
|
|
9
|
+
import { cssVariables as h } from "./theme/cssVariables.js";
|
|
10
|
+
import { theme as T } from "./theme/theme.js";
|
|
11
|
+
import { colors as E, colorsBase as b, colorsComponents as v, colorsSemantic as A, font as M, tokens as P } from "./theme/tokens.js";
|
|
12
|
+
import { flattenTokensObject as F, themeToCssVariables as O } from "./theme/utils.js";
|
|
13
|
+
import { IconCheckCircle as V } from "./icons/IconCheckCircle.js";
|
|
14
|
+
import { IconExclamationCircle as w } from "./icons/IconExclamationCircle.js";
|
|
15
|
+
import { IconLock as U } from "./icons/IconLock.js";
|
|
16
|
+
import { IconXMark as q } from "./icons/IconXMark.js";
|
|
17
|
+
import { getMessageFromUnknownError as z } from "./utils/getMessageFromUnknownError.js";
|
|
18
|
+
import { isApiError as H } from "./utils/isApiError.js";
|
|
19
|
+
import { isEmailInvalid as K } from "./utils/isEmailInvalid.js";
|
|
20
|
+
import { SignInDescription as Q } from "./components/SignIn/SignInDescription.js";
|
|
21
|
+
import { SignInForm as Y } from "./components/SignIn/SignInForm.js";
|
|
22
|
+
import { SignInImage as _ } from "./components/SignIn/SignInImage.js";
|
|
23
|
+
import { SignInTitle as oo } from "./components/SignIn/SignInTitle.js";
|
|
24
|
+
import { useSignInContext as eo } from "./components/SignIn/SignInProvider.js";
|
|
25
25
|
export {
|
|
26
26
|
m as AuthButton,
|
|
27
27
|
e as CDPReactProvider,
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
28
|
+
V as IconCheckCircle,
|
|
29
|
+
w as IconExclamationCircle,
|
|
30
|
+
U as IconLock,
|
|
31
|
+
q as IconXMark,
|
|
32
32
|
f as SendTransactionButton,
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
33
|
+
x as SignIn,
|
|
34
|
+
Q as SignInDescription,
|
|
35
|
+
Y as SignInForm,
|
|
36
|
+
_ as SignInImage,
|
|
37
|
+
g as SignInModal,
|
|
38
|
+
oo as SignInTitle,
|
|
39
|
+
l as SignOutButton,
|
|
40
|
+
u as ThemeProvider,
|
|
41
|
+
E as colors,
|
|
42
|
+
b as colorsBase,
|
|
43
|
+
v as colorsComponents,
|
|
44
|
+
A as colorsSemantic,
|
|
45
|
+
h as cssVariables,
|
|
46
|
+
F as flattenTokensObject,
|
|
47
|
+
M as font,
|
|
48
|
+
z as getMessageFromUnknownError,
|
|
49
|
+
H as isApiError,
|
|
50
|
+
K as isEmailInvalid,
|
|
51
|
+
T as theme,
|
|
52
|
+
O as themeToCssVariables,
|
|
53
|
+
P as tokens,
|
|
54
54
|
t as useAppConfig,
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
55
|
+
eo as useSignInContext,
|
|
56
|
+
c as useSignInReducer,
|
|
57
|
+
C as useTheme
|
|
58
58
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@coinbase/cdp-react",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.18",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"dependencies": {
|
|
6
6
|
"@radix-ui/react-dialog": "^1.1.14",
|
|
@@ -9,8 +9,8 @@
|
|
|
9
9
|
},
|
|
10
10
|
"peerDependencies": {
|
|
11
11
|
"react": ">=18.2.0",
|
|
12
|
-
"@coinbase/cdp-core": "^0.0.
|
|
13
|
-
"@coinbase/cdp-hooks": "^0.0.
|
|
12
|
+
"@coinbase/cdp-core": "^0.0.18",
|
|
13
|
+
"@coinbase/cdp-hooks": "^0.0.18"
|
|
14
14
|
},
|
|
15
15
|
"devDependencies": {
|
|
16
16
|
"@size-limit/preset-big-lib": "^11.2.0",
|
|
@@ -38,8 +38,8 @@
|
|
|
38
38
|
"vite": "^7.0.4",
|
|
39
39
|
"vite-plugin-dts": "^4.5.4",
|
|
40
40
|
"vite-plugin-lib-inject-css": "^2.2.2",
|
|
41
|
-
"@coinbase/cdp-core": "^0.0.
|
|
42
|
-
"@coinbase/cdp-hooks": "^0.0.
|
|
41
|
+
"@coinbase/cdp-core": "^0.0.18",
|
|
42
|
+
"@coinbase/cdp-hooks": "^0.0.18"
|
|
43
43
|
},
|
|
44
44
|
"size-limit": [
|
|
45
45
|
{
|