X-Git-Url: https://git.heureux-cyclage.org/?p=lhc%2Fweb%2Fwiklou.git;a=blobdiff_plain;f=resources%2Flib%2Fmoment%2Flocale%2Fel.js;h=588cb235c89cdca115bbb7b32dbb8b305e157251;hp=a0e1695e3f64be937c3a397b356b4aa195dc0a6a;hb=49748181dd56ec97e7ba7c13e684a16abceb3cc0;hpb=320e4c56132681f811c2819e3e22e98715f46ae7 diff --git a/resources/lib/moment/locale/el.js b/resources/lib/moment/locale/el.js index a0e1695e3f..588cb235c8 100644 --- a/resources/lib/moment/locale/el.js +++ b/resources/lib/moment/locale/el.js @@ -1,19 +1,20 @@ -// moment.js locale configuration -// locale : modern greek (el) -// author : Aggelos Karalias : https://github.com/mehiel +//! moment.js locale configuration +//! locale : Greek [el] +//! author : Aggelos Karalias : https://github.com/mehiel -(function (factory) { - // Comment out broken wrapper, see T145382 - /*if (typeof define === 'function' && define.amd) { - define(['moment'], factory); // AMD - } else if (typeof exports === 'object') { - module.exports = factory(require('../moment')); // Node - } else { - factory((typeof global !== 'undefined' ? global : this).moment); // node or other global - }*/ - factory(this.moment); -}(function (moment) { - return moment.defineLocale('el', { +;(function (global, factory) { + typeof exports === 'object' && typeof module !== 'undefined' + && typeof require === 'function' ? factory(require('../moment')) : + typeof define === 'function' && define.amd ? define(['../moment'], factory) : + factory(global.moment) +}(this, function (moment) { 'use strict'; + + function isFunction(input) { + return input instanceof Function || Object.prototype.toString.call(input) === '[object Function]'; + } + + + var el = moment.defineLocale('el', { monthsNominativeEl : 'Ιανουάριος_Φεβρουάριος_Μάρτιος_Απρίλιος_Μάιος_Ιούνιος_Ιούλιος_Αύγουστος_Σεπτέμβριος_Οκτώβριος_Νοέμβριος_Δεκέμβριος'.split('_'), monthsGenitiveEl : 'Ιανουαρίου_Φεβρουαρίου_Μαρτίου_Απριλίου_Μαΐου_Ιουνίου_Ιουλίου_Αυγούστου_Σεπτεμβρίου_Οκτωβρίου_Νοεμβρίου_Δεκεμβρίου'.split('_'), months : function (momentToFormat, format) { @@ -43,8 +44,8 @@ LTS : 'h:mm:ss A', L : 'DD/MM/YYYY', LL : 'D MMMM YYYY', - LLL : 'D MMMM YYYY LT', - LLLL : 'dddd, D MMMM YYYY LT' + LLL : 'D MMMM YYYY h:mm A', + LLLL : 'dddd, D MMMM YYYY h:mm A' }, calendarEl : { sameDay : '[Σήμερα {}] LT', @@ -64,11 +65,9 @@ calendar : function (key, mom) { var output = this._calendarEl[key], hours = mom && mom.hours(); - - if (typeof output === 'function') { + if (isFunction(output)) { output = output.apply(mom); } - return output.replace('{}', (hours % 12 === 1 ? 'στη' : 'στις')); }, relativeTime : { @@ -93,4 +92,7 @@ doy : 4 // The week that contains Jan 4st is the first week of the year. } }); -})); + + return el; + +})); \ No newline at end of file