@wavemaker-ai/app-runtime-wm-build 12.0.2-rc.344 → 12.1.0-rc.347

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@wavemaker-ai/app-runtime-wm-build",
3
- "version": "12.0.2-rc.344",
3
+ "version": "12.1.0-rc.347",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "@wavemaker-ai/app-runtime-wm-build",
9
- "version": "12.0.2-rc.344",
9
+ "version": "12.1.0-rc.347",
10
10
  "license": "MIT",
11
11
  "engines": {
12
12
  "node": ">=18.16.1",
package/package-lock.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@wavemaker-ai/app-runtime-wm-build",
3
- "version": "12.0.2-rc.344",
3
+ "version": "12.1.0-rc.347",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "@wavemaker-ai/app-runtime-wm-build",
9
- "version": "12.0.2-rc.344",
9
+ "version": "12.1.0-rc.347",
10
10
  "license": "MIT",
11
11
  "engines": {
12
12
  "node": ">=18.16.1",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wavemaker-ai/app-runtime-wm-build",
3
- "version": "12.0.2-rc.344",
3
+ "version": "12.1.0-rc.347",
4
4
  "description": "All modules required for a wavemaker application.",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -0,0 +1,73 @@
1
+ //! moment.js locale configuration
2
+ //! locale : Amharic (Ethiopia) [am-et]
3
+ //! author : Tekle Ayele : https://github.com/tekleayele
4
+
5
+ ;(function (global, factory) {
6
+ typeof exports === 'object' && typeof module !== 'undefined'
7
+ && typeof require === 'function' ? factory(require('../moment')) :
8
+ typeof define === 'function' && define.amd ? define(['../moment'], factory) :
9
+ factory(global.moment)
10
+ }(this, (function (moment) { 'use strict';
11
+
12
+ //! moment.js locale configuration
13
+
14
+ var amEt = moment.defineLocale('am-et', {
15
+ months: 'ጃንዩወሪ_ፌብሩወሪ_ማርች_ኤፕሪል_ሜይ_ጁን_ጁላይ_ኦገስት_ሴፕቴምበር_ኦክቶበር_ኖቬምበር_ዲሴምበር'.split(
16
+ '_'
17
+ ),
18
+ monthsShort: 'ጃን_ፌብ_ማር_ኤፕር_ሜይ_ጁን_ጁላይ_ኦገ_ሴፕ_ኦክቶ_ኖቬ_ዲሴ'.split('_'),
19
+ weekdays: 'እሑድ_ሰኞ_ማክሰኞ_እሮብ_ሀሙስ_ዓርብ_ቅዳሜ'.split('_'),
20
+ weekdaysShort: 'እሑ_ሰኞ_ማክ_እሮ_ሀሙ_ዓር_ቅዳ'.split('_'),
21
+ weekdaysMin: 'እሁ_ሰ_ማ_እ_ሀ_ዓ_ቅ'.split('_'),
22
+ meridiemParse: /ጥዋት|ከሰዓት/,
23
+ isPM: function (input) {
24
+ return input === 'ከሰዓት';
25
+ },
26
+ meridiem: function (hours) {
27
+ return hours < 12 ? 'ጥዋት' : 'ከሰዓት';
28
+ },
29
+ longDateFormat: {
30
+ LT: 'h:mm A',
31
+ LTS: 'h:mm:ss A',
32
+ L: 'DD/MM/YYYY',
33
+ LL: 'D MMMM YYYY',
34
+ LLL: 'D MMMM YYYY h:mm A',
35
+ LLLL: 'dddd, D MMMM YYYY h:mm A',
36
+ },
37
+ calendar: {
38
+ sameDay: '[ዛሬ በ] LT',
39
+ nextDay: '[ነገ በ] LT',
40
+ nextWeek: 'dddd [በ] LT',
41
+ lastDay: '[ትናንትና በ] LT',
42
+ lastWeek: '[ያለፈው ሳምንት] dddd [በ] LT',
43
+ sameElse: 'L',
44
+ },
45
+ relativeTime: {
46
+ future: '%s ውስጥ',
47
+ past: '%s በፊት',
48
+ s: 'ጥቂት ሰከንዶች',
49
+ ss: '%d ሰከንዶች',
50
+ m: 'አንድ ደቂቃ',
51
+ mm: '%d ደቂቃዎች',
52
+ h: 'አንድ ሰአት',
53
+ hh: '%d ሰአታት',
54
+ d: 'አንድ ቀን',
55
+ dd: '%d ቀናት',
56
+ M: 'አንድ ወር',
57
+ MM: '%d ወራት',
58
+ y: 'አንድ ዓመት',
59
+ yy: '%d ዓመታት',
60
+ },
61
+ dayOfMonthOrdinalParse: /\d{1,2}(ኛ)/,
62
+ ordinal: function (number) {
63
+ return number + 'ኛ';
64
+ },
65
+ week: {
66
+ dow: 0, // Sunday is the first day of the week.
67
+ doy: 6, // The week that contains Jan 1st is the first week of the year.
68
+ },
69
+ });
70
+
71
+ return amEt;
72
+
73
+ })));
@@ -10,6 +10,8 @@
10
10
  }(this, (function (moment) { 'use strict';
11
11
 
12
12
  //! moment.js locale configuration
13
+ // Language contact person : Abdoufata Kane : https://github.com/abdoufata
14
+
13
15
 
14
16
  var bm = moment.defineLocale('bm', {
15
17
  months: 'Zanwuyekalo_Fewuruyekalo_Marisikalo_Awirilikalo_Mɛkalo_Zuwɛnkalo_Zuluyekalo_Utikalo_Sɛtanburukalo_ɔkutɔburukalo_Nowanburukalo_Desanburukalo'.split(
@@ -17,7 +17,7 @@
17
17
  'gener_febrer_març_abril_maig_juny_juliol_agost_setembre_octubre_novembre_desembre'.split(
18
18
  '_'
19
19
  ),
20
- format: "de gener_de febrer_de març_d'abril_de maig_de juny_de juliol_d'agost_de setembre_d'octubre_de novembre_de desembre".split(
20
+ format: 'de gener_de febrer_de març_d’abril_de maig_de juny_de juliol_d’agost_de setembre_d’octubre_de novembre_de desembre'.split(
21
21
  '_'
22
22
  ),
23
23
  isFormat: /D[oD]?(\s)+MMMM/,
@@ -14,6 +14,23 @@
14
14
 
15
15
  //! moment.js locale configuration
16
16
 
17
+ var monthsParse = [
18
+ /^jän/i,
19
+ /^feb/i,
20
+ /^mär/i,
21
+ /^apr/i,
22
+ /^mai/i,
23
+ /^jun/i,
24
+ /^jul/i,
25
+ /^aug/i,
26
+ /^sep/i,
27
+ /^okt/i,
28
+ /^nov/i,
29
+ /^dez/i,
30
+ ],
31
+ monthsRegex =
32
+ /^(Jänner|Februar|März|April|Mai|Juni|Juli|August|September|Oktober|November|Dezember|Jän\.?|Feb\.?|Mär\.?|Apr\.?|Jun\.?|Jul\.?|Aug\.?|Sep\.?|Okt\.?|Nov\.?|Dez\.?)/i;
33
+
17
34
  function processRelativeTime(number, withoutSuffix, key, isFuture) {
18
35
  var format = {
19
36
  m: ['eine Minute', 'einer Minute'],
@@ -35,7 +52,18 @@
35
52
  ),
36
53
  monthsShort:
37
54
  'Jän._Feb._März_Apr._Mai_Juni_Juli_Aug._Sep._Okt._Nov._Dez.'.split('_'),
38
- monthsParseExact: true,
55
+
56
+ monthsRegex: monthsRegex,
57
+ monthsShortRegex: monthsRegex,
58
+ monthsStrictRegex:
59
+ /^(Jänner|Februar|März|April|Mai|Juni|Juli|August|September|Oktober|November|Dezember)/i,
60
+ monthsShortStrictRegex:
61
+ /^(Jän\.?|Feb\.?|März|Mär\.?|Apr\.?|Mai|Juni|Jun\.?|Juli|Jul\.?|Aug\.?|Sep\.?|Okt\.?|Nov\.?|Dez\.?)/i,
62
+
63
+ monthsParse: monthsParse,
64
+ longMonthsParse: monthsParse,
65
+ shortMonthsParse: monthsParse,
66
+
39
67
  weekdays:
40
68
  'Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag'.split(
41
69
  '_'
@@ -11,6 +11,23 @@
11
11
 
12
12
  //! moment.js locale configuration
13
13
 
14
+ var monthsParse = [
15
+ /^jan/i,
16
+ /^feb/i,
17
+ /^mär/i,
18
+ /^apr/i,
19
+ /^mai/i,
20
+ /^jun/i,
21
+ /^jul/i,
22
+ /^aug/i,
23
+ /^sep/i,
24
+ /^okt/i,
25
+ /^nov/i,
26
+ /^dez/i,
27
+ ],
28
+ monthsRegex =
29
+ /^(Januar|Februar|März|April|Mai|Juni|Juli|August|September|Oktober|November|Dezember|Jan\.?|Feb\.?|Mär\.?|Apr\.?|Jun\.?|Jul\.?|Aug\.?|Sep\.?|Okt\.?|Nov\.?|Dez\.?)/i;
30
+
14
31
  function processRelativeTime(number, withoutSuffix, key, isFuture) {
15
32
  var format = {
16
33
  m: ['eine Minute', 'einer Minute'],
@@ -32,7 +49,18 @@
32
49
  ),
33
50
  monthsShort:
34
51
  'Jan._Feb._März_Apr._Mai_Juni_Juli_Aug._Sep._Okt._Nov._Dez.'.split('_'),
35
- monthsParseExact: true,
52
+
53
+ monthsRegex: monthsRegex,
54
+ monthsShortRegex: monthsRegex,
55
+ monthsStrictRegex:
56
+ /^(Januar|Februar|März|April|Mai|Juni|Juli|August|September|Oktober|November|Dezember)/i,
57
+ monthsShortStrictRegex:
58
+ /^(Jan\.?|Feb\.?|März|Mär\.?|Apr\.?|Mai|Juni|Jun\.?|Juli|Jul\.?|Aug\.?|Sep\.?|Okt\.?|Nov\.?|Dez\.?)/i,
59
+
60
+ monthsParse: monthsParse,
61
+ longMonthsParse: monthsParse,
62
+ shortMonthsParse: monthsParse,
63
+
36
64
  weekdays:
37
65
  'Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag'.split(
38
66
  '_'
@@ -13,6 +13,23 @@
13
13
 
14
14
  //! moment.js locale configuration
15
15
 
16
+ var monthsParse = [
17
+ /^jan/i,
18
+ /^feb/i,
19
+ /^mär/i,
20
+ /^apr/i,
21
+ /^mai/i,
22
+ /^jun/i,
23
+ /^jul/i,
24
+ /^aug/i,
25
+ /^sep/i,
26
+ /^okt/i,
27
+ /^nov/i,
28
+ /^dez/i,
29
+ ],
30
+ monthsRegex =
31
+ /^(Januar|Februar|März|April|Mai|Juni|Juli|August|September|Oktober|November|Dezember|Jan\.?|Feb\.?|Mär\.?|Apr\.?|Jun\.?|Jul\.?|Aug\.?|Sep\.?|Okt\.?|Nov\.?|Dez\.?)/i;
32
+
16
33
  function processRelativeTime(number, withoutSuffix, key, isFuture) {
17
34
  var format = {
18
35
  m: ['eine Minute', 'einer Minute'],
@@ -34,7 +51,18 @@
34
51
  ),
35
52
  monthsShort:
36
53
  'Jan._Feb._März_Apr._Mai_Juni_Juli_Aug._Sep._Okt._Nov._Dez.'.split('_'),
37
- monthsParseExact: true,
54
+
55
+ monthsRegex: monthsRegex,
56
+ monthsShortRegex: monthsRegex,
57
+ monthsStrictRegex:
58
+ /^(Januar|Februar|März|April|Mai|Juni|Juli|August|September|Oktober|November|Dezember)/i,
59
+ monthsShortStrictRegex:
60
+ /^(Jan\.?|Feb\.?|März|Mär\.?|Apr\.?|Mai|Juni|Jun\.?|Juli|Jul\.?|Aug\.?|Sep\.?|Okt\.?|Nov\.?|Dez\.?)/i,
61
+
62
+ monthsParse: monthsParse,
63
+ longMonthsParse: monthsParse,
64
+ shortMonthsParse: monthsParse,
65
+
38
66
  weekdays:
39
67
  'Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag'.split(
40
68
  '_'
@@ -22,9 +22,9 @@
22
22
  ? 'néhány másodperc'
23
23
  : 'néhány másodperce';
24
24
  case 'ss':
25
- return num + (isFuture || withoutSuffix)
26
- ? ' másodperc'
27
- : ' másodperce';
25
+ return (
26
+ num + (isFuture || withoutSuffix ? ' másodperc' : ' másodperce')
27
+ );
28
28
  case 'm':
29
29
  return 'egy' + (isFuture || withoutSuffix ? ' perc' : ' perce');
30
30
  case 'mm':
@@ -12,11 +12,22 @@
12
12
 
13
13
  //! moment.js locale configuration
14
14
 
15
+ var monthsParse = [],
16
+ longMonthsParse = [],
17
+ shortMonthsParse = [];
18
+
19
+ monthsParse[7] = /^agustus|^agu|^agt/i;
20
+ longMonthsParse[7] = /^agustus$/i;
21
+ shortMonthsParse[7] = /^agu$|^agt$/i;
22
+
15
23
  var id = moment.defineLocale('id', {
16
24
  months: 'Januari_Februari_Maret_April_Mei_Juni_Juli_Agustus_September_Oktober_November_Desember'.split(
17
25
  '_'
18
26
  ),
19
- monthsShort: 'Jan_Feb_Mar_Apr_Mei_Jun_Jul_Agt_Sep_Okt_Nov_Des'.split('_'),
27
+ monthsShort: 'Jan_Feb_Mar_Apr_Mei_Jun_Jul_Agu_Sep_Okt_Nov_Des'.split('_'),
28
+ monthsParse: monthsParse,
29
+ longMonthsParse: longMonthsParse,
30
+ shortMonthsParse: shortMonthsParse,
20
31
  weekdays: 'Minggu_Senin_Selasa_Rabu_Kamis_Jumat_Sabtu'.split('_'),
21
32
  weekdaysShort: 'Min_Sen_Sel_Rab_Kam_Jum_Sab'.split('_'),
22
33
  weekdaysMin: 'Mg_Sn_Sl_Rb_Km_Jm_Sb'.split('_'),
@@ -31,7 +31,7 @@
31
31
  longDateFormat: {
32
32
  LT: 'HH:mm',
33
33
  LTS: 'HH:mm:ss',
34
- L: 'DD/MM/YYYY',
34
+ L: 'DD.MM.YYYY',
35
35
  LL: 'D MMMM YYYY',
36
36
  LLL: 'D MMMM YYYY HH:mm',
37
37
  LLLL: 'dddd, D MMMM YYYY HH:mm',
@@ -11,7 +11,6 @@
11
11
  }(this, (function (moment) { 'use strict';
12
12
 
13
13
  //! moment.js locale configuration
14
-
15
14
  var mk = moment.defineLocale('mk', {
16
15
  months: 'јануари_февруари_март_април_мај_јуни_јули_август_септември_октомври_ноември_декември'.split(
17
16
  '_'
@@ -66,7 +66,7 @@
66
66
  longDateFormat: {
67
67
  LT: 'HH:mm',
68
68
  LTS: 'HH:mm:ss',
69
- L: 'DD/MM/YYYY',
69
+ L: 'D/MM/YYYY',
70
70
  LL: 'D MMMM YYYY',
71
71
  LLL: 'D MMMM YYYY HH:mm',
72
72
  LLLL: 'dddd D MMMM YYYY HH:mm',
@@ -62,7 +62,7 @@
62
62
  months: function (momentToFormat, format) {
63
63
  if (!momentToFormat) {
64
64
  return monthsNominative;
65
- } else if (/D MMMM/.test(format)) {
65
+ } else if (/D\.? MMMM/.test(format)) {
66
66
  return monthsSubjective[momentToFormat.month()];
67
67
  } else {
68
68
  return monthsNominative[momentToFormat.month()];
@@ -0,0 +1,188 @@
1
+ //! moment.js locale configuration
2
+ //! locale : Pashto [ps]
3
+ //! author : Hanif Hefaz : https://github.com/hanifhefaz
4
+
5
+ ;(function (global, factory) {
6
+ typeof exports === 'object' && typeof module !== 'undefined'
7
+ && typeof require === 'function' ? factory(require('../moment')) :
8
+ typeof define === 'function' && define.amd ? define(['../moment'], factory) :
9
+ factory(global.moment)
10
+ }(this, (function (moment) { 'use strict';
11
+
12
+ //! moment.js locale configuration
13
+
14
+ var symbolMap = {
15
+ 1: '۱',
16
+ 2: '۲',
17
+ 3: '۳',
18
+ 4: '۴',
19
+ 5: '۵',
20
+ 6: '۶',
21
+ 7: '۷',
22
+ 8: '۸',
23
+ 9: '۹',
24
+ 0: '۰',
25
+ },
26
+ numberMap = {
27
+ '۱': '1',
28
+ '۲': '2',
29
+ '۳': '3',
30
+ '۴': '4',
31
+ '۵': '5',
32
+ '۶': '6',
33
+ '۷': '7',
34
+ '۸': '8',
35
+ '۹': '9',
36
+ '۰': '0',
37
+ },
38
+ months = {
39
+ format: 'جنوري_فبروري_مارچ_اپریل_مۍ_جون_جولای_اګست_سېپتمبر_اکتوبر_نومبر_دسمبر'.split(
40
+ '_'
41
+ ),
42
+ standalone:
43
+ 'جنوري_فېبروري_مارچ_اپریل_مۍ_جون_جولای_اګست_سپتمبر_اکتوبر_نومبر_دسمبر'.split(
44
+ '_'
45
+ ),
46
+ isFormat: /D[oD]?(\[[^\[\]]*\]|\s|,)+MMMM?/,
47
+ },
48
+ monthsShort = {
49
+ format: 'جنوري_فبروري_مارچ_اپریل_مۍ_جون_جولای_اګست_سېپتمبر_اکتوبر_نومبر_دسمبر'.split(
50
+ '_'
51
+ ),
52
+ standalone:
53
+ 'جنوري_فبروري_مارچ_اپریل_مۍ_جون_جولای_اګست_سپتمبر_اکتوبر_نومبر_دسمبر'.split(
54
+ '_'
55
+ ),
56
+ },
57
+ monthsParse = [
58
+ /^جنوري$/i,
59
+ /^(فبروري|فېبروري)$/i,
60
+ /^مارچ$/i,
61
+ /^اپریل$/i,
62
+ /^مۍ$/i,
63
+ /^جون$/i,
64
+ /^جولای$/i,
65
+ /^اګست$/i,
66
+ /^(سپتمبر|سېپتمبر)$/i,
67
+ /^اکتوبر$/i,
68
+ /^نومبر$/i,
69
+ /^دسمبر$/i,
70
+ ],
71
+ monthsRegex =
72
+ /^(جنوري|فبروري|فېبروري|مارچ|اپریل|مۍ|جون|جولای|اګست|سپتمبر|سېپتمبر|اکتوبر|نومبر|دسمبر)/i;
73
+
74
+ function relativeTime(number, withoutSuffix, key, isFuture) {
75
+ var format =
76
+ isFuture && !withoutSuffix
77
+ ? {
78
+ s: 'څو ثانيو',
79
+ ss: '%d ثانيو',
80
+ m: 'يوه دقيقه',
81
+ mm: '%d دقيقو',
82
+ h: 'يو ساعت',
83
+ hh: '%d ساعتو',
84
+ d: 'يوه ورځ',
85
+ dd: '%d ورځو',
86
+ M: 'يوه مياشت',
87
+ MM: '%d مياشتو',
88
+ y: 'يو کال',
89
+ yy: '%d کالونو',
90
+ }
91
+ : {
92
+ s: 'څو ثانيې',
93
+ ss: '%d ثانيې',
94
+ m: 'يوه دقيقه',
95
+ mm: '%d دقيقې',
96
+ h: 'يو ساعت',
97
+ hh: '%d ساعتونه',
98
+ d: 'يوه ورځ',
99
+ dd: '%d ورځې',
100
+ M: 'يوه مياشت',
101
+ MM: '%d مياشتې',
102
+ y: 'يو کال',
103
+ yy: '%d کاله',
104
+ };
105
+
106
+ return format[key].replace('%d', number);
107
+ }
108
+
109
+ var ps = moment.defineLocale('ps', {
110
+ months: months,
111
+ monthsShort: monthsShort,
112
+ monthsParse: monthsParse,
113
+ longMonthsParse: monthsParse,
114
+ shortMonthsParse: monthsParse,
115
+ monthsRegex: monthsRegex,
116
+ monthsShortRegex: monthsRegex,
117
+ monthsStrictRegex: monthsRegex,
118
+ monthsShortStrictRegex: monthsRegex,
119
+ weekdays: 'یکشنبه_دوشنبه_سه شنبه_چهارشنبه_پنج شنبه_جمعه_شنبه'.split('_'),
120
+ weekdaysShort: 'یکشنبه_دوشنبه_سه شنبه_چهارشنبه_پنج شنبه_جمعه_شنبه'.split(
121
+ '_'
122
+ ),
123
+ weekdaysMin: 'ی_د_س_چ_پ_ج_ش'.split('_'),
124
+ weekdaysParseExact: true,
125
+ longDateFormat: {
126
+ LT: 'H:mm',
127
+ LTS: 'H:mm:ss',
128
+ L: 'YYYY/M/D',
129
+ LL: 'D MMMM YYYY',
130
+ LLL: 'D MMMM YYYY H:mm',
131
+ LLLL: 'dddd D, MMMM, YYYY [په] H:mm',
132
+ },
133
+ meridiemParse: /غ\.م|غ\.و\./,
134
+ isPM: function (input) {
135
+ return input === 'غ.و.';
136
+ },
137
+ meridiem: function (hour) {
138
+ return hour < 12 ? 'غ.م' : 'غ.و.';
139
+ },
140
+ calendar: {
141
+ sameDay: '[نن په] LT',
142
+ nextDay: '[سبا په] LT',
143
+ nextWeek: 'dddd [په] LT',
144
+ lastDay: '[پرون په] LT',
145
+ lastWeek: 'dddd [په] LT',
146
+ sameElse: 'L',
147
+ },
148
+ relativeTime: {
149
+ future: 'په %s کې',
150
+ past: '%s مخکې',
151
+ s: relativeTime,
152
+ ss: relativeTime,
153
+ m: relativeTime,
154
+ mm: relativeTime,
155
+ h: relativeTime,
156
+ hh: relativeTime,
157
+ d: relativeTime,
158
+ dd: relativeTime,
159
+ M: relativeTime,
160
+ MM: relativeTime,
161
+ y: relativeTime,
162
+ yy: relativeTime,
163
+ },
164
+ preparse: function (string) {
165
+ return string
166
+ .replace(/[۰-۹]/g, function (match) {
167
+ return numberMap[match];
168
+ })
169
+ .replace(/،/g, ',');
170
+ },
171
+ postformat: function (string) {
172
+ return string
173
+ .replace(/\d/g, function (match) {
174
+ return symbolMap[match];
175
+ })
176
+ .replace(/,/g, '،');
177
+ },
178
+ dayOfMonthOrdinalParse: /\d{1,2}/,
179
+ ordinal: '%d',
180
+ week: {
181
+ dow: 6, // Saturday is the first day of the week.
182
+ doy: 12, // The week that contains Jan 12th is the first week of the year.
183
+ },
184
+ });
185
+
186
+ return ps;
187
+
188
+ })));
@@ -32,14 +32,22 @@
32
32
  LLLL: 'dddd, D [de] MMMM [de] YYYY [às] HH:mm',
33
33
  },
34
34
  calendar: {
35
- sameDay: '[Hoje às] LT',
36
- nextDay: '[Amanhã às] LT',
37
- nextWeek: 'dddd [às] LT',
38
- lastDay: '[Ontem às] LT',
35
+ sameDay: function () {
36
+ return '[Hoje ' + (this.hours() >= 2 ? 'às' : 'à') + '] LT';
37
+ },
38
+ nextDay: function () {
39
+ return '[Amanhã ' + (this.hours() >= 2 ? 'às' : 'à') + '] LT';
40
+ },
41
+ nextWeek: function () {
42
+ return 'dddd [' + (this.hours() >= 2 ? 'às' : 'à') + '] LT';
43
+ },
44
+ lastDay: function () {
45
+ return '[Ontem ' + (this.hours() >= 2 ? 'às' : 'à') + '] LT';
46
+ },
39
47
  lastWeek: function () {
40
48
  return this.day() === 0 || this.day() === 6
41
- ? '[Último] dddd [às] LT' // Saturday + Sunday
42
- : '[Última] dddd [às] LT'; // Monday - Friday
49
+ ? '[Último] dddd [' + (this.hours() >= 2 ? 'às' : 'à') + '] LT' // Saturday + Sunday
50
+ : '[Última] dddd [' + (this.hours() >= 2 ? 'às' : 'à') + '] LT'; // Monday - Friday
43
51
  },
44
52
  sameElse: 'L',
45
53
  },
@@ -17,7 +17,7 @@
17
17
  ),
18
18
  monthsShort: 'jan_feb_mar_apr_maj_jun_jul_aug_sep_okt_nov_dec'.split('_'),
19
19
  weekdays: 'söndag_måndag_tisdag_onsdag_torsdag_fredag_lördag'.split('_'),
20
- weekdaysShort: 'sön_mån_tis_ons_tor_fre_lör'.split('_'),
20
+ weekdaysShort: 'sön_mån_tis_ons_tors_fre_lör'.split('_'),
21
21
  weekdaysMin: 'sö_må_ti_on_to_fr_lö'.split('_'),
22
22
  longDateFormat: {
23
23
  LT: 'HH:mm',
@@ -11,6 +11,46 @@
11
11
 
12
12
  //! moment.js locale configuration
13
13
 
14
+ var relativeTime = {
15
+ ss: 'sekunde %d',
16
+ m: 'dakika moja',
17
+ mm: 'dakika %d',
18
+ h: 'saa moja',
19
+ hh: 'saa %d',
20
+ d: 'siku moja',
21
+ dd: 'siku %d',
22
+ M: 'mwezi mmoja',
23
+ MM: 'miezi %d',
24
+ y: 'mwaka mmoja',
25
+ yy: 'miaka %d',
26
+ };
27
+
28
+ function relativeTimeWithSuffix(number, withoutSuffix, key, isFuture) {
29
+ var output = relativeTime[key].replace(/%d/i, number);
30
+
31
+ if (withoutSuffix || isFuture) {
32
+ return output;
33
+ }
34
+
35
+ switch (key) {
36
+ case 'ss':
37
+ case 'mm':
38
+ case 'hh':
39
+ case 'dd':
40
+ return output + (number === 1 ? ' iliyopita' : ' zilizopita');
41
+ case 'm':
42
+ case 'h':
43
+ case 'd':
44
+ return output + ' iliyopita';
45
+ case 'M':
46
+ case 'y':
47
+ return output + ' uliopita';
48
+ case 'MM':
49
+ case 'yy':
50
+ return output + ' iliyopita';
51
+ }
52
+ }
53
+
14
54
  var sw = moment.defineLocale('sw', {
15
55
  months: 'Januari_Februari_Machi_Aprili_Mei_Juni_Julai_Agosti_Septemba_Oktoba_Novemba_Desemba'.split(
16
56
  '_'
@@ -34,26 +74,28 @@
34
74
  calendar: {
35
75
  sameDay: '[leo saa] LT',
36
76
  nextDay: '[kesho saa] LT',
37
- nextWeek: '[wiki ijayo] dddd [saat] LT',
77
+ nextWeek: 'dddd [ijayo saa] LT',
38
78
  lastDay: '[jana] LT',
39
- lastWeek: '[wiki iliyopita] dddd [saat] LT',
79
+ lastWeek: 'dddd [iliyopita saa] LT',
40
80
  sameElse: 'L',
41
81
  },
42
82
  relativeTime: {
43
83
  future: '%s baadaye',
44
- past: 'tokea %s',
84
+ past: function (output) {
85
+ return output === 'hivi punde' ? 'tokea ' + output : output;
86
+ },
45
87
  s: 'hivi punde',
46
- ss: 'sekunde %d',
47
- m: 'dakika moja',
48
- mm: 'dakika %d',
49
- h: 'saa limoja',
50
- hh: 'masaa %d',
51
- d: 'siku moja',
52
- dd: 'siku %d',
53
- M: 'mwezi mmoja',
54
- MM: 'miezi %d',
55
- y: 'mwaka mmoja',
56
- yy: 'miaka %d',
88
+ ss: relativeTimeWithSuffix,
89
+ m: relativeTimeWithSuffix,
90
+ mm: relativeTimeWithSuffix,
91
+ h: relativeTimeWithSuffix,
92
+ hh: relativeTimeWithSuffix,
93
+ d: relativeTimeWithSuffix,
94
+ dd: relativeTimeWithSuffix,
95
+ M: relativeTimeWithSuffix,
96
+ MM: relativeTimeWithSuffix,
97
+ y: relativeTimeWithSuffix,
98
+ yy: relativeTimeWithSuffix,
57
99
  },
58
100
  week: {
59
101
  dow: 1, // Monday is the first day of the week.