(fix) Datepicker: Use Globalize 1.0.0

- Update Globalize to 1.0.0-alpha.7
This commit is contained in:
Rafael Xavier de Souza 2014-09-04 15:47:48 -03:00 committed by Felix Nagel
parent 5d044dd88c
commit 7f432eddb0
5 changed files with 598 additions and 459 deletions

View File

@ -283,7 +283,6 @@ grunt.initConfig({
"globalize/globalize.js": "globalize/dist/globalize.js",
"globalize/globalize/date.js": "globalize/dist/globalize/date.js",
"globalize/globalize/message.js": "globalize/dist/globalize/message.js",
"globalize/LICENSE.txt": "globalize/LICENSE.txt",
"qunit/qunit.js": "qunit/qunit/qunit.js",

View File

@ -15,7 +15,7 @@
"jquery-simulate": "1.0.0",
"jshint": "2.4.4",
"qunit": "1.17.1",
"globalize": "1.0.0-alpha.6",
"globalize": "1.0.0-alpha.7",
"jquery-1.7.0": "jquery#1.7.0",
"jquery-1.7.1": "jquery#1.7.1",

View File

@ -1,5 +1,5 @@
/*!
* Globalize v1.0.0-alpha.6
* Globalize v1.0.0-alpha.7
*
* http://github.com/jquery/globalize
*
@ -7,7 +7,7 @@
* Released under the MIT license
* http://jquery.org/license
*
* Date: 2014-09-01T21:32Z
* Date: 2014-09-30T12:31Z
*/
(function( root, factory ) {

File diff suppressed because it is too large Load Diff

View File

@ -1,86 +0,0 @@
/*!
* Globalize v1.0.0-alpha.6
*
* http://github.com/jquery/globalize
*
* Copyright 2010, 2014 jQuery Foundation, Inc. and other contributors
* Released under the MIT license
* http://jquery.org/license
*
* Date: 2014-09-01T21:32Z
*/
(function( root, factory ) {
// UMD returnExports
if ( typeof define === "function" && define.amd ) {
// AMD
define([
"cldr",
"../globalize"
], factory );
} else if ( typeof exports === "object" ) {
// Node, CommonJS
module.exports = factory( require( "cldrjs" ), require( "globalize" ) );
} else {
// Extend global
factory( root.Cldr, root.Globalize );
}
}(this, function( Cldr, Globalize ) {
var alwaysArray = Globalize._alwaysArray,
validateDefaultLocale = Globalize._validateDefaultLocale,
validateParameterPresence = Globalize._validateParameterPresence,
validateParameterType = Globalize._validateParameterType,
validateParameterTypePlainObject = Globalize._validateParameterTypePlainObject;
/**
* .loadTranslations( json )
*
* @json [JSON]
*
* Load translation data.
*/
Globalize.loadTranslations = function( json ) {
var customData = {
"globalize-translations": json
};
validateParameterPresence( json, "json" );
validateParameterTypePlainObject( json, "json" );
Cldr.load( customData );
};
/**
* .translate( path )
*
* @path [String or Array]
*
* Translate item given its path.
*/
Globalize.translate =
Globalize.prototype.translate = function( path ) {
var cldr;
validateParameterPresence( path, "path" );
validateParameterType( path, "path", typeof path === "string" || Array.isArray( path ),
"a String nor an Array" );
path = alwaysArray( path );
cldr = this.cldr;
validateDefaultLocale( cldr );
return cldr.get( [ "globalize-translations/{languageId}" ].concat( path ) );
};
return Globalize;
}));