YUILibrary - Open source JavaScript and CSS for building richly interactive software.
Fork YUI on GitHub

YUI 2.x

YUI Release 2.8.0 README Digest

This document is a summary of the 2.8.0 update information that has been added to the respective README files included within each component folder. Please refer the README files for the components you are using for a full change history of each component.

  • Animation
    • Changes
      • Re-enabled multiple animations (when starting from the same value)
  • Autocomplete
    • Enhancements
      • Refactored the "isFocused" model to more simply and accurately describe if the widget instance is active or inactive.
      • Added expandContainer() and clearList() to support 'always show footer when widget is active' feature.
      • Added the property autoSnapContainer for better out-of-the-box support for inline elements, such as labels and submit buttons. By default, autoSnapContainer is true, but implementers can disable this feature if they do not use inline elements and they want to eliminate the overhead of positioning the container element before each time it expands.
      • Added enableIntervalDetection().
  • Base
    • No changes.
  • Button
    • Enhancements
      • Added a new "replaceLabel" attribute to YAHOO.widget.Button. When set to "true" the text of the Button's <label> element is used as the source for the Button's label configuration attribute and removed from the DOM.
    • Bug Fixes
      • For Buttons of type "checkbox" and "radio": clicking on a Button's corresponding <label> element will focus and check or uncheck the Button.
      • For YAHOO.widget.Button and YAHOO.widget.ButtonGroup: Moved the "yui-" prefix used for all class names into a new prototype constant named "CLASS_NAME_PREFIX"
      • Buttons with menus created from existing markup will no longer create two hidden fields for their menu when its parent form is submitted.
      • For IE: Mousing down on a focusable element (such as a form field) when a Button's Menu is visible will now result in the Button blurring properly, and the focusable element gaining focus, becoming the activeElement and firing key-related events.
      • The "selectedMenuItemChange" attribute no longer fires when a Button's Menu is initially made visible.
    • Changes
      • Removed the following prototype properties used to set the value of a Button's title attribute:
        • RADIO_DEFAULT_TITLE
        • RADIO_CHECKED_TITLE
        • CHECKBOX_DEFAULT_TITLE
        • CHECKBOX_CHECKED_TITLE
        • MENUBUTTON_DEFAULT_TITLE
        • MENUBUTTON_MENU_VISIBLE_TITLE
        • SPLITBUTTON_DEFAULT_TITLE
        • SPLITBUTTON_OPTION_VISIBLE_TITLE
        • SUBMIT_TITLE
      • These default title were known to cause problems with screen readers in that the value of the title attribute would be read instead of the Button's text label. This affected the following browser + screen reader combinations:
        • VoiceOver + Safari
        • JAWS + Firefox
        • JAWS + IE
        • Window-Eyes + IE
  • Calendar
    • Bug Fixes
      • The cells property is now populated by searching for tds by class name ("calcell") under the calendar's table element, as opposed to blindly picking up all td elements under the div container. This fixes incorrect selection state related bugs in custom calendars, where the customization introduces additional tables to the default calendar markup.
    • Enhancements
      • DateMath extracted to standalone module. However, it continues to be included in the calendar module, so no change is required to existing pages which use calendar.
      • Made default configuration property values (DEFAULT_CONFIG) public.
      • Made default class names (STYLES) used for CSS classes, public.
      • Changed the few remaining hardcoded CSS class names to use default STYLES configuration.
      • Added "year_offset" configuration property. This can be used for locales which follow the Gregorian calendar, but have the year offset by a fixed amount. For example the Thai (th_TH) calendar, for which the year is a positive 543 year offset from the Gregorian calendar. The offset is applied to any output year strings, such as the year label, or the year CSS marker class and to any input strings, such as date selection strings or the pageDate value string. <br/> NOTE: Any JavaScript Date objects which Calendar accepts as input, should reflect the Gregorian calendar state (that is, the year should be set to the Gregorian year), in order to maintain consistent state for other fields such as weekday, month and date. Similarly, any JavaScript Date objects returned by the Calendar, will be set to the Gregorian year.
      • Added "today" configuration property, allowing the user to configure the date which represents "today" in the Calendar.
      • Added "year_offset" configuration property. This can be used for locales which follow the Gregorian calendar, but have the year offset by a fixed amount. For example the Thai (th_TH) calendar, for which the year is a positive 543 year offset from the Gregorian calendar. The offset is applied to any output year strings, such as the year label, or the year CSS marker class and to any input strings, such as date selection strings or the pageDate value string. <br/> NOTE: Any JavaScript Date objects which Calendar accepts as input, should reflect the Gregorian calendar state (that is, the year should be set to the Gregorian year), in order to maintain consistent state for other fields such as weekday, month and date. Similarly, any JavaScript Date objects returned by the Calendar, will be set to the Gregorian year.
      • Added "today" configuration property, allowing the user to configure the date which represents "today" in the Calendar.
      • Added prevDate and newDate arguments to the changePage event. These are accessible through the arguments array (as with all custom events created using the default LIST signature): for example:


changePageEvent.subscribe(function(type, args) {

var prevDate = args[0];
var newDate = args[1];

if (YAHOO.widget.DateMath.before(newDate, prevDate) {
// Moving back in time
} else {
// Moving forward in time
}

});

  • Carousel
    • Enhancements
      • Added multi-row support.
      • Added pagination template support.
      • Added support for reverse lazy loading of items.
      • Added new methods replaceItem(), replaceItems().
      • Added anchor support for pager/pagination buttons (for SEO).
    • Changes
      • Changed the implementation to use absolute positioning instead of float for the Carousel list items. This change makes the component set raw styles to the Carousel items instead of just styling the element only through CSS.
    • Bug Fixes
      • Fixed bug where carousel was stealing focus from form fields.
  • Charts
    • Enhancements
      • Add ability to show/hide series
      • Add ability to style series by index
      • Add ability to export chart as jpg or png (fp 10+)
      • Add ability for displaying 2 Numeric Axes on the same chart
      • Add ability to allow markers to extend beyond viewport
      • Add font styling to chart title
      • Add ability to set dataTip function on a series level
      • Add ability to set scope for label formatting functions
      • Add ability to filter series from legend
      • Add ability to format legend labels
    • Bug Fixes
      • Enhanced legend so that items wrap when there are too many for one row/column
      • Add ability to specify different shaped line series markers
      • Fixed bug in which setting the size style of xAxis and yAxis to "0" still showed a line
      • Fixed Bug in which TimeAxis labels overlap when max/min dates are set
      • Fixed bug in which stacked bar and column charts widths were incorrectly calculated
      • Fixed bug in which chart font colors only accepted hex values. Now they can accept hex strings as well.
      • Fixed bug in which small numbers were not calculated correctly.
      • Fixed bug in which big numbers were not rounded properly
      • Fixed bug in which stacked bar and column charts do not display properly when both negative and positive values are present
      • Fixed bug in which line chart area fills were not calculated correctly when there are both positive and negative values and a maximum or minimum of have been set
  • ColorPicker
    • No changes.
  • Connection
    • Enhancements
      • Connection Manager can now perform basic cross-domain transactions using a lightweight Flash transport. Transactions using this transport will provide a subset of the response data compared to a standard transaction when using XMLHttpRequest as the transport.
        • XML response data are not supported.
        • Transactions will resolve to success or failure. There is no "complete" event -- global or transaction -- when using the XDR transport.
        • HTTP status is not available.
        • Custom HTTP headers cannot be sent with the request.
        • HTTP headers are not available in the response.
      • Connection Manager is now comprised of two modules:
        • connection_core.js: Basic transaction support, using the XMLHttpRequest transport.
          • This new core file provides basic HTTP transaction support, without the additional features, for a more streamlined file. The full file connection.js will continue to provide all Connection Manager functionality.
        • connection.js: Contains all auxiliary functionality including:
          • serializing HTML form data for POST transactions.
          • file upload transactions.
          • cross-domain transactions using the Flash transport -- connection.swf.
    • Bug Fixes
      • Fixed #2527878 HTTP response headers are trimmed.
      • Fixed #2527983 IE8 file upload's iframe tranport now sets the "enctype" instead of "encoding" attribute.
  • Container
    • Enhancements
      • Added support for an "xyoffset" parameter to Tooltip, to configure the offset from the mouse XY position at which the Tooltip should be displayed.
      • Added support for an xy offset parameter to the context argument array. This allows the user to offset the Overlay by an XY pixel value in cases where they don't want precise alignment, e.g.:


context:["contextEl", "tl", "tr", ["beforeShow"]]

      • Would align the overlays top left corner with the top right corner of the context element exactly. Using the offset parameter, the Overlay can be offset by a pixel amount if desired, e.g.:


context:["contextEl", "tl", "tr", ["beforeShow"], [5, 0]]

      • Would align the overlay's top left corner with the top right corner of the context element, but offset it along the X axis by 5 pixels, providing a gap between the overlay and context element edges.
    • Changes
      • Users can now prevent Dialog form submission by returning false from a beforeSubmit event subscriber
    • Bug Fixes
      • setHeader, setBody, setFooter will create the respective section element and add it to the DOM if called after render has already been invoked.
      • preventoverlap repositioning logic is now applied for cases where the constrained Overlay is larger than the viewport also, and takes precedence over the default behavior for constrained Overlays which are larger than the viewport.
      • Overlay unsubscribes all context trigger listeners on destroy. Trigger listeners bound to global custom events such as windowScroll and windowResize cause JS execptions if left attached after the Overlay was destroy.
  • Cookie
    • Enhancements
      • Added Cookie.exists() to allow for easier Boolean cookie detection.
      • Added option to disable url encoding/decoding by passing options.raw to set() and get() (YUILibrary bug #2527953).
    • Changes
      • Changed behavior for Boolean cookies (those that don't contain an equals sign). Previously, calling Cookie.get() on a Boolean cookie would return the name of the cookie. Now, it returns an empty string. This is necessary because IE doesn't store an equals sign when the cookie value is empty ("info=" becomes just "info").
      • Removing the last subcookie with removeSub() now removes the cookie if the removeIfEmpty option is set to true (YUILibrary bug #2527954)
      • Changed get() to take an options object with raw and converter properties, if a function is passed instead of an object then it is used as the converter for backward compatibility (YUILibrary bug #2527953).
      • Removed check for cookie value before parsing. Previously, parsing checked for name=value, now it parses anything that is passed in.
      • Changed formatting of date from toGMTString() to toUTCString() (YUILibrary bug #2527892).
    • Bug Fixes
      • Updated remove() so that it no longer modifies the options object that is passed in (YUILibrary bug #2527838).
  • DataSource
    • Enhancements
      • Negative formatting support in YAHOO.util.Number.format().
      • Added useXPath property for XPath support when parsing XML data.
  • DataTable
    • Enhancements
      • DropdownCellEditor now supports multiple and size properties.
      • Calling DataTable's destroy() method now calls Paginator destroy(), when applicable.
      • Added beforeRenderEvent.
      • Added clearScrollPositions() and scrollTo() to ScrollingDataTable.
      • Performance improvements for ScrollingDataTable in IE.
    • Bug Fixes
      • Bug fixes for DataTables rendered within table markup.
  • DateMath
    • New component
      • Extracted DateMath into a standalone module. In prior versions it was included with "calendar"
  • Dom
    • Bug Fixes
      • Fix get() with FORM that has an input named ID (IE bug)
      • Fix setAttribute for IE8 "type" attribute
  • Drag & Drop
    • No changes
  • Editor
    • Bug Fixes
      • #2527611 - Original size in insert image window not working as expected
      • #2527612 - Image size resets
      • #2527737 - _getDoc in simpleeditor could be simpler
      • #2527738 - Cleanup cmd_insertimage in simpleeditor
      • #2527795 - RTE and Safari 4 Beta Defect
      • #2527837 - Editor Window Footer open class
      • #2527861 - Editor menu collapse doesnt change image
      • #2527882 - allowDesignMode option for Editor
      • #2527888 - FFox and Chrome replicate IDs when editing <li> items
      • #2527893 - CSS typo in editor-core.css
      • #2527934 - Editor can't be extended to have a custom toolbar in init function
      • #2527951 - Ampersands are not always escaped properly in the RichTextEditor (RTE)
      • #2527952 - Controlling the saveHTML process for multiple instances of HTML Editor without a real reference to the editor, to ensure the process of collecting data from a form before tunneling the request thru YUI Connection Manager.
      • #2527977 - RTE: The cleanHTML method removes <span> tags at beginning and end of HTML when it shouldn't
      • #2527988 - multiple images inserted
      • #2528024 - Editor mangles and incorrectly removes <div> tags in WebKit
      • #2528086 - editor not working in ie8
      • #2528103 - data with large images / large quantity of images not editable
      • #2528106 - Disabling RTE doesn't work properly in IE6
      • #2528193 - undo functionality broken
      • #2528194 - Custom Image Browser Example has old code
      • #2528195 - Toggling Editor "disabled" attribute causes extra line breaks to be inserted
  • Element
    • Enhancements
      • Returning value from DEFAULT_SETTER
      • Added support for mouseenter and mouseleave events (requires the event-mouseenter module)
      • Added a "delegate" method that facilitates easy creation of delegated event listeners.

(requires the element-delegate module)

  • Event
    • Enhancements
      • Added fireOnce support for custom events.
      • Added onreadystatechange fork for IE onDOMReady when YUI is running in an iframe.
      • Removed DOM0 fallback that was there to support preventDefault in browsers that are not supported and nearly extinct.
      • Added support for mouseenter and mouseleave events (requires the inclusion of the event-mouseenter module)
      • Added support for event delegation via the "delegate" and "removeDelegate" methods (requires inclusion of the event-delegate module)
      • Deprecated onFocus, onBlur, addFocusListener, addBlurListener, removeFocusListener, and removeBlurListener. Going forward capture phase focus and blur events can be listened for directly the addListener/on methods and removed via the removeListener method
  • Event-Simulate
    • New component
      • Extracted into a standalone module from yuitest
  • Fonts
    • No changes.
  • Get
    • Enhancements
      • Added 'attributes' config, which is a hash of attributes to apply to dynamic nodes. deprecated charset
  • Grids
    • No changes.
  • History
    • No changes.
  • ImageCropper
    • No changes
  • ImageLoader
    • Enhancements
      • @requires for module, no functional changes
  • JSON
    • Enhancements
      • Refactored to be ECMA 5 spec compliant. This resulted in the following:
        • Leverages browser native JSON parse and stringify if present
        • Added JSON.useNativeParse and JSON.useNativeStringify boolean configs to allow implementers to force the use of the JavaScript implementation. These are defaulted to true when the current browser supports native JSON. It is currently recommended to set useNativeStringify to false if you need to use a replacer function.
        • Removed object key sorting (per spec)
        • Stringifying cyclical objects will now throw an error (per spec)
        • Removed support for depth control (per spec)
      • Tightened up JSON.stringToDate
      • Renamed final regex _INVALID => _UNSAFE because the destructive regex process is to detect unsafe input. It does not validate against JSON syntax.
      • Refactored stringify to match the implementation in YUI 3.
  • Layout
    • Bug Fixes
      • #2528175 - Resize event of a layout is fired twice when using the resize handles
      • #2527868 - top panel's header always displayed in a layout in IE7
      • #2527803 - Example: Simple Application broken on IE7
      • #2527706 - Can't set maxHeight/maxWidth after creation
  • Logger
    • Enhancements
      • Added destroy method.
      • Moved initialization code from the constructor to _init.
      • Moved UI construction to new render method (Still renders automatically unless configured with autoRender = false).
      • General clean up and code reduction.
    • Bug Fixes
      • Fixed yui-log-container class not being applied when constructed with a render target.
  • Menu
    • Enhancements
      • added to new methods to YAHOO.widget.MenuItem:
        • getNextSibling
        • getPreviousSibling
    • Bug Fixes
      • For IE: Mousing down on a focusable element (such as a form field) when a Menu is visible will now result in the focusable element gaining focus, becoming the activeElement and firing key-related events.
      • The keepopen configuration property now correctly cascades to all of a Menu's submenus
      • Unsubscribing from an Event listener will now correctly unsubscribe listeners from all submenus.
      • Right clicking on a Menu in Firefox will no longer result in the firing of the Menu's click event.
  • Paginator
    • Enhancements
      • Replaced non-breaking space entity with regular space in next, previous, first, and last links to support xhtml
      • updateOnChange configuration is deprecated in favor of a changeRequest subscriber that immediately calls setState(newState)
      • setState now only updates known attributes
      • render broken into render, _renderTemplate, and renderUIComponent
      • Now always builds DOM structure, but doesn't remove display:none if alwaysVisible is set to false and conditions for visibility are not met
      • render() is now chainable
      • Now hides the container when rowsPerPage <= totalRecords. It used to be only < not <=
      • destroy() now calls unsubscribeAll() to flush event listeners
  • Profiler
    • Enhancements
      • Changed profiler so that unregistering a function/object no longer deletes all recorded data.
      • Added clear() method to remove profiler data.
      • Added instrument() method to profile anonymous functions.
      • Added getReport() method and deprecated getFunctionReport().
      • Added getOriginal() method to retrieve uninstrumented versions of functions.
      • Implemented stopwatch functionality.
  • ProfilerViewer
    • No changes.
  • ProgressBar
    • Initial Release
  • Reset
    • No changes.
  • Resize
    • No changes
  • Selector
    • Bug Fixes
      • Fixed nth-of-type selector
  • Slider
    • Bug Fixes
      • baselinePos is reset on each mousedown to avoid a horrible positioning bug in IE that sends the thumb off screen
      • More work to get slideEnd event firing correctly and consistently. This time removed deprecated moveComplete from state change conditionals
  • Storage
    • Initial Release
  • StyleSheet
    • Enhancements
      • Added support for set(selector, cssTextString)
  • SWF
    • Initial Release
  • SWFDetect
    • Initial Release
  • SWFStore
    • Initial Release
  • TabView
    • Bug Fixes
      • Removing event listeners when a Tab is removed
      • Fixed CSS overflow issue
  • TreeView
    • Bug Fixes
      • Fixed #2527720: TextNode with href didn't navigate to location
      • Fixed #2527920: When moving with right arrow to a dynamic node not already loaded, focus would pass to immediate sibling instead of first child of loaded children
      • Fixed #2455223: Opacity of nodes was not always restored once faded out
      • Fixed #2528017: On nodes loaded dynamically, highlight didn't propagate down.
      • Icon pre-loading function was dropped
      • Fixed #2528296: method highlight didn't pass on the _silent flag when calling unhighlight, making it fire events.
  • Uploader
    • Enhancements
      • Added uploadThese() method (contribution by Jordan Brough) to upload a specific subset of selected files.
    • Bug Fixes
      • The queue for uploadAll() has been reimplemented (contribution by Jordan Brough) to work as a proper queue.
  • Yahoo
    • Enhancements
      • User agent detection is more granular. e.g., FireFox 3.5 reports gecko 1.91 rather than 1.9.
      • Added 'os' and 'secure' properties to Env.
  • YUI Loader
    • Enhancements
      • added datemath module, updated calendar metadata accordingly.
      • added event-simulate module, which was extracted from yuitest.
      • connection split into connectioncore and connection rollup.
    • Bug Fixes
      • Fixed uploader -min file resolution.
      • progressbar, swf, swfdetect, swfstore metadata.

YUI Test

  • Changes
    • UserAction moved into a new module: event-simulate.
      • Custom Error objects inherit from Object instead of Error.
    • Bug Fixes
      • Fixed issues with ArrayAssert methods (trac #2528121)