We have many products which only comes in a singular size, or a singular material. Though we still want them to show up when filtering for the specified size or material. I’ve attached a picture for a visual of what I am talking about.
We want to hide Size and Material
furthermore I have been going down a deep rabbit hole of the code, and found believe to find where I need to edit, though I am unable to see what I should put in a potential if statement, as I am still very new to liquid dev. (Using the Dawn Theme)
I am assuming I either have to edit something:
product-variant-options.liquid
product-variant-picker.liquid
Currently looking at:
{%- for value in option.values -%}
{%- liquid
assign option_disabled = true
for option1_name in variants_option1_arr
case option.position
when 1
if variants_option1_arr[forloop.index0] == value and variants_available_arr[forloop.index0]
assign option_disabled = false
endif
when 2
if option1_name == product.selected_or_first_available_variant.option1 and variants_option2_arr[forloop.index0] == value and variants_available_arr[forloop.index0]
assign option_disabled = false
endif
when 3
if option1_name == product.selected_or_first_available_variant.option1 and variants_option2_arr[forloop.index0] == product.selected_or_first_available_variant.option2 and variants_option3_arr[forloop.index0] == value and variants_available_arr[forloop.index0]
assign option_disabled = false
endif
endcase
endfor
-%}
within product-variant-options.liquid
Any help is appriciated
