create-stylus 0.1.3 → 0.1.5
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/cli.js +33 -0
- package/dist/cli.js.map +1 -1
- package/package.json +11 -2
- package/src/extensions.json +6 -0
- package/src/main.ts +11 -0
- package/src/tasks/config-to-sepolia.ts +25 -0
- package/src/tasks/index.ts +1 -0
- package/templates/base/package.json +10 -1
- package/templates/base/packages/nextjs/app/debug/_components/DebugContracts.tsx +15 -5
- package/templates/base/packages/nextjs/app/debug/_components/contract/ContractInput.tsx +3 -3
- package/templates/base/packages/nextjs/app/debug/_components/contract/ContractUI.tsx +103 -27
- package/templates/base/packages/nextjs/app/debug/_components/contract/DisplayVariable.tsx +15 -2
- package/templates/base/packages/nextjs/app/debug/_components/contract/ReadOnlyFunctionForm.tsx +11 -4
- package/templates/base/packages/nextjs/app/debug/_components/contract/TxReceipt.tsx +37 -21
- package/templates/base/packages/nextjs/app/debug/_components/contract/WriteOnlyFunctionForm.tsx +18 -16
- package/templates/base/packages/nextjs/app/layout.tsx +10 -4
- package/templates/base/packages/nextjs/components/AngularBorder.tsx +41 -0
- package/templates/base/packages/nextjs/components/Footer.tsx +153 -44
- package/templates/base/packages/nextjs/components/Header.tsx +73 -10
- package/templates/base/packages/nextjs/components/SwitchTheme.tsx +34 -3
- package/templates/base/packages/nextjs/components/scaffold-eth/Faucet.tsx +40 -5
- package/templates/base/packages/nextjs/components/scaffold-eth/Input/InputBase.tsx +1 -1
- package/templates/base/packages/nextjs/components/scaffold-eth/Input/IntegerInput.tsx +35 -25
- package/templates/base/packages/nextjs/components/scaffold-eth/RainbowKitCustomConnectButton/AngularWalletAddress.tsx +223 -0
- package/templates/base/packages/nextjs/components/scaffold-eth/RainbowKitCustomConnectButton/index.tsx +2 -1
- package/templates/base/packages/nextjs/icons/EthIcon.tsx +28 -0
- package/templates/base/packages/nextjs/package.json +9 -0
- package/templates/base/packages/nextjs/public/logo.svg +20 -7
- package/templates/base/packages/nextjs/styles/globals.css +333 -2
- package/templates/base/packages/nextjs/tailwind.config.js +3 -2
- package/templates/base/packages/nextjs/utils/scaffold-stylus/supportedChains.ts +1 -1
- package/templates/base/packages/stylus/package.json +9 -0
- package/templates/base/packages/stylus/scripts/deploy_contract.ts +1 -0
- package/templates/base/packages/stylus/scripts/test_network.ts +6 -7
- package/templates/base/packages/stylus/scripts/utils/contract.ts +6 -2
- package/templates/base/packages/stylus/scripts/utils/deployment.ts +1 -0
- package/templates/base/packages/stylus/scripts/utils/network.ts +23 -5
- package/templates/base/yarn.lock +837 -849
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
|
-
import { useEffect, useState } from "react";
|
|
3
|
+
import { useEffect, useState, useMemo } from "react";
|
|
4
4
|
import { Address as AddressType, createWalletClient, http, parseEther } from "viem";
|
|
5
5
|
import { privateKeyToAccount } from "viem/accounts";
|
|
6
6
|
import { useAccount } from "wagmi";
|
|
7
|
+
import { useTheme } from "next-themes";
|
|
7
8
|
import { BanknotesIcon } from "@heroicons/react/24/outline";
|
|
9
|
+
import { AngularBorder } from "~~/components/AngularBorder";
|
|
8
10
|
import { Address, AddressInput, Balance, EtherInput } from "~~/components/scaffold-eth";
|
|
9
11
|
import { useTransactor } from "~~/hooks/scaffold-eth";
|
|
10
12
|
import { notification } from "~~/utils/scaffold-eth";
|
|
@@ -29,6 +31,11 @@ export const Faucet = () => {
|
|
|
29
31
|
const [sendValue, setSendValue] = useState("");
|
|
30
32
|
|
|
31
33
|
const { chain: ConnectedChain } = useAccount();
|
|
34
|
+
const { resolvedTheme } = useTheme();
|
|
35
|
+
|
|
36
|
+
const isDarkMode = useMemo(() => {
|
|
37
|
+
return resolvedTheme === "dark";
|
|
38
|
+
}, [resolvedTheme]);
|
|
32
39
|
|
|
33
40
|
const faucetTxn = useTransactor(localWalletClient);
|
|
34
41
|
|
|
@@ -83,10 +90,38 @@ export const Faucet = () => {
|
|
|
83
90
|
|
|
84
91
|
return (
|
|
85
92
|
<div>
|
|
86
|
-
<
|
|
87
|
-
<
|
|
88
|
-
<
|
|
89
|
-
|
|
93
|
+
<div className="relative">
|
|
94
|
+
<AngularBorder width={130} height={40} color="rgba(227, 6, 110, 1)" />
|
|
95
|
+
<label
|
|
96
|
+
htmlFor="faucet-modal"
|
|
97
|
+
className="flex items-center gap-2 px-4 py-2 cursor-pointer rounded-lg"
|
|
98
|
+
style={{
|
|
99
|
+
width: "130px",
|
|
100
|
+
height: "40px",
|
|
101
|
+
display: "flex",
|
|
102
|
+
alignItems: "flex-start",
|
|
103
|
+
paddingTop: "8px",
|
|
104
|
+
position: "relative",
|
|
105
|
+
zIndex: 1,
|
|
106
|
+
}}
|
|
107
|
+
>
|
|
108
|
+
<BanknotesIcon className="h-4 w-4" style={{ color: "rgba(227, 6, 110, 1)" }} />
|
|
109
|
+
<span
|
|
110
|
+
style={{
|
|
111
|
+
color: isDarkMode ? "#FFF" : "black",
|
|
112
|
+
fontFamily: "Orbitron, sans-serif",
|
|
113
|
+
fontSize: "14px",
|
|
114
|
+
fontWeight: 700,
|
|
115
|
+
textTransform: "uppercase",
|
|
116
|
+
whiteSpace: "nowrap",
|
|
117
|
+
overflow: "hidden",
|
|
118
|
+
textOverflow: "ellipsis",
|
|
119
|
+
}}
|
|
120
|
+
>
|
|
121
|
+
Faucet
|
|
122
|
+
</span>
|
|
123
|
+
</label>
|
|
124
|
+
</div>
|
|
90
125
|
<input type="checkbox" id="faucet-modal" className="modal-toggle" />
|
|
91
126
|
<label htmlFor="faucet-modal" className="modal cursor-pointer">
|
|
92
127
|
<label className="modal-box relative">
|
|
@@ -47,7 +47,7 @@ export const InputBase = <T extends { toString: () => string } | undefined = str
|
|
|
47
47
|
}, [reFocus]);
|
|
48
48
|
|
|
49
49
|
return (
|
|
50
|
-
<div className={`flex
|
|
50
|
+
<div className={`flex text-accent ${modifier}`}>
|
|
51
51
|
{prefix}
|
|
52
52
|
<input
|
|
53
53
|
className="input input-ghost focus-within:border-transparent focus:outline-hidden focus:bg-transparent h-[2.2rem] min-h-[2.2rem] px-4 border w-full font-medium placeholder:text-accent/70 text-base-content/70 focus:text-base-content/70"
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { useCallback, useEffect, useState } from "react";
|
|
2
2
|
import { parseEther } from "viem";
|
|
3
|
+
import { useTheme } from "next-themes";
|
|
3
4
|
import { CommonInputProps, InputBase, IntegerVariant, isValidInteger } from "~~/components/scaffold-eth";
|
|
4
5
|
|
|
5
6
|
type IntegerInputProps = CommonInputProps<string> & {
|
|
@@ -16,6 +17,8 @@ export const IntegerInput = ({
|
|
|
16
17
|
variant = IntegerVariant.UINT256,
|
|
17
18
|
disableMultiplyBy1e18 = false,
|
|
18
19
|
}: IntegerInputProps) => {
|
|
20
|
+
const { resolvedTheme } = useTheme();
|
|
21
|
+
const isDarkMode = resolvedTheme === "dark";
|
|
19
22
|
const [inputError, setInputError] = useState(false);
|
|
20
23
|
const multiplyBy1e18 = useCallback(() => {
|
|
21
24
|
if (!value) {
|
|
@@ -33,31 +36,38 @@ export const IntegerInput = ({
|
|
|
33
36
|
}, [value, variant]);
|
|
34
37
|
|
|
35
38
|
return (
|
|
36
|
-
<
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
39
|
+
<div
|
|
40
|
+
className="integer-input-wrapper input-container"
|
|
41
|
+
style={{
|
|
42
|
+
padding: "12px 16px",
|
|
43
|
+
}}
|
|
44
|
+
>
|
|
45
|
+
<InputBase
|
|
46
|
+
name={name}
|
|
47
|
+
value={value}
|
|
48
|
+
placeholder={placeholder}
|
|
49
|
+
error={inputError}
|
|
50
|
+
onChange={onChange}
|
|
51
|
+
disabled={disabled}
|
|
52
|
+
suffix={
|
|
53
|
+
!inputError &&
|
|
54
|
+
!disableMultiplyBy1e18 && (
|
|
55
|
+
<div
|
|
56
|
+
className="space-x-4 flex tooltip tooltip-top tooltip-secondary before:content-[attr(data-tip)] before:right-[-10px] before:left-auto before:transform-none"
|
|
57
|
+
data-tip="Multiply by 1e18 (wei)"
|
|
55
58
|
>
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
59
|
+
<button
|
|
60
|
+
className={`${disabled ? "cursor-not-allowed" : "cursor-pointer"} font-semibold px-4 text-accent`}
|
|
61
|
+
onClick={multiplyBy1e18}
|
|
62
|
+
disabled={disabled}
|
|
63
|
+
type="button"
|
|
64
|
+
>
|
|
65
|
+
∗
|
|
66
|
+
</button>
|
|
67
|
+
</div>
|
|
68
|
+
)
|
|
69
|
+
}
|
|
70
|
+
/>
|
|
71
|
+
</div>
|
|
62
72
|
);
|
|
63
73
|
};
|
|
@@ -0,0 +1,223 @@
|
|
|
1
|
+
import { useRef, useState } from "react";
|
|
2
|
+
import { getAddress } from "viem";
|
|
3
|
+
import { Address } from "viem";
|
|
4
|
+
import { useDisconnect } from "wagmi";
|
|
5
|
+
import {
|
|
6
|
+
ArrowLeftEndOnRectangleIcon,
|
|
7
|
+
ArrowsRightLeftIcon,
|
|
8
|
+
CheckCircleIcon,
|
|
9
|
+
ChevronDownIcon,
|
|
10
|
+
DocumentDuplicateIcon,
|
|
11
|
+
QrCodeIcon,
|
|
12
|
+
UserCircleIcon,
|
|
13
|
+
} from "@heroicons/react/24/outline";
|
|
14
|
+
import { BlockieAvatar, isENS } from "~~/components/scaffold-eth";
|
|
15
|
+
import { useCopyToClipboard, useOutsideClick } from "~~/hooks/scaffold-eth";
|
|
16
|
+
import { getTargetNetworks } from "~~/utils/scaffold-stylus";
|
|
17
|
+
import { arbitrumNitro } from "~~/utils/scaffold-stylus/supportedChains";
|
|
18
|
+
import { useTheme } from "next-themes";
|
|
19
|
+
|
|
20
|
+
const allowedNetworks = getTargetNetworks();
|
|
21
|
+
|
|
22
|
+
type AngularWalletAddressProps = {
|
|
23
|
+
address: Address;
|
|
24
|
+
displayName: string;
|
|
25
|
+
ensAvatar?: string;
|
|
26
|
+
onSwitchAccount: () => void;
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
export const AngularWalletAddress = ({
|
|
30
|
+
address,
|
|
31
|
+
ensAvatar,
|
|
32
|
+
displayName,
|
|
33
|
+
onSwitchAccount,
|
|
34
|
+
}: AngularWalletAddressProps) => {
|
|
35
|
+
const { disconnect } = useDisconnect();
|
|
36
|
+
const checkSumAddress = getAddress(address);
|
|
37
|
+
const { resolvedTheme } = useTheme();
|
|
38
|
+
const isDarkMode = resolvedTheme === "dark";
|
|
39
|
+
|
|
40
|
+
const { copyToClipboard: copyAddressToClipboard, isCopiedToClipboard: isAddressCopiedToClipboard } =
|
|
41
|
+
useCopyToClipboard();
|
|
42
|
+
const [selectingNetwork, setSelectingNetwork] = useState(false);
|
|
43
|
+
const dropdownRef = useRef<HTMLDetailsElement>(null);
|
|
44
|
+
|
|
45
|
+
const closeDropdown = () => {
|
|
46
|
+
setSelectingNetwork(false);
|
|
47
|
+
dropdownRef.current?.removeAttribute("open");
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
useOutsideClick(dropdownRef, closeDropdown);
|
|
51
|
+
|
|
52
|
+
return (
|
|
53
|
+
<>
|
|
54
|
+
<details ref={dropdownRef} className="dropdown dropdown-end leading-3">
|
|
55
|
+
<summary
|
|
56
|
+
tabIndex={0}
|
|
57
|
+
className="dropdown-toggle gap-0 !h-auto"
|
|
58
|
+
style={{
|
|
59
|
+
position: "relative",
|
|
60
|
+
width: "220px",
|
|
61
|
+
height: "46px",
|
|
62
|
+
display: "flex",
|
|
63
|
+
alignItems: "center",
|
|
64
|
+
padding: "0 20px",
|
|
65
|
+
cursor: "pointer",
|
|
66
|
+
alignSelf: "center",
|
|
67
|
+
}}
|
|
68
|
+
>
|
|
69
|
+
{/* Angular border SVG */}
|
|
70
|
+
<svg
|
|
71
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
72
|
+
width="220"
|
|
73
|
+
height="46"
|
|
74
|
+
viewBox="0 0 220 46"
|
|
75
|
+
fill="none"
|
|
76
|
+
style={{
|
|
77
|
+
position: "absolute",
|
|
78
|
+
top: "-7px",
|
|
79
|
+
left: 0,
|
|
80
|
+
pointerEvents: "none",
|
|
81
|
+
}}
|
|
82
|
+
>
|
|
83
|
+
<path
|
|
84
|
+
d="M196.132 0.5L219.5 23.2109V45.5H24.0811L0.5 22.7871V0.5H196.132Z"
|
|
85
|
+
stroke="#30B4ED"
|
|
86
|
+
strokeWidth="1"
|
|
87
|
+
/>
|
|
88
|
+
</svg>
|
|
89
|
+
|
|
90
|
+
{/* Content */}
|
|
91
|
+
<div
|
|
92
|
+
style={{
|
|
93
|
+
display: "flex",
|
|
94
|
+
alignItems: "center",
|
|
95
|
+
gap: "8px",
|
|
96
|
+
width: "100%",
|
|
97
|
+
height: "100%",
|
|
98
|
+
zIndex: 1,
|
|
99
|
+
position: "relative",
|
|
100
|
+
}}
|
|
101
|
+
>
|
|
102
|
+
<BlockieAvatar address={checkSumAddress} size={30} ensImage={ensAvatar} />
|
|
103
|
+
<span
|
|
104
|
+
style={{
|
|
105
|
+
color: isDarkMode ? "#FFF" : "black",
|
|
106
|
+
fontFamily: "Orbitron, sans-serif",
|
|
107
|
+
fontSize: "14px",
|
|
108
|
+
fontWeight: 700,
|
|
109
|
+
lineHeight: "1",
|
|
110
|
+
textTransform: "uppercase",
|
|
111
|
+
display: "flex",
|
|
112
|
+
alignItems: "center",
|
|
113
|
+
height: "30px",
|
|
114
|
+
whiteSpace: "nowrap",
|
|
115
|
+
minWidth: 0,
|
|
116
|
+
}}
|
|
117
|
+
>
|
|
118
|
+
{isENS(displayName) ? displayName : checkSumAddress?.slice(0, 6) + "..." + checkSumAddress?.slice(-4)}
|
|
119
|
+
</span>
|
|
120
|
+
<ChevronDownIcon
|
|
121
|
+
className="h-4 w-4"
|
|
122
|
+
style={{
|
|
123
|
+
color: isDarkMode ? "#FFF" : "black",
|
|
124
|
+
height: "16px",
|
|
125
|
+
width: "16px",
|
|
126
|
+
}}
|
|
127
|
+
/>
|
|
128
|
+
</div>
|
|
129
|
+
</summary>
|
|
130
|
+
<ul
|
|
131
|
+
tabIndex={0}
|
|
132
|
+
className="dropdown-content menu z-[2] p-2 mt-4 gap-1"
|
|
133
|
+
style={{
|
|
134
|
+
borderRadius: "8px",
|
|
135
|
+
border: isDarkMode ? "1px solid rgba(255, 255, 255, 0.20)" : "1px solid rgba(0, 0, 0, 0.1)",
|
|
136
|
+
background: isDarkMode ? "rgba(2, 2, 2, 0.20)" : "rgba(255, 255, 255, 0.20)",
|
|
137
|
+
backdropFilter: "blur(25px)",
|
|
138
|
+
}}
|
|
139
|
+
>
|
|
140
|
+
<li className={selectingNetwork ? "hidden" : ""}>
|
|
141
|
+
<div
|
|
142
|
+
className="flex gap-3 py-3 px-3 cursor-pointer rounded-lg transition-all duration-200 hover:bg-gradient-to-r hover:from-[rgba(48,180,237,0.16)] hover:to-[rgba(227,6,110,0.16)]"
|
|
143
|
+
onClick={() => copyAddressToClipboard(checkSumAddress)}
|
|
144
|
+
>
|
|
145
|
+
{isAddressCopiedToClipboard ? (
|
|
146
|
+
<>
|
|
147
|
+
<CheckCircleIcon
|
|
148
|
+
className="h-5 w-5"
|
|
149
|
+
style={{ color: isDarkMode ? "white" : "black" }}
|
|
150
|
+
aria-hidden="true"
|
|
151
|
+
/>
|
|
152
|
+
<span className="whitespace-nowrap" style={{ color: isDarkMode ? "white" : "black" }}>
|
|
153
|
+
Copied!
|
|
154
|
+
</span>
|
|
155
|
+
</>
|
|
156
|
+
) : (
|
|
157
|
+
<>
|
|
158
|
+
<DocumentDuplicateIcon
|
|
159
|
+
className="h-5 w-5"
|
|
160
|
+
style={{ color: isDarkMode ? "white" : "black" }}
|
|
161
|
+
aria-hidden="true"
|
|
162
|
+
/>
|
|
163
|
+
<span className="whitespace-nowrap" style={{ color: isDarkMode ? "white" : "black" }}>
|
|
164
|
+
Copy address
|
|
165
|
+
</span>
|
|
166
|
+
</>
|
|
167
|
+
)}
|
|
168
|
+
</div>
|
|
169
|
+
</li>
|
|
170
|
+
<li className={selectingNetwork ? "hidden" : ""}>
|
|
171
|
+
<label
|
|
172
|
+
htmlFor="qrcode-modal"
|
|
173
|
+
className="flex gap-3 py-3 px-3 cursor-pointer rounded-lg transition-all duration-200 hover:bg-gradient-to-r hover:from-[rgba(48,180,237,0.16)] hover:to-[rgba(227,6,110,0.16)]"
|
|
174
|
+
>
|
|
175
|
+
<QrCodeIcon className="h-5 w-5" style={{ color: isDarkMode ? "white" : "black" }} />
|
|
176
|
+
<span className="whitespace-nowrap" style={{ color: isDarkMode ? "white" : "black" }}>
|
|
177
|
+
View QR Code
|
|
178
|
+
</span>
|
|
179
|
+
</label>
|
|
180
|
+
</li>
|
|
181
|
+
{allowedNetworks.some(network => network.id === arbitrumNitro.id) && (
|
|
182
|
+
<li className={selectingNetwork ? "hidden" : ""}>
|
|
183
|
+
<button
|
|
184
|
+
className="flex gap-3 py-3 px-3 cursor-pointer rounded-lg transition-all duration-200 hover:bg-gradient-to-r hover:from-[rgba(48,180,237,0.16)] hover:to-[rgba(227,6,110,0.16)] w-full text-left"
|
|
185
|
+
type="button"
|
|
186
|
+
onClick={onSwitchAccount}
|
|
187
|
+
>
|
|
188
|
+
<UserCircleIcon className="h-5 w-5" style={{ color: isDarkMode ? "white" : "black" }} />
|
|
189
|
+
<span className="whitespace-nowrap" style={{ color: isDarkMode ? "white" : "black" }}>
|
|
190
|
+
Switch account
|
|
191
|
+
</span>
|
|
192
|
+
</button>
|
|
193
|
+
</li>
|
|
194
|
+
)}
|
|
195
|
+
{allowedNetworks.length > 1 ? (
|
|
196
|
+
<li className={selectingNetwork ? "hidden" : ""}>
|
|
197
|
+
<button
|
|
198
|
+
className="flex gap-3 py-3 px-3 cursor-pointer rounded-lg transition-all duration-200 hover:bg-gradient-to-r hover:from-[rgba(48,180,237,0.16)] hover:to-[rgba(227,6,110,0.16)] w-full text-left"
|
|
199
|
+
type="button"
|
|
200
|
+
onClick={() => {
|
|
201
|
+
setSelectingNetwork(true);
|
|
202
|
+
}}
|
|
203
|
+
>
|
|
204
|
+
<ArrowsRightLeftIcon className="h-5 w-5" style={{ color: isDarkMode ? "white" : "black" }} />
|
|
205
|
+
<span style={{ color: isDarkMode ? "white" : "black" }}>Switch Network</span>
|
|
206
|
+
</button>
|
|
207
|
+
</li>
|
|
208
|
+
) : null}
|
|
209
|
+
<li className={selectingNetwork ? "hidden" : ""}>
|
|
210
|
+
<button
|
|
211
|
+
className="flex gap-3 py-3 px-3 cursor-pointer rounded-lg transition-all duration-200 hover:bg-gradient-to-r hover:from-[rgba(48,180,237,0.16)] hover:to-[rgba(227,6,110,0.16)] w-full text-left"
|
|
212
|
+
type="button"
|
|
213
|
+
onClick={() => disconnect()}
|
|
214
|
+
>
|
|
215
|
+
<ArrowLeftEndOnRectangleIcon className="h-5 w-5" style={{ color: "#FB3748" }} />
|
|
216
|
+
<span style={{ color: "#FB3748" }}>Disconnect</span>
|
|
217
|
+
</button>
|
|
218
|
+
</li>
|
|
219
|
+
</ul>
|
|
220
|
+
</details>
|
|
221
|
+
</>
|
|
222
|
+
);
|
|
223
|
+
};
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
import { useState } from "react";
|
|
5
5
|
import { Balance } from "../Balance";
|
|
6
6
|
import { AddressInfoDropdown } from "./AddressInfoDropdown";
|
|
7
|
+
import { AngularWalletAddress } from "./AngularWalletAddress";
|
|
7
8
|
import { AddressQRCodeModal } from "./AddressQRCodeModal";
|
|
8
9
|
import { BurnerWalletModal } from "./BurnerWalletModal";
|
|
9
10
|
import { WrongNetworkDropdown } from "./WrongNetworkDropdown";
|
|
@@ -64,7 +65,7 @@ export const RainbowKitCustomConnectButton = () => {
|
|
|
64
65
|
{chain.name}
|
|
65
66
|
</span>
|
|
66
67
|
</div>
|
|
67
|
-
<
|
|
68
|
+
<AngularWalletAddress
|
|
68
69
|
address={account.address as Address}
|
|
69
70
|
displayName={account.displayName}
|
|
70
71
|
ensAvatar={account.ensAvatar}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
const EthIcon = ({ width = 32, height = 32, className = "" }) => {
|
|
4
|
+
return (
|
|
5
|
+
<svg
|
|
6
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
7
|
+
width={width}
|
|
8
|
+
height={height}
|
|
9
|
+
viewBox="0 0 32 32"
|
|
10
|
+
fill="none"
|
|
11
|
+
className={className}
|
|
12
|
+
>
|
|
13
|
+
<g fill="none" fillRule="evenodd">
|
|
14
|
+
<circle cx="16" cy="16" r="16" fill="#627EEA" />
|
|
15
|
+
<g fill="#FFF" fillRule="nonzero">
|
|
16
|
+
<path fillOpacity=".602" d="M16.498 4v8.87l7.497 3.35z" />
|
|
17
|
+
<path d="M16.498 4L9 16.22l7.498-3.35z" />
|
|
18
|
+
<path fillOpacity=".602" d="M16.498 21.968v6.027L24 17.616z" />
|
|
19
|
+
<path d="M16.498 27.995v-6.028L9 17.616z" />
|
|
20
|
+
<path fillOpacity=".2" d="M16.498 20.573l7.497-4.353-7.497-3.348z" />
|
|
21
|
+
<path fillOpacity=".602" d="M9 16.22l7.498 4.353v-7.701z" />
|
|
22
|
+
</g>
|
|
23
|
+
</g>
|
|
24
|
+
</svg>
|
|
25
|
+
);
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
export default EthIcon;
|
|
@@ -13,6 +13,15 @@
|
|
|
13
13
|
"vercel": "vercel",
|
|
14
14
|
"vercel:yolo": "vercel --build-env NEXT_PUBLIC_IGNORE_BUILD_ERROR=true"
|
|
15
15
|
},
|
|
16
|
+
"overrides": {
|
|
17
|
+
"chalk": "5.3.0",
|
|
18
|
+
"strip-ansi": "7.1.0",
|
|
19
|
+
"color-convert": "2.0.1",
|
|
20
|
+
"color-name": "1.1.4",
|
|
21
|
+
"is-core-module": "2.13.1",
|
|
22
|
+
"error-ex": "1.3.2",
|
|
23
|
+
"has-ansi": "5.0.1"
|
|
24
|
+
},
|
|
16
25
|
"dependencies": {
|
|
17
26
|
"@ethersproject/providers": "^5.7.2",
|
|
18
27
|
"@heroicons/react": "^2.1.5",
|
|
@@ -1,8 +1,21 @@
|
|
|
1
|
-
<svg width="
|
|
2
|
-
<path d="
|
|
3
|
-
<path d="
|
|
4
|
-
<path d="
|
|
5
|
-
<path d="
|
|
6
|
-
<path d="
|
|
7
|
-
<path d="
|
|
1
|
+
<svg width="48" height="48" viewBox="0 0 48 48" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M0 6C0 2.68629 2.68629 0 6 0H42C45.3137 0 48 2.68629 48 6V42C48 45.3137 45.3137 48 42 48H6C2.68629 48 0 45.3137 0 42V6Z" fill="#020202"/>
|
|
3
|
+
<path d="M0 6C0 2.68629 2.68629 0 6 0H42C45.3137 0 48 2.68629 48 6V42C48 45.3137 45.3137 48 42 48H6C2.68629 48 0 45.3137 0 42V6Z" fill="url(#paint0_linear_203_709)" fill-opacity="0.3"/>
|
|
4
|
+
<path d="M9.75907 10.6256L7.26708 15.4397H14.299L14.3159 32.7282C14.3159 35.7434 11.3632 36.0117 9.29256 36.0117L6.8269 39.7194V40.1518H28.8639V39.6818L26.3834 36.0134H22.7469C20.613 36.0134 19.6704 34.2796 19.6704 32.7137V19.1777C19.6704 16.278 21.7848 15.4775 22.842 15.4397H38.0246L35.2452 10.6256H19.6704V5.69836L14.4599 7.62396V10.6256H9.75907Z" fill="url(#paint1_linear_203_709)"/>
|
|
5
|
+
<path d="M31.754 27.7199L33.2964 28.1758L32.5989 28.8467L32.5355 28.9077L31.4749 28.5951C30.4673 28.2977 29.7143 27.5331 29.4599 26.5497C29.2054 25.5663 29.498 24.5516 30.2431 23.835L34.4006 19.8348C34.4134 19.8402 34.426 19.8463 34.4379 19.8532C34.4506 19.8592 34.4632 19.8661 34.4751 19.8723C34.4966 19.8829 34.5171 19.8952 34.5386 19.9066C34.5591 19.9181 34.5797 19.9302 34.6005 19.9433C34.6171 19.9533 34.633 19.9631 34.6488 19.9737C34.6646 19.9837 34.6804 19.9943 34.6964 20.0058C34.7115 20.0158 34.7257 20.0264 34.7399 20.037C34.7527 20.0454 34.7653 20.0553 34.7772 20.0652C34.7883 20.0728 34.7986 20.0812 34.8088 20.0903C34.8104 20.0912 34.8121 20.0918 34.8136 20.0935C34.8612 20.1316 34.9063 20.1712 34.9507 20.2138L35.1521 20.4075L30.9153 24.4816C30.4088 24.9695 30.2098 25.6594 30.3826 26.3287C30.5554 26.9981 31.0682 27.5179 31.754 27.7199Z" fill="#1A1A1A"/>
|
|
6
|
+
<path d="M32.2079 26.3798L34.5399 26.9798L33.7632 27.7268L31.9622 27.2633C31.4494 27.1321 31.0617 26.7593 30.9238 26.2661C30.7867 25.7729 30.9286 25.2635 31.3034 24.903L35.5649 20.8046L36.2379 21.4518L31.9764 25.5495C31.9241 25.6005 31.8844 25.6584 31.8584 25.7225C31.8196 25.8202 31.814 25.926 31.8426 26.0297C31.8482 26.0503 31.8553 26.0701 31.864 26.0893C31.9251 26.2326 32.0496 26.3394 32.2081 26.3798H32.2079Z" fill="#1A1A1A"/>
|
|
7
|
+
<path d="M36.7257 28.6896L32.5674 32.6897L31.9848 33.25C31.7953 33.1387 31.6186 33.0044 31.4577 32.8497L31.2563 32.656L31.8168 32.117L36.0536 28.0429C36.5609 27.555 36.7599 26.8644 36.5863 26.1958C36.4126 25.5265 35.9007 25.0066 35.2149 24.8046L33.6731 24.3495L33.7365 24.2885L34.434 23.6177L35.4947 23.9303C36.5021 24.2277 37.2552 24.9922 37.5096 25.9756C37.7632 26.9591 37.4709 27.9738 36.7257 28.6896Z" fill="white"/>
|
|
8
|
+
<path d="M35.6649 27.6224L31.4043 31.7209L30.8439 32.2599L30.1709 31.6126L30.7313 31.0736L34.9928 26.976C35.0458 26.9241 35.0855 26.8662 35.1101 26.8021C35.1489 26.7044 35.1545 26.5986 35.1259 26.4955C35.1203 26.4749 35.1132 26.4551 35.1054 26.436C35.0452 26.2927 34.9198 26.1859 34.7606 26.1448L32.4293 25.5456L32.4942 25.4832L33.1411 24.8611L33.206 24.7986L35.0062 25.2605C35.519 25.3932 35.9066 25.766 36.0446 26.2585C36.1817 26.7517 36.0398 27.2617 35.6649 27.6224Z" fill="white"/>
|
|
9
|
+
<path d="M40.3805 26.2623C40.3805 26.7952 40.1648 27.2961 39.7733 27.6727L34.9506 32.3109C34.559 32.6875 34.0382 32.8949 33.4841 32.8949C33.4516 32.8949 33.4191 32.8941 33.3873 32.8926H33.3778C33.3525 32.8911 33.3278 32.8895 33.3033 32.8872C33.2946 32.8864 33.2866 32.8857 33.278 32.8849C33.2535 32.8826 33.2297 32.8803 33.205 32.8766C33.2011 32.8766 33.197 32.8758 33.1931 32.8751C33.1827 32.8743 33.1717 32.8728 33.1606 32.8713C33.1329 32.8668 33.1058 32.8622 33.079 32.8576C33.0751 32.8561 33.071 32.8553 33.0679 32.8553C33.0434 32.8499 33.0188 32.8447 32.9949 32.8393C32.972 32.8339 32.949 32.8286 32.9261 32.8218C32.9102 32.818 32.8951 32.8134 32.8801 32.8095C32.8533 32.8018 32.8262 32.7935 32.8 32.7843C32.792 32.7812 32.7842 32.7789 32.7762 32.776C32.7738 32.7752 32.7723 32.7745 32.7699 32.7737C32.747 32.766 32.7247 32.7577 32.7026 32.7485C32.693 32.7454 32.6835 32.7408 32.674 32.737C32.6415 32.7233 32.609 32.7096 32.5765 32.6943C32.5733 32.6929 32.5702 32.6912 32.567 32.6898L36.7254 28.6896C37.4705 27.9738 37.7631 26.9591 37.5093 25.9757C37.2549 24.9923 36.5017 24.2276 35.4943 23.9303L34.4337 23.6177L33.7362 24.2886L33.6727 24.3496L35.2145 24.8047C35.9001 25.0067 36.4123 25.5265 36.5859 26.1959C36.7596 26.8644 36.5606 27.5552 36.0532 28.043L31.8164 32.1171L31.256 32.6561L30.8439 32.2597L31.4043 31.7207L35.6649 27.6223C36.0398 27.2618 36.1818 26.7517 36.0445 26.2584C35.9066 25.7658 35.519 25.3931 35.0062 25.2604L33.206 24.7984L33.141 24.8609L32.4942 25.483L32.4292 25.5455L34.7606 26.1447C34.92 26.1859 35.0451 26.2926 35.1053 26.4359C35.1133 26.455 35.1205 26.4748 35.1259 26.4954C35.1545 26.5983 35.1489 26.7043 35.1101 26.8019C35.0856 26.8659 35.0458 26.924 34.9927 26.9758L30.7313 31.0735L27.1951 27.6725C26.8036 27.296 26.5879 26.7951 26.5879 26.2621C26.5879 25.7292 26.8036 25.2283 27.1951 24.8518L32.0178 20.2139C32.4093 19.8373 32.9301 19.6299 33.4843 19.6299C33.5168 19.6299 33.5492 19.6307 33.5811 19.6322H33.5906C33.6239 19.6336 33.6571 19.6368 33.6904 19.6399C33.7173 19.6422 33.7443 19.6453 33.7705 19.649C33.7753 19.649 33.7792 19.6498 33.7833 19.6505C33.7937 19.6513 33.8032 19.6528 33.8125 19.6543C33.8379 19.658 33.8625 19.6626 33.887 19.6672C33.8918 19.668 33.8957 19.6687 33.9005 19.6695C33.925 19.6749 33.9488 19.6801 33.9734 19.6855C33.9964 19.6909 34.0194 19.6961 34.0423 19.703C34.0542 19.7061 34.0668 19.7091 34.0787 19.713C34.0969 19.7184 34.1151 19.7236 34.1335 19.7298C34.1692 19.7413 34.2056 19.7534 34.2405 19.7671C34.2587 19.7725 34.2762 19.7794 34.2935 19.7877C34.3117 19.7946 34.3299 19.8023 34.3474 19.8106C34.3656 19.8183 34.3832 19.8267 34.4005 19.835L30.243 23.8351C29.4979 24.5518 29.2053 25.5664 29.4598 26.5499C29.7142 27.5333 30.4672 28.298 31.4747 28.5953L32.5354 28.9078L32.5988 28.8468L33.2963 28.176L31.7538 27.7201C31.0682 27.5181 30.5553 26.9981 30.3825 26.3289C30.2097 25.6595 30.4087 24.9696 30.9152 24.4818L35.1519 20.4077L35.5649 20.8049L31.3035 24.9033C30.9286 25.2638 30.7866 25.7732 30.9238 26.2664C31.0618 26.7596 31.4494 27.1324 31.9622 27.2636L33.7632 27.7271L34.54 26.9801L32.208 26.3801C32.0494 26.3397 31.9249 26.233 31.8639 26.0896C31.8552 26.0704 31.8481 26.0506 31.8425 26.03C31.8139 25.9263 31.8195 25.8203 31.8583 25.7228C31.8845 25.6589 31.9241 25.6008 31.9763 25.5498L36.2378 21.4521L39.7731 24.8523C40.1647 25.2288 40.3803 25.7297 40.3803 26.2626L40.3805 26.2623Z" fill="#213147"/>
|
|
10
|
+
<path d="M40.3336 24.3123L36.7982 20.9122L36.1252 20.2649L35.5117 19.6749C35.3508 19.5201 35.1732 19.386 34.9838 19.2746C34.5375 19.0093 34.0223 18.8674 33.484 18.8674C32.7183 18.8674 31.9985 19.154 31.4571 19.6747L26.6345 24.3123C26.0932 24.8338 25.7952 25.526 25.7952 26.2625C25.7952 26.9989 26.0932 27.6911 26.6345 28.2126L30.1707 31.6128L30.7312 31.0738L27.195 27.6728C26.8034 27.2963 26.5878 26.7954 26.5878 26.2625C26.5878 25.7295 26.8034 25.2286 27.195 24.8521L32.0177 20.2138C32.4092 19.8373 32.93 19.6299 33.4841 19.6299C33.5166 19.6299 33.5491 19.6307 33.5809 19.6322H33.5904C33.6238 19.6336 33.6569 19.6367 33.6903 19.6398C33.7172 19.6421 33.7442 19.6452 33.7704 19.649C33.7752 19.649 33.7791 19.6498 33.7831 19.6505C33.7935 19.6513 33.803 19.6528 33.8124 19.6542C33.8377 19.658 33.8624 19.6626 33.8869 19.6672C33.8917 19.668 33.8956 19.6686 33.9003 19.6695C33.9248 19.6749 33.9486 19.6801 33.9733 19.6855C33.9963 19.6909 34.0192 19.6961 34.0422 19.703C34.0541 19.7061 34.0667 19.709 34.0786 19.713C34.0968 19.7184 34.115 19.7236 34.1333 19.7298C34.1691 19.7413 34.2055 19.7534 34.2403 19.7671C34.2585 19.7725 34.276 19.7794 34.2934 19.7877C34.3116 19.7946 34.3298 19.8023 34.3473 19.8106C34.3655 19.8183 34.383 19.8267 34.4004 19.835L30.2429 23.8351C29.4977 24.5518 29.2052 25.5664 29.4596 26.5499C29.7141 27.5333 30.467 28.298 31.4746 28.5952L32.5352 28.9078L32.5987 28.8468L33.2962 28.176L31.7537 27.7201C31.0681 27.5181 30.5551 26.9981 30.3823 26.3289C30.2095 25.6595 30.4085 24.9695 30.915 24.4817L35.1518 20.4077L35.1462 20.4023L35.5648 20.8048L31.3033 24.9033C30.9285 25.2638 30.7864 25.7732 30.9237 26.2664C31.0616 26.7596 31.4493 27.1324 31.9621 27.2635L33.7631 27.7271L34.5398 26.9801L32.2078 26.3801C32.0493 26.3397 31.9248 26.233 31.8638 26.0896C31.8551 26.0704 31.8479 26.0506 31.8423 26.03C31.8137 25.9263 31.8194 25.8203 31.8581 25.7228C31.8843 25.6589 31.924 25.6008 31.9762 25.5497L36.2376 21.4521L39.773 24.8523C40.1645 25.2288 40.3802 25.7297 40.3802 26.2626C40.3802 26.7956 40.1645 27.2964 39.773 27.673L34.9503 32.3112C34.5587 32.6878 34.0379 32.8952 33.4838 32.8952C33.4513 32.8952 33.4188 32.8944 33.387 32.8929H33.3775C33.3522 32.8914 33.3275 32.8898 33.303 32.8875C33.2943 32.8867 33.2863 32.886 33.2777 32.8852C33.2532 32.8829 33.2294 32.8806 33.2047 32.8769C33.2008 32.8769 33.1967 32.8761 33.1928 32.8754C33.1824 32.8746 33.1714 32.8731 33.1603 32.8717C33.1326 32.8671 33.1055 32.8625 33.0787 32.8579C33.0747 32.8564 33.0707 32.8556 33.0676 32.8556C33.0431 32.8502 33.0185 32.845 32.9946 32.8396C32.9717 32.8342 32.9487 32.829 32.9258 32.8221C32.9099 32.8183 32.8948 32.8137 32.8798 32.8098C32.853 32.8021 32.8259 32.7938 32.7997 32.7846C32.7917 32.7815 32.7839 32.7792 32.7759 32.7763C32.7735 32.7755 32.772 32.7748 32.7696 32.774C32.7467 32.7663 32.7244 32.758 32.7023 32.7488C32.6927 32.7457 32.6832 32.7411 32.6737 32.7374C32.6412 32.7236 32.6087 32.7099 32.5762 32.6947C32.573 32.6932 32.5699 32.6916 32.5667 32.6901L31.9842 33.2503C32.4305 33.5157 32.9457 33.6575 33.484 33.6575C34.2497 33.6575 34.9695 33.3709 35.5117 32.8502L40.3336 28.2128C40.875 27.6913 41.1729 26.999 41.1729 26.2626C41.1729 25.5262 40.875 24.8339 40.3336 24.3124V24.3123Z" fill="#E3066E"/>
|
|
11
|
+
<defs>
|
|
12
|
+
<linearGradient id="paint0_linear_203_709" x1="24" y1="-12.0009" x2="24" y2="48" gradientUnits="userSpaceOnUse">
|
|
13
|
+
<stop stop-opacity="0"/>
|
|
14
|
+
<stop offset="1" stop-color="#E3066E"/>
|
|
15
|
+
</linearGradient>
|
|
16
|
+
<linearGradient id="paint1_linear_203_709" x1="22.4258" y1="5.69836" x2="22.4258" y2="40.1518" gradientUnits="userSpaceOnUse">
|
|
17
|
+
<stop stop-color="white"/>
|
|
18
|
+
<stop offset="1" stop-color="white" stop-opacity="0.5"/>
|
|
19
|
+
</linearGradient>
|
|
20
|
+
</defs>
|
|
8
21
|
</svg>
|