restore hover effect from commafeed v2

This commit is contained in:
Athou
2023-04-27 07:57:09 +02:00
parent 9ccc26b0b0
commit 4bea1c5e5c

View File

@@ -32,6 +32,11 @@ const useStyles = createStyles((theme, props: FeedEntryProps & { viewMode?: View
if (props.viewMode === "title") mobileMarginY = 2
else if (props.viewMode === "cozy") mobileMarginY = 4
let backgroundHoverColor = backgroundColor
if (!props.expanded) {
backgroundHoverColor = theme.colorScheme === "dark" ? theme.colors.dark[7] : theme.colors.gray[0]
}
const styles = {
paper: {
backgroundColor,
@@ -41,6 +46,9 @@ const useStyles = createStyles((theme, props: FeedEntryProps & { viewMode?: View
marginTop: mobileMarginY,
marginBottom: mobileMarginY,
},
"&:hover": {
backgroundColor: backgroundHoverColor,
},
},
body: {
maxWidth: Constants.layout.entryMaxWidth,