pissang commented on a change in pull request #16767:
URL: https://github.com/apache/echarts/pull/16767#discussion_r838093092



##########
File path: src/chart/sankey/SankeyView.ts
##########
@@ -193,7 +193,9 @@ class SankeyView extends ChartView {
                 cpy2: cpy2
             });
 
-            curve.useStyle(lineStyleModel.getItemStyle());
+            const style = lineStyleModel.getItemStyle();
+            curve.useStyle(style);
+            edgeData.setItemVisual(idx, 'style', style);

Review comment:
       It's better to put visual logic in `sankeyVisual.ts`

##########
File path: src/chart/sankey/SankeyView.ts
##########
@@ -220,6 +222,15 @@ class SankeyView extends ChartView {
                     }
             }
 
+            setLabelStyle(
+                curve, getLabelStatesModels(edgeModel, 'edgeLabel'),
+                {
+                    labelFetcher: seriesModel,
+                    labelDataIndex: edge.dataIndex,
+                    defaultText: `${edgeModel.get('value')}`

Review comment:
       template string is unnecessary here.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@echarts.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@echarts.apache.org
For additional commands, e-mail: commits-h...@echarts.apache.org

Reply via email to