Form with autocompleted that expands does not need to submit form on enter

This commit is contained in:
2019-02-13 01:26:01 +01:00
parent f4e9cd3c41
commit aa91e40aa4

View File

@@ -31,7 +31,7 @@
<div class="form-item field text required">
<label class="title" for="text3-field">Sted<span class="required">*</span></label>
<input class="field-element text" v-model="locationInput" @click="show" type="text">
<input class="field-element text" v-model="locationInput" v-on:keydown.enter.prevent @click="show" type="text">
<ul class="field-autocompleted" v-click-outside="hide" v-if="showAutocompleted && features.length > 1">
<li v-for="result in features" @click="choosePlace(result)">{{ result.place_name_no }}</li>