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

Add Indonesian Translation #379

Merged
merged 2 commits into from
Apr 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docusaurus/docs/intro.md
Original file line number Diff line number Diff line change
Expand Up @@ -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` 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` 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'
Expand Down
2 changes: 2 additions & 0 deletions example/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ import {
el,
ru,
ro,
id,
} from 'react-native-paper-dates'
import { useCallback, useState } from 'react'

Expand All @@ -79,6 +80,7 @@ const locales: [string, TranslationsType][] = [
['el', el],
['ru', ru],
['ro', ro],
['id', id],
]

locales.forEach((locale) => {
Expand Down
1 change: 1 addition & 0 deletions src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,4 @@ export { default as cs } from './translations/cs'
export { default as el } from './translations/el'
export { default as ru } from './translations/ru'
export { default as ro } from './translations/ro'
export { default as id } from './translations/id'
23 changes: 23 additions & 0 deletions src/translations/id.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
import type { TranslationsType } from './utils'

const id: TranslationsType = {
save: 'Simpan',
selectSingle: 'Pilih tanggal',
selectMultiple: 'Pilih tanggal',
selectRange: 'Pilih periode',
notAccordingToDateFormat: (inputFormat) =>
`Format tanggal harus ${inputFormat}`,
mustBeHigherThan: (date) => `Harus lebih besar dari ${date}`,
mustBeLowerThan: (date) => `Harus lebih kecil dari ${date}`,
mustBeBetween: (startDate, endDate) =>
`Harus di antara ${startDate} - ${endDate}`,
dateIsDisabled: 'Hari tidak diperbolehkan',
previous: 'Sebelumnya',
next: 'Berikutnya',
typeInDate: 'Ketik tanggal',
pickDateFromCalendar: 'Pilih tanggal dari kalender',
close: 'Tutup',
minute: 'Menit',
hour: 'Jam',
}
export default id
Loading