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/09/06 11:27:38 UTC

[GitHub] [echarts] YYL1999 opened a new issue #15682: when click custom view to triggle legendChange but the custom view position also changed

YYL1999 opened a new issue #15682:
URL: https://github.com/apache/echarts/issues/15682


   ### Version
   5.0.2
   
   ### Steps to reproduce
   1. use spec like that
   ```
   const click = (series) => {
        myChart.dispatchAction({
         type: 'legendToggleSelect',
         name: series,
       })
   }
   option = {
       "textStyle": {
           "fontFamily": "PingFang SC, microsoft yahei, helvetica neue, San Francisco, arial, sans-serif"
       },
       "color": [
           "#0052D9",
           "#ED7B2F"
       ],
       "title": {
           "show": true,
           "text": "性别环图",
           "top": 32,
           "left": 32,
           "padding": 0,
           "itemGap": 0,
           "textStyle": {
               "color": "#191919",
               "fontSize": 18,
               "fontWeight": "bold"
           }
       },
       "legend": {
           "show": false
       },
       "dataset": {
           "source": [
               [
                   "性别",
                   "男生",
                   "女生"
               ],
               [
                   "数量",
                   91,
                   9
               ]
           ]
       },
       "tooltip": {
           "show": true,
           "padding": [
               15,
               16,
               15,
               16
           ],
           "axisPointer": {
               "lineStyle": {
                   "color": "rgba(0,0,0,0.1)"
               },
               "shadowStyle": {
                   "color": "rgba(0,0,0,0.03)"
               },
               "z": 0
           },
           "backgroundColor": "rgba(255,255,255,0.95)",
           "textStyle": {
               "color": "#666666",
               "fontSize": 12
           },
           "extraCssText": "max-width: 100%; box-sizing: border-box; white-space: normal; line-height: 1.25; border-radius: 0; box-shadow: 0 15px 30px 0 rgba(0,0,0,0.14);"
       },
       "graphic": [
           {
               "type": "group",
               "bottom": "middle",
               "right": "85%",
               "onclick": () => click('男生'),
               "children": [
                   {
                       "type": "group",
                       "children": [
                           {
                               "type": "text",
                               "right": "0",
                               "style": {
                                   "text": "男生",
                                   "fontSize": "14px",
                                   "fill": "#4D4D4D"
                               }
                           },
                           {
                               "type": "group",
                               "top": "40",
                               "right": "0",
                               "children": [
                                   {
                                       "type": "text",
                                       "right": "0",
                                       "style": {
                                           "text": 91,
                                           "fontSize": "26px",
                                           "textAlign": "center",
                                           "fill": "#333333"
                                       }
                                   },
                                   {
                                       "type": "text",
                                       "top": "14",
                                       "left": "0",
                                       "style": {
                                           "text": "%",
                                           "fontSize": "12px",
                                           "textAlign": "center",
                                           "fill": "#333333"
                                       }
                                   }
                               ]
                           },
                           {
                               "type": "image",
                               "left": "10",
                               "style": {
                                   "image": "https://vfiles.gtimg.cn/vupload/20210811/f491801628670752246.svg",
                                   "fill": "#0052D9"
                               }
                           }
                       ]
                   }
               ]
           },
           {
               "type": "group",
               "bottom": "middle",
               "left": "80%",
                           "onclick": () => click('女生'),
               "children": [
                   {
                       "type": "group",
                       "children": [
                           {
                               "type": "image",
                               "right": "0",
                               "style": {
                                   "image": "https://vfiles.gtimg.cn/vupload/20210811/e3f8f41628670772782.svg",
                                   "fill": "#ED7B2F"
                               }
                           },
                           {
                               "type": "text",
                               "left": "30px",
                               "style": {
                                   "text": "女生",
                                   "fontSize": "14px",
                                   "fill": "#4D4D4D"
                               }
                           },
                           {
                               "type": "group",
                               "left": "30px",
                               "top": "40",
                               "children": [
                                   {
                                       "type": "text",
                                       "right": "0",
                                       "style": {
                                           "text": 9,
                                           "fontSize": "26px",
                                           "fill": "#333333"
                                       }
                                   },
                                   {
                                       "type": "text",
                                       "left": "0",
                                       "top": "14",
                                       "style": {
                                           "left": "0",
                                           "text": "%",
                                           "fontSize": "12px",
                                           "textAlign": "center",
                                           "fill": "#333333"
                                       }
                                   }
                               ]
                           }
                       ]
                   }
               ]
           }
       ],
       "series": [
           {
               "type": "pie",
               "seriesLayoutBy": "row",
               "selectedMode": "single",
               "itemStyle": {
                   "borderWidth": 1.5,
                   "borderColor": "#FFFFFF"
               },
               "radius": [
                   "40%",
                   "60%"
               ],
               "center": [
                   "50%",
                   "50%"
               ],
               "label": {
                   "color": "rgba(0,0,0,.3)",
                   "formatter": "{d}%"
               },
               "labelLine": {
                   "show": false,
                   "length": 4,
                   "length2": 4
               }
           }
       ]
   }
   ```
   2. click custom view (旁边小人)
   3. cutsom view position changed
   
   ### What is expected?
   custom view position not change
   
   ### What is actually happening?
   position changed
   
   <!-- This issue is generated by echarts-issue-helper. DO NOT REMOVE -->
   <!-- This issue is in English. DO NOT REMOVE -->


-- 
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 #15682: when click custom view to triggle legendChange but the custom view position also changed

Posted by GitBox <gi...@apache.org>.
echarts-bot[bot] commented on issue #15682:
URL: https://github.com/apache/echarts/issues/15682#issuecomment-913573538


   Hi! We've received your issue and please be patient to get responded. 🎉
   The average response time is expected to be within one day for weekdays.
   
   In the meanwhile, please make sure that it contains **a minimum reproducible demo** and necessary **images** to illustrate. Otherwise, our committers will ask you to do so.
   
   *A minimum reproducible demo* should contain as little data and components as possible but can still illustrate your problem. This is the best way for us to reproduce it and solve the problem faster.
   
   You may also check out the [API](http://echarts.apache.org/api.html) and [chart option](http://echarts.apache.org/option.html) to get the answer.
   
   If you don't get helped for a long time (over a week) or have an urgent question to ask, you may also send an email to dev@echarts.apache.org. Please attach the issue link if it's a technical question.
   
   If you are interested in the project, you may also subscribe to our [mailing list](https://echarts.apache.org/en/maillist.html).
   
   Have a nice day! 🍵


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