diff --git a/src/common-components/button-question/button-question.vue b/src/common-components/button-question/button-question.vue index 417230464..5df9531df 100644 --- a/src/common-components/button-question/button-question.vue +++ b/src/common-components/button-question/button-question.vue @@ -19,7 +19,7 @@ :textPosition="textPosition" :isMultiSelect="isMultiSelect" :groupName="groupName" - :loaderEnabled="loaderEnabled" + :selectingInitiatesLoad="selectingInitiatesLoad" :loaderColor="loaderColor" :loaderPosition="loaderPosition" :sizeInRem="sizeInRem" @@ -65,7 +65,7 @@ export default { type: String, default: "text-center", }, - loaderEnabled: Boolean, + selectingInitiatesLoad: Boolean, loaderColor: { type: String, default: "blue", @@ -138,7 +138,7 @@ export default { val.isChecked ? newSelectedValues.push(val.buttonId) : newSelectedValues.splice(newSelectedValues.indexOf(val.buttonId), 1); this.selectedValues = newSelectedValues; } else { - this.selectedValues = [val.buttonId] + this.selectedValues = [val.buttonId]; } }, }, diff --git a/src/layouts/vehicle-make/make-question/make-question.vue b/src/layouts/vehicle-make/make-question/make-question.vue index 9fb2d6ea1..bc8ce5f9f 100644 --- a/src/layouts/vehicle-make/make-question/make-question.vue +++ b/src/layouts/vehicle-make/make-question/make-question.vue @@ -2,11 +2,11 @@ diff --git a/src/layouts/vehicle-model/model-question/model-question.vue b/src/layouts/vehicle-model/model-question/model-question.vue index e79b8bafc..1876630ef 100644 --- a/src/layouts/vehicle-model/model-question/model-question.vue +++ b/src/layouts/vehicle-model/model-question/model-question.vue @@ -2,11 +2,11 @@ diff --git a/src/layouts/vehicle-style/style-question/style-question.vue b/src/layouts/vehicle-style/style-question/style-question.vue index bfec78571..a923c9128 100644 --- a/src/layouts/vehicle-style/style-question/style-question.vue +++ b/src/layouts/vehicle-style/style-question/style-question.vue @@ -2,11 +2,11 @@ diff --git a/src/layouts/vehicle-year/year-question/year-question.vue b/src/layouts/vehicle-year/year-question/year-question.vue index 96d047244..97c2ab618 100644 --- a/src/layouts/vehicle-year/year-question/year-question.vue +++ b/src/layouts/vehicle-year/year-question/year-question.vue @@ -2,11 +2,11 @@ diff --git a/src/ux-components/list-button-horizontal/list-button-horizontal.spec.js b/src/ux-components/list-button-horizontal/list-button-horizontal.spec.js index 5cbe02e75..ba1f12d23 100644 --- a/src/ux-components/list-button-horizontal/list-button-horizontal.spec.js +++ b/src/ux-components/list-button-horizontal/list-button-horizontal.spec.js @@ -91,7 +91,7 @@ describe("list-button-horizontal.vue", () => { // Act const wrapper = shallowMount(listButtonHorizontal, { propsData: { - loaderEnabled: true, + selectingInitiatesLoad: true, }, }); @@ -99,6 +99,7 @@ describe("list-button-horizontal.vue", () => { const label = wrapper.find("label"); + wrapper.vm.handleCheckChange = jest.fn(); wrapper.vm.handleClick(); await nextTick(); @@ -113,7 +114,7 @@ describe("list-button-horizontal.vue", () => { const wrapper = shallowMount(listButtonHorizontal, { propsData: { loaderColor: "blue", - loaderEnabled: true, + selectingInitiatesLoad: true, }, }); @@ -121,6 +122,7 @@ describe("list-button-horizontal.vue", () => { const label = wrapper.find("label"); + wrapper.vm.handleCheckChange = jest.fn(); wrapper.vm.handleClick(); await nextTick(); @@ -135,7 +137,7 @@ describe("list-button-horizontal.vue", () => { const wrapper = shallowMount(listButtonHorizontal, { propsData: { loaderPosition: "right", - loaderEnabled: true, + selectingInitiatesLoad: true, }, }); @@ -143,6 +145,7 @@ describe("list-button-horizontal.vue", () => { const label = wrapper.find("label"); + wrapper.vm.handleCheckChange = jest.fn(); wrapper.vm.handleClick(); await nextTick(); @@ -157,7 +160,7 @@ describe("list-button-horizontal.vue", () => { const wrapper = shallowMount(listButtonHorizontal, { propsData: { sizeInRem: 1, - loaderEnabled: true, + selectingInitiatesLoad: true, }, }); @@ -165,6 +168,7 @@ describe("list-button-horizontal.vue", () => { const label = wrapper.find("label"); + wrapper.vm.handleCheckChange = jest.fn(); wrapper.vm.handleClick(); await nextTick(); diff --git a/src/ux-components/list-button-horizontal/list-button-horizontal.vue b/src/ux-components/list-button-horizontal/list-button-horizontal.vue index 034f97c07..5044a7fb0 100644 --- a/src/ux-components/list-button-horizontal/list-button-horizontal.vue +++ b/src/ux-components/list-button-horizontal/list-button-horizontal.vue @@ -12,7 +12,7 @@ :aria-required="isRequired" :data-focus-target="groupName" v-model="checkValue" - @change="handleCheckChange" + @change="!selectingInitiatesLoad ? handleCheckChange : ''" />