This might be more of a feature request – but if there is a way to do this it would be great. I’d like to be able to style a page a little differently depending on a GP Element appearing.
I could start doing page templates, but thought if there were a field within the Element editor that allows custom classes to be targeted in the body tag it could open up the theme to some wild styling stuff!
Example: I have an Element named ‘Testimonial’ that appears across most pages except a dedicated Testimonial page. If I could add a custom class to the body of ‘has-testimonial-element’ then I could style *other* sections on the page – whether higher or lower in the rendered HTML – for some creative results.
I could do this via JS right now – but could be nice built in to the Settings panel where it has options to execute PHP and shortcodes