-
Anonymous
Hi Team,
I have an ongoing issue that I can’t ignore anymore, because I am being forced to create hundreds of new Global Style Tags, just to change the colour of a Text or line.
Lets say I have a Global Style element like .gbp-section__tagline. This has a Text with a coloured line under it, which is a Background Colour in the After Selector. I change this to Green, but of course it then changes all the .gbp-section__tagline instances on the website.
I 100% get that that is the point of it, but how do I avoid that and make this its own element, without having to now create yet another Global Style Element e.g .gbp-section__tagline_green
As I said, I get how it works, but I’m ending up with hundreds of style tags that I really don’t want?
Thanks
-
Alvind
Hi there,
If you want a style to apply only to a specific element, you don’t need to create or modify a Global Style.
Instead, simply apply the styling locally to that element. A local style is the better approach when the styling is only intended for a single element, and it will override Global Styles for that specific element.
-
Anonymous
I guess what I am asking then, is if the Element is already using a Global Style, how do I convert it to a local style?
-
Alvind
There is no straightforward way to do that at the moment.
However, GenerateBlocks Pro 2.6 (currently in RC-2) introduces a CSS Mode feature where both Global Styles and Local Styles are exposed as CSS. This allows you to copy the CSS from a Global Style and paste it into a Local Style, with the corresponding block settings updating automatically.
-
Anonymous
I think something like the ‘Convert to Blocks’ would be ideal, but I’ll look forward to the 2.6 update to address this and other issues.
Thanks Alvind -
Alvind
Sure, no problem!
- You must be logged in to reply to this topic.