{
if(value){
document.body.classList.add('overflow-fixed');
}else{
document.body.classList.remove('overflow-fixed');
}
});
$watch('product_handle', (value) => {
if(value){
loadProduct(value);
}
});
$nextTick(() => {
show_quick_view = true;
product_handle = $event.detail.handle;
});"
x-data="{
show_quick_view: false,
loading: false,
product_handle: '',
loadProduct(handle){
this.loading = true;
fetch(`${window.Shopify.routes.root}` + 'products/' + handle + '?view=quick-view-bundle')
.then(response => response.text())
.then(data => {
this.loading = false;
this.$refs.quick_view_content.innerHTML = data;
setTimeout(() => {
if(typeof StampedFn !== 'undefined'){
StampedFn.reloadUGC();
}
}, 500);
})
.catch((error) => {
console.error('Error:', error);
});
}
}"
style="display: none;"
x-show="show_quick_view"
@keyup.escape.window="show_quick_view = false; document.body.classList.remove('overflow-fixed');"
role="dialog"
aria-modal="true"
x-id="['quick-view-bundle']"
x-trap="show_quick_view"
:aria-labelledby="$id('quick-view-bundle')"
class="quick-view-wrapper fixed inset-0 z-[500] overflow-y-auto">
Quick view of {{ product_title }}
Loading product...