Skip to content

Commit d6870df

Browse files
Merge pull request #228 from alphazed110/feature/add-fa-ir-locale
feat(i18n): add fa-IR locale support
2 parents 9a214fe + 0f89e63 commit d6870df

File tree

5 files changed

+64
-2
lines changed

5 files changed

+64
-2
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ type File = {
116116
| `height` | string \| number | The height of the component `default: 600px`. Can be a string (e.g., `'100%'`, `'10rem'`) or a number (in pixels). |
117117
| `initialPath` | string | The path of the directory to be loaded initially e.g. `/Documents`. This should be the path of a folder which is included in `files` array. Default value is `""` |
118118
| `isLoading` | boolean | A boolean state indicating whether the application is currently performing an operation, such as creating, renaming, or deleting a file/folder. Displays a loading state if set `true`. |
119-
| `language` | string | A language code used for translations (e.g., `"en-US"`, `"fr-FR"`, `"tr-TR"`). Defaults to `"en-US"` for English. Allows the user to set the desired translation language manually. <br><br>**Available languages:** <br> 🇸🇦 `ar-SA` (Arabic, Saudi Arabia) <br> 🇩🇪 `de-DE` (German, Germany) <br> 🇺🇸 `en-US` (English, United States) <br> 🇪🇸 `es-ES` (Spanish, Spain) <br> 🇫🇷 `fr-FR` (French, France) <br> 🇮🇱 `he-IL` (Hebrew, Israel) <br> 🇮🇳 `hi-IN` (Hindi, India) <br> 🇮🇹 `it-IT` (Italian, Italy) <br> 🇯🇵 `ja-JP` (Japanese, Japan) <br> 🇰🇷 `ko-KR` (Korean, South Korea) <br> 🇧🇷 `pt-BR` (Portuguese, Brazil) <br> 🇵🇹 `pt-PT` (Portuguese, Portugal) <br> 🇷🇺 `ru-RU` (Russian, Russia) <br> 🇹🇷 `tr-TR` (Turkish, Turkey) <br> 🇺🇦 `uk-UA` (Ukrainian, Ukraine) <br> 🇵🇰 `ur-UR` (Urdu, Pakistan) <br> 🇻🇳 `vi-VN` (Vietnamese, Vietnam) <br> 🇨🇳 `zh-CN` (Chinese, Simplified) <br> 🇵🇱 `pl-PL` (Polish, Poland) |
119+
| `language` | string | A language code used for translations (e.g., `"en-US"`, `"fr-FR"`, `"tr-TR"`). Defaults to `"en-US"` for English. Allows the user to set the desired translation language manually. <br><br>**Available languages:** <br> 🇸🇦 `ar-SA` (Arabic, Saudi Arabia) <br> 🇩🇪 `de-DE` (German, Germany) <br> 🇺🇸 `en-US` (English, United States) <br> 🇪🇸 `es-ES` (Spanish, Spain) <br> 🇮🇷 `fa-IR` (Persian, Iran) <br> 🇫🇷 `fr-FR` (French, France) <br> 🇮🇱 `he-IL` (Hebrew, Israel) <br> 🇮🇳 `hi-IN` (Hindi, India) <br> 🇮🇹 `it-IT` (Italian, Italy) <br> 🇯🇵 `ja-JP` (Japanese, Japan) <br> 🇰🇷 `ko-KR` (Korean, South Korea) <br> 🇧🇷 `pt-BR` (Portuguese, Brazil) <br> 🇵🇹 `pt-PT` (Portuguese, Portugal) <br> 🇷🇺 `ru-RU` (Russian, Russia) <br> 🇹🇷 `tr-TR` (Turkish, Turkey) <br> 🇺🇦 `uk-UA` (Ukrainian, Ukraine) <br> 🇵🇰 `ur-UR` (Urdu, Pakistan) <br> 🇻🇳 `vi-VN` (Vietnamese, Vietnam) <br> 🇨🇳 `zh-CN` (Chinese, Simplified) <br> 🇵🇱 `pl-PL` (Polish, Poland) |
120120
| `layout` | "list" \| "grid" | Specifies the default layout style for the file manager. Can be either "list" or "grid". Default value is "grid". |
121121
| `maxFileSize` | number | For limiting the maximum upload file size in bytes. |
122122
| `onCopy` | (files: Array<[File](#-file-structure)>) => void | (Optional) A callback function triggered when one or more files or folders are copied providing copied files as an argument. Use this function to perform custom actions on copy event. |

frontend/CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
# [1.32.0](https://github.com/Saifullah-dev/react-file-manager/compare/v1.31.0...v1.32.0) (2025-10-19)
2+
3+
### 🧩 Internationalization (i18n)
4+
5+
- **Added:** Persian (Iran) locale support (`fa-IR`)
6+
17
# [1.30.0](https://github.com/Saifullah-dev/react-file-manager/compare/v1.27.0...v1.30.0) (2025-10-07)
28

39
### 🧩 Internationalization (i18n)

frontend/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ type File = {
114114
| `height` | string \| number | The height of the component `default: 600px`. Can be a string (e.g., `'100%'`, `'10rem'`) or a number (in pixels). |
115115
| `initialPath` | string | The path of the directory to be loaded initially e.g. `/Documents`. This should be the path of a folder which is included in `files` array. Default value is `""` |
116116
| `isLoading` | boolean | A boolean state indicating whether the application is currently performing an operation, such as creating, renaming, or deleting a file/folder. Displays a loading state if set `true`. |
117-
| `language` | string | A language code used for translations (e.g., `"en-US"`, `"fr-FR"`, `"tr-TR"`). Defaults to `"en-US"` for English. Allows the user to set the desired translation language manually. <br><br>**Available languages:** <br> 🇸🇦 `ar-SA` (Arabic, Saudi Arabia) <br> 🇩🇪 `de-DE` (German, Germany) <br> 🇺🇸 `en-US` (English, United States) <br> 🇪🇸 `es-ES` (Spanish, Spain) <br> 🇫🇷 `fr-FR` (French, France) <br> 🇮🇱 `he-IL` (Hebrew, Israel) <br> 🇮🇳 `hi-IN` (Hindi, India) <br> 🇮🇹 `it-IT` (Italian, Italy) <br> 🇯🇵 `ja-JP` (Japanese, Japan) <br> 🇰🇷 `ko-KR` (Korean, South Korea) <br> 🇧🇷 `pt-BR` (Portuguese, Brazil) <br> 🇵🇹 `pt-PT` (Portuguese, Portugal) <br> 🇷🇺 `ru-RU` (Russian, Russia) <br> 🇹🇷 `tr-TR` (Turkish, Turkey) <br> 🇺🇦 `uk-UA` (Ukrainian, Ukraine) <br> 🇵🇰 `ur-UR` (Urdu, Pakistan) <br> 🇻🇳 `vi-VN` (Vietnamese, Vietnam) <br> 🇨🇳 `zh-CN` (Chinese, Simplified) <br> 🇵🇱 `pl-PL` (Polish, Poland) |
117+
| `language` | string | A language code used for translations (e.g., `"en-US"`, `"fr-FR"`, `"tr-TR"`). Defaults to `"en-US"` for English. Allows the user to set the desired translation language manually. <br><br>**Available languages:** <br> 🇸🇦 `ar-SA` (Arabic, Saudi Arabia) <br> 🇩🇪 `de-DE` (German, Germany) <br> 🇺🇸 `en-US` (English, United States) <br> 🇪🇸 `es-ES` (Spanish, Spain) <br> 🇮🇷 `fa-IR` (Persian, Iran) <br> 🇫🇷 `fr-FR` (French, France) <br> 🇮🇱 `he-IL` (Hebrew, Israel) <br> 🇮🇳 `hi-IN` (Hindi, India) <br> 🇮🇹 `it-IT` (Italian, Italy) <br> 🇯🇵 `ja-JP` (Japanese, Japan) <br> 🇰🇷 `ko-KR` (Korean, South Korea) <br> 🇧🇷 `pt-BR` (Portuguese, Brazil) <br> 🇵🇹 `pt-PT` (Portuguese, Portugal) <br> 🇷🇺 `ru-RU` (Russian, Russia) <br> 🇹🇷 `tr-TR` (Turkish, Turkey) <br> 🇺🇦 `uk-UA` (Ukrainian, Ukraine) <br> 🇵🇰 `ur-UR` (Urdu, Pakistan) <br> 🇻🇳 `vi-VN` (Vietnamese, Vietnam) <br> 🇨🇳 `zh-CN` (Chinese, Simplified) <br> 🇵🇱 `pl-PL` (Polish, Poland) |
118118
| `layout` | "list" \| "grid" | Specifies the default layout style for the file manager. Can be either "list" or "grid". Default value is "grid". |
119119
| `maxFileSize` | number | For limiting the maximum upload file size in bytes. |
120120
| `onCopy` | (files: Array<[File](#-file-structure)>) => void | (Optional) A callback function triggered when one or more files or folders are copied providing copied files as an argument. Use this function to perform custom actions on copy event. |

frontend/src/i18n.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import arSA from "./locales/ar-SA.json";
33
import deDE from "./locales/de-DE.json";
44
import enUS from "./locales/en-US.json";
55
import esES from "./locales/es-ES.json";
6+
import faIR from "./locales/fa-IR.json";
67
import frFR from "./locales/fr-FR.json";
78
import heIL from "./locales/he-IL.json";
89
import hiIN from "./locales/hi-IN.json";
@@ -24,6 +25,7 @@ const resources = {
2425
"de-DE": { translation: deDE },
2526
"en-US": { translation: enUS },
2627
"es-ES": { translation: esES },
28+
"fa-IR": { translation: faIR },
2729
"fr-FR": { translation: frFR },
2830
"he-IL": { translation: heIL },
2931
"hi-IN": { translation: hiIN },

frontend/src/locales/fa-IR.json

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
{
2+
"newFolder": "پوشه جدید",
3+
"upload": "بارگذاری",
4+
"paste": "الحاق",
5+
"changeView": "تغییر نمایش",
6+
"refresh": "بازخوانی",
7+
"cut": "برش",
8+
"copy": "کپی",
9+
"rename": "تغییر نام",
10+
"download": "دانلود",
11+
"delete": "حذف",
12+
"itemSelected": "مورد انتخاب شده",
13+
"itemsSelected": "مورد انتخاب شده",
14+
"cancel": "لغو",
15+
"clearSelection": "پاک کردن انتخاب",
16+
"completed": "تکمیل شد",
17+
"fileNameChangeWarning": "اگر پسوند نام فایل را تغییر دهید، ممکن است فایل غیرقابل استفاده شود. آیا مطمئن هستید که می‌خواهید آن را تغییر دهید؟",
18+
"no": "خیر",
19+
"yes": "بله",
20+
"close": "بستن",
21+
"fileTypeNotAllowed": "نوع فایل مجاز نیست.",
22+
"fileAlreadyExist": "فایل از قبل موجود است.",
23+
"maxUploadSize": "حداکثر اندازه بارگذاری",
24+
"dragFileToUpload": "فایل‌ها را برای بارگذاری بکشید",
25+
"chooseFile": "انتخاب فایل",
26+
"uploadFail": "بارگذاری ناموفق بود.",
27+
"uploading": "در حال بارگذاری",
28+
"uploaded": "بارگذاری شد",
29+
"remove": "حذف",
30+
"abortUpload": "لغو بارگذاری",
31+
"preview": "پیش‌نمایش",
32+
"previewUnavailable": "متأسفیم! پیش‌نمایش برای این فایل در دسترس نیست.",
33+
"home": "خانه",
34+
"showMoreFolder": "نمایش پوشه‌های بیشتر",
35+
"moveTo": "انتقال به",
36+
"folderEmpty": "این پوشه خالی است.",
37+
"selectAll": "انتخاب همه",
38+
"view": "نمایش",
39+
"grid": "شبکه‌ای",
40+
"list": "لیستی",
41+
"open": "باز کردن",
42+
"nothingHereYet": "هنوز چیزی اینجا نیست",
43+
"name": "نام",
44+
"modified": "تغییر یافته",
45+
"size": "اندازه",
46+
"deleteItemConfirm": "آیا مطمئن هستید که می‌خواهید \"{{fileName}}\" را حذف کنید؟",
47+
"deleteItemsConfirm": "آیا مطمئن هستید که می‌خواهید این {{count}} مورد را حذف کنید؟",
48+
"percentDone": "{{percent}}% انجام شد",
49+
"canceled": "لغو شد",
50+
"invalidFileName": "نام فایل نمی‌تواند شامل هیچ یک از کاراکترهای زیر باشد: \\ / : * ? \" < > |",
51+
"folderExists": "این مقصد از قبل شامل پوشه‌ای به نام \"{{renameFile}}\" است.",
52+
"collapseNavigationPane": "بستن پنل ناوبری",
53+
"expandNavigationPane": "باز کردن پنل ناوبری"
54+
}

0 commit comments

Comments
 (0)