diff --git a/app/webpacker/controllers/accessible_autocomplete_controller.js b/app/webpacker/controllers/accessible_autocomplete_controller.js index db34213ee..5ca1b2c35 100644 --- a/app/webpacker/controllers/accessible_autocomplete_controller.js +++ b/app/webpacker/controllers/accessible_autocomplete_controller.js @@ -4,9 +4,11 @@ import 'accessible-autocomplete/dist/accessible-autocomplete.min.css' export default class extends Controller { connect() { - accessibleAutocomplete.enhanceSelectElement({ - defaultValue: '', - selectElement: this.element - }) + if(document.querySelectorAll(".autocomplete__input").length == 0){ + accessibleAutocomplete.enhanceSelectElement({ + defaultValue: '', + selectElement: this.element + }) + } } }