Commit Graph

115 Commits

Author SHA1 Message Date
Sam Stephenson
d6bf5e40ce prototype: Make document.getElementsByClassName match a subset of the WHATWG Web Applications 1.0 specification which was adopted in Firefox 3 (http://www.whatwg.org/specs/web-apps/current-work/#getelementsbyclassname). It now supports multiple class names given as a whitespace-separated list in a string. Array argument is not supported. The method will only return the nodes that match all the class names. In browsers that implement the method natively it will not be overwritten. Closes #8401. 2007-06-19 20:59:14 +00:00
Thomas Fuchs
0894f235b8 Begone, test artifacts 2007-06-17 22:29:44 +00:00
Thomas Fuchs
a611146f61 Ahem, linebreak in changelog 2007-06-17 22:28:10 +00:00
Thomas Fuchs
03ae9dd3ee * Make document.getElementsByClassName match the WHATWG Web Applications 1.0 specification which was adopted in Firefox 3 (http://www.whatwg.org/specs/web-apps/current-work/#getelementsbyclassname). It now supports multiple class names given as an array or a space-separated list in a string. The method will only return the nodes that match all the class names. In browsers that implement the method natively it will not be overwritten. Closes #8401. [Mislav Marohnic] 2007-06-17 22:26:46 +00:00
Thomas Fuchs
afbef44cd6 Prototype: save a few lines in Element.Methods.hasClassName 2007-06-17 22:14:07 +00:00
Thomas Fuchs
1b8ef5af86 Fix a Safari rendering issue when floating elements could temporarily disappear when opacity was set to 1. Closes #7063. References #3044, #3813, #6706. [Thomas Fuchs, davidjrice] 2007-06-17 18:13:37 +00:00
Thomas Fuchs
9ff57b042d Prevent a crash in Safari when calling String#evalJSON(true) on very large strings. Add String#isJSON. Closes #7834. [Tobie Langel] 2007-06-17 16:03:38 +00:00
Thomas Fuchs
1e13c1d0b7 Prototype: Prevent a crash in Safari 1.3 on String#stripScripts and String#extractScripts. Closes #8332. Allow JSON data to contain line breaks. Closes #8271. 2007-06-13 20:57:19 +00:00
Thomas Fuchs
d5665e0d22 Prototype: add failing unit test (IE) for Element.Methods.getStyle on auto-calculated widths. References #8564. 2007-06-10 12:58:32 +00:00
Thomas Fuchs
51bb86dc39 Add Hash.prototype.index which returns the first found property that has a specific value. Closes #8528. [Thomas Fuchs, slusarz, Mislav Marohnic] 2007-06-10 11:09:06 +00:00
Sam Stephenson
ae2ea8a2e9 prototype: Ensure HTMLElement exists before creating Element.extend. 2007-06-09 01:51:26 +00:00
Thomas Fuchs
4a648c6434 Use methodize() for the Math aliases 2007-06-06 16:28:18 +00:00
Thomas Fuchs
86118c3cb5 Prototype: Add Number.prototype.round/ceil/floor/abs as an aliases to the respective methods in Math. Refactor to seperate number extensions from base.js. [Thomas Fuchs] 2007-06-06 16:10:16 +00:00
Thomas Fuchs
0c7bac17f0 Prototype: Make Element#absolutize and Element#relativize properly use Element#getStyle. Closes #8580. [Christophe Porteneuve] 2007-06-06 14:30:01 +00:00
Thomas Fuchs
225597cb35 Prototype: Add Number.prototype.round as an alias to Math.round(). [Thomas Fuchs] 2007-06-06 12:08:15 +00:00
Thomas Fuchs
431dd4e994 Prototype: Test library fixes: make rake dist work on Windows, only teardown if a browser is supported. Closes #8463, #8498. [Mislav Marohnic, grant] 2007-06-04 10:02:01 +00:00
Thomas Fuchs
ae8d11d819 Prototype: make new insertion syntax work again on Ajax.Updater 2007-06-02 16:32:43 +00:00
Thomas Fuchs
5f4bab4dcb Prototype: Fix Element.insert for null values and numeric values when defaulting to bottom 2007-06-02 16:00:47 +00:00
Thomas Fuchs
d4d4fddc7c Prototype: Change Element.insert syntax to allow multiple positions. 2007-06-02 15:08:50 +00:00
Thomas Fuchs
67783190f4 whitespace is my homeboy 2007-05-31 22:35:13 +00:00
Thomas Fuchs
4cafec8a9c Prototype: String.prototype.truncate now explicitly converts its return value into a string if no truncation takes place. This prevents possible issues with methods expecting input data that is typeof == string. 2007-05-31 22:32:25 +00:00
Sam Stephenson
b61bca10da prototype: Event.findElement behaves as expected when the element passed matches the given selector. Closes #8395. 2007-05-24 07:13:55 +00:00
Thomas Fuchs
f099e670f5 Element.setOpacity now calls removeAttribute on the filter style on IE if no more filters remain, which makes Cleartype work properly. Closes #8376. 2007-05-19 00:11:46 +00:00
Sam Stephenson
55b658ac57 prototype: Event.findElement now uses Element#up (and as a result can take a CSS selector instead of just a tag name). 2007-05-18 01:44:26 +00:00
Sam Stephenson
a8a19eb439 prototype: Minor cleanup of the position methods 2007-05-18 01:21:41 +00:00
Sam Stephenson
7d2ae294a9 prototype: Fix Element#clonePosition to call Element#viewportOffset. Closes #8372. 2007-05-18 01:12:35 +00:00
Sam Stephenson
beeb12e7dd prototype: Prevent an error being thrown by $$ when #id does not exist in $$("div #id"). Closes #8325. 2007-05-18 00:51:34 +00:00
Thomas Fuchs
a7a0edd830 Make Prototype.ScriptFragment behave when including Prototype inline. 2007-05-18 00:44:20 +00:00
Thomas Fuchs
df33e410b0 testElementMethodInsert: add test for non-lowercase position argument 2007-05-12 19:12:04 +00:00
Sam Stephenson
93c43b9437 prototype: Update CHANGELOG to reflect preferred capitalization for Element#insert 2007-05-12 19:00:30 +00:00
Sam Stephenson
5e356c34a2 prototype: Update CHANGELOG 2007-05-12 05:04:02 +00:00
Sam Stephenson
83b4b337e1 Merge -r6634:HEAD from ../branches/dom.
* Make Element#update and Element#insert work for SELECT tags in IE and Opera. [Tobie Langel]

* Make Element#insert and Element#update better handle TABLE related elements in IE and Opera. Closes #7776, #8040, #7550, #7776, #7938. [Tobie Langel]

* Make Element#readAttribute('title') work in Opera. [Tobie Langel]

* Make Element#replace work with form elements in Firefox and Safari. Closes #8010, #7989. [dsl239, Tobie Langel]

* Add Element#wrap which wraps the element inside a new one. Closes #5732. [P. Vande, Tobie Langel]

* Make Element into a constructor: new Element(tagName, attributes). Add Element#writeAttribute which accepts a hash of attributes or a name/value pair. Closes #7476. [Mislav Marohnić, haraldmartin, Tobie Langel]

* Insertion overhaul: Add Element.insert(content[, position = 'Bottom']). Deprecate Insertion (kept for backwards compatibility). Make Ajax.Updater option.insertion accept both Insertion.Top or the now preferred 'Top'. Closes #7907. [Tobie Langel]
2007-05-12 05:01:56 +00:00
Sam Stephenson
67a4d00588 prototype: Refactor Element.extend and eliminate Element.extend.cache. 2007-05-12 04:32:30 +00:00
Sam Stephenson
f457c98673 prototype: Merge -r6639:HEAD from branches/rel_1-5-1 into trunk. 2007-05-01 04:19:46 +00:00
Sam Stephenson
562e61fc8c prototype: Add Function#curry, Function#delay, Function#defer, and Function#wrap. Closes #8134. 2007-04-29 05:37:07 +00:00
Sam Stephenson
e9e1a67475 prototype: trunk is now 1.5.2_pre0 2007-04-29 01:03:57 +00:00
Sam Stephenson
95df0a7c12 prototype: Prepare for 1.5.1 release. 2007-04-29 01:01:25 +00:00
Sam Stephenson
c580aea385 prototype: 1.5.1_rc4 2007-04-28 04:07:54 +00:00
Sam Stephenson
cbf8be9869 no, really! 2007-04-28 03:53:50 +00:00
Sam Stephenson
d6c7cd9c9e prototype: Fix $F breakage from [6598]. 2007-04-28 03:28:13 +00:00
Sam Stephenson
8a382ff853 prototype: Set window.$continue to an Error with a helpful message for anyone who may still be using 'throw $continue'. 2007-04-28 03:00:57 +00:00
Sam Stephenson
310b3eccfa prototype: Fix jstest.rb IE support so you don't have to close the IE window after each test (yay!). Closes #8207. 2007-04-28 02:41:00 +00:00
Sam Stephenson
b360a93999 prototype: Fix jstest.rb Konqueror support. Closes #7140. 2007-04-28 02:37:53 +00:00
Sam Stephenson
b76d34e7bb prototype: Fix regression in which no-argument calls to Element.addMethods() would not add the methods defined in Form.Methods and Form.Element.Methods. Closes #8206. 2007-04-28 02:32:21 +00:00
Sam Stephenson
1886b03d60 prototype: Fix Element#readAttribute to work with the 'type' attribute in IE. Closes #8160. 2007-04-28 02:23:26 +00:00
Sam Stephenson
d01b0b0668 changelog 2007-04-24 06:19:25 +00:00
Sam Stephenson
7857c36012 prototype: 1.5.1_rc3 2007-04-24 06:18:46 +00:00
Sam Stephenson
47bfeb5083 prototype: Add Element#childElements as an alias for Element#immediateDescendants. 2007-04-24 06:17:59 +00:00
Sam Stephenson
5784d78f6e prototype: Add Element#firstDescendant to retrieve the first non-text child node of an element. Optimize DOM navigation methods (Element#up, Element#down, Element#previous, Element#next) for no-argument calls. Closes #7848. 2007-04-24 06:06:44 +00:00
Sam Stephenson
63342b9c01 prototype: Element.addMethods should add methods to Element as well as Element.Methods. Closes #7888. 2007-04-24 05:23:41 +00:00