dvago opened a new issue #10724: Responsive SVG rendered charts URL: https://github.com/apache/incubator-echarts/issues/10724 ### What problem does this feature solve? Hardcoded values within the width and the height attributes of an SVG make the chart not responsive. Changing the way the SVG is being printed out could remove an extra DOM element and make developers capable to work with the SVG chart via CSS without using hacks to edit the rendered element via javascript. ### What does the proposed API look like? Following up the closed issue: ecomfe/vue-echarts#355 Given the charts generated as SVG, could it be possible to clean up the rendered html? In order to render the chart in a responsive way the generated DIV which wraps the SVG tag could be completely removed and the SVG tag could have the width and height attributes replaced by the viewBox Eg. given width and height from the initOptions instead of printing out: width="250" height="70" the output could be viewBox="0 0 250 70" so the developer/user could define via CSS the wanted sizing ref. <img width="902" alt="Screenshot 2019-06-24 at 13 41 11" src="https://user-images.githubusercontent.com/5074033/60019519-f6fb6c80-9685-11e9-87a2-764e7135e92c.png"> <!-- 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. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
