2
0
mirror of https://github.com/tenrok/vue-select.git synced 2026-06-19 09:50:33 +03:00

Use aria-label to improve component accessibility

This commit is contained in:
Thom Hurks
2017-06-29 00:44:36 +02:00
parent 0ce4921252
commit bf14cc50c8
+2 -1
View File
@@ -271,7 +271,7 @@
<span class="selected-tag" v-for="option in valueAsArray" v-bind:key="option.index"> <span class="selected-tag" v-for="option in valueAsArray" v-bind:key="option.index">
{{ getOptionLabel(option) }} {{ getOptionLabel(option) }}
<button v-if="multiple" @click="deselect(option)" type="button" class="close"> <button v-if="multiple" @click="deselect(option)" type="button" class="close" aria-label="Remove option">
<span aria-hidden="true">&times;</span> <span aria-hidden="true">&times;</span>
</button> </button>
</span> </span>
@@ -292,6 +292,7 @@
:readonly="!searchable" :readonly="!searchable"
:style="{ width: isValueEmpty ? '100%' : 'auto' }" :style="{ width: isValueEmpty ? '100%' : 'auto' }"
:id="inputId" :id="inputId"
aria-label="Search for option"
> >
<i v-if="!noDrop" ref="openIndicator" role="presentation" class="open-indicator"></i> <i v-if="!noDrop" ref="openIndicator" role="presentation" class="open-indicator"></i>