Ovilia commented on a change in pull request #9210: fix #9182 Graph    
label.rotate is invalid
URL: https://github.com/apache/incubator-echarts/pull/9210#discussion_r225117612
 
 

 ##########
 File path: src/chart/graph/GraphView.js
 ##########
 @@ -202,6 +202,8 @@ export default echarts.extendChartView({
         var cy = data.getLayout('cy');
         var labelRotate = seriesModel.get('label.rotate') || 0;
         data.eachItemGraphicEl(function (el, idx) {
+            var itemModel = data.getItemModel(idx);
+            labelRotate = itemModel.get('label.rotate') || labelRotate;
 
 Review comment:
   If `itemModel.get('label.rotate')` is set to be `0`, it will use 
`labelRotate`. But in fact, we wish it to be `0`.
   It should be something like
   ```js
   var itemRotate = itemModel.get('label.rotate');
   if (itemRotate != undefined) {
       labelRotate = itemRotate;
   }
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to