Remove Cart and Search Icon Desktop and Mobile Dawn Theme

Hi,

I have used the attached code to remove the search icon and cart icon from my header. It works perfect on desktop, but remains visible on mobile. How can I also remove it from mobile?

1 Like

Hi @glorygut ,

Use media query example.

@media only screen and (max-width: 750px){
#cart-icon-bubble {
display: none;
}
}

for some reason it is still showing on mobile

1 Like

Would you mind to share your URL website? Possibilities it maybe different selector name on the mobile. Thanks!

Hi @glorygut

I hope you are doing good and welcome to the Shopify Community!
I am San from MS Web Designer.

Please add this css in your bottom of the base.css file:

.header__search, .header__icon–cart {display: none !important;}

Regards,

San

Hi there,

I think your missing something. Try this one.

  1. From your Shopify admin dashboard, click on “Online Store” and then “Themes”.
  2. Find the theme that you want to edit and click on “Actions” and then “Edit code”.
  3. 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:
  4. And Save.
details-modal.header__search {
    display: none;
}
a#cart-icon-bubble {
    display: none;
}

Result:

I hope it help.