From 9532f266c98ca092926e31ce696607bb53be7440 Mon Sep 17 00:00:00 2001 From: Boaz Date: Wed, 26 Feb 2020 12:57:15 +0200 Subject: [PATCH] [l10n] Add Hebrew (he-IL) locale (#19850) --- .../pages/guides/localization/localization.md | 1 + packages/material-ui/src/locale/index.d.ts | 1 + packages/material-ui/src/locale/index.js | 50 +++++++++++++++++++ 3 files changed, 52 insertions(+) diff --git a/docs/src/pages/guides/localization/localization.md b/docs/src/pages/guides/localization/localization.md index 948c9b35a5182a..2215f04bb98302 100644 --- a/docs/src/pages/guides/localization/localization.md +++ b/docs/src/pages/guides/localization/localization.md @@ -39,6 +39,7 @@ const theme = createMuiTheme({ | Finnish | fi-FI | `fiFI` | | French | fr-FR | `frFR` | | German | de-DE | `deDE` | +| Hebrew | he-IL | `heIL` | | Hungarian | hu-HU | `huHU` | | Icelandic | is-IS | `isIS` | | Indonesian | id-ID | `idID` | diff --git a/packages/material-ui/src/locale/index.d.ts b/packages/material-ui/src/locale/index.d.ts index b8c407e954b970..10a8b356dfe30e 100644 --- a/packages/material-ui/src/locale/index.d.ts +++ b/packages/material-ui/src/locale/index.d.ts @@ -9,6 +9,7 @@ export const etEE: object; export const faIR: object; export const fiFI: object; export const frFR: object; +export const heIL: object; export const huHU: object; export const hyAM: object; export const idID: object; diff --git a/packages/material-ui/src/locale/index.js b/packages/material-ui/src/locale/index.js index ce9108dc7235f0..801bffb0906b63 100644 --- a/packages/material-ui/src/locale/index.js +++ b/packages/material-ui/src/locale/index.js @@ -144,6 +144,9 @@ export const deDE = { export const enUS = { /** props: { + MuiBreadcrumbs: { + expandText: 'Show path', + }, MuiTablePagination: { backIconButtonText: 'Previous page', labelRowsPerPage: 'Rows per page:', @@ -164,6 +167,27 @@ export const enUS = { MuiAlert: { closeText: 'Close', }, + MuiPagination: { + 'aria-label': 'Pagination navigation', + getItemAriaLabel: (type, page, selected) => { + if (type === 'page') { + return `${selected ? '' : 'Go to '}page ${page}`; + } + if (type === 'first') { + return 'Go to first page'; + } + if (type === 'last') { + return 'Go to last page'; + } + if (type === 'next') { + return 'Go to next page'; + } + if (type === 'previous') { + return 'Go to previous page'; + } + return undefined; + }, + }, }, */ }; @@ -338,6 +362,32 @@ export const frFR = { }, }; +export const heIL = { + props: { + MuiTablePagination: { + backIconButtonText: 'העמוד הקודם', + labelRowsPerPage: 'שורות בעמוד:', + labelDisplayedRows: ({ from, to, count }) => + `${from}-${to === -1 ? count : to} מתוך ${count}`, + nextIconButtonText: 'העמוד הבא', + }, + MuiRating: { + getLabelText: value => `${value} כוכב${value !== 1 ? 'ים' : ''}`, + emptyLabelText: 'ריק', + }, + MuiAutocomplete: { + clearText: 'נקה', + closeText: 'סגור', + loadingText: 'טוען…', + noOptionsText: 'אין אופציות', + openText: 'פתח', + }, + MuiAlert: { + closeText: 'סגור', + }, + }, +}; + export const huHU = { props: { MuiTablePagination: {