1 |
|
2 |
|
3 |
|
4 |
|
5 |
|
6 | ;(function (global, factory) {
|
7 | typeof exports === 'object' && typeof module !== 'undefined'
|
8 | && typeof require === 'function' ? factory(require('../moment')) :
|
9 | typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
10 | factory(global.moment)
|
11 | }(this, (function (moment) { 'use strict';
|
12 |
|
13 |
|
14 |
|
15 | var monthsShortDot =
|
16 | 'ene._feb._mar._abr._may._jun._jul._ago._sep._oct._nov._dic.'.split(
|
17 | '_'
|
18 | ),
|
19 | monthsShort = 'ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic'.split('_'),
|
20 | monthsParse = [
|
21 | /^ene/i,
|
22 | /^feb/i,
|
23 | /^mar/i,
|
24 | /^abr/i,
|
25 | /^may/i,
|
26 | /^jun/i,
|
27 | /^jul/i,
|
28 | /^ago/i,
|
29 | /^sep/i,
|
30 | /^oct/i,
|
31 | /^nov/i,
|
32 | /^dic/i,
|
33 | ],
|
34 | monthsRegex =
|
35 | /^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre|ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i;
|
36 |
|
37 | var esUs = moment.defineLocale('es-us', {
|
38 | months: 'enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre'.split(
|
39 | '_'
|
40 | ),
|
41 | monthsShort: function (m, format) {
|
42 | if (!m) {
|
43 | return monthsShortDot;
|
44 | } else if (/-MMM-/.test(format)) {
|
45 | return monthsShort[m.month()];
|
46 | } else {
|
47 | return monthsShortDot[m.month()];
|
48 | }
|
49 | },
|
50 | monthsRegex: monthsRegex,
|
51 | monthsShortRegex: monthsRegex,
|
52 | monthsStrictRegex:
|
53 | /^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre)/i,
|
54 | monthsShortStrictRegex:
|
55 | /^(ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i,
|
56 | monthsParse: monthsParse,
|
57 | longMonthsParse: monthsParse,
|
58 | shortMonthsParse: monthsParse,
|
59 | weekdays: 'domingo_lunes_martes_miércoles_jueves_viernes_sábado'.split('_'),
|
60 | weekdaysShort: 'dom._lun._mar._mié._jue._vie._sáb.'.split('_'),
|
61 | weekdaysMin: 'do_lu_ma_mi_ju_vi_sá'.split('_'),
|
62 | weekdaysParseExact: true,
|
63 | longDateFormat: {
|
64 | LT: 'h:mm A',
|
65 | LTS: 'h:mm:ss A',
|
66 | L: 'MM/DD/YYYY',
|
67 | LL: 'D [de] MMMM [de] YYYY',
|
68 | LLL: 'D [de] MMMM [de] YYYY h:mm A',
|
69 | LLLL: 'dddd, D [de] MMMM [de] YYYY h:mm A',
|
70 | },
|
71 | calendar: {
|
72 | sameDay: function () {
|
73 | return '[hoy a la' + (this.hours() !== 1 ? 's' : '') + '] LT';
|
74 | },
|
75 | nextDay: function () {
|
76 | return '[mañana a la' + (this.hours() !== 1 ? 's' : '') + '] LT';
|
77 | },
|
78 | nextWeek: function () {
|
79 | return 'dddd [a la' + (this.hours() !== 1 ? 's' : '') + '] LT';
|
80 | },
|
81 | lastDay: function () {
|
82 | return '[ayer a la' + (this.hours() !== 1 ? 's' : '') + '] LT';
|
83 | },
|
84 | lastWeek: function () {
|
85 | return (
|
86 | '[el] dddd [pasado a la' +
|
87 | (this.hours() !== 1 ? 's' : '') +
|
88 | '] LT'
|
89 | );
|
90 | },
|
91 | sameElse: 'L',
|
92 | },
|
93 | relativeTime: {
|
94 | future: 'en %s',
|
95 | past: 'hace %s',
|
96 | s: 'unos segundos',
|
97 | ss: '%d segundos',
|
98 | m: 'un minuto',
|
99 | mm: '%d minutos',
|
100 | h: 'una hora',
|
101 | hh: '%d horas',
|
102 | d: 'un día',
|
103 | dd: '%d días',
|
104 | w: 'una semana',
|
105 | ww: '%d semanas',
|
106 | M: 'un mes',
|
107 | MM: '%d meses',
|
108 | y: 'un año',
|
109 | yy: '%d años',
|
110 | },
|
111 | dayOfMonthOrdinalParse: /\d{1,2}º/,
|
112 | ordinal: '%dº',
|
113 | week: {
|
114 | dow: 0,
|
115 | doy: 6,
|
116 | },
|
117 | });
|
118 |
|
119 | return esUs;
|
120 |
|
121 | })));
|