File tree Expand file tree Collapse file tree 5 files changed +19
-10
lines changed Expand file tree Collapse file tree 5 files changed +19
-10
lines changed Original file line number Diff line number Diff line change 38
38
},
39
39
"contributors" : [
40
40
" Abaas Khorrami" ,
41
+ " Ali Rahman" ,
41
42
" Andy Wong" ,
42
43
" Bryan Lee" ,
43
44
" Becca Viner" ,
44
45
" Caitlin Chan" ,
46
+ " Caner Demir" ,
45
47
" Carlos Perez" ,
48
+ " Cole Styron" ,
46
49
" Chris Flannery" ,
47
50
" David Chai" ,
51
+ " Dennis Lopez" ,
48
52
" Edwin Menendez" ,
49
53
" Ergi Shehu" ,
50
54
" Gabriela Jardim Aquino" ,
55
59
" Josh Kim" ,
56
60
" Joshua Howard" ,
57
61
" Kevin Fey" ,
62
+ " Kevin Ngo" ,
58
63
" Kim Mai Nguyen" ,
59
64
" Nathanael Wa Mwenze" ,
60
65
" Prasanna Malla" ,
Original file line number Diff line number Diff line change @@ -141,7 +141,7 @@ const StateRoute = (props: StateRouteProps) => {
141
141
} }
142
142
label = 'LCP'
143
143
name = 'Largest Contentful Paint'
144
- description = 'Time website loads largest content on screen '
144
+ description = 'Measures loading performance. The benchmark is less than 2500 ms. '
145
145
/>
146
146
< WebMetrics
147
147
color = { FIDColor }
@@ -151,23 +151,23 @@ const StateRoute = (props: StateRouteProps) => {
151
151
} }
152
152
label = 'FID'
153
153
name = 'First Input Delay'
154
- description = 'Time from when a user first interacts with your site '
154
+ description = 'Measures interactivity. The benchmark is less than 100 ms. '
155
155
/>
156
156
< WebMetrics
157
157
color = { FCPColor }
158
158
series = { ( webMetrics . FCP / 1000 ) * 100 }
159
159
formatted = { ( val ) => ( ( val / 100 ) * 1000 ) . toFixed ( 2 ) + ' ms' }
160
160
label = 'FCP'
161
161
name = 'First Contentful Paint'
162
- description = 'How long it takes browser to render first piece of DOM content'
162
+ description = 'How long it takes browser to render first piece of DOM content. '
163
163
/>
164
164
< WebMetrics
165
165
color = { TTFBColor }
166
166
series = { ( webMetrics . TTFB / 10 ) * 100 }
167
167
formatted = { ( val ) => ( ( val / 100 ) * 10 ) . toFixed ( 2 ) + ' ms' }
168
168
label = 'TTFB'
169
169
name = 'Time to First Byte'
170
- description = 'Time at which your server sends a response '
170
+ description = 'Measures the time it takes for a browser to receive the first byte of page content. The benchmark is 600 ms. '
171
171
/>
172
172
</ div >
173
173
) ;
Original file line number Diff line number Diff line change @@ -104,9 +104,11 @@ const radialGraph = (props) => {
104
104
</ div >
105
105
</ Trigger >
106
106
< Hover type = 'hover' >
107
- < div id = 'hover-box' >
108
- < p > Metric : { props . name } </ p >
109
- < p > Tracks : { props . description } </ p >
107
+ < div style = { { padding : '0.5rem 1rem' } } id = 'hover-box' >
108
+ < p >
109
+ < strong > { props . name } </ strong >
110
+ </ p >
111
+ < p > { props . description } </ p >
110
112
</ div >
111
113
</ Hover >
112
114
</ ReactHover >
Original file line number Diff line number Diff line change 190
190
grid-template-columns : auto auto ;
191
191
align-items : center ;
192
192
justify-content : center ;
193
- margin-top : 1 rem ;
193
+ margin-top : 25 % ;
194
194
}
195
195
196
196
// container for metrics
Original file line number Diff line number Diff line change @@ -60,8 +60,10 @@ export default (origin, mode) => {
60
60
) ;
61
61
const hookState = Object . values ( hook ) ;
62
62
63
- if ( hooksComponent && hooksComponent . dispatch ) {
64
- hooksComponent . dispatch ( hookState [ 0 ] ) ;
63
+ if ( hooksComponent && hooksComponent . dispatch ) {
64
+ if ( Array . isArray ( hookState [ 0 ] ) && hookState [ 0 ] . length > 0 || ! Array . isArray ( hookState [ 0 ] ) ) {
65
+ hooksComponent . dispatch ( hookState [ 0 ] ) ;
66
+ }
65
67
}
66
68
} ) ;
67
69
}
You can’t perform that action at this time.
0 commit comments