$product = {"id":7888447635555,"title":"iPhone 12 \/ 12 Pro Mod NX (MagSafe 兼容) 布朗尼 annnbrownie 生日派對","handle":"iphone-12-pro-mod-nx-magsafe-printable-es01","description":null,"published_at":"2025-09-23T09:17:35+08:00","created_at":"2025-09-22T15:45:53+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"","tags":["10%","20%","30%","40%","50%","brand-Apple","designer","designer-annnbrownie","device-iPhone 12 Pro","merge","reseller-annnbrownie"],"price":110000,"price_min":110000,"price_max":110000,"available":true,"price_varies":false,"compare_at_price":null,"compare_at_price_min":0,"compare_at_price_max":0,"compare_at_price_varies":false,"variants":[{"id":43743151063139,"title":"Lavender","option1":"Lavender","option2":null,"option3":null,"sku":"MPB01185C1-ES01","requires_shipping":true,"taxable":true,"featured_image":{"id":34514457264227,"product_id":7888447635555,"position":3,"created_at":"2025-09-22T15:45:58+08:00","updated_at":"2025-09-22T15:46:00+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/81e94fbb2964ccc381bbb7f65c31903f66860f99.webp?v=1758527160","variant_ids":[43743151063139]},"available":true,"name":"iPhone 12 \/ 12 Pro Mod NX (MagSafe 兼容) 布朗尼 annnbrownie 生日派對 - Lavender","public_title":"Lavender","options":["Lavender"],"price":110000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB01185C1-ES01","featured_media":{"alt":null,"id":26084899782755,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/81e94fbb2964ccc381bbb7f65c31903f66860f99.webp?v=1758527160"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43743154896995,"title":"White","option1":"White","option2":null,"option3":null,"sku":"MPB0118504-ES01","requires_shipping":true,"taxable":true,"featured_image":{"id":34514456936547,"product_id":7888447635555,"position":2,"created_at":"2025-09-22T15:45:57+08:00","updated_at":"2025-09-22T15:45:59+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/52e1f7bed11a31f70570b2b4cf9c3a17a2d780bd.webp?v=1758527159","variant_ids":[43743154896995]},"available":true,"name":"iPhone 12 \/ 12 Pro Mod NX (MagSafe 兼容) 布朗尼 annnbrownie 生日派對 - White","public_title":"White","options":["White"],"price":110000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118504-ES01","featured_media":{"alt":null,"id":26084899455075,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/52e1f7bed11a31f70570b2b4cf9c3a17a2d780bd.webp?v=1758527159"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43743154929763,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"MPB0118524-ES01","requires_shipping":true,"taxable":true,"featured_image":{"id":34514458148963,"product_id":7888447635555,"position":6,"created_at":"2025-09-22T15:45:59+08:00","updated_at":"2025-09-22T15:46:01+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5944d42c818103f967a2539033b61efec9eaff00.webp?v=1758527161","variant_ids":[43743154929763]},"available":true,"name":"iPhone 12 \/ 12 Pro Mod NX (MagSafe 兼容) 布朗尼 annnbrownie 生日派對 - Black","public_title":"Black","options":["Black"],"price":110000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118524-ES01","featured_media":{"alt":null,"id":26084900667491,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5944d42c818103f967a2539033b61efec9eaff00.webp?v=1758527161"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43743154995299,"title":"Graphite","option1":"Graphite","option2":null,"option3":null,"sku":"MPB0118569-ES01","requires_shipping":true,"taxable":true,"featured_image":{"id":34514458837091,"product_id":7888447635555,"position":9,"created_at":"2025-09-22T15:46:00+08:00","updated_at":"2025-09-22T15:46:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0e8e0516ee7722c7326821d4af34280d71e0c449.webp?v=1758527163","variant_ids":[43743154995299]},"available":true,"name":"iPhone 12 \/ 12 Pro Mod NX (MagSafe 兼容) 布朗尼 annnbrownie 生日派對 - Graphite","public_title":"Graphite","options":["Graphite"],"price":110000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118569-ES01","featured_media":{"alt":null,"id":26084901355619,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0e8e0516ee7722c7326821d4af34280d71e0c449.webp?v=1758527163"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43743155093603,"title":"Navy Blue","option1":"Navy Blue","option2":null,"option3":null,"sku":"MPB01185J5-ES01","requires_shipping":true,"taxable":true,"featured_image":{"id":34514459197539,"product_id":7888447635555,"position":11,"created_at":"2025-09-22T15:46:01+08:00","updated_at":"2025-09-22T15:46:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7d179c3ca73ab74b0281abf5e1a7c1538d3cd4e8.webp?v=1758527163","variant_ids":[43743155093603]},"available":true,"name":"iPhone 12 \/ 12 Pro Mod NX (MagSafe 兼容) 布朗尼 annnbrownie 生日派對 - Navy Blue","public_title":"Navy Blue","options":["Navy Blue"],"price":110000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB01185J5-ES01","featured_media":{"alt":null,"id":26084901716067,"position":11,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7d179c3ca73ab74b0281abf5e1a7c1538d3cd4e8.webp?v=1758527163"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/82253d4dbf75321e0dc3528ad74a8629cf2d9b72.webp?v=1758527159","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/52e1f7bed11a31f70570b2b4cf9c3a17a2d780bd.webp?v=1758527159","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/81e94fbb2964ccc381bbb7f65c31903f66860f99.webp?v=1758527160","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f2ac14108ce8be34061563deaf57179a9acfaef2.webp?v=1758527160","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/14590309411cce5b2b6594ca32efdeb4b395bb43.webp?v=1758527161","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5944d42c818103f967a2539033b61efec9eaff00.webp?v=1758527161","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dad405ef411d51dffee4f89a38c7f9eee7f580a0.webp?v=1758527162","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9af8fc466fcd3853f3fdd6c76ce6680e29ea74b7.webp?v=1758527162","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0e8e0516ee7722c7326821d4af34280d71e0c449.webp?v=1758527163","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b208be7cc5815bc5987ab6240e4661707ad0d93b.webp?v=1758527163","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7d179c3ca73ab74b0281abf5e1a7c1538d3cd4e8.webp?v=1758527163"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/82253d4dbf75321e0dc3528ad74a8629cf2d9b72.webp?v=1758527159","options":["color"],"media":[{"alt":null,"id":26084899258467,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/82253d4dbf75321e0dc3528ad74a8629cf2d9b72.webp?v=1758527159"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/82253d4dbf75321e0dc3528ad74a8629cf2d9b72.webp?v=1758527159","width":2000},{"alt":null,"id":26084899455075,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/52e1f7bed11a31f70570b2b4cf9c3a17a2d780bd.webp?v=1758527159"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/52e1f7bed11a31f70570b2b4cf9c3a17a2d780bd.webp?v=1758527159","width":2000},{"alt":null,"id":26084899782755,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/81e94fbb2964ccc381bbb7f65c31903f66860f99.webp?v=1758527160"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/81e94fbb2964ccc381bbb7f65c31903f66860f99.webp?v=1758527160","width":2000},{"alt":null,"id":26084900110435,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f2ac14108ce8be34061563deaf57179a9acfaef2.webp?v=1758527160"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f2ac14108ce8be34061563deaf57179a9acfaef2.webp?v=1758527160","width":2000},{"alt":null,"id":26084900405347,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/14590309411cce5b2b6594ca32efdeb4b395bb43.webp?v=1758527161"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/14590309411cce5b2b6594ca32efdeb4b395bb43.webp?v=1758527161","width":2000},{"alt":null,"id":26084900667491,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5944d42c818103f967a2539033b61efec9eaff00.webp?v=1758527161"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5944d42c818103f967a2539033b61efec9eaff00.webp?v=1758527161","width":2000},{"alt":null,"id":26084900929635,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dad405ef411d51dffee4f89a38c7f9eee7f580a0.webp?v=1758527162"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dad405ef411d51dffee4f89a38c7f9eee7f580a0.webp?v=1758527162","width":2000},{"alt":null,"id":26084901159011,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9af8fc466fcd3853f3fdd6c76ce6680e29ea74b7.webp?v=1758527162"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9af8fc466fcd3853f3fdd6c76ce6680e29ea74b7.webp?v=1758527162","width":2000},{"alt":null,"id":26084901355619,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0e8e0516ee7722c7326821d4af34280d71e0c449.webp?v=1758527163"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0e8e0516ee7722c7326821d4af34280d71e0c449.webp?v=1758527163","width":2000},{"alt":null,"id":26084901584995,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b208be7cc5815bc5987ab6240e4661707ad0d93b.webp?v=1758527163"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b208be7cc5815bc5987ab6240e4661707ad0d93b.webp?v=1758527163","width":2000},{"alt":null,"id":26084901716067,"position":11,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7d179c3ca73ab74b0281abf5e1a7c1538d3cd4e8.webp?v=1758527163"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7d179c3ca73ab74b0281abf5e1a7c1538d3cd4e8.webp?v=1758527163","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $bumper = null; $variants = [{"id":43743151063139,"title":"Lavender","option1":"Lavender","option2":null,"option3":null,"sku":"MPB01185C1-ES01","requires_shipping":true,"taxable":true,"featured_image":{"id":34514457264227,"product_id":7888447635555,"position":3,"created_at":"2025-09-22T15:45:58+08:00","updated_at":"2025-09-22T15:46:00+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/81e94fbb2964ccc381bbb7f65c31903f66860f99.webp?v=1758527160","variant_ids":[43743151063139]},"available":true,"name":"iPhone 12 \/ 12 Pro Mod NX (MagSafe 兼容) 布朗尼 annnbrownie 生日派對 - Lavender","public_title":"Lavender","options":["Lavender"],"price":110000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB01185C1-ES01","featured_media":{"alt":null,"id":26084899782755,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/81e94fbb2964ccc381bbb7f65c31903f66860f99.webp?v=1758527160"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43743154896995,"title":"White","option1":"White","option2":null,"option3":null,"sku":"MPB0118504-ES01","requires_shipping":true,"taxable":true,"featured_image":{"id":34514456936547,"product_id":7888447635555,"position":2,"created_at":"2025-09-22T15:45:57+08:00","updated_at":"2025-09-22T15:45:59+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/52e1f7bed11a31f70570b2b4cf9c3a17a2d780bd.webp?v=1758527159","variant_ids":[43743154896995]},"available":true,"name":"iPhone 12 \/ 12 Pro Mod NX (MagSafe 兼容) 布朗尼 annnbrownie 生日派對 - White","public_title":"White","options":["White"],"price":110000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118504-ES01","featured_media":{"alt":null,"id":26084899455075,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/52e1f7bed11a31f70570b2b4cf9c3a17a2d780bd.webp?v=1758527159"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43743154929763,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"MPB0118524-ES01","requires_shipping":true,"taxable":true,"featured_image":{"id":34514458148963,"product_id":7888447635555,"position":6,"created_at":"2025-09-22T15:45:59+08:00","updated_at":"2025-09-22T15:46:01+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5944d42c818103f967a2539033b61efec9eaff00.webp?v=1758527161","variant_ids":[43743154929763]},"available":true,"name":"iPhone 12 \/ 12 Pro Mod NX (MagSafe 兼容) 布朗尼 annnbrownie 生日派對 - Black","public_title":"Black","options":["Black"],"price":110000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118524-ES01","featured_media":{"alt":null,"id":26084900667491,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5944d42c818103f967a2539033b61efec9eaff00.webp?v=1758527161"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43743154995299,"title":"Graphite","option1":"Graphite","option2":null,"option3":null,"sku":"MPB0118569-ES01","requires_shipping":true,"taxable":true,"featured_image":{"id":34514458837091,"product_id":7888447635555,"position":9,"created_at":"2025-09-22T15:46:00+08:00","updated_at":"2025-09-22T15:46:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0e8e0516ee7722c7326821d4af34280d71e0c449.webp?v=1758527163","variant_ids":[43743154995299]},"available":true,"name":"iPhone 12 \/ 12 Pro Mod NX (MagSafe 兼容) 布朗尼 annnbrownie 生日派對 - Graphite","public_title":"Graphite","options":["Graphite"],"price":110000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118569-ES01","featured_media":{"alt":null,"id":26084901355619,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0e8e0516ee7722c7326821d4af34280d71e0c449.webp?v=1758527163"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43743155093603,"title":"Navy Blue","option1":"Navy Blue","option2":null,"option3":null,"sku":"MPB01185J5-ES01","requires_shipping":true,"taxable":true,"featured_image":{"id":34514459197539,"product_id":7888447635555,"position":11,"created_at":"2025-09-22T15:46:01+08:00","updated_at":"2025-09-22T15:46:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7d179c3ca73ab74b0281abf5e1a7c1538d3cd4e8.webp?v=1758527163","variant_ids":[43743155093603]},"available":true,"name":"iPhone 12 \/ 12 Pro Mod NX (MagSafe 兼容) 布朗尼 annnbrownie 生日派對 - Navy Blue","public_title":"Navy Blue","options":["Navy Blue"],"price":110000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB01185J5-ES01","featured_media":{"alt":null,"id":26084901716067,"position":11,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7d179c3ca73ab74b0281abf5e1a7c1538d3cd4e8.webp?v=1758527163"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":43743151063139,"title":"Lavender","option1":"Lavender","option2":null,"option3":null,"sku":"MPB01185C1-ES01","requires_shipping":true,"taxable":true,"featured_image":{"id":34514457264227,"product_id":7888447635555,"position":3,"created_at":"2025-09-22T15:45:58+08:00","updated_at":"2025-09-22T15:46:00+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/81e94fbb2964ccc381bbb7f65c31903f66860f99.webp?v=1758527160","variant_ids":[43743151063139]},"available":true,"name":"iPhone 12 \/ 12 Pro Mod NX (MagSafe 兼容) 布朗尼 annnbrownie 生日派對 - Lavender","public_title":"Lavender","options":["Lavender"],"price":110000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB01185C1-ES01","featured_media":{"alt":null,"id":26084899782755,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/81e94fbb2964ccc381bbb7f65c31903f66860f99.webp?v=1758527160"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}; $device_handle = null var sellingStatus if ($bumper) { $(document).ready(function() { var productImg = $product.images[0] var bumperVariants = $bumper.variants; var bumperColors = new Object(); var currentVariant = ''; var productType = ''; bumperVariants.forEach(variant => { bumperColors[`${variant.title.split(' (')[0].toLowerCase()}`] = variant.featured_image.src; }); if (productType === 'mod-nx-backplate' || productType === 'mod-backplate') { mergeImages( [productImg, bumperColors[currentVariant]], { crossOrigin: 'anonymous' } ).then(mergedImg => { $('.merged-img').attr('src', mergedImg); }); } else { mergeImages( [bumperColors[currentVariant], productImg], { crossOrigin: 'anonymous' } ).then(mergedImg => { $('.merged-img').attr('src', mergedImg); }); } }); }; var sellingStatusData window.fetchSellingStatus().then(data => { try { sellingStatusData = data; } catch (error) { sellingStatusData = null console.error('Unable to parse selling status', error) } $(document).ready(function() { handleSellingStatus($defaultVariant.sku); }); }) function handleSellingStatus(currentSku) { if (!sellingStatusData) { console.error('No selling status available!') return } const sellingStatusElement = document.getElementById('selling-status') const addToCartButton = document.getElementById('AddToCart-product-template') const currentProductSku = currentSku.replace(/-(.*)$/, '-') if ($variants) { const flattenedSellingStatus = [...sellingStatusData.pending, ...sellingStatusData.preorder] const matchSellingStatusProduct = flattenedSellingStatus.filter(product => currentProductSku === product.sku) if (matchSellingStatusProduct.length > 0) { const isProductPending = matchSellingStatusProduct[0].status === 'pending' const matchDate = matchSellingStatusProduct[0].date sellingStatus = isProductPending ? "缺貨中" : "預購完成出貨日:" + matchDate sellingStatusElement.textContent = sellingStatus if (sellingStatus.includes("缺貨中")){ addToCartButton.disabled ='true'; addToCartButton.textContent = "缺貨中無法加入購物車" } else { addToCartButton.textContent = "加到購物車" } } else { sellingStatusElement.textContent = '' addToCartButton.textContent = "加到購物車" }; }; }; document.addEventListener('DOMContentLoaded', function () { var currentVariantSelect = document.getElementById('SingleOptionSelector-0') currentVariantSelect.addEventListener('change', function() { var currentSku = $('#current_sku').text() var skuElement = document.getElementById('current-sku') skuElement.textContent = currentSku handleSellingStatus(currentSku) }); });
// Override default values of shop.strings for each template. // Alternate product templates can change values of // add to cart button, sold out, and unavailable states here. theme.productStrings = { addToCart: "加到購物車", soldOut: "售完", unavailable: "停產" }