Is there a way to add a <br>/return to product name on product info grid (dawn theme)?

I’d like to add a return (
) to the product info on this page: https://yellowathletic.myshopify.com/collections/all

so that instead of reading like this:

Sleep Recovery - CBD oil

(30 ml)

it’ll read like this:

Sleep Recovery

CBD oil (30 ml)

I tried
but that didn’t work. Any other suggestions?

Thanks!!

Hi,

A solution to this can be using jQuery. The below code would replace ‘-’ with ‘
’ from your product name.

$(".card__heading .full-unstyled-link").each(function() {
            var leTitle=$(this).text();
            var newTitle=leTitle.replace('-','
');
            $(this).html(newTitle);
        });

Cheers!

Thank you!! Would I add this to the bass.css?

Hi Gabriel, thanks for the code above. Where should I put it? I tried base.css, but it didn’t work. Thanks again!

Hi,

Its a Javascript code, not CSS. It can be added at the end of a .js. If you don’t have coding experience, I’d recommend to hire a web developer.

Cheers!