From fd3bf874ad24ea30add92aa7b2c1aae4198938f6 Mon Sep 17 00:00:00 2001 From: nanotronic Date: Mon, 11 Apr 2016 18:47:51 +0200 Subject: [PATCH] fix typo --- src/components/Select.vue | 4 ++-- test/unit/Select.spec.js | 9 ++++----- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/src/components/Select.vue b/src/components/Select.vue index 1b2573c..e7bf99b 100644 --- a/src/components/Select.vue +++ b/src/components/Select.vue @@ -257,7 +257,7 @@ * Enable/disable creating options from searchInput. * @type {Boolean} */ - tagable: { + taggable: { type: Boolean, default: false }, @@ -442,7 +442,7 @@ typeAheadSelect() { if( this.filteredOptions[ this.typeAheadPointer ] ) { this.select( this.filteredOptions[ this.typeAheadPointer ] ); - } else if (this.tagable && this.search.length){ + } else if (this.taggable && this.search.length){ let option = this.createOption(this.search) this.isAdding = true this.$set('options', [option, ...this.options]) diff --git a/test/unit/Select.spec.js b/test/unit/Select.spec.js index f2b9ebf..7c235b3 100644 --- a/test/unit/Select.spec.js +++ b/test/unit/Select.spec.js @@ -213,9 +213,9 @@ describe('Select.vue', () => { }) }) - it('can adding option if tagable enabled and search is not empty', () => { + it('can adding option if taggable enabled and search is not empty', () => { const vm = new Vue({ - template: '
', + template: '
', components: { vSelect }, data: { value: ['one'], @@ -231,9 +231,9 @@ describe('Select.vue', () => { expect(vm.$children[0].options[0]).toEqual('four') }) - it('should select added option if tagable enabled and search is not empty', (done) => { + it('should select added option if taggable enabled and search is not empty', (done) => { const vm = new Vue({ - template: '
', + template: '
', components: { vSelect }, data: { value: ['one'], @@ -252,6 +252,5 @@ describe('Select.vue', () => { }) }) - // also see example testing a component with mocks at // https://github.com/vuejs/vueify-example/blob/master/test/unit/a.spec.js#L22-L43