@@ -9,6 +9,7 @@ import { useTooltip, useTooltipInPortal, defaultStyles } from '@visx/tooltip';
9
9
import { Text } from '@visx/text' ;
10
10
import { schemeSet3 } from 'd3-scale-chromatic' ;
11
11
import snapshots from './snapshots' ;
12
+ import { onHover , onHoverExit } from '../actions/actions'
12
13
13
14
/* NOTES
14
15
Issue - Not fully compatible with recoil apps. Reference the recoil-todo-test.
@@ -112,6 +113,7 @@ const PerformanceVisx = (props: BarStackProps) => {
112
113
const { width, height, snapshots, hierarchy } = props ;
113
114
114
115
console . log ( 'snapshots' , snapshots ) ;
116
+ console . log ( 'hierarchy' , hierarchy )
115
117
116
118
const {
117
119
tooltipOpen, tooltipLeft, tooltipTop, tooltipData, hideTooltip, showTooltip,
@@ -124,8 +126,12 @@ const PerformanceVisx = (props: BarStackProps) => {
124
126
// filter and structure incoming data for VISX
125
127
const data = getPerfMetrics ( snapshots , getSnapshotIds ( hierarchy ) ) ;
126
128
const keys = Object . keys ( data [ 0 ] ) . filter ( d => d !== 'snapshotId' ) ;
127
- const allComponentStates = traverse ( snapshots [ - 1 ] , 'getComponentType' ) ;
128
- const allComponentRtids = traverse ( snapshots [ - 1 ] , 'getRtids' ) ;
129
+ const allComponentStates = traverse ( snapshots [ 0 ] , 'getComponentType' ) ;
130
+ const allComponentRtids = traverse ( snapshots [ snapshots . length - 1 ] , 'getRtid' ) ;
131
+
132
+ console . log ( 'data' , data )
133
+ console . log ( 'allComponentState' , allComponentStates )
134
+ console . log ( 'allComponentRtids' , allComponentRtids )
129
135
130
136
// create array of total render times for each snapshot
131
137
const totalRenderArr = data . reduce ( ( totalRender , curSnapshot ) => {
0 commit comments