-
-
Notifications
You must be signed in to change notification settings - Fork 334
fix: ant-design/ant-design#21084 improve range picker calendar display on select #21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: ant-design/ant-design#21084 improve range picker calendar display on select #21
Conversation
This pull request is being automatically deployed with ZEIT Now (learn more). 🔍 Inspect: https://zeit.co/react-component/picker/ky9mbsvia |
Codecov Report
@@ Coverage Diff @@
## master #21 +/- ##
==========================================
- Coverage 99.55% 99.55% -0.01%
==========================================
Files 43 43
Lines 1793 1790 -3
Branches 525 534 +9
==========================================
- Hits 1785 1782 -3
Misses 6 6
Partials 2 2
Continue to review full report at Codecov.
|
Please fix this one :) |
wrapper.openPicker(1); | ||
wrapper.selectCell(1993); | ||
expect(isSame(onPanelChange.mock.calls[0][0][1], '1993-09-03')); | ||
expect(isSame(onPanelChange.mock.calls[0][0][1], '1993-02-03')); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should fix logic instead of change test case.
Any progress on this one @morenyang ? |
f0715eb
to
7f7e956
Compare
Hi, @zombieJ , I reviewed the issue description and code again, in the original comment, it says to reset another one when empty, but the condition seems to be wrong picker/src/hooks/useRangeViewDates.ts Lines 129 to 133 in 2d30468
so I reverse the condition and it works picker/src/hooks/useRangeViewDates.ts Lines 106 to 110 in 7f7e956
|
Got it. You are correct. |
Okay, I may add some test cases when I have time |
7f7e956
to
13aa6a3
Compare
13aa6a3
to
53bc14d
Compare
Hi @zombieJ , add a test case for this |
|
Refs to ant-design/ant-design#21084
Update
viewDates
when any item is selected.Whether this will cause other impacts, needs further review.