zalando / tech-radar

Visualizing our technology choices
https://opensource.zalando.com/tech-radar/
MIT License
1.6k stars 622 forks source link

add: config.scale option #135

Closed netpyoung closed 7 months ago

netpyoung commented 8 months ago

It will be good to support config.scale option for small size radar. It produces 700/500 size radar from 1400/1000.

radar_visualization({
  svg_id: "radar",
  width: 1400,
  height: 1000,
  scale: 0.5,   ;; <<----
bocytko commented 7 months ago

Thanks for the PR!

The two screenshots below showcase the value of scaling (here: with scale 1.5). If just the width/height is increased, the radar is just shifted to the center leaving a lot of whitespace:

without-scale

The scale attribute scales the radar SVG to occupy the full dimensions:

with-scale