mirror of
https://github.com/jquery/jquery.git
synced 2024-11-23 02:54:22 +00:00
All non-var modules should not indent in their AMD wrappers (just for prettier builds). No functionality changes.
This commit is contained in:
parent
3b53b75160
commit
cd4a9cd7fa
@ -2,7 +2,8 @@ define([
|
||||
"../core"
|
||||
], function( jQuery ) {
|
||||
|
||||
jQuery.parseJSON = JSON.parse;
|
||||
jQuery.parseJSON = JSON.parse;
|
||||
|
||||
return jQuery.parseJSON;
|
||||
|
||||
return jQuery.parseJSON;
|
||||
});
|
||||
|
@ -1,8 +1,9 @@
|
||||
define([
|
||||
"../core"
|
||||
], function( jQuery ) {
|
||||
// Cross-browser xml parsing
|
||||
jQuery.parseXML = function( data ) {
|
||||
|
||||
// Cross-browser xml parsing
|
||||
jQuery.parseXML = function( data ) {
|
||||
var xml, tmp;
|
||||
if ( !data || typeof data !== "string" ) {
|
||||
return null;
|
||||
@ -20,7 +21,8 @@ define([
|
||||
jQuery.error( "Invalid XML: " + data );
|
||||
}
|
||||
return xml;
|
||||
};
|
||||
};
|
||||
|
||||
return jQuery.parseXML;
|
||||
|
||||
return jQuery.parseXML;
|
||||
});
|
||||
|
@ -5,6 +5,7 @@ define([
|
||||
"./attributes/classes",
|
||||
"./attributes/val"
|
||||
], function( jQuery ) {
|
||||
// Return jQuery for attributes-only inclusion
|
||||
return jQuery;
|
||||
|
||||
// Return jQuery for attributes-only inclusion
|
||||
return jQuery;
|
||||
});
|
||||
|
@ -1,9 +1,10 @@
|
||||
define([
|
||||
"../core"
|
||||
], function( jQuery ) {
|
||||
// Multifunctional method to get and set values of a collection
|
||||
// The value/s can optionally be executed if it's a function
|
||||
var access = jQuery.access = function( elems, fn, key, value, chainable, emptyGet, raw ) {
|
||||
|
||||
// Multifunctional method to get and set values of a collection
|
||||
// The value/s can optionally be executed if it's a function
|
||||
var access = jQuery.access = function( elems, fn, key, value, chainable, emptyGet, raw ) {
|
||||
var i = 0,
|
||||
length = elems.length,
|
||||
bulk = key == null;
|
||||
@ -52,7 +53,8 @@ define([
|
||||
bulk ?
|
||||
fn.call( elems ) :
|
||||
length ? fn( elems[0], key ) : emptyGet;
|
||||
};
|
||||
};
|
||||
|
||||
return access;
|
||||
|
||||
return access;
|
||||
});
|
||||
|
@ -4,10 +4,10 @@ define([
|
||||
"../manipulation" // buildFragment
|
||||
], function( jQuery, rsingleTag ) {
|
||||
|
||||
// data: string of html
|
||||
// context (optional): If specified, the fragment will be created in this context, defaults to document
|
||||
// keepScripts (optional): If true, will include scripts passed in the html string
|
||||
jQuery.parseHTML = function( data, context, keepScripts ) {
|
||||
// data: string of html
|
||||
// context (optional): If specified, the fragment will be created in this context, defaults to document
|
||||
// keepScripts (optional): If true, will include scripts passed in the html string
|
||||
jQuery.parseHTML = function( data, context, keepScripts ) {
|
||||
if ( !data || typeof data !== "string" ) {
|
||||
return null;
|
||||
}
|
||||
@ -32,7 +32,8 @@ define([
|
||||
}
|
||||
|
||||
return jQuery.merge( [], parsed.childNodes );
|
||||
};
|
||||
};
|
||||
|
||||
return jQuery.parseHTML;
|
||||
|
||||
return jQuery.parseHTML;
|
||||
});
|
||||
|
@ -2,8 +2,8 @@ define([
|
||||
"../core"
|
||||
], function( jQuery ) {
|
||||
|
||||
// A method for quickly swapping in/out CSS properties to get correct calculations.
|
||||
jQuery.swap = function( elem, options, callback, args ) {
|
||||
// A method for quickly swapping in/out CSS properties to get correct calculations.
|
||||
jQuery.swap = function( elem, options, callback, args ) {
|
||||
var ret, name,
|
||||
old = {};
|
||||
|
||||
@ -21,7 +21,8 @@ define([
|
||||
}
|
||||
|
||||
return ret;
|
||||
};
|
||||
};
|
||||
|
||||
return jQuery.swap;
|
||||
|
||||
return jQuery.swap;
|
||||
});
|
||||
|
@ -3,9 +3,11 @@ define([
|
||||
"../selector",
|
||||
"../effects"
|
||||
], function( jQuery ) {
|
||||
jQuery.expr.filters.animated = function( elem ) {
|
||||
|
||||
jQuery.expr.filters.animated = function( elem ) {
|
||||
return jQuery.grep(jQuery.timers, function( fn ) {
|
||||
return elem === fn.elem;
|
||||
}).length;
|
||||
};
|
||||
};
|
||||
|
||||
});
|
||||
|
@ -1,7 +1,8 @@
|
||||
define([
|
||||
"../ajax"
|
||||
], function( jQuery ) {
|
||||
jQuery._evalUrl = function( url ) {
|
||||
|
||||
jQuery._evalUrl = function( url ) {
|
||||
return jQuery.ajax({
|
||||
url: url,
|
||||
type: "GET",
|
||||
@ -10,7 +11,8 @@ define([
|
||||
global: false,
|
||||
"throws": true
|
||||
});
|
||||
};
|
||||
};
|
||||
|
||||
return jQuery._evalUrl;
|
||||
|
||||
return jQuery._evalUrl;
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user