File tree Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -26,15 +26,18 @@ module.exports = function style(gd) {
26
26
. each ( function ( d ) {
27
27
var el = d3 . select ( this ) ;
28
28
var pt = el . selectAll ( 'path.point' ) ;
29
+ var trace = d . trace || d [ 0 ] . trace ;
29
30
30
- pt . call ( Drawing . pointStyle , d . trace || d [ 0 ] . trace ) ;
31
+ pt . call ( Drawing . pointStyle , trace ) ;
31
32
32
- pt . each ( function ( cd ) {
33
- d3 . select ( this ) . classed ( 'plotly-customdata' , cd . data !== null && cd . data !== undefined ) ;
34
- } ) ;
33
+ if ( trace . customdata ) {
34
+ pt . each ( function ( cd ) {
35
+ d3 . select ( this ) . classed ( 'plotly-customdata' , cd . data !== null && cd . data !== undefined ) ;
36
+ } ) ;
37
+ }
35
38
36
39
el . selectAll ( 'text' )
37
- . call ( Drawing . textPointStyle , d . trace || d [ 0 ] . trace ) ;
40
+ . call ( Drawing . textPointStyle , trace ) ;
38
41
} ) ;
39
42
40
43
s . selectAll ( 'g.trace path.js-line' )
You can’t perform that action at this time.
0 commit comments