Skip to content

Commit

Permalink
fix dark download and save buttons
Browse files Browse the repository at this point in the history
  • Loading branch information
sumn2u committed Jul 28, 2024
1 parent bd40461 commit bcc541c
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions client/src/workspace/HeaderButton/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@ const ButtonInnerContent = styled("div")(({ theme }) => ({
flexDirection: "column",
}))
const IconContainer = styled("div")(({defaultTheme, theme, textHidden, disabled }) => ({
color: disabled
color: disabled && theme === "light"
? defaultTheme.palette.action.disabled
: theme === "dark"
: theme === "dark" && !disabled
? colors.grey[200]
: colors.grey[700],
height: textHidden ? 32 : 20,
Expand All @@ -48,10 +48,10 @@ const IconContainer = styled("div")(({defaultTheme, theme, textHidden, disabled
const Text = styled("div")(({ defaultTheme, theme, disabled }) => ({
fontWeight: "bold",
fontSize: 11,
color: disabled
color: disabled && theme === "light"
? defaultTheme.palette.action.disabled
: theme === "dark"
? colors.grey[200]
: theme === "dark" && !disabled
? colors.grey[300]
: colors.grey[700],
display: "flex",
alignItems: "center",
Expand All @@ -70,6 +70,7 @@ export const HeaderButton = ({
const customIconMapping = useIconDictionary()
const isSmallDevice = useMediaQuery(defaultTheme.breakpoints.down("sm"))
const { theme } = useTheme();
console.log(defaultTheme, theme, 'defaultTheme')
return (
<ThemeProvider theme={defaultTheme}>
<StyledButton onClick={onClick} disabled={disabled}>
Expand Down

0 comments on commit bcc541c

Please sign in to comment.