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

update docs

This commit is contained in:
Jeff
2019-11-07 17:15:48 -08:00
committed by Jeff
parent 8cce5e0ea2
commit af424159f7
3 changed files with 53 additions and 47 deletions
+12 -17
View File
@@ -1,10 +1,10 @@
<template>
<v-select
taggable
multiple
no-drop
:map-keydown="handlers"
placeholder="try tagging with space or comma to submit"
taggable
multiple
no-drop
:map-keydown="handlers"
placeholder="enter an email"
/>
</template>
@@ -12,19 +12,14 @@
export default {
name: 'CustomHandlers',
methods: {
handlers (map, vm) {
const createTag = e => {
handlers: (map, vm) => ({
...map, 50: e => {
e.preventDefault();
vm.typeAheadSelect();
vm.searchEl.focus();
};
return {
...map, // defaults
32: createTag, // space
188: createTag, // comma
};
},
if( e.key === '@' && vm.search.length > 0 ) {
vm.search = `${vm.search}@gmail.com`;
}
},
}),
},
};
</script>