Center figure image

Hi,
Currently i am completing personal portfolio web page challenge
Here is what i have done yet: https://codepen.io/vothis/pen/gRyryX
My main problem is i can’t center the second thumbnail image, i have used quite a few css but i couldn’t make it center without changing the below text behavior. if there is any bootstrap class it would be more preferred.

Any further comment about the design or page would be appreciated.
Thanks in advance for your helps.

There probably is a bootstrap class that could do it. Something like the thumbnail component might work for you.

For this, I just cobbled together some quick code that works. Have a look.

figure>img{
  width: 300px;
  max-height: 300px;
  object-fit: contain;
}
1 Like