|
@@ -129,6 +129,7 @@ const GraphCases: React.FC<Props> = ({ countries }) => {
|
|
|
yAxisId="left"
|
|
yAxisId="left"
|
|
|
dot={false}
|
|
dot={false}
|
|
|
strokeWidth={2}
|
|
strokeWidth={2}
|
|
|
|
|
+ isAnimationActive={false}
|
|
|
/>
|
|
/>
|
|
|
))}
|
|
))}
|
|
|
{enabledCountries.map(({ country, color }) => (
|
|
{enabledCountries.map(({ country, color }) => (
|
|
@@ -139,6 +140,7 @@ const GraphCases: React.FC<Props> = ({ countries }) => {
|
|
|
stroke={lighten(0.1)(color)}
|
|
stroke={lighten(0.1)(color)}
|
|
|
yAxisId="left"
|
|
yAxisId="left"
|
|
|
dot={false}
|
|
dot={false}
|
|
|
|
|
+ isAnimationActive={false}
|
|
|
/>
|
|
/>
|
|
|
))}
|
|
))}
|
|
|
</LineChart>
|
|
</LineChart>
|
|
@@ -150,7 +152,10 @@ const GraphCases: React.FC<Props> = ({ countries }) => {
|
|
|
type="checkbox"
|
|
type="checkbox"
|
|
|
checked={enabledList[country] !== false}
|
|
checked={enabledList[country] !== false}
|
|
|
onChange={(): void =>
|
|
onChange={(): void =>
|
|
|
- setEnabledList((last: EnabledList) => ({ ...last, [country]: !last[country] }))
|
|
|
|
|
|
|
+ setEnabledList((last: EnabledList) => ({
|
|
|
|
|
+ ...last,
|
|
|
|
|
+ [country]: last[country] === false,
|
|
|
|
|
+ }))
|
|
|
}
|
|
}
|
|
|
/>
|
|
/>
|
|
|
{country}{' '}
|
|
{country}{' '}
|