We released YUI version 2.4.0 today; it’s available for download and full documentation is up on the YUI website. Here are the all-new components being issued with 2.4.0:
- Selector Utility: Matt Sweeney introduces the Selector Utility Beta in 2.4.0, our first pass at a CSS query engine. Of course, this genre owes a huge debt to Simon Willison, Sam Stephenson, John Resig and many others; most major libraries have now added selector functionality, and there’s an emerging body of work that helps implementers sort out the relative performance profiles of the various tools. The YUI Selector Utility implements much of the CSS Selector syntax as defined by the W3C, including the proposed CSS3 Selector extensions. Matt has provided support for most pseudo-classes, attribute operators, and combinators included in these working drafts. While performance is always a priority for query engines, in this initial beta our primary focus has been on passing test cases to meet the requirements of the CSS3 spec. We think we have the right selector framework to support YUI’s needs going forward, and we’re looking forward to your feedback as this goes out for a beta round.
- Profiler: Nicholas C. Zakas is back in 2.4.0 with a brand-new component, the YUI Profiler. Profiler allows you to target specific code for profiling and to retrieve profiling data programmatically while your application is running — in any A-Grade browser. In combination with Nicholas’s YUI Test Utility, Profiler allows you to build unit tests in which success or failure is predicated on performance benchmarks. Profiler is issued without a visualization layer in 2.4.0, but check out the examples to get a feel for the data that gets rolled up by this tool and how to make use of it.
- JSON Utility: YUI’s newest team member, Luke Smith, contributes an adaptation of Douglas Crockford’s public-domain JSON parse and stringify functionality. You’ll see the JSON Utility at work in the new Charts Control and working in tandem with the Get Utility to support proxyless web-services in AutoComplete.
Beyond these all-new pieces, you’ll find some other goodies throughout the library. Here are some notable ones:
- Button: Todd Kloots celebrates the GA promotion of the YUI Button Control with a set of new examples, including a calendar-menu button, color-picker button, throbber/glowing button, and slider-button.
- Calendar: Satyen Desai has added built-in year navigation to the YUI Calendar Control.
- Drag & Drop: Dav Glass enriches the Drag & Drop Utility API for 2.4.0 with a new
dragOnly configuration option. If your implementation requires simple drag-to-reposition functionality, this configuration option suppresses the complex targeting and interaction logic that is the most computationally intensive aspect of drag and drop; in those cases, you’ll see significant performance boosts. Note that Satyen has brought support for this option into the Container Family, where you can use it to improve the drag-and-drop performance of Panels and other draggable Containers.
- Rich Text Editor: Dav continues to push the YUI Rich Text Editor in both size and performance. With 2.4.0, you can better control the dependency list, allowing you to shave more than 50% off the overall k-weight of the widget (vs. its 2.3.1 profile) if you don’t need some of the glossier UI elements.
For a full rollup of the changes, see George Puckett’s change manifest posted to the forum. We’ll have more to say about some of the new components here on YUIBlog in the coming weeks. In the meantime, please download the new release and drop by the YUI community forum to let us know what you think.
(on behalf of the YUI team: Adam Moore, Dav Glass, George Puckett, Jenny Han Donnelly, Luke Smith, Matt Sweeney, Nate Koechley, Satyen Desai, Thomas Sha and Todd Kloots; and contributors: Josh Tynjala, Matt Mlinac, and Nicholas C. Zakas).