Re: How do I display a smaller price on mobile on collection pages?

Solved

How do I display a smaller price on mobile on collection pages?

WalletAces
Tourist
9 0 3

IMG_9946.jpg

 

I would like this price (on the collection pages, on mobile) to be smaller so it would fit in the same line as the strikethrough price. 

 

My font is already at its smallest so it's not possible to reduce the font further using the editor.

 

Can code edits be made to achieve this otherwise?

Accepted Solution (1)

BSSCommerce-HDL
Shopify Partner
2305 848 1062

This is an accepted solution.

Hi @WalletAces

Step 1: Go to Shopify Admin -> Online Store ->Theme -> Edit code

Step 2: Search file theme.liquid

Step 3: Insert this code above </head> tag: 

 

<style>
@media only screen and (max-width: 767px) {
  .price--on-sale .price__sale {
    display: flex !important;
    flex-direction: row;
    flex-wrap: nowrap !important;
  }

  .price--on-sale .price__sale span.money {
    font-size: 11px !important;
  }
}
</style>

 

Hope this can help you,

If our suggestions are useful, please let us know by giving it a like or marking it as a solution. Thank you 😍

Sale banner, pop ups: Customize your sale banner, pop-ups and create countdown bar to boost conversion rate.
Simicart: Transform your Shopify store into a stunning and fully functional mobile app with just a few simple steps.
Product Labels & Badges:
Get more sales with striking labels, badges, and banners from our 10,000+ available templates.

BSS Commerce - Full-service eCommerce Agency | Use Shopify for 1$ in the first month now

View solution in original post

Replies 5 (5)

BSS-TekLabs
Shopify Partner
2350 702 827

Hi @WalletAces,

Could you kindly provide us with your store URL and, if applicable, the password, so that our team can offer you the necessary support?

If our suggestions are useful, please let us know by giving it a like or marking it as a solution.


Salepify: Efficiently increase sales conversion with sale-driven features like auto add to cart, free gifts (free plan available)


Salemate: Boost your AVO with 2-layer offer, countdown upsell in your post purchase page


BSS Commerce - Full-service eCommerce Agency | Use Shopify for 1$ in the first month now

BSSCommerce-HDL
Shopify Partner
2305 848 1062

This is an accepted solution.

Hi @WalletAces

Step 1: Go to Shopify Admin -> Online Store ->Theme -> Edit code

Step 2: Search file theme.liquid

Step 3: Insert this code above </head> tag: 

 

<style>
@media only screen and (max-width: 767px) {
  .price--on-sale .price__sale {
    display: flex !important;
    flex-direction: row;
    flex-wrap: nowrap !important;
  }

  .price--on-sale .price__sale span.money {
    font-size: 11px !important;
  }
}
</style>

 

Hope this can help you,

If our suggestions are useful, please let us know by giving it a like or marking it as a solution. Thank you 😍

Sale banner, pop ups: Customize your sale banner, pop-ups and create countdown bar to boost conversion rate.
Simicart: Transform your Shopify store into a stunning and fully functional mobile app with just a few simple steps.
Product Labels & Badges:
Get more sales with striking labels, badges, and banners from our 10,000+ available templates.

BSS Commerce - Full-service eCommerce Agency | Use Shopify for 1$ in the first month now

niraj_patel
Shopify Partner
2378 514 512

HELLO @WalletAces 

You can add code by following these steps

1. Go to Online Store -> Theme -> Edit code.
2. Open your theme.liquid file

3. Paste the below code before </body> on theme.liquid
<style>
@media screen and (max-width: 767px) {
span.price-item.price-item--sale.price-item--last span {
font-size: 11px !important;
}
.price--on-sale .price-item--regular{
font-size: 11px !important;
}
.price--on-sale .price__sale {
display: flex !important;
align-items: center;
}
}
</style>

techlyser_web_0-1721990300613.png

Was my reply helpful? Click Like to let me know!
Was your question answered? Mark it as an Accepted Solution.

Shopify Partner || Helping eCommerce Stores
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution.
- For further discussion contact: Email ID- [email protected]

K-Mahesh
Shopify Partner
21 3 5

Hello @WalletAces 

Can you please provide your store URL.

 

SetuBridge_
Shopify Partner
263 60 84

@WalletAces  You can add code by following these steps

1. Go to Online Store -> Theme -> Edit code.
2. Open your theme.liquid file.
3. Paste the below code after <body> tag in theme.liquid file.
4. Find the exact class name of the price div and Set the suitable font size as you want in the CSS code.

Code:

{% if template contains 'collection' %}
<style>
@media only screen and (max-width: 600px){
.price__sale (add price class){
font-size:12px;
}
.price--on-sale (add price parent class ){
display:flex;
align-items:center;
gap:10px
}
}
</style>
{% endif %}

 

 

- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution

Shopify Partner | Shopify E-Commerce Solutions Provider