Extra CSS Class field for TD elements in VC

Posted in: Newspaper
Post count: 8

Something to add to the wishlist.

Sometimes I would like to target a specific Visual Composer Elements for additional styling. Most of the standard VC elements have an “Extra CSS Class” field for this purpose, but not the tagDiv add-ons to VC.

Thanks
Denis

Post count: 6600

Hi,

We will consider this, thanks for the suggestion.

Thanks for the message!

Post count: 388

Yes, was thinking the same thing. Currently the only way is to add a row just for the one element and then give the column a custom CSS class. But rows inside rows tend to break the layout in small ways. This is from experimenting a bit and finally deciding to just reserve a whole block style for one purpose so I could target it :p

Post count: 8

@TheMediumUTM – You can use the CSS :nth-child() selector rather than nesting elements in rows. It won’t break the layout, but accurately targeting the element sometimes takes a few tries. I often have to fix the object hierarchy, and also add a property that makes it easy to visually identify so that you know you’ve got the right one, something like:

div.some_known_class > div > div:nth-child(2) { background-color: red; }

<:) denis

  • This reply was modified 11 years by potion.
  • This reply was modified 11 years by potion.
Post count: 388

Good call! If I ever decide to use the other module, I’ll switch to this 🙂

Viewing 5 posts - 1 through 5 (of 5 total)
The forum ‘Newspaper’ is closed to new topics and replies.