diff --git a/docusaurus/docs/intro.md b/docusaurus/docs/intro.md index 023374a..19701f3 100644 --- a/docusaurus/docs/intro.md +++ b/docusaurus/docs/intro.md @@ -36,7 +36,7 @@ npm install react-native-paper-dates --save ### Supported -React-Native-Paper-Dates currently supports `ar/ca/de/en/en-GB/es/fr/he/hi/it/ko/nl/pl/pt/tr/zh/zh-TW/cs/el/ru/ro/id/ja/th` translations. Ideally you would do this somewhere before react-native-paper-dates is used. For example, you might add the follow to your `index.js` or `app.js`. +React-Native-Paper-Dates currently supports `ar/ca/de/en/en-GB/es/fr/he/hi/it/ko/nl/pl/pt/tr/zh/zh-TW/cs/el/ru/ro/id/ja/th/ua` translations. Ideally you would do this somewhere before react-native-paper-dates is used. For example, you might add the follow to your `index.js` or `app.js`. ```javascript import { enGB, registerTranslation } from 'react-native-paper-dates' diff --git a/example/app/index.tsx b/example/app/index.tsx index dbd6b5a..670112d 100644 --- a/example/app/index.tsx +++ b/example/app/index.tsx @@ -52,6 +52,7 @@ import { id, ja, th, + ua, } from 'react-native-paper-dates' import { useCallback, useMemo, useState } from 'react' import React from 'react' @@ -83,6 +84,7 @@ const locales: [string, TranslationsType][] = [ ['id', id], ['ja', ja], ['th', th], + ['ua', ua], ] locales.forEach((locale) => { diff --git a/src/index.tsx b/src/index.tsx index 0b5501c..2c00efa 100644 --- a/src/index.tsx +++ b/src/index.tsx @@ -32,3 +32,4 @@ export { default as ro } from './translations/ro' export { default as id } from './translations/id' export { default as ja } from './translations/ja' export { default as th } from './translations/th' +export { default as ua } from './translations/ua' diff --git a/src/translations/ua.ts b/src/translations/ua.ts new file mode 100644 index 0000000..0dc12c3 --- /dev/null +++ b/src/translations/ua.ts @@ -0,0 +1,23 @@ +import type { TranslationsType } from './utils' + +const ukUA: TranslationsType = { + save: 'Зберегти', + selectSingle: 'Оберіть дату', + selectMultiple: 'Оберіть дати', + selectRange: 'Оберіть період', + notAccordingToDateFormat: (inputFormat: string) => + `Формат дати має бути ${inputFormat}`, + mustBeHigherThan: (date: string) => `Має бути пізніше ніж ${date}`, + mustBeLowerThan: (date: string) => `Має бути раніше ніж ${date}`, + mustBeBetween: (startDate: string, endDate: string) => + `Має бути між ${startDate} - ${endDate}`, + dateIsDisabled: 'Цей день не дозволено обирати', + previous: 'Попередній', + next: 'Наступний', + typeInDate: 'Введіть дату', + pickDateFromCalendar: 'Оберіть дату з календаря', + close: 'Закрити', + hour: 'Година', + minute: 'Хвилина', +} +export default ukUA