Skip to content

Commit

Permalink
make marker.line.width dflt 1
Browse files Browse the repository at this point in the history
... and use paper_bgcolor for marker.line.color dflt
  • Loading branch information
etpinard committed Mar 4, 2019
1 parent a1d9b2b commit c1ccad6
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 4 deletions.
10 changes: 8 additions & 2 deletions src/traces/sunburst/attributes.js
Original file line number Diff line number Diff line change
Expand Up @@ -100,8 +100,14 @@ module.exports = {
// },

line: {
color: pieAtts.marker.line.color,
width: pieAtts.marker.line.width,
color: extendFlat({}, pieAtts.marker.line.color, {
dflt: null,
description: [
'Sets the color of the line enclosing each sector.',
'Defaults to the `paper_bgcolor` value.'
].join(' ')
}),
width: extendFlat({}, pieAtts.marker.line.width, {dflt: 1}),
editType: 'calc'
},
editType: 'calc'
Expand Down
2 changes: 1 addition & 1 deletion src/traces/sunburst/defaults.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ module.exports = function supplyDefaults(traceIn, traceOut, defaultColor, layout
coerce('maxdepth');

var lineWidth = coerce('marker.line.width');
if(lineWidth) coerce('marker.line.color');
if(lineWidth) coerce('marker.line.color', layout.paper_bgcolor);

coerce('marker.colors');

Expand Down
Binary file modified test/image/baselines/sunburst_coffee.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/sunburst_first.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/sunburst_flare.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/sunburst_values.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 2 additions & 1 deletion test/image/mocks/sunburst_values.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@
"xanchor": "center",
"y": 1.1,
"yanchor": "bottom"
}]
}],

"paper_bgcolor": "#d3d3d3"
}
}

0 comments on commit c1ccad6

Please sign in to comment.