Jump to content

How to center content of an Image Block: Card?

Recommended Posts

Site URL: https://blenny-plums-wnna.squarespace.com/work-1

Website Password: Hellothere

Hi, I am using the Card Image Block and I can't center align the content inside so that the image and the text are both centered inside the card. (Please see screenshot below)

This is what I have tried:
- Using the Squarespace Block Identifyer to get the blocks' numbers
- Adding these custom css:

.block-yui_3_17_2_1_1595587238787_9478{
  align-items:center
}

- Changing the block numbers but nothing worked.

I have also read the following articles to get some help but it did not work out either:
https://www.will-myers.com/articles/how-to-center-image-cards-to-the-text-in-squarespace
https://stackoverflow.com/questions/36108509/looking-for-centralising-an-image-in-html-blocks-on-squarespace

 

Thank you for the help!

_______

1434964888_Screenshot2020-07-29at13_29_29.thumb.png.55aba85d22ca96803b13671e75361a0a.png

 

 

Link to comment
  • Replies 5
  • Created
  • Last Reply

Top Posters In This Topic

Hi. Add to Home > Design > Custom CSS

div#page-section-5f1abad50975ca2cc4cc2d04 .span-12>.row {
    display: flex;
    align-items: center;
}

 

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

How to: Setup Password & Share url Insert Custom CSS - Page Header - Upload Custom Font - Upload File - Find Block ID - Contact Customer Care

Link to comment
9 hours ago, tuanphan said:

Hi. Add to Home > Design > Custom CSS


div#page-section-5f1abad50975ca2cc4cc2d04 .span-12>.row {
    display: flex;
    align-items: center;
}

Hello, thank you so much for helping out, it's working!!

I would like to do it for all my blocks and it's not working this time, do you happen to know why?

For example, for the block underneath, I have tried this but it does not work:


div#page-section-5f1ab909c92dd520159cd75c .span-12>.row {
    display: flex;
    align-items: center;
}

I have also tried with the Yui ID... 

Thank you! @tuanphan

 

Link to comment
  • 2 years later...
16 hours ago, Bianca11 said:

@tuanphan how do I align a banner image? I've tried variations of 'align-image' etc. but nothing is working.

Site URL: https://www.motherhoodempowerment.com/independent-minded-moms-summit

You mean top banner? What should it look like?

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

How to: Setup Password & Share url Insert Custom CSS - Page Header - Upload Custom Font - Upload File - Find Block ID - Contact Customer Care

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.