Magento – text swatch now showing out of stock Magento 2

magento-2.0swatches

Setting up configurable products and using the text swatch option to select shirt sizes. The issue is the out of stock shirt text swatches are still showing up, clickable, and have not styling to show that they are out of stock. I'd like the swatch to still show up, but not be clickable and appear faded out or something so you know they are out of stock. Any help?

I'm not seeing any class for out of stock being passed through that I can style with CSS. This is the line that shows up:

<div class="swatch-option text" option-type="0" option-id="30" option-label="3XL" option-tooltip-thumb="" option-tooltip-value="3XL">3XL</div>

Thoughts?

Best Answer

In Magento 2.1.2 this is still an official bug: https://github.com/magento/magento2/issues/5948

Someone has created a module to help with this which is also available on Github: https://github.com/mjankiewicz/MagentoConfigurableProduct

Related Topic