diff --git a/types/api/search.ts b/types/api/search.ts index f4a471420b..94b70c4f5a 100644 --- a/types/api/search.ts +++ b/types/api/search.ts @@ -16,6 +16,7 @@ export interface SearchResultToken { is_verified_via_admin_panel: boolean; is_smart_contract_verified: boolean; filecoin_robust_address?: string | null; + certified?: boolean; } export interface SearchResultAddressOrContract { diff --git a/ui/pages/__screenshots__/SearchResults.pw.tsx_default_search-by-address-hash-mobile-1.png b/ui/pages/__screenshots__/SearchResults.pw.tsx_default_search-by-address-hash-mobile-1.png index 416893e1a8..0c8827ca15 100644 Binary files a/ui/pages/__screenshots__/SearchResults.pw.tsx_default_search-by-address-hash-mobile-1.png and b/ui/pages/__screenshots__/SearchResults.pw.tsx_default_search-by-address-hash-mobile-1.png differ diff --git a/ui/pages/__screenshots__/SearchResults.pw.tsx_mobile_search-by-address-hash-mobile-1.png b/ui/pages/__screenshots__/SearchResults.pw.tsx_mobile_search-by-address-hash-mobile-1.png index e954f72aca..4b993f42bf 100644 Binary files a/ui/pages/__screenshots__/SearchResults.pw.tsx_mobile_search-by-address-hash-mobile-1.png and b/ui/pages/__screenshots__/SearchResults.pw.tsx_mobile_search-by-address-hash-mobile-1.png differ diff --git a/ui/searchResults/SearchResultListItem.tsx b/ui/searchResults/SearchResultListItem.tsx index 300b96a6b2..9ed5a28ec9 100644 --- a/ui/searchResults/SearchResultListItem.tsx +++ b/ui/searchResults/SearchResultListItem.tsx @@ -73,7 +73,8 @@ const SearchResultListItem = ({ data, searchTerm, isLoading, addressFormat }: Pr textOverflow="ellipsis" /> - { data.is_verified_via_admin_panel && } + { data.certified && } + { data.is_verified_via_admin_panel && !data.certified && } ); } @@ -385,7 +386,7 @@ const SearchResultListItem = ({ data, searchTerm, isLoading, addressFormat }: Pr { expiresText } ) } - { data.certified && } + { data.certified && } ) : null; diff --git a/ui/searchResults/SearchResultTableItem.tsx b/ui/searchResults/SearchResultTableItem.tsx index eb3b3ef742..1d195b861e 100644 --- a/ui/searchResults/SearchResultTableItem.tsx +++ b/ui/searchResults/SearchResultTableItem.tsx @@ -75,7 +75,8 @@ const SearchResultTableItem = ({ data, searchTerm, isLoading, addressFormat }: P dangerouslySetInnerHTML={{ __html: highlightText(name, searchTerm) }} /> - { data.is_verified_via_admin_panel && } + { data.certified && } + { data.is_verified_via_admin_panel && !data.certified && } @@ -154,7 +155,7 @@ const SearchResultTableItem = ({ data, searchTerm, isLoading, addressFormat }: P { expiresText } ) } - { data.certified && } + { data.certified && } ) } diff --git a/ui/snippets/searchBar/SearchBarSuggest/SearchBarSuggestAddress.tsx b/ui/snippets/searchBar/SearchBarSuggest/SearchBarSuggestAddress.tsx index 4e864ecad9..079dae8011 100644 --- a/ui/snippets/searchBar/SearchBarSuggest/SearchBarSuggestAddress.tsx +++ b/ui/snippets/searchBar/SearchBarSuggest/SearchBarSuggestAddress.tsx @@ -46,7 +46,7 @@ const SearchBarSuggestAddress = ({ data, isMobile, searchTerm, addressFormat }: { expiresText } ) } - { data.certified && } + { data.certified && } ); const addressEl = ; diff --git a/ui/snippets/searchBar/SearchBarSuggest/SearchBarSuggestToken.tsx b/ui/snippets/searchBar/SearchBarSuggest/SearchBarSuggestToken.tsx index aa2d38c999..a7c2142d0c 100644 --- a/ui/snippets/searchBar/SearchBarSuggest/SearchBarSuggestToken.tsx +++ b/ui/snippets/searchBar/SearchBarSuggest/SearchBarSuggestToken.tsx @@ -6,6 +6,7 @@ import type { SearchResultToken } from 'types/api/search'; import { toBech32Address } from 'lib/address/bech32'; import highlightText from 'lib/highlightText'; +import ContractCertifiedLabel from 'ui/shared/ContractCertifiedLabel'; import * as TokenEntity from 'ui/shared/entities/token/TokenEntity'; import HashStringShortenDynamic from 'ui/shared/HashStringShortenDynamic'; import IconSvg from 'ui/shared/IconSvg'; @@ -13,6 +14,7 @@ import IconSvg from 'ui/shared/IconSvg'; const SearchBarSuggestToken = ({ data, isMobile, searchTerm, addressFormat }: ItemsProps) => { const icon = ; const verifiedIcon = ; + const certifiedIcon = ; const hash = data.filecoin_robust_address || (addressFormat === 'bech32' ? toBech32Address(data.address) : data.address); const name = ( @@ -49,7 +51,8 @@ const SearchBarSuggestToken = ({ data, isMobile, searchTerm, addressFormat }: It { icon } { name } - { data.is_verified_via_admin_panel && verifiedIcon } + { data.certified && certifiedIcon } + { data.is_verified_via_admin_panel && !data.certified && verifiedIcon } @@ -67,7 +70,8 @@ const SearchBarSuggestToken = ({ data, isMobile, searchTerm, addressFormat }: It { icon } { name } - { data.is_verified_via_admin_panel && verifiedIcon } + { data.certified && certifiedIcon } + { data.is_verified_via_admin_panel && !data.certified && verifiedIcon } { address } diff --git a/ui/snippets/searchBar/__screenshots__/SearchBar.pw.tsx_dark-color-mode_search-by-contract-name-mobile-dark-mode-1.png b/ui/snippets/searchBar/__screenshots__/SearchBar.pw.tsx_dark-color-mode_search-by-contract-name-mobile-dark-mode-1.png index 8561be26a8..ac86dd52f9 100644 Binary files a/ui/snippets/searchBar/__screenshots__/SearchBar.pw.tsx_dark-color-mode_search-by-contract-name-mobile-dark-mode-1.png and b/ui/snippets/searchBar/__screenshots__/SearchBar.pw.tsx_dark-color-mode_search-by-contract-name-mobile-dark-mode-1.png differ diff --git a/ui/snippets/searchBar/__screenshots__/SearchBar.pw.tsx_default_search-by-contract-name-mobile-dark-mode-1.png b/ui/snippets/searchBar/__screenshots__/SearchBar.pw.tsx_default_search-by-contract-name-mobile-dark-mode-1.png index 170d128b65..70b94b6670 100644 Binary files a/ui/snippets/searchBar/__screenshots__/SearchBar.pw.tsx_default_search-by-contract-name-mobile-dark-mode-1.png and b/ui/snippets/searchBar/__screenshots__/SearchBar.pw.tsx_default_search-by-contract-name-mobile-dark-mode-1.png differ diff --git a/ui/snippets/searchBar/__screenshots__/SearchBar.pw.tsx_mobile_search-by-contract-name-mobile-dark-mode-1.png b/ui/snippets/searchBar/__screenshots__/SearchBar.pw.tsx_mobile_search-by-contract-name-mobile-dark-mode-1.png index ce6991aeb0..5188697778 100644 Binary files a/ui/snippets/searchBar/__screenshots__/SearchBar.pw.tsx_mobile_search-by-contract-name-mobile-dark-mode-1.png and b/ui/snippets/searchBar/__screenshots__/SearchBar.pw.tsx_mobile_search-by-contract-name-mobile-dark-mode-1.png differ