Skip to content
Open
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
12 changes: 12 additions & 0 deletions public/intl/messages/fa-IR.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
"behavior": "رفتار",
"block-selector": "انتخابگر بلوک",
"boards": "بردها",
"board-type": "نوع برد",
"bounce-rate": "نرخ ریزش",
"breakdown": "تفکیک",
"browser": "مرورگر",
Expand Down Expand Up @@ -201,6 +202,7 @@
"number-of-records": "{x} {x, plural, one {رکورد} other {رکورد}}",
"ok": "تایید",
"online": "آنلاین",
Comment thread
mamal72 marked this conversation as resolved.
"open": "ترکیبی",
"organic-search": "جستجوی ارگانیک",
"organic-shopping": "خرید ارگانیک",
"organic-social": "شبکه اجتماعی ارگانیک",
Expand Down Expand Up @@ -256,6 +258,7 @@
"replay": "پخش مجدد",
"replay-enabled": "پخش مجدد فعال",
"replay-id": "Replay ID",
"replay-code": "کد پخش مجدد نشست",
"replays": "پخش‌های مجدد",
"reports": "گزارش‌ها",
"required": "ضروری",
Expand All @@ -272,6 +275,7 @@
"sample-size": "اندازه نمونه",
"save": "ذخیره",
"save-cohort": "ذخیره گروه",
"save-replay": "ذخیره پخش مجدد",
"save-segment": "ذخیره بخش",
"screen": "صفحه نمایش",
"screens": "صفحه",
Expand All @@ -282,6 +286,8 @@
"select-component": "یک کامپوننت انتخاب کنید",
"select-date": "انتخاب تاریخ",
"select-filter": "انتخاب فیلتر",
"select-link": "انتخاب لینک",
"select-pixel": "انتخاب پیکسل",
"select-role": "انتخاب نقش",
"select-website": "انتخاب وب‌سایت",
"session": "نشست",
Expand Down Expand Up @@ -338,8 +344,12 @@
"unique-events": "رویدادهای یکتا",
"unique-visitors": "بازدیدکننده‌های یکتا",
"uniqueCustomers": "مشتریان یکتا",
"customers": "مشتریان",
"orders": "سفارش‌ها",
"saved": "ذخیره شد",
"unknown": "ناشناخته",
"untitled": "بدون عنوان",
"upgrade": "ارتقاء",
"update": "به‌روزرسانی",
"url": "URL",
"user": "کاربر",
Expand Down Expand Up @@ -402,6 +412,7 @@
"reset-website": "برای بازنشانی وب‌سایت، لطفاً {confirmation} را تایپ کنید.",
"reset-website-warning": "تمامی آمارهای این وب‌سایت حذف خواهد شد اما کدهای رهگیری بدون تغییر باقی می‌ماند.",
"saved": "ذخیره شد.",
"select-board-entity-first": "ابتدا یک وب‌سایت، پیکسل یا لینک انتخاب کنید.",
"select-component-preview": "یک کامپوننت برای پیش‌نمایش انتخاب کنید",
"select-website-first": "ابتدا یک وب‌سایت انتخاب کنید",
"sever-error": "خطای سرور",
Expand All @@ -415,6 +426,7 @@
"transfer-website": "مالکیت وب‌سایت را به حساب خودت یا یک تیم دیگر منتقل کنید.",
"triggered-event": "رویداد فعال شده",
"unauthorized": "غیرمجاز",
"upgrade-required": "این قابلیت نیاز به اشتراک پلن {plan} دارد.",
"user-deleted": "کاربر حذف شد.",
"viewed-page": "صفحه مشاهده شد",
"visitor-log": "بازدیدکننده از کشور <b>{country}</b> با مروگر <b>{browser}</b> در <b>{os}</b> <b>{device}</b>"
Expand Down
7 changes: 5 additions & 2 deletions src/components/hooks/useLocale.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ export function useLocale() {

setItem(LOCALE_CONFIG, value);

document.getElementById('__next')?.setAttribute('dir', getTextDirection(value));

if (locale !== value) {
setLocale(value);
} else {
Expand All @@ -47,6 +45,11 @@ export function useLocale() {
}
}, [locale]);

useEffect(() => {
document.documentElement.lang = locale.split('-')[0];
document.documentElement.setAttribute('dir', getTextDirection(locale));
}, [locale]);

useEffect(() => {
const url = new URL(window?.location?.href);
const locale = url.searchParams.get('locale');
Expand Down
1 change: 1 addition & 0 deletions src/lib/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -693,6 +693,7 @@ export const CURRENCIES = [
{ id: 'TND', name: 'Tunisian Dinar' },
{ id: 'OMR', name: 'Omani Rial' },
{ id: 'GHS', name: 'Ghanaian Cedi' },
{ id: 'IRR', name: 'Iranian Rial' },
];

export const TIMEZONE_LEGACY: Record<string, string> = {
Expand Down