Home › Forums › WoodMart support forum › Woodmart Core update broke my CSS?
Woodmart Core update broke my CSS?
- This topic has 3 replies, 2 voices, and was last updated 8 months, 3 weeks ago by Luke Nielsen.
-
AuthorPosts
-
February 15, 2024 at 4:27 pm #540456
sami-6411ParticipantHello,
As soon as I updated the woodmart core I noticed that my grouped and variable price stopped working as intended, I opened ticket 7 days ago about it and we found a working solution for it.
However now the solution doesn’t work anymore, and I think I found something that didn’t exist before the latest update?
What I found:
.hide-larger-price .price { word-spacing: -1em; visibility: hidden } .hide-larger-price .price *:not(.price) { word-spacing: normal; visibility: visible } .hide-larger-price .price>span:nth-child(2) { display: none } .hide-larger-price .price>:is(ins,small) { margin-inline-start:4px} .hide-larger-price .wd-price-unit { display: inline !important } .browser-Safari .hide-larger-price .price>:is(ins,small) { margin-inline-start:calc(1em + 4px)} .browser-Safari .hide-larger-price .price,.browser-Safari .hide-larger-price .wd-sticky-btn-cart .price { white-space: nowrap }
This was the code I used to make the variable and grouped products to show the higher price instead of the smaller one:
/**** Variable ****/ .product-type-variable .summary-inner > .price, .wd-product.product-type-variable .price { font-size: 0; } .product-type-variable .summary-inner > .price .amount:nth-child(2), .wd-product.product-type-variable .price .amount:nth-child(2) { font-size: 15px; } /**** Grouped ****/ .product-type-grouped .summary-inner > .price, .wd-product.product-type-grouped .price { font-size: 0; } .product-type-grouped .summary-inner > .price .amount:nth-child(2), .wd-product.product-type-grouped .price .amount:nth-child(2) { font-size: 15px; } /**** Simple ****/ .wd-product:not(.product-type-variable):not(.product-type-grouped) .price { font-size: initial; /* Or any appropriate font size */ }
February 16, 2024 at 12:42 pm #540680
Luke NielsenKeymasterHello,
The provided link from the private area is not working: https://prnt.sc/JNgzT8HfHFFz , also, cannot find some products: https://prnt.sc/mcMJJ9DdzQle , please clarify on which page I can check it.
Thank you in advance.
Kind Regards
February 16, 2024 at 2:27 pm #540720
sami-6411ParticipantHey,
I managed to fix it today, its just test page so I removed everything for now.
Here is my solution that fixed the problem:
/* Hide the smaller price and show the larger price for variable products */ .product-type-variable .summary-inner > .price, .wd-product.product-type-variable .price { font-size: 0; /* Hide the original price */ } .product-type-variable .summary-inner > .price .amount:nth-child(2), .wd-product.product-type-variable .price .amount:nth-child(2) { font-size: 15px; /* Show the larger price */ } /* Hide the smaller price and show the larger price for grouped products */ .product-type-grouped .summary-inner > .price, .wd-product.product-type-grouped .price { font-size: 0; /* Hide the original price */ } .product-type-grouped .summary-inner > .price .amount:nth-child(2), .wd-product.product-type-grouped .price .amount:nth-child(2) { font-size: 15px; /* Show the larger price */ } /* Show the original price for simple products */ .wd-product:not(.product-type-variable):not(.product-type-grouped) .price { font-size: initial; /* Show the original price with an appropriate font size */ }
February 16, 2024 at 3:01 pm #540750
Luke NielsenKeymasterHello,
Glad that you found a solution.
In case you need any additional help, I’d be more than happy to assist you.
Have a good day!
Kind Regards
-
AuthorPosts
The topic ‘Woodmart Core update broke my CSS?’ is closed to new replies.
- You must be logged in to create new topics. Login / Register