{"version":"1.0","type":"rich","title":"Responsive Margin Convention","description":"This example shows a reusable pattern for building responsive visualizations that maintain consistent margins as the window resizes. It uses the `d3` library (v5) to render an SVG with a rounded rectangle that fills the available space within the specified margin. The `marginConvention` function translates a group element to the margin offset and calculates the inner dimensions, while the `index.js` file re-renders on window resize. The code demonstrates the classic D3 margin convention, using `d3.select` and SVG attributes like `width`, `height`, and `transform`.","provider_name":"VizHub AI Studio","provider_url":"https://vizhub.com","html":"<iframe src=\"https://vizhub.com/viz/a06a7f571f4b4fd9900a04a4387c90b3?mode=embed\" width=\"960\" height=\"500\" scrolling=\"no\" frameborder=\"0\"></iframe>","width":960,"height":500,"cache_age":3600}