Skip to content
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(datepicker): fire onBlur callback properly #241

Merged
merged 5 commits into from
May 4, 2020

Conversation

arthurdenner
Copy link
Owner

What kind of change does this PR introduce?
Bug fix. Closes #238.

What is the current behavior?
The onBlur callback is fired automatically and in the wrong moments, e.g. selecting the first date on a range input.

What is the new behavior?
The callback is fired manually and the focus on the input is also controlled.

Checklist:

  • Documentation
  • Tests
  • Ready to be merged

@arthurdenner arthurdenner added the enhancement New feature or request label Apr 19, 2020
@vercel
Copy link

vercel bot commented Apr 19, 2020

This pull request is being automatically deployed with ZEIT Now (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://zeit.co/arthurdenner/react-semantic-ui-datepickers/pfws8blt5
✅ Preview: https://react-semantic-ui-datepickers-git-fix-onblur-fire-range.arthurdenner.now.sh

@codecov
Copy link

codecov bot commented Apr 19, 2020

Codecov Report

Merging #241 into develop will decrease coverage by 0.93%.
The diff coverage is 82.00%.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop     #241      +/-   ##
===========================================
- Coverage    88.19%   87.25%   -0.94%     
===========================================
  Files           14       14              
  Lines          432      463      +31     
  Branches        78       92      +14     
===========================================
+ Hits           381      404      +23     
- Misses          49       56       +7     
- Partials         2        3       +1     
Impacted Files Coverage Δ
src/index.tsx 90.52% <78.37%> (-2.65%) ⬇️
src/components/input.tsx 93.75% <92.30%> (-6.25%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6d63186...f749022. Read the comment docs.

@arthurdenner
Copy link
Owner Author

🎉 This PR is included in version 2.5.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request released
Projects
None yet
Development

Successfully merging this pull request may close these issues.

onBlur fires only when first date selected in SemanticDatepicker when type is range
1 participant