-
AuthorPosts
-
August 14, 2020 at 1:41 am #1237622
Hello team,
Noticing this is the issue only on a Mac (FireFox, Chrome and Safari) where the height value is not properly applied.
We still see a gray gap below the image. Gap gets smaller as we scroll down the page.
Screencap: https://imgur.com/GJdIxhNThank you!
August 15, 2020 at 1:12 pm #1238014Hey biotechz,
Thanks for the login details. If you want the image to cover the whole container, then you will likely have remove the minimum height of 350 pixels, or set the image to Stretch to Fit in the Background Repeat option. Please try that out to see if it works better that way.
Best regards,
RikardAugust 15, 2020 at 11:53 pm #1238065Thanks Rikard,
Is there no other option to set the fixed height with “Scale to Fit” image option?If we apply ‘Stretch to fit’ we loose ability to size the image properly so that the whole image is shown.
Thank you!
August 17, 2020 at 7:07 am #1238379Hi,
There’s no other alternative unfortunately. When using background images and you want them to cover the container element, then some loss of image data is inevitable.
Best regards,
RikardAugust 18, 2020 at 2:16 am #1238676Hi Rikard,
Regardless of the setting we are seeing just a small difference without using a min. height value. Does this feature not work on any of Mac browsers?
More than half of image is cropped out regardless if we use “Scale” or “Strech”.Before spinning our wheels and trying to size the image correctly, can you please take another look that it isn’t something we are doing wrong?
Pages have gone live so help would be appreciated.Thanks so much!
August 19, 2020 at 10:13 pm #1239314Here is what we settled on, hopefully this can serve as a guide for the rest.
If you have a crisp high-res images, be prepared to give up on image quality, Color Section background will not truly scale image as responsive so it is better to size the image closer to the height you want displayed. If this is a deal breaker look into using a Slider element.
—————————————So, if you need only a background image that somewhat scales without getting your image cropped out here are the settings.
Note that we had only 2 lines of text on top of image background, as H1 and H2 so this will influence your sizing of image and padding.-LAYOUT
Section Height: No min. height (apparently min. height is an issue on Mac browsers??? so we had to use padding)
Maring and Padding: No Padding (custom css will be used since you can’t really tell what size are presets)-STYLING
Background Image: Actual Image heigh of 338px
Background Attachment: Scroll (fixed and parallax – neat effects but horrible scaling, don’t bother)
Background Image Position: Center Center (adjust this depending on where the focal point of your image lands)
Background Repeat: Stretch to Fit (sadly your crisp image will get pixelated, ‘Scale to fit’ shows the best quality but it gets ‘inserted’ and does not scale down on mobile…AT ALL)-ADVANCED
Developer Setting > Custom CSS Class: bg-image (name it what you like, this will be your css class and where the sizing of “height” will come in play)In your Enfold Child Template add quick CSS:
/* --- Color Section background images --- */ .bg-image .template-page { padding-top: 120px; padding-bottom: 120px; }
—————————————
Padding values are an estimate of = text on top of image + padding value = close to actual height of your image.
In hour case H1+H2 + total of 240px of padding = image height of 338px;Best of luck!
- This reply was modified 4 years, 4 months ago by biotechz. Reason: formatting
August 23, 2020 at 8:54 pm #1240198 -
AuthorPosts
- You must be logged in to reply to this topic.