Hi guys,
I have an issue with video size in the product description tab , all views!
Thank you
A user is experiencing video sizing issues within their product description tab across all device views. The embedded video doesn’t automatically fit the product card dimensions, creating display problems.
Initial Problem:
Solution Approach:
PageFly-Victor provides CSS code to be added to the theme.scss file:
.product-single__description.rte iframe elementswidth: fit-content and media queries for responsive sizingIterative Fixes:
Multiple code revisions were needed to address:
Latest Code:
The most recent solution includes:
calc(100% - 5px)The discussion remains ongoing as the user continues testing the responsive behavior across devices.
Hi guys,
I have an issue with video size in the product description tab , all views!
Thank you
It must automatically fit the size of the card in all views.
Hi [email removed]Alliance,
You can try this code by following these steps:
Step 1: Go to Online Store->Theme->Edit code.
Step 2: Search file theme.scss or theme.scss.liquid,
Step 3: Paste the below code at bottom of the file → Save
.product-single__description.rte iframe{width:fit-content !important}
Hope my solution works perfectly for you!
Best regards,
Victor | PageFly
you can remove old code and replace it with new code
.product-single__description.rte{
margin-left:-25px !important;
padding-right:0 !important
}
.product-single__description.rte iframe{
width:calc(100% - 5px) !important;
height:200px !important
}
@media(max-width:767px){
.product-single__description.rte{
margin-left:-0 !important;
}
}
@media(max-with:1024px) and (min-width:768px){
.product-single__description.rte iframe{
height:120px !important
}
please remove the old code and replace the new code
.product-single__description.rte{
margin-left:-25px !important;
padding-right:0 !important
}
.product-single__description.rte iframe{
width:calc(100% - 5px) !important;
height:200px !important
}
@media(max-width:767px){
.product-single__description.rte{
margin-left:0 !important;
}
.product-single__description.rte iframe{
width:100% !important;
}
div#ProductSection-product-template .grid__item.medium-up--one-third{
padding:0 5px !important
}
}
@media(max-with:1024px) and (min-width:768px){
.product-single__description.rte iframe{
height:120px !important
}
you can replace the old code
@media(max-width:767px){
.product-single__description.rte{
margin-left:0 !important;
}
.product-single__description.rte iframe{
width:100% !important;
}
div#ProductSection-product-template .grid__item.medium-up--one-third{
padding:0 5px !important
}
}
by the new code
@media(max-width:767px){
.product-single__description.rte{
margin-left:0 !important;
}
.product-single__description.rte iframe{
width:100% !important;
}
div#ProductSection-product-template .grid__item.medium-up--one-third:has(.tabs li:last-child a.active){
padding:0 5px !important
}
}
@media(max-width:400px) and (min-width:376px){
.product-single__description.rte iframe{height:188px !important}
}
@media (max-width:376px){
.product-single__description.rte iframe{height:180px !important}
}