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

[pickers] Add proper support for UTC and timezones #8261

Merged
merged 30 commits into from
Jun 20, 2023

Conversation

flaviendelangle
Copy link
Member

@flaviendelangle flaviendelangle commented Mar 16, 2023

Doc preview

Follow up on #9068
Closes #8484
Fixes #8334
Fixes #5876

Challenges

  • Dayjs isSame method is based on local timezone (or UTC if the two dates are UTC). In the day view we highlight the current day and we want it to be the current day, in the timezone of props.timezone.
  • Dayjs startOf method performances are catastrophic when using timezone and Dayjs is using all over the place... I'm trying to skip its usage when possible

@flaviendelangle flaviendelangle added the component: pickers This is the name of the generic UI component, not the React module! label Mar 16, 2023
@flaviendelangle flaviendelangle self-assigned this Mar 16, 2023
@mui-bot
Copy link

mui-bot commented Mar 16, 2023

Netlify deploy preview

Netlify deploy preview: https://deploy-preview-8261--material-ui-x.netlify.app/

Updated pages

These are the results for the performance tests:

Test case Unit Min Max Median Mean σ
Filter 100k rows ms 471.8 993.3 816 724.84 212.76
Sort 100k rows ms 531.7 1,080.3 531.7 826.9 203.465
Select 100k rows ms 206.5 314.4 274.3 262.86 41.332
Deselect 100k rows ms 128 355.8 234.1 249.34 77.021

Generated by 🚫 dangerJS against 7db1884

@github-actions github-actions bot added the PR: out-of-date The pull request has merge conflicts and can't be merged label Mar 20, 2023
@github-actions
Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot added PR: out-of-date The pull request has merge conflicts and can't be merged and removed PR: out-of-date The pull request has merge conflicts and can't be merged labels Mar 24, 2023
@github-actions
Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot added PR: out-of-date The pull request has merge conflicts and can't be merged and removed PR: out-of-date The pull request has merge conflicts and can't be merged labels Mar 28, 2023
@github-actions
Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged label Mar 30, 2023
@flaviendelangle flaviendelangle changed the title [pickers] Allow to use UTC with AdapterLuxon [pickers] Add proper support for UTC and timezones Mar 30, 2023
@github-actions github-actions bot added the PR: out-of-date The pull request has merge conflicts and can't be merged label Apr 3, 2023
@github-actions
Copy link

github-actions bot commented Apr 3, 2023

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot added PR: out-of-date The pull request has merge conflicts and can't be merged and removed PR: out-of-date The pull request has merge conflicts and can't be merged labels Apr 3, 2023
@github-actions
Copy link

github-actions bot commented Apr 3, 2023

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot added PR: out-of-date The pull request has merge conflicts and can't be merged and removed PR: out-of-date The pull request has merge conflicts and can't be merged labels Apr 4, 2023
@github-actions
Copy link

github-actions bot commented Apr 6, 2023

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot added PR: out-of-date The pull request has merge conflicts and can't be merged and removed PR: out-of-date The pull request has merge conflicts and can't be merged labels Apr 6, 2023
@github-actions
Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot added PR: out-of-date The pull request has merge conflicts and can't be merged and removed PR: out-of-date The pull request has merge conflicts and can't be merged labels Apr 12, 2023
@github-actions
Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged label Apr 12, 2023
@flaviendelangle flaviendelangle force-pushed the luxon-utc branch 7 times, most recently from 703bd78 to fac3524 Compare June 14, 2023 12:50
Copy link
Member

@joserodolfofreitas joserodolfofreitas left a comment

Choose a reason for hiding this comment

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

Nice work taming this beast! It feels easy to work with timezones now :)

docs/data/date-pickers/timezone/timezone.md Outdated Show resolved Hide resolved
docs/data/date-pickers/timezone/timezone.md Show resolved Hide resolved
docs/data/date-pickers/timezone/timezone.md Outdated Show resolved Hide resolved
@github-actions github-actions bot added the PR: out-of-date The pull request has merge conflicts and can't be merged label Jun 19, 2023
@github-actions
Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged label Jun 20, 2023
@flaviendelangle flaviendelangle merged commit 13658f0 into mui:master Jun 20, 2023
@flaviendelangle flaviendelangle deleted the luxon-utc branch June 20, 2023 07:56
@richbustos
Copy link
Contributor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: pickers This is the name of the generic UI component, not the React module!
Projects
None yet
6 participants