Skip to content

Commit 23cfb93

Browse files
committed
KEEP-1157 Change order of network and contract
1 parent 6eff4ac commit 23cfb93

File tree

3 files changed

+19
-27
lines changed

3 files changed

+19
-27
lines changed

components/workflows/user-menu.tsx

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -35,20 +35,17 @@ export const UserMenu = () => {
3535
const [integrationsOpen, setIntegrationsOpen] = useState(false);
3636
const [apiKeysOpen, setApiKeysOpen] = useState(false);
3737
const [providerId, setProviderId] = useState<string | null>(null);
38-
const [walletAddress, setWalletAddress] = useState<string | null>(null);
3938

40-
// Fetch provider info and wallet when session is available
39+
// Fetch provider info when session is available
4140
useEffect(() => {
4241
if (session?.user && !session.user.name?.startsWith("Anonymous")) {
4342
api.user
4443
.get()
4544
.then((user) => {
4645
setProviderId(user.providerId);
47-
setWalletAddress(user.walletAddress || null);
4846
})
4947
.catch(() => {
5048
setProviderId(null);
51-
setWalletAddress(null);
5249
});
5350
}
5451
}, [session?.user]);
@@ -101,7 +98,7 @@ export const UserMenu = () => {
10198
<div className="flex items-center gap-2">
10299
<AuthDialog>
103100
<Button
104-
className="h-9 disabled:opacity-100 disabled:[&>*]:text-muted-foreground"
101+
className="h-9 disabled:opacity-100 disabled:*:text-muted-foreground"
105102
size="sm"
106103
variant="default"
107104
>
@@ -137,11 +134,6 @@ export const UserMenu = () => {
137134
<p className="text-muted-foreground text-xs leading-none">
138135
{session?.user?.email}
139136
</p>
140-
{walletAddress && (
141-
<p className="font-mono text-muted-foreground text-xs leading-none">
142-
{walletAddress.slice(0, 6)}...{walletAddress.slice(-4)}
143-
</p>
144-
)}
145137
</div>
146138
</DropdownMenuLabel>
147139
<DropdownMenuSeparator />

plugins/web3/icon.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
export function Web3Icon({ className }: { className?: string }) {
22
return (
3-
<svg className={className} xmlns="http://www.w3.org/2000/svg" width="148" height="148" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.25" stroke-linecap="round" stroke-linejoin="round" >
3+
<svg className={className} xmlns="http://www.w3.org/2000/svg" width="148" height="148" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="1.25" strokeLinecap="round" strokeLinejoin="round" >
44
<title>Web3</title>
55
<circle cx="12" cy="12" r="10"/>
66
<path d="M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20"/>

plugins/web3/index.ts

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -74,14 +74,6 @@ const web3Plugin: IntegrationPlugin = {
7474
},
7575
],
7676
configFields: [
77-
{
78-
key: "contractAddress",
79-
label: "Contract Address",
80-
type: "template-input",
81-
placeholder: "0x... or {{NodeName.contractAddress}}",
82-
example: "0x6B175474E89094C44Da98b954EedeAC495271d0F",
83-
required: true,
84-
},
8577
{
8678
key: "network",
8779
label: "Network",
@@ -93,6 +85,14 @@ const web3Plugin: IntegrationPlugin = {
9385
{ label: "Sepolia Testnet", value: "sepolia" },
9486
],
9587
},
88+
{
89+
key: "contractAddress",
90+
label: "Contract Address",
91+
type: "template-input",
92+
placeholder: "0x... or {{NodeName.contractAddress}}",
93+
example: "0x6B175474E89094C44Da98b954EedeAC495271d0F",
94+
required: true,
95+
},
9696
{
9797
key: "abi",
9898
label: "Contract ABI",
@@ -144,14 +144,6 @@ const web3Plugin: IntegrationPlugin = {
144144
},
145145
],
146146
configFields: [
147-
{
148-
key: "contractAddress",
149-
label: "Contract Address",
150-
type: "template-input",
151-
placeholder: "0x... or {{NodeName.contractAddress}}",
152-
example: "0x6B175474E89094C44Da98b954EedeAC495271d0F",
153-
required: true,
154-
},
155147
{
156148
key: "network",
157149
label: "Network",
@@ -163,6 +155,14 @@ const web3Plugin: IntegrationPlugin = {
163155
{ label: "Sepolia Testnet", value: "sepolia" },
164156
],
165157
},
158+
{
159+
key: "contractAddress",
160+
label: "Contract Address",
161+
type: "template-input",
162+
placeholder: "0x... or {{NodeName.contractAddress}}",
163+
example: "0x6B175474E89094C44Da98b954EedeAC495271d0F",
164+
required: true,
165+
},
166166
{
167167
key: "abi",
168168
label: "Contract ABI",

0 commit comments

Comments
 (0)