(function(e){function t(t){for(var r,s,o=t[0],c=t[1],l=t[2],d=0,p=[];d<o.length;d++)s=o[d],Object.prototype.hasOwnProperty.call(i,s)&&i[s]&&p.push(i[s][0]),i[s]=0;for(r in c)Object.prototype.hasOwnProperty.call(c,r)&&(e[r]=c[r]);u&&u(t);while(p.length)p.shift()();return n.push.apply(n,l||[]),a()}function a(){for(var e,t=0;t<n.length;t++){for(var a=n[t],r=!0,o=1;o<a.length;o++){var c=a[o];0!==i[c]&&(r=!1)}r&&(n.splice(t--,1),e=s(s.s=a[0]))}return e}var r={},i={app:0},n=[];function s(t){if(r[t])return r[t].exports;var a=r[t]={i:t,l:!1,exports:{}};return e[t].call(a.exports,a,a.exports,s),a.l=!0,a.exports}s.m=e,s.c=r,s.d=function(e,t,a){s.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:a})},s.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},s.t=function(e,t){if(1&t&&(e=s(e)),8&t)return e;if(4&t&&"object"===typeof e&&e&&e.__esModule)return e;var a=Object.create(null);if(s.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)s.d(a,r,function(t){return e[t]}.bind(null,r));return a},s.n=function(e){var t=e&&e.__esModule?function(){return e["default"]}:function(){return e};return s.d(t,"a",t),t},s.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},s.p="/";var o=window["webpackJsonp"]=window["webpackJsonp"]||[],c=o.push.bind(o);o.push=t,o=o.slice();for(var l=0;l<o.length;l++)t(o[l]);var u=c;n.push([0,"chunk-vendors"]),a()})({0:function(e,t,a){e.exports=a("56d7")},"29d8":function(e,t,a){},"56d7":function(e,t,a){"use strict";a.r(t);a("cadf"),a("551c"),a("f751"),a("097d");var r=a("2b0e"),i=a("a925"),n=a("a306"),s=a("5d67"),o=a("edd4"),c={es:n,pt:s,en:o},l=function(){var e=this,t=e._self._c;return t("div",[t("RouterView")],1)},u=[],d=a("2877"),p={},h=Object(d["a"])(p,l,u,!1,null,null,null),m=h.exports,f=a("8c4f"),v=function(){var e=this,t=e._self._c;return t("div",{staticClass:"unsubscribe"},[t("h1",[t("span",{directives:[{name:"t",rawName:"v-t",value:"unsubscribe.invalidParams",expression:"'unsubscribe.invalidParams'"}]})])])},g=[],b={},w=Object(d["a"])(b,v,g,!1,null,null,null),_=w.exports,C=function(){var e=this,t=e._self._c;return t("div",{staticClass:"optinconfirmed"},[e.hasValidLogo?t("img",{staticClass:"logo",attrs:{src:e.logo,alt:"Logo"}}):e._e(),t("h1",[t("span",{directives:[{name:"t",rawName:"v-t",value:"optinconfirmed.title",expression:"'optinconfirmed.title'"}]})]),t("p",{staticClass:"text-soft"},[e._v("\n    "+e._s(e.$t("optinconfirmed.legend"))+"\n  ")]),t("div",{staticClass:"buttons btn-confirmed"},[e.url?t("a",{directives:[{name:"t",rawName:"v-t",value:"optinconfirmed.action",expression:"'optinconfirmed.action'"}],staticClass:"btn primary",attrs:{href:e.url}}):e._e()])])},y=[],k=window.navigator.userLanguage||window.navigator.language,x=k.substr(0,2);c[x]||(x="en");var V={env:"production",apiRoot:Object({NODE_ENV:"production",VUE_APP_ACCOUNT_LOGOS_ROOT:"https://s3.amazonaws.com/perfit-resources/account-logos",VUE_APP_MODE:"production",BASE_URL:"/"}).VUE_APP_API_ROOT,accountLogosRoot:"https://s3.amazonaws.com/perfit-resources/account-logos",appMode:"production",lang:x},P={data:function(){return{hasValidLogo:!1}},computed:{logo:function(){return"".concat(V.accountLogosRoot,"/").concat(this.account,".png")}},methods:{preloadLogo:function(){var e=this,t=new Image;t.onload=function(){e.hasValidLogo=!0},t.onerror=function(){e.hasValidLogo=!1},t.src="".concat(V.accountLogosRoot,"/").concat(this.account,".png")}}},H={mixins:[P],data:function(){return{url:null,account:null}},created:function(){document.title=this.$t("optinconfirmed.pageTitle"),this.account=this.$route.query.account,this.account&&this.preloadLogo();try{new URL(this.$route.query.url),this.url=this.$route.query.url}catch(e){this.url=null}}},L=H,O=Object(d["a"])(L,C,y,!1,null,null,null),j=O.exports,T=(a("7f7f"),function(){var e=this,t=e._self._c;return t("div",{staticClass:"giftcard text-center"},[e.encoded&&e.responseValid?e._e():t("div",[t("h3",[e._v(e._s(e.$t("giftcardLanding.invalidParams")))])]),e.responseValid?t("div",[t("h1",[e._v(e._s(e.$t("giftcardLanding.title")))]),t("p",{staticClass:"description"},[e._v("\n      "+e._s(e.$t("giftcardLanding.subtitle.intro"))+"\n      "),t("span",{staticClass:"font-bold"},[e._v(" $"+e._s(e.giftcard.value)+" ")]),e._v("\n      "+e._s(e.$t("giftcardLanding.subtitle.finish"))+"\n    ")]),t("p",{staticClass:"discount mb-2"},[e._v("\n      "+e._s(e.$t("giftcardLanding.subtitle.discount"))+"\n    ")]),t("div",{ref:"capture",staticClass:"w-full flex-container"},[t("p",{staticClass:"coupon absolute position-code",style:{color:e.giftcard.color}},[e._v("\n        "+e._s(e.giftcard.code)+"\n      ")]),e.giftcard.logo?t("img",{staticClass:"absolute logo-giftcard",attrs:{src:e.giftcard.logo}}):e._e(),t("p",{staticClass:"absolute position-value coupon"},[t("span",{style:{color:e.giftcard.color}},[e._v("\n          $ "+e._s(e.giftcard.value)+"\n        ")])]),e.giftcard.endDate?t("p",{staticClass:"absolute position-enddate coupon"},[e._v("\n        "+e._s(e.$t("giftcardLanding.subtitle.expiration"))+"\n        "),t("span",{staticClass:"font-bold",style:{color:e.giftcard.color}},[e._v("\n          "+e._s(e.giftcard.endDate)+"\n        ")])]):e._e(),t("svg",{attrs:{width:"500",height:"286",viewBox:"0 0 500 286",fill:"none",xmlns:"http://www.w3.org/2000/svg"}},[t("path",{style:{fill:e.giftcard.bg},attrs:{d:"M457.048 0H42.9516C19.2301 0 0 19.2301 0 42.9516V242.114C0 265.836 19.2301 285.066 42.9516 285.066H457.048C480.77 285.066 500 265.836 500 242.114V42.9516C500 19.2301 480.77 0 457.048 0Z"}}),t("path",{attrs:{d:"M499.748 191.221H0.252274V216.448H499.748V191.221Z",fill:"#59646A"}}),t("path",{attrs:{d:"M499.748 216.448H0.252274V241.675H499.748V216.448Z",fill:"#4E595F"}}),t("path",{attrs:{d:"M187.967 214.99H195.863V228.239C193.623 229.193 191.246 229.672 188.724 229.672C185.721 229.672 183.411 228.532 181.791 226.246C180.172 223.961 179.364 220.671 179.364 216.372C179.364 212.074 180.293 208.981 182.144 206.64C184.001 204.299 186.594 203.123 189.929 203.123C191.993 203.123 193.956 203.653 195.833 204.712L194.314 208.633C192.856 207.785 191.488 207.361 190.217 207.361C188.391 207.361 186.948 208.179 185.878 209.808C184.813 211.438 184.279 213.663 184.279 216.478C184.279 219.294 184.662 221.594 185.434 223.138C186.206 224.682 187.326 225.454 188.799 225.454C189.576 225.454 190.363 225.353 191.166 225.151V219.233H187.967V214.995V214.99Z",fill:"white"}}),t("path",{attrs:{d:"M200.671 229.319V203.486H205.192V229.319H200.671Z",fill:"white"}}),t("path",{attrs:{d:"M215.424 229.319H210.656V203.486H222.23V207.639H215.429V214.813H221.771V218.966H215.429V229.319H215.424Z",fill:"white"}}),t("path",{attrs:{d:"M233.391 229.319H228.602V207.709H223.653V203.486H238.335V207.709H233.391V229.319Z",fill:"white"}}),t("path",{attrs:{d:"M258.602 207.321C257.225 207.321 256.135 208.128 255.343 209.743C254.546 211.357 254.152 213.602 254.152 216.473C254.152 222.457 255.711 225.449 258.835 225.449C260.202 225.449 261.63 225.015 263.128 224.142V228.416C261.867 229.253 260.252 229.672 258.29 229.672C255.378 229.672 253.143 228.517 251.584 226.201C250.025 223.885 249.243 220.631 249.243 216.438C249.243 212.245 250.045 208.976 251.655 206.635C253.264 204.294 255.5 203.118 258.36 203.118C259.304 203.118 260.207 203.249 261.075 203.507C261.942 203.764 262.866 204.218 263.855 204.869L262.265 208.774C261.736 208.411 261.171 208.078 260.57 207.775C259.97 207.472 259.314 207.326 258.607 207.326L258.602 207.321Z",fill:"white"}}),t("path",{attrs:{d:"M279.011 229.319L277.528 222.8H270.797L269.314 229.319H264.506L270.903 203.38H277.422L283.835 229.319H279.011ZM276.625 218.542L275.247 212.533C275.166 212.17 274.98 211.251 274.692 209.783C274.405 208.315 274.228 207.336 274.173 206.842C274.021 207.856 273.824 208.971 273.587 210.192C273.35 211.413 272.74 214.193 271.751 218.542H276.625Z",fill:"white"}}),t("path",{attrs:{d:"M290.918 219.263V229.319H286.11V203.486H292.402C295.061 203.486 297.028 204.117 298.295 205.378C299.561 206.64 300.192 208.562 300.192 211.155C300.192 214.42 299.092 216.695 296.887 217.992L301.852 229.319H296.71L292.629 219.263H290.913H290.918ZM290.918 215.131H292.154C293.285 215.131 294.097 214.808 294.591 214.167C295.086 213.527 295.333 212.568 295.333 211.297C295.333 210.025 295.071 209.036 294.546 208.476C294.021 207.916 293.214 207.639 292.119 207.639H290.918V215.131Z",fill:"white"}}),t("path",{attrs:{d:"M320.636 216.155C320.636 220.419 319.768 223.678 318.027 225.933C316.292 228.189 313.789 229.319 310.53 229.319H304.203V203.486H311.11C314.112 203.486 316.453 204.596 318.123 206.816C319.793 209.036 320.631 212.149 320.631 216.155H320.636ZM315.706 216.297C315.706 210.525 314.117 207.639 310.938 207.639H309.011V225.111H310.565C312.321 225.111 313.618 224.379 314.45 222.911C315.288 221.443 315.706 219.238 315.706 216.297Z",fill:"white"}}),t("mask",{staticStyle:{"mask-type":"luminance"},attrs:{id:"mask0_1_116",maskUnits:"userSpaceOnUse",x:"179",y:"216",width:"142",height:"15"}},[t("path",{attrs:{d:"M320.636 216.448H179.364V230.575H320.636V216.448Z",fill:"white"}})]),t("g",{attrs:{mask:"url(#mask0_1_116)"}},[t("g",{attrs:{opacity:"0.1"}},[t("path",{attrs:{d:"M187.967 214.99H195.863V228.239C193.623 229.193 191.246 229.672 188.724 229.672C185.721 229.672 183.411 228.532 181.791 226.246C180.172 223.961 179.364 220.671 179.364 216.372C179.364 212.074 180.293 208.981 182.144 206.64C184.001 204.299 186.594 203.123 189.929 203.123C191.993 203.123 193.956 203.653 195.833 204.712L194.314 208.633C192.856 207.785 191.488 207.361 190.217 207.361C188.391 207.361 186.948 208.179 185.878 209.808C184.813 211.438 184.279 213.663 184.279 216.478C184.279 219.294 184.662 221.594 185.434 223.138C186.206 224.682 187.326 225.454 188.799 225.454C189.576 225.454 190.363 225.353 191.166 225.151V219.233H187.967V214.995V214.99Z",fill:"black"}}),t("path",{attrs:{d:"M200.671 229.319V203.486H205.192V229.319H200.671Z",fill:"black"}}),t("path",{attrs:{d:"M215.424 229.319H210.656V203.486H222.23V207.639H215.429V214.813H221.771V218.966H215.429V229.319H215.424Z",fill:"black"}}),t("path",{attrs:{d:"M233.391 229.319H228.602V207.709H223.653V203.486H238.335V207.709H233.391V229.319Z",fill:"black"}}),t("path",{attrs:{d:"M258.602 207.321C257.225 207.321 256.135 208.128 255.343 209.743C254.546 211.357 254.152 213.602 254.152 216.473C254.152 222.457 255.711 225.449 258.835 225.449C260.202 225.449 261.63 225.015 263.128 224.142V228.416C261.867 229.253 260.252 229.672 258.29 229.672C255.378 229.672 253.143 228.517 251.584 226.201C250.025 223.885 249.243 220.631 249.243 216.438C249.243 212.245 250.045 208.976 251.655 206.635C253.264 204.294 255.5 203.118 258.36 203.118C259.304 203.118 260.207 203.249 261.075 203.507C261.942 203.764 262.866 204.218 263.855 204.869L262.265 208.774C261.736 208.411 261.171 208.078 260.57 207.775C259.97 207.472 259.314 207.326 258.607 207.326L258.602 207.321Z",fill:"black"}}),t("path",{attrs:{d:"M279.011 229.319L277.528 222.8H270.797L269.314 229.319H264.506L270.903 203.38H277.422L283.835 229.319H279.011ZM276.625 218.542L275.247 212.533C275.166 212.17 274.98 211.251 274.692 209.783C274.405 208.315 274.228 207.336 274.173 206.842C274.021 207.856 273.824 208.971 273.587 210.192C273.35 211.413 272.74 214.193 271.751 218.542H276.625Z",fill:"black"}}),t("path",{attrs:{d:"M290.918 219.263V229.319H286.11V203.486H292.402C295.061 203.486 297.028 204.117 298.295 205.378C299.561 206.64 300.192 208.562 300.192 211.155C300.192 214.42 299.092 216.695 296.887 217.992L301.852 229.319H296.71L292.629 219.263H290.913H290.918ZM290.918 215.131H292.154C293.285 215.131 294.097 214.808 294.591 214.167C295.086 213.527 295.333 212.568 295.333 211.297C295.333 210.025 295.071 209.036 294.546 208.476C294.021 207.916 293.214 207.639 292.119 207.639H290.918V215.131Z",fill:"black"}}),t("path",{attrs:{d:"M320.636 216.155C320.636 220.419 319.768 223.678 318.027 225.933C316.292 228.189 313.789 229.319 310.53 229.319H304.203V203.486H311.11C314.112 203.486 316.453 204.596 318.123 206.816C319.793 209.036 320.631 212.149 320.631 216.155H320.636ZM315.706 216.297C315.706 210.525 314.117 207.639 310.938 207.639H309.011V225.111H310.565C312.321 225.111 313.618 224.379 314.45 222.911C315.288 221.443 315.706 219.238 315.706 216.297Z",fill:"black"}})])])])]),t("div",{staticClass:"url"},[t("a",{staticClass:"btn primary",attrs:{target:"_blank",href:e.giftcard.url}},[e._v("\n        "+e._s(e.$t("giftcardLanding.button"))+"\n      ")])])]):e._e(),e.responseValid?t("hr"):e._e(),e.responseValid?t("div",[t("div",{staticClass:"share"},[t("p",[e._v("\n        "+e._s(e.$t("giftcardLanding.share.title"))+"\n      ")]),t("div",{staticClass:"buttons"},e._l(e.shareApps,(function(a){return t("button",{key:a.id,style:[{backgroundColor:a.color},a.style],on:{click:function(t){return e.share(a)}}},[e._v("\n          "+e._s(a.name)+"\n        ")])})),0)])]):e._e()])}),A=[],M=(a("f576"),a("6b54"),a("a481"),a("96cf"),a("3b8d")),S=a("6821f"),$=a.n(S),N={data:function(){return{encoded:"",responseValid:null,giftcard:{bg:null,color:null,code:null,endDate:null,logo:null,security:null,value:null,url:null},shareApps:[{id:"whatsapp",name:this.$t("giftcardLanding.share.links.whatsapp.title"),href:"".concat(this.$t("giftcardLanding.share.links.whatsapp.href"),"%0A").concat(window.location.href),color:"#32D16B"},{id:"email",name:this.$t("giftcardLanding.share.links.email.title"),href:"".concat(this.$t("giftcardLanding.share.links.email.href"),"%0A").concat(window.location.href),color:"#e83d80"}]}},computed:{apps:function(){return this.shareApps.filter((function(e){return"native"!==e.id||navigator.share}))}},created:function(){var e=Object(M["a"])(regeneratorRuntime.mark((function e(){var t;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return document.title=this.$t("giftcardLanding.pageTitle"),this.isMobile=this.checkIsMobile(),this.isMobile&&(t={id:"native",name:this.$t("giftcardLanding.share.links.native.title"),color:"#FFFFFF",style:{border:"2px solid #1CAEEA",color:"#1CAEEA"}},this.shareApps.push(t)),this.getEncoded(),e.next=6,this.getData();case 6:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}(),methods:{getEncoded:function(){return this.encoded=this.$route.params.encoded,!!this.encoded},checkIsMobile:function(){var e=navigator.userAgent||navigator.vendor||window.opera;this.isMobile=/android|iphone|ipad|ipod|opera mini|iemobile|wpdesktop/i.test(e)},getData:function(){var e=Object(M["a"])(regeneratorRuntime.mark((function e(){var t,a;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(this.encoded){e.next=2;break}return e.abrupt("return",!1);case 2:if(e.prev=2,t=atob(this.encoded),a=JSON.parse(t),this.giftcard.bg=a.landingBg,this.giftcard.code=a.code,this.giftcard.color=a.landingColor,this.giftcard.endDate=a.endDate,this.giftcard.logo=a.landingLogo,this.giftcard.security=a.security,this.giftcard.value=a.value,this.giftcard.url=a.urlStore,this.isSecure()){e.next=16;break}return this.responseValid=!1,e.abrupt("return",!1);case 16:this.giftcard.value=this.formatNumber(a.value),this.giftcard.endDate&&(this.giftcard.endDate=this.formatDate(this.giftcard.endDate)),this.responseValid=!0,e.next=24;break;case 21:e.prev=21,e.t0=e["catch"](2),this.responseValid=!1;case 24:return e.abrupt("return",!0);case 25:case"end":return e.stop()}}),e,this,[[2,21]])})));function t(){return e.apply(this,arguments)}return t}(),formatNumber:function(e){return e.toString().replace(/\B(?=(\d{3})+(?!\d))/g,".")},formatDate:function(e){var t=new Date(e),a=String(t.getDate()).padStart(2,"0"),r=String(t.getMonth()+1).padStart(2,"0"),i=t.getFullYear();return"".concat(a,"/").concat(r,"/").concat(i)},isSecure:function(){var e=this.giftcard.value+this.giftcard.code+this.giftcard.url,t=$()(e),a=t.slice(-6);return a===this.giftcard.security},share:function(){var e=Object(M["a"])(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if("native"!==t.id||!this.isMobile){e.next=2;break}return e.abrupt("return",navigator.share({title:t.name,url:window.location.href}));case 2:return e.abrupt("return",window.open(t.href,"_blank"));case 3:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()}},q=N,E=Object(d["a"])(q,T,A,!1,null,null,null),D=E.exports,U=function(){var e=this,t=e._self._c;return t("div",{staticClass:"unsubscribe"},[e.hasValidLogo?t("img",{staticClass:"logo",attrs:{src:e.logo,alt:"Logo"}}):e._e(),e.hasValidParams?[e.submitted?t("div",[e.error?t("h1",[t("span",{directives:[{name:"t",rawName:"v-t",value:"unsubscribe.error",expression:"'unsubscribe.error'"}]})]):t("h1",[t("span",{directives:[{name:"t",rawName:"v-t",value:"unsubscribe.success",expression:"'unsubscribe.success'"}]}),t("span",[e._v(" "+e._s(e.accountName))]),e._v(".\n      ")])]):t("form",{on:{submit:function(t){return t.preventDefault(),e.submit.apply(null,arguments)}}},[t("div",[t("h1",[t("span",{directives:[{name:"t",rawName:"v-t",value:"unsubscribe.title",expression:"'unsubscribe.title'"}]}),t("span",[e._v(" "+e._s(e.accountName))]),e._v(".\n        ")]),t("p",[t("span",{directives:[{name:"t",rawName:"v-t",value:"unsubscribe.question",expression:"'unsubscribe.question'"}]}),t("span",{staticClass:"font-bold"},[e._v(" "+e._s(e.email))]),e._v("?\n        ")]),t("p",{directives:[{name:"t",rawName:"v-t",value:"unsubscribe.warning",expression:"'unsubscribe.warning'"}],staticClass:"text-soft"})]),t("div",[t("h2",{directives:[{name:"t",rawName:"v-t",value:"unsubscribe.reason",expression:"'unsubscribe.reason'"}]}),e._l(e.$options.reasons,(function(a){return t("div",{key:a},[t("label",[t("input",{directives:[{name:"model",rawName:"v-model",value:e.reason_code,expression:"reason_code"}],attrs:{type:"radio",name:"reason"},domProps:{value:a,checked:e._q(e.reason_code,a)},on:{change:function(t){e.reason_code=a}}}),t("span",[e._v("\n              "+e._s(e.$t("unsubscribe.".concat(a)))+"\n            ")])])])})),t("button",{directives:[{name:"t",rawName:"v-t",value:"unsubscribe.action",expression:"'unsubscribe.action'"}],staticClass:"btn primary",attrs:{disabled:!e.reason_code}})],2)])]:[t("h1",[t("span",{directives:[{name:"t",rawName:"v-t",value:"unsubscribe.invalidParams",expression:"'unsubscribe.invalidParams'"}]})])]],2)},R=[],Z=a("bc3a"),z=a.n(Z),B=a("27ae"),I=function(e){var t;try{t=JSON.parse(B["Base64"].decode(e))}catch(a){return!1}return t},F={mixins:[P],reasons:["not_interested","too_frequent","spam_never_subscribed","spam_offensive"],data:function(){return{email:null,accountName:null,account:null,apiUrl:null,reason_code:"",submitted:!1,error:!1}},computed:{hasValidParams:function(){return this.email&&this.account&&this.accountName&&this.apiUrl},packet:function(){return this.$route.query.p}},created:function(){document.title=this.$t("unsubscribe.pageTitle")},beforeMount:function(){this.parseParams(),this.preloadLogo()},methods:{parseParams:function(){var e=I(this.$route.query.d);return!!e&&(this.email=e.e,this.account=e.a,this.accountName=e.n,this.apiUrl=e.u,!0)},submit:function(){var e=this,t=this.apiUrl.replace("{packet}",this.packet);z.a.post("".concat(t,"?r=").concat(this.reason_code)).then((function(){e.submitted=!0})).catch((function(){e.submitted=!0,e.error=!0}))}}},G=F,J=Object(d["a"])(G,U,R,!1,null,null,null),W=J.exports,Y=function(){var e=this,t=e._self._c;return t("div",{staticClass:"preview"},[e.hash&&e.responseValid||e.loading?e._e():t("div",[t("h1",{staticClass:"text-strong text-center"},[e._v("\n      "+e._s(e.$t("preview.invalidParams"))+"\n    ")])]),t("div",{directives:[{name:"show",rawName:"v-show",value:e.responseValid,expression:"responseValid"}]},[t("div",{staticClass:"text-strong flex-tablet items-end"},[e.response.subjects?t("div",{staticClass:"mr-1 flex items-center subjectContainer"},[t("svg",{staticClass:"mr-0-5",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor","aria-hidden":"true"}},[t("path",{attrs:{"stroke-linecap":"round","stroke-linejoin":"round",d:"M19.428 15.428a2 2 0 00-1.022-.547l-2.387-.477a6 6 0 00-3.86.517l-.318.158a6 6 0 01-3.86.517L6.05 15.21a2 2 0 00-1.806.547M8 4h8l-1 1v5.172a2 2 0 00.586 1.414l5 5c1.26 1.26.367 3.414-1.415 3.414H4.828c-1.782 0-2.674-2.154-1.414-3.414l5-5A2 2 0 009 10.172V5L8 4z"}})]),t("p",{staticClass:"font-semibold subjectTitle"},[e._v("\n          "+e._s(e.$t("preview.testABTitle"))+"\n        ")]),t("div",{staticClass:"subjectBox"},e._l(e.response.subjects,(function(a){return t("p",{key:a},[e._v("\n            "+e._s(a)+"\n          ")])})),0)]):e._e(),e.response.subject?t("p",{staticClass:"font-semibold mr-1"},[e._v("\n        "+e._s(e.response.subject)+"\n      ")]):e._e(),t("p",[e._v(" "+e._s(e.response.preheader)+" ")])]),t("div",{staticClass:"flex-tablet mt-0-5"},[e.response.sender.name||e.response.sender.email?t("p",{staticClass:"text-strong mr-1"},[t("span",{staticClass:"font-semibold"},[e._v(e._s(e.$t("preview.from"))+": ")]),e._v("\n        "+e._s(e.response.sender.name)+" <\n        "+e._s(e.response.sender.email)+" >\n      ")]):e._e(),e.response.sender.reply_to?t("p",{staticClass:"text-strong"},[t("span",{staticClass:"font-semibold"},[e._v(e._s(e.$t("preview.to"))+": ")]),e._v("\n        "+e._s(e.response.sender.reply_to)+"\n      ")]):e._e()]),"generic"!=e.response.preview_as?t("div",{staticClass:"mt-0-5 notification-box"},[t("svg",{staticClass:"mr-0-5",attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor"}},[t("path",{attrs:{"fill-rule":"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a1\n          1 0 000 2v3a1 1 0 001 1h1a1 1 0 100-2v-3a1 1 0 00-1-1H9z","clip-rule":"evenodd"}})]),t("span",{staticClass:"mr-0-5"},[e._v(e._s(e.$t("preview.as"))+" ")]),e._v("\n      "+e._s(e.response.preview_as)+"\n    ")]):e._e(),t("iframe",{ref:"iframe",staticClass:"mt-0-5",class:"generic"==e.response.preview_as&&"iframe-border",staticStyle:{height:"100vh"},attrs:{scrolling:"no",frameBorder:"0"}})])])},Q=[],K=(a("8e6e"),a("ac6a"),a("456d"),a("bd86"));a("6762"),a("2fdb");function X(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function ee(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?X(Object(a),!0).forEach((function(t){Object(K["a"])(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):X(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var te={data:function(){return{apiUrl:null,hash:"",loading:!1,response:{sender:{name:"",email:""}},responseValid:null,selectValue:""}},created:function(){var e=this;this.loading=!0,document.title=this.$t("preview.pageTitle"),document.querySelector("body").style="width: 100%;",this.getParams(),window.addEventListener("resize",this.debounce((function(){e.refreshHeight()}),500),!0)},mounted:function(){this.getTemplate(),window.removeEventListener("resize",(function(){}),{capture:!0})},methods:{debounce:function(e,t){var a;return function(){for(var r=arguments.length,i=new Array(r),n=0;n<r;n++)i[n]=arguments[n];clearTimeout(a),a=setTimeout((function(){e.apply(void 0,i)}),t)}},getParams:function(){var e=this.$route.params.hash;return!!e&&(this.hash=e,this.apiUrl=this.hasPreviewLink()?"https://thumbs-prod.s3.us-east-1.amazonaws.com/linkpreviews/".concat(this.hash,".json"):"https://d9p51ruvsfm1m.cloudfront.net/templates/preview/share/".concat(this.hash),!0)},refreshHeight:function(){var e=this.$refs.iframe;Object(r["b"])((function(){e.contentWindow&&(e.style.height="".concat(e.contentWindow.document.body.offsetHeight,"px"))}))},hasPreviewLink:function(){var e=this.$route.path,t="preview/link";return!!e.includes(t)},getTemplate:function(){var e=this;z.a.get(this.apiUrl).then((function(t){e.responseValid=!0;var a=e.$refs.iframe;if(a){a.contentDocument.open();var r=e.hasPreviewLink()?t.data.html:t.data.data.html;a.contentDocument.write(r),a.contentDocument.close(),setInterval((function(){e.refreshHeight()}),1e3),e.response=ee(ee({},e.hasPreviewLink()?t.data:t.data.data),{},{sender:!e.hasPreviewLink()&&t.data.data.sender?t.data.data.sender:e.response.sender}),e.loading=!1}})).catch((function(){e.responseValid=!1,e.loading=!1}))}}},ae=te,re=Object(d["a"])(ae,Y,Q,!1,null,null,null),ie=re.exports,ne=function(){var e=this,t=e._self._c;return e.redirects?e._e():t("div",{staticClass:"share"},[e.hasValidLogo?t("img",{staticClass:"logo",attrs:{src:e.logo,alt:"Logo"}}):e._e(),e.hasValidParams?e.submitted&&e.error?[t("h1",[t("span",{directives:[{name:"t",rawName:"v-t",value:"share.error",expression:"'share.error'"}]})])]:[t("h1",[t("span",{directives:[{name:"t",rawName:"v-t",value:"share.title",expression:"'share.title'"}]}),t("span",[e._v(" "+e._s(e.accountName))]),e._v(".\n    ")]),t("p",{directives:[{name:"t",rawName:"v-t",value:"share.legend",expression:"'share.legend'"}],staticClass:"text-soft"}),t("div",{staticClass:"buttons"},e._l(e.apps,(function(a){return t("button",{key:a.id,style:[{backgroundColor:a.color},a.style],on:{click:function(t){return e.share(a)}}},[e._v("\n        "+e._s(a.name)+"\n      ")])})),0),t("p",{staticClass:"text-soft"},[e._v("\n      "+e._s(e.$t("share.copyPaste"))+"\n      "),t("a",{directives:[{name:"t",rawName:"v-t",value:"share.thisLink",expression:"'share.thisLink'"}],attrs:{href:e.url}}),e._v(".\n    ")])]:[t("h1",[t("span",{directives:[{name:"t",rawName:"v-t",value:"share.invalidParams",expression:"'share.invalidParams'"}]})])]],2)},se=[],oe=(a("b54a"),a("7514"),[{id:"whatsapp",name:"WhatsApp",link:"https://api.whatsapp.com/send?text=",hasTextParam:!0,color:"#32D16B"},{id:"facebook",name:"Facebook",link:"https://www.facebook.com/sharer/sharer.php?u=",hasTextParam:!1,color:"#3b5998"},{id:"twitter",name:"Twitter",link:"https://twitter.com/intent/tweet?text=",hasTextParam:!0,color:"#1CAEEA"},{id:"linkedin",name:"LinkedIn",link:"https://www.linkedin.com/shareArticle?url=",hasTextParam:!1,color:"#1877A7"},{id:"native",name:"Elegir otra app",hasTextParam:!1,color:"#FFFFFF",style:{border:"1px solid #1CAEEA",color:"#1CAEEA"}}]),ce={mixins:[P],data:function(){return{error:null,submitted:!1,account:null,accountName:null,url:null,text:null,apiUrl:null,redirects:!0,nativeShare:!1}},computed:{hasValidParams:function(){return this.account&&this.accountName&&this.url&&this.apiUrl},packet:function(){return this.$route.query.p},apps:function(){return oe.filter((function(e){return"native"!==e.id||navigator.share}))}},created:function(){document.title=this.$t("share.pageTitle"),this.parseParams();var e=this.$route.query.s;e?this.share(this.apps.find((function(t){return t.id===e}))):(this.redirects=!1,this.nativeShare=navigator.share,this.preloadLogo())},methods:{parseParams:function(){var e=I(this.$route.query.d);return!!e&&(this.account=e.a,this.accountName=e.n,this.url=e.s,this.text=e.t,this.apiUrl=e.u,!0)},share:function(){var e=Object(M["a"])(regeneratorRuntime.mark((function e(t){var a,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(a=this.apiUrl.replace("{packet}",this.packet).replace("{app}",t.id),this.submitted=!0,"native"!==t.id){e.next=4;break}return e.abrupt("return",navigator.share({title:this.text,url:this.url}));case 4:return e.prev=4,e.next=7,z.a.post(a);case 7:r=this.shareable(t),window.location.href=r,e.next=14;break;case 11:e.prev=11,e.t0=e["catch"](4),this.error=!0;case 14:return e.abrupt("return",!0);case 15:case"end":return e.stop()}}),e,this,[[4,11]])})));function t(t){return e.apply(this,arguments)}return t}(),shareable:function(e){return e.hasTextParam?[e.link,[this.text,this.url].join(" ")].join(""):[e.link,this.url].join("")}}},le=ce,ue=Object(d["a"])(le,ne,se,!1,null,null,null),de=ue.exports,pe=function(){var e=this,t=e._self._c;return t("div")},he=[],me={mounted:function(){window.location.href=this.$t("footerAd.redirectUrl")+this.$route.query.a}},fe=me,ve=Object(d["a"])(fe,pe,he,!1,null,null,null),ge=ve.exports;r["a"].use(f["a"]);var be=new f["a"]({mode:"history",base:"/",routes:[{path:"/preview",name:"preview",component:ie,children:[{path:"/preview/:hash",name:"previewHash"},{path:"/preview/link/:hash",name:"previewLinkHash"}]},{path:"/share",name:"share",component:de},{path:"/unsubscribe",name:"unsubscribe",component:W},{path:"/optin/confirmed",name:"optin-confirmed",component:j},{path:"/giftcard/:encoded",name:"giftcard",component:D},{path:"/footerad",name:"footerad",component:ge},{path:"/404",component:_},{path:"*",redirect:"/404"}]}),we=a("2f62");r["a"].use(we["a"]);var _e=new we["a"].Store({state:{},mutations:{},actions:{}});a("29d8");r["a"].use(i["a"]),r["a"].config.productionTip=!1;var Ce=new i["a"]({locale:V.lang,messages:c});r["a"].config.productionTip=!1,new r["a"]({router:be,store:_e,i18n:Ce,render:function(e){return e(m)}}).$mount("#app")},"5d67":function(e){e.exports=JSON.parse('{"unsubscribe":{"pageTitle":"Descadastrar","title":"Se você se descadastrar, não receberá mais emails de","question":"Este é o endereço do seu email ","warning":"Se não estiver certo, por favor, não realize nenhuma ação aqui.","reason":"Por que você quer se descadastrar?","not_interested":"😴 Perdi o interesse nestes envios.","too_frequent":"😣 Recebo estes emails com muita frequência.","spam_never_subscribed":"😠 Nunca me cadastrei para receber isto.","spam_offensive":"😡 Recibi conteúdo ofensivo ou enganoso!","action":"Me descadastre","success":"Pronto! Não receberá mais emails de","error":"Ops.. parece que alguma coisa deu errado. Por favor, tente novamente mais tarde.","invalidParams":"️️O link utilizado é inválido."},"share":{"pageTitle":"Compartilhar","invalidParams":"️️O link utilizado é inválido.","title":"Compartilhar conteúdo de ","legend":"Selecione onde você quer compartilhar:","copyPaste":"Ou você pode copiar e colar","thisLink":"este link","error":"Ops.. parece que alguma coisa deu errado. Por favor, tente novamente mais tarde."},"optinconfirmed":{"action":"Visite o nosso site","pageTitle":"Assinatura bem-sucedida","title":"Muito obrigado!","legend":"Sua inscrição já foi confirmada.","error":"Ops.. parece que algo deu errado. Por favor, tente novamente mais tarde."},"preview":{"pageTitle":"Link da pré-visualização do template","invalidParams":"️️O link utilizado é inválido.","testABTitle":"Campanha de teste A/B com vários assuntos","from":"De","to":"Responder a","as":"Está vendo este email como o receberá:"},"footerAd":{"redirectUrl":"https://www.myperfit.com/pt/cresca-com-perfit?utm_source=footer_ad&utm_medium=email&utm_campaign="}}')},a306:function(e){e.exports=JSON.parse('{"unsubscribe":{"pageTitle":"Desuscribir","title":"Si te desuscribes no recibirás más correos de","question":"¿Es tu dirección de correo ","warning":"Si no es correcta, por favor no realices ninguna acción aquí.","reason":"¿Por qué quieres desuscribirte?","not_interested":"😴 Ya no me interesa recibir estos correos.","too_frequent":"😣 Recibo estos correos con demasiada frecuencia.","spam_never_subscribed":"😠 Nunca me suscribí para recibir esto.","spam_offensive":"😡 ¡Recibí contenido ofensivo o engañoso!","action":"Desuscribirme","success":"¡Listo! No recibirás más correos de","error":"Upss.. parece que algo salió mal. Por favor intenta nuevamente más tarde.","invalidParams":"️️El enlace utilizado es inválido."},"share":{"pageTitle":"Compartir","invalidParams":"️️El enlace utilizado es inválido.","title":"Compartir contenido de ","legend":"Selecciona dónde quieres compartirlo:","copyPaste":"O puedes copiar y pegar","thisLink":"este enlace","error":"Upss.. parece que algo salió mal. Por favor intenta nuevamente más tarde."},"optinconfirmed":{"action":"Visita nuestra web","pageTitle":"Suscripción con éxito","title":"¡Muchas gracias!","legend":"Tu suscripción ya fue confirmada.","error":"Upss.. parece que algo salió mal. Por favor intenta nuevamente más tarde."},"giftcardLanding":{"altImage":"Imagen Gift Card","title":"¡Sorpresa! Gift Card de regalo 🎉","subtitle":{"intro":"Disfruta de ","expiration":"Utilizala antes del","finish":"de regalo para utilizar en la tienda 🎁😊","discount":"Aplica el código que está a continuación en tu próxima compra 🎉"},"button":"COMPRAR AHORA","pageTitle":"Gift Card de regalo","share":{"title":"Quieres compartir la Gift Card?","links":{"whatsapp":{"title":"WhatsApp","href":"https://api.whatsapp.com/send?text=¡Sorpresa!%20Gift%20Card%20de%20regalo"},"email":{"title":"Email","href":"mailto:?subject=¡Sorpresa!%20Gift%20Card%20de%20regalo"},"native":{"title":"Compartir"}}},"invalidParams":"El enlace utilizado es inválido."},"preview":{"pageTitle":"Link del preview del template","invalidParams":"El enlace utilizado es inválido.","testABTitle":"Campaña Test A/B con múltiples asuntos","from":"De","to":"Responder a","as":"Estás viendo este email como lo recibirá:"},"footerAd":{"redirectUrl":"https://www.myperfit.com/es/crece-con-perfit?utm_source=footer_ad&utm_medium=email&utm_campaign="}}')},edd4:function(e){e.exports=JSON.parse('{"unsubscribe":{"pageTitle":"Unsubscribe","title":"If you unsubscribe, you will no longer receive any other emails from ","question":"Is this you email address: ","warning":"If the address is not correct, please do not complete any action here.","reason":"Why do you wish to unsubscribe?","not_interested":"😴 I am no longer interested.","too_frequent":"😣 I received these emails too often.","spam_never_subscribed":"😠 I have never subscribed to this.","spam_offensive":"😡 I received offensive or deceiving content!","action":"Unsubscribe","success":"Done! You will no longer receive emails from","error":"Oops.. it looks like something went wrong. Please try again later.","invalidParams":"️️The specified link is invalid."},"share":{"pageTitle":"Share","invalidParams":"️️The specified link is invalid.","title":"Share message from ","legend":"Select where you wish to share it:","copyPaste":"Or you can copy & paste ","thisLink":"this link","error":"Oops.. it looks like something went wrong. Please try again later."},"optinconfirmed":{"action":"Visit our website","pageTitle":"Successful subscription","title":"Thanks a lot!","legend":"Your subscription has already been confirmed","error":"D\'OH!.. Looks like something went wrong. Please try again later."},"giftcardLanding":{"altImage":"Gift Card Image","title":"Surprise! Gift Card 🎉","subtitle":{"intro":"Enjoy ","expiration":"Use it before","finish":"as a gift to use in the store 🎁😊","discount":"Apply the code below on your next purchase 🎉"},"button":"BUY NOW","pageTitle":"Gift Card","share":{"title":"Do you want to share the Gift Card?","links":{"whatsapp":{"title":"WhatsApp","href":"https://api.whatsapp.com/send?text=Surprisa!%20Gift%20Card"},"email":{"title":"Email","href":"mailto:?subject=Surprise!%20Gift%20Card"},"native":{"title":"Share"}}},"invalidParams":"The link used is invalid."},"preview":{"pageTitle":"Template preview link","invalidParams":"️️The specified link is invalid.","testABTitle":"A/B test campaign with multiple subjects","from":"From","to":"Answer to","as":"You are viewing this email how you will receive it:"},"footerAd":{"redirectUrl":"https://www.myperfit.com/es/crece-con-perfit?utm_source=footer_ad&utm_medium=email&utm_campaign="}}')}});
//# sourceMappingURL=app.c4dc46c6.js.map