I'm trying to change the colour of my sitetitle (text) to white for certain areas of a webpage when scrolling, based on when there is a black row – for example, a cover intro section, or a dark colour photo with a viewpoint height of 100%.
Both the sitetitle and the menu are fixed, I’ve managed to successfully get this to work for the menu / nav for both desktop and mobile using Armin’s JS code from this post: http://laythemeforum.com:4567/topic/699/change-link-color-on-fixed-nav-based-on-current-row-background
I noticed that there was also a revised JS code by Marius, to include the sitetitle on this post: http://laythemeforum.com:4567/topic/3704/change-color-of-fixed-sitetitel-menu-when-scrolling-down-page-according-to-changing-row-background
However, after several attempts, I can not get this to work for the sitetitle using Marius’s JS for some reason. I've assigned the required areas with a ‘blackrow’ HTML class / ID, and have added the CSS too – but no luck!
Can you advise and help, please?
Thank you and best,