Fix: Mongolian date format fallback to en-US

mn-MN locale is not supported in most browsers, causing dates to
display in Korean format. Changed to use en-US for Mongolian users.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
AutonetSellCar Deploy
2025-12-30 19:41:48 +09:00
parent 215a3aa880
commit 898ab3a0eb
2 changed files with 6 additions and 4 deletions

View File

@@ -56,11 +56,12 @@ export default function FindMyCarPage() {
loadVehicles();
}, [user, language]);
// Format date
// Format date (mn uses en-US as mn-MN is not supported in most browsers)
const formatDate = (dateString: string | null | undefined) => {
if (!dateString) return '-';
const date = new Date(dateString);
return date.toLocaleDateString(language === 'ko' ? 'ko-KR' : language === 'mn' ? 'mn-MN' : language === 'ru' ? 'ru-RU' : 'en-US', {
const locale = language === 'ko' ? 'ko-KR' : language === 'ru' ? 'ru-RU' : 'en-US';
return date.toLocaleDateString(locale, {
year: 'numeric',
month: 'long',
day: 'numeric',

View File

@@ -50,10 +50,11 @@ export default function MyRequestPage() {
loadRequests();
}, [user, language]);
// Format date
// Format date (mn uses en-US as mn-MN is not supported in most browsers)
const formatDate = (dateString: string) => {
const date = new Date(dateString);
return date.toLocaleDateString(language === 'ko' ? 'ko-KR' : language === 'mn' ? 'mn-MN' : language === 'ru' ? 'ru-RU' : 'en-US', {
const locale = language === 'ko' ? 'ko-KR' : language === 'ru' ? 'ru-RU' : 'en-US';
return date.toLocaleDateString(locale, {
year: 'numeric',
month: 'long',
day: 'numeric',