Skip to content

Commit c9243c8

Browse files
committed
Nebula: Add Move funds page
1 parent 2510c4f commit c9243c8

File tree

7 files changed

+795
-3
lines changed

7 files changed

+795
-3
lines changed

apps/dashboard/src/@/components/ui/decimal-input.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ export function DecimalInput(props: {
55
maxValue?: number;
66
id?: string;
77
className?: string;
8+
placeholder?: string;
89
}) {
910
return (
1011
<Input
@@ -13,6 +14,7 @@ export function DecimalInput(props: {
1314
value={props.value}
1415
className={props.className}
1516
inputMode="decimal"
17+
placeholder={props.placeholder}
1618
onChange={(e) => {
1719
const number = Number(e.target.value);
1820
// ignore if string becomes invalid number
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
"use client";
2+
3+
import { useTheme } from "next-themes";
4+
import { ConnectButton } from "thirdweb/react";
5+
import { inAppWallet } from "thirdweb/wallets";
6+
import { getSDKTheme } from "../../(app)/components/sdk-component-theme";
7+
import { getClientThirdwebClient } from "../../../@/constants/thirdweb-client.client";
8+
import { nebulaAAOptions } from "../login/account-abstraction";
9+
10+
const dashboardClient = getClientThirdwebClient();
11+
12+
const loginOptions = [
13+
inAppWallet({
14+
auth: {
15+
options: [
16+
"google",
17+
"apple",
18+
"facebook",
19+
"github",
20+
"email",
21+
"phone",
22+
"passkey",
23+
],
24+
},
25+
}),
26+
];
27+
28+
export function MoveFundsConnectButton(props: {
29+
btnClassName?: string;
30+
connectLabel?: string;
31+
}) {
32+
const { theme } = useTheme();
33+
34+
return (
35+
<ConnectButton
36+
wallets={loginOptions}
37+
client={dashboardClient}
38+
theme={getSDKTheme(theme === "light" ? "light" : "dark")}
39+
accountAbstraction={nebulaAAOptions}
40+
connectButton={{
41+
className: props.btnClassName,
42+
label: props.connectLabel,
43+
}}
44+
detailsButton={{
45+
className: props.btnClassName,
46+
}}
47+
/>
48+
);
49+
}

0 commit comments

Comments
 (0)