INSR-7759: Review dropdown header tweak, contact details drawer updates

This commit is contained in:
Alex Humphries 2026-02-19 11:12:14 -05:00
parent 4e996145c3
commit e12ac95cc7
3 changed files with 49 additions and 15 deletions

View file

@ -9,25 +9,29 @@
@isModalOpened="setModalStatus" @isModalOpened="setModalStatus"
@footerButtonEvent="clickFooterButtonEvent"> @footerButtonEvent="clickFooterButtonEvent">
<template v-if="isModalOpened"> <template v-if="isModalOpened">
<div class="row"> <span class="name-section-label">{{ nameSectionLabel }}</span>
<div class="row form-group">
<textboxQuestion <textboxQuestion
class="col" class="col-lg-6"
ref="firstNameQuestion" ref="firstNameQuestion"
v-model="firstName" v-model="firstName"
inputId="firstName" inputId="firstName"
:displayQuestionText="false"
:cmsWidgetName="widget.firstNameQuestion" :cmsWidgetName="widget.firstNameQuestion"
isRequired isRequired
:validationRules="rules.firstName" /> :validationRules="rules.firstName" />
<textboxQuestion <textboxQuestion
class="col" class="col-lg-6 last-name-question"
ref="lastNameQuestion" ref="lastNameQuestion"
v-model="lastName" v-model="lastName"
inputId="lastName" inputId="lastName"
:displayQuestionText="false"
:cmsWidgetName="widget.lastNameQuestion" :cmsWidgetName="widget.lastNameQuestion"
isRequired isRequired
:validationRules="rules.lastName" /> :validationRules="rules.lastName" />
</div> </div>
<textboxQuestion <textboxQuestion
class="form-group"
ref="emailQuestion" ref="emailQuestion"
v-model="emailAddress" v-model="emailAddress"
inputId="emailAddress" inputId="emailAddress"
@ -35,6 +39,7 @@
isRequired isRequired
:validationRules="rules.emailAddress" /> :validationRules="rules.emailAddress" />
<textboxQuestion <textboxQuestion
class="form-group"
ref="phoneNumberQuestion" ref="phoneNumberQuestion"
v-model="phoneNumber" v-model="phoneNumber"
inputId="phoneNumber" inputId="phoneNumber"
@ -44,6 +49,7 @@
disableAutoFill disableAutoFill
:validationRules="rules.phoneNumber" /> :validationRules="rules.phoneNumber" />
<textboxQuestion <textboxQuestion
class="form-group"
ref="extensionQuestion" ref="extensionQuestion"
v-model="extension" v-model="extension"
inputId="extension" inputId="extension"
@ -97,8 +103,8 @@ export default {
drawerFooter: 'ContactDetailsDrawerFooterWidget' drawerFooter: 'ContactDetailsDrawerFooterWidget'
}, },
rules: { rules: {
firstName: globalRules.FIRST_NAME_REQUIRED, firstName: globalRules.POLICYHOLDER_FIRST_NAME_REQUIRED,
lastName: globalRules.LAST_NAME_REQUIRED, lastName: globalRules.POLICYHOLDER_LAST_NAME_REQUIRED,
emailAddress: `${globalRules.EMAIL_ADDRESS_REQUIRED}|${globalRules.EMAIL_ADDRESS_FORMAT}`, emailAddress: `${globalRules.EMAIL_ADDRESS_REQUIRED}|${globalRules.EMAIL_ADDRESS_FORMAT}`,
phoneNumber: `${globalRules.PHONE_NUMBER_REQUIRED}|${globalRules.PHONE_NUMBER_FORMAT}`, phoneNumber: `${globalRules.PHONE_NUMBER_REQUIRED}|${globalRules.PHONE_NUMBER_FORMAT}`,
extension: `${globalRules.EXTENSION_FORMAT}` extension: `${globalRules.EXTENSION_FORMAT}`
@ -121,7 +127,10 @@ export default {
}, },
phoneMask() { phoneMask() {
return MaskaFormattedMasks.PHONE_NUMBER; return MaskaFormattedMasks.PHONE_NUMBER;
} },
nameSectionLabel() {
return this.getCmsContent(this.widget.firstNameQuestion, widgetFields.INPUT_QUESTION_WIDGET.QUESTION_TEXT);
},
}, },
methods: { methods: {
setModalStatus(isOpened) { setModalStatus(isOpened) {
@ -174,13 +183,18 @@ export default {
font-size: $h5-font-size; font-size: $h5-font-size;
font-weight: $font-weight-normal !important; font-weight: $font-weight-normal !important;
} }
.textbox-question { .form-group {
margin-bottom: 1.25rem; margin-bottom: 1.25rem;
:deep(label:has(b)) { align-items: start;
font-weight: $font-weight-normal; }
b { .name-section-label {
font-weight: 600; color: $black;
} font-weight: 600;
margin-bottom: .25rem;
}
.last-name-question {
@include media-breakpoint-down(lg) {
margin-top: .625rem;
} }
} }
} }

View file

@ -90,6 +90,10 @@
</div> </div>
</div> </div>
</div> </div>
<contactDetailsDrawer
ref="contactDetailsDrawer"
class="contact-details-drawer"
@updateContactDetails="refreshContactDetails" />
</div> </div>
</Form> </Form>
</template> </template>
@ -107,6 +111,7 @@ import alert from '@/ux-components/alert/alert.vue';
import textBlock from '@/digital-components/text-block/text-block.vue'; import textBlock from '@/digital-components/text-block/text-block.vue';
import buttonQuestion from '@/digital-components/button-question/button-question.vue'; import buttonQuestion from '@/digital-components/button-question/button-question.vue';
import textboxQuestion from '@/digital-components/textbox-question/textbox-question.vue'; import textboxQuestion from '@/digital-components/textbox-question/textbox-question.vue';
import contactDetailsDrawer from '@/iss-components/contact-details-drawer/contact-details-drawer.vue';
// Supporting Items // Supporting Items
import settleAllPromises from '@/helpers/layout-helper'; import settleAllPromises from '@/helpers/layout-helper';
@ -142,7 +147,8 @@ export default {
alert, alert,
textBlock, textBlock,
buttonQuestion, buttonQuestion,
textboxQuestion textboxQuestion,
contactDetailsDrawer
}, },
mixins: [baseFormMixin], mixins: [baseFormMixin],
async beforeRouteEnter(to, from, next) { async beforeRouteEnter(to, from, next) {
@ -418,6 +424,7 @@ export default {
); );
break; break;
case 'customer': case 'customer':
this.openContactDetailsModal();
break; break;
case 'wipers': case 'wipers':
this.$router.navigateWithSpinner( this.$router.navigateWithSpinner(
@ -426,6 +433,12 @@ export default {
); );
break; break;
} }
},
openContactDetailsModal() {
this.$refs.contactDetailsDrawer.openModal();
},
refreshContactDetails() {
this.smsPhoneNumber = this.getSMSPhoneFromStore();
} }
} }
}; };
@ -543,5 +556,11 @@ $page-side-padding: 1.5rem;
} }
} }
} }
.contact-details-drawer {
:deep(strong) {
color: $black;
font-weight: 600;
}
}
} }
</style> </style>

View file

@ -1,13 +1,13 @@
<template> <template>
<div> <div>
<div <div
class="row review-toggle flex align-items-center" class="review-toggle d-flex align-items-center justify-content-between"
:class="[isExpanded ? 'expanded' : '']" :class="[isExpanded ? 'expanded' : '']"
@click="toggleIsExpanded"> @click="toggleIsExpanded">
<a <a
aria-label="expand appointment details" aria-label="expand appointment details"
href="javascript:void(0)" href="javascript:void(0)"
class="col d-flex justify-content-between py-0"> class="d-flex py-0">
<span class="label">Appointment details</span> <span class="label">Appointment details</span>
</a> </a>
</div> </div>
@ -117,6 +117,7 @@ export default {
.review-toggle { .review-toggle {
margin-bottom: .625rem; margin-bottom: .625rem;
flex-direction: row;
&:after { &:after {
content: ""; content: "";
transition: transform none; transition: transform none;