ACE-IoT-Solutions / ace-svg-react

Grafana SVG Rendering Panel using the 7+ Plugin Framework
https://grafana.com/grafana/plugins/aceiot-svg-panel/
MIT License
41 stars 14 forks source link

Ensure SVG is sized to panel and centered #1

Closed svet-b closed 4 years ago

svet-b commented 4 years ago

This involves two changes: 1) To ensures that the SVG does not overflow the panel vertically, in cases where it is taller than the panel 2) To center the SVG in the panel (via CSS)

acedrew commented 4 years ago

@svet-b Can you try a clean pull of main? I think it does everything you need just using CSS, without the additional JS. I also moved the css into an inline style to avoid generating classes on resize.

svet-b commented 4 years ago

@acedrew thanks - will do that! As I said, I had serious doubts as to whether my approach to solving the issues I was having was particularly sensible...

svet-b commented 4 years ago

You're right, what you've got there is better!