Skip to content

Commit 0925b27

Browse files
author
Kenneth Cheng
committed
autocomplete for map using startsWith matching
1 parent 645c509 commit 0925b27

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "vue3-excel-editor",
33
"email": "apple.6502@gmail.com",
44
"description": "Vue3 plugin for displaying and editing the array-of-object in Excel style",
5-
"version": "1.0.10",
5+
"version": "1.0.11",
66
"main": "src/main.js",
77
"dependencies": {
88
"@vuepic/vue-datepicker": "^3.3.0",

src/VueExcelEditor.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2631,7 +2631,7 @@ export default {
26312631
}
26322632
list.sort()
26332633
}
2634-
this.autocompleteSelect = list.findIndex(element => element.toUpperCase().includes(value))
2634+
this.autocompleteSelect = list.findIndex(element => element.toUpperCase().startsWith(value))
26352635
this.autocompleteInputs = list
26362636
const rect = this.currentCell.getBoundingClientRect()
26372637
this.lazy(() => {

0 commit comments

Comments
 (0)