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(core): fix default i18n calendar used, infer it from locale if possible #9878

Merged
merged 2 commits into from
Feb 22, 2024

Conversation

slorber
Copy link
Collaborator

@slorber slorber commented Feb 22, 2024

Motivation

Fix bad default for the i18n calendar we use to format dates.

The previous default was most often always gregory even for locales not supporting gregory calendars (unless the user uses a locale that contains the calendar, which is unlikely)

Test Plan

Fix existing unit test: locale: "fa" locale should have calendar: "persian" by default instead of calendar: "gregory"

@slorber slorber added pr: bug fix This PR fixes a bug in a past release. to backport This PR is planned to be backported to a stable version of Docusaurus labels Feb 22, 2024
@facebook-github-bot facebook-github-bot added the CLA Signed Signed Facebook CLA label Feb 22, 2024
Copy link

netlify bot commented Feb 22, 2024

[V2]

Name Link
🔨 Latest commit b42ed3f
🔍 Latest deploy log https://app.netlify.com/sites/docusaurus-2/deploys/65d76d67708b9e00084a3068
😎 Deploy Preview https://deploy-preview-9878--docusaurus-2.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

github-actions bot commented Feb 22, 2024

⚡️ Lighthouse report for the deploy preview of this PR

URL Performance Accessibility Best Practices SEO PWA Report
/ 🟠 71 🟢 98 🟢 96 🟢 100 🟠 88 Report
/docs/installation 🟠 89 🟢 96 🟢 100 🟢 100 🟠 88 Report
/docs/category/getting-started 🟠 75 🟢 100 🟢 100 🟢 90 🟠 88 Report
/blog 🟠 70 🟢 100 🟢 100 🟢 90 🟠 88 Report
/blog/preparing-your-site-for-docusaurus-v3 🟠 63 🟢 96 🟢 100 🟢 100 🟠 88 Report
/blog/tags/release 🟠 70 🟢 100 🟢 100 🟠 80 🟠 88 Report
/blog/tags 🟠 76 🟢 100 🟢 100 🟢 90 🟠 88 Report

Copy link

Size Change: 0 B

Total Size: 992 kB

ℹ️ View Unchanged
Filename Size
website/.docusaurus/globalData.json 75.4 kB
website/build/assets/css/styles.********.css 114 kB
website/build/assets/js/main.********.js 765 kB
website/build/index.html 37.9 kB

compressed-size-action

@slorber slorber merged commit 6bf21d2 into main Feb 22, 2024
31 checks passed
@slorber slorber deleted the slorber/i18n-infer-default-calendar branch February 22, 2024 16:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed Signed Facebook CLA pr: bug fix This PR fixes a bug in a past release. to backport This PR is planned to be backported to a stable version of Docusaurus
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants