window.addEventListener('AddItemToCart', function(event) {
const productVariantId = event.detail;
// Perform AJAX request to add item to cart
fetch('/cart/add.js', {
method: 'POST',
headers: {
'Content-Type': 'application/json'
},
body: JSON.stringify({
items: [{
id: productVariantId,
quantity: 1,
}],
sections: 'cart-drawer,cart-icon-bubble'
})
})
.then(response => response.json())
.then(data => {
console.log('Item added to cart:', data);
document.documentElement.dispatchEvent(new CustomEvent('cart:refresh', {
bubbles: true
}));
})
.catch((error) => {
console.error('Error adding item to cart:', error);
});
});
$(document).ready(function() {
// Cache the main add to cart area and sticky add to cart button elements
var $mainAddToCart = $('.Product__Info'); // Replace with your actual selector for the main add to cart area
var $stickyAddToCart = $('#stickycart'); // Replace with your actual selector for the sticky add to cart button
// Initially hide the sticky add to cart button
$stickyAddToCart.hide();
// Function to check visibility of main add to cart area
function checkAddToCartVisibility() {
// Check if the main add to cart area is visible in the viewport
var isVisible = $mainAddToCart.is(':visible') &&
$mainAddToCart.offset().top < $(window).scrollTop() + $(window).height() &&
$mainAddToCart.offset().top + $mainAddToCart.outerHeight() > $(window).scrollTop();
// Toggle sticky add to cart button based on visibility
if (isVisible) {
$stickyAddToCart.hide();
} else {
$stickyAddToCart.show();
}
}
// Run the check on scroll and on load
$(window).on('scroll resize', checkAddToCartVisibility);
checkAddToCartVisibility(); // Initial check
});
$(document).ready(function() {
// Show the first tab content by default
$(".tab-content .tab").hide();
$(".tab-content .tab:first").show();
// Handle click on tab link
$(".tab-links li").click(function(event) {
event.preventDefault();
// Remove active class from all tabs and content
$(".tab-links li").removeClass("active");
$(".tab-content .tab").removeClass("active").hide();
// Add active class to clicked tab and show the corresponding content
$(this).addClass("active");
var target = $(this).find("a").attr("href");
$(target).addClass("active").show();
});
$('.recrecenttab a').on('click', function(){
$('.recrecenttab a').removeClass('active');
$(this).addClass('active');
var isssss = $(this).attr('data_title');
$('.producttab').each(function(){
var isssssss = $(this).attr('data_title');
if(isssssss == isssss){
$(this).show();
// alert(isssss);
}else{
$(this).hide();
}
});
});
});
{"id":8820133560624,"title":"Over the Knee Patent Leather Premium Mettalic Boots","handle":"over-the-knee-patent-leather-mettalic-boots","description":"\u003cp\u003e\u003cstrong\u003eMaterial: PU\u003c\/strong\u003e\u003c\/p\u003e\n\u003cp\u003e \u003c\/p\u003e","published_at":"2023-11-08T17:42:03+05:30","created_at":"2023-11-07T18:06:48+05:30","vendor":"Alamode By Akanksha","type":"Shoes","tags":["Birthday theme","Boots for women","concert theme","EXPRESS","FAST","Footwear","india75","Ready to ship","Winter boots for women","Winter Collection","winter collection 2023"],"price":489900,"price_min":489900,"price_max":489900,"available":true,"price_varies":false,"compare_at_price":595000,"compare_at_price_min":595000,"compare_at_price_max":595000,"compare_at_price_varies":false,"variants":[{"id":47086236303664,"title":"37","option1":"37","option2":null,"option3":null,"sku":"SH_OVER_37","requires_shipping":true,"taxable":true,"featured_image":{"id":43274060497200,"product_id":8820133560624,"position":1,"created_at":"2023-11-07T18:08:03+05:30","updated_at":"2024-12-29T14:19:03+05:30","alt":"Over the Knee Patent Leather Premium Mettalic Boots - Alamode By Akanksha","width":800,"height":800,"src":"\/\/www.alamodelabel.in\/cdn\/shop\/files\/F6999227-C39B-4DA3-A34D-61CE2BEB216E.jpg?v=1735462143","variant_ids":[47086236303664,47086236336432,47086236369200,47086236401968]},"available":true,"name":"Over the Knee Patent Leather Premium Mettalic Boots - 37","public_title":"37","options":["37"],"price":489900,"weight":200,"compare_at_price":595000,"inventory_management":"shopify","barcode":null,"featured_media":{"alt":"Over the Knee Patent Leather Premium Mettalic Boots - Alamode By Akanksha","id":35671013228848,"position":1,"preview_image":{"aspect_ratio":1.0,"height":800,"width":800,"src":"\/\/www.alamodelabel.in\/cdn\/shop\/files\/F6999227-C39B-4DA3-A34D-61CE2BEB216E.jpg?v=1735462143"}},"requires_selling_plan":false,"selling_plan_allocations":[]},{"id":47086236336432,"title":"38","option1":"38","option2":null,"option3":null,"sku":"SH_OVER_38","requires_shipping":true,"taxable":true,"featured_image":{"id":43274060497200,"product_id":8820133560624,"position":1,"created_at":"2023-11-07T18:08:03+05:30","updated_at":"2024-12-29T14:19:03+05:30","alt":"Over the Knee Patent Leather Premium Mettalic Boots - Alamode By Akanksha","width":800,"height":800,"src":"\/\/www.alamodelabel.in\/cdn\/shop\/files\/F6999227-C39B-4DA3-A34D-61CE2BEB216E.jpg?v=1735462143","variant_ids":[47086236303664,47086236336432,47086236369200,47086236401968]},"available":false,"name":"Over the Knee Patent Leather Premium Mettalic Boots - 38","public_title":"38","options":["38"],"price":489900,"weight":200,"compare_at_price":595000,"inventory_management":"shopify","barcode":null,"featured_media":{"alt":"Over the Knee Patent Leather Premium Mettalic Boots - Alamode By Akanksha","id":35671013228848,"position":1,"preview_image":{"aspect_ratio":1.0,"height":800,"width":800,"src":"\/\/www.alamodelabel.in\/cdn\/shop\/files\/F6999227-C39B-4DA3-A34D-61CE2BEB216E.jpg?v=1735462143"}},"requires_selling_plan":false,"selling_plan_allocations":[]},{"id":47086236369200,"title":"39","option1":"39","option2":null,"option3":null,"sku":"SH_OVER_39","requires_shipping":true,"taxable":true,"featured_image":{"id":43274060497200,"product_id":8820133560624,"position":1,"created_at":"2023-11-07T18:08:03+05:30","updated_at":"2024-12-29T14:19:03+05:30","alt":"Over the Knee Patent Leather Premium Mettalic Boots - Alamode By Akanksha","width":800,"height":800,"src":"\/\/www.alamodelabel.in\/cdn\/shop\/files\/F6999227-C39B-4DA3-A34D-61CE2BEB216E.jpg?v=1735462143","variant_ids":[47086236303664,47086236336432,47086236369200,47086236401968]},"available":false,"name":"Over the Knee Patent Leather Premium Mettalic Boots - 39","public_title":"39","options":["39"],"price":489900,"weight":200,"compare_at_price":595000,"inventory_management":"shopify","barcode":null,"featured_media":{"alt":"Over the Knee Patent Leather Premium Mettalic Boots - Alamode By Akanksha","id":35671013228848,"position":1,"preview_image":{"aspect_ratio":1.0,"height":800,"width":800,"src":"\/\/www.alamodelabel.in\/cdn\/shop\/files\/F6999227-C39B-4DA3-A34D-61CE2BEB216E.jpg?v=1735462143"}},"requires_selling_plan":false,"selling_plan_allocations":[]},{"id":47086236401968,"title":"40","option1":"40","option2":null,"option3":null,"sku":"SH_OVER_40","requires_shipping":true,"taxable":true,"featured_image":{"id":43274060497200,"product_id":8820133560624,"position":1,"created_at":"2023-11-07T18:08:03+05:30","updated_at":"2024-12-29T14:19:03+05:30","alt":"Over the Knee Patent Leather Premium Mettalic Boots - Alamode By Akanksha","width":800,"height":800,"src":"\/\/www.alamodelabel.in\/cdn\/shop\/files\/F6999227-C39B-4DA3-A34D-61CE2BEB216E.jpg?v=1735462143","variant_ids":[47086236303664,47086236336432,47086236369200,47086236401968]},"available":false,"name":"Over the Knee Patent Leather Premium Mettalic Boots - 40","public_title":"40","options":["40"],"price":489900,"weight":200,"compare_at_price":595000,"inventory_management":"shopify","barcode":null,"featured_media":{"alt":"Over the Knee Patent Leather Premium Mettalic Boots - Alamode By Akanksha","id":35671013228848,"position":1,"preview_image":{"aspect_ratio":1.0,"height":800,"width":800,"src":"\/\/www.alamodelabel.in\/cdn\/shop\/files\/F6999227-C39B-4DA3-A34D-61CE2BEB216E.jpg?v=1735462143"}},"requires_selling_plan":false,"selling_plan_allocations":[]}],"images":["\/\/www.alamodelabel.in\/cdn\/shop\/files\/F6999227-C39B-4DA3-A34D-61CE2BEB216E.jpg?v=1735462143","\/\/www.alamodelabel.in\/cdn\/shop\/files\/1EF11185-E845-4A3A-9A9E-1E0E2DF7C5E7.jpg?v=1735462143","\/\/www.alamodelabel.in\/cdn\/shop\/files\/AA7785C2-7DE0-4E58-BBC5-25CD48AE8FAB.jpg?v=1735462143"],"featured_image":"\/\/www.alamodelabel.in\/cdn\/shop\/files\/F6999227-C39B-4DA3-A34D-61CE2BEB216E.jpg?v=1735462143","options":["Size"],"media":[{"alt":"Over the Knee Patent Leather Premium Mettalic Boots - Alamode By Akanksha","id":35671013228848,"position":1,"preview_image":{"aspect_ratio":1.0,"height":800,"width":800,"src":"\/\/www.alamodelabel.in\/cdn\/shop\/files\/F6999227-C39B-4DA3-A34D-61CE2BEB216E.jpg?v=1735462143"},"aspect_ratio":1.0,"height":800,"media_type":"image","src":"\/\/www.alamodelabel.in\/cdn\/shop\/files\/F6999227-C39B-4DA3-A34D-61CE2BEB216E.jpg?v=1735462143","width":800},{"alt":"Over the Knee Patent Leather Premium Mettalic Boots - Alamode By Akanksha","id":35671013261616,"position":2,"preview_image":{"aspect_ratio":1.0,"height":800,"width":800,"src":"\/\/www.alamodelabel.in\/cdn\/shop\/files\/1EF11185-E845-4A3A-9A9E-1E0E2DF7C5E7.jpg?v=1735462143"},"aspect_ratio":1.0,"height":800,"media_type":"image","src":"\/\/www.alamodelabel.in\/cdn\/shop\/files\/1EF11185-E845-4A3A-9A9E-1E0E2DF7C5E7.jpg?v=1735462143","width":800},{"alt":"Over the Knee Patent Leather Premium Mettalic Boots - Alamode By Akanksha","id":35671013294384,"position":3,"preview_image":{"aspect_ratio":1.0,"height":800,"width":800,"src":"\/\/www.alamodelabel.in\/cdn\/shop\/files\/AA7785C2-7DE0-4E58-BBC5-25CD48AE8FAB.jpg?v=1735462143"},"aspect_ratio":1.0,"height":800,"media_type":"image","src":"\/\/www.alamodelabel.in\/cdn\/shop\/files\/AA7785C2-7DE0-4E58-BBC5-25CD48AE8FAB.jpg?v=1735462143","width":800}],"requires_selling_plan":false,"selling_plan_groups":[],"content":"\u003cp\u003e\u003cstrong\u003eMaterial: PU\u003c\/strong\u003e\u003c\/p\u003e\n\u003cp\u003e \u003c\/p\u003e"}