"use strict";(self.webpackChunkR2U=self.webpackChunkR2U||[]).push([[869],{5004:function(e,t,n){n.r(t);var s=n(7294),r=n(3935),o=n(9361),i=n.n(o),u=n(2367),a=function(e,t,n,s){return new(n||(n=Promise))((function(r,o){function i(e){try{a(s.next(e))}catch(e){o(e)}}function u(e){try{a(s.throw(e))}catch(e){o(e)}}function a(e){var t;e.done?r(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(i,u)}a((s=s.apply(e,t||[])).next())}))};const c=({element:e,sku:t,showInstructions:n="always"})=>{const{language:o,_id:a}=u.Z.customer,c=new URL("https://viewer.r2u.io");c.searchParams.set("customerId",a),c.searchParams.set("sku",t),c.searchParams.set("showInstructions",n),o&&c.searchParams.set("lng",o),r.render(s.createElement(i(),Object.assign({},{"data-url":c},{value:c.toString(),style:{width:"100%",height:"100%"},renderAs:"svg"})),e)};t.default={create:function({element:e,sku:t,showInstructions:n}){return a(this,void 0,void 0,(function*(){if(!u.Z.init)return Promise.reject(new Error("R2U - Not initialized"));c({element:e,sku:t,showInstructions:n});return{setSku:t=>a(this,void 0,void 0,(function*(){c({element:e,sku:t,showInstructions:n})}))}}))}}},2367:function(e,t){const n={init:!1,customer:{_id:"",slug:"",language:"en",hdri:null,exposure:null,bloom:null,experiments:{overrides:{}},viewerOptions:{}},analytics:{set:(e,t)=>{},send:({event:e,data:t,scope:n})=>Promise.resolve()},products:{},hasAutoOpenedAR:!1,growthbook:{},refreshCache:!1};t.Z=n}}]);