dotandpeg Posted February 15 Posted February 15 Hi, I need some help to remove the padding around a video and making the video fill the video block. Is that possible? https://chameleon-copper-hgx3.squarespace.com/work/billy-ruffian Password: gravy2024 In the screengrab it's the video on the left. Thanks Laura
tuanphan Posted February 16 Posted February 16 Something like this? Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)
dotandpeg Posted February 16 Author Posted February 16 Hi @tuanphan, Yes that is how I would like it. I've tried lots of different code that people have suggested but cannot get it to work.
Solution tuanphan Posted February 17 Solution Posted February 17 Try this code to Custom CSS box @media screen and (min-width:992px) { div#block-yui_3_17_2_1_1708106732776_3438 video { height: auto !important; } div#block-yui_3_17_2_1_1708106732776_3438 { justify-content: flex-start !important; } div#block-yui_3_17_2_1_1708106732776_3438 .native-video-player.video-player.video-player--medium { padding-top: 102% !important; } } Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)
dotandpeg Posted February 17 Author Posted February 17 Hi @tuanphan, This is very nearly perfect, except the video on the left is slightly longer than the image on the right. See screengrab. I thought a work around is to put a white box over the bottom of the two images (see screengrab) so they look aligned but wondering if there was a better way with code. Thanks Laura
tuanphan Posted February 18 Posted February 18 Yes. Use your way or limit height, something like this @media screen and (min-width:992px) { div#block-yui_3_17_2_1_1708106732776_3438 { video { height: auto !important; } & { justify-content: flex-start !important; max-height: 900px; overflow: hidden; } .native-video-player.video-player.video-player--medium { padding-top: 102% !important; }}} If video > 900px will hide some at bottom of video Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)
dotandpeg Posted February 19 Author Posted February 19 Thanks @tuanphan Is there a way to make it bigger for mobile, it currently looks like the attached.
dotandpeg Posted February 19 Author Posted February 19 I tried this, which does make everything bigger but it does not keep everything in its container, it just makes the page wider. I wonder if there's some code to add so that it stays in the container or the padding gets deleted? /* resize mobile video */ @media screen and (max-width:767px) { #block-yui_3_17_2_1_1707902563468_6402 { width: 150%; margin: 0 auto; } #block-yui_3_17_2_1_1707902563468_6402 { width: 150%; margin: 0 auto; } }
dotandpeg Posted February 20 Author Posted February 20 I've figured this out, I used this for mobile on a few different video blocks and this has worked to make them bigger. I just adjusted the padding figure to make them bigger or smaller. @media screen and (max-width:767px) {section[data-section-id="65c647115dbb9c51b53ba6e1"] .sqs-native-video .native-video-player { padding-top: 80%; } } tuanphan 1
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment