Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 815 lines (477 sloc) 47.52 kB
e9e1a67 @sstephenson prototype: trunk is now 1.5.2_pre0
authored
1 *SVN*
2
0632778 @tobie Add more tests to Hash.
tobie authored
3 * Add more tests to Hash. [Mislav Marohnić]
4
941359b @tobie Performance enhancements to . Closes #9464
tobie authored
5 * Performance enhancements to $A. Closes #9464. [Samuel Lebeau]
6
7dda50a @tobie Make Function#argumentNames work with named functions. Closes #9826
tobie authored
7 * Make Function#argumentNames work with named functions. Closes #9826. [Samuel Lebeau]
8
96af1b7 @tobie Add Object.isHash.
tobie authored
9 * Add Object.isHash. [Tobie Langel]
10
d195111 @tobie Performance improvements to String#times.
tobie authored
11 * Performance improvements to String#times. [Martin Ström]
12
db371dd @tobie Make Ajax.Response#getHeaderJSON and Ajax.Response#getResponseJSON ps…
tobie authored
13 * Make Ajax.Response#getHeaderJSON and Ajax.Response#getResponseJSON pseudo private instance methods. [Tobie Langel]
14
e7bb042 @tobie Make ObjectRange use the new Class.create syntax.
tobie authored
15 * Make ObjectRange use the new Class.create syntax. [Mislav Marohnić]
16
17 * Fix a failing ClassCreate test case in IE. [Tobie Langel]
18
d25b863 @tobie Complete rewrite of the Hash class.
tobie authored
19 * Complete rewrite of the Hash class.
20
21 !! BACKWARDS COMPATIBILITY CHANGE !! This new version of Hash is NOT backwards compatible with the former Hash class.
22
23 Properties are now hidden away in an private store to prevent the risk of collision with Hash's instance and mixed-in methods.
24 This implies that properties of the hash can no longer be set, accessed or deleted directly: use the new Hash#get(key), Hash#set(key, value) and Hash#unset(key) instance methods instead.
25
26 - Make $H(object) equivalent to new Hash(object). Both now return a new (cloned) instance of Hash in all circumstances.
27 - Make Hash#merge non-destructive.
28
29 - Add Hash#update (a destructive version of Hash#merge).
30 - Add Hash#clone (returns a new, cloned instance of Hash).
31 - Add Hash#toObject (returns a clone of the contained object).
32 - Add Hash#get(key) (returns the value of the specified property).
33 - Add Hash#set(key, value) (sets the value of the given property. returns the value).
34 - Add Hash#unset(key) (deletes the specified property and returns its value).
35 - Add Hash.from as a alias to $H for consistency with Array.from.
36 - Add Object.toQueryString.
37
38 - Deprecate Hash.toQueryString (use Object.toQueryString or the instance method Hash#toQueryString instead).
39
40 - Remove Hash#remove (use Hash#unset instead).
41 - Remove Hash.toJSON (use Object.toJSON or the instance method Hash#toJSON instead). [sam, Tobie Langel]
42
4607e29 @sstephenson prototype: Element#wrap now returns the wrapper instead of the elemen…
authored
43 * Element#wrap now returns the wrapper instead of the element being wrapped. [sam]
44
115d3e4 @sstephenson prototype: Namespace all custom event names to avoid conflicts with n…
authored
45 * Namespace all custom event names to avoid conflicts with native DOM events. [sam]
46 - All custom event names MUST include a namespace. Prefix custom event names for observe, stopObserving, and fire with the namespace followed by a colon. E.g. document.fire("widget:activated")
47 - The "contentloaded" event is now "dom:loaded".
48 - The Event.DOMEvents array is no longer present. If an event name does not include a namespace, the event is treated as a native event.
49
c35598c @sstephenson prototype: Clean up the new class API.
authored
50 * Clean up the new class API. [sam, Tobie Langel]
51 - Add Class#addMethods for adding instance methods to classes.
52 - Remove Class.extend and Class.mixin.
53 - Class.create now takes a variable number of arguments: if the first argument is a class, the newly created class inherits from that class; all other arguments are treated as successive calls to addMethods.
54
8ca43a5 @sstephenson prototype: Fix contentloaded event initialization in IE. Closes #945…
authored
55 * Fix contentloaded event initialization in IE. Closes #9457, #9488, #9707. [Mislav Marohnić]
56
c904fe7 @sstephenson prototype: Deprecate document.getElementsByClassName and Element#getE…
authored
57 * Deprecate document.getElementsByClassName and Element#getElementsByClassName since native versions return a NodeList and we can only return an Array. Please use $$ or Element#select instead. [sam]
58 For more information see https://bugzilla.mozilla.org/show_bug.cgi?id=390411
59
cf88669 @sstephenson prototype: Fix missing "var" in selector.js. Closes #9761.
authored
60 * Fix missing "var" in selector.js. Closes #9761. [Tobie Langel]
61
4b1fb7e @sstephenson prototype: Date#toJSON now returns times in UTC for better compatibil…
authored
62 * Date#toJSON now returns times in UTC for better compatibility with json.js. Closes #9332. [Tobie Langel]
63
8cf1f89 @sstephenson prototype: Ensure document._getElementsByXPath extends the elements i…
authored
64 * Ensure document._getElementsByXPath extends the elements it returns; fixes $$ not returning extended elements in Opera 9.2. Closes #8843. [jdalton]
65
66 * Update Prototype.Browser.MobileSafari for iPod touch compatibility. [sam]
67
746a905 @madrobby Add tests for Object.extend and Object.clone.
madrobby authored
68 * Add tests for Object.extend and Object.clone. [Tobie Langel]
69
cca235b @madrobby Prototype: Add a test for Form.Observer.
madrobby authored
70 * Add a test for Form.Observer. [Christoph Sturm]
71
6c94af7 @madrobby Make sure setting opacity works on elements that have "no layout" in IE.
madrobby authored
72 * Make sure setting opacity works on elements that have "no layout" in IE. [Thomas Fuchs]
73
6ed9095 @sstephenson prototype: Simplify Class.create by establishing a prototype chain wh…
authored
74 * Simplify Class.create by establishing a prototype chain when subclassing. Closes #9342. [Ben Newman]
75
5d3fd6f @sstephenson prototype: Fix Ajax.PeriodicalUpdater for compatibility with Ajax.Res…
authored
76 * Fix Ajax.PeriodicalUpdater for compatibility with Ajax.Response. Closes #9321. [kampers]
77
001b548 @sstephenson prototype: Ensure that classes always have an initialize method.
authored
78 * Ensure that classes always have an initialize method. [Mislav Marohnić]
79
6086db4 @sstephenson prototype: Update Template, Selector, Ajax.*, and ObjectRange classes…
authored
80 * Update Template, Selector, Ajax.*, and ObjectRange classes to use the new class system. [Mislav Marohnić]
81
75b3f3c @sstephenson prototype: Change Abstract.TimedObserver to subclass PeriodicalExecut…
authored
82 * Change Abstract.TimedObserver to subclass PeriodicalExecuter and tweak its subclasses to use new inheritance functionality. TimedObserver can now be stopped the same way as PeriodicalExecuter. Closes #8589. [Mislav Marohnić]
83
bfba40e @sstephenson prototype: Fix Class.mixin to extend the class's prototype.
authored
84 * Fix Class.mixin to extend the class's prototype. [Mislav Marohnić]
85
b923d6d @sstephenson prototype: Fix superclass method call breakage from [7337].
authored
86 * Fix superclass method call breakage from [7337]. [Mislav Marohnić, sam]
87
702d968 @sstephenson prototype: Change Class.extend to allow for superclass method resolut…
authored
88 * Change Class.extend to allow for superclass method resolution and remove Class.inherit. Closes #9274. [Samuel Lebeau]
89
b2f884b @sstephenson prototype: Event handlers are now bound to the observed element, not …
authored
90 * Event handlers are now bound to the observed element, not the event's target element. [Dan Webb]
91
aa1a7f5 @madrobby prototype: Define Node constants conditionally after checking for Nod…
madrobby authored
92 * Define Node constants conditionally after checking for Node.ELEMENT_NODE presence. Add unit test to check the values of all constants. Closes #7625. [Mislav Marohnić]
93
194fda0 @madrobby prototype: Make sure Enumerable#include doesnt do type comparision. …
madrobby authored
94 * Make sure Enumerable#include doesn't do type comparision. [Mislav Marohnić]
95
f86ac77 @madrobby Prototype: Add contextmenu to Event.DOMEvents.
madrobby authored
96 * Add contextmenu to Event.DOMEvents. [Thomas Fuchs]
97
1a0f6b3 @madrobby Prototype: update trunk CHANGELOG
madrobby authored
98 *1.6.0_rc0* (August 15, 2007)
99
d8b8c65 @sstephenson prototype: Fix readAttribute-related failure in form.html in IE.
authored
100 * Fix readAttribute-related failure in form.html in IE. [sam, Andrew Dupont]
101
c27f2de @sstephenson prototype: Fix failing dom.html and selector.html tests in IE.
authored
102 * Fix failing dom.html and selector.html tests in IE. [Tobie Langel, Andrew Dupont]
103
c603fc5 @sstephenson prototype: Make sure the WebKit redefinition of Element#cumulativeOff…
authored
104 * Make sure the WebKit redefinition of Element#cumulativeOffset uses Element._returnOffset. Closes #9245. [mdaines]
105
11f25aa @sstephenson prototype: Make sure Element#observe is always chainable.
authored
106 * Make sure Element#observe and Element#stopObserving are always chainable. [sam]
d2974cf @sstephenson prototype: Make sure Element#stopObserving is always chainable.
authored
107
14ea77e @sstephenson prototype: Event.fire/Element#fire now returns the newly-fired event …
authored
108 * Event.fire/Element#fire now returns the newly-fired event instead of the event's target element. [sam]
109
d7da841 @sstephenson prototype: Restrict Event.DOMEvents to include only events that can b…
authored
110 * Restrict Event.DOMEvents to include only events that can be supported in all browsers. [sam]
111
ffa744e @sstephenson prototype: Fix a failing test in base.html in Safari 2.
authored
112 * Fix a failing test in base.html in Safari 2. [Tobie Langel]
113
5f76c25 @madrobby Fix Element#positionedOffset and Element#getOffsetParent for static e…
madrobby authored
114 * Fix Element#positionedOffset and Element#getOffsetParent for static elements on IE. [Thomas Fuchs]
115
2fbb490 @sstephenson prototype: Make sure event handlers and their wrappers are removed fr…
authored
116 * Make sure event handlers and their wrappers are removed from the cache by Event.stopObserving. [sam, Severin Heiniger]
117
f3d9cb2 @madrobby Add line numbers to failures when unit testing in Firefox. Closes #9…
madrobby authored
118 * Add line numbers to failures when unit testing in Firefox. Closes #9231. [John Resig]
119
e75cd0a @sstephenson prototype: Fix Function#argumentNames for IE
authored
120 * Fix Function#argumentNames for Opera and IE. [Thomas Fuchs]
220f637 @sstephenson prototype: Fix Function#argumentNames for Opera
authored
121
df71a6b @sstephenson prototype: Add Object.isString, Object.isNumber, and Object.isUndefin…
authored
122 * Add Object.isString, Object.isNumber, and Object.isUndefined, and clean up the source to make use of Object.isXXX where possible. [sam]
123
ae2ab03 @sstephenson prototype: Add the document.viewport object for querying dimensions a…
authored
124 * Add the document.viewport object for querying dimensions and scroll offsets of the browser viewport. [Andrew Dupont, Thomas Fuchs, sam]
125 Example:
126 document.viewport.getDimensions() // { width: 1149, height: 923 }
127 document.viewport.getWidth() // 1149
128 document.viewport.getHeight() // 923
129 document.viewport.getScrollOffsets() // { left: 0, top: 1592 }
130
c488384 @sstephenson prototype: Add support for brackets in quoted attribute value selecto…
authored
131 * Add support for brackets in quoted attribute value selectors. Closes #9157. [Ken Snyder]
132
133 * Add some missing semicolons to the source tree. Closes #9140. [jdalton]
134
cbaec75 @madrobby Prototype: Fix event extensions and custom events firing for Safari 2.0
madrobby authored
135 * Fix event extensions and custom events firing for Safari 2.0. [Thomas Fuchs]
136
30aa7a6 @sstephenson prototype: Add RegExp.escape for escaping regular expression strings.…
authored
137 * Add RegExp.escape for escaping regular expression strings. Closes #9094. [Ken Snyder]
138
aa4602b @sstephenson prototype: Merge -r7242:HEAD from ../branches/1-6-0-events. Adds sup…
authored
139 * Make the eventName and handler arguments to Event.stopObserving optional. If no handler is specified, all handlers for the given event are unregistered. If no event name is specified, all observed events on the element are unregistered. [sam]
140
141 * Add cross-support for the DOMContentLoaded event through a Prototype custom event on document called "contentloaded". The DOMContentLoaded event fires before window.load, when the entire HTML document, but not necessarily its images, stylesheets or other assets, has loaded. Based on [6596]. [sam, Mislav Marohnić]
142 Example:
143 document.observe("contentloaded", function() {
144 $$("a").invoke("identify"); // give all <a> tags an ID
145 });
146
147 * Add Event.fire and Element.Methods.fire for firing custom events. Prototype custom events piggyback on a real DOM event ("ondataavailable"), so they bubble and cancel. You can fire custom events from any element, or fire global events on the document object. Observe custom events just as you'd observe a regular DOM event. [sam, Seth Dillingham]
148
149 * Extend the event object with methods from Event.Methods and normalize it in IE. [sam, Mislav Marohnić]
150
151 * Remove support for observing the capturing phase of DOM events, since we can't support it in all browsers. [sam]
152
52cf3f2 @sstephenson prototype: Merge -r7016:HEAD from ../branches/ajax. Add Ajax.Response…
authored
153 * Add Ajax.Response object which supports the following methods: responseJSON, headerJSON, getHeader, getAllHeaders and handles browser discrepancies in the other response methods. Add sanitizeJSON, evalJS and evalJSON to Ajax.Request. Closes #8122, #8006, #7295. [Tobie Langel]
154
155 * Add an isRunningFromRake property to unit tests. [Tobie Langel]
156
157 * Add support for Opera browser in jstest.rb. [Tobie Langel]
158
281ac64 @sstephenson prototype: Merge -r6792:HEAD from ../branches/inheritance/{src/base.j…
authored
159 * Inheritance branch merged to trunk; robust inheritance support for Class.create. Closes #5459. [Dean Edwards, Alex Arnell, Andrew Dupont, Mislav Mahronic]
160 - To access a method's superclass method, add "$super" as the first argument. (The naming is significant.) Works like Function#wrap.
161 - Class.create now takes two optional arguments. The first is an existing class to subclass; the second is an object literal defining the instance properties/methods. Either can be omitted. Backwards-compatible with old Class.create.
162 - Added Class.extend for dynamically adding methods to existing classes (while preserving inheritance chain). Can also be used for mixins.
163 - The 'constructor' property of a class instance always points back to the proper class. Class objects themselves have two special properties: 'superclass' and 'subclasses' (which default to 'null' and '[]', respectively). Allows for powerful introspection.
164 - Added Object.isFunction [sam]
165
90c9c69 @sstephenson prototype: Add Function#argumentNames, which returns an ordered array…
authored
166 * Add Function#argumentNames, which returns an ordered array of the function's named arguments. [sam]
167
52cf3f2 @sstephenson prototype: Merge -r7016:HEAD from ../branches/ajax. Add Ajax.Response…
authored
168 * Prevent a crash in Safari 1.3 on String#stripScripts and String#extractScripts. Closes #8332. [grant, Tobie Langel]
169
5645a07 @sstephenson prototype: Add Prototype.Browser.MobileSafari which evaluates to true…
authored
170 * Add Prototype.Browser.MobileSafari which evaluates to true on the iPhone's browser. [sam]
171
82bedce @sstephenson prototype: Optimize Selector#match and Element#match for simple selec…
authored
172 * Optimize Selector#match and Element#match for simple selectors. Closes #9082. [Andrew Dupont]
173
a529bcf @sstephenson prototype: Remove the dependency on Element.ClassNames from Element#a…
authored
174 * Remove the dependency on Element.ClassNames from Element#addClassName/removeClassName/toggleClassName, and deprecate Element.ClassNames. Closes #9073. [Tobie Langel]
175
c0735db @sstephenson prototype: Make Element#wrap accept a second argument for setting att…
authored
176 * Make Element#wrap accept a second argument for setting attributes on the wrapper. Allow wrapping elements which are not part of the document. Closes #9071. [Tobie Langel]
177
44ef748 @sstephenson prototype: Improvements for Element#replace, Element#update and Eleme…
authored
178 * Improvements for Element#replace, Element#update and Element#insert. Closes #7429, #9060. [Tobie Langel]
179 - Element#replace/update/insert uses the argument's toElement or toHTML method if present (toElement has precedence if both are present).
180 - Element#replace and Element#update now also accept DOM elements.
181 - Element#replace better handles table-related elements in IE and Opera.
182
183 * Add Object.isArray and Object.isElement (returns true if the object is a DOM node of type 1). [Tobie Langel]
184
185 * Add Object.toHTML (uses the object's toHTML method if present or else passes the object to String.interpret). [Tobie Langel]
186
7b2ce66 @sstephenson prototype: Make Element#setStyle accept a string argument of CSS rule…
authored
187 * Make Element#setStyle accept a string argument of CSS rules. Deprecate uncamelized style property names when setting styles using an object (for performance reasons). Closes #9059. [Tobie Langel]
188 Examples:
189 $('id').setStyle('font-size: 12px; float: left; opacity: 0.5');
190 $('id').setStyle({fontSize: '12px', cssFloat: 'left', opacity: 0.5});
191
192 !! BACKWARDS COMPATIBILITY CHANGE !!
193
194 If you have code that looks like this:
195 $('id').setStyle({'font-size': '12px'});
196 You need to replace it with either of the following:
197 $('id').setStyle({fontSize: '12px'});
198 $('id').setStyle('font-size: 12px;');
199
c6f3daa @sstephenson prototype: Add Element#identify, which returns the element's ID if it…
authored
200 * Add Element#identify, which returns the element's ID if it exists, or sets and returns a unique, auto-generated ID (of the form "anonymous_element_" + auto-incremented digit) otherwise. Use this when you need to ensure an element has an ID. Closes #9012. [Jeff Watkins, sam, Tobie Langel]
201
7e6481b @sstephenson prototype: Make Element#readAttribute work for cloned elements in IE.…
authored
202 * Make Element#readAttribute work for cloned elements in IE. Closes #8481. [chem, Tobie Langel]
203
ff45622 @sstephenson prototype: Template enhancements. Closes #8166.
authored
204 * Template enhancements. Closes #8166. [Christophe Porteneuve]
205 - Added String#interpolate as a shortcut for new Template(...).evaluate(...).
206 - If you pass String#interpolate or Template#evaluate an object with a toTemplateReplacements() method, the return value of that method will be used as the replacement object.
207 - You can now substitute properties of template replacement values in template strings, using dot or bracket notation (or both). Example:
208 "#{name.last}, #{name.first[0]}. (#{location})".interpolate({
209 name: { first: "Christophe", last: "Porteneuve" }, location: "Paris"
210 }) // "Porteneuve, C. (Paris)"
211
212 * Extended grep semantics. The first argument to Enumerable#grep is now a "filter" (an object with a match() method) so you can now e.g. filter an array of DOM nodes by CSS selector. RegExp#match is now an alias to RegExp#test, so grep can still be used to filter an array of strings with a regular expression. Closes #7596. [Christophe Porteneuve, sam]
b59399b @sstephenson prototype: Extended grep semantics. The first argument to Enumerable…
authored
213
38fa39a @sstephenson prototype: Make String#scan explicitly return a string. Closes #6350.
authored
214 * Make String#scan explicitly return a string. This prevents possible issues with methods expecting input data that is typeof == 'string'. Closes #6350. [AndrewRev, Tobie Langel]
215
513042d @madrobby Add Array#intersect for set intersection. Returns a new array contain…
madrobby authored
216 * Add Array#intersect for set intersection. Returns a new array containing all items common to the array and the argument, with duplicates removed (clone of the Ruby & method). [Thomas Fuchs]
217 Example:
218 [1,1,3,5].intersect([1,2,3]) -> [1,3]
219
cea24d6 @madrobby Prototype: Rename Element#getElementsBySelector to Element#select and…
madrobby authored
220 * Rename Element#getElementsBySelector to Element#select and add alias for Element#getElementsBySelector. [Thomas Fuchs]
221
222 * Add Element#adjacent as a shortcut to selecting all adjacent nodes (and their children) that match a CSS selector. [Thomas Fuchs]
223
1c17b63 @sstephenson prototype: Enhance the Enumerable and Array APIs to more closely matc…
authored
224 * Enhance the Enumerable and Array APIs to more closely match those of JavaScript 1.6 as implemented in Firefox 1.5. Closes #6650, #8409. [Mislav Marohnić, Sylvain Zimmer]
225 - Add Array#lastIndexOf, and change Array#indexOf not to overwrite the native method.
226 - Make Enumerable use Array.prototype.forEach instead of _each when possible (slight speed increase).
227 - Add "filter", "entries", "every", and "some" Array aliases.
228 - All Enumerable methods now have an additional parameter, "context", which, if present, specifies the object to which the iterators' "this" is bound.
229 - Function#bind and #curry now return the receiving function if the binding object is undefined.
230
29cd62e @sstephenson prototype: Temporary workaround for Prototype.BrowserFeatures.Specifi…
authored
231 * Temporary workaround for Prototype.BrowserFeatures.SpecificElementExtensions incorrectly evaluating to true on iPhone. (needs further investigation) [sam]
232
9e7efd5 @madrobby Prototype: merges from form branch. Closes #5031, #5902, #7595, #840…
madrobby authored
233 * The action for Form#request defaults to the current URL if the "action" attribute is empty. (This is what most of the major browsers do.) Fixes #8483. [Tomas, Mislav Marohnić]
234
235 * In form serialization, change the way submit buttons are handled. Previously all submit buttons were serialized; now Prototype serializes only the first one. Change Form#serialize and Form.serializeElements to accept a params hash. With the "hash: false" option, a serialized string is returned instead of the hash data object. With the "submit: 'foo'" option, only the submit button with the name "foo" is serialized. References #5031. [Mislav Marohnić]
236 Examples:
237 $('form').serialize({ submit: 'delete' })
238 $('form').serialize({ hash: false }) //-> equivalent to $('form').serialize()
239
240 * Form#findFirstElement respects HTML tabindexes. Closes #7595. [Christophe Porteneuve]
241
242 * Added Form.Element#setValue method for setting values on various form controls. Checkboxes and radio buttons respond to a boolean and multiple select boxes expect an array of values. Closes #5902. [Jonathan Viney, Mislav Marohnić]
243 Examples:
244 $('text_input').setValue('hello world!')
245 $('remember_me').setValue(true)
246 $('attend_classes').setValue(['cheese rolling', 'evil chemistry'])
247
f2d304b @sstephenson prototype: Merge [7066] from branches/1-5-1-1
authored
248 * 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. [Mislav Marohnić]
d6bf5e4 @sstephenson prototype: Make document.getElementsByClassName match a subset of the…
authored
249 Example:
03ae9dd @madrobby * Make document.getElementsByClassName match the WHATWG Web Applicati…
madrobby authored
250 document.getElementsByClassName('foo bar')
251
1b8ef5a @madrobby Fix a Safari rendering issue when floating elements could temporarily…
madrobby authored
252 * 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]
9ff57b0 @madrobby Prevent a crash in Safari when calling String#evalJSON(true) on very …
madrobby authored
253
1b8ef5a @madrobby Fix a Safari rendering issue when floating elements could temporarily…
madrobby authored
254 * Prevent a crash in Safari when calling String#evalJSON(true) on very large strings. Add String#isJSON. Closes #7834. [Tobie Langel]
1e13c1d @madrobby Prototype: Prevent a crash in Safari 1.3 on String#stripScripts and S…
madrobby authored
255
1b8ef5a @madrobby Fix a Safari rendering issue when floating elements could temporarily…
madrobby authored
256 * Prevent a crash in Safari 1.3 on String#stripScripts and String#extractScripts. Closes #8332. [grant, Tobie Langel]
257
258 * Allow JSON data to contain line breaks. Closes #8271. [pijyster, Tobie Langel]
1e13c1d @madrobby Prototype: Prevent a crash in Safari 1.3 on String#stripScripts and S…
madrobby authored
259
51bb86d @madrobby Add Hash.prototype.index which returns the first found property that …
madrobby authored
260 * Add Hash.prototype.index which returns the first found property that has a specific value. Closes #8528. [Thomas Fuchs, slusarz, Mislav Marohnić]
261 Examples:
262 var hash = $H({a:1,b:'2'});
263 hash.index(1) // -> 'a'
264 hash.index('1') // -> undefined
265
ae2ea8a @sstephenson prototype: Ensure HTMLElement exists before creating Element.extend.
authored
266 * Ensure HTMLElement exists before creating Element.extend. [Tobie Langel]
267
86118c3 @madrobby Prototype: Add Number.prototype.round/ceil/floor/abs as an aliases to…
madrobby authored
268 * 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]
0c7bac1 @madrobby Prototype: Make Element#absolutize and Element#relativize properly us…
madrobby authored
269
86118c3 @madrobby Prototype: Add Number.prototype.round/ceil/floor/abs as an aliases to…
madrobby authored
270 * Make Element#absolutize and Element#relativize properly use Element#getStyle. Closes #8580. [Christophe Porteneuve]
225597c @madrobby Prototype: Add Number.prototype.round as an alias to Math.round(). […
madrobby authored
271
431dd4e @madrobby Prototype: Test library fixes: make rake dist work on Windows, only t…
madrobby authored
272 * Test library fixes: make rake dist work on Windows, only teardown if a browser is supported. Closes #8463, #8498. [Mislav Marohnić, grant]
273
d4d4fdd @madrobby Prototype: Change Element.insert syntax to allow multiple positions.
madrobby authored
274 * Change Element.insert syntax to allow multiple positions. [Thomas Fuchs]
275 Examples:
276 Element.insert('foo', {top:'bar', bottom:'baz'});
277 $('foo').insert({after: new Element('p').update('bar')});
278 Element.insert('foo', new Element('p').update('bar')); // defaults to bottom
279 Element.insert('foo', 'bar'); // defaults to bottom
280
4cafec8 @madrobby Prototype: String.prototype.truncate now explicitly converts its retu…
madrobby authored
281 * 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'. [Thomas Fuchs, Tobie Langel, Sam Stephenson]
282
b61bca1 @sstephenson prototype: Event.findElement behaves as expected when the element pas…
authored
283 * Event.findElement behaves as expected when the element passed matches the given selector. Closes #8395. [Mislav Marohnić, Tobie Langel]
284
f099e67 @madrobby Element.setOpacity now calls removeAttribute on the filter style on I…
madrobby authored
285 * Element.setOpacity now calls removeAttribute on the filter style on IE if no more filters remain, which makes Cleartype work properly. Closes #8376. [alexdemi, Thomas Fuchs]
286
55b658a @sstephenson prototype: Event.findElement now uses Element#up (and as a result can…
authored
287 * Event.findElement now uses Element#up (and as a result can take a CSS selector instead of just a tag name). [Tobie Langel]
288
a8a19eb @sstephenson prototype: Minor cleanup of the position methods
authored
289 * Minor cleanup of the position methods [sam]
290
7d2ae29 @sstephenson prototype: Fix Element#clonePosition to call Element#viewportOffset. …
authored
291 * Fix Element#clonePosition to call viewportOffset. Closes #8372. [graemenelson, Christophe Porteneuve]
292
beeb12e @sstephenson prototype: Prevent an error being thrown by $$ when #id does not exis…
authored
293 * Prevent an error being thrown by $$ when #id does not exist in $$("div #id"). Closes #8325. [Tobie Langel, ecke]
294
a7a0edd @madrobby Make Prototype.ScriptFragment behave when including Prototype inline.
madrobby authored
295 * Make Prototype.ScriptFragment behave when including Prototype inline. [Christophe Porteneuve]
296
5e356c3 @sstephenson prototype: Update CHANGELOG
authored
297 * Deprecate Position (kept for backwards compatibility). Add Element#cumulativeOffset, Element#positionedOffset, Element#absolutize, Element#relativize, Element#cumulativeScrollOffset, Element#getOffsetParent, Element#viewportOffset and Element#clonePosition. [Christophe Porteneuve]
298
83b4b33 @sstephenson Merge -r6634:HEAD from ../branches/dom.
authored
299 * Make Element#update and Element#insert work for SELECT tags in IE and Opera. [Tobie Langel]
300
301 * Make Element#insert and Element#update better handle TABLE related elements in IE and Opera. Closes #7776, #8040, #7550, #7776, #7938. [Tobie Langel]
302
303 * Make Element#readAttribute('title') work in Opera. [Tobie Langel]
304
305 * Make Element#replace work with form elements in Firefox and Safari. Closes #8010, #7989. [dsl239, Tobie Langel]
306
307 * Add Element#wrap which wraps the element inside a new one. Closes #5732. [P. Vande, Tobie Langel]
308
309 * 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]
310
93c43b9 @sstephenson prototype: Update CHANGELOG to reflect preferred capitalization for E…
authored
311 * 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]
83b4b33 @sstephenson Merge -r6634:HEAD from ../branches/dom.
authored
312
67a4d00 @sstephenson prototype: Refactor Element.extend and eliminate Element.extend.cache.
authored
313 * Refactor Element.extend and eliminate Element.extend.cache. [sam]
314
562e61f @sstephenson prototype: Add Function#curry, Function#delay, Function#defer, and Fu…
authored
315 * Add Function#curry, Function#delay, Function#defer, and Function#wrap. Closes #8134. [Andrew Dupont, Tobie Langel, sam]
316
f457c98 @sstephenson prototype: Merge -r6639:HEAD from branches/rel_1-5-1 into trunk.
authored
317 *1.5.1* (May 1, 2007)
318
319 * Don't duplicate the event argument in Function#bindAsEventListener. Closes #6497. [wiktor]
320
321 * Fix Selector :not-clause chaining. [Andrew Dupont]
95df0a7 @sstephenson prototype: Prepare for 1.5.1 release.
authored
322
c580aea @sstephenson prototype: 1.5.1_rc4
authored
323 *1.5.1_rc4* (April 27, 2007)
1886b03 @sstephenson prototype: Fix Element#readAttribute to work with the 'type' attribut…
authored
324
d6c7cd9 @sstephenson prototype: Fix $F breakage from [6598].
authored
325 * Fix $F breakage from [6598]. [sam]
326
8a382ff @sstephenson prototype: Set window.$continue to an Error with a helpful message fo…
authored
327 * Set window.$continue to an Error with a helpful message for anyone who may still be using "throw $continue". [sam]
328
310b3ec @sstephenson prototype: Fix jstest.rb IE support so you don't have to close the IE…
authored
329 * Fix jstest.rb IE support so you don't have to close the IE window after each test (yay!). Closes #8207. [Ryan Schuft]
330
b360a93 @sstephenson prototype: Fix jstest.rb Konqueror support. Closes #7140.
authored
331 * Fix jstest.rb Konqueror support. Closes #7140. [Christophe Porteneuve]
332
b76d34e @sstephenson prototype: Fix regression in which no-argument calls to Element.addMe…
authored
333 * 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. [Tobie Langel, fwittekind]
334
1886b03 @sstephenson prototype: Fix Element#readAttribute to work with the 'type' attribut…
authored
335 * Fix Element#readAttribute to work with the 'type' attribute in IE. Closes #8160. [Tobie Langel, Wiktor Ihárosi]
336
337 *1.5.1_rc3* (April 24, 2007)
fc91a3e @madrobby Fix an issue with String.prototype.endsWith. Closes #7822. [altblue]
madrobby authored
338
47bfeb5 @sstephenson prototype: Add Element#childElements as an alias for Element#immediat…
authored
339 * Add Element#childElements as an alias for Element#immediateDescendants. [Tobie Langel]
340
5784d78 @sstephenson prototype: Add Element#firstDescendant to retrieve the first non-text…
authored
341 * Optimize DOM navigation methods (Element#up, Element#down, Element#previous, Element#next) for no-argument calls. Closes #7848. [haraldmartin, sam]
342
343 * Add Element#firstDescendant to retrieve the first non-text child node of an element. [sam]
344
63342b9 @sstephenson prototype: Element.addMethods should add methods to Element as well a…
authored
345 * Element.addMethods should add methods to Element as well as Element.Methods. Closes #7888. [Andrew Dupont]
346
7a324b8 @sstephenson prototype: Add support for per-request onCreate callbacks to Ajax.Req…
authored
347 * Add support for per-request onCreate callbacks to Ajax.Request. Closes #8011. [Andrew Dupont]
348
4174060 @sstephenson prototype: Don't call evalResponse() when an Ajax response has no Con…
authored
349 * Don't call evalResponse() when an Ajax response has no Content-type header. Closes #7827. [Tobie Langel]
350
fea6bc1 @sstephenson prototype: Automatically strip security delimiter comments from JSON …
authored
351 * Automatically strip security delimiter comments from JSON strings before evaling them. The default delimiter is '/*-secure- ... */' or you can specify your own with the Prototype.JSONFilter regular expression. If you wrap your JSON response bodies in this delimiter on the server side, rogue external sites can't hijack potentially sensitive data via <script> tags. Closes #7910. [Tobie Langel]
352 For more details on potential security problems, see: http://www.fortifysoftware.com/servlet/downloads/public/JavaScript_Hijacking.pdf
353
643b7be @sstephenson prototype: Add extra spacing so Array#toJSON and Hash#toJSON generate…
authored
354 * Add extra spacing so Array#toJSON and Hash#toJSON generate YAML-loadable JSON. Closes #7883. [Andrew Dupont]
355
95ac141 @madrobby Fix Form.request for forms containing an input element with name="act…
madrobby authored
356 * Fix Form.request for forms containing an input element with name="action". Closes #8063. [Thomas Fuchs, Mislav Marohnić]
357
358 * Make Event.element extend the returned element. Closes #7870. [Thomas Fuchs]
359
68f3b21 @madrobby Fix a CHANGELOG typo
madrobby authored
360 * Prevent a crash on Safari on String.prototype.stripScripts and extractScripts with large <script> tags. [Thomas Fuchs]
4c90be6 @madrobby Prevent a crash on Safari on String.prototype.stripScripts and extrac…
madrobby authored
361
c0509c7 @madrobby Prototype: clean (un)escapeHTML IE special casing and optimize speed …
madrobby authored
362 * Prevent linefeed normalisation in String.prototype.escapeHTML and unescapeHTML on IE for consistency with other browsers. Speed optimizations for Safari and IE. [Thomas Fuchs]
9a7dcd5 @madrobby Prevent linefeed normalisation in String.prototype.escapeHTML and une…
madrobby authored
363
5f2acb4 @madrobby Make Hash.toQueryString serialize undefined values. Ensure consistenc…
madrobby authored
364 * Make Hash.toQueryString serialize undefined values. Ensure consistency with String.prototype.toQueryParams. Closes #7806. [Mislav Marohnić]
365 Examples:
366 $H({a:'b',c:undefined}).toQueryString() -> 'a=b&c'
367 $H({a:'b',c:null}).toQueryString() -> 'a=b&c='
368 $H('a=b&c'.toQueryParams()).toQueryString() -> 'a=b&c'
369 $H('a=b&c='.toQueryParams()).toQueryString() -> 'a=b&c='
370
4506db2 @madrobby Fix Selector issues with :not and attribute selector double quotes, f…
madrobby authored
371 * Fix issues with Selector an+b logic, :not support, attribute selector double quotes, plus performance improvements. Closes #7873, #7901. [Andrew Dupont]
779cd33 @madrobby Fix issues with Selector an+b logic, performance improvements. Close…
madrobby authored
372
db2ee67 @madrobby Fix Form.disable to work again on non-form elements. Closes #6887. …
madrobby authored
373 * Fix Form.disable to work again on non-form elements. Closes #6887. [Mislav Marohnić]
374
fc91a3e @madrobby Fix an issue with String.prototype.endsWith. Closes #7822. [altblue]
madrobby authored
375 * Fix an issue with String.prototype.endsWith. Closes #7822. [altblue]
376
63985a2 @sstephenson prototype: 1.5.1_rc2
authored
377 *1.5.1_rc2* (March 12, 2007)
881b7dc @madrobby Prototype: Fix Element.Methods.descendants() to properly extend eleme…
madrobby authored
378
cb1ad0e @sstephenson prototype: Add a tab character via innerHTML to the selector whitespa…
authored
379 * Add a tab character via innerHTML to the selector whitespace test. [Christophe Porteneuve]
380
381 * Add an attribution to YUI-Ext's DomQuery in selector.js.
382
d17521f @madrobby Missed ticket #
madrobby authored
383 * Make Element.extend work on IE for Nodes with the same ID that where discarded. Closes #7497. [Mislav Marohnić, Thomas Fuchs]
e9501d6 @madrobby Make Element.extend work on IE for Nodes with the same ID that where …
madrobby authored
384
b2845e4 @madrobby Prototype: Make Selector correctly extend the first element it return…
madrobby authored
385 * Make Selector correctly extend the first element it returns on IE. [Thomas Fuchs]
386
a6984e6 @madrobby Prevent a crash in Safari when using $A() on NodeList objects that co…
madrobby authored
387 * Prevent a crash in Safari when using $A() on NodeList objects that contain text nodes. [Thomas Fuchs]
388
881b7dc @madrobby Prototype: Fix Element.Methods.descendants() to properly extend eleme…
madrobby authored
389 * Fix Element.Methods.descendants() to properly extend elements on IE. [Thomas Fuchs]
390
811fb86 @sstephenson prototype: 1.5.1_rc1: Fix readAttribute for IE7.
authored
391 *1.5.1_rc1* (March 9, 2007)
392
393 * Fix readAttribute for IE7. [Andrew Dupont]
394
94cfdd3 @sstephenson prototype: 1.5.1_rc0
authored
395 *1.5.1_rc0* (March 8, 2007)
ce639c2 @sstephenson prototype: Update HEADER to reflect new URL.
authored
396
00bce41 @sstephenson prototype: Merge the selector branch into trunk, bringing vast perfor…
authored
397 * Merge the selector branch into trunk, bringing vast performance improvements, bug fixes, and near-complete CSS3 compliance to $$ and Selector. Closes #7568. [Andrew Dupont]
398 Selector speed test: http://andrewdupont.net/test/double-dollar/
399
f160bc4 @sstephenson prototype: Add support for JSON encoding and decoding. Closes #7427.
authored
400 * Add support for JSON encoding and decoding. Closes #7427. [Tobie Langel]
401
f281192 @sstephenson prototype: Fix double escaping of query parameters in Hash.prototype.…
authored
402 * Fix double escaping of query parameters in Hash.prototype.toQueryString, and prevent Safari from iterating over shadowed properties when creating hashes. Closes #7421. [Tobie Langel, Mislav Marohnić]
403
752eebd @madrobby Prototype: Fix simulated attribute reading for IE for "href", "src" a…
madrobby authored
404 * Fix simulated attribute reading for IE for "href", "src" and boolean attributes. [Mislav Marohnić, Thomas Fuchs]
405
a9ec091 @madrobby Prototype: Form.Element.disable() will now call blur(), removed blur(…
madrobby authored
406 * Form.Element.disable() will now call blur(), removed blur() call from Form.Element.enable(). Closes #6034. [tdd]
407
fcc23f0 @madrobby Optimize document.getElementsByClassName and finalize DOM performance…
madrobby authored
408 * Optimize document.getElementsByClassName and finalize DOM performance optimization refactoring. Closes #6696. [Mislav Marohnić]
409
410 * Fix an issue with serializing empty array inputs. Closes #7516. [stakadush, Mislav Marohnić]
ebd3351 @madrobby Fix an issue with serializing empty array inputs, fixes #7516, merges…
madrobby authored
411
412 * Add optional third parameter "camelized" to Element.setStyle, for optimized performance if style names are known to be camelCased. [Thomas Fuchs]
aa7ba0d @madrobby Prototype: Add optional third parameter "camlized" to Element.setStyl…
madrobby authored
413
94d8333 @sstephenson prototype: Fix a bug in the simulated hasAttribute for IE due to getA…
authored
414 * Fix a bug in the simulated hasAttribute for IE due to getAttributeNode sometimes returning null. [sam]
415
60bb068 @madrobby Prototype: Optimize Element.getStyle and add new Element.getOpacity m…
madrobby authored
416 * Optimize Element.getStyle and add new Element.getOpacity method. Special case IE and Opera getStyle methods. Closes #7648. [Tobie Langel, Thomas Fuchs]
417
80f6f40 @madrobby Prototype: Optimize Element.setStyle and add new Element.setOpacity m…
madrobby authored
418 * Optimize Element.setStyle and add new Element.setOpacity method, special case IE and Gecko opacity methods. Closes #7585. [savetheclocktower]
419
d148193 @madrobby Prototype: Add unified Browser detection by providing Prototype.Brows…
madrobby authored
420 * Add unified Browser detection by providing Prototype.Browser.(IE|Gecko|WebKit|Opera) booleans. Closes #6800. [savetheclocktower]
421
5224f0f @madrobby Prototype: Add String.prototype.empty and String.prototype.blank (tes…
madrobby authored
422 * Add String.prototype.empty and String.prototype.blank (tests if empty or whitespace-only). Closes #7016. [Jonathan Viney, Thomas Fuchs]
423
ab59de3 @madrobby Prototype: Update README to reflect new URLs, update LICENSE copyrigh…
madrobby authored
424 * Update README to reflect new URLs, update LICENSE copyright years. Closes #7426. [Tobie Langel]
425
6eca3f0 @sstephenson prototype: Array.prototype.uniq optimization. Closes #7417.
authored
426 * Array.prototype.uniq optimization. Closes #7417. [Christophe Porteneuve]
427
74596ac @sstephenson prototype: String.prototype.endsWith should not fail on multiple occu…
authored
428 * String.prototype.endsWith should not fail on multiple occurrences. Closes #7416. [Christophe Porteneuve]
429
343eae8 @sstephenson prototype: Add Form.Methods.request as a convenience method for seria…
authored
430 * Add Form.Methods.request as a convenience method for serializing and submitting a form via Ajax.Request to the URL in the form's action attribute. [sam]
431
432 Options passed to request() are intelligently merged with the underlying Ajax.Request options:
433 - If the form has a method attribute, its value is used for the Ajax.Request method option. If a method option is passed to request(), it takes precedence over the form's method attribute. If neither is specified, method defaults to "post".
434 - Key/value pairs specified in the parameters option (either as a query string or as a hash) will be merged with (and take precedence over) the serialized form parameters.
435
7044da8 @sstephenson prototype: Fix $(form).serialize() in Safari and add support for exte…
authored
436 * Fix $(form).serialize() in Safari and add support for extending specific tags to Element.addMethods. Closes #7358. [Andrew Dupont]
437
5345085 @sstephenson prototype: Add String.prototype.startsWith, String.prototype.endsWith…
authored
438 * Add String.prototype.startsWith, String.prototype.endsWith, and String.prototype.include. Closes #7075. [Tobie Langel]
439
c556c89 @sstephenson prototype: Improve performance of String.prototype.escapeHTML by usin…
authored
440 * Improve performance of String.prototype.escapeHTML by using a cached div and text node. Closes #6937. [altblue]
441
8ea007d @madrobby Prototype: Make setStyle() with opacity: 0 in Internet Explorer work …
madrobby authored
442 * Make setStyle() with opacity: 0 in Internet Explorer work correctly. [Thomas Fuchs]
443
8490189 @sstephenson prototype: Form.Element.activate shouldn't raise an exception when th…
authored
444 * Form.Element.activate shouldn't raise an exception when the form or field is hidden. [sam]
445
c89875c @sstephenson prototype: Remove support for "throw $continue" in Enumerable. Use "…
authored
446 * Remove support for "throw $continue" in Enumerable. Use "return" instead. [sam]
447
ce639c2 @sstephenson prototype: Update HEADER to reflect new URL.
authored
448 * Update HEADER to reflect new URL. [sam]
449
3c89b25 @sstephenson prototype: Add release date to CHANGELOG
authored
450 *1.5.0* (January 18, 2007)
bb4d189 @sstephenson prototype: Reorganize the source tree.
authored
451
452 * Add test to ensure Content-type header is set for simulated verbs. [sam]
453
454 * Fix Content-Type header for HTTP methods simulated with POST not defaulting to application/x-www-form-urlencoded. [Thomas Fuchs]
455
456 * Simplify form serialization and add support for fields with the same name as Hash methods. Closes #6649. [Mislav Marohnić]
457
458 * Fix attribute selectors for IE. Closes #5170. [Tobie Langel, Andrew Dupont]
459
460 * A slew of dom.js improvements. Closes #4217, #6589, #7001. [Tobie]
461 - Fix Element.getDimensions() for hidden elements, make Element.getHeight() use .getDimensions()
462 - Add Element.getWidth()
463 - Make Element.replace() call .toString() on the html argument (alike .update())
464 - Fix an issue with Element.get/setStyle() and Safari with 'float'
465 - Add a bunch of missing unit tests
466
467 * Fix an issue with Element.setStyle({opacity:''}) setting the opacity to 0 instead of removing the set inline opacity style. [Thomas Fuchs]
468
469 * Ensure Ajax.Request's evalResponse is called before onComplete so that onComplete can reference any elements created during the response. Closes #6727. [jonathan]
470
471 * Ensure the WEBrick test runner sets the correct Content-Type for tests and fixtures. [sam]
472
473 * Form.serialize once again works with non-form elements. This is a temporary change to prevent the Rails link_to_remote regression described in #6898. Prototype 1.5.1 will introduce an API for working with collections of arbitrary form elements. References #6887. Closes #6898. [sam]
474
475 * Make selectors match forms that have an element with name="id" correctly, fixes #5759 [mislav]
476
477 * Remove support for HTTP authorization in Ajax calls introduced with #6366. Closes #6638 [jmecham]
478
479 * Add Enumerable.size() to count elements in an enumerable and the corresponding Array.size() method, fixes #6710 [ZenCocoon]
480
481 * Add String.succ() method to allow for String ranges, fixes #6037 [Cory Hudson, mislav]
482 Examples:
483 'abcd'.succ(); -> 'abce'
484 $R('a','d').map(function(char){ return char; }); -> ['a','b','c','d']
485
486 * Make Element.scrollTo() correctly consider offsets of parent DOM nodes, fixes #6625 [ohader, savetheclocktower]
487
488 * Fix Enumerable.inGroupsOf() to correctly work with fill values that evaluate to false, fixes #6782 [hawk]
489
490 * Remove/cleanup redundant $() calls in dom.js, fixes #6817 [Tobie]
491
492 * Don't cache files in automatic unit tests, fixes #6218 [voidlock]
493
494 * Add $w() to easily create arrays from strings like Ruby's %w, fixes #5682 [glazedginger, brendon.aaron]
495
496 * Add Element.toggleClassName() to toggle CSS classes on elements, fixes #6759 [Tobie]
497
498 * Make Form.getInputs always return an array for consistency, fixes #6475 [Justin Gehtland, savetheclocktower]
499
500 * Make TimedObserver work correctly for SELECT MULTIPLE elements, fixes #6593 [clemos, tdd]
501
502 * Fix Template.prototype.evaluate to correctly interpret 0 and false values, add String.interpret() for safely interpreting and converting values to strings, fixes #6675 [hawk]
503
504 * Make Element.getStyle() work with camelCased argument, fixes #6686 [Tobie]
505
506 * Fix a redundant check in Array.prototype.compact, fixes #4739 [wlodarcz, mislav]
507
508 * Fix $() to correctly pass back the results of document.getElementById(), notably returning "null" on elements not found, fixes #6582 [adsmart]
509
510 * Change/add assertNull, assertUndefined, assertNullOrUndefined and not-* variants in unittest.js, fixes #6582 [adsmart]
511
512 * Cleanup String.prototype.camelize, fix an issue with String.prototype.underscore, fixes #4714, #6685 [Tobie, Thomas Fuchs]
513
514 * Add String.prototype.capitalize, which returns a string with the first character in upper case, fixes #6666 [Tobie]
515
516 * Make Element.getStyle() and Element.setStyle() handle the CSS 'opacity' property transparently in IE, fixes #6093 [brandon.aaron, Tobie]
517
518 * Fix handling of CSS 'float' property for Element.getStyle() and Element.setStyle(), fixes #4160 [Thomas Fuchs, ericf]
519
520 * Fix that onComplete would be called twice with synchronous Ajax requests on Safari (provides units tests for #5756) [Thomas Fuchs]
521
522 * Fix Form.Field.activate to not select text on buttons in IE, fixes #2653 [sutch, mislav, Thomas Fuchs]
523
524 * Fix String.unescapeHTML() on Firefox for strings that are longer than 2048 bytes, fixes #5789 [Paul Moers, Thomas Fuchs]
525
526 * Redefine Array.prototype.concat for Opera, as the native implemenation doesn't work correctly [Thomas Fuchs]
527
528 * Add unit tests for Function.prototype.bind() [Thomas Fuchs]
529
530 * Add String.prototype.underscore and String.prototype.dasherize [Thomas Fuchs]
531 Examples:
532 'Hello_World'.dasherize() -> 'Hello-World'
533 'borderBottomWidth'.underscore() -> 'border_bottom_width'
534 'borderBottomWidth'.underscore().dasherize() -> 'border-bottom-width'
535
536 *1.5.0_rc2* (November 11, 2006)
537
538 * Ensure that existing DOM properties take precedence over extended element methods in all browsers. Closes #5115. [Sean Kleinjung, sam]
539
540 * Add Element.Methods.readAttribute as a simple wrapper around getAttribute (which isn't a "real" function and doesn't have .apply or .call in Safari and IE). Useful in conjunction with Enumerable.invoke for extracting the values of a custom attribute from a collection of elements. [sam]
541 Example:
542 <div id="widgets">
543 <div class="widget" widget_id="7">...</div>
544 <div class="widget" widget_id="8">...</div>
545 <div class="widget" widget_id="9">...</div>
546 </div>
547
548 $$('div.widget').invoke('readAttribute', 'widget_id')
549 // ["7", "8", "9"]
550
551 * Add Element.Methods.immediateDescendants, like $A($(element).childNodes) but without text nodes. [sam]
552
553 * More consistency. Closes #6573. [Bob Silva]
554
555 * String.prototype.toQueryParams and Hash.prototype.toQueryString now properly serialize arrays as multiple values. Closes #4436. [mislav, altblue, L`OcuS]
556
557 * Fix Form.serialize for options with empty values. Closes #5033. [tdd, Thomas Fuchs, sam]
558
559 * Add Element.Methods.Simulated for simulating HTMLElement methods in lesser browsers. Add hasAttribute as the first simulated method. [tdd, Thomas Fuchs, sam]
560
561 * Add a "retry with throw" button for test error messages. [sam]
562
563 * rake test now runs test/unit/*.html by default. Additionally, you can specify individual tests to run with the TESTS environment variable, and you can restrict the tests to particular browsers using the BROWSERS environment variable. [sam]
564
565 Examples:
566 % BROWSERS=safari,firefox rake test
567 % TESTS=dom rake test
568
569 * Element.hasClassName now bypasses the Element.ClassNames API for performance. [sam]
570
571 * Pick some low-hanging performance and DRYness fruit. [sam]
572 - Inline length property accesses in for loops
573 - Enumerable-ize for loops where it makes sense
574 - Make better use of Element.Methods and Form.Methods/Form.Element.Methods
575
576 * A slew of Ajax improvements. Closes #6366. [mislav, sam]
577
578 Public-facing changes include:
579 - HTTP method can be specified in either lowercase or uppercase, and uppercase is always used when opening the XHR connection
580 - Added 'encoding' option (for POST) with a default of 'UTF-8'
581 - Ajax.Request now recognizes all the JavaScript MIME types we're aware of
582 - PUT body support with the 'postBody' option
583 - HTTP authentication support with the 'username' and 'password' options
584 - Query parameters can be passed as a string or as a hash
585 - Fixed both String.toQueryParams and Hash.toQueryString when handling empty values
586 - Request headers can now be specified as a hash with the 'requestHeaders' option
587
588 * Improve performance of the common case where $ is called with a single argument. Closes #6347. [sam, rvermillion, mislav]
589
590 * Fix Object.inspect to correctly distinguish between null and undefined, fixes #5941 [tdd, mislav]
591
592 * Don't serialize disabled form elements, fixes #4586 [tdd]
593
594 * Make HTML element classes extension mechanism for Safari not throw errors on WebKit beta versions [Thomas Fuchs]
595
596 * Add support for using Element.update() with no or a non-string parameter [Thomas Fuchs]
597
598 Example:
599 $('empty_me').update() -> clears the element
600 $('easy_as').update(123) -> set element content to '123'
601
602 * Add unit tests for hashes, fixes #6344 [Tobie Langel]
603
604 * Add clone() method to arrays, fixes #6338 [Tobie Langel]
605
606 * Backing out of [5194] (Element.clear) because of issues with IE on certain elements, #6051
607
608 * Add Element.clear for easily emptying out elements, fixes #6051 [brandon.aaron@gmail.com]
609
610 * Enumerable.each now returns the enumerable to allow for method chaining, fixes #6250 [eventualbuddha]
611
612 * Make makeClipping and undoClipping always return their element to stay chainable
613
614 * Fix an issue with certain Element chain calls not correctly extending elements with Prototype element methods on IE [Thomas Fuchs]
615
616 * Add Enumerable.eachSlice and Enumerable.inGroupsOf, fixes #6046 [rails@tddsworld.com, Thomas Fuchs]
617
618 Example:
619 [1,2,3,4,5].inGroupsOf(3) -> [[1,2,3],[4,5,null]]
620 [1,2,3].inGroupsOf(4,'x') -> [[1,2,3,'x']]
621
622 * Complete unit tests for array.js and string.js [Thomas Fuchs]
623
624 * Performance improvements for document.getElementsByClassName, including querying with XPath in supported browsers. [Andrew Dupont]
625
626 * Make Form.getElements() return elements in the correct order, fix broken Form.serialize return, fixes #4249, #6172 [lars@pinds.com, Thomas Fuchs, john]
627
628 * Add various DOM unit tests, fixes #6176, #6177 [tdd]
629
630 * Split Form.serialize into Form.serialize and Form.serializeElements. The latter can be used stand-alone to serialize an array of elements you pass in, instead of the entire form [DHH]
631
632 * Form.Element.disable() and .enable() will now work correctly, fixes #6034 [dresselm@businesslogic.com]
633
634 * Fix IE and Safari issues with Position.positionedOffset, add position.html unit tests, fixes #5621 [renggli@iam.unibe.ch]
635
636 * Fix an issue with Element.undoClipping and IE [Thomas Fuchs]
637
638 * Element.cleanWhitespace now correctly removes consecutive empty text nodes, fixes #3209 [livier.duroselle@gmail.com]
639
640 * Element.extend now does not try to extend text nodes, fixes #4642 [siegfried.puchbauer@gmail.com]
641
642 *1.5.0_rc1* (September 4, 2006)
643
644 * bindAsEventListener now passes along any provided arguments after the event argument. Closes #5508. [todd.fisher@revolution.com]
645
646 * Fix makeClipping and undoClipping with local overflow style values other than visible and hidden, fixes #3672 [Thomas Fuchs]
647
648 * Add Element.up, Element.down, Element.previous, and Element.next for easily traversing the DOM. (Inspired by Thomas Fuchs' original implementation of Element.up: http://pastie.caboo.se/7702) [sam]
649
650 Examples:
651 <div id="sidebar"> -> $('nav').up() or $('menu').up('div')
652 <ul id="nav"> -> $('sidebar').down() or $('sidebar').down('ul') or $('menu').previous()
653 <li>...</li> -> $('sidebar').down(1) or $('sidebar').down('li')
654 <li>...</li> -> $('sidebar').down(2) or $('sidebar').down('li', 2) or $('sidebar').down('li').next('li')
655 <li class="selected">...</li> -> $('sidebar').down('li.selected')
656 </ul>
657 <ul id="menu"> -> $('sidebar').down('ul').next()
658 ...
659
660 * Refactor $$ and Element.getElementsBySelector into Selector.findChildElements. [sam]
661
662 * Add Element.match, which takes a single CSS selector expression and returns true if it matches the element. [sam]
663
664 * Add Element.ancestors, Element.descendants, Element.previousSiblings, Element.nextSiblings, and Element.siblings. [sam]
665
666 * Add Element.inspect for better DOM debugging. [sam]
667
668 * Add an optional boolean argument to String.prototype.inspect which, when true, makes the string double-quoted instead of single-quoted. [sam]
669
670 * Add the uniq() method to Arrays, which returns a new Array with duplicates removed, fixes #3810 [secondlife]
671
672 * Add stop() method to PeriodicalExecutor, fixes #4801 [Jon Evans]
673
674 * Fix issues with Enumerable.any, ObjectRange.toArray, added unit tests, fixes #4419 [miyamuko, Thomas Fuchs]
675
676 * Fix two instances of unneccesarily redeclared variables, fixes #5229 [Thomas Fuchs]
677
678 * Fix a loop in Element.extend to properly use local variable, fixes #5128 [arrix]
679
680 * Add constants for additional keys in Event, fixes #5411, #5795 [simone_b]
681
682 * Workaround a DOM API bug in Opera in Position.page(), fixes #2407, #5848 [Thomas Fuchs]
683
684 * Remove duplicate definition of Position.clone(), fixes #3765 [Thomas Fuchs]
685
686 * Make destructive Element, Form, and Form.Element methods return their first argument, so that multiple calls can be chained together. [sam]
687
688 ex. $("sidebar").addClassName("selected").show();
689
690 The following methods now return their first argument: Element.toggle, Element.hide, Element.show, Element.remove, Element.update, Element.replace, Element.addClassName, Element.removeClassName, Element.observe, Element.stopObserving, Element.cleanWhitespace, Element.scrollTo, Element.setStyle, Element.makePositioned, Element.undoPositioned, Element.makeClipping, Element.undoClipping, Form.reset, Form.disable, Form.enable, Form.focusFirstElement, Form.Element.focus, Form.Element.select, Form.Element.clear, Form.Element.activate, Form.Element.disable, Form.Element.enable.
691
692 * For consistency, Element.toggle, Element.show, Element.hide, Field.clear, and Field.present no longer take an arbitrary number of arguments. [sam]
693
694 !! BACKWARDS COMPATIBILITY CHANGE !!
695
696 If you have code that looks like this:
697 Element.show('page', 'sidebar', 'content');
698 You need to replace it with code like this:
699 ['page', 'sidebar', 'content'].each(Element.show);
700
701 * Mix in Form and Form.Element methods to forms and form field elements with $() and $$(). Closes #4448. [Dan Webb, sam]
702
703 * Add Object.clone [sam]
704
705 * Add Form.Element.disable and Form.Element.enable. Closes #4943. [jan@prima.de]
706
707 * Field is now simply an alias for Form.Element. [sam]
708
709 * Add Element.Methods.getElementsByClassName and Element.Methods.getElementsBySelector. Closes #4669. [Andrew Dupont, DHH, sam]
710
711 * Avoid race condition when stopping an Ajax.PeriodicalUpdater. Closes #4809. [e98cuenc@gmail.com]
712
713 * Improve support for synchronous requests. Closes #5916. [sam, jthrom@gmail.com]
714
715 * Add serialization and observation support for input type=search. Closes #4096. [rpnielsen@gmail.com]
716
717 * Properly decode query components in String.prototype.toQueryParams. Closes #3487. [sam]
718
719 * Add Array.prototype.reduce [sam]:
720 [1, 2].reduce() // [1, 2]
721 [1].reduce() // 1
722 [].reduce() // undefined
723
724 * Add Object.keys and Object.values [sam]
725
726 * Simulate non-GET/POST requests by POSTing with a _method parameter set to the actual verb [DHH]
727
728 * Make Element.update() handle TABLE-related elements with the DOM API because of IE's missing .innerHTML property on them [Thomas Fuchs, thx to Rick Olson]
729
730 * Sync to script.aculo.us unittest.js library as of 2006/08/29 [Thomas Fuchs]
731
732 * Add additional unit tests to test/unit/dom.html for testing Element.update and $().update in various enviroments [Thomas Fuchs]
733
734 * Prevent possible exceptions on unloading the page in IE [Thomas Fuchs]
735
736 *1.5.0_rc0* (April 5, 2006)
737
738 * Modify HTMLElement.prototype and short-circuit Element.extend where possible. Closes #4477. [Thomas Fuchs]
739
740 * Only observe window.onunload in IE for Mozilla bfcache support. Closes #3726. [Mike A. Owens]
741
742 * Don't redefine Array.prototype.shift. Closes #4138. [leeo]
743
744 * Prevent redefining Array.prototype.reverse more than once. Closes #3951. [brettdgibson@gmail.com]
745
746 * Fix Enumerable.min/Enumerable.max to recognize the value 0. Closes #3847, #4190. [rubyonrails@brainsick.com, Martin Bialasinski]
747
748 * Change Ajax.getTransport to prefer XMLHttpRequest in anticipation of IE 7. Closes #3688. [jschrab@malicstower.org, sam]
749
750 * Make Array.prototype.flatten more robust. Closes #3453. [Martin Bialasinski, sam]
751
752 * Fix evalScripts from crashing Firefox if script includes 'var'. Closes #3288, #4165. [rahul@ntag.com, sam]
753
754 * Scope iterators locally. Closes #4589. [sam]
755
756 * Support Insertion.Before/Insertion.After for <tr> elements in IE. Closes #3925. [rails-venkatp@sneakemail.com]
757
758 * Add a contentType option for overriding application/x-www-form-urlencoded in Ajax.Request. Closes #3564. [avif@arc90.com, sam]
759
760 * Surround values in the X-JSON header in parenthesis for better compatibility with Firefox. Closes #4118. [bigsmoke@gmail.com]
761
762 * Fix Form.serialize to properly encode option values in multiple selects in IE. Closes #3291. [rubyonrails@brainsick.com]
763
764 * Cache methods added to DOM elements with Element.extend to prevent memory leaks in IE. Closes #4465. [jaen@laborint.com, sam]
765
766 * 1.5.0_pre1* (March 26, 2006)
767
768 * Add attribute selector support for Selector (and $$). Closes #4368. [devslashnull@gmail.com]
769 Example:
770 $$('form#foo input[type=text]').each(function(input) {
771 input.setStyle({color: 'red'});
772 });
773
774 * Send Accept header containing 'text/javascript, text/html, application/xml, text/xml */*'' to inform Rails that we prefer RJS, but we'll take HTML or XML or whatever if you can't deliver the goods [DHH]
775
776 * Make $$ work in IE. Closes #3715. [rubyonrails@brainsick.com]
777
778 * Add test/browser.html, which provides a simple object browser for the Prototype source (Firefox/Safari only). [sam]
779
780 * Add Element.extend, which mixes Element methods into a single HTML element. This means you can now write $('foo').show() instead of Element.show('foo'). $, $$ and document.getElementsByClassName automatically call Element.extend on any returned elements. [sam]
781
782 * Add Element.replace as a cross-browser implementation of the "outerHTML" property. References #3246. [tom@craz8.com]
783
784 * Fix Enumerable.zip iterator behavior. [Marcin Kaszynski, sam]
785
786 *1.5.0_pre0* (January 18, 2006)
787
788 * Add String.prototype.truncate to complement the Action View truncate helper. [sam]
789
790 * Add String.prototype.gsub, String.prototype.sub, and String.prototype.scan, all of which take a pattern and an iterator (or a pattern and a replacement template string in the case of gsub and sub). [sam]
791
792 * Add a Template class for interpolating named keys from an object in a string. [sam]
793
794 * Add the $$ function for finding DOM elements by simple CSS selector strings. [sam]
795 Example: Find all <img> elements inside <p> elements with class "summary", all inside
796 the <div> with id "page". Hide each matched <img> tag.
797 $$('div#page p.summary img').each(Element.hide)
798
799 * Add a Selector class for matching elements by single CSS selector tokens. [sam]
800
801 * Add Test.Unit.Assertions.assertEnumEqual for comparing Enumerables in tests. [sam]
802
803 * Add Element.childOf(element, ancestor) which returns true when element is a child of ancestor. [sam]
804
805 * Fix escaping in String.prototype.inspect. [sam]
806
807 * Add String.prototype.strip to remove leading and trailing whitespace from a string. [sam]
808
809 * Move Prototype to Rails SVN. [sam]
810 http://dev.rubyonrails.org/svn/rails/spinoffs/prototype/
811
812 * Make the console nicer. [sam]
813
814 * Prune the source tree. [sam]
Something went wrong with that request. Please try again.