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(date-picker): disable mobile UI #4443

Merged

Conversation

asudoh
Copy link
Contributor

@asudoh asudoh commented Oct 23, 2019

This change disables flatpickr's mobile mode, given we have been not
supporting the mobile UI and the mobile UI has caused several
JavaScript errors.

Fixes #4420.

Changelog

New

  • Code to disable flatpick's mobile mode.

Testing / Reviewing

Testing should make sure our date picker is not broken.

This change disables `flatpickr`'s mobile mode, given we have been not
supporting the mobile UI and the mobile UI has caused several
JavaScript errors.

Fixes carbon-design-system#4420.
@asudoh asudoh requested review from emyarod and abbeyhrt October 23, 2019 23:36
@asudoh asudoh requested a review from a team as a code owner October 23, 2019 23:36
@netlify
Copy link

netlify bot commented Oct 23, 2019

Deploy preview for the-carbon-components ready!

Built with commit 53300d7

https://deploy-preview-4443--the-carbon-components.netlify.com

@netlify
Copy link

netlify bot commented Oct 23, 2019

Deploy preview for carbon-components-react failed.

Built with commit 53300d7

https://app.netlify.com/sites/carbon-components-react/deploys/5dbc669f635e2aafe0e976f7

@netlify
Copy link

netlify bot commented Oct 23, 2019

Deploy preview for carbon-elements failed.

Built with commit 53300d7

https://app.netlify.com/sites/carbon-elements/deploys/5db381a484f6030008e6e911

Copy link
Member

@emyarod emyarod left a comment

Choose a reason for hiding this comment

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

issue is resolved for both libraries but would we want to support the native mobile date pickers in the future?

@joshblack joshblack requested a review from a team October 24, 2019 14:42
@ghost ghost requested review from jeanservaas and removed request for a team October 24, 2019 14:42
Copy link
Collaborator

@jeanservaas jeanservaas left a comment

Choose a reason for hiding this comment

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

Just want to clarify... does this affect anything visual... this is what I see following the steps in the issue, so I'm not sure what I should be reviewing in this PR

image

@abbeyhrt
Copy link
Contributor

@jeanservaas talking with @joshblack, it seems like we just wanted to verify on the UX design side if we want to disable the MobileUI for the DatePicker.

@joshblack
Copy link
Contributor

joshblack commented Oct 24, 2019

@jeanservaas I think what you are seeing may be what is intended. It seems like in the past flatpickr had a mobile view that this PR gets rid of to create that screenshot you posted

@asudoh
Copy link
Contributor Author

asudoh commented Oct 24, 2019

Sorry for not being clear enough @jeanservaas - @abbeyhrt and @joshblack are right, Flatpickr has different look for mobile. We haven't supported that mode, but in the status quo, whenever user goes to mobile such mobile mode is activated, causing several bugs, notably you'll see something below in some conditions (this is browser's native date picker):

image

So we want to ensure mobile mode is never activated.

@asudoh
Copy link
Contributor Author

asudoh commented Oct 24, 2019

@emyarod You have good question, native date picker may be in (future) consideration if we can style it in the way we want. Same thing applies to sliders, etc, too (in my personal opinion).

Copy link
Contributor

@abbeyhrt abbeyhrt left a comment

Choose a reason for hiding this comment

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

Thank you for the explanation @asudoh! This looks good to me!

@joshblack joshblack requested a review from jeanservaas October 25, 2019 16:28
@asudoh asudoh merged commit ad98531 into carbon-design-system:master Oct 25, 2019
@asudoh asudoh deleted the disable-mobile-view-date-picker branch October 25, 2019 23:24
@abbeyhrt abbeyhrt mentioned this pull request Nov 5, 2019
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.

Bug - DatePicker with Calendar - Carbon for React
5 participants