From 8659693490fffa62fb149ec556ea9ac403520738 Mon Sep 17 00:00:00 2001 From: Brandon Farmer Date: Tue, 10 Apr 2018 10:47:55 -0700 Subject: [PATCH] Add types to threshold events --- ui/src/dashboards/components/Threshold.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ui/src/dashboards/components/Threshold.tsx b/ui/src/dashboards/components/Threshold.tsx index cad84c177b..f2d3984520 100644 --- a/ui/src/dashboards/components/Threshold.tsx +++ b/ui/src/dashboards/components/Threshold.tsx @@ -1,4 +1,4 @@ -import React, {PureComponent} from 'react' +import React, {PureComponent, ChangeEvent} from 'react' import ColorDropdown from 'src/shared/components/ColorDropdown' import {THRESHOLD_COLORS} from 'src/shared/constants/thresholds' @@ -134,7 +134,7 @@ class Threshold extends PureComponent { return label } - private handleChangeWorkingValue = e => { + private handleChangeWorkingValue = (e: ChangeEvent) => { const {threshold, onValidateColorValue} = this.props const targetValue = Number(e.target.value) @@ -154,7 +154,7 @@ class Threshold extends PureComponent { } } - private handleKeyUp = e => { + private handleKeyUp = (e: KeyboardEvent) => { if (e.key === 'Enter') { this.thresholdInputRef.blur() }