Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
100pah committed Oct 29, 2018
2 parents 0357b08 + ef9cf76 commit 5a3a3d2
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
8 changes: 8 additions & 0 deletions src/chart/sunburst/SunburstPiece.js
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,8 @@ SunburstPieceProto.updateData = function (

var visualColor = getNodeColor(node, seriesModel, ecModel);

fillDefaultColor(node, seriesModel, visualColor)

var normalStyle = itemModel.getModel('itemStyle').getItemStyle();
var style;
if (state === 'normal') {
Expand Down Expand Up @@ -411,3 +413,9 @@ function isNodeHighlighted(node, activeNode, policy) {
return node === activeNode || node.isDescendantOf(activeNode);
}
}

// Fix tooltip callback function params.color incorrect when pick a default color
function fillDefaultColor(node, seriesModel, color) {
var data = seriesModel.getData();
data.setItemVisual(node.dataIndex, 'color', color);
}
2 changes: 1 addition & 1 deletion src/coord/geo/Geo.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ function Geo(name, map, nameMap, invertLongitute) {
var source = geoSourceManager.load(map, nameMap);

this._nameCoordMap = source.nameCoordMap;
this._regionsMap = source.nameCoordMap;
this._regionsMap = source.regionsMap;
this._invertLongitute = invertLongitute == null ? true : invertLongitute;

/**
Expand Down

0 comments on commit 5a3a3d2

Please sign in to comment.