Jump to content

Centre custom product title on mobile only

Recommended Posts

Site URL: https://littlewhimsey.com

Hi there, 

I'm trying to centre my product title on mobile only.  I've found this code but didn't work  (my site os 7.0) I've included a screen shot for reference. Is there an easy css code for this? Many thanks in advance 🙂

/* align shop title */
@media screen and (max-width:640px) {
h3.nested-category-title {
    text-align: center !important;
}
}

Screen Shot 2022-03-23 at 7.33.21 pm.png

Link to comment
2 hours ago, ARees said:

Site URL: https://littlewhimsey.com

Hi there, 

I'm trying to centre my product title on mobile only.  I've found this code but didn't work  (my site os 7.0) I've included a screen shot for reference. Is there an easy css code for this? Many thanks in advance 🙂

/* align shop title */
@media screen and (max-width:640px) {
h3.nested-category-title {
    text-align: center !important;
}
}

Screen Shot 2022-03-23 at 7.33.21 pm.png

Hi, add this code to custom css (Design > Custom CSS) and let me know how it goes 🙂 

@media screen and (max-width:646px) {
  h1.ProductItem-details-title {
    text-align:center !important;
  }
}

Please give this a 👍 if it helps. Make sure to quote me or tag me in your reply, otherwise I won't be notified.

Link to comment
16 hours ago, Jia said:

Hi, add this code to custom css (Design > Custom CSS) and let me know how it goes 🙂 

@media screen and (max-width:646px) {
  h1.ProductItem-details-title {
    text-align:center !important;
  }
}

You are a legend! perfect! THANK YOU again, Jia! 

Link to comment
  • 5 months later...
On 9/7/2022 at 4:29 AM, Rjafadi said:

Hi @Jia is there a way to center the production description with your code? 

Screenshot 2022-09-06 at 22.14.48.png

Use this CSS

/* center product description */
@media screen and (max-width:767px) {
.ProductItem-details-excerpt {
    text-align: center;
}
}

 

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

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment
13 hours ago, Rjafadi said:

Thank you! @tuanphan

Is there a way to create some space between the product title and images above? Also if the price could be under the title and centered too.

Screenshot 2022-09-08 at 20.51.34.png

Try this CSS

/* center product description */
@media screen and (max-width:767px) {
.ProductItem-details-excerpt {
    text-align: center;
	margin-top: 30px;
}
}

 

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

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment
  • 1 year later...

@JoseEsteves1 Please provide a link to the page.

About me: I've been a SQSP User for 18 yrs. I was invited to join the Circle when it launched in 2016. I have been a Circle Leader since 2017. I don't work for Squarespace. I value honesty, transparency, diversity and good design ♥.
Work: I founded and run SF.DIGITAL, building Squarespace Extensions to supercharge your commerce website. 
Content: Views and opinions are my own. Links in my posts may refer to SF.DIGITAL products or may be affiliate links.
Forum advice is free. You can thank me by clicking one of the feedback emojis below. Coffee is optional.

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.