diff --git a/src/components/BMDashboard/WeeklyProjectSummary/GroupedBarGraphInjurySeverity/InjuryCategoryBarChart.jsx b/src/components/BMDashboard/WeeklyProjectSummary/GroupedBarGraphInjurySeverity/InjuryCategoryBarChart.jsx index 38b7820ee2..db52e8def1 100644 --- a/src/components/BMDashboard/WeeklyProjectSummary/GroupedBarGraphInjurySeverity/InjuryCategoryBarChart.jsx +++ b/src/components/BMDashboard/WeeklyProjectSummary/GroupedBarGraphInjurySeverity/InjuryCategoryBarChart.jsx @@ -8,7 +8,6 @@ import { Legend, LabelList, ResponsiveContainer, - CartesianGrid, } from 'recharts'; import Select from 'react-select'; import DatePicker from 'react-datepicker'; @@ -142,39 +141,38 @@ function InjuryCategoryBarChart() { '#38BDF8', // cyan ]; - const selectStyles = darkMode - ? { - control: base => ({ - ...base, - backgroundColor: '#2b3e59', - color: 'white', - }), - menu: base => ({ - ...base, - backgroundColor: '#2b3e59', - color: 'white', - }), - option: (base, state) => ({ - ...base, - color: 'white', - backgroundColor: state.isSelected - ? 'rgba(255, 255, 255, 0.15)' - : state.isFocused - ? 'rgba(255, 255, 255, 0.1)' - : 'transparent', - '&:active': { - backgroundColor: 'rgba(255, 255, 255, 0.2)', - }, - }), - singleValue: base => ({ - ...base, - color: 'white', - }), - } - : {}; + const selectStyles = darkMode && { + control: base => ({ + ...base, + backgroundColor: '#2b3e59', + color: 'white', + }), + menu: base => ({ + ...base, + backgroundColor: '#2b3e59', + color: 'white', + }), + option: (base, state) => ({ + ...base, + color: 'white', + backgroundColor: state.isSelected + ? 'rgba(255, 255, 255, 0.15)' + : state.isFocused + ? 'rgba(255, 255, 255, 0.1)' + : 'transparent', + '&:active': { + backgroundColor: 'rgba(255, 255, 255, 0.2)', + }, + }), + singleValue: base => ({ + ...base, + color: 'white', + }), + }; + // : {}; return ( -
Loading…
} {!loading && error &&Error: {String(error)}
} - {!loading && !error && ( -