diff --git a/src/common-components/base-input-button/base-input-button.vue b/src/common-components/base-input-button/base-input-button.vue index 1ab003e78..76fa8e134 100644 --- a/src/common-components/base-input-button/base-input-button.vue +++ b/src/common-components/base-input-button/base-input-button.vue @@ -81,13 +81,13 @@ export default { if (this.isMultiSelect) { switch (eventType) { case eventTypes.KEYPRESS_SUBMIT: + case eventTypes.CHANGE: this.handleClick(e); break; - case eventTypes.CHANGE: - this.selectOnKeypress - ? this.handleClick(e) - : this.handleSelectionChange(e); - break; + // this.selectOnKeypress + // ? this.handleClick(e) + // : this.handleSelectionChange(e); + // break; } } else { switch (eventType) { @@ -143,8 +143,10 @@ export default { valueToLogType: this.valueToLogType, }); - window.firedGaClickEventValues = window.firedGaClickEventValues ?? {} - window.firedGaClickEventValues[window.lastFocusedInputGroup] = value ?? this.value + window.firedGaClickEventValues = + window.firedGaClickEventValues ?? {}; + window.firedGaClickEventValues[window.lastFocusedInputGroup] = + value ?? this.value; this.pushEventToGA( this.$route.query[queryStrings.FMG_PAGE], this.GaActions.CLICKED, @@ -155,29 +157,34 @@ export default { }, handleBlur() { window.lastFocusedInputGroup = this.groupName; - window.wasLastFocusedInputMultiselect = this.isMultiSelect + window.wasLastFocusedInputMultiselect = this.isMultiSelect; }, handleFocus() { console.log("FOCUS: ", { currentlySelectedValues: window.currentlySelectedValues, firedGaClickEventValues: window.firedGaClickEventValues, lastFocusedInputGroup: window.lastFocusedInputGroup, - wasLastFocusedInputMultiselect: window.wasLastFocusedInputMultiselect, - groupName: this.groupName - }) + wasLastFocusedInputMultiselect: + window.wasLastFocusedInputMultiselect, + groupName: this.groupName, + }); if ( window.currentlySelectedValues && window.firedGaClickEventValues && window.lastFocusedInputGroup && - !window.wasLastFocusedInputMultiselect && + !window.wasLastFocusedInputMultiselect && window.currentlySelectedValues[window.lastFocusedInputGroup] && window.lastFocusedInputGroup != this.groupName && - window.firedGaClickEventValues[window.lastFocusedInputGroup] != window.currentlySelectedValues[window.lastFocusedInputGroup] + window.firedGaClickEventValues[window.lastFocusedInputGroup] != + window.currentlySelectedValues[window.lastFocusedInputGroup] ) { // TODO MAKE SURE THIS IS FIRING THE RIGHT VALUE - this.pushClickEventToGA(window.currentlySelectedValues[window.lastFocusedInputGroup]) + this.pushClickEventToGA( + window.currentlySelectedValues[window.lastFocusedInputGroup] + ); } }, + test() {} }, computed: { isChecked() {