UNPKG

2.2 kBJavaScriptView Raw
1//! moment.js locale configuration
2//! locale : Urdu [ur]
3//! author : Sawood Alam : https://github.com/ibnesayeed
4//! author : Zack : https://github.com/ZackVision
5
6import moment from '../moment';
7
8var months = [
9 'جنوری',
10 'فروری',
11 'مارچ',
12 'اپریل',
13 'مئی',
14 'جون',
15 'جولائی',
16 'اگست',
17 'ستمبر',
18 'اکتوبر',
19 'نومبر',
20 'دسمبر',
21 ],
22 days = ['اتوار', 'پیر', 'منگل', 'بدھ', 'جمعرات', 'جمعہ', 'ہفتہ'];
23
24export default moment.defineLocale('ur', {
25 months: months,
26 monthsShort: months,
27 weekdays: days,
28 weekdaysShort: days,
29 weekdaysMin: days,
30 longDateFormat: {
31 LT: 'HH:mm',
32 LTS: 'HH:mm:ss',
33 L: 'DD/MM/YYYY',
34 LL: 'D MMMM YYYY',
35 LLL: 'D MMMM YYYY HH:mm',
36 LLLL: 'dddd، D MMMM YYYY HH:mm',
37 },
38 meridiemParse: /صبح|شام/,
39 isPM: function (input) {
40 return 'شام' === input;
41 },
42 meridiem: function (hour, minute, isLower) {
43 if (hour < 12) {
44 return 'صبح';
45 }
46 return 'شام';
47 },
48 calendar: {
49 sameDay: '[آج بوقت] LT',
50 nextDay: '[کل بوقت] LT',
51 nextWeek: 'dddd [بوقت] LT',
52 lastDay: '[گذشتہ روز بوقت] LT',
53 lastWeek: '[گذشتہ] dddd [بوقت] LT',
54 sameElse: 'L',
55 },
56 relativeTime: {
57 future: '%s بعد',
58 past: '%s قبل',
59 s: 'چند سیکنڈ',
60 ss: '%d سیکنڈ',
61 m: 'ایک منٹ',
62 mm: '%d منٹ',
63 h: 'ایک گھنٹہ',
64 hh: '%d گھنٹے',
65 d: 'ایک دن',
66 dd: '%d دن',
67 M: 'ایک ماہ',
68 MM: '%d ماہ',
69 y: 'ایک سال',
70 yy: '%d سال',
71 },
72 preparse: function (string) {
73 return string.replace(/،/g, ',');
74 },
75 postformat: function (string) {
76 return string.replace(/,/g, '،');
77 },
78 week: {
79 dow: 1, // Monday is the first day of the week.
80 doy: 4, // The week that contains Jan 4th is the first week of the year.
81 },
82});