Commit Graph

392 Commits

Author SHA1 Message Date
Dave Methvin
a839af034d Merge pull request #465 from anton-ryzhov/master
Fixes #10076. $.inArray crashes IE6 and Chrome if second argument is `null` or `undefined` (Thanks anton-ryzhov!)
2011-08-25 12:22:47 -07:00
Dave Methvin
749dbad981 Prioritize #id over <tag> to avoid XSS via location.hash (#9521) 2011-08-23 08:25:11 -04:00
dmethvin
1a738cb72f Landing pull request 463. Fixes #9572. Don't camelize the -ms- prefix because Microsoft didn't. A Fixes #9572.
More Details:
 - https://github.com/jquery/jquery/pull/463
 - http://bugs.jquery.com/ticket/9572
2011-08-17 17:34:09 -04:00
Anton Ryzhov
190136cf61 Unit test for this case
Codestyle fixes
2011-08-17 18:56:21 +04:00
Rick Waldron
ad16db370e Wrap obj.constructor test in try/catch. Thanks to bkrausz. Fixes #9897 2011-07-25 17:06:38 -04:00
jaubourg
27291ff06d Fixes #9255: xml parsing error in $.parseXML is now properly detected for all browsers. Unit test added. 2011-07-23 03:26:36 +02:00
rwldrn
408c98fb4b Landing pull request 383. Relocating jQuery.camelCase to core; Fixes #9368.
More Details:
 - https://github.com/jquery/jquery/pull/383
 - http://bugs.jquery.com/ticket/9368
2011-05-25 15:10:49 -04:00
John Resig
6c449fd5df Make sure that empty nodelists continue to map properly. Fixes #8993. 2011-05-02 13:25:53 -04:00
John Resig
86aa764f0b Change check for skipping the initial quickExpr RegExp check. Fixes #8984. 2011-05-02 13:14:13 -04:00
John Resig
15da298f72 Remove unnecessary usage of Function.prototype.bind (#7783) but maintain API. Also fix bug with proxy failing when a name is provided. Fixes #8893. 2011-04-17 18:17:31 -04:00
timmywil
ecf6a3c383 Switch QUnit div from depreceted #main to #qunit-fixture 2011-04-17 02:43:57 -04:00
jrburke
0b1c2e642a Add support for registering jQuery as an AMD module. Only does so if the AMD loader indicates it has special allowances for multiple versions of jQuery being loaded in a page. 2011-04-16 20:35:18 -07:00
louisremi
a5604aedb7 merge with master and resolve more conflicts 2011-04-12 11:29:25 +02:00
jeresig
31b3c44db3 Merge branch 'bug_4366' of https://github.com/jboesch/jquery into jboesch-bug_4366 2011-04-12 00:12:27 -04:00
louisremi
11adde5127 second batch 2011-04-11 22:33:29 +02:00
jeresig
14ecd9a992 Merge branch 'proxy-native-bind' of https://github.com/gf3/jquery into gf3-proxy-native-bind 2011-04-10 16:51:22 -04:00
jeresig
247363b9a7 Merge branch 'map-object.1.6' of https://github.com/danheberden/jquery into danheberden-map-object.1.6 2011-04-10 16:46:14 -04:00
jaubourg
f3c6077da0 Rewrite of globalEval. Uses window.execScript or window.eval with a trick to ensure proper context. Unit tests added. 2011-04-07 06:47:15 +02:00
carpie
e0856738e6 Skip id regex check when large html strings are passed to the jQuery constructor (#7990). 2011-04-05 23:18:35 -04:00
Dave Methvin
1e85027dee Merge branch '4321' of https://github.com/rwldrn/jquery into rwldrn-4321 2011-04-05 22:04:05 -04:00
Dan Heberden
c72371f714 Improve speed of $.map with object support (-5% previous speed) and improve .length detection 2011-04-04 23:59:54 -07:00
Jordan Boesch
3296116041 Bug 4366; fixing $.each(document.styleSheets) from throwing errors in IE 2011-03-30 11:17:48 -06:00
Dan Heberden
d832f4f71e jQuery.map to iterate over objects with a .length property 2011-03-21 12:12:31 -07:00
Dan Heberden
f0e7d28e83 Merge branch 'bug_2616' of https://github.com/jboesch/jquery into map-object.1.6
* 'bug_2616' of https://github.com/jboesch/jquery:
  Bug 2616; Adding object support to jQuery.map
2011-03-21 08:04:35 -07:00
jaubourg
2d0bc7ce72 Moves Deferred-related code into a separate module. Context handling has been simplified in _Deferred.resolve and jQuery.when has been refactored for clarity (and minor optimization). 2011-03-03 19:38:06 +01:00
jaubourg
c1279895f3 Fix for #8421. Makes sure resolveWith can be called with only one parameter. 2011-03-03 15:16:47 +01:00
Jordan Boesch
c8a887af06 Bug 2616; Adding object support to jQuery.map 2011-02-27 12:47:35 -06:00
jaubourg
a43a5ca9cf Revert "Adds an invert method to promises that returns a "inverted" promise that is resolved when the underlying deferred is rejected and rejected when the underlying deferred is resolved."
This reverts commit 4e97543051.
2011-02-18 18:06:26 +01:00
Anton M
8e40a84c24 Fix some unscoped tests which failed after recent changes to QUnit. 2011-02-15 21:03:34 +01:00
jaubourg
4e97543051 Adds an invert method to promises that returns a "inverted" promise that is resolved when the underlying deferred is rejected and rejected when the underlying deferred is resolved. 2011-01-31 14:49:14 +01:00
jeresig
749d41f7de Rename jQuery.subclass() to jQuery.sub(). 2011-01-31 08:21:42 -05:00
Digitalxero
e00f74c43b Make sure subclass is a proper subclass not just subclassing the fn methods. Fixes #7979. 2011-01-27 13:35:06 -05:00
Gianni Chiappetta
574ae3b1be added: Backcompatibility with old proxy syntax. 2011-01-21 10:33:50 -05:00
Gianni Chiappetta
a03f040dbf Merge branch 'master' into proxy-native-bind
* master: (194 commits)
  Revert "Make sure that focusin/focusout bubbles in non-IE browsers." This was causing problems with the focusin event, see: #7340.
  Replaces "text in-between" technique with a full-fledged one-level transitive search for converters (unit tests added). Also cleans up auto dataType determination and adds converter checks in order to guess the best dataType possible.
  Moves determineResponse logic into main ajax callback. Puts responseXXX fields definitions into ajaxSettings.
  Removes misleading comment.
  Bring jQuery('#id') and jQuery('body') logic back into core (while leaving it in Sizzle at the same time). Was causing too much of a performance hit to leave it all to Sizzle.
  Renames Deferred's fire and fireReject methods as resolveWith and rejectWith respectively.
  Fix typo in regex tweak from previous commit.
  Renames determineDataType as determineResponse. Makes it more generic as a first step into integrating the logic into the main ajax done callback. Also fixes some comments in ajax/xhr.js.
  Move jQuery(...) selector speed-up logic into Sizzle(...) qSA handling. Additionally add in a new catch for Sizzle('.class') (avoid using qSA and use getElementsByClassName instead, where applicable).
  Revises the way arguments are handled in ajax.
  Makes sure statusCode callbacks are ordered in the same way success and error callbacks are. Unit tests added.
  Cleans up and simplifies code shared by ajaxPrefilter and ajaxTransport. Removes chainability of ajaxSetup, ajaxPrefilter and ajaxTransport. Also makes sure context is handled properly by ajaxSetup (unit test added).
  Rework unit tests to check actual result elements.
  Moves active counter test after all other ajax tests where it should be.
  Revised the Nokia support fallback. It turns out that Nokia supports the documentElement property but does not define document.compatMode. Adding this third fallback allows Nokia to run jQuery error-free and return proper values for window width and height.
  Moves things around to make jsLint happier.
  Fixes crossDomain test so that it assumes port to be 80 for http and 443 for https when it is not provided.
  Moves determineDataType into ajaxSettings so that it is accessible to transports without the need for a second argument and so that we can now pass the original options to the transport instead. Also ensures the original options are actually propagated to prefilters (they were not).
  Re-adds hastily removed variable and simplifies statusCode based callbacks handling.
  Use undefined instead of 0 to deference transport for clarity.
  ...

Conflicts:
	src/event.js
2011-01-21 09:58:55 -05:00
jaubourg
a7cb93bee5 Renames Deferred's fire and fireReject methods as resolveWith and rejectWith respectively. 2011-01-20 17:51:57 +01:00
Colin Snover
e78d3a7e2d Merge in data_nocollide branch. Fixes #6968, improves unit testing framework checks for leaky stuff. 2011-01-17 15:31:43 -06:00
jaubourg
ac2e731b2d Added unit tests to check and demonstrate new jQuery.Deferred() works. 2011-01-17 17:52:30 +01:00
jaubourg
c272f5f7da Implements joined jQuery.when statements. Makes it so calling jQuery.when with no parameter returns a resolved promise. Ensures promise method on promises supports the promise(obj) signature. Ensures a deferred and its promise always return the same promise (itself for the promise). Unit tests provided. 2011-01-16 17:41:39 +01:00
wycats
fa45f25d1c Fix a failing subclass test due to a change in master 2011-01-14 11:17:32 -05:00
Jared Grippe
d483ce0a9c added jQuery.subclass 2011-01-14 10:38:32 -05:00
Colin Snover
b14f02899e Ensure that buildFragment clones elements properly in all browsers. Fixes #3879, #6655. Also improves form element clone tests and fixes bugs in $.fn.clone exposed by these new test cases related to the values of checkboxes and radio buttons in IE. 2011-01-09 18:38:44 -06:00
Colin Snover
e2941d5a98 Update unit tests with a leak detection mechanism for the various jQuery globals and fix all leaks in the tests. 2011-01-09 15:58:47 -06:00
jaubourg
1ca82ccd94 Renamed "complete" to "done" in order to avoid conflicts with jXHR.complete. 2011-01-06 01:26:06 +01:00
Colin Snover
e56de77df9 Cleaning up trailing whitespace again. 2011-01-05 15:44:07 -06:00
wycats
ae6655bcb6 Revert "Register as a CommonJS async module if in that kind of environment. Fixes #7102."
This reverts commit 6ffa730721.

Conflicts:

	src/core.js
2011-01-05 13:26:05 -08:00
jaubourg
cbf591152c "then" renamed "complete" and new "then" method defined using "complete" and "fail" internally. The API is still symetrical (complete/fail), still promotes AOP but is also now Promise/A compliant. Changed unit tests and ajax module accordingly. 2011-01-05 04:29:30 +01:00
rwldrn
037d6bd5c3 4321 returns empty jquery object 2011-01-01 17:13:04 -05:00
jaubourg
6fb9759a75 Simplified the way a Promise is tested for (removed promiseMarker). Removed isCancelled helper method from _Deferred, wasn't used nor tested. Reworked jQuery.Deferred and removed unnecessary variables. Also ensured a Promise will return itself when asked for a Promise. Finally, the jQuery.when tests have been revamped. 2010-12-31 04:15:15 +01:00
jaubourg
6dbffb8596 Introduced a new promise method on deferreds that returns an immutable object (exposing then, fail, isResolved, isRejected and promise itself only). Remove $.isDeferred and moved logic directly into $.when. Made sure $.when returns a promise by using promise(). Used promise() in ajax code too. 2010-12-31 04:15:11 +01:00
unknown
240d8b681e Removed custom method in isDeferred and when. 2010-12-31 04:05:56 +01:00
unknown
23d455b446 Deferred cannot be cancelled by returning false in a callback. Exception in the callback are still propagated and execution of remaining callbacks is still possible. 2010-12-31 04:05:55 +01:00
unknown
2d4001b82c Capitalized Deferred & _Deferred to clearly mark them as new types, like Event. 2010-12-31 04:05:53 +01:00
jaubourg
5bacb53866 Added deferred to core. Used internally for DOM readyness and ajax callbacks. 2010-12-31 03:49:22 +01:00
jrburke
6ffa730721 Register as a CommonJS async module if in that kind of environment. Fixes #7102. 2010-12-27 13:03:27 -06:00
Gianni Chiappetta
9f8cd6c499 Fixing $.proxy to work like (and use) Function.prototype.bind (ticket #7783)
http://bugs.jquery.com/ticket/7783
2010-12-14 21:53:04 -05:00
jeresig
b4bb6e1126 Backing out fb6c038bf0, was causing jQuery.param tests to fail - unfixes #7413. 2010-12-09 13:07:44 -05:00
jeresig
fb6c038bf0 Merge branch 'bug_7413' of https://github.com/rwldrn/jquery into rwldrn-bug_7413 2010-12-09 12:32:15 -05:00
Anton M
5c0b5d2560 Improve performance of get() for negative indices. Fixes #5476. 2010-11-19 12:28:13 +01:00
rwldrn
fc563cc42a Fixes #7413; isEmptyObject() check to see if obj passes isPlainObject 2010-11-09 16:14:11 -05:00
Robert Katic
894bd02a06 Test jQuery.type also with document. 2010-09-23 12:08:54 -04:00
Robert Katic
484cc6e220 Made jQuery.type more consistent with host objects. 2010-09-23 12:08:41 -04:00
Robert Katic
97b42492bb Added some tests for #5991. 2010-09-23 12:07:22 -04:00
Robert Katic
694b625c92 Ensured that arrays are not considered same as plain object on deep extending. Fixes #5991. 2010-09-23 12:07:06 -04:00
jeresig
d7a6e75241 Add some tests for jQuery.isWindow and make sure that we're operating against an object before testing. 2010-09-22 16:50:38 -04:00
jeresig
bca5765502 Make sure that jQuery works even when the individual modules are loaded separately AND jQuery.noConflict(true) is used. Fixes #7011. 2010-09-08 13:54:33 -04:00
John Resig
5d2be7e299 Added some tweaks to $.type to handle null and undefined. Added a bunch of unit tests as well. 2010-08-27 06:10:52 -07:00
John Resig
396dd21273 Fixing getting/setting classes and makeArray(RegExp) for Blackberry 4.7. Fixes #6930, #6931. 2010-08-23 12:38:55 -07:00
jzaefferer
6f031c1015 Replace usage of the removed global reset() method with QUnit.reset(). 2010-07-28 17:19:01 +02:00
jeresig
3b221da8b0 Adjust isPlainObject test to run in an iframe. 2010-03-24 15:18:11 -04:00
jeresig
141ad3c3e2 Landing a faster trim method. Based upon the work by Travis Hardiman and DBJDBJ. More details here: http://forum.jquery.com/topic/faster-jquery-trim Fixes #2279, #4452, and #4835. 2010-03-09 09:14:27 -05:00
jeresig
94d925cd46 Make sure leading whitespace is trimmed for parseJSON. Fixes #6031. 2010-02-13 02:14:23 -05:00
jeresig
b8076a914b Landing some minor perf optimization to jQuery(). 2010-01-28 17:17:51 -05:00
jeresig
781fe8b80d Make empty strings (and other non-string values) simply return null from parseJSON. Also added some parseJSON tests. Fixes #5859. 2010-01-23 17:08:26 -05:00
jeresig
ea9e0ed841 Moved add() tests from core to traversing. 2010-01-23 16:54:24 -05:00
jeresig
5d49335eac Make sure that disconnected nodes aren't sorted/uniqued. Fixes #5791. 2010-01-13 00:12:18 -05:00
jeresig
8e53f7b5d6 Fixed typo in logic, also disabled function setters in this case to allow the functions to passthrough and bind. 2010-01-12 21:54:06 -05:00
Filipe Fortes
0d1a2c1b11 Make sure to do a deep copy on arrays. #5750 2010-01-07 00:11:22 +08:00
jeresig
230614b4df Merging in jQuery.proxy() branch. 2010-01-05 19:18:39 -05:00
jeresig
ffb1867a43 Rewrite of jQuery.browser to become engine-centric, rather than browser-centric. Also attempt to determine the engine version in a smarter fashion, less prone to error. Finally, enhanced the test suite with 255 useragent strings from http://user-agent-string.info/download for testing. jQuery.browser.safari is now deprecated, use jQuery.browser.webkit instead. 2010-01-05 17:01:20 -05:00
jeresig
1d2b1a57da Added in jQuery.proxy(obj, name), like the method described in Secrets of the JavaScript Ninja and in Dojo's Hitch, and added in some unit tests. 2009-12-31 15:17:52 -05:00
jeresig
c05712f0a5 Fixed the spacing from the last commit. 2009-12-18 12:43:35 -05:00
jeresig
d40083c866 Disabled the passthrough .attr(method_name) functionality. You can now use it if you do: .attr({method_name: value}, true) OR as an easy initialization method: jQuery('<div/>', {html: '...', id: 'test'}). 2009-12-18 12:41:53 -05:00
Robert Katic
148fb7ba8e Made isPlainObject() supporting null, undefined, and window values on IE too. Also added some related tests. Fixes #5669. 2009-12-19 01:19:34 +08:00
John Resig
65ebf57c1e Make sure that dynamically-created elements don't have a parent. Fixes #5638. 2009-12-10 17:01:04 -08:00
John Resig
474d814076 Moved some methods around inbetween core.js and traversing.js. Core methods shouldn't rely upon other modules (e.g. the selector engine) wherever possible. 2009-12-10 09:25:25 -08:00
John Resig
715d1c5a30 Rewrote .merge() (faster and less obtuse now). Fixed #5610. 2009-12-09 21:43:20 -08:00
John Resig
04524287d3 Switched jQuery() to represent jQuery([]) instead of jQuery(document). 2009-12-09 20:36:07 -08:00
John Resig
87ba780c69 Renamed isObjectLiteral to isPlainObject (makes more sense, per the suggestion of Michael Geary). 2009-12-06 17:11:51 -05:00
jeresig
b8d0c0711f Added some isObjectLiteral tests. 2009-12-02 14:57:13 -05:00
Yehuda Katz
17955cacf4 Fixes $.trim for &nbsp; closes #4980 2009-11-30 10:22:18 -08:00
Robert Katic
ac00fe5bbb Generic jQuery.merge and safer jQuery.makeArray(nodeList).
* Made jQuery.marge more generic supporting null and undefined values, and supporting array like objects as results. Fixes #5527.

* Made jQuery.makeArray(nodeList) more safer using jQuery.merge internally. Fixes #5528.

* Added a second "results" argument to jQuery.makeArray for internal usage to avoid intermediary arrays in init.
2009-11-26 00:56:49 +08:00
Robert Katic
ee9192d103 Corrected some minor errors made by me (rkatic) in last commits. 2009-11-13 08:09:46 +08:00
Robert Katic
7b26e3bcc8 Forgotten to update the number of jQuery.extend related tests. 2009-11-12 21:59:48 +08:00
Robert Katic
93be758de9 Made jQuery.extend(true, ...) to extend recursively only 'object literal' values. 2009-11-12 21:59:47 +08:00
Robert Katic
990d9ca1b0 Made isObjectLiteral to work correctly with custom objects with empty prototypes. 2009-11-12 21:59:47 +08:00
John Resig
c4c820efff Made jQuery('<div/>') and jQuery('<div></div>') use the same code path (making the second one faster). Fixes #5293. 2009-11-11 13:49:29 -05:00
rkatic
b256a3a266 Added a method to myKlass.
If an object's prototype is "empty", then isObject returns true!
2009-11-09 19:32:24 +08:00
John Resig
b0fe380cf8 Make .add() take an optional context and - if a context is specified in the root selector - use that as the base context. 2009-11-07 16:43:31 +01:00
John Resig
4bda398e6a Switched from using QUnit's isObj/isSet to the more robust same method. 2009-09-29 19:49:43 +00:00
John Resig
67d445a703 A follow-up to [6578] (which stopped adding expandos to elements that didn't have data). That broke jQuery.unique() (so we're now using the unique from Sizzle). Using Sizzle's unique (which also sorts in document order) changed how add, andSelf, parents, nextAll, prevAll, and siblings work. after and before were changed to not use .add() (in order to guarantee their position in the jQuery set). Also, jQuery.data(elem) was updated to return that element's data object (instead of its ID).
$("<div/>").after("<span/>")
=> [ div, span ]
(calling after on a disconnected DOM node adds the nodes to the end of the jQuery set)

$("<div/>").before("<span/>")
=> [ span, div ]
(calling before on a disconnected DOM node adds the nodes to the beginning of the jQuery set)

$("div").add("span")
=> [ div, span, span, div, span ]
(results now come out in document order)

$("div").find("code").andSelf();
=> [ div, code, code ]
(results now come out in document order)

Same goes for .parents(), .nextAll(), .prevAll(), and .siblings().

Exception: .parents() will still return the results in reverse document order.

jQuery.data(elem)
=> { object of data }
(no longer returns the unique ID assigned to the node)
2009-09-25 17:55:20 +00:00
Ariel Flesler
0790989eb6 jquery core: Fixed #5202. Fixing selector generation when a manipulation function receives a jQuery object. 2009-09-14 18:03:18 +00:00
John Resig
9d8d74569c Split out the fragment-building code from domManip. Switched core.js to using that instead. Also moved the standalone tag detection to $(...) for performance. 2009-09-07 18:58:01 +00:00
John Resig
569c8b45c0 Fixed a bug with the isXMLDoc test - also made sure that isXMLDoc was handling the case where documentElement is undefined (which only occurs on HTML documents in IE). 2009-08-27 20:07:45 +00:00
John Resig
957cd6fb2a Tweaked the isXMLDoc iframe test case to test the document, not the body element (which doesn't exist in IE). Also made the isXMLDoc code handle cases where elem is null, undefined, etc. 2009-08-27 19:22:48 +00:00
John Resig
18a6fbbb6a Added an improvement to quickExpr and some more tests for jQuery('html'). Fixes #4979. 2009-07-27 20:47:32 +00:00
John Resig
2cd9ee3510 Added an extra documentElement check to isXMLDoc for IE - and added a number of unit tests for isXMLDoc. Fixes #4833. 2009-07-27 13:02:41 +00:00
Yehuda Katz
1a7f72e7fe Add test for jQuery(jQueryObj) cloning and simplify new get() code 2009-07-17 17:33:44 +00:00
Ariel Flesler
a38a5cd531 jquery core: Simplifying isEmptyObject() and adding tests. 2009-07-16 15:16:44 +00:00
Yehuda Katz
8e54b167cf Add a test for index() 2009-07-16 07:32:17 +00:00
Yehuda Katz
c10f87120f jQuery.extend(true, Object, Object) copies custom objects correctly.
- Also update jQuery.isObject to handle this case correctly
2009-07-16 07:32:03 +00:00
Yehuda Katz
8d52c27808 jQuery.extend(true, Object, Object) copies objects with length keys correctly 2009-07-16 07:31:55 +00:00
Yehuda Katz
6b912beb7b Clear some dangling whitespace 2009-07-16 07:31:47 +00:00
Yehuda Katz
e532dfe522 Add support for .get(-Number) Closes #4188 2009-07-16 07:31:41 +00:00
Yehuda Katz
e124fec5e9 Make toArray an alias for .get(). Closes #3999 2009-07-16 07:31:32 +00:00
Ariel Flesler
c6b9654ea8 jquery core: Closes #2827. jQuery.each iterates over functions 2009-06-20 15:51:19 +00:00
Brandon Aaron
c41fab1eb0 another unit test for index method 2009-05-07 16:59:35 +00:00
Ariel Flesler
c6b59263b5 testrunner: Updating an orphaned test 2009-05-03 17:02:56 +00:00
Ariel Flesler
3a80de1c7a jquery core: $() -> $(document) and $(undefined) -> $([]). Removed a duplicated block. 2009-05-03 15:57:25 +00:00
Brandon Aaron
d415e0adb8 actually should be 6330, not 6329 2009-05-02 19:23:53 +00:00
Brandon Aaron
ffd457d456 index now works in reverse when passed a selector or undefined. fixes #3971 2009-05-02 19:22:55 +00:00
John Resig
2764127335 Unified the formatting of core.js. === or !== are used wherever appropriate, syntax has been normalized, braces are added in all cases, and jQuery() now returns an empty set. 2009-03-31 17:35:20 +00:00
Brandon Aaron
7c04a64016 breaking jquery out into smaller modules. added attributes.js, manipulation.js, and traversing.js 2009-03-18 21:15:38 +00:00
Brandon Aaron
e73990a566 fix for #3688, setting type attribute on button causes IE to throw error 2009-03-17 22:27:25 +00:00
John Resig
f1f5cd9f6a Simplified the structure of the .css() and .attr() methods (reducing the number of calls). Need to optimize $.css/$.curCSS/$.attr still. Fixes #4269. 2009-02-28 20:23:48 +00:00
John Resig
a37ca9e905 Made sure that .remove now uses multiFilter. Fixes bug #4205. 2009-02-20 19:45:29 +00:00
John Resig
481171a3f8 Fixed some tests that were changed (fixed!) by fixing #3966. 2009-02-18 19:59:51 +00:00
John Resig
75a973da35 Made it so that appendTo, etc. return the inserted elements (thus using pushStack, as well). Fixes bugs #3966 and #4182. 2009-02-18 16:29:43 +00:00
John Resig
1ac087f6f9 Updated the show() tests to work without the use of jQuery.browser (the test suite now passes 100% in IE8). 2009-02-17 22:22:05 +00:00
John Resig
b536d2ac67 Reorganized and disabled some of the height/width tests. Need to look in to better abornormal-padding/margin/border support at some point. 2009-02-17 22:15:42 +00:00
John Resig
4a4d049df9 Made the div showing a little more explicit - making sure that it doesn't affect the fx tests. 2009-02-17 16:22:41 +00:00
John Resig
f89f5eb61f Reorganized some of the animation tests to work with the new hide/show changes. 2009-02-17 15:54:27 +00:00
John Resig
10ab08de43 Fixed some more CSS/visibility tests. 2009-02-17 14:08:11 +00:00
John Resig
ad7577a084 Changed a bunch of the DOM tests to work in Document Order. 2009-02-17 14:05:25 +00:00
John Resig
6bd6a4e059 Updated some of the display/visible/hidden tests to work on an appropriate element. 2009-02-17 13:57:28 +00:00
John Resig
ce90accc58 Reworked the .clone() function in IE. Fixes jQuery bugs #3500 (jQuery expandos were causing extra elements to appear from using .html() cloning), #3254 (Mis-match in clone result length causes problem), and #2845 (Cloning an <object/> causes exceptions to be thrown). 2009-02-09 14:48:15 +00:00
John Resig
cd28922b78 Made sure that .removeClass(null) doesn't throw an exception. Fixes #3847. 2009-01-20 17:33:25 +00:00
John Resig
28a1f02223 Re-worked the logic for where .selector and .context are added for ID selectors (especially ones that aren't found). Fixes jQuery bug #3833. 2009-01-20 16:00:48 +00:00
John Resig
4e7d565e50 Added two more tweaks for XHTML core tests. 2009-01-19 23:33:46 +00:00
John Resig
9db710a156 Made some tweaks to the core tests so that they'll run better under XHTML. 2009-01-19 23:22:25 +00:00
John Resig
96152559e0 Landing a fix for non-link anchor tabIndex (from scott.gonzalez). Fixes ticket #3916. 2009-01-19 21:40:23 +00:00
John Resig
ea78377760 Only try to wrap the element if it's not disconnected, fixed #3828. 2009-01-12 14:07:14 +00:00
John Resig
0c97178553 Fixed an issue with parentNode being accessed in attr() on disconnected DOM elements. 2009-01-12 14:00:35 +00:00
John Resig
73ff49ac9a Prevented non-script <script> blocks from executing, fixing #3733. 2009-01-11 19:33:01 +00:00
John Resig
0066ba3f82 .closest() with positional selectors wasn't worked as expected. 2009-01-10 20:30:03 +00:00
John Resig
29bf601f34 Fixed an issue with script nodes being removed incorrectly, fixes #3737. 2009-01-10 01:07:59 +00:00
Ariel Flesler
d62875fb01 testrunner: Removing every global variable leaked within (and outside) tests. Some were deleted and some saved within the jQuery namespace. 2009-01-09 23:49:18 +00:00
John Resig
c6f189ac73 Selector state wasn't being passed along on a cloned jQuery object. 2009-01-08 21:41:58 +00:00
Scott González
49d0d5b7a3 Fixed tabindex normalization so that elements that natively support tabbing, but don't have a tabindex explicitly set return 0 instead of undefined.
Removed jQuery.support.tabindex since we're only normalizing non-XML right now and all browsers support tabIndex for HTML documents.
2009-01-07 14:36:30 +00:00
John Resig
d3141dcdba Simplified the XML clone test. 2009-01-05 21:56:35 +00:00
John Resig
c6de039bb1 Simplified the XML selector test (save the result). 2009-01-05 21:04:15 +00:00
John Resig
122b672f70 Landed cross-browser support for tabIndex, by Scott, closes ticket #3649. 2009-01-05 17:34:42 +00:00
John Resig
4694e537bc Forgot to merge in some of the new tests from Sizzle. 2009-01-05 01:24:14 +00:00
John Resig
c0294278db Landed a proper fix for #3255 - which involves doing createElement instead of going through the normal clean method. 2009-01-03 00:51:07 +00:00
John Resig
d20e7fede1 Disabled testing of em-defined borders, need to look back into this issue. 2009-01-02 19:25:54 +00:00
John Resig
c59bf424a1 The exact escaping of the text() test isn't important - as long as < is escaped. 2009-01-02 19:23:12 +00:00
John Resig
6a3d1a1e28 Fixed an issue with .not("#foo, bar") not working correctly, closes #3757. 2008-12-31 19:21:24 +00:00
Ariel Flesler
4afa608351 jquery data: Closes #3539. Exposed jQuery.queue. Moved all the data and queue functions to their own module. Made the dequeue function more generic(designed to be used on functions). Closes #3748. Reverted a previous modification. 2008-12-30 02:31:26 +00:00
Ariel Flesler
0a8f96ac3d jquery core: Closes #1681. jQuery.fn.toggleClass can accept a boolean argument indicating add/remove. 2008-12-25 20:12:18 +00:00
Ariel Flesler
0e3e470edc jquery core: Closes #3255. The div used in jQuery.clean is emptied in the end. Cleaning the parentNode's properties of the elements. 2008-12-25 19:47:56 +00:00
Ariel Flesler
4b25b147ab jquery core: Closes #3641. jQuery.merge stopped looping once a 0 was found. 2008-12-25 19:25:30 +00:00
John Resig
6b09032864 Added support for the new .closest() method (very useful for event delegation). 2008-12-22 00:52:53 +00:00
John Resig
c85243dfc4 Landing the new Sizzle selector engine. There'll need to be some later tweaks (to make the tests a little more pragmatic - especially for document order elements). But it appears to be passing well and that's enough. Closes #3563. 2008-12-20 01:19:17 +00:00
John Resig
46ee77bcc3 Fixed line-ending issue. 2008-12-19 05:43:37 +00:00
John Resig
3963fcb30d Tweaked mis-numbered makeArray test. 2008-12-19 05:42:15 +00:00
John Resig
132b8de614 Switched to using DOM Fragments in domManip. 2008-12-19 04:37:54 +00:00
John Resig
2875460f63 Added selector path logging (creates a trail that plugins can use). 2008-12-19 04:37:10 +00:00
Ariel Flesler
e611289a79 testrunner: re adding the test for a function within isFunction. 2008-12-16 00:05:04 +00:00
Ariel Flesler
96e8f355da testrunner: fixing tests that were broken due to recent updates to qunit. 2008-10-18 21:59:09 +00:00
Ariel Flesler
1023cf1d72 jquery core: closes #3248, #3079, #3026, #3176, #3202, #3129. jQuery.makeArray doesn't support functions anymore. Voiding the conflict with Scriptaculous 1.7.x. 2008-08-12 19:34:30 +00:00
Ariel Flesler
a27b5d0468 jquery core: closes #2652. val() supports option elements, also simplified the code. 2008-07-23 17:00:32 +00:00
Ariel Flesler
69212c501f jquery core: closes #2968. Simplified isFunction, dropping support for DOM methods and functions like alert() on IE. 2008-07-23 16:18:05 +00:00
Ariel Flesler
28937ded0e test runner: optimizing a test for speed. 2008-07-01 02:08:45 +00:00
Ariel Flesler
a23e4361fc test runner: recloses #3102. Adding one test for $().eq("1") 2008-07-01 02:05:46 +00:00
Ariel Flesler
21d669135d test runner: 2 tests for [5728]. 2008-06-17 19:59:16 +00:00
Ariel Flesler
1e9593646f test runner: adding 2 tests for .val( Number ).
Removed a silly test.
2008-05-29 00:03:45 +00:00
Ariel Flesler
9e48649729 test runner: the changes are:
- Replaced all the $ for jQuery in the tests and suite.
- Added a noConflict to testrunner.js.
- Modified the test for noConflict() so that it still work.
- Added jQuery 1.2.1 and 1.2.3 to otherlibs.
2008-05-28 23:18:25 +00:00
Ariel Flesler
3c5c3dffaa test runner: A test was failing on Opera 9.50. Not a bug, just made the test less specific and it passed. 2008-05-24 21:27:12 +00:00
Ariel Flesler
0e63c789e3 test runner: adding more tests for attr(). Related to [5574] and [5683]. 2008-05-24 18:11:55 +00:00
Ariel Flesler
1382ea8d98 test runner: improved the shown message of 4 isFunction tests. 2008-05-14 21:18:46 +00:00
Ariel Flesler
37394598cb test runner: improved a test and added a missing semicolon 2008-05-12 22:59:58 +00:00
Ariel Flesler
0a794ed5fc test runner: added 2 tests for [5500] 2008-05-08 17:16:49 +00:00
Ariel Flesler
6a9b73c7b9 test runner: extra tests for $.fn.add enabled by [5503] and a small fix for an html() test. 2008-05-08 17:11:03 +00:00
Ariel Flesler
9f0c0cfec5 test runner: making 2 tests more flexible because they yield a slightly different result on Safari 3, but still acceptable. 2008-05-08 16:04:01 +00:00
Ariel Flesler
96ca83d150 test runner: extra test for makeArray, related to [5481] 2008-05-07 00:46:14 +00:00
Ariel Flesler
ba48be3ada test runner: translated all the ok() with '==' to equals(), as it gives more information on failures. 2008-05-06 18:56:02 +00:00
Ariel Flesler
6fc2c67581 test runner: adding some tests that were missing for the $ constructor. 2008-05-06 00:42:59 +00:00
Scott González
f8698395ac core: Fixed #2605: .data() now accepts null as a value. 2008-05-03 01:51:55 +00:00
Scott González
ad3c49d1b6 core: Fixed #2605: .data() now accepts null as a value. 2008-05-03 01:39:27 +00:00
Scott González
35c68b4578 core: Fixed #2600: jQuery.extend no longer skips over null properties. 2008-05-02 19:49:41 +00:00
Ariel Flesler
f54d277df4 test runner: voided the failing tests for jQuery.map, that belong to an unapproved proposal(#2616). 2008-04-29 20:54:30 +00:00
Ariel Flesler
5ca908d3b6 test runner: added another test for makeArray. 2008-04-29 20:52:48 +00:00
Jörn Zaefferer
ab756ceab0 jquery core: tests for #2616 2008-04-28 14:00:27 +00:00
Ariel Flesler
508b1e2432 jquery core: fixed makeArray to recognize the window (has length)
test runner: updated the tests for makeArray
2008-04-25 03:48:07 +00:00
Jörn Zaefferer
f8e5fd6fef jquery core: Patch from #2619 applied, making makeArray more flexible and faster; removed hint to ticket from (previously failing) test 2008-04-24 21:23:36 +00:00
Ariel Flesler
291f071eff - adding the tests for the changes to $.makeArray, proposed at #2619 2008-04-22 23:07:35 +00:00
John Resig
b0c7df65d0 You can now overwrite values returned from .data() with .bind("getData") - returning a value will override any bound value on that element. 2008-02-03 18:43:04 +00:00
John Resig
4a11e6d70b Tweaked the .data() event triggering - it now triggers a single 'setData' event, passing in a key value pair of what was changed. 2008-02-03 17:56:21 +00:00
John Resig
77da94552e Added $().data(), $().removeData(), and .bind("click!"). .data() and .removeData() handle namespaced data, .data() triggers a "set-KEY" event on all modified elements, and .bind("click!") only triggers a click (and no namespaced events). 2008-02-03 04:05:24 +00:00
David Serduke
1faed11e3c Fix #2184 by using the jQuery.clean() function instead of a direct innerHTML assignment in the clone() function for IE. 2008-01-23 03:54:23 +00:00
John Resig
d0fae71464 Discontinued the test for $(form.elements). 2008-01-14 20:40:05 +00:00