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

[DateRangeInput] Show formatted min/max dates on focus when inputs empty #874

Merged
merged 5 commits into from
Mar 22, 2017

Conversation

cmslewis
Copy link
Contributor

Addresses #805

Checklist

  • Include tests

Changes proposed in this pull request:

  • Show formatted min/max dates on focus in an empty start/end input

Reviewers should focus on:

  • Things break if min/max === null, but that's already not really a supported case. Can address that more generally in a future PR if we want.
  • See comments about caching the formatted min/max date strings. If we don't cache the formatted min/max date strings in this.state, then we'll have to cast those vanilla JS dates to moments on every render just to achieve properly formatted placeholder dates, which is exceedingly wasteful.

Screenshot

2017-03-21 14 25 43

@cmslewis cmslewis mentioned this pull request Mar 21, 2017
8 tasks
@blueprint-bot
Copy link

Little cleanups

Preview: docs
Coverage: core | datetime

@blueprint-bot
Copy link

Resolve conflicts

Preview: docs
Coverage: core | datetime

@cmslewis cmslewis merged commit 1b399a1 into master Mar 22, 2017
@cmslewis cmslewis deleted the cl/dri-placeholder-text branch March 22, 2017 00:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants