Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
frontend
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
vicotor
frontend
Commits
c15859e2
Commit
c15859e2
authored
Feb 09, 2024
by
tom
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Do not send user operations API requests, if NEXT_PUBLIC_HAS_USER_OPS is not enabled
parent
9068d41b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
Address.tsx
ui/pages/Address.tsx
+6
-6
No files found.
ui/pages/Address.tsx
View file @
c15859e2
...
...
@@ -67,7 +67,7 @@ const AddressPageContent = () => {
const
userOpsAccountQuery
=
useApiQuery
(
'
user_ops_account
'
,
{
pathParams
:
{
hash
},
queryOptions
:
{
enabled
:
Boolean
(
hash
),
enabled
:
Boolean
(
hash
)
&&
config
.
features
.
userOps
.
isEnabled
,
placeholderData
:
USER_OPS_ACCOUNT
,
},
});
...
...
@@ -160,16 +160,18 @@ const AddressPageContent = () => {
].
filter
(
Boolean
);
},
[
addressQuery
.
data
,
contractTabs
,
addressTabsCountersQuery
.
data
,
userOpsAccountQuery
.
data
]);
const
isLoading
=
addressQuery
.
isPlaceholderData
||
(
config
.
features
.
userOps
.
isEnabled
&&
userOpsAccountQuery
.
isPlaceholderData
);
const
tags
=
(
<
EntityTags
data=
{
addressQuery
.
data
}
isLoading=
{
addressQuery
.
isPlaceholderData
}
isLoading=
{
isLoading
}
tagsBefore=
{
[
!
addressQuery
.
data
?.
is_contract
?
{
label
:
'
eoa
'
,
display_name
:
'
EOA
'
}
:
undefined
,
addressQuery
.
data
?.
implementation_address
?
{
label
:
'
proxy
'
,
display_name
:
'
Proxy
'
}
:
undefined
,
addressQuery
.
data
?.
token
?
{
label
:
'
token
'
,
display_name
:
'
Token
'
}
:
undefined
,
isSafeAddress
?
{
label
:
'
safe
'
,
display_name
:
'
Multisig: Safe
'
}
:
undefined
,
userOpsAccountQuery
.
data
?
{
label
:
'
user_ops_acc
'
,
display_name
:
'
Smart contract wallet
'
}
:
undefined
,
config
.
features
.
userOps
.
isEnabled
&&
userOpsAccountQuery
.
data
?
{
label
:
'
user_ops_acc
'
,
display_name
:
'
Smart contract wallet
'
}
:
undefined
,
]
}
/>
);
...
...
@@ -189,8 +191,6 @@ const AddressPageContent = () => {
};
},
[
appProps
.
referrer
]);
const
isLoading
=
addressQuery
.
isPlaceholderData
;
const
titleSecondRow
=
(
<
Flex
alignItems=
"center"
w=
"100%"
columnGap=
{
2
}
rowGap=
{
2
}
flexWrap=
{
{
base
:
'
wrap
'
,
lg
:
'
nowrap
'
}
}
>
{
addressQuery
.
data
?.
ens_domain_name
&&
(
...
...
@@ -241,7 +241,7 @@ const AddressPageContent = () => {
<
AddressDetails
addressQuery=
{
addressQuery
}
scrollRef=
{
tabsScrollRef
}
/>
{
/* should stay before tabs to scroll up with pagination */
}
<
Box
ref=
{
tabsScrollRef
}
></
Box
>
{
(
addressQuery
.
isPlaceholderData
||
addressTabsCountersQuery
.
isPlaceholderData
||
userOpsAccount
Query
.
isPlaceholderData
)
?
{
(
isLoading
||
addressTabsCounters
Query
.
isPlaceholderData
)
?
<
TabsSkeleton
tabs=
{
tabs
}
/>
:
content
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment