You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by "sober-bruce (via GitHub)" <gi...@apache.org> on 2023/06/08 12:00:40 UTC

[GitHub] [echarts] sober-bruce opened a new issue, #18732: [Bug] 半环形图(饼图),多项为0时,显示的不为一个半环形了。

sober-bruce opened a new issue, #18732:
URL: https://github.com/apache/echarts/issues/18732

   ### Version
   
   5.4.2
   
   ### Link to Minimal Reproduction
   
   https://echarts.apache.org/examples/zh/editor.html?c=pie-half-donut
   
   ### Steps to Reproduce
   
   1、官方实现半环形图,是在最后插入了一条数据(该条数据的value是前面所有项的总和,并把它的color设置成none),这样子就只显示了前面的项,实现了展示半环形的效果。
   2、但是如果前面的项大于1个,并且value都为0,这样就会导致最后一项的value也是0;最后一项就不会占50%了。
   
   ### Current Behavior
   
   1、当项超过1且每项都为0时候,不会展示成半环形状态。
   
   ### Expected Behavior
   
   1、当项超过1且每项都为0时候,展示成半环形状态。
   
   ### Environment
   
   ```markdown
   - OS: Windows 10
   - Browser:Chrome 113.0.5672.129
   - Framework: Vue@3.2.47
   ```
   
   
   ### Any additional comments?
   
   _No response_


-- 
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-unsubscribe@echarts.apache.org.apache.org

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


[GitHub] [echarts] sober-bruce commented on issue #18732: [Bug] 半环形图(饼图),多项为0时,显示的不为一个半环形了。

Posted by "sober-bruce (via GitHub)" <gi...@apache.org>.
sober-bruce commented on issue #18732:
URL: https://github.com/apache/echarts/issues/18732#issuecomment-1582468277

   配置文件信息是:
   option = {
     series: [
       {
         type: 'pie',
         radius: ['40%', '70%'],
         center: ['50%', '55%'],
         startAngle: 180,
         data: [
           { value: 0, name: 'Search Engine' },
           { value: 0, name: 'Direct' },
           {
             value: 0,
             itemStyle: {
               color: 'none',
               decal: {
                 symbol: 'none'
               }
             },
             label: {
               show: false
             }
           }
         ]
       }
     ]
   };


-- 
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-unsubscribe@echarts.apache.org

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


[GitHub] [echarts] echarts-bot[bot] commented on issue #18732: [Bug] 半环形图(饼图),多项为0时,显示的不为一个半环形了。

Posted by "echarts-bot[bot] (via GitHub)" <gi...@apache.org>.
echarts-bot[bot] commented on issue #18732:
URL: https://github.com/apache/echarts/issues/18732#issuecomment-1582454171

   @sober-bruce It seems you are not using English, I've helped translate the content automatically. To make your issue understood by more people and get helped, we'd like to suggest using English next time. 🤗
   <details><summary><b>TRANSLATED</b></summary><br>
   
   **TITLE**
   
   [Bug] In the semi-circular chart (pie chart), when the number of items is 0, the display is no longer a semi-circular chart.
   
   **BODY**
   
   ### Version
   
   5.4.2
   
   ### Link to Minimal Reproduction
   
   https://echarts.apache.org/examples/zh/editor.html?c=pie-half-donut
   
   ### Steps to Reproduce
   
   1. The official implementation of the semi-circular chart is to insert a piece of data at the end (the value of the data is the sum of all the previous items, and its color is set to none), so that only the previous items are displayed, realizing the effect of displaying the semi-ring.
   2. However, if the previous item is greater than 1, and the value is 0, this will cause the value of the last item to be also 0; The last item will not account for 50%.
   
   ### Current Behavior
   
   1. When the item exceeds 1 and each item is 0, it will not be displayed in a semi-circular state.
   
   ### Expected Behavior
   
   1. When the item exceeds 1 and each item is 0, it is displayed in a semi-circular state.
   
   ### Environment
   
   ```markdown
   - OS: Windows 10
   - Browser:Chrome 113.0.5672.129
   - Framework: Vue@3.2.47
   ```
   
   ### Any additional comments?
   
   _No response_
   </details>


-- 
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-unsubscribe@echarts.apache.org

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


[GitHub] [echarts] Ovilia closed issue #18732: [Bug] 半环形图(饼图),多项为0时,显示的不为一个半环形了。

Posted by "Ovilia (via GitHub)" <gi...@apache.org>.
Ovilia closed issue #18732: [Bug] 半环形图(饼图),多项为0时,显示的不为一个半环形了。
URL: https://github.com/apache/echarts/issues/18732


-- 
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-unsubscribe@echarts.apache.org

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


[GitHub] [echarts] sober-bruce commented on issue #18732: [Bug] 半环形图(饼图),多项为0时,显示的不为一个半环形了。

Posted by "sober-bruce (via GitHub)" <gi...@apache.org>.
sober-bruce commented on issue #18732:
URL: https://github.com/apache/echarts/issues/18732#issuecomment-1584174939

   老哥厉害~~
   如果总和为0,就在后面插入n个color为none的项就行(n为数据项个数)


-- 
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-unsubscribe@echarts.apache.org

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