Skip to content

fix(input-time-picker): only load valid dayjs locale files and fallback to base lang when region code is unsupported #7049

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

Merged
merged 5 commits into from
May 27, 2023

Conversation

eriklharper
Copy link
Contributor

Related Issue: #7040

Summary

This fixes an issue where setting lang to a locale code with an unsupported region (e.g. nl-nl) failed to fall back to the base language and didn't render the component.

…ck to base lang when region code is unsupported
@eriklharper eriklharper requested a review from a team as a code owner May 26, 2023 22:59
@github-actions github-actions bot added the bug Bug reports for broken functionality. Issues should include a reproduction of the bug. label May 26, 2023
@eriklharper eriklharper requested a review from jcfranco May 26, 2023 23:00
Copy link
Member

@jcfranco jcfranco left a comment

Choose a reason for hiding this comment

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

Looking good! 😎

Copy link
Member

@jcfranco jcfranco left a comment

Choose a reason for hiding this comment

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

Awesome! 🎉

Once this is in place, you no longer need to check if the locale is in the import map since all supported locales are mapped to a corresponding locale config.

This is still pending, but we can tackle that separately.

@eriklharper eriklharper added the pr ready for visual snapshots Adding this label will run visual snapshot testing. label May 26, 2023
@eriklharper eriklharper merged commit d6a99d5 into master May 27, 2023
@eriklharper eriklharper deleted the eriklharper/7040-fix-dayjs-locale-imports branch May 27, 2023 00:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bug reports for broken functionality. Issues should include a reproduction of the bug. pr ready for visual snapshots Adding this label will run visual snapshot testing.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants