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/default/js/components/Newsletterblock.vue?a4e3","webpack:///./resources/area/web/default/js/components/Newsletterblock.vue","webpack:///./resources/area/web/default/js/components/Newsletterblock.vue?b962","webpack:///./resources/area/web/default/js/components/Newsletterblock.vue?31e8"],"sourcesContent":["\nimport {Component, Vue} from 'vue-property-decorator';\nimport {ValidationProvider, ValidationObserver, extend} from 'vee-validate';\nimport {email, required} from 'vee-validate/dist/rules';\n\nextend('required', required);\nextend('email', email);\n\n@Component({\n name: 'newsletter-block',\n components: {\n ValidationProvider,\n ValidationObserver\n }\n})\n\nexport default class extends Vue {\n private email: string = '';\n private message: null | string = null;\n private success: string | boolean | null = null;\n private isLoading: boolean = false;\n\n private async doSubscribe() {\n this.isLoading = true;\n try {\n const {data} = await this.$mageClient.post(`/rest/V1/newsletter/subscribe`, {email: this.email});\n this.message = data.message;\n this.success = data.success;\n\n (window[\"rrApiOnReady\"] = window[\"rrApiOnReady\"] || []).push(() => {\n window.rrApi.setProfile({\n \"email\": this.email,\n \"isAgreedToReceiveMarketingMail\": true\n });\n });\n\n } catch (e) {\n console.error(e);\n this.message = 'newsletter-validation-error';\n } finally {\n this.isLoading = false;\n this.success = false;\n setTimeout(() => {\n this.message = '';\n this.success = null;\n }, 4000);\n }\n }\n}\n","import { render, staticRenderFns } from \"./Newsletterblock.vue?vue&type=template&id=5f0d30a2&\"\nimport script from \"./Newsletterblock.vue?vue&type=script&lang=ts&\"\nexport * from \"./Newsletterblock.vue?vue&type=script&lang=ts&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","import mod from \"-!../../../../../../node_modules/ts-loader/index.js??clonedRuleSet-6.use[0]!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Newsletterblock.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../../../../../../node_modules/ts-loader/index.js??clonedRuleSet-6.use[0]!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Newsletterblock.vue?vue&type=script&lang=ts&\"","var render = function render(){var _vm=this,_c=_vm._self._c,_setup=_vm._self._setupProxy;return _c('section',[_c('div',{staticClass:\"footer__form\"},[_c('ValidationObserver',{attrs:{\"slim\":\"\"},scopedSlots:_vm._u([{key:\"default\",fn:function({ handleSubmit }){return [_c('form',{on:{\"submit\":function($event){$event.preventDefault();$event.stopPropagation();return handleSubmit(_vm.doSubscribe)}}},[_c('ValidationProvider',{attrs:{\"name\":_vm.$t('Your e-mail'),\"rules\":\"required|email\",\"skip-if-empty\":false,\"tag\":\"div\"},scopedSlots:_vm._u([{key:\"default\",fn:function({ errors, classes }){return [_c('div',{staticClass:\"newsletter__container-form\"},[_c('input',{directives:[{name:\"model\",rawName:\"v-model\",value:(_vm.email),expression:\"email\"}],class:classes,attrs:{\"type\":\"email\",\"placeholder\":_vm.$t('Your e-mail')},domProps:{\"value\":(_vm.email)},on:{\"input\":function($event){if($event.target.composing)return;_vm.email=$event.target.value}}}),_vm._v(\" \"),_c('button',{staticClass:\"--button\",class:{'--loading': _vm.isLoading},attrs:{\"type\":\"submit\",\"disabled\":_vm.isLoading}})]),_vm._v(\" \"),_c('div',{staticClass:\"_error\"},[_c('span',{staticClass:\"field-error\"},[_vm._v(_vm._s(_vm.$t(errors[0])))]),_vm._v(\" \"),_c('span',{directives:[{name:\"show\",rawName:\"v-show\",value:(null !== _vm.success),expression:\"null !== success\"}],class:_vm.success ? 'field-success' : 'field-error'},[_vm._v(_vm._s(_vm.$t(_vm.message)))])])]}}],null,true)})],1)]}}])})],1)])\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }"],"names":["extend","required","email","Vue","message","success","isLoading","doSubscribe","this","data","$mageClient","post","window","push","rrApi","setProfile","e","console","error","setTimeout","Component","name","components","ValidationProvider","ValidationObserver","render","_vm","_c","_self","_setupProxy","staticClass","attrs","scopedSlots","_u","key","fn","handleSubmit","on","$event","preventDefault","stopPropagation","$t","errors","classes","directives","rawName","value","expression","class","domProps","target","composing","_v","_s","staticRenderFns"],"sourceRoot":""}