diff --git a/packages/picker/index.ts b/packages/picker/index.ts index deeac83e..755349fc 100644 --- a/packages/picker/index.ts +++ b/packages/picker/index.ts @@ -53,6 +53,21 @@ VantComponent({ return Promise.all(stack); }, + emit(event: WechatMiniprogram.TouchEvent) { + const { type } = event.currentTarget.dataset; + if (this.simple) { + this.$emit(type, { + value: this.getColumnValue(0), + index: this.getColumnIndex(0), + }); + } else { + this.$emit(type, { + value: this.getValues(), + index: this.getIndexes(), + }); + } + }, + onChange(event: WechatMiniprogram.CustomEvent) { if (this.simple) { this.$emit('change', {