{"version":3,"sources":["webpack:///./src/components/UI/Loader.vue","webpack:///./src/components/UI/Loader.vue?baee","webpack:///./src/components/UI/Loader.vue?8596","webpack:///./src/components/UI/Loader.vue?9492","webpack:///./src/views/Unsubscribe.vue","webpack:///./src/views/Unsubscribe.vue?22f8","webpack:///./src/views/Unsubscribe.vue?f605","webpack:///./src/views/Unsubscribe.vue?b5c3","webpack:///./node_modules/client-website-ts-library/plugins/view/index.ts","webpack:///./src/components/UI/Loader.vue?fa85"],"names":["render","_vm","this","_c","_self","_setupProxy","directives","name","rawName","value","loading","expression","staticClass","staticRenderFns","Loader","Vue","__decorate","Prop","Component","component","attrs","error","_v","email","optedOut","_s","on","optOut","_e","Unsubscribe","Mixins","View","constructor","invalid","mounted","contactId","$route","query","_a","ContactId","userId","_b","UserId","length","API","CRM","GetOptoutStatus","then","status","Email","OptedOut","catch","OptOut","data","components","ViewBase","prolistAnalyticsService","ServiceManager","Get","ServiceType","Analytics","headService","Require","Head","updateAnalytics","evt","obj","getAnalyticsEvent","call","getAnalyticsData","AnalyticsPageView","path","undefined","triggerAnalyticsEvent","event","GetAll","forEach","adapter","Record","triggerCustomAnalyticsEvent","updateHead","result","head","bind","Promise","meta","Update","UpdateWithStatic","requestAnimationFrame","AsyncView","$on"],"mappings":"kHAAA,IAAIA,EAAS,WAAkB,IAAIC,EAAIC,KAAKC,EAAGF,EAAIG,MAAMD,GAAUF,EAAIG,MAAMC,YAAY,OAAOF,EAAG,MAAM,CAACG,WAAW,CAAC,CAACC,KAAK,OAAOC,QAAQ,SAASC,MAAOR,EAAIS,QAASC,WAAW,YAAYC,YAAY,YAEvMC,EAAkB,G,gWCEtB,IAAqBC,EAArB,cAAoCC,SAEhCC,GADCC,kBACD,8BAFiBH,EAAM,GAD1BI,QACoBJ,WCJ8X,I,wBCQ/YK,EAAY,eACd,EACAnB,EACAa,GACA,EACA,KACA,WACA,MAIa,OAAAM,E,kDCnBf,IAAInB,EAAS,WAAkB,IAAIC,EAAIC,KAAKC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CxE,KAAKsD,yBAAkCtD,KAAKsD,wBAAwBsB,OAAOJ,GAGvEM,aACR,GAAI,SAAU9E,KAAM,CAClB,MAAM+E,EAAS/E,KAAKgF,KAAMC,KAAKjF,KAAhBA,GAEZ+E,aAAkBG,QACnBH,EAAOlC,KAAMsC,IACXnF,KAAK2D,YAAYyB,OAAOD,KAG1BnF,KAAK2D,YAAYyB,OAAOL,QAG1B/E,KAAK2D,YAAY0B,iBAAiBrF,KAAKkC,OAAOmC,QAzC9ChB,EAAQ,yBADbrC,QACKqC,GA+CN,IAAMxB,EAAN,cAAmBwB,EACVrB,UACLsD,sBAAsB,KACpBtF,KAAK8E,aACL9E,KAAK8D,sBAJLjC,EAAI,yBADTb,QACKa,GAUN,IAAM0D,EAAN,cAAwBlC,EACfrB,UACLhC,KAAKwF,IAAI,aAAc,KACrBF,sBAAsB,KACpBtF,KAAK8E,aACL9E,KAAK8D,wBALPyB,EAAS,yBADdvE,QACKuE,I,kCCvEN,W","file":"js/chunk-a5301122.5fc86f77.js","sourcesContent":["var render = function render(){var _vm=this,_c=_vm._self._c,_setup=_vm._self._setupProxy;return _c('div',{directives:[{name:\"show\",rawName:\"v-show\",value:(_vm.loading),expression:\"loading\"}],staticClass:\"loader\"})\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","\nimport { Component, Vue, Prop } from 'vue-property-decorator';\n\n@Component\nexport default class Loader extends Vue {\n @Prop()\n private readonly loading!: boolean;\n}\n","import mod from \"-!../../../node_modules/cache-loader/dist/cjs.js??ref--15-0!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/ts-loader/index.js??ref--15-3!../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Loader.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../../../node_modules/cache-loader/dist/cjs.js??ref--15-0!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/ts-loader/index.js??ref--15-3!../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Loader.vue?vue&type=script&lang=ts&\"","import { render, staticRenderFns } from \"./Loader.vue?vue&type=template&id=b15215d2&scoped=true&\"\nimport script from \"./Loader.vue?vue&type=script&lang=ts&\"\nexport * from \"./Loader.vue?vue&type=script&lang=ts&\"\nimport style0 from \"./Loader.vue?vue&type=style&index=0&id=b15215d2&prod&scoped=true&lang=css&\"\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 \"b15215d2\",\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c,_setup=_vm._self._setupProxy;return _c('Page',[_c('SiteMasthead',{attrs:{\"mini\":\"true\",\"title\":\"Opt Out\"}}),_c('ContentRow',[_c('ContentContainer',[_c('div',{staticClass:\"center-text static-content\"},[(_vm.loading)?[_c('Loader',{attrs:{\"loading\":\"true\"}})]:(_vm.error)?[_c('p',[_vm._v(\" There was an error processing your request. Please contact us to opt out, or try again later. \")])]:(_vm.email)?[(_vm.optedOut)?_c('p',[_vm._v(\" Your email \"+_vm._s(_vm.email)+\" has been unsubscribed. \")]):[_c('p',[_vm._v(\" Please confirm that you wish to unsubscribe \"+_vm._s(_vm.email)+\". \")]),_c('br'),_c('Button',{on:{\"click\":_vm.optOut}},[_vm._v(\"Confirm\")])]]:_vm._e()],2)])],1)],1)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","\nimport { Component, Mixins } from 'vue-property-decorator';\n\nimport Loader from '@/components/UI/Loader.vue';\nimport { API } from 'client-website-ts-library/services';\nimport { View } from 'client-website-ts-library/plugins';\n\n@Component({\n components: {\n Loader,\n },\n})\nexport default class Unsubscribe extends Mixins(View) {\n private loading = true;\n\n private invalid = false;\n\n private error = false;\n\n private email: string | null = null;\n\n private optedOut = false;\n\n mounted() {\n const contactId = this.$route.query?.ContactId;\n const userId = this.$route.query?.UserId;\n\n if (contactId && contactId.length && userId && userId.length && typeof contactId === 'string' && typeof userId === 'string') {\n API.CRM.GetOptoutStatus(contactId, userId).then((status) => {\n this.email = status.Email;\n this.optedOut = status.OptedOut;\n this.loading = false;\n }).catch(() => {\n this.error = true;\n this.loading = false;\n });\n } else {\n this.invalid = true;\n this.loading = false;\n }\n }\n\n optOut() {\n const contactId = this.$route.query?.ContactId;\n const userId = this.$route.query?.UserId;\n\n this.loading = true;\n\n if (contactId && contactId.length && userId && userId.length && typeof contactId === 'string' && typeof userId === 'string') {\n API.CRM.OptOut(contactId, userId).then((data) => {\n this.loading = false;\n\n this.optedOut = data.OptedOut;\n }).catch(() => {\n this.loading = false;\n this.error = true;\n });\n }\n }\n}\n","import mod from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--15-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/ts-loader/index.js??ref--15-3!../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Unsubscribe.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--15-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/ts-loader/index.js??ref--15-3!../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Unsubscribe.vue?vue&type=script&lang=ts&\"","import { render, staticRenderFns } from \"./Unsubscribe.vue?vue&type=template&id=41b2b334&\"\nimport script from \"./Unsubscribe.vue?vue&type=script&lang=ts&\"\nexport * from \"./Unsubscribe.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 Vue from \"vue\";\r\nimport { Component } from \"vue-property-decorator\";\r\nimport { AnalyticsEvent, AnalyticsEventObject, AnalyticsPageView, IAnalyticsAdapter, PROListAnalyticsAdapter } from \"../../services/Analytics\";\r\nimport { HeadService } from \"../../services/HeadService\";\r\nimport { ServiceManager, ServiceType } from \"../../services/ServiceManager\";\r\nimport { RouteMeta } from \"../meta\";\r\n\r\ninterface ViewBase {\r\n getAnalyticsEvent?(): AnalyticsEvent | null;\r\n getAnalyticsData?(): AnalyticsEventObject | null;\r\n head?(): RouteMeta | Promise | null;\r\n}\r\n\r\n@Component\r\nclass ViewBase extends Vue {\r\n protected prolistAnalyticsService = ServiceManager.Get(ServiceType.Analytics, 'PROListAnalyticsAdapter');\r\n protected headService = ServiceManager.Require(ServiceType.Head)!;\r\n\r\n public updateAnalytics() {\r\n let evt: AnalyticsEvent | null = null;\r\n let obj: AnalyticsEventObject | null = null;\r\n\r\n if (typeof this.getAnalyticsEvent !== 'undefined') {\r\n evt = this.getAnalyticsEvent.call(this);\r\n } else if(typeof this.getAnalyticsData !== 'undefined') {\r\n obj = this.getAnalyticsData.call(this);\r\n }\r\n\r\n if (evt === null) evt = new AnalyticsPageView(this.$route.path, this.$route.name || '', obj || undefined);\r\n\r\n this.triggerAnalyticsEvent(evt);\r\n }\r\n\r\n public triggerAnalyticsEvent(event: AnalyticsEvent) {\r\n ServiceManager.GetAll(ServiceType.Analytics).forEach((adapter) => {\r\n adapter.Record(event);\r\n });\r\n }\r\n\r\n public triggerCustomAnalyticsEvent(event: AnalyticsEvent) {\r\n if (this.prolistAnalyticsService !== null) this.prolistAnalyticsService.Record(event);\r\n }\r\n\r\n protected updateHead() {\r\n if ('head' in this) {\r\n const result = this.head!.bind(this)();\r\n\r\n if(result instanceof Promise) {\r\n result.then((meta: RouteMeta | null) => {\r\n this.headService.Update(meta);\r\n });\r\n } else {\r\n this.headService.Update(result as RouteMeta | null);\r\n }\r\n } else {\r\n this.headService.UpdateWithStatic(this.$route.path);\r\n }\r\n }\r\n}\r\n\r\n@Component\r\nclass View extends ViewBase {\r\n public mounted() {\r\n requestAnimationFrame(() => {\r\n this.updateHead();\r\n this.updateAnalytics();\r\n });\r\n }\r\n}\r\n\r\n@Component\r\nclass AsyncView extends ViewBase {\r\n public mounted() {\r\n this.$on('updateView', () => {\r\n requestAnimationFrame(() => {\r\n this.updateHead();\r\n this.updateAnalytics();\r\n });\r\n });\r\n }\r\n}\r\n\r\nexport {\r\n View,\r\n AsyncView\r\n}\r\n","export * from \"-!../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--7-oneOf-1-0!../../../node_modules/css-loader/dist/cjs.js??ref--7-oneOf-1-1!../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../node_modules/postcss-loader/src/index.js??ref--7-oneOf-1-2!../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Loader.vue?vue&type=style&index=0&id=b15215d2&prod&scoped=true&lang=css&\""],"sourceRoot":""}