Use Cms defined text

This commit is contained in:
Chloe Herd 2023-08-10 16:49:14 -04:00
parent 2ae0c0922b
commit bc3b713e11

View file

@ -1,8 +1,5 @@
<template>
<reviewBlock
:headerCmsWidgetName="cmsWidgetName"
:content="displayContent"
@edit-clicked="editClicked" />
<reviewBlock :customHeaderText="header" :content="displayContent" @edit-clicked="editClicked" />
</template>
<script>
@ -24,12 +21,10 @@ export default {
},
computed: {
displayContent() {
return [
this.fullName,
this.email,
this.phoneNumber,
this.smsOptIn,
];
return [this.fullName, this.email, this.phoneNumber, this.smsOptIn];
},
header() {
return this.getCmsContent(this.cmsWidgetName, "HeaderText");
},
fullName() {
return `${this.customer?.firstName} ${this.customer?.lastName}`;
@ -41,10 +36,8 @@ export default {
return this.customer?.phoneNumber;
},
smsOptIn() {
return this.customer?.isSmsOptIn
? "Opted in to text message updates"
: "Opted out of text message updates";
}
return this.getCmsContent(this.cmsWidgetName, "SubheaderText");
},
},
components: {
reviewBlock,