Fix Bug 57877: show icon badge where hover

This commit is contained in:
Viktor Fomin 2022-06-30 13:52:50 +03:00
parent a357badf78
commit fe294e77e1
2 changed files with 16 additions and 1 deletions

View File

@ -97,7 +97,7 @@ const CatalogItem = (props) => {
{!iconBadge ? ( {!iconBadge ? (
<Badge className="catalog-item__badge" label={labelBadge} /> <Badge className="catalog-item__badge" label={labelBadge} />
) : ( ) : (
<ReactSVG src={iconBadge} /> <ReactSVG className="catalog-icon__badge" src={iconBadge} />
)} )}
</StyledCatalogItemBadgeWrapper> </StyledCatalogItemBadgeWrapper>
)} )}

View File

@ -310,7 +310,22 @@ const StyledCatalogItemContainer = styled.div`
`} `}
-webkit-tap-highlight-color: rgba(0, 0, 0, 0); -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
.catalog-icon__badge {
display: none;
}
.catalog-icon__badge:target {
display: flex;
}
:hover {
.catalog-icon__badge {
display: flex;
}
}
`; `;
StyledCatalogItemContainer.defaultProps = { theme: Base }; StyledCatalogItemContainer.defaultProps = { theme: Base };
export { export {