Center image issue only on desktop

Hi

I created a class for images to get them centered in their own column, using this css:

.centerImage img {
margin-left: auto;
margin-right: auto;
width: 50%;
}

It does work, in fact images are getting centered in the editor and on mobile, up to a certain screen width. Anyway, viewing from a desktop at full width, they go to the left, as you can see in the screenshot

Hey Riccardo,

That is not the correct way to center the image though it works. In fact, that is the cause of the issue. To center all items inside a column or row, set the Text Align to Center. I’d also recommend that you use the same image size for all your images in the row. Otherwise, you’ll need to set a Max Width. Please watch the screencast below:

Hope that helps.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.