Tagged: Overflow, responsive, text
Hello,
The main headline on my hero image is not being fully responsive. The text is overflowing so that the words are not fully visible. Please see the attached screenshot.
Hey JPOsteen,
Thanks for the screenshot, where can we inspect the actual element? We need to be able to see it in order to give you accurate CSS.
Best regards,
Rikard
See the link below.
Hi,
Thanks for that. Please try the following in Quick CSS under Enfold->General Styling:
@media only screen and (max-width: 767px) {
h1 span {
font-size:32px !important;
}
h2 span {
font-size:26px !important;
}
}
Best regards,
Rikard
Thanks, but the word “Craftsmanship” is still bleeding over the text box’s background color.
Hi,
Make sure that you delete the old CSS and JS files under Enfold->Performance before you check the results. The CSS I gave you is not applying.
Best regards,
Rikard
Is there a way to make the headline text responsive by percentage of the screen rather than assigning a specific pixel size?
Hi,
You can try to use percentages instead yes, or you can select to break the words if they overflow using this:
word-break: break-word;
Best regards,
Rikard
Thanks @Rikard. How would I use percentages?
Hi,
Thank you for contacting us.
Please refer to the below links
https://medium.com/code-better/css-units-for-font-size-px-em-rem-79f7e592bb97
Best regards,
Vinay