new color for type value and size value when selected.

Solved

new color for type value and size value when selected.

vwa-decor
Tourist
14 0 1

Hello,

How do I change the variant "type value" and variant "size value" in "background black color" and the "text white color" when selected?

Your help is appreciated.

 

Store: www.visualwallart.com

 

 

WhatsApp Image 2024-12-16 at 19.29.07_21684fa2.jpg

 

Accepted Solution (1)
AnneLuo
Shopify Partner
1246 222 255

This is an accepted solution.

You can try this code by following these steps:
Step 1: Go to the online store ->Theme ->Edit Code.
Step 2: Find the theme.liquid file and add the following code before the </head> tag

 

<style>
fieldset input[type=radio]:checked+label {
    background-color: #000 !important;
    color: #fff !important;
}
</style>

 


Hopefully it will help you. If yes then Please don't forget hit Like and Mark it as solution!

If this is helpful, please Like and Accept the solution.
Want to modify or custom changes on store? Let me help.
- Feel free to Email Me   

Buy Me A Coffee

View solution in original post

Replies 18 (18)

Guleria
Shopify Partner
3951 791 1123

Hello @vwa-decor ,

 

Please share the store URl.

 

Regards
Guleria

- Drop an email   if you are looking for quick fix or any customization
- Email: guleriathakur43@gmail.com Skype: live:navrocks1
- Try GEMPAGES a great page builder
vwa-decor
Tourist
14 0 1
Guleria
Shopify Partner
3951 791 1123

Follow these steps:

1. Go to Online Store -> Theme -> Edit code

2. Open your theme.css file and paste the following code at the bottom:

.single-option-radio input[type=radio]:checked+label {
    background-color: #000;
    color: #fff;
}

 

Problem solved don't forget to Like it and Mark it as Solution!
If you need help with customization/code part you can contact me for services

You can find the email in the signature below.

 

Regards
Guleria

- Drop an email   if you are looking for quick fix or any customization
- Email: guleriathakur43@gmail.com Skype: live:navrocks1
- Try GEMPAGES a great page builder
vwa-decor
Tourist
14 0 1

Hello,

Thank for replying.

I did put the code at the bottom of theme.css, but it did not work.

Guleria
Shopify Partner
3951 791 1123

  I don't find the code I provided in theme.css  

https://visualwallart.com/cdn/shop/t/7/assets/theme.css 

Can you please confirm how you added it ?

- Drop an email   if you are looking for quick fix or any customization
- Email: guleriathakur43@gmail.com Skype: live:navrocks1
- Try GEMPAGES a great page builder
vwa-decor
Tourist
14 0 1

Please double check I put ir back.

I removed it when it did not work.

Guleria
Shopify Partner
3951 791 1123

Yes now css is there and you are right  it's not working.

Can you please once try to add it in theme.liquid just before </head> tag

like this

<style>
.single-option-radio input[type=radio]:checked+label {
    background-color: #000 !important;
    color: #fff !important;
}
</style>

  

- Drop an email   if you are looking for quick fix or any customization
- Email: guleriathakur43@gmail.com Skype: live:navrocks1
- Try GEMPAGES a great page builder
vwa-decor
Tourist
14 0 1

You are the 'Man' ... It works fine.

Thanks

vwa-decor
Tourist
14 0 1

It works,

Thankyou very much

Guleria
Shopify Partner
3951 791 1123

Great but you mark another topic as solution.

 

- Drop an email   if you are looking for quick fix or any customization
- Email: guleriathakur43@gmail.com Skype: live:navrocks1
- Try GEMPAGES a great page builder
vwa-decor
Tourist
14 0 1

That was a mistake.

This is your code that worked for both variants:

 

<style>
.single-option-radio input[type=radio]:checked+label {
background-color: #000 !important;
color: #fff !important;
}
</style>

 

You can check it out

AnneLuo
Shopify Partner
1246 222 255

Hi, @vwa-decor 

Can you please share the store URL so that I can assist you?

If this is helpful, please Like and Accept the solution.
Want to modify or custom changes on store? Let me help.
- Feel free to Email Me   

Buy Me A Coffee

vwa-decor
Tourist
14 0 1
AnneLuo
Shopify Partner
1246 222 255

This is an accepted solution.

You can try this code by following these steps:
Step 1: Go to the online store ->Theme ->Edit Code.
Step 2: Find the theme.liquid file and add the following code before the </head> tag

 

<style>
fieldset input[type=radio]:checked+label {
    background-color: #000 !important;
    color: #fff !important;
}
</style>

 


Hopefully it will help you. If yes then Please don't forget hit Like and Mark it as solution!

If this is helpful, please Like and Accept the solution.
Want to modify or custom changes on store? Let me help.
- Feel free to Email Me   

Buy Me A Coffee

vwa-decor
Tourist
14 0 1

Thank you for replying,

I just added it, but not working

AnneLuo
Shopify Partner
1246 222 255

I can help you with it directly. I need to check your code. So I need to access your store as a collaborator if possible. Can you please send me your collaborator code?

If this is helpful, please Like and Accept the solution.
Want to modify or custom changes on store? Let me help.
- Feel free to Email Me   

Buy Me A Coffee

vwa-decor
Tourist
14 0 1

Actually it only work for the variant type value not the variant size value.

I tried the following and it works for both variants:

 

<style>
.single-option-radio input[type=radio]:checked+label {
background-color: #000 !important;
color: #fff !important;
}
</style>

AnneLuo
Shopify Partner
1246 222 255

Okay Great. I updated the code.

If this is helpful, please Like and Accept the solution.
Want to modify or custom changes on store? Let me help.
- Feel free to Email Me   

Buy Me A Coffee