Skip to content

Commit

Permalink
fix(dropdown): support dropdown-item value is empty can be upd
Browse files Browse the repository at this point in the history
ated
  • Loading branch information
yaogengzhu committed Jul 23, 2023
1 parent f6fe9c8 commit e376d69
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/dropdown-menu/dropdown-item.vue
Original file line number Diff line number Diff line change
Expand Up @@ -256,10 +256,8 @@ export default defineComponent({
if (!state.isShowItems) return;
const value = passInValue.value || [];
if (value[0] === val) return;
if (val) {
props.onChange?.(val);
setValue(val);
}
props.onChange?.(val);
setValue(val);
collapseMenu();
emitEvents('menuClosed', 'content');
});
Expand Down

0 comments on commit e376d69

Please sign in to comment.