You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by "Lazydd (via GitHub)" <gi...@apache.org> on 2023/11/30 07:51:58 UTC

[I] [Feature] Add an attribute, `title`, to the legend? [echarts]

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

   ### What problem does this feature solve?
   
   When the text is too long, I will cut it off and move the mouse up and it will display the title. If empty, do not display. Similar to the title attribute in html
   
   ### What does the proposed API look like?
   
   ```
   legend:{
      title: 'this is title'
   }
   ```


-- 
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] [Feature] Add an attribute, `title`, to the legend? [echarts]

Posted by "plainheart (via GitHub)" <gi...@apache.org>.
plainheart closed issue #19345: [Feature] Add an attribute, `title`, to the legend?
URL: https://github.com/apache/echarts/issues/19345


-- 
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] [Feature] Add an attribute, `title`, to the legend? [echarts]

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

   try [this](https://echarts.apache.org/examples/en/editor.html?c=line-simple&code=PYBwLglsB2AEC8sDeAoWsAeBBDEDOAXMmurGAJ4gCmRA5AMYCGYVA5sAE7m0A0J6AE2aMiAbVoBZGL1i0AKgFcqM2gHUqAlXIAWClQDEOEFQGVmphdFoBdEgF8-6cjnxEksByTxUjVQrFF-ZFhoRgBbGloAGwhoKlgALyTklNSk3iDBYTEARgBWAAYeWAAmAGYi0pKAFmKSnIAOYpyyvObqgHY6gDYC60dSdApqOhi42iDPQfR3UIiCaNj4gCNVtfWM6dghMBEAwuKKutrYRsO22E7i3v7MskoaWTHlSZJb9Ci2KmgBAndPgBmYAW1QKAFJaB5iiRIGBPn88ApliwMMDol8fmQIHDIsVsVQwgBxRggAiVIysbRo3oQuwoOwAbiAA)


-- 
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] [Feature] Add an attribute, `title`, to the legend? [echarts]

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

   1. Do it with pure HTML/CSS rather than the title component of ECharts
   2. Listen to the `mouseover` event of the chart and set the title when it's overflowed. [Demo](https://echarts.apache.org/examples/editor.html?c=line-simple&code=PYBwLglsB2AEC8sDeAoWtJgDYFMBcya6GOAHmAQOQAqAFhAM6yOwCGsWMA5h979D0y5KAGiLowAJwhcuOSQFEAbjmgUMkgK44xxEuQDKYAJ64CqPegDuEACZhaBAEwAGF7svAVkgGacrVFKa0ADGrGA4lOKwAL5EMR6kAIKkjObRJiD4sJRhEVzAksai0bbhrAQA2pQAsjCiOdTaDZQA6ji2LXSaLQBi0i0G4YPBlAC68R7GKWmEepnZlEqsWM2TRAzyEDgMVdEWlmVgFbCVAIwArO6wTgDM105OACwiN2cAHK9ntxdfTwDsrycADYXGMPPNjFkqFgINBItE4ugJjEANwoFAAW2MAGFaKxJGAAHQwAAUlExwE0my88gapJwAEoEAA-OawEIwBhgDn4wk4mDHOHyBCwbF4gnEuRgAAiwExpMZ6PQEB8sAZRM5mJAMFUYGoUJwsAAhPBEJQhJFmQd0CE-WABWpWMLJETLaLKJRlcRJDgwJpJNBvUiOVyeT5NFgsNQINgjYhQJAYG7Y7g3WQwN7OdBubAcFGICAGBAAF4dUU4Ik4FRqN0E6VE7mmSsRcgms2wCNRmNxrP2x1C-Gu92IfOwoul8sAfk7kejqaNVC9KBiSox4vtJOg5Mp1JwVLA9KZrPZ2dzdslA-dQ9FG8lROlcoVa5Vao1Wp18LUBqyCA7FoXShrWiC9-UFa95BTOMPWXdA4lXVEgA)


-- 
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] [Feature] Add an attribute, `title`, to the legend? [echarts]

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

   You may try to do it with pure HTML/CSS rather than the legend component of ECharts. Refer to this [demo](https://codepen.io/plainheart/pen/xxJRdam).
   


-- 
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] [Feature] Add an attribute, `title`, to the legend? [echarts]

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

   > You may try to do it with pure HTML/CSS rather than the legend component of ECharts. Refer to this [demo](https://codepen.io/plainheart/pen/xxJRdam).
   
   It would be nice if it could be written like this
   ```
   formatter(name){
      return `<h1>${name}</h1>`
   }
   ```


-- 
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] [Feature] Add an attribute, `title`, to the legend? [echarts]

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

   The legend component can't accept the HTML parameter for now and we have no plan to support it yet. It's easy enough to use ECharts instance API and HTML to make customized legends.


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