Skip to content

[docs] Section for overwriting core components i18n keys #4998

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 8 commits into from
Jun 7, 2022

Conversation

DanailH
Copy link
Member

@DanailH DanailH commented May 24, 2022

Part of #4323
Reference: #4323 (comment)

Preview: https://deploy-preview-4998--material-ui-x.netlify.app/x/react-data-grid/localization/#translation-keys

The goal is to add a section that explains that since the grid uses MUI Core components some translation keys need to be accessed through the MUI Core component.

@DanailH DanailH added the docs Improvements or additions to the documentation label May 24, 2022
@DanailH DanailH self-assigned this May 24, 2022
@mui-bot
Copy link

mui-bot commented May 24, 2022

These are the results for the performance tests:

Test case Unit Min Max Median Mean σ
Filter 100k rows ms 251.9 467.1 333.7 338.16 80.036
Sort 100k rows ms 471.5 901.1 750.8 731.32 145.893
Select 100k rows ms 119.5 198.7 169.4 158.84 28.809
Deselect 100k rows ms 114.6 230 173 168.12 43.452

Generated by 🚫 dangerJS against a2f344f

@@ -17,6 +17,22 @@ In the following example, the labels of the density selector are customized.

{{"demo": "CustomLocaleTextGrid.js", "bg": "inline"}}

> ⚠️ It's important to note that because the data grid uses components from the Material UI Core library some translation keys need to be accessed using that component key.
Copy link
Member

Choose a reason for hiding this comment

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

I'm not aware we ever reference it this way

Suggested change
> ⚠️ It's important to note that because the data grid uses components from the Material UI Core library some translation keys need to be accessed using that component key.
> ⚠️ It's important to note that because the data grid uses components from the Material UI library some translation keys need to be accessed using that component key.

Copy link
Member

Choose a reason for hiding this comment

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

Also, I think that we should use specialized callouts mui/material-ui#32402.

@siriwatknp did we ever announce the change to the other teams? I believe we didn't, maybe we should?

Copy link
Member

Choose a reason for hiding this comment

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

Yes I need to do a PR to replace all our notes to the new callouts synthax.

Copy link
Member

Choose a reason for hiding this comment

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

Copy link
Member Author

@DanailH DanailH May 25, 2022

Choose a reason for hiding this comment

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

So the correct one we should use is :::info?

Copy link
Member Author

Choose a reason for hiding this comment

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

I'm not aware we ever reference it this way

We never explicitly said it. I think the initial assumption was that people will use the theme to overwrite those texts but if you want to use the localeText only then this is the way.

Copy link
Member

@oliviertassinari oliviertassinari left a comment

Choose a reason for hiding this comment

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

Fixes #4323

I thought #4323 was a duplicate of #409. What's the relationship between this PR and the issue? I mean why does it close it? Maybe it should be more: "Pain point surfaced in #4323".

DanailH and others added 5 commits May 25, 2022 14:39

Partially verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
We cannot verify signatures from co-authors, and some of the co-authors attributed to this commit require their commits to be signed.
Co-authored-by: Olivier Tassinari <olivier.tassinari@gmail.com>

Partially verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
We cannot verify signatures from co-authors, and some of the co-authors attributed to this commit require their commits to be signed.
Co-authored-by: Olivier Tassinari <olivier.tassinari@gmail.com>
…ilH/material-ui-x into fix/docs-i18n-for-nested-components
Copy link
Member

@cherniavskii cherniavskii left a comment

Choose a reason for hiding this comment

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

LGTM

DanailH and others added 2 commits June 7, 2022 12:31

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Co-authored-by: Matheus Wichman <matheushw@outlook.com>
@DanailH DanailH merged commit 26d94e6 into mui:master Jun 7, 2022
joserodolfofreitas pushed a commit to joserodolfofreitas/mui-x that referenced this pull request Jun 13, 2022
alexfauquette pushed a commit to alexfauquette/mui-x that referenced this pull request Aug 26, 2022

Unverified

This commit is not signed, but one or more authors requires that any commit attributed to them is signed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Improvements or additions to the documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants