You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by GitBox <gi...@apache.org> on 2021/02/01 05:14:03 UTC

[GitHub] [echarts] pissang commented on a change in pull request #14165: fix(gauge) #14131 Pointer can not display when icon is image

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



##########
File path: src/chart/gauge/GaugeView.ts
##########
@@ -476,8 +477,8 @@ class GaugeView extends ChartView {
                 const itemModel = data.getItemModel<GaugeDataItemOption>(idx);
                 const emphasisModel = itemModel.getModel('emphasis');
                 if (showPointer) {
-                    const pointer = data.getItemGraphicEl(idx) as PointerPath;
-                    pointer.useStyle(data.getItemVisual(idx, 'style'));
+                    const pointer = data.getItemGraphicEl(idx) as Displayable;
+                    pointer.type !== 'image' && pointer.useStyle(data.getItemVisual(idx, 'style'));

Review comment:
       image also need to `useStyle` to clear style.
   
   Here is a reference https://github.com/apache/echarts/blob/master/src/chart/helper/Symbol.ts#L275




----------------------------------------------------------------
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.

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



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