Support » Plugin: Gutenberg » Adjusting wp-block-image so it doens’t display block

  • boon64

    (@boon64)


    After the update to 5.3 it seems that my images are not aligning correctly anymore.

    I checked it out and it seems I need to give them an alignment. That align class is overriding the ‘display:block’ used in figures.

    Because I do not want to align all my images (I have 7000 so that would cost me a week) I want to change the wp-block-image class to not display:block.

    It’s probably really simple but i’m not a developer so I need some help. Anybody know how I can do this in the css file?

    • This topic was modified 3 months ago by boon64.
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Grzegorz (Greg) Ziółkowski

    (@gziolo)

    Hello @boon64,

    Can you share a link to the post which suffers from the issue you described or at least a snippet of the HTML code generated by the block editor to better illustrate your use case?

    boon64

    (@boon64)

    Yeah i’m thinking it might be a template issue. But I will paste the code here anyway.

    Image that is not showing correctly:

    <figure class=”wp-block-image”></figure>

    This class says ‘display-block’. If you inspect the image on my blog you can see there is a block around it (or its placed in a block). I do not want this block around my image (or my image in that block).

    If you align the image, it looks ok. Code looks like this:

    <div class=”wp-block-image”><figure class=”aligncenter”></figure></div>

    So here is the wp-block-image class again but there is now and extra class ‘aligncenter’ and the styling of that one deletes (I think, i’m not a developer) the ‘display-block’.

    So now the block around my image is gone.

    Now, I could align every image on my blog but I have about 6000 images so that is definitely not what I want to do. I just want the ‘wp-block-image’ to not ‘display-block’.

    I’m guessing I maybe have to add some styling to the CSS sheet but I don’t have any code knowledge. So don’t know.

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.