Home › Forums › Support › SVG Hero Animation This topic has 9 replies, 2 voices, and was last updated 2 years ago by Graham. Viewing 10 posts - 1 through 10 (of 10 total) Author Posts March 9, 2022 at 9:41 am #2148481 Graham Hello, I wanted to add a SVG bg to the hero section of one of my pages. I have the animated .svg file. How should I go about doing this? March 9, 2022 at 11:08 am #2148585 YingStaff Customer Support Hi Graham, Are you using a block element – page hero to make the hero section? https://docs.generatepress.com/article/block-element-page-hero/ If so, you can upload the SVG to your media library, then choose it as the background image of your GB container block: https://docs.generateblocks.com/article/container-overview/#backgrounds March 9, 2022 at 11:40 am #2148615 Graham Hi Ying, Yes, the issue is that the BG or the overall image size is to large: https://dropdeskstage.wpengine.com/services so it gets cut off. What’s the best way to make the svg visibly smaller? March 9, 2022 at 11:48 am #2148633 Graham I want the animation to be contained in the hero section. I saw that you can do this via CSS background-size: contain; Just dont know where to place this March 9, 2022 at 11:54 am #2148641 YingStaff Customer Support In GB container’s background settings, you can set background size to contain, no CSS is needed: https://docs.generateblocks.com/article/container-overview/#image-size March 9, 2022 at 12:04 pm #2148657 Graham https://www.loom.com/share/24e7341433b6456a96ea77674142a5c2 March 9, 2022 at 12:30 pm #2148696 YingStaff Customer Support In your case, set the background image to the first container is the way to go. But you might want to make the container width/height ratio to match the SVG’s aspect ratio. Try tweak the top/bottom padding for the first container using % as the unit. March 9, 2022 at 12:45 pm #2148715 Graham thx it seems to work March 9, 2022 at 12:52 pm #2148723 YingStaff Customer Support Glad to hear that 🙂 March 9, 2022 at 1:58 pm #2148765 Graham thx Author Posts Viewing 10 posts - 1 through 10 (of 10 total) You must be logged in to reply to this topic. Log In Username: Password: Keep me signed in Log In