How can I limit product titles to one line on my collection page?

Hello,
Is there any way to limit the product titles in my collection page to just one line and have a “…” at the end if there is more?

https://stronos.shop/
Pass: GWR

1 Like

Hi @Kogun1

Do you mean like this?

If it is, check this one.

From your Shopify admin dashboard, click on “Online Store” and then “Themes”.

Find the theme that you want to edit and click on “Actions” and then “Edit code”.

In the “Assets” folder, click on “base.css, style.css or theme.css” file, depending on which file your theme uses to store its CSS styles. At the bottom of the file, add the following CSS code:

div#shopify-section-collection_page h3.product-title.pr.fs__14.mg__0.fwm {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

And Save.

Please don’t forget to Like and Mark Solution to the post that helped you. Thanks!

Hello, I added this code at the bottom of my style.css file. However, it still does not limit the title.

Check this one again. Thanks!

.nt_pr h3.product-title {
    overflow: hidden;
    white-space: nowrap !important;
    text-overflow: ellipsis !important;
}

And save.

Hey, thanks for the follow-up. However, this code is still not fixing the issue. Would you possibly want collaborator access? Thanks!

Hi @Kogun1

This is Richard from PageFly - Shopify Page Builder App

Please add this code to your theme.liquid above the to get this solved

Step 1: Online Stores > Themes > More Actions > Edit code

Step 2: click on theme.liquid and paste the code above the


Hope this can help you solve the issue

Best regards,

Richard | PageFly