Solved

What is the correct code for centering highlight text in Shopify?

annyeryn29
Explorer
48 0 14

Could someone please tell me the code to centre the text on my website highlight. I can't figure it out & it's doing my head in 😛 Thank you! Have attached a screenshot of the highlight in action.

www.annyanderyn.com

I tried .highlight__content-container {text-align: centre} which did not work. My website is narrative theme. I wouldn't mind it being general code so anytime I use a highlight it would be central. Thanks!

annyeryn29_0-1636901965519.png

 

Accepted Solution (1)

KetanKumar
Shopify Partner
36839 3635 11972

This is an accepted solution.

@annyeryn29 

try this code please 

.highlight--align-top .highlight__content-container, .highlight--align-top .highlight__image-container {
    -ms-flex-item-align: center;
    -webkit-align-self: center;
    align-self: center;
    text-align: center;
}
If helpful then please Like and Accept Solution.
Want to modify or custom changes on store Hire me.
- Feel free to contact me on bamaniyaketan.sky@gmail.com regarding any help
Shopify Partner | Skype : bamaniya.sky
PSD to Shopify | Shopify Design Changes | Shopify Custom Theme Development and Desing | Custom Modifications In to Shopify Theme | SEO & Digital Marketing

View solution in original post

Replies 2 (2)

suyash1
Shopify Partner
9077 1129 1479

@annyeryn29- spelling mistake in word center  , you have put centre... change it to center, it will look like screenshot below

 

suyash1_0-1636903953277.png

 

To build shopify pages use pagefly
You are welcome to contact me - suyash.patankar@gmail.com , My timezone is GMT+5:30.
paranormal story video using AI

KetanKumar
Shopify Partner
36839 3635 11972

This is an accepted solution.

@annyeryn29 

try this code please 

.highlight--align-top .highlight__content-container, .highlight--align-top .highlight__image-container {
    -ms-flex-item-align: center;
    -webkit-align-self: center;
    align-self: center;
    text-align: center;
}
If helpful then please Like and Accept Solution.
Want to modify or custom changes on store Hire me.
- Feel free to contact me on bamaniyaketan.sky@gmail.com regarding any help
Shopify Partner | Skype : bamaniya.sky
PSD to Shopify | Shopify Design Changes | Shopify Custom Theme Development and Desing | Custom Modifications In to Shopify Theme | SEO & Digital Marketing