1
-
1
+ /// <reference lib="dom" />
2
2
/* eslint-disable no-param-reassign */
3
3
import React , { useEffect } from 'react' ;
4
4
import { BarStack } from '@visx/shape' ;
@@ -20,7 +20,7 @@ import { useStoreContext } from '../../../store';
20
20
import {
21
21
snapshot , TooltipData , Margin , BarGraphComparisonProps , ActionObj , Series ,
22
22
} from '../../FrontendTypes' ;
23
- import { BarStack } from '@visx/shape/lib/types' ;
23
+ // import { BarStack as BarStacks } from '@visx/shape/lib/types';
24
24
25
25
/* DEFAULTS */
26
26
const margin : Margin = {
@@ -70,7 +70,7 @@ const BarGraphComparison = (props: BarGraphComparisonProps): JSX.Element => {
70
70
const getSnapshotId = ( d : snapshot ) => d . snapshotId ;
71
71
const formatSnapshotId = ( id : string ) : string => `Snapshot ID: ${ id } ` ;
72
72
const formatRenderTime = ( time : string ) : string => `${ time } ms ` ;
73
- const getCurrentTab = ( storedSeries : Record < string , unknown > ) => storedSeries . currentTab ;
73
+ const getCurrentTab = ( storedSeries : ActionObj ) => storedSeries . currentTab ;
74
74
75
75
// create visualization SCALES with cleaned data
76
76
// the domain array/xAxisPoints elements will place the bars along the x-axis
@@ -187,7 +187,7 @@ const BarGraphComparison = (props: BarGraphComparisonProps): JSX.Element => {
187
187
188
188
const animateButton = ( e : MouseEvent ) => {
189
189
e . preventDefault ( ) ;
190
- const target = event . target as HTMLButtonElement ;
190
+ const target = ( e . target as HTMLButtonElement ) ;
191
191
if ( target ) {
192
192
target . classList . add ( 'animate' ) ;
193
193
target . innerHTML = 'Deleted!' ;
0 commit comments