Skip to content

Commit

Permalink
fix: native token logic (#3147)
Browse files Browse the repository at this point in the history
  • Loading branch information
qwang1113 authored Jun 25, 2023
1 parent 6749427 commit 6585750
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 8 deletions.
13 changes: 5 additions & 8 deletions packages/components/src/Token/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -103,15 +103,12 @@ export const TokenVerifiedIcon: FC<{
const navigation = useAppNavigation();

const icon = useMemo(() => {
if (token?.isNative) {
return (
<Badge title={intl.formatMessage({ id: 'content__coin' })} size="sm" />
);
}
if (!token?.riskLevel) {
if (token?.isNative) {
return (
<Badge
title={intl.formatMessage({ id: 'content__coin' })}
size="sm"
/>
);
}
return null;
}
if (token?.riskLevel > TokenRiskLevel.VERIFIED) {
Expand Down
2 changes: 2 additions & 0 deletions packages/kit/src/views/Wallet/AssetsList/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,9 @@ function AssetsList({
useEffect(() => {
const { serviceOverview } = backgroundApiProxy;
serviceOverview.subscribe();
}, [accountId, networkId]);

useEffect(() => {
if (platformEnv.isExtensionUi) {
chrome.runtime.connect();
}
Expand Down

0 comments on commit 6585750

Please sign in to comment.