Override Javascript to set height for section

Hi,

On our site, http://darealty.com/aurum/location

I've set a background and height for the AURUM logo so that when you scroll down, the main body text disappears behind it.

However if the content text is too long it already starts by being cut off at the top by the logo overlay (.desktop-logo), so I've added jQuery to check how long the text is, and if needed add a top-margin to it (.left-text) to push it down enough so that the text starts below the overlay.

The problem with this is that the height of the section container is not taking this margin into account, so in some places on some screen sizes it sets the height for .section too small, leaving a white gap at the bottom (on Firefox) or cutting off the content on the left (Chrome).

This only happens on some screen sizes, eg. 1366x768 & 1024 x 768.

I've tried to set the height with jQuery to incorporate the margin, but it's not letting me override the height or padding, however I can set other properties that are not being set by other javascript so the code IS working, just not allowing me to override those properties.

I've made sure that my script is running after the theme scripts.js but it still doesn't work!

Please help.

How can I override the height being set on .section?



Thanks,
Steven

Comments

Sign In or Register to comment.
This website uses cookies

We use cookies to personalise content and ads, to provide social media features and to analyse our traffic. We also share information about your use of our site with our social media, advertising and analytics partners who may combine it with other information that you’ve provided to them or that they’ve collected from your use of their services.

Cookies are small text files that can be used by websites to make a user's experience more efficient.

The law states that we can store cookies on your device if they are strictly necessary for the operation of this site. For all other types of cookies we need your permission. This means that cookies which are categorized as necessary, are processed based on GDPR Art. 6 (1) (f). All other cookies, meaning those from the categories preferences and marketing, are processed based on GDPR Art. 6 (1) (a) GDPR.

This site uses different types of cookies. Some cookies are placed by third party services that appear on our pages.

You can at any time change or withdraw your consent from the Cookie Declaration on our website.

Learn more about who we are, how you can contact us and how we process personal data in our Privacy Policy.

Please state your consent ID and date when you contact us regarding your consent.