Remove HotbarIcon box-shadow artifacts (#5142)

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
This commit is contained in:
Alex Andreev authored and GitHub committed 2022-03-30 15:23:46 +03:00
1 parent 69f1ecb0b9
commit 37d8294198
3 files changed
+13 -11

No files matched your search

@@ -4,7 +4,8 @@
*/
.HotbarIcon {
--iconActiveShadow: 0 0 0px 3px var(--clusterMenuBackground), 0 0 0px 6px var(--textColorAccent);
--corner: 0px 0px 0px 1px var(--clusterMenuBackground);
--iconActiveShadow: var(--corner), var(--corner), 0 0 0px 3px var(--clusterMenuBackground), 0 0 0px 6px var(--textColorAccent);
--iconHoverShadow: 0 0 0px 3px var(--clusterMenuBackground), 0 0 0px 6px #ffffff50;
display: flex;
@@ -24,6 +25,10 @@
.avatar {
border-radius: 6px;
&.hasImage {
background-color: var(--clusterMenuCellBackground);
}
}
.active {
@@ -61,7 +61,7 @@ export const HotbarIcon = observer(({ menuItems = [], size = 40, tooltip, ...pro
id={id}
title={title}
colorHash={`${title}-${source}`}
className={cssNames(styles.avatar, { [styles.active]: active })}
className={cssNames(styles.avatar, { [styles.active]: active, [styles.hasImage]: !!src })}
disabled={disabled}
size={size}
src={src}