Shopify themes, liquid, logos, and UX
Hello,
this is my store: https://raicesjewellery.com
As you can see the header background is transparent and when you scroll it is white, which is great!
1. The only issue is that our logo is in black and i would like it to be in white when the background is transparent and then change to black when i scroll and the background changes to white. The logo is a png.
2. As well as the logo, i would need the other features such as :shop icon, login icon, currency icon, search icon a.s.o to change colours as well from white to black.
Could someone please help with this?
Thank you
.section-header .header-wrapper * {
fill: white !important;
color: white !important;
}
html .section-header.scrolled-past-header .header-wrapper * {
fill: black !important;
color: black !important;
}
Hello, thank you for your help. Unfortunately it didnt exactly work. It did turn white, but not black when scrolling.. do you think you have a solution for that? And also with the logo?
Thank you for your time!
This section should be set to white, but it still turns black when scrolling.
As for the logo, it can't be adjusted since it's a black image, and there's only one version of it.
I hope this helps
Best,
Daisy
Hi @Raicesjewellery ,
1. Go to Online Store -> Theme -> Edit code.
2. Open your theme.css / based.css file and paste the code in the bottom of the file
img.header__heading-logo.motion-reduce {
filter: invert(1);
}
html .section-header.scrolled-past-header .header-wrapper img {
filter: unset;
}
.header-localization:not(.menu-drawer__localization) {
filter: invert(1);
}
html .section-header.scrolled-past-header .header-wrapper .header__icons.header__icons--localization.header-localization {
filter: none;
}
header-drawer, svg.icon, button.disclosure__button.localization-form__select.localization-selector.link.link--text.caption-large, summary.header__icon.header__icon--search.header__icon--summary.link.focus-inset.modal__toggle {
filter: invert(1);
}
html .section-header.scrolled-past-header .header-wrapper header-drawer, svg.icon, button.disclosure__button.localization-form__select.localization-selector.link.link--text.caption-large, summary.header__icon.header__icon--search.header__icon--summary.link.focus-inset.modal__toggle{
filter: none !important;
}
If my reply is helpful, kindly click like and mark it as an accepted solution.
If you are happy with my help, you can help me buy a COFFEE
Thanks!
Hey Community! As we jump into 2025, we want to give a big shout-out to all of you wh...
By JasonH Jan 7, 2025Hey Community! As the holiday season unfolds, we want to extend heartfelt thanks to a...
By JasonH Dec 6, 2024Dropshipping, a high-growth, $226 billion-dollar industry, remains a highly dynamic bus...
By JasonH Nov 27, 2024