• Resolved Jasnick

    (@jasnick)


    A column block with 3 columns which include paragraph blocks.

    I’m trying to change font-style:italic text in a paragraph block to font-style:normal.

    I need to do this in many column blocks.

    Is there a selector I can use? I’ve tried .wp-container.wp-column-block p separately and together to no avail.

    Or does it have to be done in each and every block?

    Thanks

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hi @jasnick. I am not 100% sure I have enough details to help effectively.

    Why are those paragraphs showing as italics in the first place?

    Could you please share a link (or multiple links, if this needs to be fixed in several place) to the site you need help with so we can take a direct look?.

    Thank you!

    Thread Starter Jasnick

    (@jasnick)

    Thanks for reply Alvaro

    The paragraphs were originally copied and pasted from Word docs.

    Staging environment at present so would rather not post links.

    While not new to web design, I am fairly new to using Gutenberg.
    In a non-Gutenberg site I would just use CSS so that all paragraphs would have a certain style in whatever part of the site they were on. For example:

    .entry-content p{
    font-style:normal;
    }

    So I was wondering what the selector would be for column blocks.
    I can see that I can remove the italics on each block on each page manually but was hoping I could do it via CSS globally for the site. Or is that not possible in Gutenberg?

    Thanks

    Hello there @jasnick!

    Thank you for mentioning that this was copy/paste from somewhere else. If the italics come from a standard <em> tag, you could turn them back into normal text using the following CSS:

    .wp-block-column p em {font-style:normal}

    The only problem here is that you would not be able to add italics inside columns in the future, as they would be changed to regular text.

    I hope that helps!

    Thread Starter Jasnick

    (@jasnick)

    Thank you so much Alvaro

    That is brilliant. I would never have thought to use em in the selector. I will remember not to add italics in future.

    Thank you again.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘CSS selector for paragraph in column block’ is closed to new replies.