To scale charts based on outer Elements viewbox attribute needs to be set. So a viewbox property should be rendered in the svg.