Skip to content

Commit

Permalink
Fix dropdown color
Browse files Browse the repository at this point in the history
  • Loading branch information
spaaaacccee committed Feb 19, 2024
1 parent 03035fb commit c4ff4e0
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions client/src/components/app-bar/FeaturePickerButton.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { KeyboardArrowDownOutlined } from "@mui/icons-material";
import { Box, Button, ButtonProps } from "@mui/material";
import { Box, Button, ButtonProps, useTheme } from "@mui/material";
import { Props } from "./FeaturePicker";

export function FeaturePickerButton({
Expand All @@ -8,6 +8,7 @@ export function FeaturePickerButton({
showArrow,
...props
}: ButtonProps & Pick<Props, "icon" | "showArrow">) {
const theme = useTheme();
return (
<Button
{...props}
Expand All @@ -21,7 +22,8 @@ export function FeaturePickerButton({
<KeyboardArrowDownOutlined
sx={{
ml: -0.5,
color: "text.primary",
// For some reason this color must be explicit
color: theme.palette.text.primary,
opacity: (t) =>
props.disabled ? t.palette.action.disabledOpacity : 1,
}}
Expand All @@ -31,7 +33,7 @@ export function FeaturePickerButton({
>
<Box
sx={{
color: "text.primary",
color: (t) => t.palette.text.primary,
opacity: (t) =>
props.disabled ? t.palette.action.disabledOpacity : 1,
}}
Expand Down

0 comments on commit c4ff4e0

Please sign in to comment.