Header Image
  • GBP£
  • Åland Islands (EUR€)
Albania (ALLL)
63 : parseInt(""),57747177832831 : parseInt(""),57747177865599 : parseInt(""),}; window._RestockRocketConfig.variantsPreorderCountForMarket = {57747177636223 : null,57747177668991 : null,57747177701759 : null,57747177734527 : null,57747177767295 : null,57747177800063 : null,57747177832831 : null,57747177865599 : null,}; window._RestockRocketConfig.variantsPreorderMaxCount = {57747177636223 : parseInt(""),57747177668991 : parseInt(""),57747177701759 : parseInt(""),57747177734527 : parseInt(""),57747177767295 : parseInt(""),57747177800063 : parseInt(""),57747177832831 : parseInt(""),57747177865599 : parseInt(""),}; window._RestockRocketConfig.variantsPreorderMaxCountForMarket = {57747177636223 : null,57747177668991 : null,57747177701759 : null,57747177734527 : null,57747177767295 : null,57747177800063 : null,57747177832831 : null,57747177865599 : null,}; window._RestockRocketConfig.variantsShippingText = {57747177636223 : "",57747177668991 : "",57747177701759 : "",57747177734527 : "",57747177767
he flag stays unset and both // consumers no-op. try { var _sqCfg = window._RestockRocketConfig; var _sqPlanEnabled = Array.isArray(_sqCfg.sellingPlans) && _sqCfg.sellingPlans.some(function (p) { return p && p.enabled; }); var _sqPreCount = ((_sqCfg.cachedPreorderVariantIds && _sqCfg.cachedPreorderVariantIds.preorder_variant_ids) || []).length; _sqCfg.preordersConfigured = !!(_sqPlanEnabled && _sqPreCount); } catch (e) { /* fail open */ } // STOQ-1612: block (not hide) Buy Now / Shop Pay until our JS runs, so a tap in the // load window can't bypass preorder. pointer-events via .stoq-buy-now-pending (no // reflow); timeout releases; renderPreorderButton / featured_product.js lift it. // Gated by the `block_accelerated_checkout` toggle (default OFF) for gradual rollout. // Armed ONLY when we're sure preorder is in play — product page: THIS product has a // preorder variant (never block a plain product's Shop Pay); featured: integration // enabled for this pageAlgeria (DZDد.ج) classList.remove('stoq-buy-now-pending'); }, 6000); } } catch (e) { /* fail open */ } window._RestockRocketConfig.scriptUrlProduct = 'https://cdn.shopify.com/extensions/019f37a7-f058-7bcb-a02d-3fb0b8a7522a/restockrocket-1-539/assets/restockrocket-product.js' window._RestockRocketConfig.scriptUrlCollection = 'https://cdn.shopify.com/extensions/019f37a7-f058-7bcb-a02d-3fb0b8a7522a/restockrocket-1-539/assets/restockrocket-collection.js' window._RestockRocketConfig.scriptUrlProductBis = 'https://cdn.shopify.com/extensions/019f37a7-f058-7bcb-a02d-3fb0b8a7522a/restockrocket-1-539/assets/restockrocket-product-bis.js' window._RestockRocketConfig.scriptUrlCollectionBis = 'https://cdn.shopify.com/extensions/019f37a7-f058-7bcb-a02d-3fb0b8a7522a/restockrocket-1-539/assets/restockrocket-collection-bis.js' window._RestockRocketConfig.scriptHost = window._RestockRocketConfig.scriptUrlProduct.substring(0, window._RestockRocketConfig.scriptUrlProduct.lastIndexOf('/') + 1) // Canary override (STOQ-1287 <
SETTINGS_CACHE_DURATION) { console.debug('STOQ - settings changed recently, skipping cache'); return null; } return settings; } catch (error) { console.debug('STOQ - Error checking settings cache:', error); return null; } } function createRestockRocketContainer() { const restockRocketContainer = document.createElement('div'); restockRocketContainer.id = 'restock-rocket'; document.body.appendChild(restockRocketContainer); } function createRestockRocketScript(scriptUrl) { const restockRocketScriptElement = document.createElement('script'); restockRocketScriptElement.setAttribute('defer', 'defer'); restockRocketScriptElement.src = scriptUrl; document.body.appendChild(restockRocketScriptElement); } createRestockRocketContainer() console.debug('STOQ - extension activated') // Fire stoq_initialized once per page load so the funnel pipeline has a definitive // "our code ran on this page" signal independent of any cus ctedVariantId || '', liquid_rendered_at: _stoqInitConfig.liquidRenderedAt || 0, app_version: _stoqInitConfig.appVersion || '', liquid_cache_age: _stoqInitConfig.liquidCacheAge, // Selected variant's stock posture as our app saw it at render — explains // whether we *should* have treated it as a preorder candidate. inventory_policy: (_stoqInitConfig.variantsInventoryPolicy || {})[_stoqSelectedVariantId] || '', inventory_quantity: (_stoqInitConfig.variantsInventoryQuantity || {})[_stoqSelectedVariantId], }); } catch (e) { console.debug('STOQ - stoq_initialized publish failed:', e); } // STOQ-1595: publish stoq_accelerated_checkout_clicked for every accelerated-checkout // click (Buy Now / dynamic checkout / Shop Pay installments) on ALL surfaces, before our // bundle loads, via one delegated capture-phase listener (catches late-rendered buttons). // Only on shops with preorders configured (shared `preordersConfigured` signal from the // derivati

p' }; if (window.Shopify?.theme?.role === 'main') { headers['X-Shopify-Theme-Schema-Name'] = window.Shopify.theme.schema_name; headers['X-Shopify-Theme-Schema-Version'] = window.Shopify.theme.schema_version; headers['X-Shopify-Theme-Store-Id'] = window.Shopify.theme.theme_store_id; } fetch( `${window._RestockRocketConfig.host}/api/v1/setting.json?translation_locale=${window._RestockRocketConfig.normalizedLocale}`, { headers } ) .then(function(response) { if (!response.ok) { throw new Error('Network response was not ok'); } return response.json(); }) .then(function(settings) { initializeScripts(settings); }) .catch(function(error) { // If request failed and we have cached settings (even if expired), use them as fallback if (cachedSettings) { console.debug('STOQ - using expired cached settings as fallback'); initializeScripts(cachedSettings); } else { console.error('S

endpoint + ':', applyError); throw applyError; } }) .catch(function(error) { console.debug(`STOQ - using cached ${endpoint}:`, error.message); }); } function initializeScripts(settings) { settings = applyTranslations(settings); window._RestockRocketConfig.settings = settings; console.debug(`STOQ - settings configured for ${window._RestockRocketConfig.pageType}`); // Stale-Liquid resilience (default-on, per-shop opt-out via the // `disable_refresh_on_stale_liquid` Toggle, surfaced as the negative // `disable_refresh_on_stale_liquid` flag in settings.json so that // `undefined` -- in CDN-cached metafield payloads that predate this // key -- reads as `!undefined === true` and gets default-on behavior // immediately, no metafield rewrite required). // When the Liquid CDN cache is older than LIQUID_CACHE_MAX_AGE the in-page // selling_plans / integrations metafields can be wrong; refresh both from // the API before launching scr
} }), fetchEmbedConfig('integrations', function(data) { if (Array.isArray(data)) { window._RestockRocketConfig.integrations = data; } }) ]), new Promise(function(resolve) { setTimeout(resolve, 1000); }) ]).then(function() { loadScripts(settings); }); return; } loadScripts(settings); } function loadScripts(settings) { // Setup cart selling plan updater BEFORE loading any scripts to avoid race conditions setupCartSellingPlanUpdater(settings); if(settings.enable_app) { const hijackIntegration = window._RestockRocketConfig.integrations.find(function(integration) { return integration.type === 'hijack' && integration.enabled && integration.page_types.includes(window._RestockRocketConfig.pageType); }) // STOQ-1520: serve the lean back-in-stock-only build (no preorder/hijack code) // only to shops with NO preorder plans. Use the full build if preorder is o onPageTypes = ['collection', 'index', 'search', 'page']; if(collectionPageTypes.indexOf(pageType) !== -1 && (settings[`show_button_on_${pageType}`] || settings[`preorder_${pageType}_enabled`])) { createRestockRocketScript(collectionScriptUrl); } else if(pageType === 'product') { createRestockRocketScript(productScriptUrl); } else if(hijackIntegration) { createRestockRocketScript(window._RestockRocketConfig.scriptUrlCollection); } else if(usePreorderBuild) { // cart/article/blog/list-collections: full build so the cart sweep runs. createRestockRocketScript(window._RestockRocketConfig.scriptUrlCollection); } else { console.debug(`STOQ - no scripts enabled for ${pageType}`); } // Dispatch custom event when app is loaded // Cart selling plan updates will be triggered by stoq:inventory-data-loaded event const appLoadedEvent = new CustomEvent('stoq:loaded', { detail: { pageType: window._RestockRAustria (EUR€)
Belarus (GBP£)
Belgium (EUR€)
Eswatini (GBP£)