diff --git a/snippets/shx-product-desc.liquid b/snippets/shx-product-desc.liquid index da41c37..26362f5 100644 --- a/snippets/shx-product-desc.liquid +++ b/snippets/shx-product-desc.liquid @@ -110,7 +110,6 @@ class CustomVariantDescriptionElement extends HTMLElement { constructor() { super(); - this.style.display = 'block'; // "variant" is the id of the variant @@ -125,6 +124,10 @@ this.updateVariantDescription(id); } + connectedCallback() { + this.style.display = 'none'; + } + disconnectedCallback() { // Clean up the element when it is removed from the DOM. }