EASYAIuniappNewUI/node_modules/dayjs/esm/locale/bn.js
2025-02-08 18:50:38 +08:00

72 lines
2.2 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

// Bengali [bn]
import dayjs from '../index';
var symbolMap = {
1: '১',
2: '২',
3: '৩',
4: '',
5: '৫',
6: '৬',
7: '',
8: '৮',
9: '৯',
0: ''
};
var numberMap = {
'১': '1',
'২': '2',
'৩': '3',
'': '4',
'৫': '5',
'৬': '6',
'': '7',
'৮': '8',
'৯': '9',
'': '0'
};
var locale = {
name: 'bn',
weekdays: 'রবিবার_সোমবার_মঙ্গলবার_বুধবার_বৃহস্পতিবার_শুক্রবার_শনিবার'.split('_'),
months: 'ি_ফি_ম_এপি_ম_জ_জ_আগস_সবর_অকবর_নভবর_ডিবর'.split('_'),
weekdaysShort: 'রবি_স_মঙগল_ব_বহসপতি_শ_শনি'.split('_'),
monthsShort: '_ফ_ম_এপি_ম_জ_জ_আগস_স_অক_নভ_ডি'.split('_'),
weekdaysMin: 'রবি_স_মঙ_ব_ব_শ_শনি'.split('_'),
preparse: function preparse(string) {
return string.replace(/[১২৩৪৫৬৭৮৯০]/g, function (match) {
return numberMap[match];
});
},
postformat: function postformat(string) {
return string.replace(/\d/g, function (match) {
return symbolMap[match];
});
},
ordinal: function ordinal(n) {
return n;
},
formats: {
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 সময়'
},
relativeTime: {
future: '%s পর',
past: '%s আগ',
s: 'কয় ',
m: 'এক িি',
mm: '%d িি',
h: 'এক ঘন',
hh: '%d ঘন',
d: 'এক ি',
dd: '%d ি',
M: 'এক ',
MM: '%d ',
y: 'এক বছর',
yy: '%d বছর'
}
};
dayjs.locale(locale, null, true);
export default locale;