Archived topic
Changing the spacing on mobile in a single container
5 replies · Started by Sue on June 17, 2022
When I view my site on mobile, there is a lot of white space to the left & right of the shortcode block (which I'm using with a slide show plugin). I tried setting the margins to 0 using the Mobile Spacing selection of the editing screen, but it didn't help. I only want to remove the margins around the slide show, not the text which follows. Do I need to add custom CSS? Thanks!
Hi there,
Are you referring to this space here?
https://www.screencast.com/t/d1i39o3ks
If so that would be the 30px of mobile content padding set in the customizer:
https://docs.generatepress.com/article/content-padding/
I would not recommend removing that as it will make the text below the portrait sit right against the screen.
No -- just the spacing around the slide show (where I've drawn the red arrows).
Can you:
1. Switch the site structure from Float to Flex in Customizer > General:
https://docs.generatepress.com/article/switching-from-floats-to-flexbox/
2. Then use the Contained content container for the home page:
https://docs.generatepress.com/article/content-container/
https://docs.generatepress.com/article/layout-metabox-overview/#where-is-it
Great -- that worked! Thanks.
No problem :)