Update linter

This commit is contained in:
Thomas Nordquist
2020-04-16 10:56:46 +02:00
parent 19e8bfdb37
commit 30af13f793
53 changed files with 92 additions and 97 deletions

View File

@@ -31,7 +31,7 @@ function ColorSettings(props: {
)
const menuItems = React.useMemo(() => {
return colors.map((color) => (
return colors.map(color => (
<MenuItem
style={{ minWidth: '8em', minHeight: '36px', backgroundColor: color, textAlign: 'center' }}
key={color}

View File

@@ -38,7 +38,7 @@ function InterpolationSettings(props: {
}, [curves])
const menuItems = React.useMemo(() => {
return curves.map((curve) => (
return curves.map(curve => (
<MenuItem key={curve} onClick={callbacks[curve]} selected={props.chart.interpolation === curve}>
<Typography variant="inherit">{curve.replace(/_/g, ' ')}</Typography>
</MenuItem>

View File

@@ -58,7 +58,7 @@ function TimeRangeSettings(props: Props) {
>
<Typography>Chart data within a time interval</Typography>
<div style={{ padding: '0 16px', width: '275px', textAlign: 'center' }}>
{ranges.map((r) => {
{ranges.map(r => {
return (
<Button
style={{ margin: '4px', textTransform: 'none' }}

View File

@@ -39,7 +39,7 @@ export function colors() {
indigo,
yellow,
]
.map((color) => [color[200], color[500], color[700]])
.map(color => [color[200], color[500], color[700]])
.reduce((a, b) => a.concat(b), [])
.sort((a, b) => colorCompare(a, b))
return colors

View File

@@ -63,7 +63,7 @@ function ChartPanel(props: Props) {
}
}, [chartsInView])
const charts = props.charts.map((chartParameters) => (
const charts = props.charts.map(chartParameters => (
<CSSTransition
key={`${chartParameters.topic}-${chartParameters.dotPath || ''}`}
timeout={{ enter: 500, exit: 500 }}