New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@loophq/onstore-sdk

Package Overview
Dependencies
Maintainers
17
Versions
41
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@loophq/onstore-sdk - npm Package Compare versions

Comparing version 1.0.17 to 1.1.0

2

dist/loop-onstore-sdk.js

@@ -1,1 +0,1 @@

!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.LoopOnstore=e():t.LoopOnstore=e()}(window,(function(){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var o=e[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)n.d(r,o,function(e){return t[e]}.bind(null,o));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=107)}([function(t,e,n){(function(e){var n=function(t){return t&&t.Math==Math&&t};t.exports=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof e&&e)||Function("return this")()}).call(this,n(59))},function(t,e,n){var r=n(0),o=n(38),i=n(5),c=n(39),a=n(42),u=n(72),s=o("wks"),l=r.Symbol,f=u?l:c;t.exports=function(t){return i(s,t)||(a&&i(l,t)?s[t]=l[t]:s[t]=f("Symbol."+t)),s[t]}},function(t,e,n){var r=n(8);t.exports=function(t){if(!r(t))throw TypeError(String(t)+" is not an object");return t}},function(t,e){t.exports=function(t){try{return!!t()}catch(t){return!0}}},function(t,e){t.exports=function(t){if(null==t)throw TypeError("Can't call method on "+t);return t}},function(t,e){var n={}.hasOwnProperty;t.exports=function(t,e){return n.call(t,e)}},function(t,e,n){var r=n(9),o=n(12),i=n(22);t.exports=r?function(t,e,n){return o.f(t,e,i(1,n))}:function(t,e,n){return t[e]=n,t}},function(t,e){var n={}.toString;t.exports=function(t){return n.call(t).slice(8,-1)}},function(t,e){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},function(t,e,n){var r=n(3);t.exports=!r((function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a}))},function(t,e){var n=Math.ceil,r=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?r:n)(t)}},function(t,e,n){var r=n(0),o=n(18).f,i=n(6),c=n(13),a=n(24),u=n(63),s=n(41);t.exports=function(t,e){var n,l,f,p,d,v=t.target,h=t.global,y=t.stat;if(n=h?r:y?r[v]||a(v,{}):(r[v]||{}).prototype)for(l in e){if(p=e[l],f=t.noTargetGet?(d=o(n,l))&&d.value:n[l],!s(h?l:v+(y?".":"#")+l,t.forced)&&void 0!==f){if(typeof p==typeof f)continue;u(p,f)}(t.sham||f&&f.sham)&&i(p,"sham",!0),c(n,l,p,t)}}},function(t,e,n){var r=n(9),o=n(36),i=n(2),c=n(35),a=Object.defineProperty;e.f=r?a:function(t,e,n){if(i(t),e=c(e,!0),i(n),o)try{return a(t,e,n)}catch(t){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(t[e]=n.value),t}},function(t,e,n){var r=n(0),o=n(6),i=n(5),c=n(24),a=n(25),u=n(26),s=u.get,l=u.enforce,f=String(String).split("String");(t.exports=function(t,e,n,a){var u=!!a&&!!a.unsafe,s=!!a&&!!a.enumerable,p=!!a&&!!a.noTargetGet;"function"==typeof n&&("string"!=typeof e||i(n,"name")||o(n,"name",e),l(n).source=f.join("string"==typeof e?e:"")),t!==r?(u?!p&&t[e]&&(s=!0):delete t[e],s?t[e]=n:o(t,e,n)):s?t[e]=n:c(e,n)})(Function.prototype,"toString",(function(){return"function"==typeof this&&s(this).source||a(this)}))},function(t,e){t.exports=!1},function(t,e,n){var r=n(65),o=n(0),i=function(t){return"function"==typeof t?t:void 0};t.exports=function(t,e){return arguments.length<2?i(r[t])||i(o[t]):r[t]&&r[t][e]||o[t]&&o[t][e]}},function(t,e,n){var r=n(10),o=Math.min;t.exports=function(t){return t>0?o(r(t),9007199254740991):0}},function(t,e){t.exports={}},function(t,e,n){var r=n(9),o=n(60),i=n(22),c=n(19),a=n(35),u=n(5),s=n(36),l=Object.getOwnPropertyDescriptor;e.f=r?l:function(t,e){if(t=c(t),e=a(e,!0),s)try{return l(t,e)}catch(t){}if(u(t,e))return i(!o.f.call(t,e),t[e])}},function(t,e,n){var r=n(61),o=n(4);t.exports=function(t){return r(o(t))}},function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(String(t)+" is not a function");return t}},function(t,e,n){var r=n(0),o=n(87),i=n(88),c=n(6),a=n(1),u=a("iterator"),s=a("toStringTag"),l=i.values;for(var f in o){var p=r[f],d=p&&p.prototype;if(d){if(d[u]!==l)try{c(d,u,l)}catch(t){d[u]=l}if(d[s]||c(d,s,f),o[f])for(var v in i)if(d[v]!==i[v])try{c(d,v,i[v])}catch(t){d[v]=i[v]}}}},function(t,e){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},function(t,e,n){var r=n(0),o=n(8),i=r.document,c=o(i)&&o(i.createElement);t.exports=function(t){return c?i.createElement(t):{}}},function(t,e,n){var r=n(0),o=n(6);t.exports=function(t,e){try{o(r,t,e)}catch(n){r[t]=e}return e}},function(t,e,n){var r=n(37),o=Function.toString;"function"!=typeof r.inspectSource&&(r.inspectSource=function(t){return o.call(t)}),t.exports=r.inspectSource},function(t,e,n){var r,o,i,c=n(62),a=n(0),u=n(8),s=n(6),l=n(5),f=n(27),p=n(28),d=a.WeakMap;if(c){var v=new d,h=v.get,y=v.has,m=v.set;r=function(t,e){return m.call(v,t,e),e},o=function(t){return h.call(v,t)||{}},i=function(t){return y.call(v,t)}}else{var g=f("state");p[g]=!0,r=function(t,e){return s(t,g,e),e},o=function(t){return l(t,g)?t[g]:{}},i=function(t){return l(t,g)}}t.exports={set:r,get:o,has:i,enforce:function(t){return i(t)?o(t):r(t,{})},getterFor:function(t){return function(e){var n;if(!u(e)||(n=o(e)).type!==t)throw TypeError("Incompatible receiver, "+t+" required");return n}}}},function(t,e,n){var r=n(38),o=n(39),i=r("keys");t.exports=function(t){return i[t]||(i[t]=o(t))}},function(t,e){t.exports={}},function(t,e){t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},function(t,e,n){var r=n(12).f,o=n(5),i=n(1)("toStringTag");t.exports=function(t,e,n){t&&!o(t=n?t:t.prototype,i)&&r(t,i,{configurable:!0,value:e})}},function(t,e,n){"use strict";var r=n(6),o=n(13),i=n(3),c=n(1),a=n(32),u=c("species"),s=!i((function(){var t=/./;return t.exec=function(){var t=[];return t.groups={a:"7"},t},"7"!=="".replace(t,"$<a>")})),l=!i((function(){var t=/(?:)/,e=t.exec;t.exec=function(){return e.apply(this,arguments)};var n="ab".split(t);return 2!==n.length||"a"!==n[0]||"b"!==n[1]}));t.exports=function(t,e,n,f){var p=c(t),d=!i((function(){var e={};return e[p]=function(){return 7},7!=""[t](e)})),v=d&&!i((function(){var e=!1,n=/a/;return"split"===t&&((n={}).constructor={},n.constructor[u]=function(){return n},n.flags="",n[p]=/./[p]),n.exec=function(){return e=!0,null},n[p](""),!e}));if(!d||!v||"replace"===t&&!s||"split"===t&&!l){var h=/./[p],y=n(p,""[t],(function(t,e,n,r,o){return e.exec===a?d&&!o?{done:!0,value:h.call(e,n,r)}:{done:!0,value:t.call(n,e,r)}:{done:!1}})),m=y[0],g=y[1];o(String.prototype,t,m),o(RegExp.prototype,p,2==e?function(t,e){return g.call(t,this,e)}:function(t){return g.call(t,this)}),f&&r(RegExp.prototype[p],"sham",!0)}}},function(t,e,n){"use strict";var r,o,i=n(101),c=RegExp.prototype.exec,a=String.prototype.replace,u=c,s=(r=/a/,o=/b*/g,c.call(r,"a"),c.call(o,"a"),0!==r.lastIndex||0!==o.lastIndex),l=void 0!==/()??/.exec("")[1];(s||l)&&(u=function(t){var e,n,r,o,u=this;return l&&(n=new RegExp("^"+u.source+"$(?!\\s)",i.call(u))),s&&(e=u.lastIndex),r=c.call(u,t),s&&r&&(u.lastIndex=u.global?r.index+r[0].length:e),l&&r&&r.length>1&&a.call(r[0],n,(function(){for(o=1;o<arguments.length-2;o++)void 0===arguments[o]&&(r[o]=void 0)})),r}),t.exports=u},function(t,e,n){var r=n(7),o=n(32);t.exports=function(t,e){var n=t.exec;if("function"==typeof n){var i=n.call(t,e);if("object"!=typeof i)throw TypeError("RegExp exec method returned something other than an Object or null");return i}if("RegExp"!==r(t))throw TypeError("RegExp#exec called on incompatible receiver");return o.call(t,e)}},function(t,e,n){"use strict";var r,o,i,c,a=n(11),u=n(14),s=n(0),l=n(15),f=n(70),p=n(13),d=n(71),v=n(30),h=n(73),y=n(8),m=n(20),g=n(74),b=n(7),x=n(25),w=n(75),O=n(81),S=n(44),_=n(45).set,j=n(82),P=n(83),k=n(84),E=n(49),L=n(85),I=n(26),C=n(41),T=n(1),A=n(86),M=T("species"),R="Promise",D=I.get,N=I.set,F=I.getterFor(R),U=f,z=s.TypeError,q=s.document,G=s.process,$=l("fetch"),H=E.f,B=H,W="process"==b(G),V=!!(q&&q.createEvent&&s.dispatchEvent),J=C(R,(function(){if(!(x(U)!==String(U))){if(66===A)return!0;if(!W&&"function"!=typeof PromiseRejectionEvent)return!0}if(u&&!U.prototype.finally)return!0;if(A>=51&&/native code/.test(U))return!1;var t=U.resolve(1),e=function(t){t((function(){}),(function(){}))};return(t.constructor={})[M]=e,!(t.then((function(){}))instanceof e)})),Y=J||!O((function(t){U.all(t).catch((function(){}))})),K=function(t){var e;return!(!y(t)||"function"!=typeof(e=t.then))&&e},Z=function(t,e,n){if(!e.notified){e.notified=!0;var r=e.reactions;j((function(){for(var o=e.value,i=1==e.state,c=0;r.length>c;){var a,u,s,l=r[c++],f=i?l.ok:l.fail,p=l.resolve,d=l.reject,v=l.domain;try{f?(i||(2===e.rejection&&et(t,e),e.rejection=1),!0===f?a=o:(v&&v.enter(),a=f(o),v&&(v.exit(),s=!0)),a===l.promise?d(z("Promise-chain cycle")):(u=K(a))?u.call(a,p,d):p(a)):d(o)}catch(t){v&&!s&&v.exit(),d(t)}}e.reactions=[],e.notified=!1,n&&!e.rejection&&Q(t,e)}))}},X=function(t,e,n){var r,o;V?((r=q.createEvent("Event")).promise=e,r.reason=n,r.initEvent(t,!1,!0),s.dispatchEvent(r)):r={promise:e,reason:n},(o=s["on"+t])?o(r):"unhandledrejection"===t&&k("Unhandled promise rejection",n)},Q=function(t,e){_.call(s,(function(){var n,r=e.value;if(tt(e)&&(n=L((function(){W?G.emit("unhandledRejection",r,t):X("unhandledrejection",t,r)})),e.rejection=W||tt(e)?2:1,n.error))throw n.value}))},tt=function(t){return 1!==t.rejection&&!t.parent},et=function(t,e){_.call(s,(function(){W?G.emit("rejectionHandled",t):X("rejectionhandled",t,e.value)}))},nt=function(t,e,n,r){return function(o){t(e,n,o,r)}},rt=function(t,e,n,r){e.done||(e.done=!0,r&&(e=r),e.value=n,e.state=2,Z(t,e,!0))},ot=function(t,e,n,r){if(!e.done){e.done=!0,r&&(e=r);try{if(t===n)throw z("Promise can't be resolved itself");var o=K(n);o?j((function(){var r={done:!1};try{o.call(n,nt(ot,t,r,e),nt(rt,t,r,e))}catch(n){rt(t,r,n,e)}})):(e.value=n,e.state=1,Z(t,e,!1))}catch(n){rt(t,{done:!1},n,e)}}};J&&(U=function(t){g(this,U,R),m(t),r.call(this);var e=D(this);try{t(nt(ot,this,e),nt(rt,this,e))}catch(t){rt(this,e,t)}},(r=function(t){N(this,{type:R,done:!1,notified:!1,parent:!1,reactions:[],rejection:!1,state:0,value:void 0})}).prototype=d(U.prototype,{then:function(t,e){var n=F(this),r=H(S(this,U));return r.ok="function"!=typeof t||t,r.fail="function"==typeof e&&e,r.domain=W?G.domain:void 0,n.parent=!0,n.reactions.push(r),0!=n.state&&Z(this,n,!1),r.promise},catch:function(t){return this.then(void 0,t)}}),o=function(){var t=new r,e=D(t);this.promise=t,this.resolve=nt(ot,t,e),this.reject=nt(rt,t,e)},E.f=H=function(t){return t===U||t===i?new o(t):B(t)},u||"function"!=typeof f||(c=f.prototype.then,p(f.prototype,"then",(function(t,e){var n=this;return new U((function(t,e){c.call(n,t,e)})).then(t,e)}),{unsafe:!0}),"function"==typeof $&&a({global:!0,enumerable:!0,forced:!0},{fetch:function(t){return P(U,$.apply(s,arguments))}}))),a({global:!0,wrap:!0,forced:J},{Promise:U}),v(U,R,!1,!0),h(R),i=l(R),a({target:R,stat:!0,forced:J},{reject:function(t){var e=H(this);return e.reject.call(void 0,t),e.promise}}),a({target:R,stat:!0,forced:u||J},{resolve:function(t){return P(u&&this===i?U:this,t)}}),a({target:R,stat:!0,forced:Y},{all:function(t){var e=this,n=H(e),r=n.resolve,o=n.reject,i=L((function(){var n=m(e.resolve),i=[],c=0,a=1;w(t,(function(t){var u=c++,s=!1;i.push(void 0),a++,n.call(e,t).then((function(t){s||(s=!0,i[u]=t,--a||r(i))}),o)})),--a||r(i)}));return i.error&&o(i.value),n.promise},race:function(t){var e=this,n=H(e),r=n.reject,o=L((function(){var o=m(e.resolve);w(t,(function(t){o.call(e,t).then(n.resolve,r)}))}));return o.error&&r(o.value),n.promise}})},function(t,e,n){var r=n(8);t.exports=function(t,e){if(!r(t))return t;var n,o;if(e&&"function"==typeof(n=t.toString)&&!r(o=n.call(t)))return o;if("function"==typeof(n=t.valueOf)&&!r(o=n.call(t)))return o;if(!e&&"function"==typeof(n=t.toString)&&!r(o=n.call(t)))return o;throw TypeError("Can't convert object to primitive value")}},function(t,e,n){var r=n(9),o=n(3),i=n(23);t.exports=!r&&!o((function(){return 7!=Object.defineProperty(i("div"),"a",{get:function(){return 7}}).a}))},function(t,e,n){var r=n(0),o=n(24),i=r["__core-js_shared__"]||o("__core-js_shared__",{});t.exports=i},function(t,e,n){var r=n(14),o=n(37);(t.exports=function(t,e){return o[t]||(o[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.5.0",mode:r?"pure":"global",copyright:"© 2019 Denis Pushkarev (zloirock.ru)"})},function(t,e){var n=0,r=Math.random();t.exports=function(t){return"Symbol("+String(void 0===t?"":t)+")_"+(++n+r).toString(36)}},function(t,e,n){var r=n(5),o=n(19),i=n(67).indexOf,c=n(28);t.exports=function(t,e){var n,a=o(t),u=0,s=[];for(n in a)!r(c,n)&&r(a,n)&&s.push(n);for(;e.length>u;)r(a,n=e[u++])&&(~i(s,n)||s.push(n));return s}},function(t,e,n){var r=n(3),o=/#|\.prototype\./,i=function(t,e){var n=a[c(t)];return n==s||n!=u&&("function"==typeof e?r(e):!!e)},c=i.normalize=function(t){return String(t).replace(o,".").toLowerCase()},a=i.data={},u=i.NATIVE="N",s=i.POLYFILL="P";t.exports=i},function(t,e,n){var r=n(3);t.exports=!!Object.getOwnPropertySymbols&&!r((function(){return!String(Symbol())}))},function(t,e,n){var r=n(20);t.exports=function(t,e,n){if(r(t),void 0===e)return t;switch(n){case 0:return function(){return t.call(e)};case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,o){return t.call(e,n,r,o)}}return function(){return t.apply(e,arguments)}}},function(t,e,n){var r=n(2),o=n(20),i=n(1)("species");t.exports=function(t,e){var n,c=r(t).constructor;return void 0===c||null==(n=r(c)[i])?e:o(n)}},function(t,e,n){var r,o,i,c=n(0),a=n(3),u=n(7),s=n(43),l=n(46),f=n(23),p=n(47),d=c.location,v=c.setImmediate,h=c.clearImmediate,y=c.process,m=c.MessageChannel,g=c.Dispatch,b=0,x={},w=function(t){if(x.hasOwnProperty(t)){var e=x[t];delete x[t],e()}},O=function(t){return function(){w(t)}},S=function(t){w(t.data)},_=function(t){c.postMessage(t+"",d.protocol+"//"+d.host)};v&&h||(v=function(t){for(var e=[],n=1;arguments.length>n;)e.push(arguments[n++]);return x[++b]=function(){("function"==typeof t?t:Function(t)).apply(void 0,e)},r(b),b},h=function(t){delete x[t]},"process"==u(y)?r=function(t){y.nextTick(O(t))}:g&&g.now?r=function(t){g.now(O(t))}:m&&!p?(i=(o=new m).port2,o.port1.onmessage=S,r=s(i.postMessage,i,1)):!c.addEventListener||"function"!=typeof postMessage||c.importScripts||a(_)?r="onreadystatechange"in f("script")?function(t){l.appendChild(f("script")).onreadystatechange=function(){l.removeChild(this),w(t)}}:function(t){setTimeout(O(t),0)}:(r=_,c.addEventListener("message",S,!1))),t.exports={set:v,clear:h}},function(t,e,n){var r=n(15);t.exports=r("document","documentElement")},function(t,e,n){var r=n(48);t.exports=/(iphone|ipod|ipad).*applewebkit/i.test(r)},function(t,e,n){var r=n(15);t.exports=r("navigator","userAgent")||""},function(t,e,n){"use strict";var r=n(20),o=function(t){var e,n;this.promise=new t((function(t,r){if(void 0!==e||void 0!==n)throw TypeError("Bad Promise constructor");e=t,n=r})),this.resolve=r(e),this.reject=r(n)};t.exports.f=function(t){return new o(t)}},function(t,e,n){var r=n(2),o=n(90),i=n(29),c=n(28),a=n(46),u=n(23),s=n(27)("IE_PROTO"),l=function(){},f=function(){var t,e=u("iframe"),n=i.length;for(e.style.display="none",a.appendChild(e),e.src=String("javascript:"),(t=e.contentWindow.document).open(),t.write("<script>document.F=Object<\/script>"),t.close(),f=t.F;n--;)delete f.prototype[i[n]];return f()};t.exports=Object.create||function(t,e){var n;return null!==t?(l.prototype=r(t),n=new l,l.prototype=null,n[s]=t):n=f(),void 0===e?n:o(n,e)},c[s]=!0},function(t,e,n){"use strict";var r,o,i,c=n(52),a=n(6),u=n(5),s=n(1),l=n(14),f=s("iterator"),p=!1;[].keys&&("next"in(i=[].keys())?(o=c(c(i)))!==Object.prototype&&(r=o):p=!0),null==r&&(r={}),l||u(r,f)||a(r,f,(function(){return this})),t.exports={IteratorPrototype:r,BUGGY_SAFARI_ITERATORS:p}},function(t,e,n){var r=n(5),o=n(53),i=n(27),c=n(94),a=i("IE_PROTO"),u=Object.prototype;t.exports=c?Object.getPrototypeOf:function(t){return t=o(t),r(t,a)?t[a]:"function"==typeof t.constructor&&t instanceof t.constructor?t.constructor.prototype:t instanceof Object?u:null}},function(t,e,n){var r=n(4);t.exports=function(t){return Object(r(t))}},function(t,e,n){"use strict";var r=n(102).charAt;t.exports=function(t,e,n){return e+(n?r(t,e).length:1)}},function(t,e,n){"use strict";var r=n(31),o=n(56),i=n(2),c=n(4),a=n(44),u=n(54),s=n(16),l=n(33),f=n(32),p=n(3),d=[].push,v=Math.min,h=!p((function(){return!RegExp(4294967295,"y")}));r("split",2,(function(t,e,n){var r;return r="c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1).length||2!="ab".split(/(?:ab)*/).length||4!=".".split(/(.?)(.?)/).length||".".split(/()()/).length>1||"".split(/.?/).length?function(t,n){var r=String(c(this)),i=void 0===n?4294967295:n>>>0;if(0===i)return[];if(void 0===t)return[r];if(!o(t))return e.call(r,t,i);for(var a,u,s,l=[],p=(t.ignoreCase?"i":"")+(t.multiline?"m":"")+(t.unicode?"u":"")+(t.sticky?"y":""),v=0,h=new RegExp(t.source,p+"g");(a=f.call(h,r))&&!((u=h.lastIndex)>v&&(l.push(r.slice(v,a.index)),a.length>1&&a.index<r.length&&d.apply(l,a.slice(1)),s=a[0].length,v=u,l.length>=i));)h.lastIndex===a.index&&h.lastIndex++;return v===r.length?!s&&h.test("")||l.push(""):l.push(r.slice(v)),l.length>i?l.slice(0,i):l}:"0".split(void 0,0).length?function(t,n){return void 0===t&&0===n?[]:e.call(this,t,n)}:e,[function(e,n){var o=c(this),i=null==e?void 0:e[t];return void 0!==i?i.call(e,o,n):r.call(String(o),e,n)},function(t,o){var c=n(r,t,this,o,r!==e);if(c.done)return c.value;var f=i(t),p=String(this),d=a(f,RegExp),y=f.unicode,m=(f.ignoreCase?"i":"")+(f.multiline?"m":"")+(f.unicode?"u":"")+(h?"y":"g"),g=new d(h?f:"^(?:"+f.source+")",m),b=void 0===o?4294967295:o>>>0;if(0===b)return[];if(0===p.length)return null===l(g,p)?[p]:[];for(var x=0,w=0,O=[];w<p.length;){g.lastIndex=h?w:0;var S,_=l(g,h?p:p.slice(w));if(null===_||(S=v(s(g.lastIndex+(h?0:w)),p.length))===x)w=u(p,w,y);else{if(O.push(p.slice(x,w)),O.length===b)return O;for(var j=1;j<=_.length-1;j++)if(O.push(_[j]),O.length===b)return O;w=x=S}}return O.push(p.slice(x)),O}]}),!h)},function(t,e,n){var r=n(8),o=n(7),i=n(1)("match");t.exports=function(t){var e;return r(t)&&(void 0!==(e=t[i])?!!e:"RegExp"==o(t))}},function(t,e,n){var r=n(56);t.exports=function(t){if(r(t))throw TypeError("The method doesn't accept regular expressions");return t}},function(t,e,n){var r=n(1)("match");t.exports=function(t){var e=/./;try{"/./"[t](e)}catch(n){try{return e[r]=!1,"/./"[t](e)}catch(t){}}return!1}},function(t,e){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(t){"object"==typeof window&&(n=window)}t.exports=n},function(t,e,n){"use strict";var r={}.propertyIsEnumerable,o=Object.getOwnPropertyDescriptor,i=o&&!r.call({1:2},1);e.f=i?function(t){var e=o(this,t);return!!e&&e.enumerable}:r},function(t,e,n){var r=n(3),o=n(7),i="".split;t.exports=r((function(){return!Object("z").propertyIsEnumerable(0)}))?function(t){return"String"==o(t)?i.call(t,""):Object(t)}:Object},function(t,e,n){var r=n(0),o=n(25),i=r.WeakMap;t.exports="function"==typeof i&&/native code/.test(o(i))},function(t,e,n){var r=n(5),o=n(64),i=n(18),c=n(12);t.exports=function(t,e){for(var n=o(e),a=c.f,u=i.f,s=0;s<n.length;s++){var l=n[s];r(t,l)||a(t,l,u(e,l))}}},function(t,e,n){var r=n(15),o=n(66),i=n(69),c=n(2);t.exports=r("Reflect","ownKeys")||function(t){var e=o.f(c(t)),n=i.f;return n?e.concat(n(t)):e}},function(t,e,n){var r=n(0);t.exports=r},function(t,e,n){var r=n(40),o=n(29).concat("length","prototype");e.f=Object.getOwnPropertyNames||function(t){return r(t,o)}},function(t,e,n){var r=n(19),o=n(16),i=n(68),c=function(t){return function(e,n,c){var a,u=r(e),s=o(u.length),l=i(c,s);if(t&&n!=n){for(;s>l;)if((a=u[l++])!=a)return!0}else for(;s>l;l++)if((t||l in u)&&u[l]===n)return t||l||0;return!t&&-1}};t.exports={includes:c(!0),indexOf:c(!1)}},function(t,e,n){var r=n(10),o=Math.max,i=Math.min;t.exports=function(t,e){var n=r(t);return n<0?o(n+e,0):i(n,e)}},function(t,e){e.f=Object.getOwnPropertySymbols},function(t,e,n){var r=n(0);t.exports=r.Promise},function(t,e,n){var r=n(13);t.exports=function(t,e,n){for(var o in e)r(t,o,e[o],n);return t}},function(t,e,n){var r=n(42);t.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol()},function(t,e,n){"use strict";var r=n(15),o=n(12),i=n(1),c=n(9),a=i("species");t.exports=function(t){var e=r(t),n=o.f;c&&e&&!e[a]&&n(e,a,{configurable:!0,get:function(){return this}})}},function(t,e){t.exports=function(t,e,n){if(!(t instanceof e))throw TypeError("Incorrect "+(n?n+" ":"")+"invocation");return t}},function(t,e,n){var r=n(2),o=n(76),i=n(16),c=n(43),a=n(77),u=n(80),s=function(t,e){this.stopped=t,this.result=e};(t.exports=function(t,e,n,l,f){var p,d,v,h,y,m,g,b=c(e,n,l?2:1);if(f)p=t;else{if("function"!=typeof(d=a(t)))throw TypeError("Target is not iterable");if(o(d)){for(v=0,h=i(t.length);h>v;v++)if((y=l?b(r(g=t[v])[0],g[1]):b(t[v]))&&y instanceof s)return y;return new s(!1)}p=d.call(t)}for(m=p.next;!(g=m.call(p)).done;)if("object"==typeof(y=u(p,b,g.value,l))&&y&&y instanceof s)return y;return new s(!1)}).stop=function(t){return new s(!0,t)}},function(t,e,n){var r=n(1),o=n(17),i=r("iterator"),c=Array.prototype;t.exports=function(t){return void 0!==t&&(o.Array===t||c[i]===t)}},function(t,e,n){var r=n(78),o=n(17),i=n(1)("iterator");t.exports=function(t){if(null!=t)return t[i]||t["@@iterator"]||o[r(t)]}},function(t,e,n){var r=n(79),o=n(7),i=n(1)("toStringTag"),c="Arguments"==o(function(){return arguments}());t.exports=r?o:function(t){var e,n,r;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=function(t,e){try{return t[e]}catch(t){}}(e=Object(t),i))?n:c?o(e):"Object"==(r=o(e))&&"function"==typeof e.callee?"Arguments":r}},function(t,e,n){var r={};r[n(1)("toStringTag")]="z",t.exports="[object z]"===String(r)},function(t,e,n){var r=n(2);t.exports=function(t,e,n,o){try{return o?e(r(n)[0],n[1]):e(n)}catch(e){var i=t.return;throw void 0!==i&&r(i.call(t)),e}}},function(t,e,n){var r=n(1)("iterator"),o=!1;try{var i=0,c={next:function(){return{done:!!i++}},return:function(){o=!0}};c[r]=function(){return this},Array.from(c,(function(){throw 2}))}catch(t){}t.exports=function(t,e){if(!e&&!o)return!1;var n=!1;try{var i={};i[r]=function(){return{next:function(){return{done:n=!0}}}},t(i)}catch(t){}return n}},function(t,e,n){var r,o,i,c,a,u,s,l,f=n(0),p=n(18).f,d=n(7),v=n(45).set,h=n(47),y=f.MutationObserver||f.WebKitMutationObserver,m=f.process,g=f.Promise,b="process"==d(m),x=p(f,"queueMicrotask"),w=x&&x.value;w||(r=function(){var t,e;for(b&&(t=m.domain)&&t.exit();o;){e=o.fn,o=o.next;try{e()}catch(t){throw o?c():i=void 0,t}}i=void 0,t&&t.enter()},b?c=function(){m.nextTick(r)}:y&&!h?(a=!0,u=document.createTextNode(""),new y(r).observe(u,{characterData:!0}),c=function(){u.data=a=!a}):g&&g.resolve?(s=g.resolve(void 0),l=s.then,c=function(){l.call(s,r)}):c=function(){v.call(f,r)}),t.exports=w||function(t){var e={fn:t,next:void 0};i&&(i.next=e),o||(o=e,c()),i=e}},function(t,e,n){var r=n(2),o=n(8),i=n(49);t.exports=function(t,e){if(r(t),o(e)&&e.constructor===t)return e;var n=i.f(t);return(0,n.resolve)(e),n.promise}},function(t,e,n){var r=n(0);t.exports=function(t,e){var n=r.console;n&&n.error&&(1===arguments.length?n.error(t):n.error(t,e))}},function(t,e){t.exports=function(t){try{return{error:!1,value:t()}}catch(t){return{error:!0,value:t}}}},function(t,e,n){var r,o,i=n(0),c=n(48),a=i.process,u=a&&a.versions,s=u&&u.v8;s?o=(r=s.split("."))[0]+r[1]:c&&(!(r=c.match(/Edge\/(\d+)/))||r[1]>=74)&&(r=c.match(/Chrome\/(\d+)/))&&(o=r[1]),t.exports=o&&+o},function(t,e){t.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},function(t,e,n){"use strict";var r=n(19),o=n(89),i=n(17),c=n(26),a=n(92),u=c.set,s=c.getterFor("Array Iterator");t.exports=a(Array,"Array",(function(t,e){u(this,{type:"Array Iterator",target:r(t),index:0,kind:e})}),(function(){var t=s(this),e=t.target,n=t.kind,r=t.index++;return!e||r>=e.length?(t.target=void 0,{value:void 0,done:!0}):"keys"==n?{value:r,done:!1}:"values"==n?{value:e[r],done:!1}:{value:[r,e[r]],done:!1}}),"values"),i.Arguments=i.Array,o("keys"),o("values"),o("entries")},function(t,e,n){var r=n(1),o=n(50),i=n(6),c=r("unscopables"),a=Array.prototype;null==a[c]&&i(a,c,o(null)),t.exports=function(t){a[c][t]=!0}},function(t,e,n){var r=n(9),o=n(12),i=n(2),c=n(91);t.exports=r?Object.defineProperties:function(t,e){i(t);for(var n,r=c(e),a=r.length,u=0;a>u;)o.f(t,n=r[u++],e[n]);return t}},function(t,e,n){var r=n(40),o=n(29);t.exports=Object.keys||function(t){return r(t,o)}},function(t,e,n){"use strict";var r=n(11),o=n(93),i=n(52),c=n(95),a=n(30),u=n(6),s=n(13),l=n(1),f=n(14),p=n(17),d=n(51),v=d.IteratorPrototype,h=d.BUGGY_SAFARI_ITERATORS,y=l("iterator"),m=function(){return this};t.exports=function(t,e,n,l,d,g,b){o(n,e,l);var x,w,O,S=function(t){if(t===d&&E)return E;if(!h&&t in P)return P[t];switch(t){case"keys":case"values":case"entries":return function(){return new n(this,t)}}return function(){return new n(this)}},_=e+" Iterator",j=!1,P=t.prototype,k=P[y]||P["@@iterator"]||d&&P[d],E=!h&&k||S(d),L="Array"==e&&P.entries||k;if(L&&(x=i(L.call(new t)),v!==Object.prototype&&x.next&&(f||i(x)===v||(c?c(x,v):"function"!=typeof x[y]&&u(x,y,m)),a(x,_,!0,!0),f&&(p[_]=m))),"values"==d&&k&&"values"!==k.name&&(j=!0,E=function(){return k.call(this)}),f&&!b||P[y]===E||u(P,y,E),p[e]=E,d)if(w={values:S("values"),keys:g?E:S("keys"),entries:S("entries")},b)for(O in w)!h&&!j&&O in P||s(P,O,w[O]);else r({target:e,proto:!0,forced:h||j},w);return w}},function(t,e,n){"use strict";var r=n(51).IteratorPrototype,o=n(50),i=n(22),c=n(30),a=n(17),u=function(){return this};t.exports=function(t,e,n){var s=e+" Iterator";return t.prototype=o(r,{next:i(1,n)}),c(t,s,!1,!0),a[s]=u,t}},function(t,e,n){var r=n(3);t.exports=!r((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype}))},function(t,e,n){var r=n(2),o=n(96);t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,n={};try{(t=Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set).call(n,[]),e=n instanceof Array}catch(t){}return function(n,i){return r(n),o(i),e?t.call(n,i):n.__proto__=i,n}}():void 0)},function(t,e,n){var r=n(8);t.exports=function(t){if(!r(t)&&null!==t)throw TypeError("Can't set "+String(t)+" as a prototype");return t}},function(t,e,n){"use strict";var r=n(11),o=n(10),i=n(98),c=n(99),a=n(3),u=1..toFixed,s=Math.floor,l=function(t,e,n){return 0===e?n:e%2==1?l(t,e-1,n*t):l(t*t,e/2,n)};r({target:"Number",proto:!0,forced:u&&("0.000"!==8e-5.toFixed(3)||"1"!==.9.toFixed(0)||"1.25"!==1.255.toFixed(2)||"1000000000000000128"!==(0xde0b6b3a7640080).toFixed(0))||!a((function(){u.call({})}))},{toFixed:function(t){var e,n,r,a,u=i(this),f=o(t),p=[0,0,0,0,0,0],d="",v="0",h=function(t,e){for(var n=-1,r=e;++n<6;)r+=t*p[n],p[n]=r%1e7,r=s(r/1e7)},y=function(t){for(var e=6,n=0;--e>=0;)n+=p[e],p[e]=s(n/t),n=n%t*1e7},m=function(){for(var t=6,e="";--t>=0;)if(""!==e||0===t||0!==p[t]){var n=String(p[t]);e=""===e?n:e+c.call("0",7-n.length)+n}return e};if(f<0||f>20)throw RangeError("Incorrect fraction digits");if(u!=u)return"NaN";if(u<=-1e21||u>=1e21)return String(u);if(u<0&&(d="-",u=-u),u>1e-21)if(n=(e=function(t){for(var e=0,n=t;n>=4096;)e+=12,n/=4096;for(;n>=2;)e+=1,n/=2;return e}(u*l(2,69,1))-69)<0?u*l(2,-e,1):u/l(2,e,1),n*=4503599627370496,(e=52-e)>0){for(h(0,n),r=f;r>=7;)h(1e7,0),r-=7;for(h(l(10,r,1),0),r=e-1;r>=23;)y(1<<23),r-=23;y(1<<r),h(1,1),y(2),v=m()}else h(0,n),h(1<<-e,0),v=m()+c.call("0",f);return v=f>0?d+((a=v.length)<=f?"0."+c.call("0",f-a)+v:v.slice(0,a-f)+"."+v.slice(a-f)):d+v}})},function(t,e,n){var r=n(7);t.exports=function(t){if("number"!=typeof t&&"Number"!=r(t))throw TypeError("Incorrect invocation");return+t}},function(t,e,n){"use strict";var r=n(10),o=n(4);t.exports="".repeat||function(t){var e=String(o(this)),n="",i=r(t);if(i<0||i==1/0)throw RangeError("Wrong number of repetitions");for(;i>0;(i>>>=1)&&(e+=e))1&i&&(n+=e);return n}},function(t,e,n){"use strict";var r=n(31),o=n(2),i=n(53),c=n(16),a=n(10),u=n(4),s=n(54),l=n(33),f=Math.max,p=Math.min,d=Math.floor,v=/\$([$&'`]|\d\d?|<[^>]*>)/g,h=/\$([$&'`]|\d\d?)/g;r("replace",2,(function(t,e,n){return[function(n,r){var o=u(this),i=null==n?void 0:n[t];return void 0!==i?i.call(n,o,r):e.call(String(o),n,r)},function(t,i){var u=n(e,t,this,i);if(u.done)return u.value;var d=o(t),v=String(this),h="function"==typeof i;h||(i=String(i));var y=d.global;if(y){var m=d.unicode;d.lastIndex=0}for(var g=[];;){var b=l(d,v);if(null===b)break;if(g.push(b),!y)break;""===String(b[0])&&(d.lastIndex=s(v,c(d.lastIndex),m))}for(var x,w="",O=0,S=0;S<g.length;S++){b=g[S];for(var _=String(b[0]),j=f(p(a(b.index),v.length),0),P=[],k=1;k<b.length;k++)P.push(void 0===(x=b[k])?x:String(x));var E=b.groups;if(h){var L=[_].concat(P,j,v);void 0!==E&&L.push(E);var I=String(i.apply(void 0,L))}else I=r(_,v,j,P,E,i);j>=O&&(w+=v.slice(O,j)+I,O=j+_.length)}return w+v.slice(O)}];function r(t,n,r,o,c,a){var u=r+t.length,s=o.length,l=h;return void 0!==c&&(c=i(c),l=v),e.call(a,l,(function(e,i){var a;switch(i.charAt(0)){case"$":return"$";case"&":return t;case"`":return n.slice(0,r);case"'":return n.slice(u);case"<":a=c[i.slice(1,-1)];break;default:var l=+i;if(0===l)return e;if(l>s){var f=d(l/10);return 0===f?e:f<=s?void 0===o[f-1]?i.charAt(1):o[f-1]+i.charAt(1):e}a=o[l-1]}return void 0===a?"":a}))}}))},function(t,e,n){"use strict";var r=n(2);t.exports=function(){var t=r(this),e="";return t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),t.dotAll&&(e+="s"),t.unicode&&(e+="u"),t.sticky&&(e+="y"),e}},function(t,e,n){var r=n(10),o=n(4),i=function(t){return function(e,n){var i,c,a=String(o(e)),u=r(n),s=a.length;return u<0||u>=s?t?"":void 0:(i=a.charCodeAt(u))<55296||i>56319||u+1===s||(c=a.charCodeAt(u+1))<56320||c>57343?t?a.charAt(u):i:t?a.slice(u,u+2):c-56320+(i-55296<<10)+65536}};t.exports={codeAt:i(!1),charAt:i(!0)}},function(t,e,n){"use strict";var r=n(11),o=n(57),i=n(4);r({target:"String",proto:!0,forced:!n(58)("includes")},{includes:function(t){return!!~String(i(this)).indexOf(o(t),arguments.length>1?arguments[1]:void 0)}})},function(t,e,n){"use strict";var r=n(31),o=n(2),i=n(4),c=n(105),a=n(33);r("search",1,(function(t,e,n){return[function(e){var n=i(this),r=null==e?void 0:e[t];return void 0!==r?r.call(e,n):new RegExp(e)[t](String(n))},function(t){var r=n(e,t,this);if(r.done)return r.value;var i=o(t),u=String(this),s=i.lastIndex;c(s,0)||(i.lastIndex=0);var l=a(i,u);return c(i.lastIndex,s)||(i.lastIndex=s),null===l?-1:l.index}]}))},function(t,e){t.exports=Object.is||function(t,e){return t===e?0!==t||1/t==1/e:t!=t&&e!=e}},function(t,e,n){"use strict";var r,o=n(11),i=n(18).f,c=n(16),a=n(57),u=n(4),s=n(58),l=n(14),f="".startsWith,p=Math.min,d=s("startsWith");o({target:"String",proto:!0,forced:!!(l||d||(r=i(String.prototype,"startsWith"),!r||r.writable))&&!d},{startsWith:function(t){var e=String(u(this));a(t);var n=c(p(arguments.length>1?arguments[1]:void 0,e.length)),r=String(t);return f?f.call(e,r,n):e.slice(n,n+r.length)===r}})},function(t,e,n){"use strict";n.r(e);n(34),n(21);var r={get:(t="loop-onstore-data")=>JSON.parse(localStorage.getItem(t)||null),set(t,e="loop-onstore-data"){localStorage.setItem(e,JSON.stringify(t))},remove(t="loop-onstore-data"){localStorage.removeItem(t)}};function o(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function i(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}let c={debug:!1,testMode:!1,redirect:!0,active:!1,params:null,key:null,api:null,token:null,id:null,fullPayload:!1,preserveCart:!1,draftOrderId:null};const a=t=>t?c[t]:c,u=(t,e)=>{c[t]=e,r.set(c)},s=()=>{const t=r.get();t&&(c=function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?o(Object(n),!0).forEach((function(e){i(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}({},c,{},t))};var l=new Proxy({},{get:(t,e)=>!t[e]&&a("debug")?t=>"string"==typeof t?console[e]("%c".concat(t),"color: #3256E6"):console[e](t):t[e]||function(){}});const f=(t,e)=>{const n=[...document.querySelectorAll(t)];return n.length>1&&l.warn("Attaching Loop.submit() to more than one element. Make sure you're using the right selector!"),n.forEach(t=>{t.addEventListener("click",e)}),n};n(97),n(100),n(55);const p={JPY:{constant:1,decimals:0,decimalSymbol:"",thousandSymbol:",",symbol:"¥"},GBP:{constant:100,decimals:2,decimalSymbol:".",thousandSymbol:",",symbol:"£"},EUR:{constant:100,decimals:2,decimalSymbol:",",thousandSymbol:".",symbol:"€"},USD:{constant:100,decimals:2,decimalSymbol:".",thousandSymbol:",",symbol:"$"},CAD:{constant:100,decimals:2,decimalSymbol:".",thousandSymbol:",",symbol:"$"},AUD:{constant:100,decimals:2,decimalSymbol:".",thousandSymbol:",",symbol:"$"},HKD:{constant:100,decimals:2,decimalSymbol:".",thousandSymbol:",",symbol:"$"},NZD:{constant:100,decimals:2,decimalSymbol:".",thousandSymbol:",",symbol:"$"},SGD:{constant:100,decimals:2,decimalSymbol:".",thousandSymbol:",",symbol:"$"}},d=(t,e="USD")=>{if(!t)return"";const n=p[e];if(n){const{dollars:e,cents:r}=((t,e)=>{const[n,r]=Number.parseFloat(t/e.constant).toFixed(e.decimals).split(".");return{dollars:n?n.replace(/\B(?=(\d{3})+(?!\d))/g,e.thousandSymbol):"0",cents:r||""}})(t,n);return"".concat(n.symbol).concat(e).concat(n.decimalSymbol).concat(r)}return new Intl.NumberFormat("en-US",{style:"currency",currency:e}).format(t/n.constant)};function v(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function h(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?v(Object(n),!0).forEach((function(e){y(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):v(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function y(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}const m=()=>{var t;return null!==(t=a("api"))&&void 0!==t?t:"https://api.loopreturns.com/api/v1/"},g=t=>{const{token:e,total_discount:n,original_total_price:r,total_price:o,items:i,currency:c,items_subtotal_price:a,cart_level_discount_applications:u}=t;return(t=>{const e="object"==typeof t&&null!==t?JSON.stringify(t):String(t);return window.btoa(unescape(encodeURIComponent(e)))})({token:e,total_discount:n,original_total_price:r,total_price:o,items:i.map(t=>{const{id:e,quantity:n,variant_id:r,price:o,original_price:i,discounted_price:c,original_line_price:a,line_price:u,total_discount:s,final_price:l,final_line_price:f,taxable:p,product_id:d,discount_allocations:v,line_level_discount_allocations:h}=t;return{id:e,quantity:n,variant_id:r,price:o,original_price:i,discounted_price:c,original_line_price:a,line_price:u,total_discount:s,final_price:l,final_line_price:f,taxable:p,product_id:d,discount_allocations:v,line_level_discount_allocations:h}}),currency:c,items_subtotal_price:a,cart_level_discount_applications:u})},b=(t,e="GET",n)=>{const r=a("key");return new Promise(o=>{const i=null!=n?JSON.stringify(n):null;var c=new XMLHttpRequest;c.withCredentials=!0,c.addEventListener("readystatechange",(function(){this.readyState===this.DONE&&o(JSON.parse(this.responseText))})),c.open(e,t),""!==r&&c.setRequestHeader("x-authorization",r),c.setRequestHeader("content-type","application/json"),c.send(i)})},x=()=>{return b("/cart/clear.js","POST")};function w(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function O(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}const S=(t,e)=>{l.info("Creating cart request..."),l.info("Syncing these variants to the Loop cart:"),l.info(t);const n=a("token");return n?((t,e,n)=>{const r=m(),o="".concat(r,"cart/").concat(t);let i={};return a("fullPayload")&&(i={shopify:g(n)}),b(o,"POST",h({cart:e,draftOrderId:a("draftOrderId")},i))})(n,t,e).then(t=>(function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?w(Object(n),!0).forEach((function(e){O(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):w(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t})({},t,{token:n})):((t,e)=>{const n=m(),r="".concat(n,"cart/");let o={};return a("fullPayload")&&(o={shopify:g(e)}),b(r,"POST",h({cart:t,draftOrderId:a("draftOrderId")},o))})(t,e)};n(103),n(104),n(106);function _(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function j(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}const P=t=>{const e=Number(t);return Number.isNaN(e)?t:e};var k={get:(t=window.location.search)=>t.substr(1).split("&").reduce((t,e)=>{const[n,r]=decodeURIComponent(e).split("=");return function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?_(Object(n),!0).forEach((function(e){j(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):_(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}({},t,{[n]:P(r)})},{}),hasLoopData:(t=window.location.search)=>t.includes("loop_total"),getKeys:(t,e="loop")=>Object.keys(t).filter(t=>t.startsWith(e)),clear(t=[]){const e=Object.entries(this.get()).reduce((e,[n,r])=>{if(t.includes(n))return e;const o=e.length?"&":"?";return"".concat(e).concat(o).concat(encodeURIComponent(n),"=").concat(encodeURIComponent(r))},"");window.history.replaceState({},"","".concat(window.location.origin).concat(window.location.pathname).concat(e))}};const E={amount:".loop-onstore__amount"},L=(t,e,n)=>{return t.querySelector(n).textContent=e,t};var I=(t,e={})=>{if(t)return t;const n=((t={})=>{const e=document.createElement("div");return e.classList.add("loop-onstore"),e.id="loop-onstore",e.innerHTML='\n <span class="loop-onstore__amount"></span>\n <p class="loop-onstore__copy">\n in available credit\n </p>\n <button class="loop-onstore__back" onClick="LoopOnstore.backToLoop()">Go Back</button>\n',Object.keys(t).forEach(n=>{L(e,t[n],E[n])}),e})(e);return document.body.appendChild(n)};n.d(e,"init",(function(){return T})),n.d(e,"testMode",(function(){return A})),n.d(e,"submit",(function(){return D})),n.d(e,"attach",(function(){return N})),n.d(e,"debug",(function(){return M})),n.d(e,"setKey",(function(){return R})),n.d(e,"backToLoop",(function(){return F})),n.d(e,"isActive",(function(){return U}));const C={bar:null,attached:[]},T=async t=>{if(s(),null==t?void 0:t.key)R(t.key);else if(!a("key"))throw new Error("Loop Returns on-store API requires an API key.");(null==t?void 0:t.api)&&(l.info("Setting api to ".concat(t.api,".")),u("api",t.api)),(null==t?void 0:t.preserveCart)&&(l.info("Setting preserve cart to ".concat(t.preserveCart)),u("preserveCart",t.preserveCart));const e=k.get();if(k.hasLoopData()){a("id")!==e.loop_return_id&&u("token",null),u("params",e),u("id",e.loop_return_id),k.clear(k.getKeys(e)),await x();const t=a("token");if(t)try{const{cart:e}=await(t=>{const e=m(),n="".concat(e,"cart/").concat(t);return b(n)})(t);await(t=>{const e=t.reduce((t,e)=>t[e]?h({},t,{[e]:t[e]+1}):h({},t,{[e]:1}),{});return b("/cart/update.js","POST",{updates:e})})(e),l.info("Updating Shopify cart to match loop cart."),document.dispatchEvent(new Event("Loop:Cart Update"))}catch(t){l.warn("Unable to reboot cart"),l.error(t)}}const n=a("params");if(n){u("active",!0),document.body.classList.add("loop-returns-activated");const t=I(null,{amount:d(n.loop_total,n.loop_currency)});(()=>{const t=document.createElement("style");t.type="text/css",t.innerText="\n:root {\n --loop-primary-color: black;\n --loop-text-color: white;\n --loop-button-background: white;\n --loop-button-text: black;\n}\n.loop-returns-activated .loop-onstore {\n transform: translateY(0);\n display: flex;\n}\n.loop-onstore {\n box-sizing: border-box;\n width: 100%;\n position: fixed;\n display: none;\n align-items: center;\n top: auto !important;\n bottom: 0 !important;\n left: 0;\n z-index: 2147483647;\n background-color: var(--loop-primary-color);\n color: var(--loop-text-color);\n transform: translateY(100%);\n transition: transform .2s;\n font-size: 1rem;\n padding: 1.25rem 2rem;\n}\n.loop-onstore *, .loop-onstore *::before, .loop-onstore *::after {\n box-sizing: inherit;\n}\n.loop-onstore__amount {\n margin: 0;\n margin-right: .5rem;\n font-size: 1.5rem;\n font-weight: 800;\n color: var(--loop-text-color);\n}\n.loop-onstore__copy {\n margin: 0;\n color: var(--loop-text-color);\n}\n.loop-onstore__back {\n color: var(--loop-button-text);\n background: var(--loop-button-background);\n display: block;\n padding: .75rem 1.25rem;\n margin-left: auto;\n border: none;\n appearance: none;\n transition: all .2s;\n font-size: 1rem;\n border-radius: 5px;\n cursor: pointer;\n}\n.loop-onstore__back:hover {\n opacity: .7;\n}\n\n.loop-returns-modal {\n font-family: untitled sans,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji !important;\n -moz-osx-font-smoothing: grayscale;\n -webkit-font-smoothing: antialiased;\n font-style: normal;\n display: flex;\n justify-content: center;\n align-items: center;\n position: fixed;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n z-index: 999;\n }\n\n .loop-returns-modal__backdrop{\n position: fixed;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background-color: rgba(65, 69, 74, 0.7);\n }\n\n .loop-returns-modal__content {\n overflow: auto;\n max-height: 600px;\n background-color: #fff;\n box-shadow: 0px 1px 4px rgb(0 0 0 / 12%), 0px 6px 12px rgb(0 0 0 / 8%);\n border-radius: 8px;\n width: 500px;\n max-width: 700px;\n position: relative;\n z-index: 1000;\n }\n\n .loop-returns-modal__header {\n color: #3256E5;\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding: 15px 20px;\n border-bottom: 1px solid #EAEAEA;\n font-size: 1.25rem;\n font-weight: 500;\n }\n\n .loop-returns-modal__close--icon {\n height: 20px;\n width: 20px;\n cursor: pointer;\n }\n\n .loop-returns-modal__body {\n padding: 20px;\n }\n\n@media screen and (max-width: 680px) {\n .loop-onstore {\n z-index: 200;\n bottom: 3.2rem;\n padding: 1rem 1.5rem;\n }\n .loop-onstore__copy {\n font-size: .875rem;\n }\n .loop-onstore__amount {\n font-size: 1.25rem;\n }\n}\n",document.head.appendChild(t)})(),C.bar=t,l.info("Loop returns activated"),document.dispatchEvent(new Event("Loop:Activated"))}(null==t?void 0:t.attach)&&N(t.attach),(null==t?void 0:t.full)&&u("fullPayload",null==t?void 0:t.full)},A=(t=!0)=>{u("debug",!0),u("testMode",!0),l.info("Test mode activated"),u("redirect",t),window.location="".concat(window.location.origin).concat(window.location.pathname,"?loop_domain=example.loopreturns.com&loop_return_id=this-is-a-test&loop_currency=USD&loop_total=12099&loop_base=799&loop_credit=500&loop_subdomain=example&loop_redirect_url=example.loopreturns.com%2F%23%2Fcredit&loop_customer_name=Jane%20Doe")},M=()=>{const t=!a("debug");return u("debug",t),"Debug ".concat(t?"on":"off")},R=t=>{if(!t||"string"!=typeof t)return console.error("Your api key is either undefined or not a string.");u("key",t),l.info("Loop Returns on-store API key set.")},D=async t=>{let e=null;t||(l.info("Requesting updated cart from Shopify"),e=await b("/cart.js"),t=e.items.reduce((t,e)=>[...t,...Array(e.quantity).fill(e.variant_id)],[]));try{var n;if(window.stackableService&&"function"==typeof(null===(n=window.stackableService)||void 0===n?void 0:n.send)){window.stackableService.send({type:"checkout",data:{preventRedirect:!0}});let t=0;await(async()=>await new Promise(e=>{const n=setInterval(()=>{(window.stackableService.state.context.draftOrderId||6===t)&&(e(),clearInterval(n)),t++},500)}))(),u("draftOrderId",window.stackableService.state.context.draftOrderId)}const r=await S(t,e);return u("token",r.token),a("preserveCart")||await x(),F(r.token),Promise.resolve(r.token)}catch(t){return l.info("Unable to create Loop Returns cart:"),l.error(t),Promise.reject(t)}},N=t=>{if(a("active")){l.info('Loop attaching to: "'.concat(t,'"'));const e=async t=>{if(a("active")){t.stopImmediatePropagation(),t.preventDefault(),t.target.disabled=!0,t.target.classList.add("loop-activated");try{await D(),t.target.disabled=!1,t.target.classList.remove("loop-activated")}catch(e){t.target.disabled=!1,t.target.classList.remove("loop-activated")}}};C.attached=f(t,e),new MutationObserver(n=>{const r=((t,e)=>t.filter(t=>t[e].length).reduce((t,n)=>[...t,...n[e]],[]))(n,"addedNodes");if(r.length){r.some(e=>e&&1===e.nodeType&&(e.matches(t)||e.querySelector(t)))&&(((t,e)=>{t.forEach(t=>{t.removeEventListener("click",e)})})(C.attached,e),C.attached=f(t,e),l.info('Loop reattached to: "'.concat(t,'"')))}}).observe(document.body,{childList:!0,subtree:!0})}},F=t=>{const e=a("testMode");u("active",!1);const n=a("params");let r="http://".concat(n.loop_redirect_url);if(t&&n.loop_return_key?r="http://".concat(n.loop_domain,"/#/cart/v2/").concat(t,"/").concat(n.loop_return_key):t&&(r="http://".concat(n.loop_domain,"/#/cart/v2/").concat(t)),u("params",null),l.info("Redirecting to:"),l.info(r),document.dispatchEvent(new Event("Loop:Back To Loop")),e)return(()=>{document.body.style.overflow="hidden";const t=document.createElement("div");t.classList.add("loop-returns-modal"),t.innerHTML='\n <div class="loop-returns-modal">\n <div class="loop-returns-modal__backdrop"></div>\n <div class="loop-returns-modal__content">\n <div class="loop-returns-modal__header">\n <div class="loop-returns-modal__text">Loop Onstore Installed</div>\n <div class="loop-returns-modal__close">\n <svg class="loop-returns-modal__close--icon width="15" height="15" viewBox="0 0 15 15" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path\n d="M0 7.50024C0 3.36474 3.3645 0.000244141 7.5 0.000244141C11.6355 0.000244141 15 3.36474 15 7.50024C15 11.6357 11.6355 15.0002 7.5 15.0002C3.3645 15.0002 0 11.6357 0 7.50024ZM5.78025 4.71999C5.6388 4.58338 5.44935 4.50778 5.2527 4.50949C5.05605 4.5112 4.86794 4.59007 4.72889 4.72913C4.58983 4.86819 4.51095 5.0563 4.50924 5.25294C4.50754 5.44959 4.58313 5.63904 4.71975 5.78049L6.4395 7.50024L4.71975 9.21999C4.64812 9.28918 4.59098 9.37194 4.55167 9.46344C4.51237 9.55494 4.49168 9.65336 4.49081 9.75294C4.48995 9.85253 4.50892 9.95129 4.54663 10.0435C4.58434 10.1356 4.64003 10.2194 4.71045 10.2898C4.78087 10.3602 4.86461 10.4159 4.95678 10.4536C5.04896 10.4913 5.14772 10.5103 5.2473 10.5094C5.34689 10.5086 5.4453 10.4879 5.5368 10.4486C5.62831 10.4093 5.71106 10.3521 5.78025 10.2805L7.5 8.56074L9.21975 10.2805C9.3612 10.4171 9.55065 10.4927 9.7473 10.491C9.94395 10.4893 10.1321 10.4104 10.2711 10.2714C10.4102 10.1323 10.489 9.94419 10.4908 9.74754C10.4925 9.5509 10.4169 9.36145 10.2802 9.21999L8.5605 7.50024L10.2802 5.78049C10.4169 5.63904 10.4925 5.44959 10.4908 5.25294C10.489 5.0563 10.4102 4.86819 10.2711 4.72913C10.1321 4.59007 9.94395 4.5112 9.7473 4.50949C9.55065 4.50778 9.3612 4.58338 9.21975 4.71999L7.5 6.43974L5.78025 4.71999Z"\n fill="black" />\n </svg>\n </div>\n </div>\n <div class="loop-returns-modal__body">\n Test Mode Successful\n </div>\n </div>\n </div>\n </div>',document.body.appendChild(t);const e=document.querySelector(".loop-returns-modal__close"),n=document.querySelector(".loop-returns-modal__backdrop"),r=e=>{"Escape"===e.key&&(t.remove(),document.removeEventListener("keydown",r))};document.addEventListener("keydown",r),null==e||e.addEventListener("click",()=>{t.remove(),document.removeEventListener("keydown",r),document.body.style.overflow="auto"}),null==n||n.addEventListener("click",()=>{t.remove(),document.removeEventListener("keydown",r),document.body.style.overflow="auto"})})(),void u("testMode",!1);a("redirect")&&(window.location.href=r)},U=()=>a("active")}])}));
!function(t,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports.LoopOnstore=n():t.LoopOnstore=n()}(window,(function(){return function(t){var n={};function e(o){if(n[o])return n[o].exports;var r=n[o]={i:o,l:!1,exports:{}};return t[o].call(r.exports,r,r.exports,e),r.l=!0,r.exports}return e.m=t,e.c=n,e.d=function(t,n,o){e.o(t,n)||Object.defineProperty(t,n,{enumerable:!0,get:o})},e.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},e.t=function(t,n){if(1&n&&(t=e(t)),8&n)return t;if(4&n&&"object"==typeof t&&t&&t.__esModule)return t;var o=Object.create(null);if(e.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:t}),2&n&&"string"!=typeof t)for(var r in t)e.d(o,r,function(n){return t[n]}.bind(null,r));return o},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},e.p="",e(e.s=107)}([function(t,n,e){(function(n){var e=function(t){return t&&t.Math==Math&&t};t.exports=e("object"==typeof globalThis&&globalThis)||e("object"==typeof window&&window)||e("object"==typeof self&&self)||e("object"==typeof n&&n)||Function("return this")()}).call(this,e(59))},function(t,n,e){var o=e(0),r=e(38),i=e(5),c=e(39),a=e(42),s=e(72),u=r("wks"),l=o.Symbol,f=s?l:c;t.exports=function(t){return i(u,t)||(a&&i(l,t)?u[t]=l[t]:u[t]=f("Symbol."+t)),u[t]}},function(t,n,e){var o=e(8);t.exports=function(t){if(!o(t))throw TypeError(String(t)+" is not an object");return t}},function(t,n){t.exports=function(t){try{return!!t()}catch(t){return!0}}},function(t,n){t.exports=function(t){if(null==t)throw TypeError("Can't call method on "+t);return t}},function(t,n){var e={}.hasOwnProperty;t.exports=function(t,n){return e.call(t,n)}},function(t,n,e){var o=e(9),r=e(12),i=e(22);t.exports=o?function(t,n,e){return r.f(t,n,i(1,e))}:function(t,n,e){return t[n]=e,t}},function(t,n){var e={}.toString;t.exports=function(t){return e.call(t).slice(8,-1)}},function(t,n){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},function(t,n,e){var o=e(3);t.exports=!o((function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a}))},function(t,n){var e=Math.ceil,o=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?o:e)(t)}},function(t,n,e){var o=e(0),r=e(18).f,i=e(6),c=e(13),a=e(24),s=e(63),u=e(41);t.exports=function(t,n){var e,l,f,p,d,v=t.target,y=t.global,h=t.stat;if(e=y?o:h?o[v]||a(v,{}):(o[v]||{}).prototype)for(l in n){if(p=n[l],f=t.noTargetGet?(d=r(e,l))&&d.value:e[l],!u(y?l:v+(h?".":"#")+l,t.forced)&&void 0!==f){if(typeof p==typeof f)continue;s(p,f)}(t.sham||f&&f.sham)&&i(p,"sham",!0),c(e,l,p,t)}}},function(t,n,e){var o=e(9),r=e(36),i=e(2),c=e(35),a=Object.defineProperty;n.f=o?a:function(t,n,e){if(i(t),n=c(n,!0),i(e),r)try{return a(t,n,e)}catch(t){}if("get"in e||"set"in e)throw TypeError("Accessors not supported");return"value"in e&&(t[n]=e.value),t}},function(t,n,e){var o=e(0),r=e(6),i=e(5),c=e(24),a=e(25),s=e(26),u=s.get,l=s.enforce,f=String(String).split("String");(t.exports=function(t,n,e,a){var s=!!a&&!!a.unsafe,u=!!a&&!!a.enumerable,p=!!a&&!!a.noTargetGet;"function"==typeof e&&("string"!=typeof n||i(e,"name")||r(e,"name",n),l(e).source=f.join("string"==typeof n?n:"")),t!==o?(s?!p&&t[n]&&(u=!0):delete t[n],u?t[n]=e:r(t,n,e)):u?t[n]=e:c(n,e)})(Function.prototype,"toString",(function(){return"function"==typeof this&&u(this).source||a(this)}))},function(t,n){t.exports=!1},function(t,n,e){var o=e(65),r=e(0),i=function(t){return"function"==typeof t?t:void 0};t.exports=function(t,n){return arguments.length<2?i(o[t])||i(r[t]):o[t]&&o[t][n]||r[t]&&r[t][n]}},function(t,n,e){var o=e(10),r=Math.min;t.exports=function(t){return t>0?r(o(t),9007199254740991):0}},function(t,n){t.exports={}},function(t,n,e){var o=e(9),r=e(60),i=e(22),c=e(19),a=e(35),s=e(5),u=e(36),l=Object.getOwnPropertyDescriptor;n.f=o?l:function(t,n){if(t=c(t),n=a(n,!0),u)try{return l(t,n)}catch(t){}if(s(t,n))return i(!r.f.call(t,n),t[n])}},function(t,n,e){var o=e(61),r=e(4);t.exports=function(t){return o(r(t))}},function(t,n){t.exports=function(t){if("function"!=typeof t)throw TypeError(String(t)+" is not a function");return t}},function(t,n,e){var o=e(0),r=e(87),i=e(88),c=e(6),a=e(1),s=a("iterator"),u=a("toStringTag"),l=i.values;for(var f in r){var p=o[f],d=p&&p.prototype;if(d){if(d[s]!==l)try{c(d,s,l)}catch(t){d[s]=l}if(d[u]||c(d,u,f),r[f])for(var v in i)if(d[v]!==i[v])try{c(d,v,i[v])}catch(t){d[v]=i[v]}}}},function(t,n){t.exports=function(t,n){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:n}}},function(t,n,e){var o=e(0),r=e(8),i=o.document,c=r(i)&&r(i.createElement);t.exports=function(t){return c?i.createElement(t):{}}},function(t,n,e){var o=e(0),r=e(6);t.exports=function(t,n){try{r(o,t,n)}catch(e){o[t]=n}return n}},function(t,n,e){var o=e(37),r=Function.toString;"function"!=typeof o.inspectSource&&(o.inspectSource=function(t){return r.call(t)}),t.exports=o.inspectSource},function(t,n,e){var o,r,i,c=e(62),a=e(0),s=e(8),u=e(6),l=e(5),f=e(27),p=e(28),d=a.WeakMap;if(c){var v=new d,y=v.get,h=v.has,m=v.set;o=function(t,n){return m.call(v,t,n),n},r=function(t){return y.call(v,t)||{}},i=function(t){return h.call(v,t)}}else{var g=f("state");p[g]=!0,o=function(t,n){return u(t,g,n),n},r=function(t){return l(t,g)?t[g]:{}},i=function(t){return l(t,g)}}t.exports={set:o,get:r,has:i,enforce:function(t){return i(t)?r(t):o(t,{})},getterFor:function(t){return function(n){var e;if(!s(n)||(e=r(n)).type!==t)throw TypeError("Incompatible receiver, "+t+" required");return e}}}},function(t,n,e){var o=e(38),r=e(39),i=o("keys");t.exports=function(t){return i[t]||(i[t]=r(t))}},function(t,n){t.exports={}},function(t,n){t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},function(t,n,e){var o=e(12).f,r=e(5),i=e(1)("toStringTag");t.exports=function(t,n,e){t&&!r(t=e?t:t.prototype,i)&&o(t,i,{configurable:!0,value:n})}},function(t,n,e){"use strict";var o=e(6),r=e(13),i=e(3),c=e(1),a=e(32),s=c("species"),u=!i((function(){var t=/./;return t.exec=function(){var t=[];return t.groups={a:"7"},t},"7"!=="".replace(t,"$<a>")})),l=!i((function(){var t=/(?:)/,n=t.exec;t.exec=function(){return n.apply(this,arguments)};var e="ab".split(t);return 2!==e.length||"a"!==e[0]||"b"!==e[1]}));t.exports=function(t,n,e,f){var p=c(t),d=!i((function(){var n={};return n[p]=function(){return 7},7!=""[t](n)})),v=d&&!i((function(){var n=!1,e=/a/;return"split"===t&&((e={}).constructor={},e.constructor[s]=function(){return e},e.flags="",e[p]=/./[p]),e.exec=function(){return n=!0,null},e[p](""),!n}));if(!d||!v||"replace"===t&&!u||"split"===t&&!l){var y=/./[p],h=e(p,""[t],(function(t,n,e,o,r){return n.exec===a?d&&!r?{done:!0,value:y.call(n,e,o)}:{done:!0,value:t.call(e,n,o)}:{done:!1}})),m=h[0],g=h[1];r(String.prototype,t,m),r(RegExp.prototype,p,2==n?function(t,n){return g.call(t,this,n)}:function(t){return g.call(t,this)}),f&&o(RegExp.prototype[p],"sham",!0)}}},function(t,n,e){"use strict";var o,r,i=e(101),c=RegExp.prototype.exec,a=String.prototype.replace,s=c,u=(o=/a/,r=/b*/g,c.call(o,"a"),c.call(r,"a"),0!==o.lastIndex||0!==r.lastIndex),l=void 0!==/()??/.exec("")[1];(u||l)&&(s=function(t){var n,e,o,r,s=this;return l&&(e=new RegExp("^"+s.source+"$(?!\\s)",i.call(s))),u&&(n=s.lastIndex),o=c.call(s,t),u&&o&&(s.lastIndex=s.global?o.index+o[0].length:n),l&&o&&o.length>1&&a.call(o[0],e,(function(){for(r=1;r<arguments.length-2;r++)void 0===arguments[r]&&(o[r]=void 0)})),o}),t.exports=s},function(t,n,e){var o=e(7),r=e(32);t.exports=function(t,n){var e=t.exec;if("function"==typeof e){var i=e.call(t,n);if("object"!=typeof i)throw TypeError("RegExp exec method returned something other than an Object or null");return i}if("RegExp"!==o(t))throw TypeError("RegExp#exec called on incompatible receiver");return r.call(t,n)}},function(t,n,e){"use strict";var o,r,i,c,a=e(11),s=e(14),u=e(0),l=e(15),f=e(70),p=e(13),d=e(71),v=e(30),y=e(73),h=e(8),m=e(20),g=e(74),b=e(7),x=e(25),_=e(75),w=e(81),S=e(44),O=e(45).set,j=e(82),k=e(83),P=e(84),E=e(49),L=e(85),I=e(26),C=e(41),T=e(1),A=e(86),M=T("species"),D="Promise",R=I.get,N=I.set,F=I.getterFor(D),U=f,q=u.TypeError,z=u.document,G=u.process,H=l("fetch"),$=E.f,B=$,W="process"==b(G),V=!!(z&&z.createEvent&&u.dispatchEvent),J=C(D,(function(){if(!(x(U)!==String(U))){if(66===A)return!0;if(!W&&"function"!=typeof PromiseRejectionEvent)return!0}if(s&&!U.prototype.finally)return!0;if(A>=51&&/native code/.test(U))return!1;var t=U.resolve(1),n=function(t){t((function(){}),(function(){}))};return(t.constructor={})[M]=n,!(t.then((function(){}))instanceof n)})),Y=J||!w((function(t){U.all(t).catch((function(){}))})),K=function(t){var n;return!(!h(t)||"function"!=typeof(n=t.then))&&n},Z=function(t,n,e){if(!n.notified){n.notified=!0;var o=n.reactions;j((function(){for(var r=n.value,i=1==n.state,c=0;o.length>c;){var a,s,u,l=o[c++],f=i?l.ok:l.fail,p=l.resolve,d=l.reject,v=l.domain;try{f?(i||(2===n.rejection&&nt(t,n),n.rejection=1),!0===f?a=r:(v&&v.enter(),a=f(r),v&&(v.exit(),u=!0)),a===l.promise?d(q("Promise-chain cycle")):(s=K(a))?s.call(a,p,d):p(a)):d(r)}catch(t){v&&!u&&v.exit(),d(t)}}n.reactions=[],n.notified=!1,e&&!n.rejection&&Q(t,n)}))}},X=function(t,n,e){var o,r;V?((o=z.createEvent("Event")).promise=n,o.reason=e,o.initEvent(t,!1,!0),u.dispatchEvent(o)):o={promise:n,reason:e},(r=u["on"+t])?r(o):"unhandledrejection"===t&&P("Unhandled promise rejection",e)},Q=function(t,n){O.call(u,(function(){var e,o=n.value;if(tt(n)&&(e=L((function(){W?G.emit("unhandledRejection",o,t):X("unhandledrejection",t,o)})),n.rejection=W||tt(n)?2:1,e.error))throw e.value}))},tt=function(t){return 1!==t.rejection&&!t.parent},nt=function(t,n){O.call(u,(function(){W?G.emit("rejectionHandled",t):X("rejectionhandled",t,n.value)}))},et=function(t,n,e,o){return function(r){t(n,e,r,o)}},ot=function(t,n,e,o){n.done||(n.done=!0,o&&(n=o),n.value=e,n.state=2,Z(t,n,!0))},rt=function(t,n,e,o){if(!n.done){n.done=!0,o&&(n=o);try{if(t===e)throw q("Promise can't be resolved itself");var r=K(e);r?j((function(){var o={done:!1};try{r.call(e,et(rt,t,o,n),et(ot,t,o,n))}catch(e){ot(t,o,e,n)}})):(n.value=e,n.state=1,Z(t,n,!1))}catch(e){ot(t,{done:!1},e,n)}}};J&&(U=function(t){g(this,U,D),m(t),o.call(this);var n=R(this);try{t(et(rt,this,n),et(ot,this,n))}catch(t){ot(this,n,t)}},(o=function(t){N(this,{type:D,done:!1,notified:!1,parent:!1,reactions:[],rejection:!1,state:0,value:void 0})}).prototype=d(U.prototype,{then:function(t,n){var e=F(this),o=$(S(this,U));return o.ok="function"!=typeof t||t,o.fail="function"==typeof n&&n,o.domain=W?G.domain:void 0,e.parent=!0,e.reactions.push(o),0!=e.state&&Z(this,e,!1),o.promise},catch:function(t){return this.then(void 0,t)}}),r=function(){var t=new o,n=R(t);this.promise=t,this.resolve=et(rt,t,n),this.reject=et(ot,t,n)},E.f=$=function(t){return t===U||t===i?new r(t):B(t)},s||"function"!=typeof f||(c=f.prototype.then,p(f.prototype,"then",(function(t,n){var e=this;return new U((function(t,n){c.call(e,t,n)})).then(t,n)}),{unsafe:!0}),"function"==typeof H&&a({global:!0,enumerable:!0,forced:!0},{fetch:function(t){return k(U,H.apply(u,arguments))}}))),a({global:!0,wrap:!0,forced:J},{Promise:U}),v(U,D,!1,!0),y(D),i=l(D),a({target:D,stat:!0,forced:J},{reject:function(t){var n=$(this);return n.reject.call(void 0,t),n.promise}}),a({target:D,stat:!0,forced:s||J},{resolve:function(t){return k(s&&this===i?U:this,t)}}),a({target:D,stat:!0,forced:Y},{all:function(t){var n=this,e=$(n),o=e.resolve,r=e.reject,i=L((function(){var e=m(n.resolve),i=[],c=0,a=1;_(t,(function(t){var s=c++,u=!1;i.push(void 0),a++,e.call(n,t).then((function(t){u||(u=!0,i[s]=t,--a||o(i))}),r)})),--a||o(i)}));return i.error&&r(i.value),e.promise},race:function(t){var n=this,e=$(n),o=e.reject,r=L((function(){var r=m(n.resolve);_(t,(function(t){r.call(n,t).then(e.resolve,o)}))}));return r.error&&o(r.value),e.promise}})},function(t,n,e){var o=e(8);t.exports=function(t,n){if(!o(t))return t;var e,r;if(n&&"function"==typeof(e=t.toString)&&!o(r=e.call(t)))return r;if("function"==typeof(e=t.valueOf)&&!o(r=e.call(t)))return r;if(!n&&"function"==typeof(e=t.toString)&&!o(r=e.call(t)))return r;throw TypeError("Can't convert object to primitive value")}},function(t,n,e){var o=e(9),r=e(3),i=e(23);t.exports=!o&&!r((function(){return 7!=Object.defineProperty(i("div"),"a",{get:function(){return 7}}).a}))},function(t,n,e){var o=e(0),r=e(24),i=o["__core-js_shared__"]||r("__core-js_shared__",{});t.exports=i},function(t,n,e){var o=e(14),r=e(37);(t.exports=function(t,n){return r[t]||(r[t]=void 0!==n?n:{})})("versions",[]).push({version:"3.5.0",mode:o?"pure":"global",copyright:"© 2019 Denis Pushkarev (zloirock.ru)"})},function(t,n){var e=0,o=Math.random();t.exports=function(t){return"Symbol("+String(void 0===t?"":t)+")_"+(++e+o).toString(36)}},function(t,n,e){var o=e(5),r=e(19),i=e(67).indexOf,c=e(28);t.exports=function(t,n){var e,a=r(t),s=0,u=[];for(e in a)!o(c,e)&&o(a,e)&&u.push(e);for(;n.length>s;)o(a,e=n[s++])&&(~i(u,e)||u.push(e));return u}},function(t,n,e){var o=e(3),r=/#|\.prototype\./,i=function(t,n){var e=a[c(t)];return e==u||e!=s&&("function"==typeof n?o(n):!!n)},c=i.normalize=function(t){return String(t).replace(r,".").toLowerCase()},a=i.data={},s=i.NATIVE="N",u=i.POLYFILL="P";t.exports=i},function(t,n,e){var o=e(3);t.exports=!!Object.getOwnPropertySymbols&&!o((function(){return!String(Symbol())}))},function(t,n,e){var o=e(20);t.exports=function(t,n,e){if(o(t),void 0===n)return t;switch(e){case 0:return function(){return t.call(n)};case 1:return function(e){return t.call(n,e)};case 2:return function(e,o){return t.call(n,e,o)};case 3:return function(e,o,r){return t.call(n,e,o,r)}}return function(){return t.apply(n,arguments)}}},function(t,n,e){var o=e(2),r=e(20),i=e(1)("species");t.exports=function(t,n){var e,c=o(t).constructor;return void 0===c||null==(e=o(c)[i])?n:r(e)}},function(t,n,e){var o,r,i,c=e(0),a=e(3),s=e(7),u=e(43),l=e(46),f=e(23),p=e(47),d=c.location,v=c.setImmediate,y=c.clearImmediate,h=c.process,m=c.MessageChannel,g=c.Dispatch,b=0,x={},_=function(t){if(x.hasOwnProperty(t)){var n=x[t];delete x[t],n()}},w=function(t){return function(){_(t)}},S=function(t){_(t.data)},O=function(t){c.postMessage(t+"",d.protocol+"//"+d.host)};v&&y||(v=function(t){for(var n=[],e=1;arguments.length>e;)n.push(arguments[e++]);return x[++b]=function(){("function"==typeof t?t:Function(t)).apply(void 0,n)},o(b),b},y=function(t){delete x[t]},"process"==s(h)?o=function(t){h.nextTick(w(t))}:g&&g.now?o=function(t){g.now(w(t))}:m&&!p?(i=(r=new m).port2,r.port1.onmessage=S,o=u(i.postMessage,i,1)):!c.addEventListener||"function"!=typeof postMessage||c.importScripts||a(O)?o="onreadystatechange"in f("script")?function(t){l.appendChild(f("script")).onreadystatechange=function(){l.removeChild(this),_(t)}}:function(t){setTimeout(w(t),0)}:(o=O,c.addEventListener("message",S,!1))),t.exports={set:v,clear:y}},function(t,n,e){var o=e(15);t.exports=o("document","documentElement")},function(t,n,e){var o=e(48);t.exports=/(iphone|ipod|ipad).*applewebkit/i.test(o)},function(t,n,e){var o=e(15);t.exports=o("navigator","userAgent")||""},function(t,n,e){"use strict";var o=e(20),r=function(t){var n,e;this.promise=new t((function(t,o){if(void 0!==n||void 0!==e)throw TypeError("Bad Promise constructor");n=t,e=o})),this.resolve=o(n),this.reject=o(e)};t.exports.f=function(t){return new r(t)}},function(t,n,e){var o=e(2),r=e(90),i=e(29),c=e(28),a=e(46),s=e(23),u=e(27)("IE_PROTO"),l=function(){},f=function(){var t,n=s("iframe"),e=i.length;for(n.style.display="none",a.appendChild(n),n.src=String("javascript:"),(t=n.contentWindow.document).open(),t.write("<script>document.F=Object<\/script>"),t.close(),f=t.F;e--;)delete f.prototype[i[e]];return f()};t.exports=Object.create||function(t,n){var e;return null!==t?(l.prototype=o(t),e=new l,l.prototype=null,e[u]=t):e=f(),void 0===n?e:r(e,n)},c[u]=!0},function(t,n,e){"use strict";var o,r,i,c=e(52),a=e(6),s=e(5),u=e(1),l=e(14),f=u("iterator"),p=!1;[].keys&&("next"in(i=[].keys())?(r=c(c(i)))!==Object.prototype&&(o=r):p=!0),null==o&&(o={}),l||s(o,f)||a(o,f,(function(){return this})),t.exports={IteratorPrototype:o,BUGGY_SAFARI_ITERATORS:p}},function(t,n,e){var o=e(5),r=e(53),i=e(27),c=e(94),a=i("IE_PROTO"),s=Object.prototype;t.exports=c?Object.getPrototypeOf:function(t){return t=r(t),o(t,a)?t[a]:"function"==typeof t.constructor&&t instanceof t.constructor?t.constructor.prototype:t instanceof Object?s:null}},function(t,n,e){var o=e(4);t.exports=function(t){return Object(o(t))}},function(t,n,e){"use strict";var o=e(102).charAt;t.exports=function(t,n,e){return n+(e?o(t,n).length:1)}},function(t,n,e){"use strict";var o=e(31),r=e(56),i=e(2),c=e(4),a=e(44),s=e(54),u=e(16),l=e(33),f=e(32),p=e(3),d=[].push,v=Math.min,y=!p((function(){return!RegExp(4294967295,"y")}));o("split",2,(function(t,n,e){var o;return o="c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1).length||2!="ab".split(/(?:ab)*/).length||4!=".".split(/(.?)(.?)/).length||".".split(/()()/).length>1||"".split(/.?/).length?function(t,e){var o=String(c(this)),i=void 0===e?4294967295:e>>>0;if(0===i)return[];if(void 0===t)return[o];if(!r(t))return n.call(o,t,i);for(var a,s,u,l=[],p=(t.ignoreCase?"i":"")+(t.multiline?"m":"")+(t.unicode?"u":"")+(t.sticky?"y":""),v=0,y=new RegExp(t.source,p+"g");(a=f.call(y,o))&&!((s=y.lastIndex)>v&&(l.push(o.slice(v,a.index)),a.length>1&&a.index<o.length&&d.apply(l,a.slice(1)),u=a[0].length,v=s,l.length>=i));)y.lastIndex===a.index&&y.lastIndex++;return v===o.length?!u&&y.test("")||l.push(""):l.push(o.slice(v)),l.length>i?l.slice(0,i):l}:"0".split(void 0,0).length?function(t,e){return void 0===t&&0===e?[]:n.call(this,t,e)}:n,[function(n,e){var r=c(this),i=null==n?void 0:n[t];return void 0!==i?i.call(n,r,e):o.call(String(r),n,e)},function(t,r){var c=e(o,t,this,r,o!==n);if(c.done)return c.value;var f=i(t),p=String(this),d=a(f,RegExp),h=f.unicode,m=(f.ignoreCase?"i":"")+(f.multiline?"m":"")+(f.unicode?"u":"")+(y?"y":"g"),g=new d(y?f:"^(?:"+f.source+")",m),b=void 0===r?4294967295:r>>>0;if(0===b)return[];if(0===p.length)return null===l(g,p)?[p]:[];for(var x=0,_=0,w=[];_<p.length;){g.lastIndex=y?_:0;var S,O=l(g,y?p:p.slice(_));if(null===O||(S=v(u(g.lastIndex+(y?0:_)),p.length))===x)_=s(p,_,h);else{if(w.push(p.slice(x,_)),w.length===b)return w;for(var j=1;j<=O.length-1;j++)if(w.push(O[j]),w.length===b)return w;_=x=S}}return w.push(p.slice(x)),w}]}),!y)},function(t,n,e){var o=e(8),r=e(7),i=e(1)("match");t.exports=function(t){var n;return o(t)&&(void 0!==(n=t[i])?!!n:"RegExp"==r(t))}},function(t,n,e){var o=e(56);t.exports=function(t){if(o(t))throw TypeError("The method doesn't accept regular expressions");return t}},function(t,n,e){var o=e(1)("match");t.exports=function(t){var n=/./;try{"/./"[t](n)}catch(e){try{return n[o]=!1,"/./"[t](n)}catch(t){}}return!1}},function(t,n){var e;e=function(){return this}();try{e=e||new Function("return this")()}catch(t){"object"==typeof window&&(e=window)}t.exports=e},function(t,n,e){"use strict";var o={}.propertyIsEnumerable,r=Object.getOwnPropertyDescriptor,i=r&&!o.call({1:2},1);n.f=i?function(t){var n=r(this,t);return!!n&&n.enumerable}:o},function(t,n,e){var o=e(3),r=e(7),i="".split;t.exports=o((function(){return!Object("z").propertyIsEnumerable(0)}))?function(t){return"String"==r(t)?i.call(t,""):Object(t)}:Object},function(t,n,e){var o=e(0),r=e(25),i=o.WeakMap;t.exports="function"==typeof i&&/native code/.test(r(i))},function(t,n,e){var o=e(5),r=e(64),i=e(18),c=e(12);t.exports=function(t,n){for(var e=r(n),a=c.f,s=i.f,u=0;u<e.length;u++){var l=e[u];o(t,l)||a(t,l,s(n,l))}}},function(t,n,e){var o=e(15),r=e(66),i=e(69),c=e(2);t.exports=o("Reflect","ownKeys")||function(t){var n=r.f(c(t)),e=i.f;return e?n.concat(e(t)):n}},function(t,n,e){var o=e(0);t.exports=o},function(t,n,e){var o=e(40),r=e(29).concat("length","prototype");n.f=Object.getOwnPropertyNames||function(t){return o(t,r)}},function(t,n,e){var o=e(19),r=e(16),i=e(68),c=function(t){return function(n,e,c){var a,s=o(n),u=r(s.length),l=i(c,u);if(t&&e!=e){for(;u>l;)if((a=s[l++])!=a)return!0}else for(;u>l;l++)if((t||l in s)&&s[l]===e)return t||l||0;return!t&&-1}};t.exports={includes:c(!0),indexOf:c(!1)}},function(t,n,e){var o=e(10),r=Math.max,i=Math.min;t.exports=function(t,n){var e=o(t);return e<0?r(e+n,0):i(e,n)}},function(t,n){n.f=Object.getOwnPropertySymbols},function(t,n,e){var o=e(0);t.exports=o.Promise},function(t,n,e){var o=e(13);t.exports=function(t,n,e){for(var r in n)o(t,r,n[r],e);return t}},function(t,n,e){var o=e(42);t.exports=o&&!Symbol.sham&&"symbol"==typeof Symbol()},function(t,n,e){"use strict";var o=e(15),r=e(12),i=e(1),c=e(9),a=i("species");t.exports=function(t){var n=o(t),e=r.f;c&&n&&!n[a]&&e(n,a,{configurable:!0,get:function(){return this}})}},function(t,n){t.exports=function(t,n,e){if(!(t instanceof n))throw TypeError("Incorrect "+(e?e+" ":"")+"invocation");return t}},function(t,n,e){var o=e(2),r=e(76),i=e(16),c=e(43),a=e(77),s=e(80),u=function(t,n){this.stopped=t,this.result=n};(t.exports=function(t,n,e,l,f){var p,d,v,y,h,m,g,b=c(n,e,l?2:1);if(f)p=t;else{if("function"!=typeof(d=a(t)))throw TypeError("Target is not iterable");if(r(d)){for(v=0,y=i(t.length);y>v;v++)if((h=l?b(o(g=t[v])[0],g[1]):b(t[v]))&&h instanceof u)return h;return new u(!1)}p=d.call(t)}for(m=p.next;!(g=m.call(p)).done;)if("object"==typeof(h=s(p,b,g.value,l))&&h&&h instanceof u)return h;return new u(!1)}).stop=function(t){return new u(!0,t)}},function(t,n,e){var o=e(1),r=e(17),i=o("iterator"),c=Array.prototype;t.exports=function(t){return void 0!==t&&(r.Array===t||c[i]===t)}},function(t,n,e){var o=e(78),r=e(17),i=e(1)("iterator");t.exports=function(t){if(null!=t)return t[i]||t["@@iterator"]||r[o(t)]}},function(t,n,e){var o=e(79),r=e(7),i=e(1)("toStringTag"),c="Arguments"==r(function(){return arguments}());t.exports=o?r:function(t){var n,e,o;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(e=function(t,n){try{return t[n]}catch(t){}}(n=Object(t),i))?e:c?r(n):"Object"==(o=r(n))&&"function"==typeof n.callee?"Arguments":o}},function(t,n,e){var o={};o[e(1)("toStringTag")]="z",t.exports="[object z]"===String(o)},function(t,n,e){var o=e(2);t.exports=function(t,n,e,r){try{return r?n(o(e)[0],e[1]):n(e)}catch(n){var i=t.return;throw void 0!==i&&o(i.call(t)),n}}},function(t,n,e){var o=e(1)("iterator"),r=!1;try{var i=0,c={next:function(){return{done:!!i++}},return:function(){r=!0}};c[o]=function(){return this},Array.from(c,(function(){throw 2}))}catch(t){}t.exports=function(t,n){if(!n&&!r)return!1;var e=!1;try{var i={};i[o]=function(){return{next:function(){return{done:e=!0}}}},t(i)}catch(t){}return e}},function(t,n,e){var o,r,i,c,a,s,u,l,f=e(0),p=e(18).f,d=e(7),v=e(45).set,y=e(47),h=f.MutationObserver||f.WebKitMutationObserver,m=f.process,g=f.Promise,b="process"==d(m),x=p(f,"queueMicrotask"),_=x&&x.value;_||(o=function(){var t,n;for(b&&(t=m.domain)&&t.exit();r;){n=r.fn,r=r.next;try{n()}catch(t){throw r?c():i=void 0,t}}i=void 0,t&&t.enter()},b?c=function(){m.nextTick(o)}:h&&!y?(a=!0,s=document.createTextNode(""),new h(o).observe(s,{characterData:!0}),c=function(){s.data=a=!a}):g&&g.resolve?(u=g.resolve(void 0),l=u.then,c=function(){l.call(u,o)}):c=function(){v.call(f,o)}),t.exports=_||function(t){var n={fn:t,next:void 0};i&&(i.next=n),r||(r=n,c()),i=n}},function(t,n,e){var o=e(2),r=e(8),i=e(49);t.exports=function(t,n){if(o(t),r(n)&&n.constructor===t)return n;var e=i.f(t);return(0,e.resolve)(n),e.promise}},function(t,n,e){var o=e(0);t.exports=function(t,n){var e=o.console;e&&e.error&&(1===arguments.length?e.error(t):e.error(t,n))}},function(t,n){t.exports=function(t){try{return{error:!1,value:t()}}catch(t){return{error:!0,value:t}}}},function(t,n,e){var o,r,i=e(0),c=e(48),a=i.process,s=a&&a.versions,u=s&&s.v8;u?r=(o=u.split("."))[0]+o[1]:c&&(!(o=c.match(/Edge\/(\d+)/))||o[1]>=74)&&(o=c.match(/Chrome\/(\d+)/))&&(r=o[1]),t.exports=r&&+r},function(t,n){t.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},function(t,n,e){"use strict";var o=e(19),r=e(89),i=e(17),c=e(26),a=e(92),s=c.set,u=c.getterFor("Array Iterator");t.exports=a(Array,"Array",(function(t,n){s(this,{type:"Array Iterator",target:o(t),index:0,kind:n})}),(function(){var t=u(this),n=t.target,e=t.kind,o=t.index++;return!n||o>=n.length?(t.target=void 0,{value:void 0,done:!0}):"keys"==e?{value:o,done:!1}:"values"==e?{value:n[o],done:!1}:{value:[o,n[o]],done:!1}}),"values"),i.Arguments=i.Array,r("keys"),r("values"),r("entries")},function(t,n,e){var o=e(1),r=e(50),i=e(6),c=o("unscopables"),a=Array.prototype;null==a[c]&&i(a,c,r(null)),t.exports=function(t){a[c][t]=!0}},function(t,n,e){var o=e(9),r=e(12),i=e(2),c=e(91);t.exports=o?Object.defineProperties:function(t,n){i(t);for(var e,o=c(n),a=o.length,s=0;a>s;)r.f(t,e=o[s++],n[e]);return t}},function(t,n,e){var o=e(40),r=e(29);t.exports=Object.keys||function(t){return o(t,r)}},function(t,n,e){"use strict";var o=e(11),r=e(93),i=e(52),c=e(95),a=e(30),s=e(6),u=e(13),l=e(1),f=e(14),p=e(17),d=e(51),v=d.IteratorPrototype,y=d.BUGGY_SAFARI_ITERATORS,h=l("iterator"),m=function(){return this};t.exports=function(t,n,e,l,d,g,b){r(e,n,l);var x,_,w,S=function(t){if(t===d&&E)return E;if(!y&&t in k)return k[t];switch(t){case"keys":case"values":case"entries":return function(){return new e(this,t)}}return function(){return new e(this)}},O=n+" Iterator",j=!1,k=t.prototype,P=k[h]||k["@@iterator"]||d&&k[d],E=!y&&P||S(d),L="Array"==n&&k.entries||P;if(L&&(x=i(L.call(new t)),v!==Object.prototype&&x.next&&(f||i(x)===v||(c?c(x,v):"function"!=typeof x[h]&&s(x,h,m)),a(x,O,!0,!0),f&&(p[O]=m))),"values"==d&&P&&"values"!==P.name&&(j=!0,E=function(){return P.call(this)}),f&&!b||k[h]===E||s(k,h,E),p[n]=E,d)if(_={values:S("values"),keys:g?E:S("keys"),entries:S("entries")},b)for(w in _)!y&&!j&&w in k||u(k,w,_[w]);else o({target:n,proto:!0,forced:y||j},_);return _}},function(t,n,e){"use strict";var o=e(51).IteratorPrototype,r=e(50),i=e(22),c=e(30),a=e(17),s=function(){return this};t.exports=function(t,n,e){var u=n+" Iterator";return t.prototype=r(o,{next:i(1,e)}),c(t,u,!1,!0),a[u]=s,t}},function(t,n,e){var o=e(3);t.exports=!o((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype}))},function(t,n,e){var o=e(2),r=e(96);t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var t,n=!1,e={};try{(t=Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set).call(e,[]),n=e instanceof Array}catch(t){}return function(e,i){return o(e),r(i),n?t.call(e,i):e.__proto__=i,e}}():void 0)},function(t,n,e){var o=e(8);t.exports=function(t){if(!o(t)&&null!==t)throw TypeError("Can't set "+String(t)+" as a prototype");return t}},function(t,n,e){"use strict";var o=e(11),r=e(10),i=e(98),c=e(99),a=e(3),s=1..toFixed,u=Math.floor,l=function(t,n,e){return 0===n?e:n%2==1?l(t,n-1,e*t):l(t*t,n/2,e)};o({target:"Number",proto:!0,forced:s&&("0.000"!==8e-5.toFixed(3)||"1"!==.9.toFixed(0)||"1.25"!==1.255.toFixed(2)||"1000000000000000128"!==(0xde0b6b3a7640080).toFixed(0))||!a((function(){s.call({})}))},{toFixed:function(t){var n,e,o,a,s=i(this),f=r(t),p=[0,0,0,0,0,0],d="",v="0",y=function(t,n){for(var e=-1,o=n;++e<6;)o+=t*p[e],p[e]=o%1e7,o=u(o/1e7)},h=function(t){for(var n=6,e=0;--n>=0;)e+=p[n],p[n]=u(e/t),e=e%t*1e7},m=function(){for(var t=6,n="";--t>=0;)if(""!==n||0===t||0!==p[t]){var e=String(p[t]);n=""===n?e:n+c.call("0",7-e.length)+e}return n};if(f<0||f>20)throw RangeError("Incorrect fraction digits");if(s!=s)return"NaN";if(s<=-1e21||s>=1e21)return String(s);if(s<0&&(d="-",s=-s),s>1e-21)if(e=(n=function(t){for(var n=0,e=t;e>=4096;)n+=12,e/=4096;for(;e>=2;)n+=1,e/=2;return n}(s*l(2,69,1))-69)<0?s*l(2,-n,1):s/l(2,n,1),e*=4503599627370496,(n=52-n)>0){for(y(0,e),o=f;o>=7;)y(1e7,0),o-=7;for(y(l(10,o,1),0),o=n-1;o>=23;)h(1<<23),o-=23;h(1<<o),y(1,1),h(2),v=m()}else y(0,e),y(1<<-n,0),v=m()+c.call("0",f);return v=f>0?d+((a=v.length)<=f?"0."+c.call("0",f-a)+v:v.slice(0,a-f)+"."+v.slice(a-f)):d+v}})},function(t,n,e){var o=e(7);t.exports=function(t){if("number"!=typeof t&&"Number"!=o(t))throw TypeError("Incorrect invocation");return+t}},function(t,n,e){"use strict";var o=e(10),r=e(4);t.exports="".repeat||function(t){var n=String(r(this)),e="",i=o(t);if(i<0||i==1/0)throw RangeError("Wrong number of repetitions");for(;i>0;(i>>>=1)&&(n+=n))1&i&&(e+=n);return e}},function(t,n,e){"use strict";var o=e(31),r=e(2),i=e(53),c=e(16),a=e(10),s=e(4),u=e(54),l=e(33),f=Math.max,p=Math.min,d=Math.floor,v=/\$([$&'`]|\d\d?|<[^>]*>)/g,y=/\$([$&'`]|\d\d?)/g;o("replace",2,(function(t,n,e){return[function(e,o){var r=s(this),i=null==e?void 0:e[t];return void 0!==i?i.call(e,r,o):n.call(String(r),e,o)},function(t,i){var s=e(n,t,this,i);if(s.done)return s.value;var d=r(t),v=String(this),y="function"==typeof i;y||(i=String(i));var h=d.global;if(h){var m=d.unicode;d.lastIndex=0}for(var g=[];;){var b=l(d,v);if(null===b)break;if(g.push(b),!h)break;""===String(b[0])&&(d.lastIndex=u(v,c(d.lastIndex),m))}for(var x,_="",w=0,S=0;S<g.length;S++){b=g[S];for(var O=String(b[0]),j=f(p(a(b.index),v.length),0),k=[],P=1;P<b.length;P++)k.push(void 0===(x=b[P])?x:String(x));var E=b.groups;if(y){var L=[O].concat(k,j,v);void 0!==E&&L.push(E);var I=String(i.apply(void 0,L))}else I=o(O,v,j,k,E,i);j>=w&&(_+=v.slice(w,j)+I,w=j+O.length)}return _+v.slice(w)}];function o(t,e,o,r,c,a){var s=o+t.length,u=r.length,l=y;return void 0!==c&&(c=i(c),l=v),n.call(a,l,(function(n,i){var a;switch(i.charAt(0)){case"$":return"$";case"&":return t;case"`":return e.slice(0,o);case"'":return e.slice(s);case"<":a=c[i.slice(1,-1)];break;default:var l=+i;if(0===l)return n;if(l>u){var f=d(l/10);return 0===f?n:f<=u?void 0===r[f-1]?i.charAt(1):r[f-1]+i.charAt(1):n}a=r[l-1]}return void 0===a?"":a}))}}))},function(t,n,e){"use strict";var o=e(2);t.exports=function(){var t=o(this),n="";return t.global&&(n+="g"),t.ignoreCase&&(n+="i"),t.multiline&&(n+="m"),t.dotAll&&(n+="s"),t.unicode&&(n+="u"),t.sticky&&(n+="y"),n}},function(t,n,e){var o=e(10),r=e(4),i=function(t){return function(n,e){var i,c,a=String(r(n)),s=o(e),u=a.length;return s<0||s>=u?t?"":void 0:(i=a.charCodeAt(s))<55296||i>56319||s+1===u||(c=a.charCodeAt(s+1))<56320||c>57343?t?a.charAt(s):i:t?a.slice(s,s+2):c-56320+(i-55296<<10)+65536}};t.exports={codeAt:i(!1),charAt:i(!0)}},function(t,n,e){"use strict";var o=e(11),r=e(57),i=e(4);o({target:"String",proto:!0,forced:!e(58)("includes")},{includes:function(t){return!!~String(i(this)).indexOf(r(t),arguments.length>1?arguments[1]:void 0)}})},function(t,n,e){"use strict";var o=e(31),r=e(2),i=e(4),c=e(105),a=e(33);o("search",1,(function(t,n,e){return[function(n){var e=i(this),o=null==n?void 0:n[t];return void 0!==o?o.call(n,e):new RegExp(n)[t](String(e))},function(t){var o=e(n,t,this);if(o.done)return o.value;var i=r(t),s=String(this),u=i.lastIndex;c(u,0)||(i.lastIndex=0);var l=a(i,s);return c(i.lastIndex,u)||(i.lastIndex=u),null===l?-1:l.index}]}))},function(t,n){t.exports=Object.is||function(t,n){return t===n?0!==t||1/t==1/n:t!=t&&n!=n}},function(t,n,e){"use strict";var o,r=e(11),i=e(18).f,c=e(16),a=e(57),s=e(4),u=e(58),l=e(14),f="".startsWith,p=Math.min,d=u("startsWith");r({target:"String",proto:!0,forced:!!(l||d||(o=i(String.prototype,"startsWith"),!o||o.writable))&&!d},{startsWith:function(t){var n=String(s(this));a(t);var e=c(p(arguments.length>1?arguments[1]:void 0,n.length)),o=String(t);return f?f.call(n,o,e):n.slice(e,e+o.length)===o}})},function(t,n,e){"use strict";e.r(n);e(34),e(21);var o={get:(t="loop-onstore-data")=>JSON.parse(localStorage.getItem(t)||null),set(t,n="loop-onstore-data"){localStorage.setItem(n,JSON.stringify(t))},remove(t="loop-onstore-data"){localStorage.removeItem(t)}};function r(t,n){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);n&&(o=o.filter((function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable}))),e.push.apply(e,o)}return e}function i(t,n,e){return n in t?Object.defineProperty(t,n,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[n]=e,t}let c={debug:!1,testMode:!1,redirect:!0,active:!1,params:null,key:null,api:null,token:null,id:null,fullPayload:!1,preserveCart:!1,draftOrderId:null};const a=t=>t?c[t]:c,s=(t,n)=>{c[t]=n,o.set(c)},u=()=>{const t=o.get();t&&(c=function(t){for(var n=1;n<arguments.length;n++){var e=null!=arguments[n]?arguments[n]:{};n%2?r(Object(e),!0).forEach((function(n){i(t,n,e[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):r(Object(e)).forEach((function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(e,n))}))}return t}({},c,{},t))};var l=new Proxy({},{get:(t,n)=>!t[n]&&a("debug")?t=>"string"==typeof t?console[n]("%c".concat(t),"color: #3256E6"):console[n](t):t[n]||function(){}});const f=(t,n)=>{const e=[...document.querySelectorAll(t)];return e.length>1&&l.warn("Attaching Loop.submit() to more than one element. Make sure you're using the right selector!"),e.forEach(t=>{t.addEventListener("click",n)}),e};e(97),e(100),e(55);const p={JPY:{constant:1,decimals:0,decimalSymbol:"",thousandSymbol:",",symbol:"¥"},GBP:{constant:100,decimals:2,decimalSymbol:".",thousandSymbol:",",symbol:"£"},EUR:{constant:100,decimals:2,decimalSymbol:",",thousandSymbol:".",symbol:"€"},USD:{constant:100,decimals:2,decimalSymbol:".",thousandSymbol:",",symbol:"$"},CAD:{constant:100,decimals:2,decimalSymbol:".",thousandSymbol:",",symbol:"$"},AUD:{constant:100,decimals:2,decimalSymbol:".",thousandSymbol:",",symbol:"$"},HKD:{constant:100,decimals:2,decimalSymbol:".",thousandSymbol:",",symbol:"$"},NZD:{constant:100,decimals:2,decimalSymbol:".",thousandSymbol:",",symbol:"$"},SGD:{constant:100,decimals:2,decimalSymbol:".",thousandSymbol:",",symbol:"$"}},d=(t,n="USD")=>{if(!t)return"";const e=p[n];if(e){const{dollars:n,cents:o}=((t,n)=>{const[e,o]=Number.parseFloat(t/n.constant).toFixed(n.decimals).split(".");return{dollars:e?e.replace(/\B(?=(\d{3})+(?!\d))/g,n.thousandSymbol):"0",cents:o||""}})(t,e);return"".concat(e.symbol).concat(n).concat(e.decimalSymbol).concat(o)}return new Intl.NumberFormat("en-US",{style:"currency",currency:n}).format(t/e.constant)};function v(t,n){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);n&&(o=o.filter((function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable}))),e.push.apply(e,o)}return e}function y(t){for(var n=1;n<arguments.length;n++){var e=null!=arguments[n]?arguments[n]:{};n%2?v(Object(e),!0).forEach((function(n){h(t,n,e[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):v(Object(e)).forEach((function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(e,n))}))}return t}function h(t,n,e){return n in t?Object.defineProperty(t,n,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[n]=e,t}const m=()=>{var t;return null!==(t=a("api"))&&void 0!==t?t:"https://api.loopreturns.com/api/v1/"},g=t=>{const{token:n,total_discount:e,original_total_price:o,total_price:r,items:i,currency:c,items_subtotal_price:a,cart_level_discount_applications:s}=t;return(t=>{const n="object"==typeof t&&null!==t?JSON.stringify(t):String(t);return window.btoa(unescape(encodeURIComponent(n)))})({token:n,total_discount:e,original_total_price:o,total_price:r,items:i.map(t=>{const{id:n,quantity:e,variant_id:o,price:r,original_price:i,discounted_price:c,original_line_price:a,line_price:s,total_discount:u,final_price:l,final_line_price:f,taxable:p,product_id:d,discount_allocations:v,line_level_discount_allocations:y}=t;return{id:n,quantity:e,variant_id:o,price:r,original_price:i,discounted_price:c,original_line_price:a,line_price:s,total_discount:u,final_price:l,final_line_price:f,taxable:p,product_id:d,discount_allocations:v,line_level_discount_allocations:y}}),currency:c,items_subtotal_price:a,cart_level_discount_applications:s})},b=(t,n="GET",e)=>{const o=a("key");return new Promise(r=>{const i=null!=e?JSON.stringify(e):null;var c=new XMLHttpRequest;c.withCredentials=!0,c.addEventListener("readystatechange",(function(){this.readyState===this.DONE&&r(JSON.parse(this.responseText))})),c.open(n,t),""!==o&&c.setRequestHeader("x-authorization",o),c.setRequestHeader("content-type","application/json"),c.send(i)})},x=()=>{return b("/cart/clear.js","POST")};function _(t,n){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);n&&(o=o.filter((function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable}))),e.push.apply(e,o)}return e}function w(t,n,e){return n in t?Object.defineProperty(t,n,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[n]=e,t}const S=(t,n)=>{l.info("Creating cart request..."),l.info("Syncing these variants to the Loop cart:"),l.info(t);const e=a("token");return e?((t,n,e)=>{const o=m(),r="".concat(o,"cart/").concat(t);let i={};return a("fullPayload")&&(i={shopify:g(e)}),b(r,"POST",y({cart:n,draftOrderId:a("draftOrderId")},i))})(e,t,n).then(t=>(function(t){for(var n=1;n<arguments.length;n++){var e=null!=arguments[n]?arguments[n]:{};n%2?_(Object(e),!0).forEach((function(n){w(t,n,e[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):_(Object(e)).forEach((function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(e,n))}))}return t})({},t,{token:e})):((t,n)=>{const e=m(),o="".concat(e,"cart/");let r={};return a("fullPayload")&&(r={shopify:g(n)}),b(o,"POST",y({cart:t,draftOrderId:a("draftOrderId")},r))})(t,n)};e(103),e(104),e(106);function O(t,n){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);n&&(o=o.filter((function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable}))),e.push.apply(e,o)}return e}function j(t,n,e){return n in t?Object.defineProperty(t,n,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[n]=e,t}const k=t=>{const n=Number(t);return Number.isNaN(n)?t:n};var P={get:(t=window.location.search)=>t.substr(1).split("&").reduce((t,n)=>{const[e,o]=decodeURIComponent(n).split("=");return function(t){for(var n=1;n<arguments.length;n++){var e=null!=arguments[n]?arguments[n]:{};n%2?O(Object(e),!0).forEach((function(n){j(t,n,e[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):O(Object(e)).forEach((function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(e,n))}))}return t}({},t,{[e]:k(o)})},{}),hasLoopData:(t=window.location.search)=>t.includes("loop_total"),getKeys:(t,n="loop")=>Object.keys(t).filter(t=>t.startsWith(n)),clear(t=[]){const n=Object.entries(this.get()).reduce((n,[e,o])=>{if(t.includes(e))return n;const r=n.length?"&":"?";return"".concat(n).concat(r).concat(encodeURIComponent(e),"=").concat(encodeURIComponent(o))},"");window.history.replaceState({},"","".concat(window.location.origin).concat(window.location.pathname).concat(n))}};const E={credit:{container:".loop-onstore__credit",amount:".loop-onstore__credit-amount"},percentDiscount:{container:".loop-onstore__percent-discount",amount:".loop-onstore__percent-discount-amount"}};var L=(t,n={})=>{if(t)return t;const e=((t={})=>{const n=document.createElement("div");return n.classList.add("loop-onstore"),n.id="loop-onstore",n.innerHTML='\n <div class="loop-onstore__percent-discount">\n <span class="loop-onstore__percent-discount-amount"></span>\n <span class="loop-onstore__copy loop-onstore__percent-discount-copy">\n applied at checkout\n </span>\n </div>\n <div class="loop-onstore__credit">\n <span class="loop-onstore__amount loop-onstore__credit-amount"></span>\n <span class="loop-onstore__copy loop-onstore__credit-copy">\n in available credit\n </span>\n <span class="loop-onstore__copy loop-onstore__mobile-credit-copy">\n credit\n </span>\n </div>\n <button class="loop-onstore__back" onClick="LoopOnstore.backToLoop()">\n <svg \n class="loop-onstore__back-icon"\n width="16"\n height="16"\n viewBox="0 0 16 16"\n fill="none"\n xmlns="http://www.w3.org/2000/svg"\n >\n <path d="M12.6667 8H3.33333" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>\n <path d="M8 12.6666L3.33333 7.99998L8 3.33331" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>\n </svg> \n <span>Go back</span>\n </button>\n\n',Object.keys(t).forEach(e=>{const o=t[e],r=E[e];if(r&&o){const t=n.querySelector(r.container);if(t){t.style.display="flex";const n=t.querySelector(r.amount);n&&o.amount&&(n.textContent=o.amount)}}}),n})(n);return document.body.appendChild(e)};e.d(n,"init",(function(){return C})),e.d(n,"testMode",(function(){return T})),e.d(n,"submit",(function(){return D})),e.d(n,"attach",(function(){return R})),e.d(n,"debug",(function(){return A})),e.d(n,"setKey",(function(){return M})),e.d(n,"backToLoop",(function(){return N})),e.d(n,"isActive",(function(){return F}));const I={bar:null,attached:[]},C=async t=>{if(u(),null==t?void 0:t.key)M(t.key);else if(!a("key"))throw new Error("Loop Returns on-store API requires an API key.");(null==t?void 0:t.api)&&(l.info("Setting api to ".concat(t.api,".")),s("api",t.api)),(null==t?void 0:t.preserveCart)&&(l.info("Setting preserve cart to ".concat(t.preserveCart)),s("preserveCart",t.preserveCart));const n=P.get();if(P.hasLoopData()){a("id")!==n.loop_return_id&&s("token",null),s("params",n),s("id",n.loop_return_id),P.clear(P.getKeys(n)),await x();const t=a("token");if(t)try{const{cart:n}=await(t=>{const n=m(),e="".concat(n,"cart/").concat(t);return b(e)})(t);await(t=>{const n=t.reduce((t,n)=>t[n]?y({},t,{[n]:t[n]+1}):y({},t,{[n]:1}),{});return b("/cart/update.js","POST",{updates:n})})(n),l.info("Updating Shopify cart to match loop cart."),document.dispatchEvent(new Event("Loop:Cart Update"))}catch(t){l.warn("Unable to reboot cart"),l.error(t)}}const e=a("params");if(e){var o,r;s("active",!0),document.body.classList.add("loop-returns-activated");const t={};null!==(o=e.loop_total)&&void 0!==o&&o&&(t.credit={amount:d(e.loop_total,e.loop_currency)}),null!==(r=e.loop_discount_percentage)&&void 0!==r&&r&&(t.percentDiscount={amount:e.loop_discount_percentage+"% off"});const n=L(null,t);(()=>{const t=document.createElement("style");t.type="text/css",t.innerText="\n:root {\n --loop-primary-color: #030712;\n --loop-text-color: white;\n --loop-badge-background: #F9FAFB;\n --loop-badge-text: #374151;\n --loop-button-background: white;\n --loop-button-text: #1F2937;\n --loop-button-border: #D1D5DB;\n}\n.loop-returns-activated .loop-onstore {\n transform: translateY(0);\n display: flex;\n}\n.loop-onstore {\n box-sizing: border-box;\n width: 100%;\n position: fixed;\n display: none;\n align-items: center;\n justify-content: space-between;\n top: auto !important;\n bottom: 0 !important;\n left: 0;\n z-index: 2147483647;\n background-color: var(--loop-primary-color);\n color: var(--loop-text-color);\n font-family: 'SF Pro Text', untitled sans, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Sans', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji' !important;\n transform: translateY(100%);\n transition: transform .2s;\n font-size: 0.875rem;\n font-style: normal;\n font-weight: 400;\n line-height: 150%;\n padding: 1rem 1.5rem;\n}\n.loop-onstore *, .loop-onstore *::before, .loop-onstore *::after {\n box-sizing: inherit;\n}\n.loop-onstore__credit {\n display: none;\n align-items: flex-start;\n gap: 0.25rem;\n}\n.loop-onstore__credit-amount {\n font-weight: 600;\n}\n.loop-onstore__mobile-credit-copy {\n display: none;\n}\n.loop-onstore__percent-discount {\n display: none;\n align-items: flex-start;\n gap: 0.5rem; \n}\n.loop-onstore__percent-discount-amount {\n display: flex;\n padding: 0.125rem 0.5rem;\n justify-content: center;\n align-items: center;\n gap: 0.375rem;\n border-radius: 100px;\n background: var(--loop-badge-background);\n font-weight: 600;\n font-size: 0.75rem;\n color: var(--loop-badge-text);\n}\n.loop-onstore__percent-discount-copy {\n text-align: center;\n}\n.loop-onstore__back {\n color: var(--loop-button-text);\n background: var(--loop-button-background);\n border: none;\n appearance: none;\n transition: all .2s;\n font-size: 1rem;\n font-weight: 600;\n line-height: 1.5rem;\n border-radius: 0.5rem;\n border: 1px solid var(--loop-button-border);\n display: flex;\n padding: 0.5rem 1rem;\n align-items: center;\n gap: 0.25rem; \n cursor: pointer;\n}\n.loop-onstore__back:hover {\n opacity: .7;\n}\n.loop-onstore__back-icon path {\n stroke: var(--loop-button-text); \n}\n\n.loop-returns-modal {\n font-family: 'SF Pro Text', untitled sans,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji !important;\n -moz-osx-font-smoothing: grayscale;\n -webkit-font-smoothing: antialiased;\n font-style: normal;\n display: flex;\n justify-content: center;\n align-items: center;\n position: fixed;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n z-index: 999;\n }\n\n .loop-returns-modal__backdrop{\n position: fixed;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background-color: rgba(65, 69, 74, 0.7);\n }\n\n .loop-returns-modal__content {\n overflow: auto;\n max-height: 600px;\n background-color: #fff;\n box-shadow: 0px 1px 4px rgb(0 0 0 / 12%), 0px 6px 12px rgb(0 0 0 / 8%);\n border-radius: 8px;\n width: 500px;\n max-width: 700px;\n position: relative;\n z-index: 1000;\n }\n\n .loop-returns-modal__header {\n color: #3256E5;\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding: 15px 20px;\n border-bottom: 1px solid #EAEAEA;\n font-size: 1.25rem;\n font-weight: 500;\n }\n\n .loop-returns-modal__close--icon {\n height: 20px;\n width: 20px;\n cursor: pointer;\n }\n\n .loop-returns-modal__body {\n padding: 20px;\n }\n\n@media screen and (max-width: 680px) {\n .loop-onstore {\n z-index: 200;\n bottom: 3.2rem;\n padding: 1rem 1.5rem;\n }\n .loop-onstore__mobile-credit-copy {\n display: block;\n }\n .loop-onstore__credit-copy {\n display: none;\n }\n .loop-onstore__percent-discount-copy {\n display: none;\n }\n .loop-onstore__back {\n font-size: 0.875rem;\n line-height: 1.25rem;\n }\n}\n",document.head.appendChild(t)})(),I.bar=n,l.info("Loop returns activated"),document.dispatchEvent(new Event("Loop:Activated"))}(null==t?void 0:t.attach)&&R(t.attach),(null==t?void 0:t.full)&&s("fullPayload",null==t?void 0:t.full)},T=(t=!0)=>{s("debug",!0),s("testMode",!0),l.info("Test mode activated"),s("redirect",t),window.location="".concat(window.location.origin).concat(window.location.pathname,"?loop_domain=example.loopreturns.com&loop_return_id=this-is-a-test&loop_currency=USD&loop_total=12099&loop_discount_percentage=25&loop_base=799&loop_credit=500&loop_subdomain=example&loop_redirect_url=example.loopreturns.com%2F%23%2Fcredit&loop_customer_name=Jane%20Doe")},A=()=>{const t=!a("debug");return s("debug",t),"Debug ".concat(t?"on":"off")},M=t=>{if(!t||"string"!=typeof t)return console.error("Your api key is either undefined or not a string.");s("key",t),l.info("Loop Returns on-store API key set.")},D=async t=>{let n=null;t||(l.info("Requesting updated cart from Shopify"),n=await b("/cart.js"),t=n.items.reduce((t,n)=>[...t,...Array(n.quantity).fill(n.variant_id)],[]));try{var e;if(window.stackableService&&"function"==typeof(null===(e=window.stackableService)||void 0===e?void 0:e.send)){window.stackableService.send({type:"checkout",data:{preventRedirect:!0}});let t=0;await(async()=>await new Promise(n=>{const e=setInterval(()=>{(window.stackableService.state.context.draftOrderId||6===t)&&(n(),clearInterval(e)),t++},500)}))(),s("draftOrderId",window.stackableService.state.context.draftOrderId)}const o=await S(t,n);return s("token",o.token),a("preserveCart")||await x(),N(o.token),Promise.resolve(o.token)}catch(t){return l.info("Unable to create Loop Returns cart:"),l.error(t),Promise.reject(t)}},R=t=>{if(a("active")){l.info('Loop attaching to: "'.concat(t,'"'));const n=async t=>{if(a("active")){t.stopImmediatePropagation(),t.preventDefault(),t.target.disabled=!0,t.target.classList.add("loop-activated");try{await D(),t.target.disabled=!1,t.target.classList.remove("loop-activated")}catch(n){t.target.disabled=!1,t.target.classList.remove("loop-activated")}}};I.attached=f(t,n),new MutationObserver(e=>{const o=((t,n)=>t.filter(t=>t[n].length).reduce((t,e)=>[...t,...e[n]],[]))(e,"addedNodes");if(o.length){o.some(n=>n&&1===n.nodeType&&(n.matches(t)||n.querySelector(t)))&&(((t,n)=>{t.forEach(t=>{t.removeEventListener("click",n)})})(I.attached,n),I.attached=f(t,n),l.info('Loop reattached to: "'.concat(t,'"')))}}).observe(document.body,{childList:!0,subtree:!0})}},N=t=>{const n=a("testMode");s("active",!1);const e=a("params");let o="http://".concat(e.loop_redirect_url);if(t&&e.loop_return_key?o="http://".concat(e.loop_domain,"/#/cart/v2/").concat(t,"/").concat(e.loop_return_key):t&&(o="http://".concat(e.loop_domain,"/#/cart/v2/").concat(t)),s("params",null),l.info("Redirecting to:"),l.info(o),document.dispatchEvent(new Event("Loop:Back To Loop")),n)return(()=>{document.body.style.overflow="hidden";const t=document.createElement("div");t.classList.add("loop-returns-modal"),t.innerHTML='\n <div class="loop-returns-modal">\n <div class="loop-returns-modal__backdrop"></div>\n <div class="loop-returns-modal__content">\n <div class="loop-returns-modal__header">\n <div class="loop-returns-modal__text">Loop Onstore Installed</div>\n <div class="loop-returns-modal__close">\n <svg class="loop-returns-modal__close--icon width="15" height="15" viewBox="0 0 15 15" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path\n d="M0 7.50024C0 3.36474 3.3645 0.000244141 7.5 0.000244141C11.6355 0.000244141 15 3.36474 15 7.50024C15 11.6357 11.6355 15.0002 7.5 15.0002C3.3645 15.0002 0 11.6357 0 7.50024ZM5.78025 4.71999C5.6388 4.58338 5.44935 4.50778 5.2527 4.50949C5.05605 4.5112 4.86794 4.59007 4.72889 4.72913C4.58983 4.86819 4.51095 5.0563 4.50924 5.25294C4.50754 5.44959 4.58313 5.63904 4.71975 5.78049L6.4395 7.50024L4.71975 9.21999C4.64812 9.28918 4.59098 9.37194 4.55167 9.46344C4.51237 9.55494 4.49168 9.65336 4.49081 9.75294C4.48995 9.85253 4.50892 9.95129 4.54663 10.0435C4.58434 10.1356 4.64003 10.2194 4.71045 10.2898C4.78087 10.3602 4.86461 10.4159 4.95678 10.4536C5.04896 10.4913 5.14772 10.5103 5.2473 10.5094C5.34689 10.5086 5.4453 10.4879 5.5368 10.4486C5.62831 10.4093 5.71106 10.3521 5.78025 10.2805L7.5 8.56074L9.21975 10.2805C9.3612 10.4171 9.55065 10.4927 9.7473 10.491C9.94395 10.4893 10.1321 10.4104 10.2711 10.2714C10.4102 10.1323 10.489 9.94419 10.4908 9.74754C10.4925 9.5509 10.4169 9.36145 10.2802 9.21999L8.5605 7.50024L10.2802 5.78049C10.4169 5.63904 10.4925 5.44959 10.4908 5.25294C10.489 5.0563 10.4102 4.86819 10.2711 4.72913C10.1321 4.59007 9.94395 4.5112 9.7473 4.50949C9.55065 4.50778 9.3612 4.58338 9.21975 4.71999L7.5 6.43974L5.78025 4.71999Z"\n fill="black" />\n </svg>\n </div>\n </div>\n <div class="loop-returns-modal__body">\n Test Mode Successful\n </div>\n </div>\n </div>\n </div>',document.body.appendChild(t);const n=document.querySelector(".loop-returns-modal__close"),e=document.querySelector(".loop-returns-modal__backdrop"),o=n=>{"Escape"===n.key&&(t.remove(),document.removeEventListener("keydown",o))};document.addEventListener("keydown",o),null==n||n.addEventListener("click",()=>{t.remove(),document.removeEventListener("keydown",o),document.body.style.overflow="auto"}),null==e||e.addEventListener("click",()=>{t.remove(),document.removeEventListener("keydown",o),document.body.style.overflow="auto"})})(),void s("testMode",!1);a("redirect")&&(window.location.href=o)},F=()=>a("active")}])}));
{
"name": "@loophq/onstore-sdk",
"private": false,
"version": "1.0.17",
"version": "1.1.0",
"description": "An SDK for integrating with loop returns on-store api",

@@ -6,0 +6,0 @@ "main": "dist/loop-onstore-sdk.js",

@@ -12,3 +12,3 @@ # Loop Onstore SDK

```
<script src="https://unpkg.com/@loophq/onstore-sdk@latest/dist/loop-onstore-sdk.js"></script>
<script src="https://cdn.jsdelivr.net/npm/@loophq/onstore-sdk@latest/dist/loop-onstore-sdk.min.js"></script>
<script>

@@ -250,3 +250,3 @@ LoopOnstore.init();

0. If this is your first time releasing, ask in the engineering team channel to be added to the loop npm organization. Make sure you log in to npm in your terminal as well.
1. On your machine, check out the branch you'd like to release. This can either be a feature branch or a release branch if you have multiple features to package together as a release. This branch should be PRed into `master` and be approved by a peer before releasing.
1. On your machine, check out the branch you'd like to release. This can either be a feature branch or a release branch if you have multiple features to package together as a release. This branch should be PRed into `main` and be approved by a peer before releasing.
2. Compile the sdk

@@ -253,0 +253,0 @@ ```

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc