Skip to content

Commit

Permalink
fix: Picker should open when click on padding
Browse files Browse the repository at this point in the history
  • Loading branch information
zombieJ committed Feb 17, 2020
1 parent ae16e30 commit 85e3933
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/Picker.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -289,6 +289,7 @@ function InnerPicker<DateType>(props: PickerProps<DateType>) {

if (inputRef.current) {
inputRef.current.focus();
triggerOpen(true);
}
};

Expand Down
1 change: 1 addition & 0 deletions tests/picker.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -557,6 +557,7 @@ describe('Picker.Basic', () => {

wrapper.find('.rc-picker').simulate('mouseUp');
expect(inputElement.focus).toHaveBeenCalled();
expect(wrapper.isOpen()).toBeTruthy();
});

it('defaultOpenValue in timePicker', () => {
Expand Down

1 comment on commit 85e3933

@vercel
Copy link

@vercel vercel bot commented on 85e3933 Feb 17, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.