You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by "prpanto (via GitHub)" <gi...@apache.org> on 2024/12/11 11:22:26 UTC

[I] Series data dont apply on legend but data exist on series and legend. [echarts]

prpanto opened a new issue, #20577:
URL: https://github.com/apache/echarts/issues/20577

   ### Version
   
   5.5.1
   
   ### Link to Minimal Reproduction
   
   https://example.com/
   
   ### Steps to Reproduce
   
   const option = shallowRef<echarts.EChartsCoreOption>({
     legend: {
       type: 'scroll',
       bottom: '0%',
       left: 'center',
     },
     polar: {
       radius: [50, '60%'],
       startAngle: 90,
     },
     angleAxis: {
       show: false,
     },
     radiusAxis: {
       show: false,
       type: 'category',
     },
     series: {
       name: 'Meters Overview',
       type: 'bar',
       roundCap: true,
       data: {},
       coordinateSystem: 'polar',
       label: {
         show: false,
       },
     },
     graphic: [
       {
         type: 'text',
         left: 'center',
         top: '46%',
         style: {
           text: 'TOTAL',
           textAlign: 'center',
           fontSize: 22,
           fontWeight: 'normal',
           fill: '#6A5ACD',
         }
       },
       {
         type: 'text',
         left: 'center',
         top: '51%',
         style: {
           text: null,
           textAlign: 'center',
           fontSize: 22,
           fontWeight: 'normal',
           fill: '#6A5ACD',
         }
       }
     ]
   })
   
   onMounted(async () => {
     data.value = await fetchData()
   
     const chartData = [
       { name: 'Alarms', value: data.value.alarms, },
       { name: 'Readings', value: data.value.readings, },
       { name: 'Smart', value: data.value.smart, },
     ]
   
     option.value.series.data = chartData
     option.value.legend.data = chartData
     option.value.angleAxis.max = data.value.total
     option.value.graphic[1].style.text = data.value.total
   })
   
   ### Current Behavior
   
   Dont show the legend if series data exist
   
   ### Expected Behavior
   
   Legend must show on the chart
   
   ### Environment
   
   ```markdown
   - OS: Ubuntu
   - Browser: Firefox
   - Framework: Nuxt
   ```
   
   
   ### 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


Re: [I] Series data dont apply on legend but data exist on series and legend. [echarts]

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

   https://echarts.apache.org/en/api.html#echartsInstance.setOption ?


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


Re: [I] Series data dont apply on legend but data exist on series and legend. [echarts]

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

   > https://echarts.apache.org/en/api.html#echartsInstance.setOption ?
   
   I set the option to the chart 


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


Re: [I] Series data dont apply on legend but data exist on series and legend. [echarts]

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

   you are missing _setOption_ command at the end - [Demo](https://echarts.apache.org/examples/en/editor.html?code=PYBwLglsB2AEC8sDeAoWtJgDYFMBcSYOAHmHgOQDGWElA1rDBiWOQL4A0asuA5jtAAmeZN3RgAniHyxyAZ0oAnYFizku6dACNgYMMAC2I8gAYApOrE8cAMzKzKAoovLdO3ECoCGikak2wil6CEACuciIA2gCsJhyyAGzm5AC6GppyYD5gAILQvLgiAJwmbule-bg5xBARogFyABbAAO4iNl5Ycjhl3EEh4dW1flZNre2d3eniUjJUXkS8wIoSruju6N2KEDh1_prQXgZzOVg-BnKWAZLSxlo-V5rKoUIAwl4gImCKoTjTsIIFl4_BtNJRgMsQociABlCSZHBGWSeM4uf5nLQ4LAjAKbZptWAdLo9AJsXroXhBECNWhRKz7a6zYxEUiPAK4OzGRzQZxszT6T6yAAsCQs_02kkK9Vx4hYxgAKgB5eU5AAyfOuLFOEF40C5ThwaKsARsMDAMIgAC8ZAAmG3izSmnkAdRwOsa9nI0GWBk6GsdEFUxgAxAkctEcq8ACJrXFk0n_Bn8pmyFmsB0cz3c3kOgXGaIARjFxtgmQkUqTmtIImgoVUDtlpG1uv1PMN_vQTvNVtt9pLnbNrvdnu9il9agbhMD2NkofDkZjJfjmmXKRQbAA3CgUAYJK9GtkAHQwAAUVBo9HUsBPAEoEAA-aUAegAVNxwdBMrBKAfFGAo0CCCwJE9KwIcxzGKc5yXPEABunS_CIgJZIe8FYL8h6dNBsCgugSBgUccwAEo4MEED5DBsBoYhAJAqhCE4IeiikVCvByDhiYERBsgwr6f5XtRMjIV49HoYxch8WAOHcCkW7cKAkAwKJGFbDsciHsJQE_tkAFZFu6AKVA0DKYxfACIIGmAYg2l_rpXj6Yw4BGS
 ZmGVDgQzqb6xBAcJLn6FkWAOYZSmCYelIfDSlCRAWKSHmWuCHmmPl0aF_mdNwL5PvJTlKeF1K0NFsXxYxSWIOQXgHgAhOQDm7vuR7dGAio5dAJ7BdAN5bmwnVAA)


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