2016-02-06 04:42:48 +08:00
|
|
|
|
//! moment.js locale configuration
|
2020-11-11 09:34:26 +08:00
|
|
|
|
//! locale : Bengali [bn]
|
|
|
|
|
//! author : Kaushik Gandhi : https://github.com/kaushikgandhi
|
2016-02-06 04:42:48 +08:00
|
|
|
|
|
|
|
|
|
;(function (global, factory) {
|
|
|
|
|
typeof exports === 'object' && typeof module !== 'undefined'
|
|
|
|
|
&& typeof require === 'function' ? factory(require('../moment')) :
|
2017-04-20 12:24:20 +08:00
|
|
|
|
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
2016-02-06 04:42:48 +08:00
|
|
|
|
factory(global.moment)
|
2017-04-20 12:24:20 +08:00
|
|
|
|
}(this, (function (moment) { 'use strict';
|
2016-02-06 04:42:48 +08:00
|
|
|
|
|
2020-11-11 09:34:26 +08:00
|
|
|
|
//! moment.js locale configuration
|
2014-08-21 02:41:50 +08:00
|
|
|
|
|
2018-04-26 15:15:53 +08:00
|
|
|
|
var symbolMap = {
|
2020-11-11 09:34:26 +08:00
|
|
|
|
1: '১',
|
|
|
|
|
2: '২',
|
|
|
|
|
3: '৩',
|
|
|
|
|
4: '৪',
|
|
|
|
|
5: '৫',
|
|
|
|
|
6: '৬',
|
|
|
|
|
7: '৭',
|
|
|
|
|
8: '৮',
|
|
|
|
|
9: '৯',
|
|
|
|
|
0: '০',
|
|
|
|
|
},
|
|
|
|
|
numberMap = {
|
|
|
|
|
'১': '1',
|
|
|
|
|
'২': '2',
|
|
|
|
|
'৩': '3',
|
|
|
|
|
'৪': '4',
|
|
|
|
|
'৫': '5',
|
|
|
|
|
'৬': '6',
|
|
|
|
|
'৭': '7',
|
|
|
|
|
'৮': '8',
|
|
|
|
|
'৯': '9',
|
|
|
|
|
'০': '0',
|
|
|
|
|
};
|
2018-04-26 15:15:53 +08:00
|
|
|
|
|
|
|
|
|
var bn = moment.defineLocale('bn', {
|
2020-11-11 09:34:26 +08:00
|
|
|
|
months: 'জানুয়ারি_ফেব্রুয়ারি_মার্চ_এপ্রিল_মে_জুন_জুলাই_আগস্ট_সেপ্টেম্বর_অক্টোবর_নভেম্বর_ডিসেম্বর'.split(
|
|
|
|
|
'_'
|
|
|
|
|
),
|
2022-04-12 01:27:24 +08:00
|
|
|
|
monthsShort:
|
|
|
|
|
'জানু_ফেব্রু_মার্চ_এপ্রিল_মে_জুন_জুলাই_আগস্ট_সেপ্ট_অক্টো_নভে_ডিসে'.split(
|
|
|
|
|
'_'
|
|
|
|
|
),
|
2020-11-11 09:34:26 +08:00
|
|
|
|
weekdays: 'রবিবার_সোমবার_মঙ্গলবার_বুধবার_বৃহস্পতিবার_শুক্রবার_শনিবার'.split(
|
|
|
|
|
'_'
|
|
|
|
|
),
|
|
|
|
|
weekdaysShort: 'রবি_সোম_মঙ্গল_বুধ_বৃহস্পতি_শুক্র_শনি'.split('_'),
|
|
|
|
|
weekdaysMin: 'রবি_সোম_মঙ্গল_বুধ_বৃহ_শুক্র_শনি'.split('_'),
|
|
|
|
|
longDateFormat: {
|
|
|
|
|
LT: 'A h:mm সময়',
|
|
|
|
|
LTS: 'A h:mm:ss সময়',
|
|
|
|
|
L: 'DD/MM/YYYY',
|
|
|
|
|
LL: 'D MMMM YYYY',
|
|
|
|
|
LLL: 'D MMMM YYYY, A h:mm সময়',
|
|
|
|
|
LLLL: 'dddd, D MMMM YYYY, A h:mm সময়',
|
2018-04-26 15:15:53 +08:00
|
|
|
|
},
|
2020-11-11 09:34:26 +08:00
|
|
|
|
calendar: {
|
|
|
|
|
sameDay: '[আজ] LT',
|
|
|
|
|
nextDay: '[আগামীকাল] LT',
|
|
|
|
|
nextWeek: 'dddd, LT',
|
|
|
|
|
lastDay: '[গতকাল] LT',
|
|
|
|
|
lastWeek: '[গত] dddd, LT',
|
|
|
|
|
sameElse: 'L',
|
2018-04-26 15:15:53 +08:00
|
|
|
|
},
|
2020-11-11 09:34:26 +08:00
|
|
|
|
relativeTime: {
|
|
|
|
|
future: '%s পরে',
|
|
|
|
|
past: '%s আগে',
|
|
|
|
|
s: 'কয়েক সেকেন্ড',
|
|
|
|
|
ss: '%d সেকেন্ড',
|
|
|
|
|
m: 'এক মিনিট',
|
|
|
|
|
mm: '%d মিনিট',
|
|
|
|
|
h: 'এক ঘন্টা',
|
|
|
|
|
hh: '%d ঘন্টা',
|
|
|
|
|
d: 'এক দিন',
|
|
|
|
|
dd: '%d দিন',
|
|
|
|
|
M: 'এক মাস',
|
|
|
|
|
MM: '%d মাস',
|
|
|
|
|
y: 'এক বছর',
|
|
|
|
|
yy: '%d বছর',
|
2018-04-26 15:15:53 +08:00
|
|
|
|
},
|
|
|
|
|
preparse: function (string) {
|
|
|
|
|
return string.replace(/[১২৩৪৫৬৭৮৯০]/g, function (match) {
|
|
|
|
|
return numberMap[match];
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
postformat: function (string) {
|
|
|
|
|
return string.replace(/\d/g, function (match) {
|
|
|
|
|
return symbolMap[match];
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
meridiemParse: /রাত|সকাল|দুপুর|বিকাল|রাত/,
|
2020-11-11 09:34:26 +08:00
|
|
|
|
meridiemHour: function (hour, meridiem) {
|
2018-04-26 15:15:53 +08:00
|
|
|
|
if (hour === 12) {
|
|
|
|
|
hour = 0;
|
|
|
|
|
}
|
2020-11-11 09:34:26 +08:00
|
|
|
|
if (
|
|
|
|
|
(meridiem === 'রাত' && hour >= 4) ||
|
|
|
|
|
(meridiem === 'দুপুর' && hour < 5) ||
|
|
|
|
|
meridiem === 'বিকাল'
|
|
|
|
|
) {
|
2018-04-26 15:15:53 +08:00
|
|
|
|
return hour + 12;
|
|
|
|
|
} else {
|
|
|
|
|
return hour;
|
|
|
|
|
}
|
|
|
|
|
},
|
2020-11-11 09:34:26 +08:00
|
|
|
|
meridiem: function (hour, minute, isLower) {
|
2018-04-26 15:15:53 +08:00
|
|
|
|
if (hour < 4) {
|
|
|
|
|
return 'রাত';
|
|
|
|
|
} else if (hour < 10) {
|
|
|
|
|
return 'সকাল';
|
|
|
|
|
} else if (hour < 17) {
|
|
|
|
|
return 'দুপুর';
|
|
|
|
|
} else if (hour < 20) {
|
|
|
|
|
return 'বিকাল';
|
|
|
|
|
} else {
|
|
|
|
|
return 'রাত';
|
|
|
|
|
}
|
|
|
|
|
},
|
2020-11-11 09:34:26 +08:00
|
|
|
|
week: {
|
|
|
|
|
dow: 0, // Sunday is the first day of the week.
|
|
|
|
|
doy: 6, // The week that contains Jan 6th is the first week of the year.
|
|
|
|
|
},
|
2018-04-26 15:15:53 +08:00
|
|
|
|
});
|
2016-02-06 04:42:48 +08:00
|
|
|
|
|
2018-04-26 15:15:53 +08:00
|
|
|
|
return bn;
|
2016-02-06 04:42:48 +08:00
|
|
|
|
|
2017-04-20 12:24:20 +08:00
|
|
|
|
})));
|