diff --git a/.gitignore b/.gitignore index e28257efcb6..fd03e7bc0bb 100644 --- a/.gitignore +++ b/.gitignore @@ -1,8 +1,11 @@ build_tmp*/ build_rollup_tmp*/ +docs/ +node_modules/ tmp/ CVS/ .DS_Store .*.swp .svn *~ +src/build.log diff --git a/build/anim/anim-debug.js b/build/anim/anim-debug.js index d3168ed972f..fb3cc78565f 100644 --- a/build/anim/anim-debug.js +++ b/build/anim/anim-debug.js @@ -1204,5 +1204,5 @@ Y.Anim.behaviors.xy = { }, '@VERSION@' ,{requires:['anim-base', 'node-screen']}); -YUI.add('anim', function(Y){}, '@VERSION@' ,{use:['anim-base', 'anim-color', 'anim-curve', 'anim-easing', 'anim-node-plugin', 'anim-scroll', 'anim-xy'], skinnable:false}); +YUI.add('anim', function(Y){}, '@VERSION@' ,{skinnable:false, use:['anim-base', 'anim-color', 'anim-curve', 'anim-easing', 'anim-node-plugin', 'anim-scroll', 'anim-xy']}); diff --git a/build/anim/anim-min.js b/build/anim/anim-min.js index 5e5cbc7bd57..dbc28bb64a4 100644 --- a/build/anim/anim-min.js +++ b/build/anim/anim-min.js @@ -1,2 +1,2 @@ YUI.add("anim-base",function(b){var c="running",n="startTime",l="elapsedTime",j="start",i="tween",m="end",d="node",k="paused",o="reverse",h="iterationCount",a=Number;var f={},e;b.Anim=function(){b.Anim.superclass.constructor.apply(this,arguments);b.Anim._instances[b.stamp(this)]=this;};b.Anim.NAME="anim";b.Anim._instances={};b.Anim.RE_DEFAULT_UNIT=/^width|height|top|right|bottom|left|margin.*|padding.*|border.*$/i;b.Anim.DEFAULT_UNIT="px";b.Anim.DEFAULT_EASING=function(q,p,s,r){return s*q/r+p;};b.Anim._intervalTime=20;b.Anim.behaviors={left:{get:function(q,p){return q._getOffset(p);}}};b.Anim.behaviors.top=b.Anim.behaviors.left;b.Anim.DEFAULT_SETTER=function(s,t,v,w,y,r,u,x){var q=s._node,p=u(y,a(v),a(w)-a(v),r);if(t in q._node.style||t in b.DOM.CUSTOM_STYLES){x=x||"";q.setStyle(t,p+x);}else{if(q._node.attributes[t]){q.setAttribute(t,p);}else{q.set(t,p);}}};b.Anim.DEFAULT_GETTER=function(r,p){var q=r._node,s="";if(p in q._node.style||p in b.DOM.CUSTOM_STYLES){s=q.getComputedStyle(p);}else{if(q._node.attributes[p]){s=q.getAttribute(p);}else{s=q.get(p);}}return s;};b.Anim.ATTRS={node:{setter:function(p){p=b.one(p);this._node=p;if(!p){}return p;}},duration:{value:1},easing:{value:b.Anim.DEFAULT_EASING,setter:function(p){if(typeof p==="string"&&b.Easing){return b.Easing[p];}}},from:{},to:{},startTime:{value:0,readOnly:true},elapsedTime:{value:0,readOnly:true},running:{getter:function(){return !!f[b.stamp(this)];},value:false,readOnly:true},iterations:{value:1},iterationCount:{value:0,readOnly:true},direction:{value:"normal"},paused:{readOnly:true,value:false},reverse:{value:false}};b.Anim.run=function(){var q=b.Anim._instances;for(var p in q){if(q[p].run){q[p].run();}}};b.Anim.pause=function(){for(var p in f){if(f[p].pause){f[p].pause();}}b.Anim._stopTimer();};b.Anim.stop=function(){for(var p in f){if(f[p].stop){f[p].stop();}}b.Anim._stopTimer();};b.Anim._startTimer=function(){if(!e){e=setInterval(b.Anim._runFrame,b.Anim._intervalTime);}};b.Anim._stopTimer=function(){clearInterval(e);e=0;};b.Anim._runFrame=function(){var p=true;for(var q in f){if(f[q]._runFrame){p=false;f[q]._runFrame();}}if(p){b.Anim._stopTimer();}};b.Anim.RE_UNITS=/^(-?\d*\.?\d*){1}(em|ex|px|in|cm|mm|pt|pc|%)*$/;var g={run:function(){if(this.get(k)){this._resume();}else{if(!this.get(c)){this._start();}}return this;},pause:function(){if(this.get(c)){this._pause();}return this;},stop:function(p){if(this.get(c)||this.get(k)){this._end(p);}return this;},_added:false,_start:function(){this._set(n,new Date()-this.get(l));this._actualFrames=0;if(!this.get(k)){this._initAnimAttr();}f[b.stamp(this)]=this;b.Anim._startTimer();this.fire(j);},_pause:function(){this._set(n,null);this._set(k,true);delete f[b.stamp(this)];this.fire("pause");},_resume:function(){this._set(k,false);f[b.stamp(this)]=this;this._set(n,new Date()-this.get(l));b.Anim._startTimer();this.fire("resume");},_end:function(p){var q=this.get("duration")*1000;if(p){this._runAttrs(q,q,this.get(o));}this._set(n,null);this._set(l,0);this._set(k,false);delete f[b.stamp(this)];this.fire(m,{elapsed:this.get(l)});},_runFrame:function(){var u=this._runtimeAttr.duration,r=new Date()-this.get(n),q=this.get(o),p=(r>=u),s,v;this._runAttrs(r,u,q);this._actualFrames+=1;this._set(l,r);this.fire(i);if(p){this._lastFrame();}},_runAttrs:function(A,z,w){var x=this._runtimeAttr,r=b.Anim.behaviors,y=x.easing,p=z,u=false,q,s,v;if(A>=z){u=true;}if(w){A=z-A;p=0;}for(v in x){if(x[v].to){q=x[v];s=(v in r&&"set" in r[v])?r[v].set:b.Anim.DEFAULT_SETTER;if(!u){s(this,v,q.from,q.to,A,z,y,q.unit);}else{s(this,v,q.from,q.to,p,z,y,q.unit);}}}},_lastFrame:function(){var p=this.get("iterations"),q=this.get(h);q+=1;if(p==="infinite"||q
= 3),
- location = Y.config.win.location;
+ win = Y.config.win,
+ location = win.location,
+
+ /**
+ Fired when the controller is ready to begin dispatching to route handlers.
+
+ You shouldn't need to wait for this event unless you plan to implement some
+ kind of custom dispatching logic. It's used internally in order to avoid
+ dispatching to an initial route if a browser history change occurs first.
+
+ @event ready
+ @param {Boolean} dispatched `true` if routes have already been dispatched
+ (most likely due to a history change).
+ @fireOnce
+ **/
+ EVT_READY = 'ready';
function Controller() {
Controller.superclass.constructor.apply(this, arguments);
@@ -40,23 +57,45 @@ Y.Controller = Y.extend(Controller, Y.Base, {
// -- Public Properties ----------------------------------------------------
/**
- Base path or URL from which all routes should be evaluated.
+ If `true`, the controller will dispatch to the first route handler that
+ matches the current URL immediately after the controller is initialized,
+ even if there was no browser history change to trigger a dispatch.
+
+ If you're rendering the initial pageview on the server, then you'll probably
+ want this to be `false`, but if you're doing all your rendering and route
+ handling entirely on the client, then setting this to `true` will allow your
+ client-side routes to handle the initial request of all pageviews without
+ depending on any server-side handling.
+
+ This property defaults to `false` for HTML5 browsers, `true` for browsers
+ that rely on hash-based history (since the hash is never sent to the
+ server).
+
+ @property dispatchOnInit
+ @type Boolean
+ @default `false` for HTML5 browsers, `true` for hash-based browsers
+ **/
+ dispatchOnInit: !html5,
+
+ /**
+ Root path from which all routes should be evaluated.
For example, if your controller is running on a page at
`http://example.com/myapp/` and you add a route with the path `/`, your
route will never execute, because the path will always be preceded by
- `/myapp`. Setting _base_ to `/myapp` would cause all routes to be evaluated
- relative to that base path, so the `/` route would then execute.
+ `/myapp`. Setting `root` to `/myapp` would cause all routes to be evaluated
+ relative to that root URL, so the `/` route would then execute when the
+ user browses to `http://example.com/myapp/`.
This property may be overridden in a subclass, set after instantiation, or
passed as a config attribute when instantiating a `Y.Controller`-based
class.
- @property base
+ @property root
@type String
@default `''`
**/
- base : '',
+ root: '',
/**
Array of route objects specifying routes to be created at instantiation
@@ -85,6 +124,34 @@ Y.Controller = Y.extend(Controller, Y.Base, {
// -- Protected Properties -------------------------------------------------
+ /**
+ Whether or not `_dispatch()` has been called since this controller was
+ instantiated.
+
+ @property _dispatched
+ @type Boolean
+ @default undefined
+ @protected
+ **/
+
+ /**
+ Whether or not this browser is capable of using HTML5 history.
+
+ @property _html5
+ @type Boolean
+ @protected
+ **/
+ _html5: html5,
+
+ /**
+ Whether or not the `ready` event has fired yet.
+
+ @property _ready
+ @type Boolean
+ @default undefined
+ @protected
+ **/
+
/**
Regex used to match parameter placeholders in route paths.
@@ -109,31 +176,58 @@ Y.Controller = Y.extend(Controller, Y.Base, {
@type RegExp
@protected
**/
- _regexUrlQuery : /\?([^#]*).*$/,
+ _regexUrlQuery: /\?([^#]*).*$/,
// -- Lifecycle Methods ----------------------------------------------------
initializer: function (config) {
+ var self = this;
+
+ // Set config properties.
config || (config = {});
- this._routes = [];
+ config.routes && (self.routes = config.routes);
+
+ Lang.isValue(config.root) && (self.root = config.root);
+ Lang.isValue(config.dispatchOnInit) &&
+ (self.dispatchOnInit = config.dispatchOnInit);
+
+ // Create routes.
+ self._routes = [];
- config.base && (this.base = config.base);
- config.routes && (this.routes = config.routes);
+ YArray.each(self.routes, function (route) {
+ self.route(route.path, route.callback, true);
+ });
- YArray.each(this.routes, function (route) {
- this.route(route.path, route.callback, true);
- }, this);
+ // Set up a history instance or hashchange listener.
+ if (html5) {
+ self._history = new Y.HistoryHTML5({force: true});
+ self._history.after('change', self._afterHistoryChange, self);
+ } else {
+ Y.on('hashchange', self._afterHistoryChange, win, self);
+ }
- // Set up a history instance.
- this._history = html5 ? new Y.HistoryHTML5() : new Y.HistoryHash();
- this._history.after('change', this._afterHistoryChange, this);
+ // Fire a 'ready' event once we're ready to route. We wait first for all
+ // subclass initializers to finish, and then an additional 20ms to allow
+ // the browser to fire an initial `popstate` event if it wants to.
+ self.publish(EVT_READY, {
+ defaultFn : self._defReadyFn,
+ fireOnce : true,
+ preventable: false
+ });
- // Handle the initial route.
- this._dispatch(this._getPath(), this._getState());
+ self.once('initializedChange', function () {
+ setTimeout(function () {
+ self.fire(EVT_READY, {dispatched: !!self._dispatched});
+ }, 20);
+ });
},
destructor: function () {
- this._history.detachAll();
+ if (html5) {
+ this._history.detachAll();
+ } else {
+ Y.detach('hashchange', this._afterHistoryChange, win);
+ }
},
// -- Public Methods -------------------------------------------------------
@@ -177,7 +271,7 @@ Y.Controller = Y.extend(Controller, Y.Base, {
Behind the scenes, this method uses HTML5 `pushState()` in browsers that
support it (or the location hash in older browsers and IE) to change the
- URL and create a history entry for the given state.
+ URL.
The specified URL must share the same origin (i.e., protocol, host, and
port) as the current page, or an error will occur.
@@ -185,25 +279,24 @@ Y.Controller = Y.extend(Controller, Y.Base, {
@example
// Starting URL: http://example.com/
- controller.replace('/bar/', 'You are now at /bar/', {bar: true});
- // New URL: http://example.com/bar/
+ controller.replace('/path/');
+ // New URL: http://example.com/path/
- controller.replace('/', 'You are now at example.com');
+ controller.replace('/path?foo=bar');
+ // New URL: http://example.com/path?foo=bar
+
+ controller.replace('/');
// New URL: http://example.com/
@method replace
- @param {String} [url] URL to set. May be relative or absolute, but if a
- `base` property is specified, this URL must be relative to that property.
- If not specified, the page's current URL will be used.
- @param {String} [title] Page title to set. If not specified, the page's
- current title will be used.
- @param {Object} [state] State object to associate with this history entry.
- May be any object that can be serialized to JSON.
+ @param {String} [url] URL to set. Should be a relative URL. If this
+ controller's `root` property is set, this URL must be relative to the
+ root URL. If no URL is specified, the page's current URL will be used.
@chainable
@see save()
**/
- replace: function (url, title, state) {
- return this._save(url, title, state, true);
+ replace: function (url) {
+ return this._save(url, true);
},
/**
@@ -258,8 +351,6 @@ Y.Controller = Y.extend(Controller, Y.Base, {
@param {Object} callback.req.query Query hash representing the URL query
string, if any. Parameter names are keys, and are mapped to parameter
values.
- @param {Object} callback.req.state State object associated with this
- URL, if any.
@param {Function} callback.next Callback to pass control to the next
matching route. If you don't call this function, then no further route
handlers will be executed, even if there are more that match. If you do
@@ -288,7 +379,7 @@ Y.Controller = Y.extend(Controller, Y.Base, {
Behind the scenes, this method uses HTML5 `pushState()` in browsers that
support it (or the location hash in older browsers and IE) to change the
- URL and create a history entry for the given state.
+ URL and create a history entry.
The specified URL must share the same origin (i.e., protocol, host, and
port) as the current page, or an error will occur.
@@ -296,25 +387,24 @@ Y.Controller = Y.extend(Controller, Y.Base, {
@example
// Starting URL: http://example.com/
- controller.save('/bar/', 'You are now at /bar/', {bar: true});
- // New URL: http://example.com/bar/
+ controller.save('/path/');
+ // New URL: http://example.com/path/
+
+ controller.save('/path?foo=bar');
+ // New URL: http://example.com/path?foo=bar
- controller.save('/', 'You are now at example.com');
+ controller.save('/');
// New URL: http://example.com/
@method save
- @param {String} [url] URL to set. May be relative or absolute, but if a
- `base` property is specified, this URL must be relative to that property.
- If not specified, the page's current URL will be used.
- @param {String} [title] Page title to set. If not specified, the page's
- current title will be used.
- @param {Object} [state] State object to associate with this history entry.
- May be any object that can be serialized to JSON.
+ @param {String} [url] URL to set. Should be a relative URL. If this
+ controller's `root` property is set, this URL must be relative to the
+ root URL. If no URL is specified, the page's current URL will be used.
@chainable
@see replace()
**/
- save: function (url, title, state) {
- return this._save(url, title, state);
+ save: function (url) {
+ return this._save(url);
},
// -- Protected Methods ----------------------------------------------------
@@ -335,24 +425,29 @@ Y.Controller = Y.extend(Controller, Y.Base, {
/**
Dispatches to the first route handler that matches the specified _path_.
+ If called before the `ready` event has fired, the dispatch will be aborted.
+ This ensures normalized behavior between Chrome (which fires a `popstate`
+ event on every pageview) and other browsers (which do not).
+
@method _dispatch
@param {String} path URL path.
- @param {Object} state State to pass to route handlers.
@protected
**/
- _dispatch: function (path, state) {
- var routes = this.match(path),
- req, route, self;
+ _dispatch: function (path) {
+ var self = this,
+ routes = self.match(path),
+ req;
+
+ self._dispatched = true;
if (!routes || !routes.length) {
return;
}
- req = this._getRequest(path, state);
- self = this;
+ req = self._getRequest(path);
function next(err) {
- var callback, matches;
+ var callback, matches, route;
if (err) {
Y.error(err);
@@ -380,6 +475,18 @@ Y.Controller = Y.extend(Controller, Y.Base, {
next();
},
+ /**
+ Gets the current path from the location hash, or an empty string if the
+ hash is empty.
+
+ @method _getHashPath
+ @return {String} Current hash path, or an empty string if the hash is empty.
+ @protected
+ **/
+ _getHashPath: function () {
+ return HistoryHash.getHash().replace(this._regexUrlQuery, '');
+ },
+
/**
Gets the current route path.
@@ -388,16 +495,9 @@ Y.Controller = Y.extend(Controller, Y.Base, {
@protected
**/
_getPath: html5 ? function () {
- var base = this.base,
- path = location.pathname;
-
- if (base && path.indexOf(base) === 0) {
- path = path.substring(base.length);
- }
-
- return path;
+ return this._removeRoot(location.pathname);
} : function () {
- return this._history.get('path') || this.base + location.pathname;
+ return this._getHashPath() || this._removeRoot(location.pathname);
},
/**
@@ -410,12 +510,15 @@ Y.Controller = Y.extend(Controller, Y.Base, {
_getQuery: html5 ? function () {
return location.search.substring(1);
} : function () {
- return this._history.get('query') || location.search.substring(1);
+ var hash = HistoryHash.getHash(),
+ matches = hash.match(this._regexUrlQuery);
+
+ return hash && matches ? matches[1] : location.search.substring(1);
},
/**
- Creates a regular expression from the specified route specification. If
- _path_ is already a regex, it will be returned unmodified.
+ Creates a regular expression from the given route specification. If _path_
+ is already a regex, it will be returned unmodified.
@method _getRegex
@param {String|RegExp} path Route path specification.
@@ -442,30 +545,44 @@ Y.Controller = Y.extend(Controller, Y.Base, {
@method _getRequest
@param {String} path Current path being dispatched.
- @param {Object} state Current state.
@return {Object} Request object.
@protected
**/
- _getRequest: function (path, state) {
+ _getRequest: function (path) {
return {
path : path,
- query: this._parseQuery(this._getQuery()),
- state: state
+ query: this._parseQuery(this._getQuery())
};
},
/**
- Gets the current state, if any.
+ Joins the `root` URL to the specified _url_, normalizing leading/trailing
+ `/` characters.
+
+ @example
+ controller.root = '/foo'
+ controller._joinURL('bar'); // => '/foo/bar'
+ controller._joinURL('/bar'); // => '/foo/bar'
+
+ controller.root = '/foo/'
+ controller._joinURL('bar'); // => '/foo/bar'
+ controller._joinURL('/bar'); // => '/foo/bar'
- @method _getState
- @return {Object} Current state.
+ @method _joinURL
+ @param {String} url URL to append to the `root` URL.
+ @return {String} Joined URL.
@protected
**/
- _getState: html5 ? function () {
- return this._history.get();
- } : function () {
- var jsonState = this._history.get('state');
- return jsonState ? Y.JSON.parse(jsonState) : {};
+ _joinURL: function (url) {
+ var root = this.root;
+
+ if (url.charAt(0) === '/') {
+ url = url.substring(1);
+ }
+
+ return root && root.charAt(root.length - 1) === '/' ?
+ root + url :
+ root + '/' + url;
},
/**
@@ -496,58 +613,59 @@ Y.Controller = Y.extend(Controller, Y.Base, {
return result;
},
+ /**
+ Removes the `root` URL from the from of _path_ (if it's there) and returns
+ the result. The returned path will always have a leading `/`.
+
+ @method _removeRoot
+ @param {String} path URL path.
+ @return {String} Rootless path.
+ @protected
+ **/
+ _removeRoot: function (path) {
+ var root = this.root;
+
+ if (root && path.indexOf(root) === 0) {
+ path = path.substring(root.length);
+ }
+
+ return path.charAt(0) === '/' ? path : '/' + path;
+ },
+
/**
Saves a history entry using either `pushState()` or the location hash.
@method _save
@param {String} [url] URL for the history entry.
- @param {String} [title] Page title associated with the history entry.
- @param {Object} [state] State object associated with the history entry.
@param {Boolean} [replace=false] If `true`, the current history entry will
be replaced instead of a new one being added.
@chainable
@protected
**/
- _save: function (url, title, state, replace) {
- var jsonState, query;
+ _save: html5 ? function (url, replace) {
+ // Force _ready to true to ensure that the history change is handled
+ // even if _save is called before the `ready` event fires.
+ this._ready = true;
- if (html5) {
- if (typeof url === 'string') {
- url = this.base + url;
- }
- } else {
- // If we're not using HTML5 history, take over the history state for
- // our own purposes and shove the implementer's state inside it as a
- // JSON string.
- jsonState = state && Y.JSON.stringify(state);
-
- // Extract a query string from the URL if there is one, then remove
- // both the query and the hash portions of the URL so we can store
- // just the path.
- url = url.replace(this._regexUrlQuery, function (match, params) {
- query = params;
- return '';
- });
-
- state = {path: url || this._getPath()};
+ this._history[replace ? 'replace' : 'add'](null, {
+ url: typeof url === 'string' ? this._joinURL(url) : url
+ });
+ return this;
+ } : function (url, replace) {
+ this._ready = true;
- query && (state.query = query);
- jsonState && (state.state = jsonState);
+ if (typeof url === 'string' && url.charAt(0) !== '/') {
+ url = '/' + url;
}
- this._history[replace ? 'replace' : 'add'](state || {}, {
- merge: false,
- title: title,
- url : url
- });
-
+ HistoryHash[replace ? 'replaceHash' : 'setHash'](url);
return this;
},
// -- Protected Event Handlers ---------------------------------------------
/**
- Handles `history:change` events.
+ Handles `history:change` and `hashchange` events.
@method _afterHistoryChange
@param {EventFacade} e
@@ -556,18 +674,48 @@ Y.Controller = Y.extend(Controller, Y.Base, {
_afterHistoryChange: function (e) {
var self = this;
- // We need to yield control to the UI thread to allow the browser to
- // update document.location before we dispatch.
- setTimeout(function () {
- self._dispatch(self._getPath(), self._getState());
- }, 1);
+ if (self._ready) {
+ // We need to yield control to the UI thread to allow the browser to
+ // update window.location before we dispatch.
+ setTimeout(function () {
+ self._dispatch(self._getPath());
+ }, 1);
+ }
+ },
+
+ // -- Default Event Handlers -----------------------------------------------
+
+ /**
+ Default handler for the `ready` event.
+
+ @method _defReadyFn
+ @param {EventFacade} e
+ @protected
+ **/
+ _defReadyFn: function (e) {
+ var hash;
+
+ this._ready = true;
+
+ if (this.dispatchOnInit && !this._dispatched) {
+ if (html5 && (hash = this._getHashPath())
+ && hash.charAt(0) === '/') {
+
+ // This is an HTML5 browser and we have a hash-based path in the
+ // URL, so we need to upgrade the URL to a non-hash URL. This
+ // will trigger a `history:change` event.
+ this._history.replace(null, {url: this._joinURL(hash)});
+ } else {
+ this._dispatch(this._getPath());
+ }
+ }
}
}, {
NAME: 'controller'
});
-}, '@VERSION@' ,{optional:['querystring-parse'], requires:['array-extras', 'base-build', 'history', 'json']});
+}, '@VERSION@' ,{requires:['array-extras', 'base-build', 'history'], optional:['querystring-parse']});
YUI.add('model', function(Y) {
/**
diff --git a/build/app/app-min.js b/build/app/app-min.js
index cb7bd5a18fc..af1547fe90e 100644
--- a/build/app/app-min.js
+++ b/build/app/app-min.js
@@ -1,2 +1,3 @@
-YUI.add("controller",function(f){var d=f.Array,b=f.QueryString,c=f.HistoryBase.html5&&(!f.UA.android||f.UA.android>=3),a=f.config.win.location;function e(){e.superclass.constructor.apply(this,arguments);}f.Controller=f.extend(e,f.Base,{base:"",routes:[],_regexPathParam:/([:*])([\w\d-]+)/g,_regexUrlQuery:/\?([^#]*).*$/,initializer:function(g){g||(g={});this._routes=[];g.base&&(this.base=g.base);g.routes&&(this.routes=g.routes);d.each(this.routes,function(h){this.route(h.path,h.callback,true);},this);this._history=c?new f.HistoryHTML5():new f.HistoryHash();this._history.after("change",this._afterHistoryChange,this);this._dispatch(this._getPath(),this._getState());},destructor:function(){this._history.detachAll();},match:function(g){return d.filter(this._routes,function(h){return g.search(h.regex)>-1;});},replace:function(g,i,h){return this._save(g,i,h,true);},route:function(h,i){var g=[];this._routes.push({callback:i,keys:g,path:h,regex:this._getRegex(h,g)});return this;},save:function(g,i,h){return this._save(g,i,h);},_decode:function(g){return decodeURIComponent(g.replace(/\+/g," "));},_dispatch:function(m,l){var g=this.match(m),k,i,h;if(!g||!g.length){return;}k=this._getRequest(m,l);h=this;function j(n){var p,o;if(n){f.error(n);}else{if((i=g.shift())){o=i.regex.exec(m);p=typeof i.callback==="string"?h[i.callback]:i.callback;if(o.length===i.keys.length+1){k.params=d.hash(i.keys,o.slice(1));}else{k.params={};d.each(o,function(r,q){k.params[q]=r;});}p.call(h,k,j);}}}j();},_getPath:c?function(){var g=this.base,h=a.pathname;if(g&&h.indexOf(g)===0){h=h.substring(g.length);}return h;}:function(){return this._history.get("path")||this.base+a.pathname;},_getQuery:c?function(){return a.search.substring(1);}:function(){return this._history.get("query")||a.search.substring(1);},_getRegex:function(h,g){if(h instanceof RegExp){return h;}h=h.replace(this._regexPathParam,function(j,i,k){g.push(k);return i==="*"?"(.*?)":"([^/]*)";});return new RegExp("^"+h+"$");},_getRequest:function(h,g){return{path:h,query:this._parseQuery(this._getQuery()),state:g};},_getState:c?function(){return this._history.get();}:function(){var g=this._history.get("state");return g?f.JSON.parse(g):{};},_parseQuery:b&&b.parse?b.parse:function(k){var l=this._decode,n=k.split("&"),j=0,h=n.length,g={},m;for(;j_item
method in case there is any special behavior that is
* appropriate for API mirroring.
If the iterated method returns a value, the return value from the
+ * added method will be an array of values with each value being at the
+ * corresponding index for that item. If the iterated method does not
+ * return a value, the added method will be chainable.
+ *
* @method addMethod
* @static
- * @param dest { Object } Object or prototype to receive the iterator method
- * @param name { String | Array } Name of method of methods to create
+ * @param dest {Object} Object or prototype to receive the iterator method
+ * @param name {String|String[]} Name of method of methods to create
*/
addMethod: function ( dest, names ) {
@@ -191,7 +196,7 @@ Y.mix( ArrayList, {
var result = item[ name ].apply( item, args );
if ( result !== undefined && result !== item ) {
- ret.push( result );
+ ret[i] = result;
}
}, this);
diff --git a/build/arraylist/arraylist-min.js b/build/arraylist/arraylist-min.js
index 74f3ebe2bc0..a4c0e74cf0e 100644
--- a/build/arraylist/arraylist-min.js
+++ b/build/arraylist/arraylist-min.js
@@ -1 +1 @@
-YUI.add("arraylist",function(e){var d=e.Array,c=d.each,a;function b(f){if(f!==undefined){this._items=e.Lang.isArray(f)?f:d(f);}else{this._items=this._items||[];}}a={item:function(f){return this._items[f];},each:function(g,f){c(this._items,function(j,h){j=this.item(h);g.call(f||j,j,h,this);},this);return this;},some:function(g,f){return d.some(this._items,function(j,h){j=this.item(h);return g.call(f||j,j,h,this);},this);},indexOf:function(f){return d.indexOf(this._items,f);},size:function(){return this._items.length;},isEmpty:function(){return !this.size();},toJSON:function(){return this._items;}};a._item=a.item;b.prototype=a;e.mix(b,{addMethod:function(f,g){g=d(g);c(g,function(h){f[h]=function(){var j=d(arguments,0,true),i=[];c(this._items,function(m,l){m=this._item(l);var k=m[h].apply(m,j);if(k!==undefined&&k!==m){i.push(k);}},this);return i.length?i:this;};});}});e.ArrayList=b;},"@VERSION@");
\ No newline at end of file
+YUI.add("arraylist",function(e){var d=e.Array,c=d.each,a;function b(f){if(f!==undefined){this._items=e.Lang.isArray(f)?f:d(f);}else{this._items=this._items||[];}}a={item:function(f){return this._items[f];},each:function(g,f){c(this._items,function(j,h){j=this.item(h);g.call(f||j,j,h,this);},this);return this;},some:function(g,f){return d.some(this._items,function(j,h){j=this.item(h);return g.call(f||j,j,h,this);},this);},indexOf:function(f){return d.indexOf(this._items,f);},size:function(){return this._items.length;},isEmpty:function(){return !this.size();},toJSON:function(){return this._items;}};a._item=a.item;b.prototype=a;e.mix(b,{addMethod:function(f,g){g=d(g);c(g,function(h){f[h]=function(){var j=d(arguments,0,true),i=[];c(this._items,function(m,l){m=this._item(l);var k=m[h].apply(m,j);if(k!==undefined&&k!==m){i[l]=k;}},this);return i.length?i:this;};});}});e.ArrayList=b;},"@VERSION@");
\ No newline at end of file
diff --git a/build/arraylist/arraylist.js b/build/arraylist/arraylist.js
index 5d5c120eb73..9e018c94748 100644
--- a/build/arraylist/arraylist.js
+++ b/build/arraylist/arraylist.js
@@ -171,10 +171,15 @@ Y.mix( ArrayList, {
* _item
method in case there is any special behavior that is
* appropriate for API mirroring.
If the iterated method returns a value, the return value from the
+ * added method will be an array of values with each value being at the
+ * corresponding index for that item. If the iterated method does not
+ * return a value, the added method will be chainable.
+ *
* @method addMethod
* @static
- * @param dest { Object } Object or prototype to receive the iterator method
- * @param name { String | Array } Name of method of methods to create
+ * @param dest {Object} Object or prototype to receive the iterator method
+ * @param name {String|String[]} Name of method of methods to create
*/
addMethod: function ( dest, names ) {
@@ -191,7 +196,7 @@ Y.mix( ArrayList, {
var result = item[ name ].apply( item, args );
if ( result !== undefined && result !== item ) {
- ret.push( result );
+ ret[i] = result;
}
}, this);
diff --git a/build/autocomplete-base/autocomplete-base-debug.js b/build/autocomplete-base/autocomplete-base-debug.js
index e4dab16bd1a..239b2d49d7c 100644
--- a/build/autocomplete-base/autocomplete-base-debug.js
+++ b/build/autocomplete-base/autocomplete-base-debug.js
@@ -1628,4 +1628,4 @@ AutoCompleteBase.prototype = {
Y.AutoCompleteBase = AutoCompleteBase;
-}, '@VERSION@' ,{requires:['array-extras', 'base-build', 'escape', 'event-valuechange', 'node-base'], optional:['autocomplete-sources']});
+}, '@VERSION@' ,{optional:['autocomplete-sources'], requires:['array-extras', 'base-build', 'escape', 'event-valuechange', 'node-base']});
diff --git a/build/autocomplete-base/autocomplete-base-min.js b/build/autocomplete-base/autocomplete-base-min.js
index 157db0f924a..eb5c73bc334 100644
--- a/build/autocomplete-base/autocomplete-base-min.js
+++ b/build/autocomplete-base/autocomplete-base-min.js
@@ -1,2 +1,2 @@
YUI.add("autocomplete-base",function(f){var g=f.Escape,j=f.Lang,q=f.Array,i=f.Object,d=j.isFunction,r=j.isString,u=j.trim,l=f.Attribute.INVALID_VALUE,o="_functionValidator",x="_sourceSuccess",c="allowBrowserAutocomplete",h="inputNode",w="query",e="queryDelimiter",b="requestTemplate",m="results",n="resultListLocator",k="value",s="valueChange",a="clear",t=w,p=m;function v(){f.before(this._bindUIACBase,this,"bindUI");f.before(this._destructorACBase,this,"destructor");f.before(this._syncUIACBase,this,"syncUI");this.publish(a,{defaultFn:this._defClearFn});this.publish(t,{defaultFn:this._defQueryFn});this.publish(p,{defaultFn:this._defResultsFn});}v.ATTRS={allowBrowserAutocomplete:{value:false},allowTrailingDelimiter:{value:false},inputNode:{setter:f.one,writeOnce:"initOnly"},maxResults:{value:0},minQueryLength:{value:1},query:{readOnly:true,value:null},queryDelay:{value:100},queryDelimiter:{value:null},requestTemplate:{setter:"_setRequestTemplate",value:null},resultFilters:{setter:"_setResultFilters",value:[]},resultFormatter:{validator:o},resultHighlighter:{setter:"_setResultHighlighter"},resultListLocator:{setter:"_setLocator"},results:{readOnly:true,value:[]},resultTextLocator:{setter:"_setLocator"},source:{setter:"_setSource"},sourceType:{value:null},tokenInput:{readOnly:true},value:{value:""}};v.CSS_PREFIX="ac";v.UI_SRC=(f.Widget&&f.Widget.UI_SRC)||"ui";v.SOURCE_TYPES={array:"_createArraySource","function":"_createFunctionSource",object:"_createObjectSource"};v.prototype={sendRequest:function(A,B){var y,z=this.get("source");if(A||A===""){this._set(w,A);}else{A=this.get(w);}if(z){if(!B){B=this.get(b);}y=B?B(A):A;z.sendRequest({query:A,request:y,callback:{success:f.bind(this._onResponse,this,A)}});}return this;},_bindUIACBase:function(){var z=this.get(h),y=z&&z.tokenInput;if(y){z=y.get(h);this._set("tokenInput",y);}if(!z){f.error("No inputNode specified.");return;}this._inputNode=z;this._acBaseEvents=new f.EventHandle([z.on(s,this._onInputValueChange,this),z.on("blur",this._onInputBlur,this),this.after(c+"Change",this._syncBrowserAutocomplete),this.after("sourceTypeChange",this._afterSourceTypeChange),this.after(s,this._afterValueChange)]);},_destructorACBase:function(){this._acBaseEvents.detach();},_syncUIACBase:function(){this._syncBrowserAutocomplete();this.set(k,this.get(h).get(k));},_createArraySource:function(z){var y=this;return{type:"array",sendRequest:function(A){y[x](z.concat(),A);}};},_createFunctionSource:function(z){var y=this;return{type:"function",sendRequest:function(A){var B;function C(D){y[x](D||[],A);}if((B=z(A.query,C))){C(B);}}};},_createObjectSource:function(z){var y=this;return{type:"object",sendRequest:function(A){var B=A.query;y[x](i.owns(z,B)?z[B]:[],A);}};},_functionValidator:function(y){return y===null||d(y);},_getObjectValue:function(B,A){if(!B){return;}for(var z=0,y=A.length;B&&z When passing in an array of JS files, setting this flag to true
+ * will insert them into the document in parallel, as opposed to the
+ * default behavior, which is to chain load them serially. It will also
+ * set the async attribute on the script node to true. Setting async:true
+ * will lead to optimal file download performance allowing the browser to
+ * download multiple scripts in parallel, and execute them as soon as they
+ * are available. Note that async:true does not guarantee execution order of the
+ * scripts being downloaded. They are executed in whichever order they
+ * are received. When passing in an array of JS files, setting this flag to true
+ * will insert them into the document in parallel, as opposed to the
+ * default behavior, which is to chain load them serially. It will also
+ * set the async attribute on the script node to true. Setting async:true
+ * will lead to optimal file download performance allowing the browser to
+ * download multiple scripts in parallel, and execute them as soon as they
+ * are available. Note that async:true does not guarantee execution order of the
+ * scripts being downloaded. They are executed in whichever order they
+ * are received. =g.rollup);if(e){break;}}}}if(e){b[k]=true;d=true;this.getRequires(g);}}}}if(!d){break;}}};},"@VERSION@",{requires:["loader-base"]});YUI.add("loader-yui3",function(a){YUI.Env[a.version].modules=YUI.Env[a.version].modules||{"align-plugin":{"requires":["node-screen","node-pluginhost"]},"anim":{"use":["anim-base","anim-color","anim-curve","anim-easing","anim-node-plugin","anim-scroll","anim-xy"]},"anim-base":{"requires":["base-base","node-style"]},"anim-color":{"requires":["anim-base"]},"anim-curve":{"requires":["anim-xy"]},"anim-easing":{"requires":["anim-base"]},"anim-node-plugin":{"requires":["node-pluginhost","anim-base"]},"anim-scroll":{"requires":["anim-base"]},"anim-xy":{"requires":["anim-base","node-screen"]},"app":{"use":["controller","model","model-list","view"]},"array-extras":{},"array-invoke":{},"arraylist":{},"arraylist-add":{"requires":["arraylist"]},"arraylist-filter":{"requires":["arraylist"]},"arraysort":{"requires":["yui-base"]},"async-queue":{"requires":["event-custom"]},"attribute":{"use":["attribute-base","attribute-complex"]},"attribute-base":{"requires":["event-custom"]},"attribute-complex":{"requires":["attribute-base"]},"autocomplete":{"use":["autocomplete-base","autocomplete-sources","autocomplete-list","autocomplete-plugin"]},"autocomplete-base":{"optional":["autocomplete-sources"],"requires":["array-extras","base-build","escape","event-valuechange","node-base"]},"autocomplete-filters":{"requires":["array-extras","text-wordbreak"]},"autocomplete-filters-accentfold":{"requires":["array-extras","text-accentfold","text-wordbreak"]},"autocomplete-highlighters":{"requires":["array-extras","highlight-base"]},"autocomplete-highlighters-accentfold":{"requires":["array-extras","highlight-accentfold"]},"autocomplete-list":{"after":["autocomplete-sources"],"lang":["en"],"requires":["autocomplete-base","event-resize","selector-css3","shim-plugin","widget","widget-position","widget-position-align"],"skinnable":true},"autocomplete-list-keys":{"condition":{"name":"autocomplete-list-keys","test":function(b){return !(b.UA.ios||b.UA.android);
-},"trigger":"autocomplete-list"},"requires":["autocomplete-list","base-build"]},"autocomplete-plugin":{"requires":["autocomplete-list","node-pluginhost"]},"autocomplete-sources":{"optional":["io-base","json-parse","jsonp","yql"],"requires":["autocomplete-base"]},"base":{"use":["base-base","base-pluginhost","base-build"]},"base-base":{"after":["attribute-complex"],"requires":["attribute-base"]},"base-build":{"requires":["base-base"]},"base-pluginhost":{"requires":["base-base","pluginhost"]},"cache":{"use":["cache-base","cache-offline","cache-plugin"]},"cache-base":{"requires":["base"]},"cache-offline":{"requires":["cache-base","json"]},"cache-plugin":{"requires":["plugin","cache-base"]},"charts":{"requires":["dom","datatype","event-custom","event-mouseenter","widget","widget-position","widget-stack"]},"classnamemanager":{"requires":["yui-base"]},"clickable-rail":{"requires":["slider-base"]},"collection":{"use":["array-extras","arraylist","arraylist-add","arraylist-filter","array-invoke"]},"compat":{"requires":["event-base","dom","dump","substitute"]},"console":{"lang":["en","es"],"requires":["yui-log","widget","substitute"],"skinnable":true},"console-filters":{"requires":["plugin","console"],"skinnable":true},"controller":{"optional":["querystring-parse"],"requires":["array-extras","base-build","history","json"]},"cookie":{"requires":["yui-base"]},"createlink-base":{"requires":["editor-base"]},"cssbase":{"after":["cssreset","cssfonts","cssgrids","cssreset-context","cssfonts-context","cssgrids-context"],"type":"css"},"cssbase-context":{"after":["cssreset","cssfonts","cssgrids","cssreset-context","cssfonts-context","cssgrids-context"],"type":"css"},"cssfonts":{"type":"css"},"cssfonts-context":{"type":"css"},"cssgrids":{"optional":["cssreset","cssfonts"],"type":"css"},"cssgrids-context-deprecated":{"optional":["cssreset-context"],"requires":["cssfonts-context"],"type":"css"},"cssgrids-deprecated":{"optional":["cssreset"],"requires":["cssfonts"],"type":"css"},"cssreset":{"type":"css"},"cssreset-context":{"type":"css"},"dataschema":{"use":["dataschema-base","dataschema-json","dataschema-xml","dataschema-array","dataschema-text"]},"dataschema-array":{"requires":["dataschema-base"]},"dataschema-base":{"requires":["base"]},"dataschema-json":{"requires":["dataschema-base","json"]},"dataschema-text":{"requires":["dataschema-base"]},"dataschema-xml":{"requires":["dataschema-base"]},"datasource":{"use":["datasource-local","datasource-io","datasource-get","datasource-function","datasource-cache","datasource-jsonschema","datasource-xmlschema","datasource-arrayschema","datasource-textschema","datasource-polling"]},"datasource-arrayschema":{"requires":["datasource-local","plugin","dataschema-array"]},"datasource-cache":{"requires":["datasource-local","plugin","cache-base"]},"datasource-function":{"requires":["datasource-local"]},"datasource-get":{"requires":["datasource-local","get"]},"datasource-io":{"requires":["datasource-local","io-base"]},"datasource-jsonschema":{"requires":["datasource-local","plugin","dataschema-json"]},"datasource-local":{"requires":["base"]},"datasource-polling":{"requires":["datasource-local"]},"datasource-textschema":{"requires":["datasource-local","plugin","dataschema-text"]},"datasource-xmlschema":{"requires":["datasource-local","plugin","dataschema-xml"]},"datatable":{"use":["datatable-base","datatable-datasource","datatable-sort","datatable-scroll"]},"datatable-base":{"requires":["recordset-base","widget","substitute","event-mouseenter"],"skinnable":true},"datatable-datasource":{"requires":["datatable-base","plugin","datasource-local"]},"datatable-scroll":{"requires":["datatable-base","plugin","stylesheet"]},"datatable-sort":{"lang":["en"],"requires":["datatable-base","plugin","recordset-sort"]},"datatype":{"use":["datatype-number","datatype-date","datatype-xml"]},"datatype-date":{"lang":["ar","ar-JO","ca","ca-ES","da","da-DK","de","de-AT","de-DE","el","el-GR","en","en-AU","en-CA","en-GB","en-IE","en-IN","en-JO","en-MY","en-NZ","en-PH","en-SG","en-US","es","es-AR","es-BO","es-CL","es-CO","es-EC","es-ES","es-MX","es-PE","es-PY","es-US","es-UY","es-VE","fi","fi-FI","fr","fr-BE","fr-CA","fr-FR","hi","hi-IN","id","id-ID","it","it-IT","ja","ja-JP","ko","ko-KR","ms","ms-MY","nb","nb-NO","nl","nl-BE","nl-NL","pl","pl-PL","pt","pt-BR","ro","ro-RO","ru","ru-RU","sv","sv-SE","th","th-TH","tr","tr-TR","vi","vi-VN","zh-Hans","zh-Hans-CN","zh-Hant","zh-Hant-HK","zh-Hant-TW"],"supersedes":["datatype-date-format"],"use2":["datatype-date-parse","datatype-date-format"]},"datatype-date-format":{},"datatype-date-parse":{},"datatype-number":{"use":["datatype-number-parse","datatype-number-format"]},"datatype-number-format":{},"datatype-number-parse":{},"datatype-xml":{"use":["datatype-xml-parse","datatype-xml-format"]},"datatype-xml-format":{},"datatype-xml-parse":{},"dd":{"use":["dd-ddm-base","dd-ddm","dd-ddm-drop","dd-drag","dd-proxy","dd-constrain","dd-drop","dd-scroll","dd-delegate"]},"dd-constrain":{"requires":["dd-drag"]},"dd-ddm":{"requires":["dd-ddm-base","event-resize"]},"dd-ddm-base":{"requires":["node","base","yui-throttle","classnamemanager"]},"dd-ddm-drop":{"requires":["dd-ddm"]},"dd-delegate":{"requires":["dd-drag","dd-drop-plugin","event-mouseenter"]},"dd-drag":{"requires":["dd-ddm-base"]},"dd-drop":{"requires":["dd-drag","dd-ddm-drop"]},"dd-drop-plugin":{"requires":["dd-drop"]},"dd-gestures":{"condition":{"name":"dd-gestures","test":function(b){return(b.config.win&&("ontouchstart" in b.config.win&&!b.UA.chrome));},"trigger":"dd-drag"},"requires":["dd-drag","event-synthetic","event-gestures"]},"dd-plugin":{"optional":["dd-constrain","dd-proxy"],"requires":["dd-drag"]},"dd-proxy":{"requires":["dd-drag"]},"dd-scroll":{"requires":["dd-drag"]},"dial":{"lang":["en","es"],"requires":["widget","dd-drag","substitute","event-mouseenter","event-move","transition","intl"],"skinnable":true},"dom":{"use":["dom-core","dom-base","dom-attrs","dom-create","dom-class","dom-size","dom-screen","dom-style","selector-native","selector"]},"dom-attrs":{"requires":["dom-core"]},"dom-base":{"requires":["dom-core","dom-attrs","dom-create","dom-class","dom-size"]},"dom-class":{"requires":["dom-core"]},"dom-core":{"requires":["oop","features"]},"dom-create":{"requires":["dom-core"]},"dom-deprecated":{"requires":["dom-core"]},"dom-screen":{"requires":["dom-core","dom-style"]},"dom-size":{"requires":["dom-core"]},"dom-style":{"requires":["dom-core"]},"dom-style-ie":{"condition":{"name":"dom-style-ie","test":function(h){var f=h.Features.test,g=h.Features.add,d=h.config.win,e=h.config.doc,b="documentElement",c=false;
-g("style","computedStyle",{test:function(){return d&&"getComputedStyle" in d;}});g("style","opacity",{test:function(){return e&&"opacity" in e[b].style;}});c=(!f("style","opacity")&&!f("style","computedStyle"));return c;},"trigger":"dom-style"},"requires":["dom-style"]},"dump":{},"editor":{"use":["frame","selection","exec-command","editor-base","editor-para","editor-br","editor-bidi","editor-tab","createlink-base"]},"editor-base":{"requires":["base","frame","node","exec-command","selection"]},"editor-bidi":{"requires":["editor-base"]},"editor-br":{"requires":["editor-base"]},"editor-lists":{"requires":["editor-base"]},"editor-para":{"requires":["editor-base"]},"editor-tab":{"requires":["editor-base"]},"escape":{},"event":{"after":["node-base"],"use":["event-base","event-delegate","event-synthetic","event-mousewheel","event-mouseenter","event-key","event-focus","event-resize","event-hover"]},"event-base":{"after":["node-base"],"requires":["event-custom-base"]},"event-base-ie":{"after":["event-base"],"condition":{"name":"event-base-ie","test":function(c){var b=c.config.doc&&c.config.doc.implementation;return(b&&(!b.hasFeature("Events","2.0")));},"trigger":"node-base"},"requires":["node-base"]},"event-custom":{"use":["event-custom-base","event-custom-complex"]},"event-custom-base":{"requires":["oop"]},"event-custom-complex":{"requires":["event-custom-base"]},"event-delegate":{"requires":["node-base"]},"event-flick":{"requires":["node-base","event-touch","event-synthetic"]},"event-focus":{"requires":["event-synthetic"]},"event-gestures":{"use":["event-flick","event-move"]},"event-hover":{"requires":["event-mouseenter"]},"event-key":{"requires":["event-synthetic"]},"event-mouseenter":{"requires":["event-synthetic"]},"event-mousewheel":{"requires":["node-base"]},"event-move":{"requires":["node-base","event-touch","event-synthetic"]},"event-resize":{"requires":["node-base"]},"event-simulate":{"requires":["event-base"]},"event-synthetic":{"requires":["node-base","event-custom-complex"]},"event-touch":{"requires":["node-base"]},"event-valuechange":{"requires":["event-focus","event-synthetic"]},"exec-command":{"requires":["frame"]},"features":{"requires":["yui-base"]},"frame":{"requires":["base","node","selector-css3","substitute","yui-throttle"]},"get":{"requires":["yui-base"]},"highlight":{"use":["highlight-base","highlight-accentfold"]},"highlight-accentfold":{"requires":["highlight-base","text-accentfold"]},"highlight-base":{"requires":["array-extras","escape","text-wordbreak"]},"history":{"use":["history-base","history-hash","history-hash-ie","history-html5"]},"history-base":{"requires":["event-custom-complex"]},"history-hash":{"after":["history-html5"],"requires":["event-synthetic","history-base","yui-later"]},"history-hash-ie":{"condition":{"name":"history-hash-ie","test":function(c){var b=c.config.doc&&c.config.doc.documentMode;return c.UA.ie&&(!("onhashchange" in c.config.win)||!b||b<8);},"trigger":"history-hash"},"requires":["history-hash","node-base"]},"history-html5":{"optional":["json"],"requires":["event-base","history-base","node-base"]},"imageloader":{"requires":["base-base","node-style","node-screen"]},"intl":{"requires":["intl-base","event-custom"]},"intl-base":{"requires":["yui-base"]},"io":{"use":["io-base","io-xdr","io-form","io-upload-iframe","io-queue"]},"io-base":{"requires":["event-custom-base","querystring-stringify-simple"]},"io-form":{"requires":["io-base","node-base"]},"io-queue":{"requires":["io-base","queue-promote"]},"io-upload-iframe":{"requires":["io-base","node-base"]},"io-xdr":{"requires":["io-base","datatype-xml"]},"json":{"use":["json-parse","json-stringify"]},"json-parse":{},"json-stringify":{},"jsonp":{"requires":["get","oop"]},"jsonp-url":{"requires":["jsonp"]},"loader":{"use":["loader-base","loader-rollup","loader-yui3"]},"loader-base":{"requires":["get"]},"loader-rollup":{"requires":["loader-base"]},"loader-yui3":{"requires":["loader-base"]},"model":{"requires":["base-build","escape","json-parse"]},"model-list":{"requires":["array-extras","array-invoke","arraylist","base-build","json-parse","model"]},"node":{"use":["node-base","node-event-delegate","node-pluginhost","node-screen","node-style"]},"node-base":{"requires":["dom-base","selector-css2","event-base"]},"node-deprecated":{"requires":["node-base"]},"node-event-delegate":{"requires":["node-base","event-delegate"]},"node-event-simulate":{"requires":["node-base","event-simulate"]},"node-flick":{"requires":["classnamemanager","transition","event-flick","plugin"],"skinnable":true},"node-focusmanager":{"requires":["attribute","node","plugin","node-event-simulate","event-key","event-focus"]},"node-load":{"requires":["node-base","io-base"]},"node-menunav":{"requires":["node","classnamemanager","plugin","node-focusmanager"],"skinnable":true},"node-pluginhost":{"requires":["node-base","pluginhost"]},"node-screen":{"requires":["dom-screen","node-base"]},"node-style":{"requires":["dom-style","node-base"]},"oop":{"requires":["yui-base"]},"overlay":{"requires":["widget","widget-stdmod","widget-position","widget-position-align","widget-stack","widget-position-constrain"],"skinnable":true},"plugin":{"requires":["base-base"]},"pluginattr":{"requires":["plugin"]},"pluginhost":{"use":["pluginhost-base","pluginhost-config"]},"pluginhost-base":{"requires":["yui-base"]},"pluginhost-config":{"requires":["pluginhost-base"]},"profiler":{"requires":["yui-base"]},"querystring":{"use":["querystring-parse","querystring-stringify"]},"querystring-parse":{"requires":["yui-base","array-extras"]},"querystring-parse-simple":{"requires":["yui-base"]},"querystring-stringify":{"requires":["yui-base"]},"querystring-stringify-simple":{"requires":["yui-base"]},"queue-promote":{"requires":["yui-base"]},"range-slider":{"requires":["slider-base","slider-value-range","clickable-rail"]},"recordset":{"use":["recordset-base","recordset-sort","recordset-filter","recordset-indexer"]},"recordset-base":{"requires":["base","arraylist"]},"recordset-filter":{"requires":["recordset-base","array-extras","plugin"]},"recordset-indexer":{"requires":["recordset-base","plugin"]},"recordset-sort":{"requires":["arraysort","recordset-base","plugin"]},"resize":{"use":["resize-base","resize-proxy","resize-constrain"]},"resize-base":{"requires":["base","widget","substitute","event","oop","dd-drag","dd-delegate","dd-drop"],"skinnable":true},"resize-constrain":{"requires":["plugin","resize-base"]},"resize-plugin":{"optional":["resize-constrain"],"requires":["resize-base","plugin"]},"resize-proxy":{"requires":["plugin","resize-base"]},"rls":{"requires":["get","features"]},"scrollview":{"requires":["scrollview-base","scrollview-scrollbars"]},"scrollview-base":{"requires":["widget","event-gestures","transition"],"skinnable":true},"scrollview-base-ie":{"condition":{"name":"scrollview-base-ie","trigger":"scrollview-base","ua":"ie"},"requires":["scrollview-base"]},"scrollview-paginator":{"requires":["plugin"]},"scrollview-scrollbars":{"requires":["plugin"],"skinnable":true},"selection":{"requires":["node"]},"selector":{"requires":["selector-native"]},"selector-css2":{"condition":{"name":"selector-css2","test":function(d){var c=d.config.doc,b=c&&!("querySelectorAll" in c);
-return b;},"trigger":"selector"},"requires":["selector-native"]},"selector-css3":{"requires":["selector-native","selector-css2"]},"selector-native":{"requires":["dom-core"]},"shim-plugin":{"requires":["node-style","node-pluginhost"]},"slider":{"use":["slider-base","slider-value-range","clickable-rail","range-slider"]},"slider-base":{"requires":["widget","dd-constrain","substitute"],"skinnable":true},"slider-value-range":{"requires":["slider-base"]},"sortable":{"requires":["dd-delegate","dd-drop-plugin","dd-proxy"]},"sortable-scroll":{"requires":["dd-scroll","sortable"]},"stylesheet":{},"substitute":{"optional":["dump"]},"swf":{"requires":["event-custom","node","swfdetect"]},"swfdetect":{},"tabview":{"requires":["widget","widget-parent","widget-child","tabview-base","node-pluginhost","node-focusmanager"],"skinnable":true},"tabview-base":{"requires":["node-event-delegate","classnamemanager","skin-sam-tabview"]},"tabview-plugin":{"requires":["tabview-base"]},"test":{"requires":["event-simulate","event-custom","substitute","json-stringify"],"skinnable":true},"text":{"use":["text-accentfold","text-wordbreak"]},"text-accentfold":{"requires":["array-extras","text-data-accentfold"]},"text-data-accentfold":{},"text-data-wordbreak":{},"text-wordbreak":{"requires":["array-extras","text-data-wordbreak"]},"transition":{"use":["transition-native","transition-timer"]},"transition-native":{"requires":["node-base"]},"transition-timer":{"requires":["transition-native","node-style"]},"uploader":{"requires":["event-custom","node","base","swf"]},"view":{"requires":["base-build","node-event-delegate"]},"widget":{"skinnable":true,"use":["widget-base","widget-htmlparser","widget-uievents","widget-skin"]},"widget-anim":{"requires":["plugin","anim-base","widget"]},"widget-base":{"requires":["attribute","event-focus","base-base","base-pluginhost","node-base","node-style","classnamemanager"]},"widget-base-ie":{"condition":{"name":"widget-base-ie","trigger":"widget-base","ua":"ie"},"requires":["widget-base"]},"widget-child":{"requires":["base-build","widget"]},"widget-htmlparser":{"requires":["widget-base"]},"widget-locale":{"requires":["widget-base"]},"widget-parent":{"requires":["base-build","arraylist","widget"]},"widget-position":{"requires":["base-build","node-screen","widget"]},"widget-position-align":{"requires":["widget-position"]},"widget-position-constrain":{"requires":["widget-position"]},"widget-skin":{"requires":["widget-base"]},"widget-stack":{"requires":["base-build","widget"],"skinnable":true},"widget-stdmod":{"requires":["base-build","widget"]},"widget-uievents":{"requires":["widget-base","node-event-delegate"]},"yql":{"requires":["jsonp","jsonp-url"]},"yui":{"use":["yui-base","get","features","intl-base","yui-log","yui-later","loader-base","loader-rollup","loader-yui3"]},"yui-base":{},"yui-later":{"requires":["yui-base"]},"yui-log":{"requires":["yui-base"]},"yui-rls":{"use":["yui-base","get","features","intl-base","rls","yui-log","yui-later"]},"yui-throttle":{"requires":["yui-base"]}};YUI.Env[a.version].md5="cfd89af2919db3983caf2874fc3a38bf";},"@VERSION@",{requires:["loader-base"]});YUI.add("loader",function(a){},"@VERSION@",{use:["loader-base","loader-rollup","loader-yui3"]});
\ No newline at end of file
+},"trigger":"autocomplete-list"},"requires":["autocomplete-list","base-build"]},"autocomplete-plugin":{"requires":["autocomplete-list","node-pluginhost"]},"autocomplete-sources":{"optional":["io-base","json-parse","jsonp","yql"],"requires":["autocomplete-base"]},"base":{"use":["base-base","base-pluginhost","base-build"]},"base-base":{"after":["attribute-complex"],"requires":["attribute-base"]},"base-build":{"requires":["base-base"]},"base-pluginhost":{"requires":["base-base","pluginhost"]},"cache":{"use":["cache-base","cache-offline","cache-plugin"]},"cache-base":{"requires":["base"]},"cache-offline":{"requires":["cache-base","json"]},"cache-plugin":{"requires":["plugin","cache-base"]},"charts":{"requires":["dom","datatype","event-custom","event-mouseenter","widget","widget-position","widget-stack"]},"classnamemanager":{"requires":["yui-base"]},"clickable-rail":{"requires":["slider-base"]},"collection":{"use":["array-extras","arraylist","arraylist-add","arraylist-filter","array-invoke"]},"compat":{"requires":["event-base","dom","dump","substitute"]},"console":{"lang":["en","es"],"requires":["yui-log","widget","substitute"],"skinnable":true},"console-filters":{"requires":["plugin","console"],"skinnable":true},"controller":{"optional":["querystring-parse"],"requires":["array-extras","base-build","history"]},"cookie":{"requires":["yui-base"]},"createlink-base":{"requires":["editor-base"]},"cssbase":{"after":["cssreset","cssfonts","cssgrids","cssreset-context","cssfonts-context","cssgrids-context"],"type":"css"},"cssbase-context":{"after":["cssreset","cssfonts","cssgrids","cssreset-context","cssfonts-context","cssgrids-context"],"type":"css"},"cssfonts":{"type":"css"},"cssfonts-context":{"type":"css"},"cssgrids":{"optional":["cssreset","cssfonts"],"type":"css"},"cssgrids-context-deprecated":{"optional":["cssreset-context"],"requires":["cssfonts-context"],"type":"css"},"cssgrids-deprecated":{"optional":["cssreset"],"requires":["cssfonts"],"type":"css"},"cssreset":{"type":"css"},"cssreset-context":{"type":"css"},"dataschema":{"use":["dataschema-base","dataschema-json","dataschema-xml","dataschema-array","dataschema-text"]},"dataschema-array":{"requires":["dataschema-base"]},"dataschema-base":{"requires":["base"]},"dataschema-json":{"requires":["dataschema-base","json"]},"dataschema-text":{"requires":["dataschema-base"]},"dataschema-xml":{"requires":["dataschema-base"]},"datasource":{"use":["datasource-local","datasource-io","datasource-get","datasource-function","datasource-cache","datasource-jsonschema","datasource-xmlschema","datasource-arrayschema","datasource-textschema","datasource-polling"]},"datasource-arrayschema":{"requires":["datasource-local","plugin","dataschema-array"]},"datasource-cache":{"requires":["datasource-local","plugin","cache-base"]},"datasource-function":{"requires":["datasource-local"]},"datasource-get":{"requires":["datasource-local","get"]},"datasource-io":{"requires":["datasource-local","io-base"]},"datasource-jsonschema":{"requires":["datasource-local","plugin","dataschema-json"]},"datasource-local":{"requires":["base"]},"datasource-polling":{"requires":["datasource-local"]},"datasource-textschema":{"requires":["datasource-local","plugin","dataschema-text"]},"datasource-xmlschema":{"requires":["datasource-local","plugin","dataschema-xml"]},"datatable":{"use":["datatable-base","datatable-datasource","datatable-sort","datatable-scroll"]},"datatable-base":{"requires":["recordset-base","widget","substitute","event-mouseenter"],"skinnable":true},"datatable-datasource":{"requires":["datatable-base","plugin","datasource-local"]},"datatable-scroll":{"requires":["datatable-base","plugin","stylesheet"]},"datatable-sort":{"lang":["en"],"requires":["datatable-base","plugin","recordset-sort"]},"datatype":{"use":["datatype-number","datatype-date","datatype-xml"]},"datatype-date":{"lang":["ar","ar-JO","ca","ca-ES","da","da-DK","de","de-AT","de-DE","el","el-GR","en","en-AU","en-CA","en-GB","en-IE","en-IN","en-JO","en-MY","en-NZ","en-PH","en-SG","en-US","es","es-AR","es-BO","es-CL","es-CO","es-EC","es-ES","es-MX","es-PE","es-PY","es-US","es-UY","es-VE","fi","fi-FI","fr","fr-BE","fr-CA","fr-FR","hi","hi-IN","id","id-ID","it","it-IT","ja","ja-JP","ko","ko-KR","ms","ms-MY","nb","nb-NO","nl","nl-BE","nl-NL","pl","pl-PL","pt","pt-BR","ro","ro-RO","ru","ru-RU","sv","sv-SE","th","th-TH","tr","tr-TR","vi","vi-VN","zh-Hans","zh-Hans-CN","zh-Hant","zh-Hant-HK","zh-Hant-TW"],"supersedes":["datatype-date-format"],"use2":["datatype-date-parse","datatype-date-format"]},"datatype-date-format":{},"datatype-date-parse":{},"datatype-number":{"use":["datatype-number-parse","datatype-number-format"]},"datatype-number-format":{},"datatype-number-parse":{},"datatype-xml":{"use":["datatype-xml-parse","datatype-xml-format"]},"datatype-xml-format":{},"datatype-xml-parse":{},"dd":{"use":["dd-ddm-base","dd-ddm","dd-ddm-drop","dd-drag","dd-proxy","dd-constrain","dd-drop","dd-scroll","dd-delegate"]},"dd-constrain":{"requires":["dd-drag"]},"dd-ddm":{"requires":["dd-ddm-base","event-resize"]},"dd-ddm-base":{"requires":["node","base","yui-throttle","classnamemanager"]},"dd-ddm-drop":{"requires":["dd-ddm"]},"dd-delegate":{"requires":["dd-drag","dd-drop-plugin","event-mouseenter"]},"dd-drag":{"requires":["dd-ddm-base"]},"dd-drop":{"requires":["dd-drag","dd-ddm-drop"]},"dd-drop-plugin":{"requires":["dd-drop"]},"dd-gestures":{"condition":{"name":"dd-gestures","test":function(b){return(b.config.win&&("ontouchstart" in b.config.win&&!b.UA.chrome));},"trigger":"dd-drag"},"requires":["dd-drag","event-synthetic","event-gestures"]},"dd-plugin":{"optional":["dd-constrain","dd-proxy"],"requires":["dd-drag"]},"dd-proxy":{"requires":["dd-drag"]},"dd-scroll":{"requires":["dd-drag"]},"dial":{"lang":["en","es"],"requires":["widget","dd-drag","substitute","event-mouseenter","event-move","transition","intl"],"skinnable":true},"dom":{"use":["dom-core","dom-base","dom-attrs","dom-create","dom-class","dom-size","dom-screen","dom-style","selector-native","selector"]},"dom-attrs":{"requires":["dom-core"]},"dom-base":{"requires":["dom-core","dom-attrs","dom-create","dom-class","dom-size"]},"dom-class":{"requires":["dom-core"]},"dom-core":{"requires":["oop","features"]},"dom-create":{"requires":["dom-core"]},"dom-deprecated":{"requires":["dom-core"]},"dom-screen":{"requires":["dom-core","dom-style"]},"dom-size":{"requires":["dom-core"]},"dom-style":{"requires":["dom-core"]},"dom-style-ie":{"condition":{"name":"dom-style-ie","test":function(h){var f=h.Features.test,g=h.Features.add,d=h.config.win,e=h.config.doc,b="documentElement",c=false;
+g("style","computedStyle",{test:function(){return d&&"getComputedStyle" in d;}});g("style","opacity",{test:function(){return e&&"opacity" in e[b].style;}});c=(!f("style","opacity")&&!f("style","computedStyle"));return c;},"trigger":"dom-style"},"requires":["dom-style"]},"dump":{},"editor":{"use":["frame","selection","exec-command","editor-base","editor-para","editor-br","editor-bidi","editor-tab","createlink-base"]},"editor-base":{"requires":["base","frame","node","exec-command","selection"]},"editor-bidi":{"requires":["editor-base"]},"editor-br":{"requires":["editor-base"]},"editor-lists":{"requires":["editor-base"]},"editor-para":{"requires":["editor-base"]},"editor-tab":{"requires":["editor-base"]},"escape":{},"event":{"after":["node-base"],"use":["event-base","event-delegate","event-synthetic","event-mousewheel","event-mouseenter","event-key","event-focus","event-resize","event-hover"]},"event-base":{"after":["node-base"],"requires":["event-custom-base"]},"event-base-ie":{"after":["event-base"],"condition":{"name":"event-base-ie","test":function(c){var b=c.config.doc&&c.config.doc.implementation;return(b&&(!b.hasFeature("Events","2.0")));},"trigger":"node-base"},"requires":["node-base"]},"event-custom":{"use":["event-custom-base","event-custom-complex"]},"event-custom-base":{"requires":["oop"]},"event-custom-complex":{"requires":["event-custom-base"]},"event-delegate":{"requires":["node-base"]},"event-flick":{"requires":["node-base","event-touch","event-synthetic"]},"event-focus":{"requires":["event-synthetic"]},"event-gestures":{"use":["event-flick","event-move"]},"event-hover":{"requires":["event-mouseenter"]},"event-key":{"requires":["event-synthetic"]},"event-mouseenter":{"requires":["event-synthetic"]},"event-mousewheel":{"requires":["node-base"]},"event-move":{"requires":["node-base","event-touch","event-synthetic"]},"event-resize":{"requires":["node-base"]},"event-simulate":{"requires":["event-base"]},"event-synthetic":{"requires":["node-base","event-custom-complex"]},"event-touch":{"requires":["node-base"]},"event-valuechange":{"requires":["event-focus","event-synthetic"]},"exec-command":{"requires":["frame"]},"features":{"requires":["yui-base"]},"frame":{"requires":["base","node","selector-css3","substitute","yui-throttle"]},"get":{"requires":["yui-base"]},"highlight":{"use":["highlight-base","highlight-accentfold"]},"highlight-accentfold":{"requires":["highlight-base","text-accentfold"]},"highlight-base":{"requires":["array-extras","escape","text-wordbreak"]},"history":{"use":["history-base","history-hash","history-hash-ie","history-html5"]},"history-base":{"requires":["event-custom-complex"]},"history-hash":{"after":["history-html5"],"requires":["event-synthetic","history-base","yui-later"]},"history-hash-ie":{"condition":{"name":"history-hash-ie","test":function(c){var b=c.config.doc&&c.config.doc.documentMode;return c.UA.ie&&(!("onhashchange" in c.config.win)||!b||b<8);},"trigger":"history-hash"},"requires":["history-hash","node-base"]},"history-html5":{"optional":["json"],"requires":["event-base","history-base","node-base"]},"imageloader":{"requires":["base-base","node-style","node-screen"]},"intl":{"requires":["intl-base","event-custom"]},"intl-base":{"requires":["yui-base"]},"io":{"use":["io-base","io-xdr","io-form","io-upload-iframe","io-queue"]},"io-base":{"requires":["event-custom-base","querystring-stringify-simple"]},"io-form":{"requires":["io-base","node-base"]},"io-queue":{"requires":["io-base","queue-promote"]},"io-upload-iframe":{"requires":["io-base","node-base"]},"io-xdr":{"requires":["io-base","datatype-xml"]},"json":{"use":["json-parse","json-stringify"]},"json-parse":{},"json-stringify":{},"jsonp":{"requires":["get","oop"]},"jsonp-url":{"requires":["jsonp"]},"loader":{"use":["loader-base","loader-rollup","loader-yui3"]},"loader-base":{"requires":["get"]},"loader-rollup":{"requires":["loader-base"]},"loader-yui3":{"requires":["loader-base"]},"model":{"requires":["base-build","escape","json-parse"]},"model-list":{"requires":["array-extras","array-invoke","arraylist","base-build","json-parse","model"]},"node":{"use":["node-base","node-event-delegate","node-pluginhost","node-screen","node-style"]},"node-base":{"requires":["dom-base","selector-css2","event-base"]},"node-deprecated":{"requires":["node-base"]},"node-event-delegate":{"requires":["node-base","event-delegate"]},"node-event-simulate":{"requires":["node-base","event-simulate"]},"node-flick":{"requires":["classnamemanager","transition","event-flick","plugin"],"skinnable":true},"node-focusmanager":{"requires":["attribute","node","plugin","node-event-simulate","event-key","event-focus"]},"node-load":{"requires":["node-base","io-base"]},"node-menunav":{"requires":["node","classnamemanager","plugin","node-focusmanager"],"skinnable":true},"node-pluginhost":{"requires":["node-base","pluginhost"]},"node-screen":{"requires":["dom-screen","node-base"]},"node-style":{"requires":["dom-style","node-base"]},"oop":{"requires":["yui-base"]},"overlay":{"requires":["widget","widget-stdmod","widget-position","widget-position-align","widget-stack","widget-position-constrain"],"skinnable":true},"plugin":{"requires":["base-base"]},"pluginattr":{"requires":["plugin"]},"pluginhost":{"use":["pluginhost-base","pluginhost-config"]},"pluginhost-base":{"requires":["yui-base"]},"pluginhost-config":{"requires":["pluginhost-base"]},"profiler":{"requires":["yui-base"]},"querystring":{"use":["querystring-parse","querystring-stringify"]},"querystring-parse":{"requires":["yui-base","array-extras"]},"querystring-parse-simple":{"requires":["yui-base"]},"querystring-stringify":{"requires":["yui-base"]},"querystring-stringify-simple":{"requires":["yui-base"]},"queue-promote":{"requires":["yui-base"]},"range-slider":{"requires":["slider-base","slider-value-range","clickable-rail"]},"recordset":{"use":["recordset-base","recordset-sort","recordset-filter","recordset-indexer"]},"recordset-base":{"requires":["base","arraylist"]},"recordset-filter":{"requires":["recordset-base","array-extras","plugin"]},"recordset-indexer":{"requires":["recordset-base","plugin"]},"recordset-sort":{"requires":["arraysort","recordset-base","plugin"]},"resize":{"use":["resize-base","resize-proxy","resize-constrain"]},"resize-base":{"requires":["base","widget","substitute","event","oop","dd-drag","dd-delegate","dd-drop"],"skinnable":true},"resize-constrain":{"requires":["plugin","resize-base"]},"resize-plugin":{"optional":["resize-constrain"],"requires":["resize-base","plugin"]},"resize-proxy":{"requires":["plugin","resize-base"]},"rls":{"requires":["get","features"]},"scrollview":{"requires":["scrollview-base","scrollview-scrollbars"]},"scrollview-base":{"requires":["widget","event-gestures","transition"],"skinnable":true},"scrollview-base-ie":{"condition":{"name":"scrollview-base-ie","trigger":"scrollview-base","ua":"ie"},"requires":["scrollview-base"]},"scrollview-paginator":{"requires":["plugin"]},"scrollview-scrollbars":{"requires":["classnamemanager","transition","plugin"],"skinnable":true},"selection":{"requires":["node"]},"selector":{"requires":["selector-native"]},"selector-css2":{"condition":{"name":"selector-css2","test":function(d){var c=d.config.doc,b=c&&!("querySelectorAll" in c);
+return b;},"trigger":"selector"},"requires":["selector-native"]},"selector-css3":{"requires":["selector-native","selector-css2"]},"selector-native":{"requires":["dom-core"]},"shim-plugin":{"requires":["node-style","node-pluginhost"]},"slider":{"use":["slider-base","slider-value-range","clickable-rail","range-slider"]},"slider-base":{"requires":["widget","dd-constrain","substitute"],"skinnable":true},"slider-value-range":{"requires":["slider-base"]},"sortable":{"requires":["dd-delegate","dd-drop-plugin","dd-proxy"]},"sortable-scroll":{"requires":["dd-scroll","sortable"]},"stylesheet":{},"substitute":{"optional":["dump"]},"swf":{"requires":["event-custom","node","swfdetect"]},"swfdetect":{},"tabview":{"requires":["widget","widget-parent","widget-child","tabview-base","node-pluginhost","node-focusmanager"],"skinnable":true},"tabview-base":{"requires":["node-event-delegate","classnamemanager","skin-sam-tabview"]},"tabview-plugin":{"requires":["tabview-base"]},"test":{"requires":["event-simulate","event-custom","substitute","json-stringify"],"skinnable":true},"text":{"use":["text-accentfold","text-wordbreak"]},"text-accentfold":{"requires":["array-extras","text-data-accentfold"]},"text-data-accentfold":{},"text-data-wordbreak":{},"text-wordbreak":{"requires":["array-extras","text-data-wordbreak"]},"transition":{"use":["transition-native","transition-timer"]},"transition-native":{"requires":["node-base"]},"transition-timer":{"requires":["transition-native","node-style"]},"uploader":{"requires":["event-custom","node","base","swf"]},"view":{"requires":["base-build","node-event-delegate"]},"widget":{"skinnable":true,"use":["widget-base","widget-htmlparser","widget-uievents","widget-skin"]},"widget-anim":{"requires":["plugin","anim-base","widget"]},"widget-base":{"requires":["attribute","event-focus","base-base","base-pluginhost","node-base","node-style","classnamemanager"]},"widget-base-ie":{"condition":{"name":"widget-base-ie","trigger":"widget-base","ua":"ie"},"requires":["widget-base"]},"widget-child":{"requires":["base-build","widget"]},"widget-htmlparser":{"requires":["widget-base"]},"widget-locale":{"requires":["widget-base"]},"widget-modality":{"requires":["widget","plugin","gallery-outside-events","base-build"],"skinnable":false},"widget-parent":{"requires":["base-build","arraylist","widget"]},"widget-position":{"requires":["base-build","node-screen","widget"]},"widget-position-align":{"requires":["widget-position"]},"widget-position-constrain":{"requires":["widget-position"]},"widget-skin":{"requires":["widget-base"]},"widget-stack":{"requires":["base-build","widget"],"skinnable":true},"widget-stdmod":{"requires":["base-build","widget"]},"widget-uievents":{"requires":["widget-base","node-event-delegate"]},"yql":{"requires":["jsonp","jsonp-url"]},"yui":{"use":["yui-base","get","features","intl-base","yui-log","yui-later","loader-base","loader-rollup","loader-yui3"]},"yui-base":{},"yui-later":{"requires":["yui-base"]},"yui-log":{"requires":["yui-base"]},"yui-rls":{"use":["yui-base","get","features","intl-base","rls","yui-log","yui-later"]},"yui-throttle":{"requires":["yui-base"]}};YUI.Env[a.version].md5="8deea7d26f0f85ddcacf3aa4da9bfed6";},"@VERSION@",{requires:["loader-base"]});YUI.add("loader",function(a){},"@VERSION@",{use:["loader-base","loader-rollup","loader-yui3"]});
\ No newline at end of file
diff --git a/build/loader/loader-yui3-debug.js b/build/loader/loader-yui3-debug.js
index a1a840b18ce..b176c6426ac 100644
--- a/build/loader/loader-yui3-debug.js
+++ b/build/loader/loader-yui3-debug.js
@@ -68,8 +68,7 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"requires": [
"array-extras",
"base-build",
- "history",
- "json"
+ "history"
]
},
"model": {
@@ -1939,6 +1938,15 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"widget-base"
]
},
+ "widget-modality": {
+ "requires": [
+ "widget",
+ "plugin",
+ "gallery-outside-events",
+ "base-build"
+ ],
+ "skinnable": false
+ },
"yql": {
"requires": [
"jsonp",
@@ -2009,7 +2017,7 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
]
}
};
-YUI.Env[Y.version].md5 = '8cddfeca586b80c7fb7245817b42fa87';
+YUI.Env[Y.version].md5 = '3d2e8dc698d320d37e410b30e4cc20b2';
}, '@VERSION@' ,{requires:['loader-base']});
diff --git a/build/loader/loader-yui3-min.js b/build/loader/loader-yui3-min.js
index 4d4bcfd2f3e..f1f987ffd4e 100644
--- a/build/loader/loader-yui3-min.js
+++ b/build/loader/loader-yui3-min.js
@@ -1,3 +1,3 @@
-YUI.add("loader-yui3",function(a){YUI.Env[a.version].modules=YUI.Env[a.version].modules||{"anim":{"submodules":{"anim-base":{"requires":["base-base","node-style"]},"anim-color":{"requires":["anim-base"]},"anim-curve":{"requires":["anim-xy"]},"anim-easing":{"requires":["anim-base"]},"anim-node-plugin":{"requires":["node-pluginhost","anim-base"]},"anim-scroll":{"requires":["anim-base"]},"anim-xy":{"requires":["anim-base","node-screen"]}},"use":["anim-base","anim-color","anim-curve","anim-easing","anim-node-plugin","anim-scroll","anim-xy"]},"app":{"submodules":{"controller":{"optional":["querystring-parse"],"requires":["array-extras","base-build","history","json"]},"model":{"requires":["base-build","escape","json-parse"]},"model-list":{"requires":["array-extras","array-invoke","arraylist","base-build","json-parse","model"]},"view":{"requires":["base-build","node-event-delegate"]}},"use":["controller","model","model-list","view"]},"arraysort":{"requires":["yui-base"]},"async-queue":{"requires":["event-custom"]},"attribute":{"submodules":{"attribute-base":{"requires":["event-custom"]},"attribute-complex":{"requires":["attribute-base"]}},"use":["attribute-base","attribute-complex"]},"autocomplete":{"submodules":{"autocomplete-base":{"optional":["autocomplete-sources"],"plugins":{"autocomplete-filters":{"path":"autocomplete/autocomplete-filters-min.js","requires":["array-extras","text-wordbreak"]},"autocomplete-filters-accentfold":{"path":"autocomplete/autocomplete-filters-accentfold-min.js","requires":["array-extras","text-accentfold","text-wordbreak"]},"autocomplete-highlighters":{"path":"autocomplete/autocomplete-highlighters-min.js","requires":["array-extras","highlight-base"]},"autocomplete-highlighters-accentfold":{"path":"autocomplete/autocomplete-highlighters-accentfold-min.js","requires":["array-extras","highlight-accentfold"]}},"requires":["array-extras","base-build","escape","event-valuechange","node-base"]},"autocomplete-list":{"after":["autocomplete-sources"],"lang":["en"],"plugins":{"autocomplete-list-keys":{"condition":{"name":"autocomplete-list-keys","test":function(b){return !(b.UA.ios||b.UA.android);},"trigger":"autocomplete-list"},"path":"autocomplete/autocomplete-list-keys-min.js","requires":["autocomplete-list","base-build"]},"autocomplete-plugin":{"path":"autocomplete/autocomplete-plugin-min.js","requires":["autocomplete-list","node-pluginhost"]}},"requires":["autocomplete-base","event-resize","selector-css3","shim-plugin","widget","widget-position","widget-position-align"],"skinnable":true},"autocomplete-sources":{"optional":["io-base","json-parse","jsonp","yql"],"requires":["autocomplete-base"]}},"use":["autocomplete-base","autocomplete-sources","autocomplete-list","autocomplete-plugin"]},"base":{"submodules":{"base-base":{"after":["attribute-complex"],"requires":["attribute-base"]},"base-build":{"requires":["base-base"]},"base-pluginhost":{"requires":["base-base","pluginhost"]}},"use":["base-base","base-pluginhost","base-build"]},"cache":{"submodules":{"cache-base":{"requires":["base"]},"cache-offline":{"requires":["cache-base","json"]},"cache-plugin":{"requires":["plugin","cache-base"]}},"use":["cache-base","cache-offline","cache-plugin"]},"charts":{"requires":["dom","datatype","event-custom","event-mouseenter","widget","widget-position","widget-stack"]},"classnamemanager":{"requires":["yui-base"]},"collection":{"submodules":{"array-extras":{},"array-invoke":{},"arraylist":{},"arraylist-add":{"requires":["arraylist"]},"arraylist-filter":{"requires":["arraylist"]}},"use":["array-extras","arraylist","arraylist-add","arraylist-filter","array-invoke"]},"compat":{"requires":["event-base","dom","dump","substitute"]},"console":{"lang":["en","es"],"plugins":{"console-filters":{"requires":["plugin","console"],"skinnable":true}},"requires":["yui-log","widget","substitute"],"skinnable":true},"cookie":{"requires":["yui-base"]},"cssbase":{"after":["cssreset","cssfonts","cssgrids","cssreset-context","cssfonts-context","cssgrids-context"],"path":"cssbase/base-min.css","type":"css"},"cssbase-context":{"after":["cssreset","cssfonts","cssgrids","cssreset-context","cssfonts-context","cssgrids-context"],"path":"cssbase/base-context-min.css","type":"css"},"cssfonts":{"path":"cssfonts/fonts-min.css","type":"css"},"cssfonts-context":{"path":"cssfonts/fonts-context-min.css","type":"css"},"cssgrids":{"optional":["cssreset","cssfonts"],"path":"cssgrids/grids-min.css","type":"css"},"cssgrids-context-deprecated":{"optional":["cssreset-context"],"path":"cssgrids-deprecated/grids-context-min.css","requires":["cssfonts-context"],"type":"css"},"cssgrids-deprecated":{"optional":["cssreset"],"path":"cssgrids-deprecated/grids-min.css","requires":["cssfonts"],"type":"css"},"cssreset":{"path":"cssreset/reset-min.css","type":"css"},"cssreset-context":{"path":"cssreset/reset-context-min.css","type":"css"},"dataschema":{"submodules":{"dataschema-array":{"requires":["dataschema-base"]},"dataschema-base":{"requires":["base"]},"dataschema-json":{"requires":["dataschema-base","json"]},"dataschema-text":{"requires":["dataschema-base"]},"dataschema-xml":{"requires":["dataschema-base"]}},"use":["dataschema-base","dataschema-json","dataschema-xml","dataschema-array","dataschema-text"]},"datasource":{"submodules":{"datasource-arrayschema":{"requires":["datasource-local","plugin","dataschema-array"]},"datasource-cache":{"requires":["datasource-local","plugin","cache-base"]},"datasource-function":{"requires":["datasource-local"]},"datasource-get":{"requires":["datasource-local","get"]},"datasource-io":{"requires":["datasource-local","io-base"]},"datasource-jsonschema":{"requires":["datasource-local","plugin","dataschema-json"]},"datasource-local":{"requires":["base"]},"datasource-polling":{"requires":["datasource-local"]},"datasource-textschema":{"requires":["datasource-local","plugin","dataschema-text"]},"datasource-xmlschema":{"requires":["datasource-local","plugin","dataschema-xml"]}},"use":["datasource-local","datasource-io","datasource-get","datasource-function","datasource-cache","datasource-jsonschema","datasource-xmlschema","datasource-arrayschema","datasource-textschema","datasource-polling"]},"datatable":{"submodules":{"datatable-base":{"requires":["recordset-base","widget","substitute","event-mouseenter"],"skinnable":true},"datatable-datasource":{"requires":["datatable-base","plugin","datasource-local"]},"datatable-scroll":{"requires":["datatable-base","plugin","stylesheet"]},"datatable-sort":{"lang":["en"],"requires":["datatable-base","plugin","recordset-sort"]}},"use":["datatable-base","datatable-datasource","datatable-sort","datatable-scroll"]},"datatype":{"submodules":{"datatype-date":{"lang":["ar","ar-JO","ca","ca-ES","da","da-DK","de","de-AT","de-DE","el","el-GR","en","en-AU","en-CA","en-GB","en-IE","en-IN","en-JO","en-MY","en-NZ","en-PH","en-SG","en-US","es","es-AR","es-BO","es-CL","es-CO","es-EC","es-ES","es-MX","es-PE","es-PY","es-US","es-UY","es-VE","fi","fi-FI","fr","fr-BE","fr-CA","fr-FR","hi","hi-IN","id","id-ID","it","it-IT","ja","ja-JP","ko","ko-KR","ms","ms-MY","nb","nb-NO","nl","nl-BE","nl-NL","pl","pl-PL","pt","pt-BR","ro","ro-RO","ru","ru-RU","sv","sv-SE","th","th-TH","tr","tr-TR","vi","vi-VN","zh-Hans","zh-Hans-CN","zh-Hant","zh-Hant-HK","zh-Hant-TW"],"submodules":{"datatype-date-format":{"path":"datatype/datatype-date-format-min.js"},"datatype-date-parse":{"path":"datatype/datatype-date-parse-min.js"}},"supersedes":["datatype-date-format"],"use2":["datatype-date-parse","datatype-date-format"]},"datatype-number":{"submodules":{"datatype-number-format":{"path":"datatype/datatype-number-format-min.js"},"datatype-number-parse":{"path":"datatype/datatype-number-parse-min.js"}},"use":["datatype-number-parse","datatype-number-format"]},"datatype-xml":{"submodules":{"datatype-xml-format":{"path":"datatype/datatype-xml-format-min.js"},"datatype-xml-parse":{"path":"datatype/datatype-xml-parse-min.js"}},"use":["datatype-xml-parse","datatype-xml-format"]}},"use":["datatype-number","datatype-date","datatype-xml"]},"dd":{"plugins":{"dd-drop-plugin":{"requires":["dd-drop"]},"dd-gestures":{"condition":{"name":"dd-gestures","test":function(b){return(b.config.win&&("ontouchstart" in b.config.win&&!b.UA.chrome));
-},"trigger":"dd-drag"},"requires":["dd-drag","event-synthetic","event-gestures"]},"dd-plugin":{"optional":["dd-constrain","dd-proxy"],"requires":["dd-drag"]}},"submodules":{"dd-constrain":{"requires":["dd-drag"]},"dd-ddm":{"requires":["dd-ddm-base","event-resize"]},"dd-ddm-base":{"requires":["node","base","yui-throttle","classnamemanager"]},"dd-ddm-drop":{"requires":["dd-ddm"]},"dd-delegate":{"requires":["dd-drag","dd-drop-plugin","event-mouseenter"]},"dd-drag":{"requires":["dd-ddm-base"]},"dd-drop":{"requires":["dd-drag","dd-ddm-drop"]},"dd-proxy":{"requires":["dd-drag"]},"dd-scroll":{"requires":["dd-drag"]}},"use":["dd-ddm-base","dd-ddm","dd-ddm-drop","dd-drag","dd-proxy","dd-constrain","dd-drop","dd-scroll","dd-delegate"]},"dial":{"lang":["en","es"],"requires":["widget","dd-drag","substitute","event-mouseenter","event-move","transition","intl"],"skinnable":true},"dom":{"plugins":{"dom-deprecated":{"requires":["dom-core"]},"dom-style-ie":{"condition":{"name":"dom-style-ie","test":function(h){var f=h.Features.test,g=h.Features.add,d=h.config.win,e=h.config.doc,b="documentElement",c=false;g("style","computedStyle",{test:function(){return d&&"getComputedStyle" in d;}});g("style","opacity",{test:function(){return e&&"opacity" in e[b].style;}});c=(!f("style","opacity")&&!f("style","computedStyle"));return c;},"trigger":"dom-style"},"requires":["dom-style"]},"selector-css2":{"condition":{"name":"selector-css2","test":function(d){var c=d.config.doc,b=c&&!("querySelectorAll" in c);return b;},"trigger":"selector"},"requires":["selector-native"]},"selector-css3":{"requires":["selector-native","selector-css2"]}},"submodules":{"dom-attrs":{"requires":["dom-core"]},"dom-base":{"requires":["dom-core","dom-attrs","dom-create","dom-class","dom-size"]},"dom-class":{"requires":["dom-core"]},"dom-core":{"requires":["oop","features"]},"dom-create":{"requires":["dom-core"]},"dom-screen":{"requires":["dom-core","dom-style"]},"dom-size":{"requires":["dom-core"]},"dom-style":{"requires":["dom-core"]},"selector":{"requires":["selector-native"]},"selector-native":{"requires":["dom-core"]}},"use":["dom-core","dom-base","dom-attrs","dom-create","dom-class","dom-size","dom-screen","dom-style","selector-native","selector"]},"dump":{},"editor":{"submodules":{"createlink-base":{"requires":["editor-base"]},"editor-base":{"requires":["base","frame","node","exec-command","selection"]},"editor-bidi":{"requires":["editor-base"]},"editor-br":{"requires":["editor-base"]},"editor-lists":{"requires":["editor-base"]},"editor-para":{"requires":["editor-base"]},"editor-tab":{"requires":["editor-base"]},"exec-command":{"requires":["frame"]},"frame":{"requires":["base","node","selector-css3","substitute","yui-throttle"]},"selection":{"requires":["node"]}},"use":["frame","selection","exec-command","editor-base","editor-para","editor-br","editor-bidi","editor-tab","createlink-base"]},"escape":{},"event":{"after":["node-base"],"plugins":{"event-base-ie":{"after":["event-base"],"condition":{"name":"event-base-ie","test":function(c){var b=c.config.doc&&c.config.doc.implementation;return(b&&(!b.hasFeature("Events","2.0")));},"trigger":"node-base"},"requires":["node-base"]},"event-touch":{"requires":["node-base"]}},"submodules":{"event-base":{"after":["node-base"],"requires":["event-custom-base"]},"event-delegate":{"requires":["node-base"]},"event-focus":{"requires":["event-synthetic"]},"event-hover":{"requires":["event-mouseenter"]},"event-key":{"requires":["event-synthetic"]},"event-mouseenter":{"requires":["event-synthetic"]},"event-mousewheel":{"requires":["node-base"]},"event-resize":{"requires":["node-base"]},"event-synthetic":{"requires":["node-base","event-custom-complex"]}},"use":["event-base","event-delegate","event-synthetic","event-mousewheel","event-mouseenter","event-key","event-focus","event-resize","event-hover"]},"event-custom":{"submodules":{"event-custom-base":{"requires":["oop"]},"event-custom-complex":{"requires":["event-custom-base"]}},"use":["event-custom-base","event-custom-complex"]},"event-gestures":{"submodules":{"event-flick":{"requires":["node-base","event-touch","event-synthetic"]},"event-move":{"requires":["node-base","event-touch","event-synthetic"]}},"use":["event-flick","event-move"]},"event-simulate":{"requires":["event-base"]},"event-valuechange":{"requires":["event-focus","event-synthetic"]},"highlight":{"submodules":{"highlight-accentfold":{"requires":["highlight-base","text-accentfold"]},"highlight-base":{"requires":["array-extras","escape","text-wordbreak"]}},"use":["highlight-base","highlight-accentfold"]},"history":{"plugins":{"history-hash-ie":{"condition":{"name":"history-hash-ie","test":function(c){var b=c.config.doc&&c.config.doc.documentMode;return c.UA.ie&&(!("onhashchange" in c.config.win)||!b||b<8);},"trigger":"history-hash"},"requires":["history-hash","node-base"]}},"submodules":{"history-base":{"requires":["event-custom-complex"]},"history-hash":{"after":["history-html5"],"requires":["event-synthetic","history-base","yui-later"]},"history-html5":{"optional":["json"],"requires":["event-base","history-base","node-base"]}},"use":["history-base","history-hash","history-hash-ie","history-html5"]},"imageloader":{"requires":["base-base","node-style","node-screen"]},"intl":{"requires":["intl-base","event-custom"]},"io":{"submodules":{"io-base":{"requires":["event-custom-base","querystring-stringify-simple"]},"io-form":{"requires":["io-base","node-base"]},"io-queue":{"requires":["io-base","queue-promote"]},"io-upload-iframe":{"requires":["io-base","node-base"]},"io-xdr":{"requires":["io-base","datatype-xml"]}},"use":["io-base","io-xdr","io-form","io-upload-iframe","io-queue"]},"json":{"submodules":{"json-parse":{},"json-stringify":{}},"use":["json-parse","json-stringify"]},"jsonp":{"plugins":{"jsonp-url":{"requires":["jsonp"]}},"requires":["get","oop"]},"loader":{"submodules":{"loader-base":{"requires":["get"]},"loader-rollup":{"requires":["loader-base"]},"loader-yui3":{"requires":["loader-base"]}},"use":["loader-base","loader-rollup","loader-yui3"]},"node":{"plugins":{"align-plugin":{"requires":["node-screen","node-pluginhost"]},"node-deprecated":{"requires":["node-base"]},"node-event-simulate":{"requires":["node-base","event-simulate"]},"node-load":{"requires":["node-base","io-base"]},"shim-plugin":{"requires":["node-style","node-pluginhost"]}},"submodules":{"node-base":{"requires":["dom-base","selector-css2","event-base"]},"node-event-delegate":{"requires":["node-base","event-delegate"]},"node-pluginhost":{"requires":["node-base","pluginhost"]},"node-screen":{"requires":["dom-screen","node-base"]},"node-style":{"requires":["dom-style","node-base"]}},"use":["node-base","node-event-delegate","node-pluginhost","node-screen","node-style"]},"node-flick":{"requires":["classnamemanager","transition","event-flick","plugin"],"skinnable":true},"node-focusmanager":{"requires":["attribute","node","plugin","node-event-simulate","event-key","event-focus"]},"node-menunav":{"requires":["node","classnamemanager","plugin","node-focusmanager"],"skinnable":true},"oop":{"requires":["yui-base"]},"overlay":{"requires":["widget","widget-stdmod","widget-position","widget-position-align","widget-stack","widget-position-constrain"],"skinnable":true},"plugin":{"plugins":{"pluginattr":{"path":"plugin/pluginattr-min.js","requires":["plugin"]}},"requires":["base-base"]},"pluginhost":{"submodules":{"pluginhost-base":{"requires":["yui-base"]},"pluginhost-config":{"requires":["pluginhost-base"]}},"use":["pluginhost-base","pluginhost-config"]},"profiler":{"requires":["yui-base"]},"querystring":{"submodules":{"querystring-parse":{"requires":["yui-base","array-extras"]},"querystring-stringify":{"requires":["yui-base"]}},"use":["querystring-parse","querystring-stringify"]},"querystring-parse-simple":{"path":"querystring/querystring-parse-simple-min.js","requires":["yui-base"]},"querystring-stringify-simple":{"path":"querystring/querystring-stringify-simple-min.js","requires":["yui-base"]},"queue-promote":{"requires":["yui-base"]},"recordset":{"submodules":{"recordset-base":{"requires":["base","arraylist"]},"recordset-filter":{"requires":["recordset-base","array-extras","plugin"]},"recordset-indexer":{"requires":["recordset-base","plugin"]},"recordset-sort":{"requires":["arraysort","recordset-base","plugin"]}},"use":["recordset-base","recordset-sort","recordset-filter","recordset-indexer"]},"resize":{"plugins":{"resize-plugin":{"optional":["resize-constrain"],"requires":["resize-base","plugin"]}},"submodules":{"resize-base":{"requires":["base","widget","substitute","event","oop","dd-drag","dd-delegate","dd-drop"],"skinnable":true},"resize-constrain":{"requires":["plugin","resize-base"]},"resize-proxy":{"requires":["plugin","resize-base"]}},"use":["resize-base","resize-proxy","resize-constrain"]},"scrollview":{"plugins":{"scrollview-base":{"path":"scrollview/scrollview-base-min.js","requires":["widget","event-gestures","transition"],"skinnable":true},"scrollview-base-ie":{"condition":{"name":"scrollview-base-ie","trigger":"scrollview-base","ua":"ie"},"requires":["scrollview-base"]},"scrollview-paginator":{"path":"scrollview/scrollview-paginator-min.js","requires":["plugin"]},"scrollview-scrollbars":{"path":"scrollview/scrollview-scrollbars-min.js","requires":["plugin"],"skinnable":true}},"requires":["scrollview-base","scrollview-scrollbars"]},"slider":{"submodules":{"clickable-rail":{"requires":["slider-base"]},"range-slider":{"requires":["slider-base","slider-value-range","clickable-rail"]},"slider-base":{"requires":["widget","dd-constrain","substitute"],"skinnable":true},"slider-value-range":{"requires":["slider-base"]}},"use":["slider-base","slider-value-range","clickable-rail","range-slider"]},"sortable":{"plugins":{"sortable-scroll":{"requires":["dd-scroll","sortable"]}},"requires":["dd-delegate","dd-drop-plugin","dd-proxy"]},"stylesheet":{},"substitute":{"optional":["dump"]},"swf":{"requires":["event-custom","node","swfdetect"]},"swfdetect":{},"tabview":{"plugins":{"tabview-base":{"requires":["node-event-delegate","classnamemanager","skin-sam-tabview"]},"tabview-plugin":{"requires":["tabview-base"]}},"requires":["widget","widget-parent","widget-child","tabview-base","node-pluginhost","node-focusmanager"],"skinnable":true},"test":{"requires":["event-simulate","event-custom","substitute","json-stringify"],"skinnable":true},"text":{"submodules":{"text-accentfold":{"requires":["array-extras","text-data-accentfold"]},"text-data-accentfold":{},"text-data-wordbreak":{},"text-wordbreak":{"requires":["array-extras","text-data-wordbreak"]}},"use":["text-accentfold","text-wordbreak"]},"transition":{"submodules":{"transition-native":{"requires":["node-base"]},"transition-timer":{"requires":["transition-native","node-style"]}},"use":["transition-native","transition-timer"]},"uploader":{"requires":["event-custom","node","base","swf"]},"widget":{"plugins":{"widget-base-ie":{"condition":{"name":"widget-base-ie","trigger":"widget-base","ua":"ie"},"requires":["widget-base"]},"widget-child":{"requires":["base-build","widget"]},"widget-parent":{"requires":["base-build","arraylist","widget"]},"widget-position":{"requires":["base-build","node-screen","widget"]},"widget-position-align":{"requires":["widget-position"]},"widget-position-constrain":{"requires":["widget-position"]},"widget-stack":{"requires":["base-build","widget"],"skinnable":true},"widget-stdmod":{"requires":["base-build","widget"]}},"skinnable":true,"submodules":{"widget-base":{"requires":["attribute","event-focus","base-base","base-pluginhost","node-base","node-style","classnamemanager"]},"widget-htmlparser":{"requires":["widget-base"]},"widget-skin":{"requires":["widget-base"]},"widget-uievents":{"requires":["widget-base","node-event-delegate"]}},"use":["widget-base","widget-htmlparser","widget-uievents","widget-skin"]},"widget-anim":{"requires":["plugin","anim-base","widget"]},"widget-locale":{"path":"widget/widget-locale-min.js","requires":["widget-base"]},"yql":{"requires":["jsonp","jsonp-url"]},"yui":{"submodules":{"features":{"requires":["yui-base"]},"get":{"requires":["yui-base"]},"intl-base":{"requires":["yui-base"]},"rls":{"requires":["get","features"]},"yui-base":{},"yui-later":{"requires":["yui-base"]},"yui-log":{"requires":["yui-base"]},"yui-rls":{"use":["yui-base","get","features","intl-base","rls","yui-log","yui-later"]}},"use":["yui-base","get","features","intl-base","yui-log","yui-later","loader-base","loader-rollup","loader-yui3"]},"yui-throttle":{"requires":["yui-base"]}};
-YUI.Env[a.version].md5="8cddfeca586b80c7fb7245817b42fa87";},"@VERSION@",{requires:["loader-base"]});
\ No newline at end of file
+YUI.add("loader-yui3",function(a){YUI.Env[a.version].modules=YUI.Env[a.version].modules||{"anim":{"submodules":{"anim-base":{"requires":["base-base","node-style"]},"anim-color":{"requires":["anim-base"]},"anim-curve":{"requires":["anim-xy"]},"anim-easing":{"requires":["anim-base"]},"anim-node-plugin":{"requires":["node-pluginhost","anim-base"]},"anim-scroll":{"requires":["anim-base"]},"anim-xy":{"requires":["anim-base","node-screen"]}},"use":["anim-base","anim-color","anim-curve","anim-easing","anim-node-plugin","anim-scroll","anim-xy"]},"app":{"submodules":{"controller":{"optional":["querystring-parse"],"requires":["array-extras","base-build","history"]},"model":{"requires":["base-build","escape","json-parse"]},"model-list":{"requires":["array-extras","array-invoke","arraylist","base-build","json-parse","model"]},"view":{"requires":["base-build","node-event-delegate"]}},"use":["controller","model","model-list","view"]},"arraysort":{"requires":["yui-base"]},"async-queue":{"requires":["event-custom"]},"attribute":{"submodules":{"attribute-base":{"requires":["event-custom"]},"attribute-complex":{"requires":["attribute-base"]}},"use":["attribute-base","attribute-complex"]},"autocomplete":{"submodules":{"autocomplete-base":{"optional":["autocomplete-sources"],"plugins":{"autocomplete-filters":{"path":"autocomplete/autocomplete-filters-min.js","requires":["array-extras","text-wordbreak"]},"autocomplete-filters-accentfold":{"path":"autocomplete/autocomplete-filters-accentfold-min.js","requires":["array-extras","text-accentfold","text-wordbreak"]},"autocomplete-highlighters":{"path":"autocomplete/autocomplete-highlighters-min.js","requires":["array-extras","highlight-base"]},"autocomplete-highlighters-accentfold":{"path":"autocomplete/autocomplete-highlighters-accentfold-min.js","requires":["array-extras","highlight-accentfold"]}},"requires":["array-extras","base-build","escape","event-valuechange","node-base"]},"autocomplete-list":{"after":["autocomplete-sources"],"lang":["en"],"plugins":{"autocomplete-list-keys":{"condition":{"name":"autocomplete-list-keys","test":function(b){return !(b.UA.ios||b.UA.android);},"trigger":"autocomplete-list"},"path":"autocomplete/autocomplete-list-keys-min.js","requires":["autocomplete-list","base-build"]},"autocomplete-plugin":{"path":"autocomplete/autocomplete-plugin-min.js","requires":["autocomplete-list","node-pluginhost"]}},"requires":["autocomplete-base","event-resize","selector-css3","shim-plugin","widget","widget-position","widget-position-align"],"skinnable":true},"autocomplete-sources":{"optional":["io-base","json-parse","jsonp","yql"],"requires":["autocomplete-base"]}},"use":["autocomplete-base","autocomplete-sources","autocomplete-list","autocomplete-plugin"]},"base":{"submodules":{"base-base":{"after":["attribute-complex"],"requires":["attribute-base"]},"base-build":{"requires":["base-base"]},"base-pluginhost":{"requires":["base-base","pluginhost"]}},"use":["base-base","base-pluginhost","base-build"]},"cache":{"submodules":{"cache-base":{"requires":["base"]},"cache-offline":{"requires":["cache-base","json"]},"cache-plugin":{"requires":["plugin","cache-base"]}},"use":["cache-base","cache-offline","cache-plugin"]},"charts":{"requires":["dom","datatype","event-custom","event-mouseenter","widget","widget-position","widget-stack"]},"classnamemanager":{"requires":["yui-base"]},"collection":{"submodules":{"array-extras":{},"array-invoke":{},"arraylist":{},"arraylist-add":{"requires":["arraylist"]},"arraylist-filter":{"requires":["arraylist"]}},"use":["array-extras","arraylist","arraylist-add","arraylist-filter","array-invoke"]},"compat":{"requires":["event-base","dom","dump","substitute"]},"console":{"lang":["en","es"],"plugins":{"console-filters":{"requires":["plugin","console"],"skinnable":true}},"requires":["yui-log","widget","substitute"],"skinnable":true},"cookie":{"requires":["yui-base"]},"cssbase":{"after":["cssreset","cssfonts","cssgrids","cssreset-context","cssfonts-context","cssgrids-context"],"path":"cssbase/base-min.css","type":"css"},"cssbase-context":{"after":["cssreset","cssfonts","cssgrids","cssreset-context","cssfonts-context","cssgrids-context"],"path":"cssbase/base-context-min.css","type":"css"},"cssfonts":{"path":"cssfonts/fonts-min.css","type":"css"},"cssfonts-context":{"path":"cssfonts/fonts-context-min.css","type":"css"},"cssgrids":{"optional":["cssreset","cssfonts"],"path":"cssgrids/grids-min.css","type":"css"},"cssgrids-context-deprecated":{"optional":["cssreset-context"],"path":"cssgrids-deprecated/grids-context-min.css","requires":["cssfonts-context"],"type":"css"},"cssgrids-deprecated":{"optional":["cssreset"],"path":"cssgrids-deprecated/grids-min.css","requires":["cssfonts"],"type":"css"},"cssreset":{"path":"cssreset/reset-min.css","type":"css"},"cssreset-context":{"path":"cssreset/reset-context-min.css","type":"css"},"dataschema":{"submodules":{"dataschema-array":{"requires":["dataschema-base"]},"dataschema-base":{"requires":["base"]},"dataschema-json":{"requires":["dataschema-base","json"]},"dataschema-text":{"requires":["dataschema-base"]},"dataschema-xml":{"requires":["dataschema-base"]}},"use":["dataschema-base","dataschema-json","dataschema-xml","dataschema-array","dataschema-text"]},"datasource":{"submodules":{"datasource-arrayschema":{"requires":["datasource-local","plugin","dataschema-array"]},"datasource-cache":{"requires":["datasource-local","plugin","cache-base"]},"datasource-function":{"requires":["datasource-local"]},"datasource-get":{"requires":["datasource-local","get"]},"datasource-io":{"requires":["datasource-local","io-base"]},"datasource-jsonschema":{"requires":["datasource-local","plugin","dataschema-json"]},"datasource-local":{"requires":["base"]},"datasource-polling":{"requires":["datasource-local"]},"datasource-textschema":{"requires":["datasource-local","plugin","dataschema-text"]},"datasource-xmlschema":{"requires":["datasource-local","plugin","dataschema-xml"]}},"use":["datasource-local","datasource-io","datasource-get","datasource-function","datasource-cache","datasource-jsonschema","datasource-xmlschema","datasource-arrayschema","datasource-textschema","datasource-polling"]},"datatable":{"submodules":{"datatable-base":{"requires":["recordset-base","widget","substitute","event-mouseenter"],"skinnable":true},"datatable-datasource":{"requires":["datatable-base","plugin","datasource-local"]},"datatable-scroll":{"requires":["datatable-base","plugin","stylesheet"]},"datatable-sort":{"lang":["en"],"requires":["datatable-base","plugin","recordset-sort"]}},"use":["datatable-base","datatable-datasource","datatable-sort","datatable-scroll"]},"datatype":{"submodules":{"datatype-date":{"lang":["ar","ar-JO","ca","ca-ES","da","da-DK","de","de-AT","de-DE","el","el-GR","en","en-AU","en-CA","en-GB","en-IE","en-IN","en-JO","en-MY","en-NZ","en-PH","en-SG","en-US","es","es-AR","es-BO","es-CL","es-CO","es-EC","es-ES","es-MX","es-PE","es-PY","es-US","es-UY","es-VE","fi","fi-FI","fr","fr-BE","fr-CA","fr-FR","hi","hi-IN","id","id-ID","it","it-IT","ja","ja-JP","ko","ko-KR","ms","ms-MY","nb","nb-NO","nl","nl-BE","nl-NL","pl","pl-PL","pt","pt-BR","ro","ro-RO","ru","ru-RU","sv","sv-SE","th","th-TH","tr","tr-TR","vi","vi-VN","zh-Hans","zh-Hans-CN","zh-Hant","zh-Hant-HK","zh-Hant-TW"],"submodules":{"datatype-date-format":{"path":"datatype/datatype-date-format-min.js"},"datatype-date-parse":{"path":"datatype/datatype-date-parse-min.js"}},"supersedes":["datatype-date-format"],"use2":["datatype-date-parse","datatype-date-format"]},"datatype-number":{"submodules":{"datatype-number-format":{"path":"datatype/datatype-number-format-min.js"},"datatype-number-parse":{"path":"datatype/datatype-number-parse-min.js"}},"use":["datatype-number-parse","datatype-number-format"]},"datatype-xml":{"submodules":{"datatype-xml-format":{"path":"datatype/datatype-xml-format-min.js"},"datatype-xml-parse":{"path":"datatype/datatype-xml-parse-min.js"}},"use":["datatype-xml-parse","datatype-xml-format"]}},"use":["datatype-number","datatype-date","datatype-xml"]},"dd":{"plugins":{"dd-drop-plugin":{"requires":["dd-drop"]},"dd-gestures":{"condition":{"name":"dd-gestures","test":function(b){return(b.config.win&&("ontouchstart" in b.config.win&&!b.UA.chrome));
+},"trigger":"dd-drag"},"requires":["dd-drag","event-synthetic","event-gestures"]},"dd-plugin":{"optional":["dd-constrain","dd-proxy"],"requires":["dd-drag"]}},"submodules":{"dd-constrain":{"requires":["dd-drag"]},"dd-ddm":{"requires":["dd-ddm-base","event-resize"]},"dd-ddm-base":{"requires":["node","base","yui-throttle","classnamemanager"]},"dd-ddm-drop":{"requires":["dd-ddm"]},"dd-delegate":{"requires":["dd-drag","dd-drop-plugin","event-mouseenter"]},"dd-drag":{"requires":["dd-ddm-base"]},"dd-drop":{"requires":["dd-drag","dd-ddm-drop"]},"dd-proxy":{"requires":["dd-drag"]},"dd-scroll":{"requires":["dd-drag"]}},"use":["dd-ddm-base","dd-ddm","dd-ddm-drop","dd-drag","dd-proxy","dd-constrain","dd-drop","dd-scroll","dd-delegate"]},"dial":{"lang":["en","es"],"requires":["widget","dd-drag","substitute","event-mouseenter","event-move","transition","intl"],"skinnable":true},"dom":{"plugins":{"dom-deprecated":{"requires":["dom-core"]},"dom-style-ie":{"condition":{"name":"dom-style-ie","test":function(h){var f=h.Features.test,g=h.Features.add,d=h.config.win,e=h.config.doc,b="documentElement",c=false;g("style","computedStyle",{test:function(){return d&&"getComputedStyle" in d;}});g("style","opacity",{test:function(){return e&&"opacity" in e[b].style;}});c=(!f("style","opacity")&&!f("style","computedStyle"));return c;},"trigger":"dom-style"},"requires":["dom-style"]},"selector-css2":{"condition":{"name":"selector-css2","test":function(d){var c=d.config.doc,b=c&&!("querySelectorAll" in c);return b;},"trigger":"selector"},"requires":["selector-native"]},"selector-css3":{"requires":["selector-native","selector-css2"]}},"submodules":{"dom-attrs":{"requires":["dom-core"]},"dom-base":{"requires":["dom-core","dom-attrs","dom-create","dom-class","dom-size"]},"dom-class":{"requires":["dom-core"]},"dom-core":{"requires":["oop","features"]},"dom-create":{"requires":["dom-core"]},"dom-screen":{"requires":["dom-core","dom-style"]},"dom-size":{"requires":["dom-core"]},"dom-style":{"requires":["dom-core"]},"selector":{"requires":["selector-native"]},"selector-native":{"requires":["dom-core"]}},"use":["dom-core","dom-base","dom-attrs","dom-create","dom-class","dom-size","dom-screen","dom-style","selector-native","selector"]},"dump":{},"editor":{"submodules":{"createlink-base":{"requires":["editor-base"]},"editor-base":{"requires":["base","frame","node","exec-command","selection"]},"editor-bidi":{"requires":["editor-base"]},"editor-br":{"requires":["editor-base"]},"editor-lists":{"requires":["editor-base"]},"editor-para":{"requires":["editor-base"]},"editor-tab":{"requires":["editor-base"]},"exec-command":{"requires":["frame"]},"frame":{"requires":["base","node","selector-css3","substitute","yui-throttle"]},"selection":{"requires":["node"]}},"use":["frame","selection","exec-command","editor-base","editor-para","editor-br","editor-bidi","editor-tab","createlink-base"]},"escape":{},"event":{"after":["node-base"],"plugins":{"event-base-ie":{"after":["event-base"],"condition":{"name":"event-base-ie","test":function(c){var b=c.config.doc&&c.config.doc.implementation;return(b&&(!b.hasFeature("Events","2.0")));},"trigger":"node-base"},"requires":["node-base"]},"event-touch":{"requires":["node-base"]}},"submodules":{"event-base":{"after":["node-base"],"requires":["event-custom-base"]},"event-delegate":{"requires":["node-base"]},"event-focus":{"requires":["event-synthetic"]},"event-hover":{"requires":["event-mouseenter"]},"event-key":{"requires":["event-synthetic"]},"event-mouseenter":{"requires":["event-synthetic"]},"event-mousewheel":{"requires":["node-base"]},"event-resize":{"requires":["node-base"]},"event-synthetic":{"requires":["node-base","event-custom-complex"]}},"use":["event-base","event-delegate","event-synthetic","event-mousewheel","event-mouseenter","event-key","event-focus","event-resize","event-hover"]},"event-custom":{"submodules":{"event-custom-base":{"requires":["oop"]},"event-custom-complex":{"requires":["event-custom-base"]}},"use":["event-custom-base","event-custom-complex"]},"event-gestures":{"submodules":{"event-flick":{"requires":["node-base","event-touch","event-synthetic"]},"event-move":{"requires":["node-base","event-touch","event-synthetic"]}},"use":["event-flick","event-move"]},"event-simulate":{"requires":["event-base"]},"event-valuechange":{"requires":["event-focus","event-synthetic"]},"highlight":{"submodules":{"highlight-accentfold":{"requires":["highlight-base","text-accentfold"]},"highlight-base":{"requires":["array-extras","escape","text-wordbreak"]}},"use":["highlight-base","highlight-accentfold"]},"history":{"plugins":{"history-hash-ie":{"condition":{"name":"history-hash-ie","test":function(c){var b=c.config.doc&&c.config.doc.documentMode;return c.UA.ie&&(!("onhashchange" in c.config.win)||!b||b<8);},"trigger":"history-hash"},"requires":["history-hash","node-base"]}},"submodules":{"history-base":{"requires":["event-custom-complex"]},"history-hash":{"after":["history-html5"],"requires":["event-synthetic","history-base","yui-later"]},"history-html5":{"optional":["json"],"requires":["event-base","history-base","node-base"]}},"use":["history-base","history-hash","history-hash-ie","history-html5"]},"imageloader":{"requires":["base-base","node-style","node-screen"]},"intl":{"requires":["intl-base","event-custom"]},"io":{"submodules":{"io-base":{"requires":["event-custom-base","querystring-stringify-simple"]},"io-form":{"requires":["io-base","node-base"]},"io-queue":{"requires":["io-base","queue-promote"]},"io-upload-iframe":{"requires":["io-base","node-base"]},"io-xdr":{"requires":["io-base","datatype-xml"]}},"use":["io-base","io-xdr","io-form","io-upload-iframe","io-queue"]},"json":{"submodules":{"json-parse":{},"json-stringify":{}},"use":["json-parse","json-stringify"]},"jsonp":{"plugins":{"jsonp-url":{"requires":["jsonp"]}},"requires":["get","oop"]},"loader":{"submodules":{"loader-base":{"requires":["get"]},"loader-rollup":{"requires":["loader-base"]},"loader-yui3":{"requires":["loader-base"]}},"use":["loader-base","loader-rollup","loader-yui3"]},"node":{"plugins":{"align-plugin":{"requires":["node-screen","node-pluginhost"]},"node-deprecated":{"requires":["node-base"]},"node-event-simulate":{"requires":["node-base","event-simulate"]},"node-load":{"requires":["node-base","io-base"]},"shim-plugin":{"requires":["node-style","node-pluginhost"]}},"submodules":{"node-base":{"requires":["dom-base","selector-css2","event-base"]},"node-event-delegate":{"requires":["node-base","event-delegate"]},"node-pluginhost":{"requires":["node-base","pluginhost"]},"node-screen":{"requires":["dom-screen","node-base"]},"node-style":{"requires":["dom-style","node-base"]}},"use":["node-base","node-event-delegate","node-pluginhost","node-screen","node-style"]},"node-flick":{"requires":["classnamemanager","transition","event-flick","plugin"],"skinnable":true},"node-focusmanager":{"requires":["attribute","node","plugin","node-event-simulate","event-key","event-focus"]},"node-menunav":{"requires":["node","classnamemanager","plugin","node-focusmanager"],"skinnable":true},"oop":{"requires":["yui-base"]},"overlay":{"requires":["widget","widget-stdmod","widget-position","widget-position-align","widget-stack","widget-position-constrain"],"skinnable":true},"plugin":{"plugins":{"pluginattr":{"path":"plugin/pluginattr-min.js","requires":["plugin"]}},"requires":["base-base"]},"pluginhost":{"submodules":{"pluginhost-base":{"requires":["yui-base"]},"pluginhost-config":{"requires":["pluginhost-base"]}},"use":["pluginhost-base","pluginhost-config"]},"profiler":{"requires":["yui-base"]},"querystring":{"submodules":{"querystring-parse":{"requires":["yui-base","array-extras"]},"querystring-stringify":{"requires":["yui-base"]}},"use":["querystring-parse","querystring-stringify"]},"querystring-parse-simple":{"path":"querystring/querystring-parse-simple-min.js","requires":["yui-base"]},"querystring-stringify-simple":{"path":"querystring/querystring-stringify-simple-min.js","requires":["yui-base"]},"queue-promote":{"requires":["yui-base"]},"recordset":{"submodules":{"recordset-base":{"requires":["base","arraylist"]},"recordset-filter":{"requires":["recordset-base","array-extras","plugin"]},"recordset-indexer":{"requires":["recordset-base","plugin"]},"recordset-sort":{"requires":["arraysort","recordset-base","plugin"]}},"use":["recordset-base","recordset-sort","recordset-filter","recordset-indexer"]},"resize":{"plugins":{"resize-plugin":{"optional":["resize-constrain"],"requires":["resize-base","plugin"]}},"submodules":{"resize-base":{"requires":["base","widget","substitute","event","oop","dd-drag","dd-delegate","dd-drop"],"skinnable":true},"resize-constrain":{"requires":["plugin","resize-base"]},"resize-proxy":{"requires":["plugin","resize-base"]}},"use":["resize-base","resize-proxy","resize-constrain"]},"scrollview":{"plugins":{"scrollview-base":{"path":"scrollview/scrollview-base-min.js","requires":["widget","event-gestures","transition"],"skinnable":true},"scrollview-base-ie":{"condition":{"name":"scrollview-base-ie","trigger":"scrollview-base","ua":"ie"},"requires":["scrollview-base"]},"scrollview-paginator":{"path":"scrollview/scrollview-paginator-min.js","requires":["plugin"]},"scrollview-scrollbars":{"path":"scrollview/scrollview-scrollbars-min.js","requires":["plugin"],"skinnable":true}},"requires":["scrollview-base","scrollview-scrollbars"]},"slider":{"submodules":{"clickable-rail":{"requires":["slider-base"]},"range-slider":{"requires":["slider-base","slider-value-range","clickable-rail"]},"slider-base":{"requires":["widget","dd-constrain","substitute"],"skinnable":true},"slider-value-range":{"requires":["slider-base"]}},"use":["slider-base","slider-value-range","clickable-rail","range-slider"]},"sortable":{"plugins":{"sortable-scroll":{"requires":["dd-scroll","sortable"]}},"requires":["dd-delegate","dd-drop-plugin","dd-proxy"]},"stylesheet":{},"substitute":{"optional":["dump"]},"swf":{"requires":["event-custom","node","swfdetect"]},"swfdetect":{},"tabview":{"plugins":{"tabview-base":{"requires":["node-event-delegate","classnamemanager","skin-sam-tabview"]},"tabview-plugin":{"requires":["tabview-base"]}},"requires":["widget","widget-parent","widget-child","tabview-base","node-pluginhost","node-focusmanager"],"skinnable":true},"test":{"requires":["event-simulate","event-custom","substitute","json-stringify"],"skinnable":true},"text":{"submodules":{"text-accentfold":{"requires":["array-extras","text-data-accentfold"]},"text-data-accentfold":{},"text-data-wordbreak":{},"text-wordbreak":{"requires":["array-extras","text-data-wordbreak"]}},"use":["text-accentfold","text-wordbreak"]},"transition":{"submodules":{"transition-native":{"requires":["node-base"]},"transition-timer":{"requires":["transition-native","node-style"]}},"use":["transition-native","transition-timer"]},"uploader":{"requires":["event-custom","node","base","swf"]},"widget":{"plugins":{"widget-base-ie":{"condition":{"name":"widget-base-ie","trigger":"widget-base","ua":"ie"},"requires":["widget-base"]},"widget-child":{"requires":["base-build","widget"]},"widget-parent":{"requires":["base-build","arraylist","widget"]},"widget-position":{"requires":["base-build","node-screen","widget"]},"widget-position-align":{"requires":["widget-position"]},"widget-position-constrain":{"requires":["widget-position"]},"widget-stack":{"requires":["base-build","widget"],"skinnable":true},"widget-stdmod":{"requires":["base-build","widget"]}},"skinnable":true,"submodules":{"widget-base":{"requires":["attribute","event-focus","base-base","base-pluginhost","node-base","node-style","classnamemanager"]},"widget-htmlparser":{"requires":["widget-base"]},"widget-skin":{"requires":["widget-base"]},"widget-uievents":{"requires":["widget-base","node-event-delegate"]}},"use":["widget-base","widget-htmlparser","widget-uievents","widget-skin"]},"widget-anim":{"requires":["plugin","anim-base","widget"]},"widget-locale":{"path":"widget/widget-locale-min.js","requires":["widget-base"]},"widget-modality":{"requires":["widget","plugin","gallery-outside-events","base-build"],"skinnable":false},"yql":{"requires":["jsonp","jsonp-url"]},"yui":{"submodules":{"features":{"requires":["yui-base"]},"get":{"requires":["yui-base"]},"intl-base":{"requires":["yui-base"]},"rls":{"requires":["get","features"]},"yui-base":{},"yui-later":{"requires":["yui-base"]},"yui-log":{"requires":["yui-base"]},"yui-rls":{"use":["yui-base","get","features","intl-base","rls","yui-log","yui-later"]}},"use":["yui-base","get","features","intl-base","yui-log","yui-later","loader-base","loader-rollup","loader-yui3"]},"yui-throttle":{"requires":["yui-base"]}};
+YUI.Env[a.version].md5="3d2e8dc698d320d37e410b30e4cc20b2";},"@VERSION@",{requires:["loader-base"]});
\ No newline at end of file
diff --git a/build/loader/loader-yui3.js b/build/loader/loader-yui3.js
index a1a840b18ce..b176c6426ac 100644
--- a/build/loader/loader-yui3.js
+++ b/build/loader/loader-yui3.js
@@ -68,8 +68,7 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"requires": [
"array-extras",
"base-build",
- "history",
- "json"
+ "history"
]
},
"model": {
@@ -1939,6 +1938,15 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"widget-base"
]
},
+ "widget-modality": {
+ "requires": [
+ "widget",
+ "plugin",
+ "gallery-outside-events",
+ "base-build"
+ ],
+ "skinnable": false
+ },
"yql": {
"requires": [
"jsonp",
@@ -2009,7 +2017,7 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
]
}
};
-YUI.Env[Y.version].md5 = '8cddfeca586b80c7fb7245817b42fa87';
+YUI.Env[Y.version].md5 = '3d2e8dc698d320d37e410b30e4cc20b2';
}, '@VERSION@' ,{requires:['loader-base']});
diff --git a/build/loader/loader.js b/build/loader/loader.js
index 4b21593a4e4..c7a59b141df 100644
--- a/build/loader/loader.js
+++ b/build/loader/loader.js
@@ -2663,8 +2663,7 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"requires": [
"array-extras",
"base-build",
- "history",
- "json"
+ "history"
]
},
"cookie": {
@@ -3885,6 +3884,8 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
},
"scrollview-scrollbars": {
"requires": [
+ "classnamemanager",
+ "transition",
"plugin"
],
"skinnable": true
@@ -4115,6 +4116,15 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"widget-base"
]
},
+ "widget-modality": {
+ "requires": [
+ "widget",
+ "plugin",
+ "gallery-outside-events",
+ "base-build"
+ ],
+ "skinnable": false
+ },
"widget-parent": {
"requires": [
"base-build",
@@ -4210,7 +4220,7 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
]
}
};
-YUI.Env[Y.version].md5 = 'cfd89af2919db3983caf2874fc3a38bf';
+YUI.Env[Y.version].md5 = '8deea7d26f0f85ddcacf3aa4da9bfed6';
}, '@VERSION@' ,{requires:['loader-base']});
diff --git a/build/node-screen/node-screen-debug.js b/build/node-screen/node-screen-debug.js
index 4a947e08abf..1f2e325eea6 100644
--- a/build/node-screen/node-screen-debug.js
+++ b/build/node-screen/node-screen-debug.js
@@ -168,7 +168,7 @@ Y.Node.importMethod(Y.DOM, [
*/
Y.Node.ATTRS.region = {
getter: function() {
- var node = Y.Node.getDOMNode(this),
+ var node = this.getDOMNode(),
region;
if (node && !node.tagName) {
@@ -176,7 +176,7 @@ Y.Node.ATTRS.region = {
node = node.documentElement;
}
}
- if (node.alert) {
+ if (Y.DOM.isWindow(node)) {
region = Y.DOM.viewportRegion(node);
} else {
region = Y.DOM.region(node);
diff --git a/build/node-screen/node-screen-min.js b/build/node-screen/node-screen-min.js
index df5d73d83f4..82a47e0ae0b 100644
--- a/build/node-screen/node-screen-min.js
+++ b/build/node-screen/node-screen-min.js
@@ -1 +1 @@
-YUI.add("node-screen",function(a){a.each(["winWidth","winHeight","docWidth","docHeight","docScrollX","docScrollY"],function(b){a.Node.ATTRS[b]={getter:function(){var c=Array.prototype.slice.call(arguments);c.unshift(a.Node.getDOMNode(this));return a.DOM[b].apply(this,c);}};});a.Node.ATTRS.scrollLeft={getter:function(){var b=a.Node.getDOMNode(this);return("scrollLeft" in b)?b.scrollLeft:a.DOM.docScrollX(b);},setter:function(c){var b=a.Node.getDOMNode(this);if(b){if("scrollLeft" in b){b.scrollLeft=c;}else{if(b.document||b.nodeType===9){a.DOM._getWin(b).scrollTo(c,a.DOM.docScrollY(b));}}}else{}}};a.Node.ATTRS.scrollTop={getter:function(){var b=a.Node.getDOMNode(this);return("scrollTop" in b)?b.scrollTop:a.DOM.docScrollY(b);},setter:function(c){var b=a.Node.getDOMNode(this);if(b){if("scrollTop" in b){b.scrollTop=c;}else{if(b.document||b.nodeType===9){a.DOM._getWin(b).scrollTo(a.DOM.docScrollX(b),c);}}}else{}}};a.Node.importMethod(a.DOM,["getXY","setXY","getX","setX","getY","setY","swapXY"]);a.Node.ATTRS.region={getter:function(){var b=a.Node.getDOMNode(this),c;if(b&&!b.tagName){if(b.nodeType===9){b=b.documentElement;}}if(b.alert){c=a.DOM.viewportRegion(b);}else{c=a.DOM.region(b);}return c;}};a.Node.ATTRS.viewportRegion={getter:function(){return a.DOM.viewportRegion(a.Node.getDOMNode(this));}};a.Node.importMethod(a.DOM,"inViewportRegion");a.Node.prototype.intersect=function(b,d){var c=a.Node.getDOMNode(this);if(a.instanceOf(b,a.Node)){b=a.Node.getDOMNode(b);}return a.DOM.intersect(c,b,d);};a.Node.prototype.inRegion=function(b,d,e){var c=a.Node.getDOMNode(this);if(a.instanceOf(b,a.Node)){b=a.Node.getDOMNode(b);}return a.DOM.inRegion(c,b,d,e);};},"@VERSION@",{requires:["node-base","dom-screen"]});
\ No newline at end of file
+YUI.add("node-screen",function(a){a.each(["winWidth","winHeight","docWidth","docHeight","docScrollX","docScrollY"],function(b){a.Node.ATTRS[b]={getter:function(){var c=Array.prototype.slice.call(arguments);c.unshift(a.Node.getDOMNode(this));return a.DOM[b].apply(this,c);}};});a.Node.ATTRS.scrollLeft={getter:function(){var b=a.Node.getDOMNode(this);return("scrollLeft" in b)?b.scrollLeft:a.DOM.docScrollX(b);},setter:function(c){var b=a.Node.getDOMNode(this);if(b){if("scrollLeft" in b){b.scrollLeft=c;}else{if(b.document||b.nodeType===9){a.DOM._getWin(b).scrollTo(c,a.DOM.docScrollY(b));}}}else{}}};a.Node.ATTRS.scrollTop={getter:function(){var b=a.Node.getDOMNode(this);return("scrollTop" in b)?b.scrollTop:a.DOM.docScrollY(b);},setter:function(c){var b=a.Node.getDOMNode(this);if(b){if("scrollTop" in b){b.scrollTop=c;}else{if(b.document||b.nodeType===9){a.DOM._getWin(b).scrollTo(a.DOM.docScrollX(b),c);}}}else{}}};a.Node.importMethod(a.DOM,["getXY","setXY","getX","setX","getY","setY","swapXY"]);a.Node.ATTRS.region={getter:function(){var b=this.getDOMNode(),c;if(b&&!b.tagName){if(b.nodeType===9){b=b.documentElement;}}if(a.DOM.isWindow(b)){c=a.DOM.viewportRegion(b);}else{c=a.DOM.region(b);}return c;}};a.Node.ATTRS.viewportRegion={getter:function(){return a.DOM.viewportRegion(a.Node.getDOMNode(this));}};a.Node.importMethod(a.DOM,"inViewportRegion");a.Node.prototype.intersect=function(b,d){var c=a.Node.getDOMNode(this);if(a.instanceOf(b,a.Node)){b=a.Node.getDOMNode(b);}return a.DOM.intersect(c,b,d);};a.Node.prototype.inRegion=function(b,d,e){var c=a.Node.getDOMNode(this);if(a.instanceOf(b,a.Node)){b=a.Node.getDOMNode(b);}return a.DOM.inRegion(c,b,d,e);};},"@VERSION@",{requires:["node-base","dom-screen"]});
\ No newline at end of file
diff --git a/build/node-screen/node-screen.js b/build/node-screen/node-screen.js
index 596a70e68c3..28d1b5aacd7 100644
--- a/build/node-screen/node-screen.js
+++ b/build/node-screen/node-screen.js
@@ -166,7 +166,7 @@ Y.Node.importMethod(Y.DOM, [
*/
Y.Node.ATTRS.region = {
getter: function() {
- var node = Y.Node.getDOMNode(this),
+ var node = this.getDOMNode(),
region;
if (node && !node.tagName) {
@@ -174,7 +174,7 @@ Y.Node.ATTRS.region = {
node = node.documentElement;
}
}
- if (node.alert) {
+ if (Y.DOM.isWindow(node)) {
region = Y.DOM.viewportRegion(node);
} else {
region = Y.DOM.region(node);
diff --git a/build/node/node-debug.js b/build/node/node-debug.js
index d956fa9d7a4..67ad1379298 100644
--- a/build/node/node-debug.js
+++ b/build/node/node-debug.js
@@ -2517,7 +2517,7 @@ Y.Node.importMethod(Y.DOM, [
*/
Y.Node.ATTRS.region = {
getter: function() {
- var node = Y.Node.getDOMNode(this),
+ var node = this.getDOMNode(),
region;
if (node && !node.tagName) {
@@ -2525,7 +2525,7 @@ Y.Node.ATTRS.region = {
node = node.documentElement;
}
}
- if (node.alert) {
+ if (Y.DOM.isWindow(node)) {
region = Y.DOM.viewportRegion(node);
} else {
region = Y.DOM.region(node);
@@ -2692,5 +2692,5 @@ Y.Node.prototype.delegate = function(type) {
}, '@VERSION@' ,{requires:['node-base', 'event-delegate']});
-YUI.add('node', function(Y){}, '@VERSION@' ,{use:['node-base', 'node-style', 'node-screen', 'node-pluginhost', 'node-event-delegate'], skinnable:false});
+YUI.add('node', function(Y){}, '@VERSION@' ,{skinnable:false, use:['node-base', 'node-style', 'node-screen', 'node-pluginhost', 'node-event-delegate']});
diff --git a/build/node/node-min.js b/build/node/node-min.js
index 645fc73f859..d7538b4301c 100644
--- a/build/node/node-min.js
+++ b/build/node/node-min.js
@@ -1,3 +1,3 @@
YUI.add("node-base",function(c){var j=".",e="nodeName",n="nodeType",b="ownerDocument",m="tagName",d="_yuid",i={},p=Array.prototype.slice,f=c.DOM,k=function(r){if(!this.getDOMNode){return new k(r);}if(typeof r=="string"){r=k._fromString(r);if(!r){return null;}}var q=(r.nodeType!==9)?r.uniqueID:r[d];if(q&&k._instances[q]&&k._instances[q]._node!==r){r[d]=null;}q=q||c.stamp(r);if(!q){q=c.guid();}this[d]=q;this._node=r;this._stateProxy=r;if(this._initPlugins){this._initPlugins();}this.SHOW_TRANSITION=k.SHOW_TRANSITION;this.HIDE_TRANSITION=k.HIDE_TRANSITION;},o=function(r){var q=null;if(r){q=(typeof r=="string")?function(s){return c.Selector.test(s,r);}:function(s){return r(c.one(s));};}return q;};k._fromString=function(q){if(q){if(q.indexOf("doc")===0){q=c.config.doc;}else{if(q.indexOf("win")===0){q=c.config.win;}else{q=c.Selector.query(q,null,true);}}}return q||null;};k.NAME="node";k.re_aria=/^(?:role$|aria-)/;k.SHOW_TRANSITION="fadeIn";k.HIDE_TRANSITION="fadeOut";k.DOM_EVENTS={abort:1,beforeunload:1,blur:1,change:1,click:1,close:1,command:1,contextmenu:1,dblclick:1,DOMMouseScroll:1,drag:1,dragstart:1,dragenter:1,dragover:1,dragleave:1,dragend:1,drop:1,error:1,focus:1,key:1,keydown:1,keypress:1,keyup:1,load:1,message:1,mousedown:1,mouseenter:1,mouseleave:1,mousemove:1,mousemultiwheel:1,mouseout:1,mouseover:1,mouseup:1,mousewheel:1,orientationchange:1,reset:1,resize:1,select:1,selectstart:1,submit:1,scroll:1,textInput:1,unload:1};c.mix(k.DOM_EVENTS,c.Env.evt.plugins);k._instances={};k.getDOMNode=function(q){if(q){return(q.nodeType)?q:q._node||null;}return null;};k.scrubVal=function(r,q){if(r){if(typeof r=="object"||typeof r=="function"){if(n in r||f.isWindow(r)){r=c.one(r);}else{if((r.item&&!r._nodes)||(r[0]&&r[0][n])){r=c.all(r);}}}}else{if(typeof r==="undefined"){r=q;}else{if(r===null){r=null;}}}return r;};k.addMethod=function(q,s,r){if(q&&s&&typeof s=="function"){k.prototype[q]=function(){var u=p.call(arguments),v=this,t;if(u[0]&&c.instanceOf(u[0],k)){u[0]=u[0]._node;}if(u[1]&&c.instanceOf(u[1],k)){u[1]=u[1]._node;}u.unshift(v._node);t=s.apply(v,u);if(t){t=k.scrubVal(t,v);}(typeof t!="undefined")||(t=v);return t;};}else{}};k.importMethod=function(s,q,r){if(typeof q=="string"){r=r||q;k.addMethod(r,s[q],s);}else{c.Array.each(q,function(t){k.importMethod(s,t);});}};k.one=function(t){var q=null,s,r;if(t){if(typeof t=="string"){t=k._fromString(t);if(!t){return null;}}else{if(t.getDOMNode){return t;}}if(t.nodeType||c.DOM.isWindow(t)){r=(t.uniqueID&&t.nodeType!==9)?t.uniqueID:t._yuid;q=k._instances[r];s=q?q._node:null;if(!q||(s&&t!==s)){q=new k(t);k._instances[q[d]]=q;}}}return q;};k.create=function(q,r){if(r&&r._node){r=r._node;}return c.one(f.create(q,r));};k.ATTRS={text:{getter:function(){return f.getText(this._node);},setter:function(q){f.setText(this._node,q);return q;}},"for":{getter:function(){return f.getAttribute(this._node,"for");},setter:function(q){f.setAttribute(this._node,"for",q);return q;}},"options":{getter:function(){return this._node.getElementsByTagName("option");}},"children":{getter:function(){var t=this._node,s=t.children,u,r,q;if(!s){u=t.childNodes;s=[];for(r=0,q=u.length;r When passing in an array of JS files, setting this flag to true
+ * will insert them into the document in parallel, as opposed to the
+ * default behavior, which is to chain load them serially. It will also
+ * set the async attribute on the script node to true. Setting async:true
+ * will lead to optimal file download performance allowing the browser to
+ * download multiple scripts in parallel, and execute them as soon as they
+ * are available. Note that async:true does not guarantee execution order of the
+ * scripts being downloaded. They are executed in whichever order they
+ * are received.
+
+Yahoo!
+",initializer:function(){var x=this.get("inputNode");if(!x){b.error("No inputNode specified.");return;}this._inputNode=x;this._listEvents=[];this.DEF_PARENT_NODE=x.get("parentNode");this[s]=this.getClassName(e);this[t]=this.getClassName(e,"active");this[d]=this.getClassName(e,"hover");this[u]="."+this[s];this.publish(n,{defaultFn:this._defSelectFn});},destructor:function(){while(this._listEvents.length){this._listEvents.pop().detach();}if(this._ariaNode){this._ariaNode.remove().destroy(true);}},bindUI:function(){this._bindInput();this._bindList();},renderUI:function(){var C=this._createAriaNode(),z=this.get("boundingBox"),y=this.get("contentBox"),B=this._inputNode,A,x=B.get("parentNode");A=this._createListNode();this._set("listNode",A);y.append(A);B.addClass(this.getClassName("input")).setAttrs({"aria-autocomplete":c,"aria-expanded":false,"aria-owns":A.get("id"),role:"combobox"});x.append(C);if(h){z.plug(b.Plugin.Shim);}z.setStyle("position","absolute");this._ariaNode=C;this._boundingBox=z;this._contentBox=y;this._listNode=A;this._parentNode=x;},syncUI:function(){this._syncResults();this._syncVisibility();},hide:function(){return this.get(k)?this:this.set(q,false);},selectItem:function(y,x){if(y){if(!y.hasClass(this[s])){return this;}}else{y=this.get(f);if(!y){return this;}}this.fire(n,{itemNode:y,originEvent:x||null,result:y.getData(w)});return this;},_activateNextItem:function(){var y=this.get(f),x;if(y){x=y.next(this[u])||(this.get(o)?null:y);}else{x=this._getFirstItemNode();}this.set(f,x);return this;},_activatePrevItem:function(){var y=this.get(f),x=y?y.previous(this[u]):this.get(o)&&this._getLastItemNode();this.set(f,x||null);return this;},_add:function(x){var y=[];l.each(i.isArray(x)?x:[x],function(z){y.push(this._createItemNode(z).setData(w,z));},this);y=b.all(y);this._listNode.append(y.toFrag());return y;},_ariaSay:function(z,x){var y=this.get("strings."+z);this._ariaNode.setContent(x?i.sub(y,x):y);},_bindInput:function(){var A=this._inputNode,y,z,x;if(this.get("align")===null){x=this.get("tokenInput");y=(x&&x.get("boundingBox"))||A;this.set("align",{node:y,points:["tl","bl"]});if(!this.get(g)&&(z=y.get("offsetWidth"))){this.set(g,z);}}this._listEvents.push(A.on("blur",this._onListInputBlur,this));},_bindList:function(){this._listEvents.concat([b.on("windowresize",this._syncPosition,this),this.after({mouseover:this._afterMouseOver,mouseout:this._afterMouseOut,activeItemChange:this._afterActiveItemChange,alwaysShowListChange:this._afterAlwaysShowListChange,hoveredItemChange:this._afterHoveredItemChange,resultsChange:this._afterResultsChange,visibleChange:this._afterVisibleChange}),this._listNode.delegate("click",this._onItemClick,this[u],this)]);},_clear:function(){this.set(f,null);this._set(r,null);this._listNode.get("children").remove(true);},_createAriaNode:function(){var x=v.create(this.ARIA_TEMPLATE);return x.addClass(this.getClassName("aria")).setAttrs({"aria-live":"polite",role:"status"});},_createItemNode:function(x){var y=v.create(this.ITEM_TEMPLATE);return y.addClass(this[s]).setAttrs({id:b.stamp(y),role:"option"}).setAttribute("data-text",x.text).append(x.display);},_createListNode:function(){var x=v.create(this.LIST_TEMPLATE);return x.addClass(this.getClassName(c)).setAttrs({id:b.stamp(x),role:"listbox"});},_getFirstItemNode:function(){return this._listNode.one(this[u]);},_getLastItemNode:function(){return this._listNode.one(this[u]+":last-child");},_syncPosition:function(){this._syncUIPosAlign();this._syncShim();},_syncResults:function(x){if(!x){x=this.get(j);}this._clear();if(x.length){this._add(x);this._ariaSay("items_available");}this._syncPosition();if(this.get("activateFirstItem")&&!this.get(f)){this.set(f,this._getFirstItemNode());}},_syncShim:h?function(){this._boundingBox.shim.sync();}:function(){},_syncVisibility:function(x){if(this.get(k)){x=true;this.set(q,x);}if(typeof x==="undefined"){x=this.get(q);}this._inputNode.set("aria-expanded",x);this._boundingBox.set("aria-hidden",!x);if(x){this._syncPosition();}else{this.set(f,null);this._set(r,null);this._boundingBox.get("offsetWidth");}},_afterActiveItemChange:function(z){var y=this._inputNode,x=z.newVal,A=z.prevVal;if(A&&A._node){A.removeClass(this[t]);}if(x){x.addClass(this[t]);y.set("aria-activedescendant",x.get(m));}else{y.removeAttribute("aria-activedescendant");}if(this.get("scrollIntoView")){(x||y).scrollIntoView();}},_afterAlwaysShowListChange:function(x){this.set(q,x.newVal||this.get(j).length>0);},_afterHoveredItemChange:function(y){var x=y.newVal,z=y.prevVal;if(z){z.removeClass(this[d]);}if(x){x.addClass(this[d]);}},_afterMouseOver:function(x){var y=x.domEvent.target.ancestor(this[u],true);this._mouseOverList=true;if(y){this._set(r,y);}},_afterMouseOut:function(){this._mouseOverList=false;this._set(r,null);},_afterResultsChange:function(x){this._syncResults(x.newVal);if(!this.get(k)){this.set(q,!!x.newVal.length);}},_afterVisibleChange:function(x){this._syncVisibility(!!x.newVal);},_onListInputBlur:function(x){if(!this._mouseOverList||this._lastInputKey===p){this.hide();}},_onItemClick:function(x){var y=x.currentTarget;this.set(f,y);this.selectItem(y,x);},_defSelectFn:function(x){var y=x.result.text;this._inputNode.focus();this._updateValue(y);this._ariaSay("item_selected",{item:y});this.hide();}},{ATTRS:{activateFirstItem:{value:false},activeItem:{setter:b.one,value:null},alwaysShowList:{value:false},circular:{value:true},hoveredItem:{readOnly:true,value:null},listNode:{readOnly:true,value:null},scrollIntoView:{value:false},strings:{valueFn:function(){return b.Intl.get("autocomplete-list");
-}},tabSelect:{value:true},visible:{value:false}},CSS_PREFIX:b.ClassNameManager.getClassName("aclist")});b.AutoCompleteList=a;b.AutoComplete=a;},"@VERSION@",{after:["autocomplete-sources"],lang:["en"],skinnable:true,requires:["autocomplete-base","event-resize","selector-css3","shim-plugin","widget","widget-position","widget-position-align"]});
\ No newline at end of file
+}},tabSelect:{value:true},visible:{value:false}},CSS_PREFIX:b.ClassNameManager.getClassName("aclist")});b.AutoCompleteList=a;b.AutoComplete=a;},"@VERSION@",{requires:["autocomplete-base","event-resize","selector-css3","shim-plugin","widget","widget-position","widget-position-align"],after:["autocomplete-sources"],lang:["en"],skinnable:true});
\ No newline at end of file
diff --git a/build/autocomplete-list/autocomplete-list.js b/build/autocomplete-list/autocomplete-list.js
index 1a21c740890..c3ee968383e 100644
--- a/build/autocomplete-list/autocomplete-list.js
+++ b/build/autocomplete-list/autocomplete-list.js
@@ -830,4 +830,4 @@ Y.AutoCompleteList = List;
Y.AutoComplete = List;
-}, '@VERSION@' ,{after:['autocomplete-sources'], lang:['en'], skinnable:true, requires:['autocomplete-base', 'event-resize', 'selector-css3', 'shim-plugin', 'widget', 'widget-position', 'widget-position-align']});
+}, '@VERSION@' ,{requires:['autocomplete-base', 'event-resize', 'selector-css3', 'shim-plugin', 'widget', 'widget-position', 'widget-position-align'], after:['autocomplete-sources'], lang:['en'], skinnable:true});
diff --git a/build/autocomplete-sources/autocomplete-sources-debug.js b/build/autocomplete-sources/autocomplete-sources-debug.js
index 94458110dec..ea7a8237068 100644
--- a/build/autocomplete-sources/autocomplete-sources-debug.js
+++ b/build/autocomplete-sources/autocomplete-sources-debug.js
@@ -477,4 +477,4 @@ Y.mix(ACBase.SOURCE_TYPES, {
}, true);
-}, '@VERSION@' ,{requires:['autocomplete-base'], optional:['io-base', 'json-parse', 'jsonp', 'yql']});
+}, '@VERSION@' ,{optional:['io-base', 'json-parse', 'jsonp', 'yql'], requires:['autocomplete-base']});
diff --git a/build/autocomplete-sources/autocomplete-sources-min.js b/build/autocomplete-sources/autocomplete-sources-min.js
index 83d8a316f90..1c6459c078b 100644
--- a/build/autocomplete-sources/autocomplete-sources-min.js
+++ b/build/autocomplete-sources/autocomplete-sources-min.js
@@ -1 +1 @@
-YUI.add("autocomplete-sources",function(g){var a=g.AutoCompleteBase,f=g.Lang,b="_sourceSuccess",d="maxResults",e="requestTemplate",c="resultListLocator";g.mix(a.prototype,{_YQL_SOURCE_REGEX:/^(?:select|set|use)\s+/i,_beforeCreateObjectSource:function(h){if(h instanceof g.Node&&h.get("nodeName").toLowerCase()==="select"){return this._createSelectSource(h);}if(g.JSONPRequest&&h instanceof g.JSONPRequest){return this._createJSONPSource(h);}return this._createObjectSource(h);},_createIOSource:function(m){var j={},k={type:"io"},l=this,o,i,n;function h(p){var q=p.query;if(j[q]){l[b](j[q],p);return;}if(o&&o.isInProgress()){o.abort();}o=g.io(l._getXHRUrl(m,q),{on:{success:function(u,r){var t;try{t=g.JSON.parse(r.responseText);}catch(s){g.error("JSON parse error",s);}if(t){j[q]=t;l[b](t,p);}}}});}k.sendRequest=function(p){i=p;if(n){return;}n=true;g.use("io-base","json-parse",function(){k.sendRequest=h;h(i);});};return k;},_createJSONPSource:function(m){var j={},k={type:"jsonp"},l=this,i,n;function h(o){var p=o.query;if(j[p]){l[b](j[p],o);return;}m._config.on.success=function(q){j[p]=q;l[b](q,o);};m.send(p);}k.sendRequest=function(o){i=o;if(n){return;}n=true;g.use("jsonp",function(){if(!(m instanceof g.JSONPRequest)){m=new g.JSONPRequest(m,{format:g.bind(l._jsonpFormatter,l)});}k.sendRequest=h;h(i);});};return k;},_createSelectSource:function(i){var h=this;return{type:"select",sendRequest:function(k){var j=[];i.get("options").each(function(l){j.push({html:l.get("innerHTML"),index:l.get("index"),node:l,selected:l.get("selected"),text:l.get("text"),value:l.get("value")});});h[b](j,k);}};},_createStringSource:function(h){if(this._YQL_SOURCE_REGEX.test(h)){return this._createYQLSource(h);}else{if(h.indexOf("{callback}")!==-1){return this._createJSONPSource(h);}else{return this._createIOSource(h);}}},_createYQLSource:function(m){var j={},n={type:"yql"},l=this,i,o,k;if(!this.get(c)){this.set(c,this._defaultYQLLocator);}function h(t){var u=t.query,v,r,p,s,q;if(j[u]){l[b](j[u],t);return;}v=function(w){j[u]=w;l[b](w,t);};r=l.get("yqlEnv");p=l.get(d);s={proto:l.get("yqlProtocol")};q=f.sub(m,{maxResults:p>0?p:1000,query:u});if(k){k._callback=v;k._opts=s;k._params.q=q;if(r){k._params.env=r;}}else{k=new g.YQLRequest(q,{on:{success:v},allowCache:false},r?{env:r}:null,s);}k.send();}n.sendRequest=function(p){i=p;if(!o){o=true;g.use("yql",function(){n.sendRequest=h;h(i);});}};return n;},_defaultYQLLocator:function(i){var j=i&&i.query&&i.query.results,h;if(j&&f.isObject(j)){h=g.Object.values(j)||[];j=h.length===1?h[0]:h;if(!f.isArray(j)){j=[j];}}else{j=[];}return j;},_getXHRUrl:function(i,j){var h=this.get(d),k=this.get(e);if(k){i+=k(j);}return f.sub(i,{maxResults:h>0?h:1000,query:encodeURIComponent(j)});},_jsonpFormatter:function(i,j,k){var h=this.get(d),l=this.get(e);if(l){i+=l(k);}return f.sub(i,{callback:j,maxResults:h>0?h:1000,query:encodeURIComponent(k)});}});g.mix(a.ATTRS,{yqlEnv:{value:null},yqlProtocol:{value:"http"}});g.mix(a.SOURCE_TYPES,{io:"_createIOSource",jsonp:"_createJSONPSource",object:"_beforeCreateObjectSource",select:"_createSelectSource",string:"_createStringSource",yql:"_createYQLSource"},true);},"@VERSION@",{requires:["autocomplete-base"],optional:["io-base","json-parse","jsonp","yql"]});
\ No newline at end of file
+YUI.add("autocomplete-sources",function(g){var a=g.AutoCompleteBase,f=g.Lang,b="_sourceSuccess",d="maxResults",e="requestTemplate",c="resultListLocator";g.mix(a.prototype,{_YQL_SOURCE_REGEX:/^(?:select|set|use)\s+/i,_beforeCreateObjectSource:function(h){if(h instanceof g.Node&&h.get("nodeName").toLowerCase()==="select"){return this._createSelectSource(h);}if(g.JSONPRequest&&h instanceof g.JSONPRequest){return this._createJSONPSource(h);}return this._createObjectSource(h);},_createIOSource:function(m){var j={},k={type:"io"},l=this,o,i,n;function h(p){var q=p.query;if(j[q]){l[b](j[q],p);return;}if(o&&o.isInProgress()){o.abort();}o=g.io(l._getXHRUrl(m,q),{on:{success:function(u,r){var t;try{t=g.JSON.parse(r.responseText);}catch(s){g.error("JSON parse error",s);}if(t){j[q]=t;l[b](t,p);}}}});}k.sendRequest=function(p){i=p;if(n){return;}n=true;g.use("io-base","json-parse",function(){k.sendRequest=h;h(i);});};return k;},_createJSONPSource:function(m){var j={},k={type:"jsonp"},l=this,i,n;function h(o){var p=o.query;if(j[p]){l[b](j[p],o);return;}m._config.on.success=function(q){j[p]=q;l[b](q,o);};m.send(p);}k.sendRequest=function(o){i=o;if(n){return;}n=true;g.use("jsonp",function(){if(!(m instanceof g.JSONPRequest)){m=new g.JSONPRequest(m,{format:g.bind(l._jsonpFormatter,l)});}k.sendRequest=h;h(i);});};return k;},_createSelectSource:function(i){var h=this;return{type:"select",sendRequest:function(k){var j=[];i.get("options").each(function(l){j.push({html:l.get("innerHTML"),index:l.get("index"),node:l,selected:l.get("selected"),text:l.get("text"),value:l.get("value")});});h[b](j,k);}};},_createStringSource:function(h){if(this._YQL_SOURCE_REGEX.test(h)){return this._createYQLSource(h);}else{if(h.indexOf("{callback}")!==-1){return this._createJSONPSource(h);}else{return this._createIOSource(h);}}},_createYQLSource:function(m){var j={},n={type:"yql"},l=this,i,o,k;if(!this.get(c)){this.set(c,this._defaultYQLLocator);}function h(t){var u=t.query,v,r,p,s,q;if(j[u]){l[b](j[u],t);return;}v=function(w){j[u]=w;l[b](w,t);};r=l.get("yqlEnv");p=l.get(d);s={proto:l.get("yqlProtocol")};q=f.sub(m,{maxResults:p>0?p:1000,query:u});if(k){k._callback=v;k._opts=s;k._params.q=q;if(r){k._params.env=r;}}else{k=new g.YQLRequest(q,{on:{success:v},allowCache:false},r?{env:r}:null,s);}k.send();}n.sendRequest=function(p){i=p;if(!o){o=true;g.use("yql",function(){n.sendRequest=h;h(i);});}};return n;},_defaultYQLLocator:function(i){var j=i&&i.query&&i.query.results,h;if(j&&f.isObject(j)){h=g.Object.values(j)||[];j=h.length===1?h[0]:h;if(!f.isArray(j)){j=[j];}}else{j=[];}return j;},_getXHRUrl:function(i,j){var h=this.get(d),k=this.get(e);if(k){i+=k(j);}return f.sub(i,{maxResults:h>0?h:1000,query:encodeURIComponent(j)});},_jsonpFormatter:function(i,j,k){var h=this.get(d),l=this.get(e);if(l){i+=l(k);}return f.sub(i,{callback:j,maxResults:h>0?h:1000,query:encodeURIComponent(k)});}});g.mix(a.ATTRS,{yqlEnv:{value:null},yqlProtocol:{value:"http"}});g.mix(a.SOURCE_TYPES,{io:"_createIOSource",jsonp:"_createJSONPSource",object:"_beforeCreateObjectSource",select:"_createSelectSource",string:"_createStringSource",yql:"_createYQLSource"},true);},"@VERSION@",{optional:["io-base","json-parse","jsonp","yql"],requires:["autocomplete-base"]});
\ No newline at end of file
diff --git a/build/autocomplete-sources/autocomplete-sources.js b/build/autocomplete-sources/autocomplete-sources.js
index 94458110dec..ea7a8237068 100644
--- a/build/autocomplete-sources/autocomplete-sources.js
+++ b/build/autocomplete-sources/autocomplete-sources.js
@@ -477,4 +477,4 @@ Y.mix(ACBase.SOURCE_TYPES, {
}, true);
-}, '@VERSION@' ,{requires:['autocomplete-base'], optional:['io-base', 'json-parse', 'jsonp', 'yql']});
+}, '@VERSION@' ,{optional:['io-base', 'json-parse', 'jsonp', 'yql'], requires:['autocomplete-base']});
diff --git a/build/autocomplete/autocomplete-debug.js b/build/autocomplete/autocomplete-debug.js
index 0312c48b534..261b8792d6b 100644
--- a/build/autocomplete/autocomplete-debug.js
+++ b/build/autocomplete/autocomplete-debug.js
@@ -1628,7 +1628,7 @@ AutoCompleteBase.prototype = {
Y.AutoCompleteBase = AutoCompleteBase;
-}, '@VERSION@' ,{requires:['array-extras', 'base-build', 'escape', 'event-valuechange', 'node-base'], optional:['autocomplete-sources']});
+}, '@VERSION@' ,{optional:['autocomplete-sources'], requires:['array-extras', 'base-build', 'escape', 'event-valuechange', 'node-base']});
YUI.add('autocomplete-sources', function(Y) {
/**
@@ -2108,7 +2108,7 @@ Y.mix(ACBase.SOURCE_TYPES, {
}, true);
-}, '@VERSION@' ,{requires:['autocomplete-base'], optional:['io-base', 'json-parse', 'jsonp', 'yql']});
+}, '@VERSION@' ,{optional:['io-base', 'json-parse', 'jsonp', 'yql'], requires:['autocomplete-base']});
YUI.add('autocomplete-list', function(Y) {
/**
@@ -2941,7 +2941,7 @@ Y.AutoCompleteList = List;
Y.AutoComplete = List;
-}, '@VERSION@' ,{after:['autocomplete-sources'], lang:['en'], skinnable:true, requires:['autocomplete-base', 'event-resize', 'selector-css3', 'shim-plugin', 'widget', 'widget-position', 'widget-position-align']});
+}, '@VERSION@' ,{requires:['autocomplete-base', 'event-resize', 'selector-css3', 'shim-plugin', 'widget', 'widget-position', 'widget-position-align'], after:['autocomplete-sources'], lang:['en'], skinnable:true});
YUI.add('autocomplete-plugin', function(Y) {
/**
diff --git a/build/autocomplete/autocomplete-min.js b/build/autocomplete/autocomplete-min.js
index 1624410c975..3bfaee2c27e 100644
--- a/build/autocomplete/autocomplete-min.js
+++ b/build/autocomplete/autocomplete-min.js
@@ -1,3 +1,3 @@
YUI.add("autocomplete-base",function(f){var g=f.Escape,j=f.Lang,q=f.Array,i=f.Object,d=j.isFunction,r=j.isString,u=j.trim,l=f.Attribute.INVALID_VALUE,o="_functionValidator",x="_sourceSuccess",c="allowBrowserAutocomplete",h="inputNode",w="query",e="queryDelimiter",b="requestTemplate",m="results",n="resultListLocator",k="value",s="valueChange",a="clear",t=w,p=m;function v(){f.before(this._bindUIACBase,this,"bindUI");f.before(this._destructorACBase,this,"destructor");f.before(this._syncUIACBase,this,"syncUI");this.publish(a,{defaultFn:this._defClearFn});this.publish(t,{defaultFn:this._defQueryFn});this.publish(p,{defaultFn:this._defResultsFn});}v.ATTRS={allowBrowserAutocomplete:{value:false},allowTrailingDelimiter:{value:false},inputNode:{setter:f.one,writeOnce:"initOnly"},maxResults:{value:0},minQueryLength:{value:1},query:{readOnly:true,value:null},queryDelay:{value:100},queryDelimiter:{value:null},requestTemplate:{setter:"_setRequestTemplate",value:null},resultFilters:{setter:"_setResultFilters",value:[]},resultFormatter:{validator:o},resultHighlighter:{setter:"_setResultHighlighter"},resultListLocator:{setter:"_setLocator"},results:{readOnly:true,value:[]},resultTextLocator:{setter:"_setLocator"},source:{setter:"_setSource"},sourceType:{value:null},tokenInput:{readOnly:true},value:{value:""}};v.CSS_PREFIX="ac";v.UI_SRC=(f.Widget&&f.Widget.UI_SRC)||"ui";v.SOURCE_TYPES={array:"_createArraySource","function":"_createFunctionSource",object:"_createObjectSource"};v.prototype={sendRequest:function(A,B){var y,z=this.get("source");if(A||A===""){this._set(w,A);}else{A=this.get(w);}if(z){if(!B){B=this.get(b);}y=B?B(A):A;z.sendRequest({query:A,request:y,callback:{success:f.bind(this._onResponse,this,A)}});}return this;},_bindUIACBase:function(){var z=this.get(h),y=z&&z.tokenInput;if(y){z=y.get(h);this._set("tokenInput",y);}if(!z){f.error("No inputNode specified.");return;}this._inputNode=z;this._acBaseEvents=new f.EventHandle([z.on(s,this._onInputValueChange,this),z.on("blur",this._onInputBlur,this),this.after(c+"Change",this._syncBrowserAutocomplete),this.after("sourceTypeChange",this._afterSourceTypeChange),this.after(s,this._afterValueChange)]);},_destructorACBase:function(){this._acBaseEvents.detach();},_syncUIACBase:function(){this._syncBrowserAutocomplete();this.set(k,this.get(h).get(k));},_createArraySource:function(z){var y=this;return{type:"array",sendRequest:function(A){y[x](z.concat(),A);}};},_createFunctionSource:function(z){var y=this;return{type:"function",sendRequest:function(A){var B;function C(D){y[x](D||[],A);}if((B=z(A.query,C))){C(B);}}};},_createObjectSource:function(z){var y=this;return{type:"object",sendRequest:function(A){var B=A.query;y[x](i.owns(z,B)?z[B]:[],A);}};},_functionValidator:function(y){return y===null||d(y);},_getObjectValue:function(B,A){if(!B){return;}for(var z=0,y=A.length;B&&z
",initializer:function(){var x=this.get("inputNode");if(!x){b.error("No inputNode specified.");return;}this._inputNode=x;this._listEvents=[];this.DEF_PARENT_NODE=x.get("parentNode");this[s]=this.getClassName(e);this[t]=this.getClassName(e,"active");this[d]=this.getClassName(e,"hover");this[u]="."+this[s];this.publish(n,{defaultFn:this._defSelectFn});},destructor:function(){while(this._listEvents.length){this._listEvents.pop().detach();}if(this._ariaNode){this._ariaNode.remove().destroy(true);}},bindUI:function(){this._bindInput();this._bindList();},renderUI:function(){var C=this._createAriaNode(),z=this.get("boundingBox"),y=this.get("contentBox"),B=this._inputNode,A,x=B.get("parentNode");A=this._createListNode();this._set("listNode",A);y.append(A);B.addClass(this.getClassName("input")).setAttrs({"aria-autocomplete":c,"aria-expanded":false,"aria-owns":A.get("id"),role:"combobox"});x.append(C);if(h){z.plug(b.Plugin.Shim);}z.setStyle("position","absolute");this._ariaNode=C;this._boundingBox=z;this._contentBox=y;this._listNode=A;this._parentNode=x;},syncUI:function(){this._syncResults();this._syncVisibility();},hide:function(){return this.get(k)?this:this.set(q,false);},selectItem:function(y,x){if(y){if(!y.hasClass(this[s])){return this;}}else{y=this.get(f);if(!y){return this;}}this.fire(n,{itemNode:y,originEvent:x||null,result:y.getData(w)});return this;},_activateNextItem:function(){var y=this.get(f),x;if(y){x=y.next(this[u])||(this.get(o)?null:y);}else{x=this._getFirstItemNode();}this.set(f,x);return this;},_activatePrevItem:function(){var y=this.get(f),x=y?y.previous(this[u]):this.get(o)&&this._getLastItemNode();this.set(f,x||null);return this;},_add:function(x){var y=[];l.each(i.isArray(x)?x:[x],function(z){y.push(this._createItemNode(z).setData(w,z));
-},this);y=b.all(y);this._listNode.append(y.toFrag());return y;},_ariaSay:function(z,x){var y=this.get("strings."+z);this._ariaNode.setContent(x?i.sub(y,x):y);},_bindInput:function(){var A=this._inputNode,y,z,x;if(this.get("align")===null){x=this.get("tokenInput");y=(x&&x.get("boundingBox"))||A;this.set("align",{node:y,points:["tl","bl"]});if(!this.get(g)&&(z=y.get("offsetWidth"))){this.set(g,z);}}this._listEvents.push(A.on("blur",this._onListInputBlur,this));},_bindList:function(){this._listEvents.concat([b.on("windowresize",this._syncPosition,this),this.after({mouseover:this._afterMouseOver,mouseout:this._afterMouseOut,activeItemChange:this._afterActiveItemChange,alwaysShowListChange:this._afterAlwaysShowListChange,hoveredItemChange:this._afterHoveredItemChange,resultsChange:this._afterResultsChange,visibleChange:this._afterVisibleChange}),this._listNode.delegate("click",this._onItemClick,this[u],this)]);},_clear:function(){this.set(f,null);this._set(r,null);this._listNode.get("children").remove(true);},_createAriaNode:function(){var x=v.create(this.ARIA_TEMPLATE);return x.addClass(this.getClassName("aria")).setAttrs({"aria-live":"polite",role:"status"});},_createItemNode:function(x){var y=v.create(this.ITEM_TEMPLATE);return y.addClass(this[s]).setAttrs({id:b.stamp(y),role:"option"}).setAttribute("data-text",x.text).append(x.display);},_createListNode:function(){var x=v.create(this.LIST_TEMPLATE);return x.addClass(this.getClassName(c)).setAttrs({id:b.stamp(x),role:"listbox"});},_getFirstItemNode:function(){return this._listNode.one(this[u]);},_getLastItemNode:function(){return this._listNode.one(this[u]+":last-child");},_syncPosition:function(){this._syncUIPosAlign();this._syncShim();},_syncResults:function(x){if(!x){x=this.get(j);}this._clear();if(x.length){this._add(x);this._ariaSay("items_available");}this._syncPosition();if(this.get("activateFirstItem")&&!this.get(f)){this.set(f,this._getFirstItemNode());}},_syncShim:h?function(){this._boundingBox.shim.sync();}:function(){},_syncVisibility:function(x){if(this.get(k)){x=true;this.set(q,x);}if(typeof x==="undefined"){x=this.get(q);}this._inputNode.set("aria-expanded",x);this._boundingBox.set("aria-hidden",!x);if(x){this._syncPosition();}else{this.set(f,null);this._set(r,null);this._boundingBox.get("offsetWidth");}},_afterActiveItemChange:function(z){var y=this._inputNode,x=z.newVal,A=z.prevVal;if(A&&A._node){A.removeClass(this[t]);}if(x){x.addClass(this[t]);y.set("aria-activedescendant",x.get(m));}else{y.removeAttribute("aria-activedescendant");}if(this.get("scrollIntoView")){(x||y).scrollIntoView();}},_afterAlwaysShowListChange:function(x){this.set(q,x.newVal||this.get(j).length>0);},_afterHoveredItemChange:function(y){var x=y.newVal,z=y.prevVal;if(z){z.removeClass(this[d]);}if(x){x.addClass(this[d]);}},_afterMouseOver:function(x){var y=x.domEvent.target.ancestor(this[u],true);this._mouseOverList=true;if(y){this._set(r,y);}},_afterMouseOut:function(){this._mouseOverList=false;this._set(r,null);},_afterResultsChange:function(x){this._syncResults(x.newVal);if(!this.get(k)){this.set(q,!!x.newVal.length);}},_afterVisibleChange:function(x){this._syncVisibility(!!x.newVal);},_onListInputBlur:function(x){if(!this._mouseOverList||this._lastInputKey===p){this.hide();}},_onItemClick:function(x){var y=x.currentTarget;this.set(f,y);this.selectItem(y,x);},_defSelectFn:function(x){var y=x.result.text;this._inputNode.focus();this._updateValue(y);this._ariaSay("item_selected",{item:y});this.hide();}},{ATTRS:{activateFirstItem:{value:false},activeItem:{setter:b.one,value:null},alwaysShowList:{value:false},circular:{value:true},hoveredItem:{readOnly:true,value:null},listNode:{readOnly:true,value:null},scrollIntoView:{value:false},strings:{valueFn:function(){return b.Intl.get("autocomplete-list");}},tabSelect:{value:true},visible:{value:false}},CSS_PREFIX:b.ClassNameManager.getClassName("aclist")});b.AutoCompleteList=a;b.AutoComplete=a;},"@VERSION@",{after:["autocomplete-sources"],lang:["en"],skinnable:true,requires:["autocomplete-base","event-resize","selector-css3","shim-plugin","widget","widget-position","widget-position-align"]});YUI.add("autocomplete-plugin",function(b){var a=b.Plugin;function c(d){d.inputNode=d.host;if(!d.render&&d.render!==false){d.render=true;}c.superclass.constructor.apply(this,arguments);}b.extend(c,b.AutoCompleteList,{},{NAME:"autocompleteListPlugin",NS:"ac",CSS_PREFIX:b.ClassNameManager.getClassName("aclist")});a.AutoComplete=c;a.AutoCompleteList=c;},"@VERSION@",{requires:["autocomplete-list","node-pluginhost"]});YUI.add("autocomplete",function(a){},"@VERSION@",{use:["autocomplete-base","autocomplete-sources","autocomplete-list","autocomplete-plugin"]});
\ No newline at end of file
+}if(z!==A){this.set(k,z);}}},_onInputValueChange:function(z){var y=z.newVal;if(y===this.get(k)){return;}this.set(k,y,{src:v.UI_SRC});},_onResponse:function(y,z){if(y===this.get(w)){this._parseResponse(y,z.response,z.data);}},_defClearFn:function(){this._set(w,null);this._set(m,[]);},_defQueryFn:function(z){var y=z.query;this.sendRequest(y);},_defResultsFn:function(y){this._set(m,y[m]);}};f.AutoCompleteBase=v;},"@VERSION@",{optional:["autocomplete-sources"],requires:["array-extras","base-build","escape","event-valuechange","node-base"]});YUI.add("autocomplete-sources",function(g){var a=g.AutoCompleteBase,f=g.Lang,b="_sourceSuccess",d="maxResults",e="requestTemplate",c="resultListLocator";g.mix(a.prototype,{_YQL_SOURCE_REGEX:/^(?:select|set|use)\s+/i,_beforeCreateObjectSource:function(h){if(h instanceof g.Node&&h.get("nodeName").toLowerCase()==="select"){return this._createSelectSource(h);}if(g.JSONPRequest&&h instanceof g.JSONPRequest){return this._createJSONPSource(h);}return this._createObjectSource(h);},_createIOSource:function(m){var j={},k={type:"io"},l=this,o,i,n;function h(p){var q=p.query;if(j[q]){l[b](j[q],p);return;}if(o&&o.isInProgress()){o.abort();}o=g.io(l._getXHRUrl(m,q),{on:{success:function(u,r){var t;try{t=g.JSON.parse(r.responseText);}catch(s){g.error("JSON parse error",s);}if(t){j[q]=t;l[b](t,p);}}}});}k.sendRequest=function(p){i=p;if(n){return;}n=true;g.use("io-base","json-parse",function(){k.sendRequest=h;h(i);});};return k;},_createJSONPSource:function(m){var j={},k={type:"jsonp"},l=this,i,n;function h(o){var p=o.query;if(j[p]){l[b](j[p],o);return;}m._config.on.success=function(q){j[p]=q;l[b](q,o);};m.send(p);}k.sendRequest=function(o){i=o;if(n){return;}n=true;g.use("jsonp",function(){if(!(m instanceof g.JSONPRequest)){m=new g.JSONPRequest(m,{format:g.bind(l._jsonpFormatter,l)});}k.sendRequest=h;h(i);});};return k;},_createSelectSource:function(i){var h=this;return{type:"select",sendRequest:function(k){var j=[];i.get("options").each(function(l){j.push({html:l.get("innerHTML"),index:l.get("index"),node:l,selected:l.get("selected"),text:l.get("text"),value:l.get("value")});});h[b](j,k);}};},_createStringSource:function(h){if(this._YQL_SOURCE_REGEX.test(h)){return this._createYQLSource(h);}else{if(h.indexOf("{callback}")!==-1){return this._createJSONPSource(h);}else{return this._createIOSource(h);}}},_createYQLSource:function(m){var j={},n={type:"yql"},l=this,i,o,k;if(!this.get(c)){this.set(c,this._defaultYQLLocator);}function h(t){var u=t.query,v,r,p,s,q;if(j[u]){l[b](j[u],t);return;}v=function(w){j[u]=w;l[b](w,t);};r=l.get("yqlEnv");p=l.get(d);s={proto:l.get("yqlProtocol")};q=f.sub(m,{maxResults:p>0?p:1000,query:u});if(k){k._callback=v;k._opts=s;k._params.q=q;if(r){k._params.env=r;}}else{k=new g.YQLRequest(q,{on:{success:v},allowCache:false},r?{env:r}:null,s);}k.send();}n.sendRequest=function(p){i=p;if(!o){o=true;g.use("yql",function(){n.sendRequest=h;h(i);});}};return n;},_defaultYQLLocator:function(i){var j=i&&i.query&&i.query.results,h;if(j&&f.isObject(j)){h=g.Object.values(j)||[];j=h.length===1?h[0]:h;if(!f.isArray(j)){j=[j];}}else{j=[];}return j;},_getXHRUrl:function(i,j){var h=this.get(d),k=this.get(e);if(k){i+=k(j);}return f.sub(i,{maxResults:h>0?h:1000,query:encodeURIComponent(j)});},_jsonpFormatter:function(i,j,k){var h=this.get(d),l=this.get(e);if(l){i+=l(k);}return f.sub(i,{callback:j,maxResults:h>0?h:1000,query:encodeURIComponent(k)});}});g.mix(a.ATTRS,{yqlEnv:{value:null},yqlProtocol:{value:"http"}});g.mix(a.SOURCE_TYPES,{io:"_createIOSource",jsonp:"_createJSONPSource",object:"_beforeCreateObjectSource",select:"_createSelectSource",string:"_createStringSource",yql:"_createYQLSource"},true);},"@VERSION@",{optional:["io-base","json-parse","jsonp","yql"],requires:["autocomplete-base"]});YUI.add("autocomplete-list",function(b){var i=b.Lang,v=b.Node,l=b.Array,h=b.UA.ie&&b.UA.ie<7,p=9,s="_CLASS_ITEM",t="_CLASS_ITEM_ACTIVE",d="_CLASS_ITEM_HOVER",u="_SELECTOR_ITEM",f="activeItem",k="alwaysShowList",o="circular",r="hoveredItem",m="id",e="item",c="list",w="result",j="results",q="visible",g="width",n="select",a=b.Base.create("autocompleteList",b.Widget,[b.AutoCompleteBase,b.WidgetPosition,b.WidgetPositionAlign],{ARIA_TEMPLATE:"",ITEM_TEMPLATE:"",LIST_TEMPLATE:"
",initializer:function(){var x=this.get("inputNode");if(!x){b.error("No inputNode specified.");return;}this._inputNode=x;this._listEvents=[];this.DEF_PARENT_NODE=x.get("parentNode");this[s]=this.getClassName(e);this[t]=this.getClassName(e,"active");this[d]=this.getClassName(e,"hover");this[u]="."+this[s];this.publish(n,{defaultFn:this._defSelectFn});},destructor:function(){while(this._listEvents.length){this._listEvents.pop().detach();}if(this._ariaNode){this._ariaNode.remove().destroy(true);}},bindUI:function(){this._bindInput();this._bindList();},renderUI:function(){var C=this._createAriaNode(),z=this.get("boundingBox"),y=this.get("contentBox"),B=this._inputNode,A,x=B.get("parentNode");A=this._createListNode();this._set("listNode",A);y.append(A);B.addClass(this.getClassName("input")).setAttrs({"aria-autocomplete":c,"aria-expanded":false,"aria-owns":A.get("id"),role:"combobox"});x.append(C);if(h){z.plug(b.Plugin.Shim);}z.setStyle("position","absolute");this._ariaNode=C;this._boundingBox=z;this._contentBox=y;this._listNode=A;this._parentNode=x;},syncUI:function(){this._syncResults();this._syncVisibility();},hide:function(){return this.get(k)?this:this.set(q,false);},selectItem:function(y,x){if(y){if(!y.hasClass(this[s])){return this;}}else{y=this.get(f);if(!y){return this;}}this.fire(n,{itemNode:y,originEvent:x||null,result:y.getData(w)});return this;},_activateNextItem:function(){var y=this.get(f),x;if(y){x=y.next(this[u])||(this.get(o)?null:y);}else{x=this._getFirstItemNode();}this.set(f,x);return this;},_activatePrevItem:function(){var y=this.get(f),x=y?y.previous(this[u]):this.get(o)&&this._getLastItemNode();this.set(f,x||null);return this;},_add:function(x){var y=[];l.each(i.isArray(x)?x:[x],function(z){y.push(this._createItemNode(z).setData(w,z));
+},this);y=b.all(y);this._listNode.append(y.toFrag());return y;},_ariaSay:function(z,x){var y=this.get("strings."+z);this._ariaNode.setContent(x?i.sub(y,x):y);},_bindInput:function(){var A=this._inputNode,y,z,x;if(this.get("align")===null){x=this.get("tokenInput");y=(x&&x.get("boundingBox"))||A;this.set("align",{node:y,points:["tl","bl"]});if(!this.get(g)&&(z=y.get("offsetWidth"))){this.set(g,z);}}this._listEvents.push(A.on("blur",this._onListInputBlur,this));},_bindList:function(){this._listEvents.concat([b.on("windowresize",this._syncPosition,this),this.after({mouseover:this._afterMouseOver,mouseout:this._afterMouseOut,activeItemChange:this._afterActiveItemChange,alwaysShowListChange:this._afterAlwaysShowListChange,hoveredItemChange:this._afterHoveredItemChange,resultsChange:this._afterResultsChange,visibleChange:this._afterVisibleChange}),this._listNode.delegate("click",this._onItemClick,this[u],this)]);},_clear:function(){this.set(f,null);this._set(r,null);this._listNode.get("children").remove(true);},_createAriaNode:function(){var x=v.create(this.ARIA_TEMPLATE);return x.addClass(this.getClassName("aria")).setAttrs({"aria-live":"polite",role:"status"});},_createItemNode:function(x){var y=v.create(this.ITEM_TEMPLATE);return y.addClass(this[s]).setAttrs({id:b.stamp(y),role:"option"}).setAttribute("data-text",x.text).append(x.display);},_createListNode:function(){var x=v.create(this.LIST_TEMPLATE);return x.addClass(this.getClassName(c)).setAttrs({id:b.stamp(x),role:"listbox"});},_getFirstItemNode:function(){return this._listNode.one(this[u]);},_getLastItemNode:function(){return this._listNode.one(this[u]+":last-child");},_syncPosition:function(){this._syncUIPosAlign();this._syncShim();},_syncResults:function(x){if(!x){x=this.get(j);}this._clear();if(x.length){this._add(x);this._ariaSay("items_available");}this._syncPosition();if(this.get("activateFirstItem")&&!this.get(f)){this.set(f,this._getFirstItemNode());}},_syncShim:h?function(){this._boundingBox.shim.sync();}:function(){},_syncVisibility:function(x){if(this.get(k)){x=true;this.set(q,x);}if(typeof x==="undefined"){x=this.get(q);}this._inputNode.set("aria-expanded",x);this._boundingBox.set("aria-hidden",!x);if(x){this._syncPosition();}else{this.set(f,null);this._set(r,null);this._boundingBox.get("offsetWidth");}},_afterActiveItemChange:function(z){var y=this._inputNode,x=z.newVal,A=z.prevVal;if(A&&A._node){A.removeClass(this[t]);}if(x){x.addClass(this[t]);y.set("aria-activedescendant",x.get(m));}else{y.removeAttribute("aria-activedescendant");}if(this.get("scrollIntoView")){(x||y).scrollIntoView();}},_afterAlwaysShowListChange:function(x){this.set(q,x.newVal||this.get(j).length>0);},_afterHoveredItemChange:function(y){var x=y.newVal,z=y.prevVal;if(z){z.removeClass(this[d]);}if(x){x.addClass(this[d]);}},_afterMouseOver:function(x){var y=x.domEvent.target.ancestor(this[u],true);this._mouseOverList=true;if(y){this._set(r,y);}},_afterMouseOut:function(){this._mouseOverList=false;this._set(r,null);},_afterResultsChange:function(x){this._syncResults(x.newVal);if(!this.get(k)){this.set(q,!!x.newVal.length);}},_afterVisibleChange:function(x){this._syncVisibility(!!x.newVal);},_onListInputBlur:function(x){if(!this._mouseOverList||this._lastInputKey===p){this.hide();}},_onItemClick:function(x){var y=x.currentTarget;this.set(f,y);this.selectItem(y,x);},_defSelectFn:function(x){var y=x.result.text;this._inputNode.focus();this._updateValue(y);this._ariaSay("item_selected",{item:y});this.hide();}},{ATTRS:{activateFirstItem:{value:false},activeItem:{setter:b.one,value:null},alwaysShowList:{value:false},circular:{value:true},hoveredItem:{readOnly:true,value:null},listNode:{readOnly:true,value:null},scrollIntoView:{value:false},strings:{valueFn:function(){return b.Intl.get("autocomplete-list");}},tabSelect:{value:true},visible:{value:false}},CSS_PREFIX:b.ClassNameManager.getClassName("aclist")});b.AutoCompleteList=a;b.AutoComplete=a;},"@VERSION@",{requires:["autocomplete-base","event-resize","selector-css3","shim-plugin","widget","widget-position","widget-position-align"],after:["autocomplete-sources"],lang:["en"],skinnable:true});YUI.add("autocomplete-plugin",function(b){var a=b.Plugin;function c(d){d.inputNode=d.host;if(!d.render&&d.render!==false){d.render=true;}c.superclass.constructor.apply(this,arguments);}b.extend(c,b.AutoCompleteList,{},{NAME:"autocompleteListPlugin",NS:"ac",CSS_PREFIX:b.ClassNameManager.getClassName("aclist")});a.AutoComplete=c;a.AutoCompleteList=c;},"@VERSION@",{requires:["autocomplete-list","node-pluginhost"]});YUI.add("autocomplete",function(a){},"@VERSION@",{use:["autocomplete-base","autocomplete-sources","autocomplete-list","autocomplete-plugin"]});
\ No newline at end of file
diff --git a/build/autocomplete/autocomplete.js b/build/autocomplete/autocomplete.js
index 60b3f5ec314..f485388811c 100644
--- a/build/autocomplete/autocomplete.js
+++ b/build/autocomplete/autocomplete.js
@@ -1621,7 +1621,7 @@ AutoCompleteBase.prototype = {
Y.AutoCompleteBase = AutoCompleteBase;
-}, '@VERSION@' ,{requires:['array-extras', 'base-build', 'escape', 'event-valuechange', 'node-base'], optional:['autocomplete-sources']});
+}, '@VERSION@' ,{optional:['autocomplete-sources'], requires:['array-extras', 'base-build', 'escape', 'event-valuechange', 'node-base']});
YUI.add('autocomplete-sources', function(Y) {
/**
@@ -2101,7 +2101,7 @@ Y.mix(ACBase.SOURCE_TYPES, {
}, true);
-}, '@VERSION@' ,{requires:['autocomplete-base'], optional:['io-base', 'json-parse', 'jsonp', 'yql']});
+}, '@VERSION@' ,{optional:['io-base', 'json-parse', 'jsonp', 'yql'], requires:['autocomplete-base']});
YUI.add('autocomplete-list', function(Y) {
/**
@@ -2934,7 +2934,7 @@ Y.AutoCompleteList = List;
Y.AutoComplete = List;
-}, '@VERSION@' ,{after:['autocomplete-sources'], lang:['en'], skinnable:true, requires:['autocomplete-base', 'event-resize', 'selector-css3', 'shim-plugin', 'widget', 'widget-position', 'widget-position-align']});
+}, '@VERSION@' ,{requires:['autocomplete-base', 'event-resize', 'selector-css3', 'shim-plugin', 'widget', 'widget-position', 'widget-position-align'], after:['autocomplete-sources'], lang:['en'], skinnable:true});
YUI.add('autocomplete-plugin', function(Y) {
/**
diff --git a/build/controller/controller-debug.js b/build/controller/controller-debug.js
index fed5ca744c5..9ff16a28721 100644
--- a/build/controller/controller-debug.js
+++ b/build/controller/controller-debug.js
@@ -21,8 +21,10 @@ URLs.
@uses Base
**/
-var YArray = Y.Array,
- QS = Y.QueryString,
+var HistoryHash = Y.HistoryHash,
+ Lang = Y.Lang,
+ QS = Y.QueryString,
+ YArray = Y.Array,
// Android versions lower than 3.0 are buggy and don't update
// window.location after a pushState() call, so we fall back to hash-based
@@ -30,7 +32,22 @@ var YArray = Y.Array,
//
// See http://code.google.com/p/android/issues/detail?id=17471
html5 = Y.HistoryBase.html5 && (!Y.UA.android || Y.UA.android >= 3),
- location = Y.config.win.location;
+ win = Y.config.win,
+ location = win.location,
+
+ /**
+ Fired when the controller is ready to begin dispatching to route handlers.
+
+ You shouldn't need to wait for this event unless you plan to implement some
+ kind of custom dispatching logic. It's used internally in order to avoid
+ dispatching to an initial route if a browser history change occurs first.
+
+ @event ready
+ @param {Boolean} dispatched `true` if routes have already been dispatched
+ (most likely due to a history change).
+ @fireOnce
+ **/
+ EVT_READY = 'ready';
function Controller() {
Controller.superclass.constructor.apply(this, arguments);
@@ -40,23 +57,45 @@ Y.Controller = Y.extend(Controller, Y.Base, {
// -- Public Properties ----------------------------------------------------
/**
- Base path or URL from which all routes should be evaluated.
+ If `true`, the controller will dispatch to the first route handler that
+ matches the current URL immediately after the controller is initialized,
+ even if there was no browser history change to trigger a dispatch.
+
+ If you're rendering the initial pageview on the server, then you'll probably
+ want this to be `false`, but if you're doing all your rendering and route
+ handling entirely on the client, then setting this to `true` will allow your
+ client-side routes to handle the initial request of all pageviews without
+ depending on any server-side handling.
+
+ This property defaults to `false` for HTML5 browsers, `true` for browsers
+ that rely on hash-based history (since the hash is never sent to the
+ server).
+
+ @property dispatchOnInit
+ @type Boolean
+ @default `false` for HTML5 browsers, `true` for hash-based browsers
+ **/
+ dispatchOnInit: !html5,
+
+ /**
+ Root path from which all routes should be evaluated.
For example, if your controller is running on a page at
`http://example.com/myapp/` and you add a route with the path `/`, your
route will never execute, because the path will always be preceded by
- `/myapp`. Setting _base_ to `/myapp` would cause all routes to be evaluated
- relative to that base path, so the `/` route would then execute.
+ `/myapp`. Setting `root` to `/myapp` would cause all routes to be evaluated
+ relative to that root URL, so the `/` route would then execute when the
+ user browses to `http://example.com/myapp/`.
This property may be overridden in a subclass, set after instantiation, or
passed as a config attribute when instantiating a `Y.Controller`-based
class.
- @property base
+ @property root
@type String
@default `''`
**/
- base : '',
+ root: '',
/**
Array of route objects specifying routes to be created at instantiation
@@ -85,6 +124,34 @@ Y.Controller = Y.extend(Controller, Y.Base, {
// -- Protected Properties -------------------------------------------------
+ /**
+ Whether or not `_dispatch()` has been called since this controller was
+ instantiated.
+
+ @property _dispatched
+ @type Boolean
+ @default undefined
+ @protected
+ **/
+
+ /**
+ Whether or not this browser is capable of using HTML5 history.
+
+ @property _html5
+ @type Boolean
+ @protected
+ **/
+ _html5: html5,
+
+ /**
+ Whether or not the `ready` event has fired yet.
+
+ @property _ready
+ @type Boolean
+ @default undefined
+ @protected
+ **/
+
/**
Regex used to match parameter placeholders in route paths.
@@ -109,31 +176,58 @@ Y.Controller = Y.extend(Controller, Y.Base, {
@type RegExp
@protected
**/
- _regexUrlQuery : /\?([^#]*).*$/,
+ _regexUrlQuery: /\?([^#]*).*$/,
// -- Lifecycle Methods ----------------------------------------------------
initializer: function (config) {
+ var self = this;
+
+ // Set config properties.
config || (config = {});
- this._routes = [];
+ config.routes && (self.routes = config.routes);
- config.base && (this.base = config.base);
- config.routes && (this.routes = config.routes);
+ Lang.isValue(config.root) && (self.root = config.root);
+ Lang.isValue(config.dispatchOnInit) &&
+ (self.dispatchOnInit = config.dispatchOnInit);
- YArray.each(this.routes, function (route) {
- this.route(route.path, route.callback, true);
- }, this);
+ // Create routes.
+ self._routes = [];
- // Set up a history instance.
- this._history = html5 ? new Y.HistoryHTML5() : new Y.HistoryHash();
- this._history.after('change', this._afterHistoryChange, this);
+ YArray.each(self.routes, function (route) {
+ self.route(route.path, route.callback, true);
+ });
- // Handle the initial route.
- this._dispatch(this._getPath(), this._getState());
+ // Set up a history instance or hashchange listener.
+ if (html5) {
+ self._history = new Y.HistoryHTML5({force: true});
+ self._history.after('change', self._afterHistoryChange, self);
+ } else {
+ Y.on('hashchange', self._afterHistoryChange, win, self);
+ }
+
+ // Fire a 'ready' event once we're ready to route. We wait first for all
+ // subclass initializers to finish, and then an additional 20ms to allow
+ // the browser to fire an initial `popstate` event if it wants to.
+ self.publish(EVT_READY, {
+ defaultFn : self._defReadyFn,
+ fireOnce : true,
+ preventable: false
+ });
+
+ self.once('initializedChange', function () {
+ setTimeout(function () {
+ self.fire(EVT_READY, {dispatched: !!self._dispatched});
+ }, 20);
+ });
},
destructor: function () {
- this._history.detachAll();
+ if (html5) {
+ this._history.detachAll();
+ } else {
+ Y.detach('hashchange', this._afterHistoryChange, win);
+ }
},
// -- Public Methods -------------------------------------------------------
@@ -177,7 +271,7 @@ Y.Controller = Y.extend(Controller, Y.Base, {
Behind the scenes, this method uses HTML5 `pushState()` in browsers that
support it (or the location hash in older browsers and IE) to change the
- URL and create a history entry for the given state.
+ URL.
The specified URL must share the same origin (i.e., protocol, host, and
port) as the current page, or an error will occur.
@@ -185,25 +279,24 @@ Y.Controller = Y.extend(Controller, Y.Base, {
@example
// Starting URL: http://example.com/
- controller.replace('/bar/', 'You are now at /bar/', {bar: true});
- // New URL: http://example.com/bar/
+ controller.replace('/path/');
+ // New URL: http://example.com/path/
+
+ controller.replace('/path?foo=bar');
+ // New URL: http://example.com/path?foo=bar
- controller.replace('/', 'You are now at example.com');
+ controller.replace('/');
// New URL: http://example.com/
@method replace
- @param {String} [url] URL to set. May be relative or absolute, but if a
- `base` property is specified, this URL must be relative to that property.
- If not specified, the page's current URL will be used.
- @param {String} [title] Page title to set. If not specified, the page's
- current title will be used.
- @param {Object} [state] State object to associate with this history entry.
- May be any object that can be serialized to JSON.
+ @param {String} [url] URL to set. Should be a relative URL. If this
+ controller's `root` property is set, this URL must be relative to the
+ root URL. If no URL is specified, the page's current URL will be used.
@chainable
@see save()
**/
- replace: function (url, title, state) {
- return this._save(url, title, state, true);
+ replace: function (url) {
+ return this._save(url, true);
},
/**
@@ -258,8 +351,6 @@ Y.Controller = Y.extend(Controller, Y.Base, {
@param {Object} callback.req.query Query hash representing the URL query
string, if any. Parameter names are keys, and are mapped to parameter
values.
- @param {Object} callback.req.state State object associated with this
- URL, if any.
@param {Function} callback.next Callback to pass control to the next
matching route. If you don't call this function, then no further route
handlers will be executed, even if there are more that match. If you do
@@ -288,7 +379,7 @@ Y.Controller = Y.extend(Controller, Y.Base, {
Behind the scenes, this method uses HTML5 `pushState()` in browsers that
support it (or the location hash in older browsers and IE) to change the
- URL and create a history entry for the given state.
+ URL and create a history entry.
The specified URL must share the same origin (i.e., protocol, host, and
port) as the current page, or an error will occur.
@@ -296,25 +387,24 @@ Y.Controller = Y.extend(Controller, Y.Base, {
@example
// Starting URL: http://example.com/
- controller.save('/bar/', 'You are now at /bar/', {bar: true});
- // New URL: http://example.com/bar/
+ controller.save('/path/');
+ // New URL: http://example.com/path/
- controller.save('/', 'You are now at example.com');
+ controller.save('/path?foo=bar');
+ // New URL: http://example.com/path?foo=bar
+
+ controller.save('/');
// New URL: http://example.com/
@method save
- @param {String} [url] URL to set. May be relative or absolute, but if a
- `base` property is specified, this URL must be relative to that property.
- If not specified, the page's current URL will be used.
- @param {String} [title] Page title to set. If not specified, the page's
- current title will be used.
- @param {Object} [state] State object to associate with this history entry.
- May be any object that can be serialized to JSON.
+ @param {String} [url] URL to set. Should be a relative URL. If this
+ controller's `root` property is set, this URL must be relative to the
+ root URL. If no URL is specified, the page's current URL will be used.
@chainable
@see replace()
**/
- save: function (url, title, state) {
- return this._save(url, title, state);
+ save: function (url) {
+ return this._save(url);
},
// -- Protected Methods ----------------------------------------------------
@@ -335,24 +425,29 @@ Y.Controller = Y.extend(Controller, Y.Base, {
/**
Dispatches to the first route handler that matches the specified _path_.
+ If called before the `ready` event has fired, the dispatch will be aborted.
+ This ensures normalized behavior between Chrome (which fires a `popstate`
+ event on every pageview) and other browsers (which do not).
+
@method _dispatch
@param {String} path URL path.
- @param {Object} state State to pass to route handlers.
@protected
**/
- _dispatch: function (path, state) {
- var routes = this.match(path),
- req, route, self;
+ _dispatch: function (path) {
+ var self = this,
+ routes = self.match(path),
+ req;
+
+ self._dispatched = true;
if (!routes || !routes.length) {
return;
}
- req = this._getRequest(path, state);
- self = this;
+ req = self._getRequest(path);
function next(err) {
- var callback, matches;
+ var callback, matches, route;
if (err) {
Y.error(err);
@@ -380,6 +475,18 @@ Y.Controller = Y.extend(Controller, Y.Base, {
next();
},
+ /**
+ Gets the current path from the location hash, or an empty string if the
+ hash is empty.
+
+ @method _getHashPath
+ @return {String} Current hash path, or an empty string if the hash is empty.
+ @protected
+ **/
+ _getHashPath: function () {
+ return HistoryHash.getHash().replace(this._regexUrlQuery, '');
+ },
+
/**
Gets the current route path.
@@ -388,16 +495,9 @@ Y.Controller = Y.extend(Controller, Y.Base, {
@protected
**/
_getPath: html5 ? function () {
- var base = this.base,
- path = location.pathname;
-
- if (base && path.indexOf(base) === 0) {
- path = path.substring(base.length);
- }
-
- return path;
+ return this._removeRoot(location.pathname);
} : function () {
- return this._history.get('path') || this.base + location.pathname;
+ return this._getHashPath() || this._removeRoot(location.pathname);
},
/**
@@ -410,12 +510,15 @@ Y.Controller = Y.extend(Controller, Y.Base, {
_getQuery: html5 ? function () {
return location.search.substring(1);
} : function () {
- return this._history.get('query') || location.search.substring(1);
+ var hash = HistoryHash.getHash(),
+ matches = hash.match(this._regexUrlQuery);
+
+ return hash && matches ? matches[1] : location.search.substring(1);
},
/**
- Creates a regular expression from the specified route specification. If
- _path_ is already a regex, it will be returned unmodified.
+ Creates a regular expression from the given route specification. If _path_
+ is already a regex, it will be returned unmodified.
@method _getRegex
@param {String|RegExp} path Route path specification.
@@ -442,30 +545,44 @@ Y.Controller = Y.extend(Controller, Y.Base, {
@method _getRequest
@param {String} path Current path being dispatched.
- @param {Object} state Current state.
@return {Object} Request object.
@protected
**/
- _getRequest: function (path, state) {
+ _getRequest: function (path) {
return {
path : path,
- query: this._parseQuery(this._getQuery()),
- state: state
+ query: this._parseQuery(this._getQuery())
};
},
/**
- Gets the current state, if any.
+ Joins the `root` URL to the specified _url_, normalizing leading/trailing
+ `/` characters.
- @method _getState
- @return {Object} Current state.
+ @example
+ controller.root = '/foo'
+ controller._joinURL('bar'); // => '/foo/bar'
+ controller._joinURL('/bar'); // => '/foo/bar'
+
+ controller.root = '/foo/'
+ controller._joinURL('bar'); // => '/foo/bar'
+ controller._joinURL('/bar'); // => '/foo/bar'
+
+ @method _joinURL
+ @param {String} url URL to append to the `root` URL.
+ @return {String} Joined URL.
@protected
**/
- _getState: html5 ? function () {
- return this._history.get();
- } : function () {
- var jsonState = this._history.get('state');
- return jsonState ? Y.JSON.parse(jsonState) : {};
+ _joinURL: function (url) {
+ var root = this.root;
+
+ if (url.charAt(0) === '/') {
+ url = url.substring(1);
+ }
+
+ return root && root.charAt(root.length - 1) === '/' ?
+ root + url :
+ root + '/' + url;
},
/**
@@ -496,58 +613,59 @@ Y.Controller = Y.extend(Controller, Y.Base, {
return result;
},
+ /**
+ Removes the `root` URL from the from of _path_ (if it's there) and returns
+ the result. The returned path will always have a leading `/`.
+
+ @method _removeRoot
+ @param {String} path URL path.
+ @return {String} Rootless path.
+ @protected
+ **/
+ _removeRoot: function (path) {
+ var root = this.root;
+
+ if (root && path.indexOf(root) === 0) {
+ path = path.substring(root.length);
+ }
+
+ return path.charAt(0) === '/' ? path : '/' + path;
+ },
+
/**
Saves a history entry using either `pushState()` or the location hash.
@method _save
@param {String} [url] URL for the history entry.
- @param {String} [title] Page title associated with the history entry.
- @param {Object} [state] State object associated with the history entry.
@param {Boolean} [replace=false] If `true`, the current history entry will
be replaced instead of a new one being added.
@chainable
@protected
**/
- _save: function (url, title, state, replace) {
- var jsonState, query;
+ _save: html5 ? function (url, replace) {
+ // Force _ready to true to ensure that the history change is handled
+ // even if _save is called before the `ready` event fires.
+ this._ready = true;
- if (html5) {
- if (typeof url === 'string') {
- url = this.base + url;
- }
- } else {
- // If we're not using HTML5 history, take over the history state for
- // our own purposes and shove the implementer's state inside it as a
- // JSON string.
- jsonState = state && Y.JSON.stringify(state);
-
- // Extract a query string from the URL if there is one, then remove
- // both the query and the hash portions of the URL so we can store
- // just the path.
- url = url.replace(this._regexUrlQuery, function (match, params) {
- query = params;
- return '';
- });
-
- state = {path: url || this._getPath()};
-
- query && (state.query = query);
- jsonState && (state.state = jsonState);
- }
-
- this._history[replace ? 'replace' : 'add'](state || {}, {
- merge: false,
- title: title,
- url : url
+ this._history[replace ? 'replace' : 'add'](null, {
+ url: typeof url === 'string' ? this._joinURL(url) : url
});
+ return this;
+ } : function (url, replace) {
+ this._ready = true;
+ if (typeof url === 'string' && url.charAt(0) !== '/') {
+ url = '/' + url;
+ }
+
+ HistoryHash[replace ? 'replaceHash' : 'setHash'](url);
return this;
},
// -- Protected Event Handlers ---------------------------------------------
/**
- Handles `history:change` events.
+ Handles `history:change` and `hashchange` events.
@method _afterHistoryChange
@param {EventFacade} e
@@ -556,15 +674,45 @@ Y.Controller = Y.extend(Controller, Y.Base, {
_afterHistoryChange: function (e) {
var self = this;
- // We need to yield control to the UI thread to allow the browser to
- // update document.location before we dispatch.
- setTimeout(function () {
- self._dispatch(self._getPath(), self._getState());
- }, 1);
+ if (self._ready) {
+ // We need to yield control to the UI thread to allow the browser to
+ // update window.location before we dispatch.
+ setTimeout(function () {
+ self._dispatch(self._getPath());
+ }, 1);
+ }
+ },
+
+ // -- Default Event Handlers -----------------------------------------------
+
+ /**
+ Default handler for the `ready` event.
+
+ @method _defReadyFn
+ @param {EventFacade} e
+ @protected
+ **/
+ _defReadyFn: function (e) {
+ var hash;
+
+ this._ready = true;
+
+ if (this.dispatchOnInit && !this._dispatched) {
+ if (html5 && (hash = this._getHashPath())
+ && hash.charAt(0) === '/') {
+
+ // This is an HTML5 browser and we have a hash-based path in the
+ // URL, so we need to upgrade the URL to a non-hash URL. This
+ // will trigger a `history:change` event.
+ this._history.replace(null, {url: this._joinURL(hash)});
+ } else {
+ this._dispatch(this._getPath());
+ }
+ }
}
}, {
NAME: 'controller'
});
-}, '@VERSION@' ,{optional:['querystring-parse'], requires:['array-extras', 'base-build', 'history', 'json']});
+}, '@VERSION@' ,{requires:['array-extras', 'base-build', 'history'], optional:['querystring-parse']});
diff --git a/build/controller/controller-min.js b/build/controller/controller-min.js
index 7a06b667c02..f3523e17d57 100644
--- a/build/controller/controller-min.js
+++ b/build/controller/controller-min.js
@@ -1 +1 @@
-YUI.add("controller",function(f){var d=f.Array,b=f.QueryString,c=f.HistoryBase.html5&&(!f.UA.android||f.UA.android>=3),a=f.config.win.location;function e(){e.superclass.constructor.apply(this,arguments);}f.Controller=f.extend(e,f.Base,{base:"",routes:[],_regexPathParam:/([:*])([\w\d-]+)/g,_regexUrlQuery:/\?([^#]*).*$/,initializer:function(g){g||(g={});this._routes=[];g.base&&(this.base=g.base);g.routes&&(this.routes=g.routes);d.each(this.routes,function(h){this.route(h.path,h.callback,true);},this);this._history=c?new f.HistoryHTML5():new f.HistoryHash();this._history.after("change",this._afterHistoryChange,this);this._dispatch(this._getPath(),this._getState());},destructor:function(){this._history.detachAll();},match:function(g){return d.filter(this._routes,function(h){return g.search(h.regex)>-1;});},replace:function(g,i,h){return this._save(g,i,h,true);},route:function(h,i){var g=[];this._routes.push({callback:i,keys:g,path:h,regex:this._getRegex(h,g)});return this;},save:function(g,i,h){return this._save(g,i,h);},_decode:function(g){return decodeURIComponent(g.replace(/\+/g," "));},_dispatch:function(m,l){var g=this.match(m),k,i,h;if(!g||!g.length){return;}k=this._getRequest(m,l);h=this;function j(n){var p,o;if(n){f.error(n);}else{if((i=g.shift())){o=i.regex.exec(m);p=typeof i.callback==="string"?h[i.callback]:i.callback;if(o.length===i.keys.length+1){k.params=d.hash(i.keys,o.slice(1));}else{k.params={};d.each(o,function(r,q){k.params[q]=r;});}p.call(h,k,j);}}}j();},_getPath:c?function(){var g=this.base,h=a.pathname;if(g&&h.indexOf(g)===0){h=h.substring(g.length);}return h;}:function(){return this._history.get("path")||this.base+a.pathname;},_getQuery:c?function(){return a.search.substring(1);}:function(){return this._history.get("query")||a.search.substring(1);},_getRegex:function(h,g){if(h instanceof RegExp){return h;}h=h.replace(this._regexPathParam,function(j,i,k){g.push(k);return i==="*"?"(.*?)":"([^/]*)";});return new RegExp("^"+h+"$");},_getRequest:function(h,g){return{path:h,query:this._parseQuery(this._getQuery()),state:g};},_getState:c?function(){return this._history.get();}:function(){var g=this._history.get("state");return g?f.JSON.parse(g):{};},_parseQuery:b&&b.parse?b.parse:function(k){var l=this._decode,n=k.split("&"),j=0,h=n.length,g={},m;for(;j
",x="
',G='',a=' ',j="{value}",n='';function m(L){m.superclass.constructor.apply(this,arguments);}c.mix(m,{NAME:"column",ATTRS:{id:{valueFn:"_defaultId",readOnly:true},key:{valueFn:"_defaultKey"},field:{valueFn:"_defaultField"},label:{valueFn:"_defaultLabel"},children:{value:null},abbr:{value:""},classnames:{readOnly:true,getter:"_getClassnames"},formatter:{},sortable:{value:false},editor:{},width:{},resizeable:{},minimized:{},minWidth:{},maxAutoWidth:{}}});c.extend(m,c.Widget,{_defaultId:function(){return c.guid();},_defaultKey:function(L){return L||c.guid();},_defaultField:function(L){return L||this.get("key");},_defaultLabel:function(L){return L||this.get("key");},_afterAbbrChange:function(L){this._uiSetAbbr(L.newVal);},keyIndex:null,headers:null,colSpan:1,rowSpan:1,parent:null,thNode:null,initializer:function(L){},destructor:function(){},_getClassnames:function(){return c.ClassNameManager.getClassName(r,this.get("id"));},syncUI:function(){this._uiSetAbbr(this.get("abbr"));},_uiSetAbbr:function(L){this.thNode.set("abbr",L);}});c.Column=m;function y(L){y.superclass.constructor.apply(this,arguments);}c.mix(y,{NAME:"columnset",ATTRS:{definitions:{setter:"_setDefinitions"}}});c.extend(y,c.Base,{_setDefinitions:function(L){return c.clone(L);},tree:null,idHash:null,keyHash:null,keys:null,initializer:function(){var L=[],Q={},R={},P=[],O=this.get("definitions"),M=this;function N(Z,Y,X){var U=0,T=Y.length,W,V,S;Z++;if(!L[Z]){L[Z]=[];}for(;U";function n(){n.superclass.constructor.apply(this,arguments);}b.mix(n,{NS:"scroll",NAME:"dataTableScroll",ATTRS:{width:{value:undefined,writeOnce:"initOnly"},height:{value:undefined,writeOnce:"initOnly"},_scroll:{valueFn:function(){var o=this.get("width"),p=this.get("height");if(o&&p){return"xy";}else{if(o){return"x";}else{if(p){return"y";}else{return null;}}}}},COLOR_COLUMNFILLER:{value:"#f2f2f2",validator:j.isString,setter:function(o){if(this._headerContainerNode){this._headerContainerNode.setStyle("backgroundColor",o);}}}}});b.extend(n,b.Plugin.Base,{_parentTableNode:null,_parentTheadNode:null,_parentTbodyNode:null,_parentMsgNode:null,_parentContainer:null,_bodyContainerNode:null,_headerContainerNode:null,initializer:function(o){var p=this.get("host");this._parentContainer=p.get("contentBox");this._parentContainer.addClass(i);this._setUpNodes();},_setUpNodes:function(){this.afterHostMethod("_addTableNode",this._setUpParentTableNode);this.afterHostMethod("_addTheadNode",this._setUpParentTheadNode);this.afterHostMethod("_addTbodyNode",this._setUpParentTbodyNode);this.afterHostMethod("_addMessageNode",this._setUpParentMessageNode);this.afterHostMethod("renderUI",this.renderUI);this.afterHostMethod("syncUI",this.syncUI);if(this.get("_scroll")!=="x"){this.afterHostMethod("_attachTheadThNode",this._attachTheadThNode);this.afterHostMethod("_attachTbodyTdNode",this._attachTbodyTdNode);}},_setUpParentTableNode:function(){this._parentTableNode=this.get("host")._tableNode;},_setUpParentTheadNode:function(){this._parentTheadNode=this.get("host")._theadNode;},_setUpParentTbodyNode:function(){this._parentTbodyNode=this.get("host")._tbodyNode;},_setUpParentMessageNode:function(){this._parentMsgNode=this.get("host")._msgNode;},renderUI:function(){this._createBodyContainer();this._createHeaderContainer();this._setContentBoxDimensions();},syncUI:function(){this._removeCaptionNode();this._syncWidths();this._syncScroll();},_removeCaptionNode:function(){this.get("host")._captionNode.remove();},_syncWidths:function(){var p=k.all("#"+this._parentContainer.get("id")+" ."+a+" table thead th"),q=k.one("#"+this._parentContainer.get("id")+" ."+e+" table ."+d).get("firstChild").get("children"),r,u,w,t,v,s,o=m.ie;for(r=0,u=p.size();rt){s.setStyle("width",(w-20+"px"));}else{if(t>w){v.setStyle("width",(t-20+"px"));s.setStyle("width",(t-20+"px"));}}}},_attachTheadThNode:function(q){var p=q.column.get("width")||"auto";if(p!=="auto"){q.th.get("firstChild").setStyles({width:p,overflow:"hidden"});}return q;},_attachTbodyTdNode:function(q){var p=q.column.get("width")||"auto";if(p!=="auto"){q.td.get("firstChild").setStyles({width:p,overflow:"hidden"});}return q;},_createBodyContainer:function(){var p=k.create(c),o=b.bind("_onScroll",this);this._bodyContainerNode=p;this._setStylesForTbody();p.appendChild(this._parentTableNode);this._parentContainer.appendChild(p);p.on("scroll",o);},_createHeaderContainer:function(){var p=k.create(h),o=k.create(g);this._headerContainerNode=p;this._setStylesForThead();o.appendChild(this._parentTheadNode);p.appendChild(o);this._parentContainer.prepend(p);},_setStylesForTbody:function(){var p=this.get("_scroll"),o=this.get("width")||"",r=this.get("height")||"",q=this._bodyContainerNode,s={width:"",height:r};if(p==="x"){s.overflowY="hidden";s.width=o;}else{if(p==="y"){s.overflowX="hidden";}else{if(p==="xy"){s.width=o;}else{s.overflowX="hidden";s.overflowY="hidden";s.width=o;}}}q.setStyles(s);return q;},_setStylesForThead:function(){var o=this.get("width")||"",p=this._headerContainerNode;p.setStyles({"width":o,"overflow":"hidden"});},_setContentBoxDimensions:function(){if(this.get("_scroll")==="y"||(!this.get("width"))){this._parentContainer.setStyle("width","auto");}},_onScroll:function(){this._headerContainerNode.set("scrollLeft",this._bodyContainerNode.get("scrollLeft"));},_syncScroll:function(){this._syncScrollX();this._syncScrollY();this._syncScrollOverhang();if(m.opera){this._headerContainerNode.set("scrollLeft",this._bodyContainerNode.get("scrollLeft"));if(!this.get("width")){document.body.style+="";
+}else{return{key:i.key,dir:"asc",notdir:"desc"};}}else{return null;}}},_uiSetLastSortedBy:function(m,j,i){var u=m&&m.key,n=m&&m.dir,t=j&&j.key,k=j&&j.dir,q=i.get("columnset"),s=q.keyHash[u],o=q.keyHash[t],r=i._tbodyNode,l,p;if(s){s.thNode.removeClass(f(h,n));l=r.all("."+f(b,s.get("id")));l.removeClass(f(h,n));}if(o){o.thNode.addClass(f(h,k));p=r.all("."+f(b,o.get("id")));p.addClass(f(h,k));}},_beforeCreateTheadThNode:function(i){if(i.column.get("sortable")){i.value=g.substitute(this.get("template"),{link_class:i.link_class||"",link_title:"title",link_href:"#",value:i.value});}},_beforeAttachTheadThNode:function(m){var l=this.get("lastSortedBy"),k=l&&l.key,i=l&&l.dir,j=l&&l.notdir;if(m.column.get("sortable")){m.th.addClass(f(h,"sortable"));}if(k&&(k===m.column.get("key"))){m.th.replaceClass(f(h,j),f(h,i));}},_beforeAttachTbodyTdNode:function(m){var l=this.get("lastSortedBy"),k=l&&l.key,i=l&&l.dir,j=l&&l.notdir;if(m.column.get("sortable")){m.td.addClass(f(h,"sortable"));}if(k&&(k===m.column.get("key"))){m.td.replaceClass(f(h,j),f(h,i));}},_onEventSortColumn:function(n){n.halt();var l=this.get("host"),k=l.get("columnset").idHash[n.currentTarget.get("id")],j=k.get("key"),m=k.get("field"),o=this.get("lastSortedBy"),i=(o&&o.key===j&&o.dir===d)?c:d,p=k.get("sortFn");if(k.get("sortable")){l.get("recordset").sort.sort(m,i===c,p);this.set("lastSortedBy",{key:j,dir:i});}}});g.namespace("Plugin").DataTableSort=e;},"@VERSION@",{requires:["datatable-base","plugin","recordset-sort"],lang:["en"]});YUI.add("datatable-scroll",function(b){var k=b.Node,j=b.Lang,m=b.UA,f=b.ClassNameManager.getClassName,l="datatable",a=f(l,"hd"),e=f(l,"bd"),d=f(l,"data"),i=f(l,"scrollable"),h='',c='',g="
";function n(){n.superclass.constructor.apply(this,arguments);}b.mix(n,{NS:"scroll",NAME:"dataTableScroll",ATTRS:{width:{value:undefined,writeOnce:"initOnly"},height:{value:undefined,writeOnce:"initOnly"},_scroll:{valueFn:function(){var o=this.get("width"),p=this.get("height");if(o&&p){return"xy";}else{if(o){return"x";}else{if(p){return"y";}else{return null;}}}}},COLOR_COLUMNFILLER:{value:"#f2f2f2",validator:j.isString,setter:function(o){if(this._headerContainerNode){this._headerContainerNode.setStyle("backgroundColor",o);}}}}});b.extend(n,b.Plugin.Base,{_parentTableNode:null,_parentTheadNode:null,_parentTbodyNode:null,_parentMsgNode:null,_parentContainer:null,_bodyContainerNode:null,_headerContainerNode:null,initializer:function(o){var p=this.get("host");this._parentContainer=p.get("contentBox");this._parentContainer.addClass(i);this._setUpNodes();},_setUpNodes:function(){this.afterHostMethod("_addTableNode",this._setUpParentTableNode);this.afterHostMethod("_addTheadNode",this._setUpParentTheadNode);this.afterHostMethod("_addTbodyNode",this._setUpParentTbodyNode);this.afterHostMethod("_addMessageNode",this._setUpParentMessageNode);this.afterHostMethod("renderUI",this.renderUI);this.afterHostMethod("syncUI",this.syncUI);if(this.get("_scroll")!=="x"){this.afterHostMethod("_attachTheadThNode",this._attachTheadThNode);this.afterHostMethod("_attachTbodyTdNode",this._attachTbodyTdNode);}},_setUpParentTableNode:function(){this._parentTableNode=this.get("host")._tableNode;},_setUpParentTheadNode:function(){this._parentTheadNode=this.get("host")._theadNode;},_setUpParentTbodyNode:function(){this._parentTbodyNode=this.get("host")._tbodyNode;},_setUpParentMessageNode:function(){this._parentMsgNode=this.get("host")._msgNode;},renderUI:function(){this._createBodyContainer();this._createHeaderContainer();this._setContentBoxDimensions();},syncUI:function(){this._removeCaptionNode();this._syncWidths();this._syncScroll();},_removeCaptionNode:function(){this.get("host")._captionNode.remove();},_syncWidths:function(){var p=k.all("#"+this._parentContainer.get("id")+" ."+a+" table thead th"),q=k.one("#"+this._parentContainer.get("id")+" ."+e+" table ."+d).get("firstChild").get("children"),r,u,w,t,v,s,o=m.ie;for(r=0,u=p.size();rt){s.setStyle("width",(w-20+"px"));}else{if(t>w){v.setStyle("width",(t-20+"px"));s.setStyle("width",(t-20+"px"));}}}},_attachTheadThNode:function(q){var p=q.column.get("width")||"auto";if(p!=="auto"){q.th.get("firstChild").setStyles({width:p,overflow:"hidden"});}return q;},_attachTbodyTdNode:function(q){var p=q.column.get("width")||"auto";if(p!=="auto"){q.td.get("firstChild").setStyles({width:p,overflow:"hidden"});}return q;},_createBodyContainer:function(){var p=k.create(c),o=b.bind("_onScroll",this);this._bodyContainerNode=p;this._setStylesForTbody();p.appendChild(this._parentTableNode);this._parentContainer.appendChild(p);p.on("scroll",o);},_createHeaderContainer:function(){var p=k.create(h),o=k.create(g);this._headerContainerNode=p;this._setStylesForThead();o.appendChild(this._parentTheadNode);p.appendChild(o);this._parentContainer.prepend(p);},_setStylesForTbody:function(){var p=this.get("_scroll"),o=this.get("width")||"",r=this.get("height")||"",q=this._bodyContainerNode,s={width:"",height:r};if(p==="x"){s.overflowY="hidden";s.width=o;}else{if(p==="y"){s.overflowX="hidden";}else{if(p==="xy"){s.width=o;}else{s.overflowX="hidden";s.overflowY="hidden";s.width=o;}}}q.setStyles(s);return q;},_setStylesForThead:function(){var o=this.get("width")||"",p=this._headerContainerNode;p.setStyles({"width":o,"overflow":"hidden"});},_setContentBoxDimensions:function(){if(this.get("_scroll")==="y"||(!this.get("width"))){this._parentContainer.setStyle("width","auto");}},_onScroll:function(){this._headerContainerNode.set("scrollLeft",this._bodyContainerNode.get("scrollLeft"));},_syncScroll:function(){this._syncScrollX();this._syncScrollY();this._syncScrollOverhang();if(m.opera){this._headerContainerNode.set("scrollLeft",this._bodyContainerNode.get("scrollLeft"));if(!this.get("width")){document.body.style+="";
}}},_syncScrollY:function(){var o=this._parentTbodyNode,q=this._bodyContainerNode,p;if(!this.get("width")){p=(q.get("scrollHeight")>q.get("clientHeight"))?(o.get("parentNode").get("clientWidth")+19)+"px":(o.get("parentNode").get("clientWidth")+2)+"px";this._parentContainer.setStyle("width",p);}},_syncScrollX:function(){var o=this._parentTbodyNode,q=this._bodyContainerNode,p;this._headerContainerNode.set("scrollLeft",this._bodyContainerNode.get("scrollLeft"));if(!this.get("height")&&(m.ie)){p=(q.get("scrollWidth")>q.get("offsetWidth"))?(o.get("parentNode").get("offsetHeight")+18)+"px":o.get("parentNode").get("offsetHeight")+"px";q.setStyle("height",p);}if(o.get("rows").length===0){this._parentMsgNode.get("parentNode").setStyle("width",this._parentTheadNode.get("parentNode").get("offsetWidth")+"px");}else{this._parentMsgNode.get("parentNode").setStyle("width","");}},_syncScrollOverhang:function(){var o=this._bodyContainerNode,p=1;if((o.get("scrollHeight")>o.get("clientHeight"))||(o.get("scrollWidth")>o.get("clientWidth"))){p=18;}this._setOverhangValue(p);if(m.ie!==0&&this.get("_scroll")==="y"&&this._bodyContainerNode.get("scrollHeight")>this._bodyContainerNode.get("offsetHeight")){this._headerContainerNode.setStyle("width",this._parentContainer.get("width"));}},_setOverhangValue:function(p){var r=this.get("host"),t=r.get("columnset").get("definitions"),o=t.length,s=p+"px solid "+this.get("COLOR_COLUMNFILLER"),q=k.all("#"+this._parentContainer.get("id")+" ."+a+" table thead th");q.item(o-1).setStyle("borderRight",s);}});b.namespace("Plugin").DataTableScroll=n;},"@VERSION@",{requires:["datatable-base","plugin","stylesheet"]});YUI.add("datatable",function(a){},"@VERSION@",{use:["datatable-base","datatable-datasource","datatable-sort","datatable-scroll"]});
\ No newline at end of file
diff --git a/build/datatable/datatable.js b/build/datatable/datatable.js
index aecf42f01f6..3b677fdb1e1 100644
--- a/build/datatable/datatable.js
+++ b/build/datatable/datatable.js
@@ -2127,7 +2127,7 @@ Y.namespace("Plugin").DataTableSort = DataTableSort;
-}, '@VERSION@' ,{lang:['en'], requires:['datatable-base','plugin','recordset-sort']});
+}, '@VERSION@' ,{requires:['datatable-base','plugin','recordset-sort'], lang:['en']});
YUI.add('datatable-scroll', function(Y) {
/**
diff --git a/build/datatype-date-format/datatype-date-format-debug.js b/build/datatype-date-format/datatype-date-format-debug.js
index f2ff56b54a3..3afa92dac44 100644
--- a/build/datatype-date-format/datatype-date-format-debug.js
+++ b/build/datatype-date-format/datatype-date-format-debug.js
@@ -356,7 +356,7 @@ Y.mix(Y.namespace("DataType.Date"), Dt);
*
- * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale, {
+ * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale["en"], {
* a: ["dim", "lun", "mar", "mer", "jeu", "ven", "sam"],
* A: ["dimanche", "lundi", "mardi", "mercredi", "jeudi", "vendredi", "samedi"],
* b: ["jan", "fév", "mar", "avr", "mai", "jun", "jui", "aoû", "sep", "oct", "nov", "déc"],
diff --git a/build/datatype-date-format/datatype-date-format.js b/build/datatype-date-format/datatype-date-format.js
index 7de62272ebd..8e4c736db79 100644
--- a/build/datatype-date-format/datatype-date-format.js
+++ b/build/datatype-date-format/datatype-date-format.js
@@ -352,7 +352,7 @@ Y.mix(Y.namespace("DataType.Date"), Dt);
*
- * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale, {
+ * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale["en"], {
* a: ["dim", "lun", "mar", "mer", "jeu", "ven", "sam"],
* A: ["dimanche", "lundi", "mardi", "mercredi", "jeudi", "vendredi", "samedi"],
* b: ["jan", "fév", "mar", "avr", "mai", "jun", "jui", "aoû", "sep", "oct", "nov", "déc"],
diff --git a/build/datatype-date/datatype-date-debug.js b/build/datatype-date/datatype-date-debug.js
index bd497b2b256..5941846bcef 100644
--- a/build/datatype-date/datatype-date-debug.js
+++ b/build/datatype-date/datatype-date-debug.js
@@ -402,7 +402,7 @@ Y.mix(Y.namespace("DataType.Date"), Dt);
*
- * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale, {
+ * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale["en"], {
* a: ["dim", "lun", "mar", "mer", "jeu", "ven", "sam"],
* A: ["dimanche", "lundi", "mardi", "mercredi", "jeudi", "vendredi", "samedi"],
* b: ["jan", "fév", "mar", "avr", "mai", "jun", "jui", "aoû", "sep", "oct", "nov", "déc"],
diff --git a/build/datatype-date/datatype-date.js b/build/datatype-date/datatype-date.js
index 8746c46a92b..d2eb1a1fc2d 100644
--- a/build/datatype-date/datatype-date.js
+++ b/build/datatype-date/datatype-date.js
@@ -397,7 +397,7 @@ Y.mix(Y.namespace("DataType.Date"), Dt);
*
- * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale, {
+ * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale["en"], {
* a: ["dim", "lun", "mar", "mer", "jeu", "ven", "sam"],
* A: ["dimanche", "lundi", "mardi", "mercredi", "jeudi", "vendredi", "samedi"],
* b: ["jan", "fév", "mar", "avr", "mai", "jun", "jui", "aoû", "sep", "oct", "nov", "déc"],
diff --git a/build/datatype/datatype-date-debug.js b/build/datatype/datatype-date-debug.js
index bd497b2b256..5941846bcef 100644
--- a/build/datatype/datatype-date-debug.js
+++ b/build/datatype/datatype-date-debug.js
@@ -402,7 +402,7 @@ Y.mix(Y.namespace("DataType.Date"), Dt);
*
- * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale, {
+ * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale["en"], {
* a: ["dim", "lun", "mar", "mer", "jeu", "ven", "sam"],
* A: ["dimanche", "lundi", "mardi", "mercredi", "jeudi", "vendredi", "samedi"],
* b: ["jan", "fév", "mar", "avr", "mai", "jun", "jui", "aoû", "sep", "oct", "nov", "déc"],
diff --git a/build/datatype/datatype-date-format-debug.js b/build/datatype/datatype-date-format-debug.js
index f2ff56b54a3..3afa92dac44 100644
--- a/build/datatype/datatype-date-format-debug.js
+++ b/build/datatype/datatype-date-format-debug.js
@@ -356,7 +356,7 @@ Y.mix(Y.namespace("DataType.Date"), Dt);
*
- * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale, {
+ * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale["en"], {
* a: ["dim", "lun", "mar", "mer", "jeu", "ven", "sam"],
* A: ["dimanche", "lundi", "mardi", "mercredi", "jeudi", "vendredi", "samedi"],
* b: ["jan", "fév", "mar", "avr", "mai", "jun", "jui", "aoû", "sep", "oct", "nov", "déc"],
diff --git a/build/datatype/datatype-date-format.js b/build/datatype/datatype-date-format.js
index 7de62272ebd..8e4c736db79 100644
--- a/build/datatype/datatype-date-format.js
+++ b/build/datatype/datatype-date-format.js
@@ -352,7 +352,7 @@ Y.mix(Y.namespace("DataType.Date"), Dt);
*
- * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale, {
+ * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale["en"], {
* a: ["dim", "lun", "mar", "mer", "jeu", "ven", "sam"],
* A: ["dimanche", "lundi", "mardi", "mercredi", "jeudi", "vendredi", "samedi"],
* b: ["jan", "fév", "mar", "avr", "mai", "jun", "jui", "aoû", "sep", "oct", "nov", "déc"],
diff --git a/build/datatype/datatype-date.js b/build/datatype/datatype-date.js
index 8746c46a92b..d2eb1a1fc2d 100644
--- a/build/datatype/datatype-date.js
+++ b/build/datatype/datatype-date.js
@@ -397,7 +397,7 @@ Y.mix(Y.namespace("DataType.Date"), Dt);
*
- * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale, {
+ * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale["en"], {
* a: ["dim", "lun", "mar", "mer", "jeu", "ven", "sam"],
* A: ["dimanche", "lundi", "mardi", "mercredi", "jeudi", "vendredi", "samedi"],
* b: ["jan", "fév", "mar", "avr", "mai", "jun", "jui", "aoû", "sep", "oct", "nov", "déc"],
diff --git a/build/datatype/datatype-debug.js b/build/datatype/datatype-debug.js
index b8f08d4aa93..95b95897126 100644
--- a/build/datatype/datatype-debug.js
+++ b/build/datatype/datatype-debug.js
@@ -549,7 +549,7 @@ Y.mix(Y.namespace("DataType.Date"), Dt);
*
- * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale, {
+ * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale["en"], {
* a: ["dim", "lun", "mar", "mer", "jeu", "ven", "sam"],
* A: ["dimanche", "lundi", "mardi", "mercredi", "jeudi", "vendredi", "samedi"],
* b: ["jan", "fév", "mar", "avr", "mai", "jun", "jui", "aoû", "sep", "oct", "nov", "déc"],
diff --git a/build/datatype/datatype.js b/build/datatype/datatype.js
index 3758d118e79..8a555afc271 100644
--- a/build/datatype/datatype.js
+++ b/build/datatype/datatype.js
@@ -542,7 +542,7 @@ Y.mix(Y.namespace("DataType.Date"), Dt);
*
- * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale, {
+ * Y.DataType.Date.Locale["fr"] = Y.merge(Y.DataType.Date.Locale["en"], {
* a: ["dim", "lun", "mar", "mer", "jeu", "ven", "sam"],
* A: ["dimanche", "lundi", "mardi", "mercredi", "jeudi", "vendredi", "samedi"],
* b: ["jan", "fév", "mar", "avr", "mai", "jun", "jui", "aoû", "sep", "oct", "nov", "déc"],
diff --git a/build/dd-drop-plugin/dd-drop-plugin-debug.js b/build/dd-drop-plugin/dd-drop-plugin-debug.js
index 3f0264bb6b7..f11754c2c65 100644
--- a/build/dd-drop-plugin/dd-drop-plugin-debug.js
+++ b/build/dd-drop-plugin/dd-drop-plugin-debug.js
@@ -42,4 +42,4 @@ YUI.add('dd-drop-plugin', function(Y) {
-}, '@VERSION@' ,{requires:['dd-drop'], skinnable:false});
+}, '@VERSION@' ,{skinnable:false, requires:['dd-drop']});
diff --git a/build/dd-drop-plugin/dd-drop-plugin-min.js b/build/dd-drop-plugin/dd-drop-plugin-min.js
index abf2030d863..7005d2e6c42 100644
--- a/build/dd-drop-plugin/dd-drop-plugin-min.js
+++ b/build/dd-drop-plugin/dd-drop-plugin-min.js
@@ -1 +1 @@
-YUI.add("dd-drop-plugin",function(a){var b=function(c){c.node=c.host;b.superclass.constructor.apply(this,arguments);};b.NAME="dd-drop-plugin";b.NS="drop";a.extend(b,a.DD.Drop);a.namespace("Plugin");a.Plugin.Drop=b;},"@VERSION@",{requires:["dd-drop"],skinnable:false});
\ No newline at end of file
+YUI.add("dd-drop-plugin",function(a){var b=function(c){c.node=c.host;b.superclass.constructor.apply(this,arguments);};b.NAME="dd-drop-plugin";b.NS="drop";a.extend(b,a.DD.Drop);a.namespace("Plugin");a.Plugin.Drop=b;},"@VERSION@",{skinnable:false,requires:["dd-drop"]});
\ No newline at end of file
diff --git a/build/dd-drop-plugin/dd-drop-plugin.js b/build/dd-drop-plugin/dd-drop-plugin.js
index 3f0264bb6b7..f11754c2c65 100644
--- a/build/dd-drop-plugin/dd-drop-plugin.js
+++ b/build/dd-drop-plugin/dd-drop-plugin.js
@@ -42,4 +42,4 @@ YUI.add('dd-drop-plugin', function(Y) {
-}, '@VERSION@' ,{requires:['dd-drop'], skinnable:false});
+}, '@VERSION@' ,{skinnable:false, requires:['dd-drop']});
diff --git a/build/dd-gestures/dd-gestures-debug.js b/build/dd-gestures/dd-gestures-debug.js
index e902aac29ec..fec1d752fa7 100644
--- a/build/dd-gestures/dd-gestures-debug.js
+++ b/build/dd-gestures/dd-gestures-debug.js
@@ -37,4 +37,4 @@ YUI.add('dd-gestures', function(Y) {
-}, '@VERSION@' ,{requires:['dd-drag', 'event-synthetic', 'event-gestures'], skinnable:false});
+}, '@VERSION@' ,{skinnable:false, requires:['dd-drag', 'event-synthetic', 'event-gestures']});
diff --git a/build/dd-gestures/dd-gestures-min.js b/build/dd-gestures/dd-gestures-min.js
index b1d40aa6224..c360848bfc1 100644
--- a/build/dd-gestures/dd-gestures-min.js
+++ b/build/dd-gestures/dd-gestures-min.js
@@ -1 +1 @@
-YUI.add("dd-gestures",function(a){a.DD.Drag.START_EVENT="gesturemovestart";a.DD.Drag.prototype._prep=function(){this._dragThreshMet=false;var c=this.get("node"),b=a.DD.DDM;c.addClass(b.CSS_PREFIX+"-draggable");c.on(a.DD.Drag.START_EVENT,a.bind(this._handleMouseDownEvent,this),{minDistance:0,minTime:0});c.on("gesturemoveend",a.bind(this._handleMouseUp,this),{standAlone:true});c.on("dragstart",a.bind(this._fixDragStart,this));};a.DD.DDM._setupListeners=function(){var b=a.DD.DDM;this._createPG();this._active=true;a.one(a.config.doc).on("gesturemove",a.throttle(a.bind(b._move,b),b.get("throttleTime")),{standAlone:true});};},"@VERSION@",{requires:["dd-drag","event-synthetic","event-gestures"],skinnable:false});
\ No newline at end of file
+YUI.add("dd-gestures",function(a){a.DD.Drag.START_EVENT="gesturemovestart";a.DD.Drag.prototype._prep=function(){this._dragThreshMet=false;var c=this.get("node"),b=a.DD.DDM;c.addClass(b.CSS_PREFIX+"-draggable");c.on(a.DD.Drag.START_EVENT,a.bind(this._handleMouseDownEvent,this),{minDistance:0,minTime:0});c.on("gesturemoveend",a.bind(this._handleMouseUp,this),{standAlone:true});c.on("dragstart",a.bind(this._fixDragStart,this));};a.DD.DDM._setupListeners=function(){var b=a.DD.DDM;this._createPG();this._active=true;a.one(a.config.doc).on("gesturemove",a.throttle(a.bind(b._move,b),b.get("throttleTime")),{standAlone:true});};},"@VERSION@",{skinnable:false,requires:["dd-drag","event-synthetic","event-gestures"]});
\ No newline at end of file
diff --git a/build/dd-gestures/dd-gestures.js b/build/dd-gestures/dd-gestures.js
index a5e0717d5d6..40eb98cec31 100644
--- a/build/dd-gestures/dd-gestures.js
+++ b/build/dd-gestures/dd-gestures.js
@@ -35,4 +35,4 @@ YUI.add('dd-gestures', function(Y) {
-}, '@VERSION@' ,{requires:['dd-drag', 'event-synthetic', 'event-gestures'], skinnable:false});
+}, '@VERSION@' ,{skinnable:false, requires:['dd-drag', 'event-synthetic', 'event-gestures']});
diff --git a/build/dd-plugin/dd-plugin-debug.js b/build/dd-plugin/dd-plugin-debug.js
index cc8e7a9b408..5e9044522bf 100644
--- a/build/dd-plugin/dd-plugin-debug.js
+++ b/build/dd-plugin/dd-plugin-debug.js
@@ -153,4 +153,4 @@ YUI.add('dd-plugin', function(Y) {
-}, '@VERSION@' ,{requires:['dd-drag'], skinnable:false, optional:['dd-constrain', 'dd-proxy']});
+}, '@VERSION@' ,{optional:['dd-constrain', 'dd-proxy'], skinnable:false, requires:['dd-drag']});
diff --git a/build/dd-plugin/dd-plugin-min.js b/build/dd-plugin/dd-plugin-min.js
index 738a80919dc..a724b92b9c0 100644
--- a/build/dd-plugin/dd-plugin-min.js
+++ b/build/dd-plugin/dd-plugin-min.js
@@ -1 +1 @@
-YUI.add("dd-plugin",function(c){var a=function(e){if(c.Widget&&e.host instanceof c.Widget){e.node=e.host.get("boundingBox");e.widget=e.host;}else{e.node=e.host;e.widget=false;}a.superclass.constructor.call(this,e);},b="drag:drag",d="drag:end";a.NAME="dd-plugin";a.NS="dd";c.extend(a,c.DD.Drag,{_widget:undefined,_stoppedPosition:undefined,_usesWidgetPosition:function(f){var e=false;if(f){e=(f.hasImpl&&f.hasImpl(c.WidgetPosition))?true:false;}return e;},initializer:function(e){this._widget=e.widget;if(this._usesWidgetPosition(this._widget)){this.on(b,this._setWidgetCoords);this.on(d,this._updateStopPosition);}},_setWidgetCoords:function(i){var h=this._stoppedPosition||i.target.nodeXY,f=i.target.realXY,g=[f[0]-h[0],f[1]-h[0]];if(g[0]!==0&&g[1]!==0){this._widget.set("xy",f);}else{if(g[0]===0){this._widget.set("y",f[1]);}else{if(g[1]===0){this._widget.set("x",f[0]);}}}},updateStopPosition:function(f){this._stoppedPosition=f.target.realXY;}});c.namespace("Plugin");c.Plugin.Drag=a;},"@VERSION@",{requires:["dd-drag"],skinnable:false,optional:["dd-constrain","dd-proxy"]});
\ No newline at end of file
+YUI.add("dd-plugin",function(c){var a=function(e){if(c.Widget&&e.host instanceof c.Widget){e.node=e.host.get("boundingBox");e.widget=e.host;}else{e.node=e.host;e.widget=false;}a.superclass.constructor.call(this,e);},b="drag:drag",d="drag:end";a.NAME="dd-plugin";a.NS="dd";c.extend(a,c.DD.Drag,{_widget:undefined,_stoppedPosition:undefined,_usesWidgetPosition:function(f){var e=false;if(f){e=(f.hasImpl&&f.hasImpl(c.WidgetPosition))?true:false;}return e;},initializer:function(e){this._widget=e.widget;if(this._usesWidgetPosition(this._widget)){this.on(b,this._setWidgetCoords);this.on(d,this._updateStopPosition);}},_setWidgetCoords:function(i){var h=this._stoppedPosition||i.target.nodeXY,f=i.target.realXY,g=[f[0]-h[0],f[1]-h[0]];if(g[0]!==0&&g[1]!==0){this._widget.set("xy",f);}else{if(g[0]===0){this._widget.set("y",f[1]);}else{if(g[1]===0){this._widget.set("x",f[0]);}}}},updateStopPosition:function(f){this._stoppedPosition=f.target.realXY;}});c.namespace("Plugin");c.Plugin.Drag=a;},"@VERSION@",{optional:["dd-constrain","dd-proxy"],skinnable:false,requires:["dd-drag"]});
\ No newline at end of file
diff --git a/build/dd-plugin/dd-plugin.js b/build/dd-plugin/dd-plugin.js
index cc8e7a9b408..5e9044522bf 100644
--- a/build/dd-plugin/dd-plugin.js
+++ b/build/dd-plugin/dd-plugin.js
@@ -153,4 +153,4 @@ YUI.add('dd-plugin', function(Y) {
-}, '@VERSION@' ,{requires:['dd-drag'], skinnable:false, optional:['dd-constrain', 'dd-proxy']});
+}, '@VERSION@' ,{optional:['dd-constrain', 'dd-proxy'], skinnable:false, requires:['dd-drag']});
diff --git a/build/dd-scroll/dd-scroll-debug.js b/build/dd-scroll/dd-scroll-debug.js
index 2df4fdf94cd..801dbf5d8b0 100644
--- a/build/dd-scroll/dd-scroll-debug.js
+++ b/build/dd-scroll/dd-scroll-debug.js
@@ -423,4 +423,4 @@ YUI.add('dd-scroll', function(Y) {
-}, '@VERSION@' ,{skinnable:false, optional:['dd-proxy'], requires:['dd-drag']});
+}, '@VERSION@' ,{optional:['dd-proxy'], skinnable:false, requires:['dd-drag']});
diff --git a/build/dd-scroll/dd-scroll-min.js b/build/dd-scroll/dd-scroll-min.js
index 7ab30e02d13..415676a48c4 100644
--- a/build/dd-scroll/dd-scroll-min.js
+++ b/build/dd-scroll/dd-scroll-min.js
@@ -1 +1 @@
-YUI.add("dd-scroll",function(b){var h=function(){h.superclass.constructor.apply(this,arguments);},c,d,l="host",a="buffer",j="parentScroll",g="windowScroll",i="scrollTop",f="scrollLeft",e="offsetWidth",k="offsetHeight";h.ATTRS={parentScroll:{value:false,setter:function(m){if(m){return m;}return false;}},buffer:{value:30,validator:b.Lang.isNumber},scrollDelay:{value:235,validator:b.Lang.isNumber},host:{value:null},windowScroll:{value:false,validator:b.Lang.isBoolean},vertical:{value:true,validator:b.Lang.isBoolean},horizontal:{value:true,validator:b.Lang.isBoolean}};b.extend(h,b.Base,{_scrolling:null,_vpRegionCache:null,_dimCache:null,_scrollTimer:null,_getVPRegion:function(){var m={},o=this.get(j),u=this.get(a),s=this.get(g),y=((s)?[]:o.getXY()),v=((s)?"winWidth":e),q=((s)?"winHeight":k),x=((s)?o.get(i):y[1]),p=((s)?o.get(f):y[0]);m={top:x+u,right:(o.get(v)+p)-u,bottom:(o.get(q)+x)-u,left:p+u};this._vpRegionCache=m;return m;},initializer:function(){var m=this.get(l);m.after("drag:start",b.bind(this.start,this));m.after("drag:end",b.bind(this.end,this));m.on("drag:align",b.bind(this.align,this));b.one("win").on("scroll",b.bind(function(){this._vpRegionCache=null;},this));},_checkWinScroll:function(A){var z=this._getVPRegion(),m=this.get(l),o=this.get(g),t=m.lastXY,n=false,F=this.get(a),s=this.get(j),H=s.get(i),v=s.get(f),x=this._dimCache.w,C=this._dimCache.h,u=t[1]+C,y=t[1],E=t[0]+x,q=t[0],G=y,p=q,B=H,D=v;if(this.get("horizontal")){if(q<=z.left){n=true;p=t[0]-((o)?F:0);D=v-F;}if(E>=z.right){n=true;p=t[0]+((o)?F:0);D=v+F;}}if(this.get("vertical")){if(u>=z.bottom){n=true;G=t[1]+((o)?F:0);B=H+F;}if(y<=z.top){n=true;G=t[1]-((o)?F:0);B=H-F;}}if(B<0){B=0;G=t[1];}if(D<0){D=0;p=t[0];}if(G<0){G=t[1];}if(p<0){p=t[0];}if(A){m.actXY=[p,G];m._moveNode({node:s,top:B,left:D});if(!B&&!D){this._cancelScroll();}}else{if(n){this._initScroll();}else{this._cancelScroll();}}},_initScroll:function(){this._cancelScroll();this._scrollTimer=b.Lang.later(this.get("scrollDelay"),this,this._checkWinScroll,[true],true);},_cancelScroll:function(){this._scrolling=false;if(this._scrollTimer){this._scrollTimer.cancel();delete this._scrollTimer;}},align:function(m){if(this._scrolling){this._cancelScroll();m.preventDefault();}if(!this._scrolling){this._checkWinScroll();}},_setDimCache:function(){var m=this.get(l).get("dragNode");this._dimCache={h:m.get(k),w:m.get(e)};},start:function(){this._setDimCache();},end:function(m){this._dimCache=null;this._cancelScroll();},toString:function(){return h.NAME+" #"+this.get("node").get("id");}});b.namespace("Plugin");c=function(){c.superclass.constructor.apply(this,arguments);};c.ATTRS=b.merge(h.ATTRS,{windowScroll:{value:true,setter:function(m){if(m){this.set(j,b.one("win"));}return m;}}});b.extend(c,h,{initializer:function(){this.set("windowScroll",this.get("windowScroll"));}});c.NAME=c.NS="winscroll";b.Plugin.DDWinScroll=c;d=function(){d.superclass.constructor.apply(this,arguments);};d.ATTRS=b.merge(h.ATTRS,{node:{value:false,setter:function(m){var o=b.one(m);if(!o){if(m!==false){b.error("DDNodeScroll: Invalid Node Given: "+m);}}else{this.set(j,o);}return o;}}});b.extend(d,h,{initializer:function(){this.set("node",this.get("node"));}});d.NAME=d.NS="nodescroll";b.Plugin.DDNodeScroll=d;b.DD.Scroll=h;},"@VERSION@",{skinnable:false,optional:["dd-proxy"],requires:["dd-drag"]});
\ No newline at end of file
+YUI.add("dd-scroll",function(b){var h=function(){h.superclass.constructor.apply(this,arguments);},c,d,l="host",a="buffer",j="parentScroll",g="windowScroll",i="scrollTop",f="scrollLeft",e="offsetWidth",k="offsetHeight";h.ATTRS={parentScroll:{value:false,setter:function(m){if(m){return m;}return false;}},buffer:{value:30,validator:b.Lang.isNumber},scrollDelay:{value:235,validator:b.Lang.isNumber},host:{value:null},windowScroll:{value:false,validator:b.Lang.isBoolean},vertical:{value:true,validator:b.Lang.isBoolean},horizontal:{value:true,validator:b.Lang.isBoolean}};b.extend(h,b.Base,{_scrolling:null,_vpRegionCache:null,_dimCache:null,_scrollTimer:null,_getVPRegion:function(){var m={},o=this.get(j),u=this.get(a),s=this.get(g),y=((s)?[]:o.getXY()),v=((s)?"winWidth":e),q=((s)?"winHeight":k),x=((s)?o.get(i):y[1]),p=((s)?o.get(f):y[0]);m={top:x+u,right:(o.get(v)+p)-u,bottom:(o.get(q)+x)-u,left:p+u};this._vpRegionCache=m;return m;},initializer:function(){var m=this.get(l);m.after("drag:start",b.bind(this.start,this));m.after("drag:end",b.bind(this.end,this));m.on("drag:align",b.bind(this.align,this));b.one("win").on("scroll",b.bind(function(){this._vpRegionCache=null;},this));},_checkWinScroll:function(A){var z=this._getVPRegion(),m=this.get(l),o=this.get(g),t=m.lastXY,n=false,F=this.get(a),s=this.get(j),H=s.get(i),v=s.get(f),x=this._dimCache.w,C=this._dimCache.h,u=t[1]+C,y=t[1],E=t[0]+x,q=t[0],G=y,p=q,B=H,D=v;if(this.get("horizontal")){if(q<=z.left){n=true;p=t[0]-((o)?F:0);D=v-F;}if(E>=z.right){n=true;p=t[0]+((o)?F:0);D=v+F;}}if(this.get("vertical")){if(u>=z.bottom){n=true;G=t[1]+((o)?F:0);B=H+F;}if(y<=z.top){n=true;G=t[1]-((o)?F:0);B=H-F;}}if(B<0){B=0;G=t[1];}if(D<0){D=0;p=t[0];}if(G<0){G=t[1];}if(p<0){p=t[0];}if(A){m.actXY=[p,G];m._moveNode({node:s,top:B,left:D});if(!B&&!D){this._cancelScroll();}}else{if(n){this._initScroll();}else{this._cancelScroll();}}},_initScroll:function(){this._cancelScroll();this._scrollTimer=b.Lang.later(this.get("scrollDelay"),this,this._checkWinScroll,[true],true);},_cancelScroll:function(){this._scrolling=false;if(this._scrollTimer){this._scrollTimer.cancel();delete this._scrollTimer;}},align:function(m){if(this._scrolling){this._cancelScroll();m.preventDefault();}if(!this._scrolling){this._checkWinScroll();}},_setDimCache:function(){var m=this.get(l).get("dragNode");this._dimCache={h:m.get(k),w:m.get(e)};},start:function(){this._setDimCache();},end:function(m){this._dimCache=null;this._cancelScroll();},toString:function(){return h.NAME+" #"+this.get("node").get("id");}});b.namespace("Plugin");c=function(){c.superclass.constructor.apply(this,arguments);};c.ATTRS=b.merge(h.ATTRS,{windowScroll:{value:true,setter:function(m){if(m){this.set(j,b.one("win"));}return m;}}});b.extend(c,h,{initializer:function(){this.set("windowScroll",this.get("windowScroll"));}});c.NAME=c.NS="winscroll";b.Plugin.DDWinScroll=c;d=function(){d.superclass.constructor.apply(this,arguments);};d.ATTRS=b.merge(h.ATTRS,{node:{value:false,setter:function(m){var o=b.one(m);if(!o){if(m!==false){b.error("DDNodeScroll: Invalid Node Given: "+m);}}else{this.set(j,o);}return o;}}});b.extend(d,h,{initializer:function(){this.set("node",this.get("node"));}});d.NAME=d.NS="nodescroll";b.Plugin.DDNodeScroll=d;b.DD.Scroll=h;},"@VERSION@",{optional:["dd-proxy"],skinnable:false,requires:["dd-drag"]});
\ No newline at end of file
diff --git a/build/dd-scroll/dd-scroll.js b/build/dd-scroll/dd-scroll.js
index 2df4fdf94cd..801dbf5d8b0 100644
--- a/build/dd-scroll/dd-scroll.js
+++ b/build/dd-scroll/dd-scroll.js
@@ -423,4 +423,4 @@ YUI.add('dd-scroll', function(Y) {
-}, '@VERSION@' ,{skinnable:false, optional:['dd-proxy'], requires:['dd-drag']});
+}, '@VERSION@' ,{optional:['dd-proxy'], skinnable:false, requires:['dd-drag']});
diff --git a/build/dd/dd-debug.js b/build/dd/dd-debug.js
index 4402316b9b2..a1178319ff2 100644
--- a/build/dd/dd-debug.js
+++ b/build/dd/dd-debug.js
@@ -3331,7 +3331,7 @@ YUI.add('dd-scroll', function(Y) {
-}, '@VERSION@' ,{skinnable:false, optional:['dd-proxy'], requires:['dd-drag']});
+}, '@VERSION@' ,{optional:['dd-proxy'], skinnable:false, requires:['dd-drag']});
YUI.add('dd-drop', function(Y) {
@@ -4216,5 +4216,5 @@ YUI.add('dd-delegate', function(Y) {
}, '@VERSION@' ,{skinnable:false, requires:['dd-drag', 'event-mouseenter', 'dd-drop-plugin']});
-YUI.add('dd', function(Y){}, '@VERSION@' ,{use:['dd-ddm-base', 'dd-ddm', 'dd-ddm-drop', 'dd-drag', 'dd-proxy', 'dd-constrain', 'dd-drop', 'dd-scroll', 'dd-delegate'], skinnable:false});
+YUI.add('dd', function(Y){}, '@VERSION@' ,{skinnable:false, use:['dd-ddm-base', 'dd-ddm', 'dd-ddm-drop', 'dd-drag', 'dd-proxy', 'dd-constrain', 'dd-drop', 'dd-scroll', 'dd-delegate']});
diff --git a/build/dd/dd-min.js b/build/dd/dd-min.js
index d3742af85f0..840c660c304 100644
--- a/build/dd/dd-min.js
+++ b/build/dd/dd-min.js
@@ -2,5 +2,5 @@ YUI.add("dd-ddm-base",function(b){var a=function(){a.superclass.constructor.appl
}},this);return[c,b];}else{return c;}},_deactivateTargets:function(){var b=[],c,e=this.activeDrag,d=this.activeDrop;if(e&&d&&this.otherDrops[d]){if(!e.get("dragMode")){b=this.otherDrops;delete b[d];}else{c=this.getBestMatch(this.otherDrops,true);d=c[0];b=c[1];}e.get("node").removeClass(this.CSS_PREFIX+"-drag-over");if(d){d.fire("drop:hit",{drag:e,drop:d,others:b});e.fire("drag:drophit",{drag:e,drop:d,others:b});}}else{if(e&&e.get("dragging")){e.get("node").removeClass(this.CSS_PREFIX+"-drag-over");e.fire("drag:dropmiss",{pageX:e.lastXY[0],pageY:e.lastXY[1]});}else{}}this.activeDrop=null;a.each(this.targets,function(g,f){g._deactivateShim([]);},this);},_dropMove:function(){if(this._hasActiveShim()){this._handleTargetOver();}else{a.each(this.otherDrops,function(c,b){c._handleOut.apply(c,[]);});}},_lookup:function(){if(!this.useHash||this._noShim){return this.validDrops;}var b=[];a.each(this.validDrops,function(d,c){if(d.shim&&d.shim.inViewportRegion(false,d.region)){b[b.length]=d;}});return b;},_handleTargetOver:function(){var b=this._lookup();a.each(b,function(d,c){d._handleTargetOver.call(d);},this);},_regTarget:function(b){this.targets[this.targets.length]=b;},_unregTarget:function(c){var b=[],d;a.each(this.targets,function(f,e){if(f!=c){b[b.length]=f;}},this);this.targets=b;d=[];a.each(this.validDrops,function(f,e){if(f!==c){d[d.length]=f;}});this.validDrops=d;},getDrop:function(c){var b=false,d=a.one(c);if(d instanceof a.Node){a.each(this.targets,function(f,e){if(d.compareTo(f.get("node"))){b=f;}});}return b;}},true);},"@VERSION@",{skinnable:false,requires:["dd-ddm"]});YUI.add("dd-drag",function(d){var e=d.DD.DDM,r="node",g="dragging",m="dragNode",c="offsetHeight",k="offsetWidth",h="drag:mouseDown",b="drag:afterMouseDown",f="drag:removeHandle",l="drag:addHandle",p="drag:removeInvalid",q="drag:addInvalid",j="drag:start",i="drag:end",n="drag:drag",o="drag:align",a=function(t){this._lazyAddAttrs=false;a.superclass.constructor.apply(this,arguments);var s=e._regDrag(this);if(!s){d.error("Failed to register node, already in use: "+t.node);}};a.NAME="drag";a.START_EVENT="mousedown";a.ATTRS={node:{setter:function(s){var t=d.one(s);if(!t){d.error("DD.Drag: Invalid Node Given: "+s);}return t;}},dragNode:{setter:function(s){var t=d.one(s);if(!t){d.error("DD.Drag: Invalid dragNode Given: "+s);}return t;}},offsetNode:{value:true},startCentered:{value:false},clickPixelThresh:{value:e.get("clickPixelThresh")},clickTimeThresh:{value:e.get("clickTimeThresh")},lock:{value:false,setter:function(s){if(s){this.get(r).addClass(e.CSS_PREFIX+"-locked");}else{this.get(r).removeClass(e.CSS_PREFIX+"-locked");}return s;}},data:{value:false},move:{value:true},useShim:{value:true},activeHandle:{value:false},primaryButtonOnly:{value:true},dragging:{value:false},parent:{value:false},target:{value:false,setter:function(s){this._handleTarget(s);return s;}},dragMode:{value:null,setter:function(s){return e._setDragMode(s);}},groups:{value:["default"],getter:function(){if(!this._groups){this._groups={};}var s=[];d.each(this._groups,function(u,t){s[s.length]=t;});return s;},setter:function(s){this._groups={};d.each(s,function(u,t){this._groups[u]=true;},this);return s;}},handles:{value:null,setter:function(s){if(s){this._handles={};d.each(s,function(u,t){var w=u;if(u instanceof d.Node||u instanceof d.NodeList){w=u._yuid;}this._handles[w]=u;},this);}else{this._handles=null;}return s;}},bubbles:{setter:function(s){this.addTarget(s);return s;}},haltDown:{value:true}};d.extend(a,d.Base,{_bubbleTargets:d.DD.DDM,addToGroup:function(s){this._groups[s]=true;e._activateTargets();return this;},removeFromGroup:function(s){delete this._groups[s];e._activateTargets();return this;},target:null,_handleTarget:function(s){if(d.DD.Drop){if(s===false){if(this.target){e._unregTarget(this.target);this.target=null;}return false;}else{if(!d.Lang.isObject(s)){s={};}s.bubbleTargets=("bubbleTargets" in s)?s.bubbleTargets:d.Object.values(this._yuievt.targets);s.node=this.get(r);s.groups=s.groups||this.get("groups");this.target=new d.DD.Drop(s);}}else{return false;}},_groups:null,_createEvents:function(){this.publish(h,{defaultFn:this._defMouseDownFn,queuable:false,emitFacade:true,bubbles:true,prefix:"drag"});this.publish(o,{defaultFn:this._defAlignFn,queuable:false,emitFacade:true,bubbles:true,prefix:"drag"});this.publish(n,{defaultFn:this._defDragFn,queuable:false,emitFacade:true,bubbles:true,prefix:"drag"});this.publish(i,{defaultFn:this._defEndFn,preventedFn:this._prevEndFn,queuable:false,emitFacade:true,bubbles:true,prefix:"drag"});var s=[b,f,l,p,q,j,"drag:drophit","drag:dropmiss","drag:over","drag:enter","drag:exit"];d.each(s,function(u,t){this.publish(u,{type:u,emitFacade:true,bubbles:true,preventable:false,queuable:false,prefix:"drag"});},this);},_ev_md:null,_startTime:null,_endTime:null,_handles:null,_invalids:null,_invalidsDefault:{"textarea":true,"input":true,"a":true,"button":true,"select":true},_dragThreshMet:null,_fromTimeout:null,_clickTimeout:null,deltaXY:null,startXY:null,nodeXY:null,lastXY:null,actXY:null,realXY:null,mouseXY:null,region:null,_handleMouseUp:function(s){this.fire("drag:mouseup");this._fixIEMouseUp();if(e.activeDrag){e._end();}},_fixDragStart:function(s){s.preventDefault();},_ieSelectFix:function(){return false;},_ieSelectBack:null,_fixIEMouseDown:function(s){if(d.UA.ie){this._ieSelectBack=d.config.doc.body.onselectstart;d.config.doc.body.onselectstart=this._ieSelectFix;}},_fixIEMouseUp:function(){if(d.UA.ie){d.config.doc.body.onselectstart=this._ieSelectBack;}},_handleMouseDownEvent:function(s){this.fire(h,{ev:s});},_defMouseDownFn:function(t){var s=t.ev;this._dragThreshMet=false;this._ev_md=s;if(this.get("primaryButtonOnly")&&s.button>1){return false;}if(this.validClick(s)){this._fixIEMouseDown(s);if(this.get("haltDown")){s.halt();}else{s.preventDefault();}this._setStartPosition([s.pageX,s.pageY]);e.activeDrag=this;this._clickTimeout=d.later(this.get("clickTimeThresh"),this,this._timeoutCheck);}this.fire(b,{ev:s});},validClick:function(w){var v=false,z=false,s=w.target,u=null,t=null,x=null,y=false;
if(this._handles){d.each(this._handles,function(A,B){if(A instanceof d.Node||A instanceof d.NodeList){if(!v){x=A;if(x instanceof d.Node){x=new d.NodeList(A._node);}x.each(function(C){if(C.contains(s)){v=true;}});}}else{if(d.Lang.isString(B)){if(s.test(B+", "+B+" *")&&!u){u=B;v=true;}}}});}else{z=this.get(r);if(z.contains(s)||z.compareTo(s)){v=true;}}if(v){if(this._invalids){d.each(this._invalids,function(A,B){if(d.Lang.isString(B)){if(s.test(B+", "+B+" *")){v=false;}}});}}if(v){if(u){t=w.currentTarget.all(u);y=false;t.each(function(B,A){if((B.contains(s)||B.compareTo(s))&&!y){y=true;this.set("activeHandle",B);}},this);}else{this.set("activeHandle",this.get(r));}}return v;},_setStartPosition:function(s){this.startXY=s;this.nodeXY=this.lastXY=this.realXY=this.get(r).getXY();if(this.get("offsetNode")){this.deltaXY=[(this.startXY[0]-this.nodeXY[0]),(this.startXY[1]-this.nodeXY[1])];}else{this.deltaXY=[0,0];}},_timeoutCheck:function(){if(!this.get("lock")&&!this._dragThreshMet&&this._ev_md){this._fromTimeout=this._dragThreshMet=true;this.start();this._alignNode([this._ev_md.pageX,this._ev_md.pageY],true);}},removeHandle:function(t){var s=t;if(t instanceof d.Node||t instanceof d.NodeList){s=t._yuid;}if(this._handles[s]){delete this._handles[s];this.fire(f,{handle:t});}return this;},addHandle:function(t){if(!this._handles){this._handles={};}var s=t;if(t instanceof d.Node||t instanceof d.NodeList){s=t._yuid;}this._handles[s]=t;this.fire(l,{handle:t});return this;},removeInvalid:function(s){if(this._invalids[s]){this._invalids[s]=null;delete this._invalids[s];this.fire(p,{handle:s});}return this;},addInvalid:function(s){if(d.Lang.isString(s)){this._invalids[s]=true;this.fire(q,{handle:s});}return this;},initializer:function(s){this.get(r).dd=this;if(!this.get(r).get("id")){var t=d.stamp(this.get(r));this.get(r).set("id",t);}this.actXY=[];this._invalids=d.clone(this._invalidsDefault,true);this._createEvents();if(!this.get(m)){this.set(m,this.get(r));}this.on("initializedChange",d.bind(this._prep,this));this.set("groups",this.get("groups"));},_prep:function(){this._dragThreshMet=false;var s=this.get(r);s.addClass(e.CSS_PREFIX+"-draggable");s.on(a.START_EVENT,d.bind(this._handleMouseDownEvent,this));s.on("mouseup",d.bind(this._handleMouseUp,this));s.on("dragstart",d.bind(this._fixDragStart,this));},_unprep:function(){var s=this.get(r);s.removeClass(e.CSS_PREFIX+"-draggable");s.detachAll();},start:function(){if(!this.get("lock")&&!this.get(g)){var t=this.get(r),s,u,v;this._startTime=(new Date()).getTime();e._start();t.addClass(e.CSS_PREFIX+"-dragging");this.fire(j,{pageX:this.nodeXY[0],pageY:this.nodeXY[1],startTime:this._startTime});t=this.get(m);v=this.nodeXY;s=t.get(k);u=t.get(c);if(this.get("startCentered")){this._setStartPosition([v[0]+(s/2),v[1]+(u/2)]);}this.region={"0":v[0],"1":v[1],area:0,top:v[1],right:v[0]+s,bottom:v[1]+u,left:v[0]};this.set(g,true);}return this;},end:function(){this._endTime=(new Date()).getTime();if(this._clickTimeout){this._clickTimeout.cancel();}this._dragThreshMet=this._fromTimeout=false;if(!this.get("lock")&&this.get(g)){this.fire(i,{pageX:this.lastXY[0],pageY:this.lastXY[1],startTime:this._startTime,endTime:this._endTime});}this.get(r).removeClass(e.CSS_PREFIX+"-dragging");this.set(g,false);this.deltaXY=[0,0];return this;},_defEndFn:function(s){this._fixIEMouseUp();this._ev_md=null;},_prevEndFn:function(s){this._fixIEMouseUp();this.get(m).setXY(this.nodeXY);this._ev_md=null;this.region=null;},_align:function(s){this.fire(o,{pageX:s[0],pageY:s[1]});},_defAlignFn:function(s){this.actXY=[s.pageX-this.deltaXY[0],s.pageY-this.deltaXY[1]];},_alignNode:function(s){this._align(s);this._moveNode();},_moveNode:function(s){var t=[],u=[],w=this.nodeXY,v=this.actXY;t[0]=(v[0]-this.lastXY[0]);t[1]=(v[1]-this.lastXY[1]);u[0]=(v[0]-this.nodeXY[0]);u[1]=(v[1]-this.nodeXY[1]);this.region={"0":v[0],"1":v[1],area:0,top:v[1],right:v[0]+this.get(m).get(k),bottom:v[1]+this.get(m).get(c),left:v[0]};this.fire(n,{pageX:v[0],pageY:v[1],scroll:s,info:{start:w,xy:v,delta:t,offset:u}});this.lastXY=v;},_defDragFn:function(s){if(this.get("move")){if(s.scroll){s.scroll.node.set("scrollTop",s.scroll.top);s.scroll.node.set("scrollLeft",s.scroll.left);}this.get(m).setXY([s.pageX,s.pageY]);this.realXY=[s.pageX,s.pageY];}},_move:function(u){if(this.get("lock")){return false;}else{this.mouseXY=[u.pageX,u.pageY];if(!this._dragThreshMet){var t=Math.abs(this.startXY[0]-u.pageX),s=Math.abs(this.startXY[1]-u.pageY);if(t>this.get("clickPixelThresh")||s>this.get("clickPixelThresh")){this._dragThreshMet=true;this.start();this._alignNode([u.pageX,u.pageY]);}}else{if(this._clickTimeout){this._clickTimeout.cancel();}this._alignNode([u.pageX,u.pageY]);}}},stopDrag:function(){if(this.get(g)){e._end();}return this;},destructor:function(){this._unprep();this.detachAll();if(this.target){this.target.destroy();}e._unregDrag(this);}});d.namespace("DD");d.DD.Drag=a;},"@VERSION@",{skinnable:false,requires:["dd-ddm-base"]});YUI.add("dd-proxy",function(h){var f=h.DD.DDM,b="node",c="dragNode",a="host",d=true,e,g=function(i){g.superclass.constructor.apply(this,arguments);};g.NAME="DDProxy";g.NS="proxy";g.ATTRS={host:{},moveOnEnd:{value:d},hideOnEnd:{value:d},resizeFrame:{value:d},positionProxy:{value:d},borderStyle:{value:"1px solid #808080"},cloneNode:{value:false}};e={_hands:null,_init:function(){if(!f._proxy){f._createFrame();h.on("domready",h.bind(this._init,this));return;}if(!this._hands){this._hands=[];}var k,j,l=this.get(a),i=l.get(c);if(i.compareTo(l.get(b))){if(f._proxy){l.set(c,f._proxy);}}h.each(this._hands,function(m){m.detach();});k=f.on("ddm:start",h.bind(function(){if(f.activeDrag===l){f._setFrame(l);}},this));j=f.on("ddm:end",h.bind(function(){if(l.get("dragging")){if(this.get("moveOnEnd")){l.get(b).setXY(l.lastXY);}if(this.get("hideOnEnd")){l.get(c).setStyle("display","none");}if(this.get("cloneNode")){l.get(c).remove();l.set(c,f._proxy);}}},this));this._hands=[k,j];},initializer:function(){this._init();},destructor:function(){var i=this.get(a);
h.each(this._hands,function(j){j.detach();});i.set(c,i.get(b));},clone:function(){var i=this.get(a),k=i.get(b),j=k.cloneNode(true);delete j._yuid;j.setAttribute("id",h.guid());j.setStyle("position","absolute");k.get("parentNode").appendChild(j);i.set(c,j);return j;}};h.namespace("Plugin");h.extend(g,h.Base,e);h.Plugin.DDProxy=g;h.mix(f,{_createFrame:function(){if(!f._proxy){f._proxy=d;var j=h.Node.create(""),i=h.one("body");j.setStyles({position:"absolute",display:"none",zIndex:"999",top:"-999px",left:"-999px"});i.prepend(j);j.set("id",h.guid());j.addClass(f.CSS_PREFIX+"-proxy");f._proxy=j;}},_setFrame:function(j){var m=j.get(b),l=j.get(c),i,k="auto";i=f.activeDrag.get("activeHandle");if(i){k=i.getStyle("cursor");}if(k=="auto"){k=f.get("dragCursor");}l.setStyles({visibility:"hidden",display:"block",cursor:k,border:j.proxy.get("borderStyle")});if(j.proxy.get("cloneNode")){l=j.proxy.clone();}if(j.proxy.get("resizeFrame")){l.setStyles({height:m.get("offsetHeight")+"px",width:m.get("offsetWidth")+"px"});}if(j.proxy.get("positionProxy")){l.setXY(j.nodeXY);}l.setStyle("visibility","visible");}});},"@VERSION@",{skinnable:false,requires:["dd-drag"]});YUI.add("dd-constrain",function(b){var l="dragNode",n="offsetHeight",e="offsetWidth",q="host",f="tickXArray",o="tickYArray",p=b.DD.DDM,d="top",j="right",m="bottom",c="left",k="view",h=null,i="drag:tickAlignX",g="drag:tickAlignY",a=function(r){this._lazyAddAttrs=false;a.superclass.constructor.apply(this,arguments);};a.NAME="ddConstrained";a.NS="con";a.ATTRS={host:{},stickX:{value:false},stickY:{value:false},tickX:{value:false},tickY:{value:false},tickXArray:{value:false},tickYArray:{value:false},gutter:{value:"0",setter:function(r){return b.DD.DDM.cssSizestoObject(r);}},constrain:{value:k,setter:function(r){var s=b.one(r);if(s){r=s;}return r;}},constrain2region:{setter:function(s){return this.set("constrain",s);}},constrain2node:{setter:function(r){return this.set("constrain",b.one(r));}},constrain2view:{setter:function(r){return this.set("constrain",k);}},cacheRegion:{value:true}};h={_lastTickXFired:null,_lastTickYFired:null,initializer:function(){this._createEvents();this.get(q).on("drag:end",b.bind(this._handleEnd,this));this.get(q).on("drag:start",b.bind(this._handleStart,this));this.get(q).after("drag:align",b.bind(this.align,this));this.get(q).after("drag:drag",b.bind(this.drag,this));},_createEvents:function(){var r=this;var s=[i,g];b.each(s,function(u,t){this.publish(u,{type:u,emitFacade:true,bubbles:true,queuable:false,prefix:"drag"});},this);},_handleEnd:function(){this._lastTickYFired=null;this._lastTickXFired=null;},_handleStart:function(){this.resetCache();},_regionCache:null,_cacheRegion:function(){this._regionCache=this.get("constrain").get("region");},resetCache:function(){this._regionCache=null;},_getConstraint:function(){var r=this.get("constrain"),s=this.get("gutter"),t;if(r){if(r instanceof b.Node){if(!this._regionCache){b.on("resize",b.bind(this._cacheRegion,this),b.config.win);this._cacheRegion();}t=b.clone(this._regionCache);if(!this.get("cacheRegion")){this.resetCache();}}else{if(b.Lang.isObject(r)){t=b.clone(r);}}}if(!r||!t){r=k;}if(r===k){t=this.get(q).get(l).get("viewportRegion");}b.each(s,function(u,v){if((v==j)||(v==m)){t[v]-=u;}else{t[v]+=u;}});return t;},getRegion:function(w){var u={},v=null,s=null,t=this.get(q);u=this._getConstraint();if(w){v=t.get(l).get(n);s=t.get(l).get(e);u[j]=u[j]-s;u[m]=u[m]-v;}return u;},_checkRegion:function(s){var u=s,w=this.getRegion(),v=this.get(q),x=v.get(l).get(n),t=v.get(l).get(e);if(u[1]>(w[m]-x)){s[1]=(w[m]-x);}if(w[d]>u[1]){s[1]=w[d];}if(u[0]>(w[j]-t)){s[0]=(w[j]-t);}if(w[c]>u[0]){s[0]=w[c];}return s;},inRegion:function(t){t=t||this.get(q).get(l).getXY();var s=this._checkRegion([t[0],t[1]]),r=false;if((t[0]===s[0])&&(t[1]===s[1])){r=true;}return r;},align:function(){var u=this.get(q),s=[u.actXY[0],u.actXY[1]],t=this.getRegion(true);if(this.get("stickX")){s[1]=(u.startXY[1]-u.deltaXY[1]);}if(this.get("stickY")){s[0]=(u.startXY[0]-u.deltaXY[0]);}if(t){s=this._checkRegion(s);}s=this._checkTicks(s,t);u.actXY=s;},drag:function(v){var u=this.get(q),s=this.get("tickX"),t=this.get("tickY"),r=[u.actXY[0],u.actXY[1]];if((b.Lang.isNumber(s)||this.get(f))&&(this._lastTickXFired!==r[0])){this._tickAlignX();this._lastTickXFired=r[0];}if((b.Lang.isNumber(t)||this.get(o))&&(this._lastTickYFired!==r[1])){this._tickAlignY();this._lastTickYFired=r[1];}},_checkTicks:function(y,w){var v=this.get(q),x=(v.startXY[0]-v.deltaXY[0]),u=(v.startXY[1]-v.deltaXY[1]),s=this.get("tickX"),t=this.get("tickY");if(s&&!this.get(f)){y[0]=p._calcTicks(y[0],x,s,w[c],w[j]);}if(t&&!this.get(o)){y[1]=p._calcTicks(y[1],u,t,w[d],w[m]);}if(this.get(f)){y[0]=p._calcTickArray(y[0],this.get(f),w[c],w[j]);}if(this.get(o)){y[1]=p._calcTickArray(y[1],this.get(o),w[d],w[m]);}return y;},_tickAlignX:function(){this.fire(i);},_tickAlignY:function(){this.fire(g);}};b.namespace("Plugin");b.extend(a,b.Base,h);b.Plugin.DDConstrained=a;b.mix(p,{_calcTicks:function(y,x,u,w,v){var s=((y-x)/u),t=Math.floor(s),r=Math.ceil(s);if((t!==0)||(r!==0)){if((s>=t)&&(s<=r)){y=(x+(u*t));if(w&&v){if(y
',setter:function(e){if(e.substr(0,1)==="\n"){e=e.substr(1);}if(e===""){e='
';}if(e===" "){if(d.UA.gecko){e='
';}}return this.frame.set("content",e);},getter:function(){return this.frame.get("content");}},dir:{writeOnce:true,value:"ltr"},linkedcss:{value:"",setter:function(e){if(this.frame){this.frame.set("linkedcss",e);}return e;}},extracss:{value:false,setter:function(e){if(this.frame){this.frame.set("extracss",e);}return e;}},defaultblock:{value:"p"}}});d.EditorBase=c;},"@VERSION@",{skinnable:false,requires:["base","frame","node","exec-command","selection"]});YUI.add("editor-lists",function(f){var e=function(){e.superclass.constructor.apply(this,arguments);},b="li",c="ol",d="ul",a="host";f.extend(e,f.Base,{_onNodeChange:function(l){var j=this.get(a).getInstance(),g,o,p,h,i,m,n=false,q,k=false;if(l.changedType==="tab"){if(l.changedNode.test(b+", "+b+" *")){l.changedEvent.halt();l.preventDefault();o=l.changedNode;i=l.changedEvent.shiftKey;m=o.ancestor(c+","+d);q=d;if(m.get("tagName").toLowerCase()===c){q=c;}if(!o.test(b)){o=o.ancestor(b);}if(i){if(o.ancestor(b)){o.ancestor(b).insert(o,"after");n=true;k=true;}}else{if(o.previous(b)){h=j.Node.create("<"+q+">"+q+">");o.previous(b).append(h);h.append(o);n=true;}}}if(n){if(!o.test(b)){o=o.ancestor(b);}o.all(e.REMOVE).remove();if(f.UA.ie){o=o.append(e.NON).one(e.NON_SEL);}(new j.Selection()).selectNode(o,true,k);}}},initializer:function(){this.get(a).on("nodeChange",f.bind(this._onNodeChange,this));}},{NON:' ',NON_SEL:"span.yui-non",REMOVE:"br",NAME:"editorLists",NS:"lists",ATTRS:{host:{value:false}}});f.namespace("Plugin");f.Plugin.EditorLists=e;},"@VERSION@",{skinnable:false,requires:["editor-base"]});YUI.add("editor-bidi",function(a){var b=function(){b.superclass.constructor.apply(this,arguments);},i="host",h="dir",f="BODY",d="nodeChange",e="bidiContextChange",c=f+" > p",g="style";a.extend(b,a.Base,{lastDirection:null,firstEvent:null,_checkForChange:function(){var k=this.get(i),m=k.getInstance(),l=new m.Selection(),j,n;if(l.isCollapsed){j=b.blockParent(l.focusNode);if(j){n=j.getStyle("direction");if(n!==this.lastDirection){k.fire(e,{changedTo:n});this.lastDirection=n;}}}else{k.fire(e,{changedTo:"select"});this.lastDirection=null;}},_afterNodeChange:function(j){if(this.firstEvent||b.EVENTS[j.changedType]){this._checkForChange();this.firstEvent=false;}},_afterMouseUp:function(j){this._checkForChange();this.firstEvent=false;},initializer:function(){var j=this.get(i);this.firstEvent=true;j.after(d,a.bind(this._afterNodeChange,this));j.after("dom:mouseup",a.bind(this._afterMouseUp,this));}},{EVENTS:{"backspace-up":true,"pageup-up":true,"pagedown-down":true,"end-up":true,"home-up":true,"left-up":true,"up-up":true,"right-up":true,"down-up":true,"delete-up":true},BLOCKS:a.Selection.BLOCKS,DIV_WRAPPER:"",blockParent:function(l,k){var j=l,n,m;if(!j){j=a.one(f);}if(!j.test(b.BLOCKS)){j=j.ancestor(b.BLOCKS);}if(k&&j.test(f)){n=a.Node.create(b.DIV_WRAPPER);j.get("children").each(function(p,o){if(o===0){m=p;}else{n.append(p);}});m.replace(n);n.prepend(m);j=n;}return j;},_NODE_SELECTED:"bidiSelected",addParents:function(m){var j,l,k;for(j=0;
j
",i="firstChild",e="li";a.extend(d,a.Base,{_fixFirstPara:function(){var p=this.get(k),r=p.getInstance(),q,s,l=r.config.doc.body,o=l.innerHTML,m=((o.length)?true:false);if(o===g){o="";m=false;}l.innerHTML="<"+h+">"+o+r.Selection.CURSOR+""+h+">";s=r.one(b);q=new r.Selection();q.selectNode(s,true,m);},_onNodeChange:function(Q){var F=this.get(k),q=F.getInstance(),x,D,C,S,N,H=q.Selection.DEFAULT_BLOCK_TAG,z,o,s,O,v,l,G,L,u,M,U,R,J,B,A,P=":last-child";switch(Q.changedType){case"enter-up":var m=((this._lastPara)?this._lastPara:Q.changedNode),T=m.one("br.yui-cursor");if(this._lastPara){delete this._lastPara;}if(T){if(T.previous()||T.next()){if(T.ancestor(h)){T.remove();}}}if(!m.test(H)){var E=m.ancestor(H);if(E){m=E;E=null;}}if(m.test(H)){var I=m.previous(),K,w,y=false;if(I){K=I.one(P);while(!y){if(K){w=K.one(P);if(w){K=w;}else{y=true;}}else{y=true;}}if(K){F.copyStyles(K,m);}}}break;case"enter":if(a.UA.ie){if(Q.changedNode.test("br")){Q.changedNode.remove();}else{if(Q.changedNode.test("p, span")){var T=Q.changedNode.one("br.yui-cursor");if(T){T.remove();}}}}if(a.UA.webkit){if(Q.changedEvent.shiftKey){F.execCommand("insertbr");Q.changedEvent.preventDefault();}}if(a.UA.gecko&&F.get("defaultblock")!=="p"){C=Q.changedNode;if(!C.test(e)&&!C.ancestor(e)){if(!C.test(H)){C=C.ancestor(H);}S=q.Node.create("<"+H+">"+H+">");C.insert(S,"after");N=new q.Selection();if(N.anchorOffset){z=N.anchorNode.get("textContent");D=q.one(q.config.doc.createTextNode(z.substr(0,N.anchorOffset)));o=q.one(q.config.doc.createTextNode(z.substr(N.anchorOffset)));O=N.anchorNode;O.setContent("");l=O.cloneNode();l.append(o);G=false;u=O;while(!G){u=u.get(j);if(u&&!u.test(H)){L=u.cloneNode();L.set("innerHTML","");L.append(l);s=u.get("childNodes");var r=false;s.each(function(n){if(r){L.append(n);}if(n===O){r=true;}});O=u;l=L;}else{G=true;}}o=l;N.anchorNode.append(D);if(o){S.append(o);}}if(S.get(i)){S=S.get(i);}S.prepend(q.Selection.CURSOR);N.focusCursor(true,true);x=q.Selection.getText(S);if(x!==""){q.Selection.cleanCursor();}Q.changedEvent.preventDefault();}}break;case"keyup":if(a.UA.gecko){if(q.config.doc&&q.config.doc.body&&q.config.doc.body.innerHTML.length<2){this._fixFirstPara();}}break;case"backspace-up":case"backspace-down":case"delete-up":if(!a.UA.ie){M=q.all(b);R=q.one(f);if(M.item(0)){R=M.item(0);}U=R.one("br");if(U){U.removeAttribute("id");U.removeAttribute("class");}D=q.Selection.getText(R);D=D.replace(/ /g,"").replace(/\n/g,"");B=R.all("img");if(D.length===0&&!B.size()){if(!R.test(h)){this._fixFirstPara();}J=null;if(Q.changedNode&&Q.changedNode.test(h)){J=Q.changedNode;}if(!J&&F._lastPara&&F._lastPara.inDoc()){J=F._lastPara;}if(J&&!J.test(h)){J=J.ancestor(h);}if(J){if(!J.previous()&&J.get(j)&&J.get(j).test(f)){Q.changedEvent.frameEvent.halt();}}}if(a.UA.webkit){if(Q.changedNode){R=Q.changedNode;if(R.test("li")&&(!R.previous()&&!R.next())){x=R.get("innerHTML").replace(g,"");if(x===""){if(R.get(j)){R.get(j).replace(q.Node.create(g));Q.changedEvent.frameEvent.halt();Q.preventDefault();q.Selection.filterBlocks();}}}}}}if(a.UA.gecko){S=Q.changedNode;A=q.config.doc.createTextNode(" ");S.appendChild(A);S.removeChild(A);}break;}if(a.UA.gecko){if(Q.changedNode&&!Q.changedNode.test(H)){J=Q.changedNode.ancestor(H);if(J){this._lastPara=J;}}}},_afterEditorReady:function(){var m=this.get(k),n=m.getInstance(),l;if(n){n.Selection.filterBlocks();l=n.Selection.DEFAULT_BLOCK_TAG;b=f+" > "+l;h=l;}},_afterContentChange:function(){var l=this.get(k),m=l.getInstance();if(m&&m.Selection){m.Selection.filterBlocks();}},_afterPaste:function(){var l=this.get(k),n=l.getInstance(),m=new n.Selection();a.later(50,l,function(){n.Selection.filterBlocks();});},initializer:function(){var l=this.get(k);if(l.editorBR){a.error("Can not plug EditorPara and EditorBR at the same time.");return;}l.on(c,a.bind(this._onNodeChange,this));l.after("ready",a.bind(this._afterEditorReady,this));l.after("contentChange",a.bind(this._afterContentChange,this));if(a.Env.webkit){l.after("dom:paste",a.bind(this._afterPaste,this));}}},{NAME:"editorPara",NS:"editorPara",ATTRS:{host:{value:false}}});a.namespace("Plugin");a.Plugin.EditorPara=d;},"@VERSION@",{skinnable:false,requires:["editor-base"]});YUI.add("editor-br",function(c){var d=function(){d.superclass.constructor.apply(this,arguments);
-},a="host",b="li";c.extend(d,c.Base,{_onKeyDown:function(j){if(j.stopped){j.halt();return;}if(j.keyCode==13){var g=this.get(a),i=g.getInstance(),h=new i.Selection(),f="";if(h){if(c.UA.ie){if(!h.anchorNode||(!h.anchorNode.test(b)&&!h.anchorNode.ancestor(b))){h._selection.pasteHTML("
");h._selection.collapse(false);h._selection.select();j.halt();}}if(c.UA.webkit){if(!h.anchorNode.test(b)&&!h.anchorNode.ancestor(b)){g.frame._execCommand("insertlinebreak",null);j.halt();}}}}},_afterEditorReady:function(){var e=this.get(a).getInstance();try{e.config.doc.execCommand("insertbronreturn",null,true);}catch(f){}if(c.UA.ie||c.UA.webkit){e.on("keydown",c.bind(this._onKeyDown,this),e.config.doc);}},_onNodeChange:function(h){switch(h.changedType){case"backspace-up":case"backspace-down":case"delete-up":var g=this.get(a).getInstance();var i=h.changedNode;var f=g.config.doc.createTextNode(" ");i.appendChild(f);i.removeChild(f);break;}},initializer:function(){var e=this.get(a);if(e.editorPara){c.error("Can not plug EditorBR and EditorPara at the same time.");return;}e.after("ready",c.bind(this._afterEditorReady,this));if(c.UA.gecko){e.on("nodeChange",c.bind(this._onNodeChange,this));}}},{NAME:"editorBR",NS:"editorBR",ATTRS:{host:{value:false}}});c.namespace("Plugin");c.Plugin.EditorBR=d;},"@VERSION@",{skinnable:false,requires:["editor-base"]});YUI.add("editor",function(a){},"@VERSION@",{use:["frame","selection","exec-command","editor-base","editor-para","editor-br","editor-bidi","editor-tab","createlink-base"],skinnable:false});
\ No newline at end of file
+},a="host",b="li";c.extend(d,c.Base,{_onKeyDown:function(j){if(j.stopped){j.halt();return;}if(j.keyCode==13){var g=this.get(a),i=g.getInstance(),h=new i.Selection(),f="";if(h){if(c.UA.ie){if(!h.anchorNode||(!h.anchorNode.test(b)&&!h.anchorNode.ancestor(b))){h._selection.pasteHTML("
");h._selection.collapse(false);h._selection.select();j.halt();}}if(c.UA.webkit){if(!h.anchorNode.test(b)&&!h.anchorNode.ancestor(b)){g.frame._execCommand("insertlinebreak",null);j.halt();}}}}},_afterEditorReady:function(){var e=this.get(a).getInstance();try{e.config.doc.execCommand("insertbronreturn",null,true);}catch(f){}if(c.UA.ie||c.UA.webkit){e.on("keydown",c.bind(this._onKeyDown,this),e.config.doc);}},_onNodeChange:function(h){switch(h.changedType){case"backspace-up":case"backspace-down":case"delete-up":var g=this.get(a).getInstance();var i=h.changedNode;var f=g.config.doc.createTextNode(" ");i.appendChild(f);i.removeChild(f);break;}},initializer:function(){var e=this.get(a);if(e.editorPara){c.error("Can not plug EditorBR and EditorPara at the same time.");return;}e.after("ready",c.bind(this._afterEditorReady,this));if(c.UA.gecko){e.on("nodeChange",c.bind(this._onNodeChange,this));}}},{NAME:"editorBR",NS:"editorBR",ATTRS:{host:{value:false}}});c.namespace("Plugin");c.Plugin.EditorBR=d;},"@VERSION@",{skinnable:false,requires:["editor-base"]});YUI.add("editor",function(a){},"@VERSION@",{skinnable:false,use:["frame","selection","exec-command","editor-base","editor-para","editor-br","editor-bidi","editor-tab","createlink-base"]});
\ No newline at end of file
diff --git a/build/editor/editor.js b/build/editor/editor.js
index de2e7046c87..817418c1f26 100644
--- a/build/editor/editor.js
+++ b/build/editor/editor.js
@@ -4613,5 +4613,5 @@ YUI.add('editor-br', function(Y) {
}, '@VERSION@' ,{skinnable:false, requires:['editor-base']});
-YUI.add('editor', function(Y){}, '@VERSION@' ,{use:['frame', 'selection', 'exec-command', 'editor-base', 'editor-para', 'editor-br', 'editor-bidi', 'editor-tab', 'createlink-base'], skinnable:false});
+YUI.add('editor', function(Y){}, '@VERSION@' ,{skinnable:false, use:['frame', 'selection', 'exec-command', 'editor-base', 'editor-para', 'editor-br', 'editor-bidi', 'editor-tab', 'createlink-base']});
diff --git a/build/get/get-debug.js b/build/get/get-debug.js
index c14fad6955d..9c93f50a1bd 100644
--- a/build/get/get-debug.js
+++ b/build/get/get-debug.js
@@ -1,6 +1,5 @@
YUI.add('get', function(Y) {
-
/**
* Provides a mechanism to fetch remote resources and
* insert them into a document.
@@ -8,26 +7,41 @@ YUI.add('get', function(Y) {
* @submodule get
*/
-var ua = Y.UA,
- L = Y.Lang,
- TYPE_JS = 'text/javascript',
- TYPE_CSS = 'text/css',
- STYLESHEET = 'stylesheet';
-
/**
* Fetches and inserts one or more script or link nodes into the document
* @class Get
* @static
*/
-Y.Get = function() {
+
+var ua = Y.UA,
+ L = Y.Lang,
+ TYPE_JS = 'text/javascript',
+ TYPE_CSS = 'text/css',
+ STYLESHEET = 'stylesheet',
+ SCRIPT = 'script',
+ AUTOPURGE = 'autopurge',
+ UTF8 = 'utf-8',
+ LINK = 'link',
+ ASYNC = 'async',
+ ALL = true,
+
+ // FireFox does not support the onload event for link nodes, so
+ // there is no way to make the css requests synchronous. This means
+ // that the css rules in multiple files could be applied out of order
+ // in this browser if a later request returns before an earlier one.
+
+ // Safari too.
+
+ ONLOAD_SUPPORTED = {
+ script: ALL,
+ css: !(ua.webkit || ua.gecko)
+ },
/**
* hash of queues to manage multiple requests
* @property queues
* @private
*/
- var _get, _purge, _track,
-
queues = {},
/**
@@ -47,22 +61,41 @@ Y.Get = function() {
*/
purging,
+ /**
+ * Clear timeout state
+ *
+ * @method _clearTimeout
+ * @param {Object} q Queue data
+ * @private
+ */
+ _clearTimeout = function(q) {
+ var timer = q.timer;
+ if (timer) {
+ clearTimeout(timer);
+ q.timer = null;
+ }
+ },
/**
* Generates an HTML element, this is not appended to a document
* @method _node
* @param {string} type the type of element.
- * @param {string} attr the attributes.
+ * @param {Object} attr the fixed set of attribute for the type.
+ * @param {Object} custAttrs optional Any custom attributes provided by the user.
* @param {Window} win optional window to create the element in.
* @return {HTMLElement} the generated node.
* @private
*/
- _node = function(type, attr, win) {
+ _node = function(type, attr, custAttrs, win) {
var w = win || Y.config.win,
d = w.document,
n = d.createElement(type),
i;
+ if (custAttrs) {
+ Y.mix(attr, custAttrs);
+ }
+
for (i in attr) {
if (attr[i] && attr.hasOwnProperty(i)) {
n.setAttribute(i, attr[i]);
@@ -83,16 +116,12 @@ Y.Get = function() {
* @private
*/
_linkNode = function(url, win, attributes) {
- var o = {
- id: Y.guid(),
- type: TYPE_CSS,
- rel: STYLESHEET,
- href: url
- };
- if (attributes) {
- Y.mix(o, attributes);
- }
- return _node('link', o, win);
+ return _node(LINK, {
+ id: Y.guid(),
+ type: TYPE_CSS,
+ rel: STYLESHEET,
+ href: url
+ }, attributes, win);
},
/**
@@ -106,18 +135,11 @@ Y.Get = function() {
* @private
*/
_scriptNode = function(url, win, attributes) {
- var o = {
- id: Y.guid(),
- type: TYPE_JS
- };
-
- if (attributes) {
- Y.mix(o, attributes);
- }
-
- o.src = url;
-
- return _node('script', o, win);
+ return _node(SCRIPT, {
+ id: Y.guid(),
+ type: TYPE_JS,
+ src: url
+ }, attributes, win);
},
/**
@@ -131,16 +153,17 @@ Y.Get = function() {
*/
_returnData = function(q, msg, result) {
return {
- tId: q.tId,
- win: q.win,
- data: q.data,
- nodes: q.nodes,
- msg: msg,
- statusText: result,
- purge: function() {
- _purge(this.tId);
- }
- };
+ tId: q.tId,
+ win: q.win,
+ data: q.data,
+ nodes: q.nodes,
+ msg: msg,
+ statusText: result,
+
+ purge: function() {
+ _purge(this.tId);
+ }
+ };
},
/**
@@ -152,14 +175,17 @@ Y.Get = function() {
* @private
*/
_end = function(id, msg, result) {
- var q = queues[id], sc;
- if (q && q.onEnd) {
- sc = q.context || q;
- q.onEnd.call(sc, _returnData(q, msg, result));
+ var q = queues[id],
+ onEnd = q && q.onEnd;
+
+ q.finished = true;
+
+ if (onEnd) {
+ onEnd.call(q.context, _returnData(q, msg, result));
}
},
- /*
+ /**
* The request failed, execute fail handler with whatever
* was accomplished. There isn't a failure case at the
* moment unless you count aborted transactions
@@ -170,49 +196,144 @@ Y.Get = function() {
_fail = function(id, msg) {
Y.log('get failure: ' + msg, 'warn', 'get');
- var q = queues[id], sc;
- if (q.timer) {
- // q.timer.cancel();
- clearTimeout(q.timer);
- }
+ var q = queues[id],
+ onFailure = q.onFailure;
+
+ _clearTimeout(q);
- // execute failure callback
- if (q.onFailure) {
- sc = q.context || q;
- q.onFailure.call(sc, _returnData(q, msg));
+ if (onFailure) {
+ onFailure.call(q.context, _returnData(q, msg));
}
_end(id, msg, 'failure');
},
+
+ /**
+ * Abort the transaction
+ *
+ * @method _abort
+ * @param {Object} id
+ * @private
+ */
+ _abort = function(id) {
+ _fail(id, 'transaction ' + id + ' was aborted');
+ },
+
/**
* The request is complete, so executing the requester's callback
- * @method _finish
+ * @method _complete
* @param {string} id the id of the request.
* @private
*/
- _finish = function(id) {
- // Y.log("Finishing transaction " + id, "info", "get");
- var q = queues[id], msg, sc;
- if (q.timer) {
- // q.timer.cancel();
- clearTimeout(q.timer);
- }
- q.finished = true;
+ _complete = function(id) {
+ Y.log("Finishing transaction " + id, "info", "get");
+
+ var q = queues[id],
+ onSuccess = q.onSuccess;
+
+ _clearTimeout(q);
if (q.aborted) {
- msg = 'transaction ' + id + ' was aborted';
- _fail(id, msg);
- return;
+ _abort(id);
+ } else {
+
+ if (onSuccess) {
+ onSuccess.call(q.context, _returnData(q));
+ }
+
+ // 3.3.0 had undefined msg for this path.
+ _end(id, undefined, 'OK');
}
+ },
+
+ /**
+ * Get node reference, from string
+ *
+ * @method _getNodeRef
+ * @param {String|HTMLElement} nId The node id to find. If an HTMLElement is passed in, it will be returned.
+ * @param {String} tId Queue id, used to determine document for queue
+ * @private
+ */
+ _getNodeRef = function(nId, tId) {
+ var q = queues[tId],
+ n = (L.isString(nId)) ? q.win.document.getElementById(nId) : nId;
+ if (!n) {
+ _fail(tId, 'target node not found: ' + nId);
+ }
+
+ return n;
+ },
+
+ /**
+ * Removes the nodes for the specified queue
+ * @method _purge
+ * @param {string} tId the transaction id.
+ * @private
+ */
+ _purge = function(tId) {
+ var nodes, doc, parent, sibling, node, attr, insertBefore,
+ i, l,
+ q = queues[tId];
+
+ if (q) {
+ nodes = q.nodes;
+ l = nodes.length;
+
+ // TODO: Why is node.parentNode undefined? Which forces us to do this...
+ /*
+ doc = q.win.document;
+ parent = doc.getElementsByTagName('head')[0];
+ insertBefore = q.insertBefore || doc.getElementsByTagName('base')[0];
+
+ if (insertBefore) {
+ sibling = _getNodeRef(insertBefore, tId);
+ if (sibling) {
+ parent = sibling.parentNode;
+ }
+ }
+ */
+
+ for (i = 0; i < l; i++) {
+ node = nodes[i];
+ parent = node.parentNode;
- // execute success callback
- if (q.onSuccess) {
- sc = q.context || q;
- q.onSuccess.call(sc, _returnData(q));
+ if (node.clearAttributes) {
+ node.clearAttributes();
+ } else {
+ // This destroys parentNode ref, so we hold onto it above first.
+ for (attr in node) {
+ if (node.hasOwnProperty(attr)) {
+ delete node[attr];
+ }
+ }
+ }
+
+ parent.removeChild(node);
+ }
}
- _end(id, msg, 'OK');
+ q.nodes = [];
+ },
+
+ /**
+ * Progress callback
+ *
+ * @method _progress
+ * @param {string} id The id of the request.
+ * @param {string} The url which just completed.
+ * @private
+ */
+ _progress = function(id, url) {
+ var q = queues[id],
+ onProgress = q.onProgress,
+ o;
+
+ if (onProgress) {
+ o = _returnData(q);
+ o.url = url;
+ onProgress.call(q.context, o);
+ }
},
/**
@@ -223,120 +344,185 @@ Y.Get = function() {
*/
_timeout = function(id) {
Y.log('Timeout ' + id, 'info', 'get');
- var q = queues[id], sc;
- if (q.onTimeout) {
- sc = q.context || q;
- q.onTimeout.call(sc, _returnData(q));
+
+ var q = queues[id],
+ onTimeout = q.onTimeout;
+
+ if (onTimeout) {
+ onTimeout.call(q.context, _returnData(q));
}
_end(id, 'timeout', 'timeout');
},
-
/**
- * Loads the next item for a given request
- * @method _next
+ * onload callback
+ * @method _loaded
* @param {string} id the id of the request.
- * @param {string} loaded the url that was just loaded, if any.
* @return {string} the result.
* @private
*/
- _next = function(id, loaded) {
-// Y.log("_next: " + id + ", loaded: " + (loaded || "nothing"), "info", "get");
- var q = queues[id], msg, w, d, h, n, url, s,
- insertBefore;
-
- if (q.timer) {
- // Y.log('cancel timer');
- // q.timer.cancel();
- clearTimeout(q.timer);
- }
+ _loaded = function(id, url) {
- if (q.aborted) {
- msg = 'transaction ' + id + ' was aborted';
- _fail(id, msg);
- return;
+ var q = queues[id],
+ sync = !q.async;
+
+ if (sync) {
+ _clearTimeout(q);
}
- if (loaded) {
- q.url.shift();
- if (q.varName) {
- q.varName.shift();
- }
- } else {
- // This is the first pass: make sure the url is an array
- q.url = (L.isString(q.url)) ? [q.url] : q.url;
- if (q.varName) {
- q.varName = (L.isString(q.varName)) ? [q.varName] : q.varName;
+ _progress(id, url);
+
+ // TODO: Cleaning up flow to have a consistent end point
+
+ // !q.finished check is for the async case,
+ // where scripts may still be loading when we've
+ // already aborted. Ideally there should be a single path
+ // for this.
+
+ if (!q.finished) {
+ if (q.aborted) {
+ _abort(id);
+ } else {
+ if ((--q.remaining) === 0) {
+ _complete(id);
+ } else if (sync) {
+ _next(id);
+ }
}
}
+ },
- w = q.win;
- d = w.document;
- h = d.getElementsByTagName('head')[0];
+ /**
+ * Detects when a node has been loaded. In the case of
+ * script nodes, this does not guarantee that contained
+ * script is ready to use.
+ * @method _trackLoad
+ * @param {string} type the type of node to track.
+ * @param {HTMLElement} n the node to track.
+ * @param {string} id the id of the request.
+ * @param {string} url the url that is being loaded.
+ * @private
+ */
+ _trackLoad = function(type, n, id, url) {
- if (q.url.length === 0) {
- _finish(id);
- return;
- }
+ // TODO: Can we massage this to use ONLOAD_SUPPORTED[type]?
- url = q.url[0];
+ // IE supports the readystatechange event for script and css nodes
+ // Opera only for script nodes. Opera support onload for script
+ // nodes, but this doesn't fire when there is a load failure.
+ // The onreadystatechange appears to be a better way to respond
+ // to both success and failure.
- // if the url is undefined, this is probably a trailing comma
- // problem in IE.
- if (!url) {
- q.url.shift();
- Y.log('skipping empty url');
- return _next(id);
- }
+ if (ua.ie) {
- Y.log('attempting to load ' + url, 'info', 'get');
+ n.onreadystatechange = function() {
+ var rs = this.readyState;
+ if ('loaded' === rs || 'complete' === rs) {
+ // Y.log(id + " onreadstatechange " + url, "info", "get");
+ n.onreadystatechange = null;
+ _loaded(id, url);
+ }
+ };
- if (q.timeout) {
- // Y.log('create timer');
- // q.timer = L.later(q.timeout, q, _timeout, id);
- q.timer = setTimeout(function() {
- _timeout(id);
- }, q.timeout);
- }
+ } else if (ua.webkit) {
+
+ // webkit prior to 3.x is no longer supported
+ if (type === SCRIPT) {
+ // Safari 3.x supports the load event for script nodes (DOM2)
+ n.addEventListener('load', function() {
+ _loaded(id, url);
+ }, false);
+ }
- if (q.type === 'script') {
- n = _scriptNode(url, w, q.attributes);
} else {
- n = _linkNode(url, w, q.attributes);
- }
- // track this node's load progress
- _track(q.type, n, id, url, w, q.url.length);
+ // FireFox and Opera support onload (but not DOM2 in FF) handlers for
+ // script nodes. Opera, but not FF, supports the onload event for link nodes.
- // add the node to the queue so we can return it to the user supplied
- // callback
- q.nodes.push(n);
+ n.onload = function() {
+ // Y.log(id + " onload " + url, "info", "get");
+ _loaded(id, url);
+ };
- // add it to the head or insert it before 'insertBefore'. Work around
- // IE bug if there is a base tag.
- insertBefore = q.insertBefore ||
- d.getElementsByTagName('base')[0];
+ n.onerror = function(e) {
+ _fail(id, e + ': ' + url);
+ };
+ }
+ },
+
+ _insertInDoc = function(node, id, win) {
+
+ // Add it to the head or insert it before 'insertBefore'.
+ // Work around IE bug if there is a base tag.
+ var q = queues[id],
+ doc = win.document,
+ insertBefore = q.insertBefore || doc.getElementsByTagName('base')[0],
+ sibling;
if (insertBefore) {
- s = _get(insertBefore, id);
- if (s) {
+ sibling = _getNodeRef(insertBefore, id);
+ if (sibling) {
Y.log('inserting before: ' + insertBefore, 'info', 'get');
- s.parentNode.insertBefore(n, s);
+ sibling.parentNode.insertBefore(node, sibling);
}
} else {
- h.appendChild(n);
+ // 3.3.0 assumed head is always around.
+ doc.getElementsByTagName('head')[0].appendChild(node);
}
+ },
+
+ /**
+ * Loads the next item for a given request
+ * @method _next
+ * @param {string} id the id of the request.
+ * @return {string} the result.
+ * @private
+ */
+ _next = function(id) {
+
+ // Assigning out here for readability
+ var q = queues[id],
+ type = q.type,
+ attrs = q.attributes,
+ win = q.win,
+ timeout = q.timeout,
+ node,
+ url;
+
+ if (q.url.length > 0) {
+
+ url = q.url.shift();
- // Y.log("Appending node: " + url, "info", "get");
+ Y.log('attempting to load ' + url, 'info', 'get');
- // FireFox does not support the onload event for link nodes, so
- // there is no way to make the css requests synchronous. This means
- // that the css rules in multiple files could be applied out of order
- // in this browser if a later request returns before an earlier one.
- // Safari too.
- if ((ua.webkit || ua.gecko) && q.type === 'css') {
- _next(id, url);
+ // !q.timer ensures that this only happens once for async
+ if (timeout && !q.timer) {
+ q.timer = setTimeout(function() {
+ _timeout(id);
+ }, timeout);
+ }
+
+ if (type === SCRIPT) {
+ node = _scriptNode(url, win, attrs);
+ } else {
+ node = _linkNode(url, win, attrs);
+ }
+
+ // add the node to the queue so we can return it in the callback
+ q.nodes.push(node);
+
+ _trackLoad(type, node, id, url);
+ _insertInDoc(node, id, win);
+
+ if (!ONLOAD_SUPPORTED[type]) {
+ _loaded(id, url);
+ }
+
+ if (q.async) {
+ // For sync, the _next call is chained in _loaded
+ _next(id);
+ }
}
},
@@ -377,31 +563,47 @@ Y.Get = function() {
* @private
*/
_queue = function(type, url, opts) {
+
opts = opts || {};
- var id = 'q' + (qidx++), q,
- thresh = opts.purgethreshold || Y.Get.PURGE_THRESH;
+ var id = 'q' + (qidx++),
+ thresh = opts.purgethreshold || Y.Get.PURGE_THRESH,
+ q;
if (qidx % thresh === 0) {
_autoPurge();
}
- queues[id] = Y.merge(opts, {
- tId: id,
- type: type,
- url: url,
- finished: false,
- nodes: []
- });
+ // Merge to protect opts (grandfathered in).
+ q = queues[id] = Y.merge(opts);
+
+ // Avoid mix, merge overhead. Known set of props.
+ q.tId = id;
+ q.type = type;
+ q.url = url;
+ q.finished = false;
+ q.nodes = [];
- q = queues[id];
q.win = q.win || Y.config.win;
q.context = q.context || q;
- q.autopurge = ('autopurge' in q) ? q.autopurge :
- (type === 'script') ? true : false;
-
+ q.autopurge = (AUTOPURGE in q) ? q.autopurge : (type === SCRIPT) ? true : false;
q.attributes = q.attributes || {};
- q.attributes.charset = opts.charset || q.attributes.charset || 'utf-8';
+ q.attributes.charset = opts.charset || q.attributes.charset || UTF8;
+
+ if (ASYNC in q && type === SCRIPT) {
+ q.attributes.async = q.async;
+ }
+
+ q.url = (L.isString(q.url)) ? [q.url] : q.url;
+
+ // TODO: Do we really need to account for this developer error?
+ // If the url is undefined, this is probably a trailing comma problem in IE.
+ if (!q.url[0]) {
+ q.url.shift();
+ Y.log('skipping empty url');
+ }
+
+ q.remaining = q.url.length;
_next(id);
@@ -410,364 +612,264 @@ Y.Get = function() {
};
};
+
+Y.Get = {
+
/**
- * Detects when a node has been loaded. In the case of
- * script nodes, this does not guarantee that contained
- * script is ready to use.
- * @method _track
- * @param {string} type the type of node to track.
- * @param {HTMLElement} n the node to track.
- * @param {string} id the id of the request.
- * @param {string} url the url that is being loaded.
- * @param {Window} win the targeted window.
- * @param {int} qlength the number of remaining items in the queue,
- * including this one.
- * @param {Function} trackfn function to execute when finished
- * the default is _next.
+ * The number of request required before an automatic purge.
+ * Can be configured via the 'purgethreshold' config
+ * property PURGE_THRESH
+ * @static
+ * @type int
+ * @default 20
* @private
*/
- _track = function(type, n, id, url, win, qlength, trackfn) {
- var f = trackfn || _next;
-
- // IE supports the readystatechange event for script and css nodes
- // Opera only for script nodes. Opera support onload for script
- // nodes, but this doesn't fire when there is a load failure.
- // The onreadystatechange appears to be a better way to respond
- // to both success and failure.
- if (ua.ie) {
- n.onreadystatechange = function() {
- var rs = this.readyState;
- if ('loaded' === rs || 'complete' === rs) {
- // Y.log(id + " onreadstatechange " + url, "info", "get");
- n.onreadystatechange = null;
- f(id, url);
- }
- };
-
- // webkit prior to 3.x is no longer supported
- } else if (ua.webkit) {
- if (type === 'script') {
- // Safari 3.x supports the load event for script nodes (DOM2)
- n.addEventListener('load', function() {
- // Y.log(id + " DOM2 onload " + url, "info", "get");
- f(id, url);
- }, false);
- }
-
- // FireFox and Opera support onload (but not DOM2 in FF) handlers for
- // script nodes. Opera, but not FF, supports the onload event for link
- // nodes.
- } else {
- n.onload = function() {
- // Y.log(id + " onload " + url, "info", "get");
- f(id, url);
- };
-
- n.onerror = function(e) {
- _fail(id, e + ': ' + url);
- };
- }
- };
-
- _get = function(nId, tId) {
- var q = queues[tId],
- n = (L.isString(nId)) ? q.win.document.getElementById(nId) : nId;
- if (!n) {
- _fail(tId, 'target node not found: ' + nId);
- }
-
- return n;
- };
+ PURGE_THRESH: 20,
/**
- * Removes the nodes for the specified queue
- * @method _purge
- * @param {string} tId the transaction id.
- * @private
+ * Abort a transaction
+ * @method abort
+ * @static
+ * @param {string|object} o Either the tId or the object returned from
+ * script() or css().
*/
- _purge = function(tId) {
- var n, l, d, h, s, i, node, attr, insertBefore,
- q = queues[tId];
+ abort : function(o) {
+ var id = (L.isString(o)) ? o : o.tId,
+ q = queues[id];
if (q) {
- n = q.nodes;
- l = n.length;
- d = q.win.document;
- h = d.getElementsByTagName('head')[0];
-
- insertBefore = q.insertBefore ||
- d.getElementsByTagName('base')[0];
-
- if (insertBefore) {
- s = _get(insertBefore, tId);
- if (s) {
- h = s.parentNode;
- }
- }
-
- for (i = 0; i < l; i = i + 1) {
- node = n[i];
- if (node.clearAttributes) {
- node.clearAttributes();
- } else {
- for (attr in node) {
- if (node.hasOwnProperty(attr)) {
- delete node[attr];
- }
- }
- }
-
- h.removeChild(node);
- }
+ Y.log('Aborting ' + id, 'info', 'get');
+ q.aborted = true;
}
- q.nodes = [];
- };
+ },
- return {
-
- /**
- * The number of request required before an automatic purge.
- * Can be configured via the 'purgethreshold' config
- * property PURGE_THRESH
- * @static
- * @type int
- * @default 20
- * @private
- */
- PURGE_THRESH: 20,
-
- /**
- * Called by the the helper for detecting script load in Safari
- * @method _finalize
- * @static
- * @param {string} id the transaction id.
- * @private
- */
- _finalize: function(id) {
- Y.log(id + ' finalized ', 'info', 'get');
- setTimeout(function() {
- _finish(id);
- }, 0);
- },
-
- /**
- * Abort a transaction
- * @method abort
- * @static
- * @param {string|object} o Either the tId or the object returned from
- * script() or css().
- */
- abort: function(o) {
- var id = (L.isString(o)) ? o : o.tId,
- q = queues[id];
- if (q) {
- Y.log('Aborting ' + id, 'info', 'get');
- q.aborted = true;
- }
- },
-
- /**
- * Fetches and inserts one or more script nodes into the head
- * of the current document or the document in a specified window.
- *
- * @method script
- * @static
- * @param {string|string[]} url the url or urls to the script(s).
- * @param {object} opts Options:
- *
- *
- *
- *
- *
- *
- *
- *
- *
- * Y.Get.script(
- * ["http://yui.yahooapis.com/2.5.2/build/yahoo/yahoo-min.js",
- * "http://yui.yahooapis.com/2.5.2/build/event/event-min.js"],
- * {
- * onSuccess: function(o) {
- * this.log("won't cause error because Y is the context");
- * Y.log(o.data); // foo
- * Y.log(o.nodes.length === 2) // true
- * // o.purge(); // optionally remove the script nodes
- * // immediately
- * },
- * onFailure: function(o) {
- * Y.log("transaction failed");
- * },
- * onTimeout: function(o) {
- * Y.log("transaction timed out");
- * },
- * data: "foo",
- * timeout: 10000, // 10 second timeout
- * context: Y, // make the YUI instance
- * // win: otherframe // target another window/frame
- * autopurge: true // allow the utility to choose when to
- * // remove the nodes
- * purgetheshold: 1 // purge previous transaction before
- * // next transaction
- * });.
- *
- * @return {tId: string} an object containing info about the
- * transaction.
- */
- script: function(url, opts) {
- return _queue('script', url, opts);
- },
-
- /**
- * Fetches and inserts one or more css link nodes into the
- * head of the current document or the document in a specified
- * window.
- * @method css
- * @static
- * @param {string} url the url or urls to the css file(s).
- * @param {object} opts Options:
- *
- *
- *
- * win
- *
- * Y.Get.css("http://localhost/css/menu.css");
- *
- *
- * Y.Get.css(
- * ["http://localhost/css/menu.css",
- * "http://localhost/css/logger.css"], {
- * insertBefore: 'custom-styles' // nodes will be inserted
- * // before the specified node
- * });.
- *
- * @return {tId: string} an object containing info about the
- * transaction.
- */
- css: function(url, opts) {
- return _queue('css', url, opts);
- }
- };
-}();
+ /**
+ * Fetches and inserts one or more script nodes into the head
+ * of the current document or the document in a specified window.
+ *
+ * @method script
+ * @static
+ * @param {string|string[]} url the url or urls to the script(s).
+ * @param {object} opts Options:
+ *
+ *
+ *
+ *
+ *
+ *
+ *
+ *
+ * url
+ * property, which identifies the file which was loaded.
+ * Y.Get.script(
+ * ["http://yui.yahooapis.com/2.5.2/build/yahoo/yahoo-min.js",
+ * "http://yui.yahooapis.com/2.5.2/build/event/event-min.js"],
+ * {
+ * onSuccess: function(o) {
+ * this.log("won't cause error because Y is the context");
+ * Y.log(o.data); // foo
+ * Y.log(o.nodes.length === 2) // true
+ * // o.purge(); // optionally remove the script nodes
+ * // immediately
+ * },
+ * onFailure: function(o) {
+ * Y.log("transaction failed");
+ * },
+ * onTimeout: function(o) {
+ * Y.log("transaction timed out");
+ * },
+ * data: "foo",
+ * timeout: 10000, // 10 second timeout
+ * context: Y, // make the YUI instance
+ * // win: otherframe // target another window/frame
+ * autopurge: true // allow the utility to choose when to
+ * // remove the nodes
+ * purgetheshold: 1 // purge previous transaction before
+ * // next transaction
+ * });.
+ *
+ * @return {tId: string} an object containing info about the
+ * transaction.
+ */
+ script: function(url, opts) {
+ return _queue(SCRIPT, url, opts);
+ },
+ /**
+ * Fetches and inserts one or more css link nodes into the
+ * head of the current document or the document in a specified
+ * window.
+ * @method css
+ * @static
+ * @param {string} url the url or urls to the css file(s).
+ * @param {object} opts Options:
+ *
+ *
+ *
+ * win
+ * url
property, which identifies the file which was loaded. Currently only useful for non Webkit/Gecko browsers,
+ * where onload for css is detected accurately.
+ * Y.Get.css("http://localhost/css/menu.css");
+ *
+ *
+ * Y.Get.css(
+ * ["http://localhost/css/menu.css",
+ * "http://localhost/css/logger.css"], {
+ * insertBefore: 'custom-styles' // nodes will be inserted
+ * // before the specified node
+ * });.
+ *
+ * @return {tId: string} an object containing info about the
+ * transaction.
+ */
+ css: function(url, opts) {
+ return _queue('css', url, opts);
+ }
+};
}, '@VERSION@' ,{requires:['yui-base']});
diff --git a/build/get/get-min.js b/build/get/get-min.js
index 2374f8f10c7..cea319ba41f 100644
--- a/build/get/get-min.js
+++ b/build/get/get-min.js
@@ -1 +1 @@
-YUI.add("get",function(f){var b=f.UA,a=f.Lang,d="text/javascript",e="text/css",c="stylesheet";f.Get=function(){var m,n,j,l={},k=0,u,w=function(A,x,B){var y=B||f.config.win,C=y.document,D=C.createElement(A),z;for(z in x){if(x[z]&&x.hasOwnProperty(z)){D.setAttribute(z,x[z]);}}return D;},t=function(y,z,x){var A={id:f.guid(),type:e,rel:c,href:y};if(x){f.mix(A,x);}return w("link",A,z);},s=function(y,z,x){var A={id:f.guid(),type:d};if(x){f.mix(A,x);}A.src=y;return w("script",A,z);},p=function(y,z,x){return{tId:y.tId,win:y.win,data:y.data,nodes:y.nodes,msg:z,statusText:x,purge:function(){n(this.tId);}};},o=function(B,A,x){var y=l[B],z;if(y&&y.onEnd){z=y.context||y;y.onEnd.call(z,p(y,A,x));}},v=function(A,z){var x=l[A],y;if(x.timer){clearTimeout(x.timer);}if(x.onFailure){y=x.context||x;x.onFailure.call(y,p(x,z));}o(A,z,"failure");},i=function(A){var x=l[A],z,y;if(x.timer){clearTimeout(x.timer);}x.finished=true;if(x.aborted){z="transaction "+A+" was aborted";v(A,z);return;}if(x.onSuccess){y=x.context||x;x.onSuccess.call(y,p(x));}o(A,z,"OK");},q=function(z){var x=l[z],y;if(x.onTimeout){y=x.context||x;x.onTimeout.call(y,p(x));}o(z,"timeout","timeout");},h=function(z,C){var y=l[z],B,G,F,D,A,x,H,E;if(y.timer){clearTimeout(y.timer);}if(y.aborted){B="transaction "+z+" was aborted";v(z,B);return;}if(C){y.url.shift();if(y.varName){y.varName.shift();}}else{y.url=(a.isString(y.url))?[y.url]:y.url;if(y.varName){y.varName=(a.isString(y.varName))?[y.varName]:y.varName;}}G=y.win;F=G.document;D=F.getElementsByTagName("head")[0];if(y.url.length===0){i(z);return;}x=y.url[0];if(!x){y.url.shift();return h(z);}if(y.timeout){y.timer=setTimeout(function(){q(z);},y.timeout);}if(y.type==="script"){A=s(x,G,y.attributes);}else{A=t(x,G,y.attributes);}j(y.type,A,z,x,G,y.url.length);y.nodes.push(A);E=y.insertBefore||F.getElementsByTagName("base")[0];if(E){H=m(E,z);if(H){H.parentNode.insertBefore(A,H);}}else{D.appendChild(A);}if((b.webkit||b.gecko)&&y.type==="css"){h(z,x);}},g=function(){if(u){return;}u=true;var x,y;for(x in l){if(l.hasOwnProperty(x)){y=l[x];if(y.autopurge&&y.finished){n(y.tId);delete l[x];}}}u=false;},r=function(y,x,z){z=z||{};var C="q"+(k++),A,B=z.purgethreshold||f.Get.PURGE_THRESH;if(k%B===0){g();}l[C]=f.merge(z,{tId:C,type:y,url:x,finished:false,nodes:[]});A=l[C];A.win=A.win||f.config.win;A.context=A.context||A;A.autopurge=("autopurge" in A)?A.autopurge:(y==="script")?true:false;A.attributes=A.attributes||{};A.attributes.charset=z.charset||A.attributes.charset||"utf-8";h(C);return{tId:C};};j=function(z,E,D,y,C,B,x){var A=x||h;if(b.ie){E.onreadystatechange=function(){var F=this.readyState;if("loaded"===F||"complete"===F){E.onreadystatechange=null;A(D,y);}};}else{if(b.webkit){if(z==="script"){E.addEventListener("load",function(){A(D,y);},false);}}else{E.onload=function(){A(D,y);};E.onerror=function(F){v(D,F+": "+y);};}}};m=function(x,A){var y=l[A],z=(a.isString(x))?y.win.document.getElementById(x):x;if(!z){v(A,"target node not found: "+x);}return z;};n=function(C){var y,A,G,D,H,B,z,F,E,x=l[C];if(x){y=x.nodes;A=y.length;G=x.win.document;D=G.getElementsByTagName("head")[0];E=x.insertBefore||G.getElementsByTagName("base")[0];if(E){H=m(E,C);if(H){D=H.parentNode;}}for(B=0;B0){J=O.url.shift();if(N&&!O.timer){O.timer=setTimeout(function(){D(Q);},N);}if(L===s){M=E(J,P,K);}else{M=k(J,P,K);}O.nodes.push(M);c(L,M,Q,J);G(M,Q,P);if(!l[L]){f(Q,J);}if(O.async){i(Q);}}},n=function(){if(g){return;}g=true;var J,K;for(J in z){if(z.hasOwnProperty(J)){K=z[J];if(K.autopurge&&K.finished){d(K.tId);delete z[J];}}}g=false;},j=function(K,J,L){L=L||{};var O="q"+(r++),N=L.purgethreshold||e.Get.PURGE_THRESH,M;if(r%N===0){n();}M=z[O]=e.merge(L);M.tId=O;M.type=K;M.url=J;M.finished=false;M.nodes=[];M.win=M.win||e.config.win;M.context=M.context||M;M.autopurge=(q in M)?M.autopurge:(K===s)?true:false;M.attributes=M.attributes||{};M.attributes.charset=L.charset||M.attributes.charset||A;if(C in M&&K===s){M.attributes.async=M.async;}M.url=(p.isString(M.url))?[M.url]:M.url;if(!M.url[0]){M.url.shift();}M.remaining=M.url.length;i(O);return{tId:O};};e.Get={PURGE_THRESH:20,abort:function(K){var L=(p.isString(K))?K:K.tId,J=z[L];if(J){J.aborted=true;}},script:function(J,K){return j(s,J,K);},css:function(J,K){return j("css",J,K);}};},"@VERSION@",{requires:["yui-base"]});
\ No newline at end of file
diff --git a/build/get/get.js b/build/get/get.js
index 0bce5470756..33eca5cb117 100644
--- a/build/get/get.js
+++ b/build/get/get.js
@@ -1,6 +1,5 @@
YUI.add('get', function(Y) {
-
/**
* Provides a mechanism to fetch remote resources and
* insert them into a document.
@@ -8,26 +7,41 @@ YUI.add('get', function(Y) {
* @submodule get
*/
-var ua = Y.UA,
- L = Y.Lang,
- TYPE_JS = 'text/javascript',
- TYPE_CSS = 'text/css',
- STYLESHEET = 'stylesheet';
-
/**
* Fetches and inserts one or more script or link nodes into the document
* @class Get
* @static
*/
-Y.Get = function() {
+
+var ua = Y.UA,
+ L = Y.Lang,
+ TYPE_JS = 'text/javascript',
+ TYPE_CSS = 'text/css',
+ STYLESHEET = 'stylesheet',
+ SCRIPT = 'script',
+ AUTOPURGE = 'autopurge',
+ UTF8 = 'utf-8',
+ LINK = 'link',
+ ASYNC = 'async',
+ ALL = true,
+
+ // FireFox does not support the onload event for link nodes, so
+ // there is no way to make the css requests synchronous. This means
+ // that the css rules in multiple files could be applied out of order
+ // in this browser if a later request returns before an earlier one.
+
+ // Safari too.
+
+ ONLOAD_SUPPORTED = {
+ script: ALL,
+ css: !(ua.webkit || ua.gecko)
+ },
/**
* hash of queues to manage multiple requests
* @property queues
* @private
*/
- var _get, _purge, _track,
-
queues = {},
/**
@@ -47,22 +61,41 @@ Y.Get = function() {
*/
purging,
+ /**
+ * Clear timeout state
+ *
+ * @method _clearTimeout
+ * @param {Object} q Queue data
+ * @private
+ */
+ _clearTimeout = function(q) {
+ var timer = q.timer;
+ if (timer) {
+ clearTimeout(timer);
+ q.timer = null;
+ }
+ },
/**
* Generates an HTML element, this is not appended to a document
* @method _node
* @param {string} type the type of element.
- * @param {string} attr the attributes.
+ * @param {Object} attr the fixed set of attribute for the type.
+ * @param {Object} custAttrs optional Any custom attributes provided by the user.
* @param {Window} win optional window to create the element in.
* @return {HTMLElement} the generated node.
* @private
*/
- _node = function(type, attr, win) {
+ _node = function(type, attr, custAttrs, win) {
var w = win || Y.config.win,
d = w.document,
n = d.createElement(type),
i;
+ if (custAttrs) {
+ Y.mix(attr, custAttrs);
+ }
+
for (i in attr) {
if (attr[i] && attr.hasOwnProperty(i)) {
n.setAttribute(i, attr[i]);
@@ -83,16 +116,12 @@ Y.Get = function() {
* @private
*/
_linkNode = function(url, win, attributes) {
- var o = {
- id: Y.guid(),
- type: TYPE_CSS,
- rel: STYLESHEET,
- href: url
- };
- if (attributes) {
- Y.mix(o, attributes);
- }
- return _node('link', o, win);
+ return _node(LINK, {
+ id: Y.guid(),
+ type: TYPE_CSS,
+ rel: STYLESHEET,
+ href: url
+ }, attributes, win);
},
/**
@@ -106,18 +135,11 @@ Y.Get = function() {
* @private
*/
_scriptNode = function(url, win, attributes) {
- var o = {
- id: Y.guid(),
- type: TYPE_JS
- };
-
- if (attributes) {
- Y.mix(o, attributes);
- }
-
- o.src = url;
-
- return _node('script', o, win);
+ return _node(SCRIPT, {
+ id: Y.guid(),
+ type: TYPE_JS,
+ src: url
+ }, attributes, win);
},
/**
@@ -131,16 +153,17 @@ Y.Get = function() {
*/
_returnData = function(q, msg, result) {
return {
- tId: q.tId,
- win: q.win,
- data: q.data,
- nodes: q.nodes,
- msg: msg,
- statusText: result,
- purge: function() {
- _purge(this.tId);
- }
- };
+ tId: q.tId,
+ win: q.win,
+ data: q.data,
+ nodes: q.nodes,
+ msg: msg,
+ statusText: result,
+
+ purge: function() {
+ _purge(this.tId);
+ }
+ };
},
/**
@@ -152,14 +175,17 @@ Y.Get = function() {
* @private
*/
_end = function(id, msg, result) {
- var q = queues[id], sc;
- if (q && q.onEnd) {
- sc = q.context || q;
- q.onEnd.call(sc, _returnData(q, msg, result));
+ var q = queues[id],
+ onEnd = q && q.onEnd;
+
+ q.finished = true;
+
+ if (onEnd) {
+ onEnd.call(q.context, _returnData(q, msg, result));
}
},
- /*
+ /**
* The request failed, execute fail handler with whatever
* was accomplished. There isn't a failure case at the
* moment unless you count aborted transactions
@@ -169,48 +195,143 @@ Y.Get = function() {
*/
_fail = function(id, msg) {
- var q = queues[id], sc;
- if (q.timer) {
- // q.timer.cancel();
- clearTimeout(q.timer);
- }
+ var q = queues[id],
+ onFailure = q.onFailure;
+
+ _clearTimeout(q);
- // execute failure callback
- if (q.onFailure) {
- sc = q.context || q;
- q.onFailure.call(sc, _returnData(q, msg));
+ if (onFailure) {
+ onFailure.call(q.context, _returnData(q, msg));
}
_end(id, msg, 'failure');
},
+
+ /**
+ * Abort the transaction
+ *
+ * @method _abort
+ * @param {Object} id
+ * @private
+ */
+ _abort = function(id) {
+ _fail(id, 'transaction ' + id + ' was aborted');
+ },
+
/**
* The request is complete, so executing the requester's callback
- * @method _finish
+ * @method _complete
* @param {string} id the id of the request.
* @private
*/
- _finish = function(id) {
- var q = queues[id], msg, sc;
- if (q.timer) {
- // q.timer.cancel();
- clearTimeout(q.timer);
- }
- q.finished = true;
+ _complete = function(id) {
+
+ var q = queues[id],
+ onSuccess = q.onSuccess;
+
+ _clearTimeout(q);
if (q.aborted) {
- msg = 'transaction ' + id + ' was aborted';
- _fail(id, msg);
- return;
+ _abort(id);
+ } else {
+
+ if (onSuccess) {
+ onSuccess.call(q.context, _returnData(q));
+ }
+
+ // 3.3.0 had undefined msg for this path.
+ _end(id, undefined, 'OK');
}
+ },
+
+ /**
+ * Get node reference, from string
+ *
+ * @method _getNodeRef
+ * @param {String|HTMLElement} nId The node id to find. If an HTMLElement is passed in, it will be returned.
+ * @param {String} tId Queue id, used to determine document for queue
+ * @private
+ */
+ _getNodeRef = function(nId, tId) {
+ var q = queues[tId],
+ n = (L.isString(nId)) ? q.win.document.getElementById(nId) : nId;
+ if (!n) {
+ _fail(tId, 'target node not found: ' + nId);
+ }
+
+ return n;
+ },
+
+ /**
+ * Removes the nodes for the specified queue
+ * @method _purge
+ * @param {string} tId the transaction id.
+ * @private
+ */
+ _purge = function(tId) {
+ var nodes, doc, parent, sibling, node, attr, insertBefore,
+ i, l,
+ q = queues[tId];
+
+ if (q) {
+ nodes = q.nodes;
+ l = nodes.length;
+
+ // TODO: Why is node.parentNode undefined? Which forces us to do this...
+ /*
+ doc = q.win.document;
+ parent = doc.getElementsByTagName('head')[0];
+ insertBefore = q.insertBefore || doc.getElementsByTagName('base')[0];
+
+ if (insertBefore) {
+ sibling = _getNodeRef(insertBefore, tId);
+ if (sibling) {
+ parent = sibling.parentNode;
+ }
+ }
+ */
+
+ for (i = 0; i < l; i++) {
+ node = nodes[i];
+ parent = node.parentNode;
+
+ if (node.clearAttributes) {
+ node.clearAttributes();
+ } else {
+ // This destroys parentNode ref, so we hold onto it above first.
+ for (attr in node) {
+ if (node.hasOwnProperty(attr)) {
+ delete node[attr];
+ }
+ }
+ }
- // execute success callback
- if (q.onSuccess) {
- sc = q.context || q;
- q.onSuccess.call(sc, _returnData(q));
+ parent.removeChild(node);
+ }
}
- _end(id, msg, 'OK');
+ q.nodes = [];
+ },
+
+ /**
+ * Progress callback
+ *
+ * @method _progress
+ * @param {string} id The id of the request.
+ * @param {string} The url which just completed.
+ * @private
+ */
+ _progress = function(id, url) {
+ var q = queues[id],
+ onProgress = q.onProgress,
+ o;
+
+ if (onProgress) {
+ o = _returnData(q);
+ o.url = url;
+ onProgress.call(q.context, o);
+ }
},
/**
@@ -220,113 +341,181 @@ Y.Get = function() {
* @private
*/
_timeout = function(id) {
- var q = queues[id], sc;
- if (q.onTimeout) {
- sc = q.context || q;
- q.onTimeout.call(sc, _returnData(q));
+
+ var q = queues[id],
+ onTimeout = q.onTimeout;
+
+ if (onTimeout) {
+ onTimeout.call(q.context, _returnData(q));
}
_end(id, 'timeout', 'timeout');
},
-
/**
- * Loads the next item for a given request
- * @method _next
+ * onload callback
+ * @method _loaded
* @param {string} id the id of the request.
- * @param {string} loaded the url that was just loaded, if any.
* @return {string} the result.
* @private
*/
- _next = function(id, loaded) {
- var q = queues[id], msg, w, d, h, n, url, s,
- insertBefore;
+ _loaded = function(id, url) {
- if (q.timer) {
- // q.timer.cancel();
- clearTimeout(q.timer);
- }
+ var q = queues[id],
+ sync = !q.async;
- if (q.aborted) {
- msg = 'transaction ' + id + ' was aborted';
- _fail(id, msg);
- return;
+ if (sync) {
+ _clearTimeout(q);
}
- if (loaded) {
- q.url.shift();
- if (q.varName) {
- q.varName.shift();
- }
- } else {
- // This is the first pass: make sure the url is an array
- q.url = (L.isString(q.url)) ? [q.url] : q.url;
- if (q.varName) {
- q.varName = (L.isString(q.varName)) ? [q.varName] : q.varName;
+ _progress(id, url);
+
+ // TODO: Cleaning up flow to have a consistent end point
+
+ // !q.finished check is for the async case,
+ // where scripts may still be loading when we've
+ // already aborted. Ideally there should be a single path
+ // for this.
+
+ if (!q.finished) {
+ if (q.aborted) {
+ _abort(id);
+ } else {
+ if ((--q.remaining) === 0) {
+ _complete(id);
+ } else if (sync) {
+ _next(id);
+ }
}
}
+ },
- w = q.win;
- d = w.document;
- h = d.getElementsByTagName('head')[0];
+ /**
+ * Detects when a node has been loaded. In the case of
+ * script nodes, this does not guarantee that contained
+ * script is ready to use.
+ * @method _trackLoad
+ * @param {string} type the type of node to track.
+ * @param {HTMLElement} n the node to track.
+ * @param {string} id the id of the request.
+ * @param {string} url the url that is being loaded.
+ * @private
+ */
+ _trackLoad = function(type, n, id, url) {
- if (q.url.length === 0) {
- _finish(id);
- return;
- }
+ // TODO: Can we massage this to use ONLOAD_SUPPORTED[type]?
- url = q.url[0];
+ // IE supports the readystatechange event for script and css nodes
+ // Opera only for script nodes. Opera support onload for script
+ // nodes, but this doesn't fire when there is a load failure.
+ // The onreadystatechange appears to be a better way to respond
+ // to both success and failure.
- // if the url is undefined, this is probably a trailing comma
- // problem in IE.
- if (!url) {
- q.url.shift();
- return _next(id);
- }
+ if (ua.ie) {
+ n.onreadystatechange = function() {
+ var rs = this.readyState;
+ if ('loaded' === rs || 'complete' === rs) {
+ n.onreadystatechange = null;
+ _loaded(id, url);
+ }
+ };
- if (q.timeout) {
- // q.timer = L.later(q.timeout, q, _timeout, id);
- q.timer = setTimeout(function() {
- _timeout(id);
- }, q.timeout);
- }
+ } else if (ua.webkit) {
+
+ // webkit prior to 3.x is no longer supported
+ if (type === SCRIPT) {
+ // Safari 3.x supports the load event for script nodes (DOM2)
+ n.addEventListener('load', function() {
+ _loaded(id, url);
+ }, false);
+ }
- if (q.type === 'script') {
- n = _scriptNode(url, w, q.attributes);
} else {
- n = _linkNode(url, w, q.attributes);
- }
- // track this node's load progress
- _track(q.type, n, id, url, w, q.url.length);
+ // FireFox and Opera support onload (but not DOM2 in FF) handlers for
+ // script nodes. Opera, but not FF, supports the onload event for link nodes.
+
+ n.onload = function() {
+ _loaded(id, url);
+ };
+
+ n.onerror = function(e) {
+ _fail(id, e + ': ' + url);
+ };
+ }
+ },
- // add the node to the queue so we can return it to the user supplied
- // callback
- q.nodes.push(n);
+ _insertInDoc = function(node, id, win) {
- // add it to the head or insert it before 'insertBefore'. Work around
- // IE bug if there is a base tag.
- insertBefore = q.insertBefore ||
- d.getElementsByTagName('base')[0];
+ // Add it to the head or insert it before 'insertBefore'.
+ // Work around IE bug if there is a base tag.
+ var q = queues[id],
+ doc = win.document,
+ insertBefore = q.insertBefore || doc.getElementsByTagName('base')[0],
+ sibling;
if (insertBefore) {
- s = _get(insertBefore, id);
- if (s) {
- s.parentNode.insertBefore(n, s);
+ sibling = _getNodeRef(insertBefore, id);
+ if (sibling) {
+ sibling.parentNode.insertBefore(node, sibling);
}
} else {
- h.appendChild(n);
+ // 3.3.0 assumed head is always around.
+ doc.getElementsByTagName('head')[0].appendChild(node);
}
+ },
+
+ /**
+ * Loads the next item for a given request
+ * @method _next
+ * @param {string} id the id of the request.
+ * @return {string} the result.
+ * @private
+ */
+ _next = function(id) {
+
+ // Assigning out here for readability
+ var q = queues[id],
+ type = q.type,
+ attrs = q.attributes,
+ win = q.win,
+ timeout = q.timeout,
+ node,
+ url;
+
+ if (q.url.length > 0) {
+ url = q.url.shift();
- // FireFox does not support the onload event for link nodes, so
- // there is no way to make the css requests synchronous. This means
- // that the css rules in multiple files could be applied out of order
- // in this browser if a later request returns before an earlier one.
- // Safari too.
- if ((ua.webkit || ua.gecko) && q.type === 'css') {
- _next(id, url);
+
+ // !q.timer ensures that this only happens once for async
+ if (timeout && !q.timer) {
+ q.timer = setTimeout(function() {
+ _timeout(id);
+ }, timeout);
+ }
+
+ if (type === SCRIPT) {
+ node = _scriptNode(url, win, attrs);
+ } else {
+ node = _linkNode(url, win, attrs);
+ }
+
+ // add the node to the queue so we can return it in the callback
+ q.nodes.push(node);
+
+ _trackLoad(type, node, id, url);
+ _insertInDoc(node, id, win);
+
+ if (!ONLOAD_SUPPORTED[type]) {
+ _loaded(id, url);
+ }
+
+ if (q.async) {
+ // For sync, the _next call is chained in _loaded
+ _next(id);
+ }
}
},
@@ -367,31 +556,46 @@ Y.Get = function() {
* @private
*/
_queue = function(type, url, opts) {
+
opts = opts || {};
- var id = 'q' + (qidx++), q,
- thresh = opts.purgethreshold || Y.Get.PURGE_THRESH;
+ var id = 'q' + (qidx++),
+ thresh = opts.purgethreshold || Y.Get.PURGE_THRESH,
+ q;
if (qidx % thresh === 0) {
_autoPurge();
}
- queues[id] = Y.merge(opts, {
- tId: id,
- type: type,
- url: url,
- finished: false,
- nodes: []
- });
+ // Merge to protect opts (grandfathered in).
+ q = queues[id] = Y.merge(opts);
+
+ // Avoid mix, merge overhead. Known set of props.
+ q.tId = id;
+ q.type = type;
+ q.url = url;
+ q.finished = false;
+ q.nodes = [];
- q = queues[id];
q.win = q.win || Y.config.win;
q.context = q.context || q;
- q.autopurge = ('autopurge' in q) ? q.autopurge :
- (type === 'script') ? true : false;
-
+ q.autopurge = (AUTOPURGE in q) ? q.autopurge : (type === SCRIPT) ? true : false;
q.attributes = q.attributes || {};
- q.attributes.charset = opts.charset || q.attributes.charset || 'utf-8';
+ q.attributes.charset = opts.charset || q.attributes.charset || UTF8;
+
+ if (ASYNC in q && type === SCRIPT) {
+ q.attributes.async = q.async;
+ }
+
+ q.url = (L.isString(q.url)) ? [q.url] : q.url;
+
+ // TODO: Do we really need to account for this developer error?
+ // If the url is undefined, this is probably a trailing comma problem in IE.
+ if (!q.url[0]) {
+ q.url.shift();
+ }
+
+ q.remaining = q.url.length;
_next(id);
@@ -400,353 +604,257 @@ Y.Get = function() {
};
};
+
+Y.Get = {
+
/**
- * Detects when a node has been loaded. In the case of
- * script nodes, this does not guarantee that contained
- * script is ready to use.
- * @method _track
- * @param {string} type the type of node to track.
- * @param {HTMLElement} n the node to track.
- * @param {string} id the id of the request.
- * @param {string} url the url that is being loaded.
- * @param {Window} win the targeted window.
- * @param {int} qlength the number of remaining items in the queue,
- * including this one.
- * @param {Function} trackfn function to execute when finished
- * the default is _next.
+ * The number of request required before an automatic purge.
+ * Can be configured via the 'purgethreshold' config
+ * property PURGE_THRESH
+ * @static
+ * @type int
+ * @default 20
* @private
*/
- _track = function(type, n, id, url, win, qlength, trackfn) {
- var f = trackfn || _next;
-
- // IE supports the readystatechange event for script and css nodes
- // Opera only for script nodes. Opera support onload for script
- // nodes, but this doesn't fire when there is a load failure.
- // The onreadystatechange appears to be a better way to respond
- // to both success and failure.
- if (ua.ie) {
- n.onreadystatechange = function() {
- var rs = this.readyState;
- if ('loaded' === rs || 'complete' === rs) {
- n.onreadystatechange = null;
- f(id, url);
- }
- };
-
- // webkit prior to 3.x is no longer supported
- } else if (ua.webkit) {
- if (type === 'script') {
- // Safari 3.x supports the load event for script nodes (DOM2)
- n.addEventListener('load', function() {
- f(id, url);
- }, false);
- }
-
- // FireFox and Opera support onload (but not DOM2 in FF) handlers for
- // script nodes. Opera, but not FF, supports the onload event for link
- // nodes.
- } else {
- n.onload = function() {
- f(id, url);
- };
-
- n.onerror = function(e) {
- _fail(id, e + ': ' + url);
- };
- }
- };
-
- _get = function(nId, tId) {
- var q = queues[tId],
- n = (L.isString(nId)) ? q.win.document.getElementById(nId) : nId;
- if (!n) {
- _fail(tId, 'target node not found: ' + nId);
- }
-
- return n;
- };
+ PURGE_THRESH: 20,
/**
- * Removes the nodes for the specified queue
- * @method _purge
- * @param {string} tId the transaction id.
- * @private
+ * Abort a transaction
+ * @method abort
+ * @static
+ * @param {string|object} o Either the tId or the object returned from
+ * script() or css().
*/
- _purge = function(tId) {
- var n, l, d, h, s, i, node, attr, insertBefore,
- q = queues[tId];
+ abort : function(o) {
+ var id = (L.isString(o)) ? o : o.tId,
+ q = queues[id];
if (q) {
- n = q.nodes;
- l = n.length;
- d = q.win.document;
- h = d.getElementsByTagName('head')[0];
-
- insertBefore = q.insertBefore ||
- d.getElementsByTagName('base')[0];
-
- if (insertBefore) {
- s = _get(insertBefore, tId);
- if (s) {
- h = s.parentNode;
- }
- }
-
- for (i = 0; i < l; i = i + 1) {
- node = n[i];
- if (node.clearAttributes) {
- node.clearAttributes();
- } else {
- for (attr in node) {
- if (node.hasOwnProperty(attr)) {
- delete node[attr];
- }
- }
- }
-
- h.removeChild(node);
- }
+ q.aborted = true;
}
- q.nodes = [];
- };
+ },
- return {
-
- /**
- * The number of request required before an automatic purge.
- * Can be configured via the 'purgethreshold' config
- * property PURGE_THRESH
- * @static
- * @type int
- * @default 20
- * @private
- */
- PURGE_THRESH: 20,
-
- /**
- * Called by the the helper for detecting script load in Safari
- * @method _finalize
- * @static
- * @param {string} id the transaction id.
- * @private
- */
- _finalize: function(id) {
- setTimeout(function() {
- _finish(id);
- }, 0);
- },
-
- /**
- * Abort a transaction
- * @method abort
- * @static
- * @param {string|object} o Either the tId or the object returned from
- * script() or css().
- */
- abort: function(o) {
- var id = (L.isString(o)) ? o : o.tId,
- q = queues[id];
- if (q) {
- q.aborted = true;
- }
- },
-
- /**
- * Fetches and inserts one or more script nodes into the head
- * of the current document or the document in a specified window.
- *
- * @method script
- * @static
- * @param {string|string[]} url the url or urls to the script(s).
- * @param {object} opts Options:
- *
- *
- *
- *
- *
- *
- *
- *
- *
- * Y.Get.script(
- * ["http://yui.yahooapis.com/2.5.2/build/yahoo/yahoo-min.js",
- * "http://yui.yahooapis.com/2.5.2/build/event/event-min.js"],
- * {
- * onSuccess: function(o) {
- * this.log("won't cause error because Y is the context");
- * // immediately
- * },
- * onFailure: function(o) {
- * },
- * onTimeout: function(o) {
- * },
- * data: "foo",
- * timeout: 10000, // 10 second timeout
- * context: Y, // make the YUI instance
- * // win: otherframe // target another window/frame
- * autopurge: true // allow the utility to choose when to
- * // remove the nodes
- * purgetheshold: 1 // purge previous transaction before
- * // next transaction
- * });.
- *
- * @return {tId: string} an object containing info about the
- * transaction.
- */
- script: function(url, opts) {
- return _queue('script', url, opts);
- },
-
- /**
- * Fetches and inserts one or more css link nodes into the
- * head of the current document or the document in a specified
- * window.
- * @method css
- * @static
- * @param {string} url the url or urls to the css file(s).
- * @param {object} opts Options:
- *
- *
- *
- * win
- *
- * Y.Get.css("http://localhost/css/menu.css");
- *
- *
- * Y.Get.css(
- * ["http://localhost/css/menu.css",
- * insertBefore: 'custom-styles' // nodes will be inserted
- * // before the specified node
- * });.
- *
- * @return {tId: string} an object containing info about the
- * transaction.
- */
- css: function(url, opts) {
- return _queue('css', url, opts);
- }
- };
-}();
+ /**
+ * Fetches and inserts one or more script nodes into the head
+ * of the current document or the document in a specified window.
+ *
+ * @method script
+ * @static
+ * @param {string|string[]} url the url or urls to the script(s).
+ * @param {object} opts Options:
+ *
+ *
+ *
+ *
+ *
+ *
+ *
+ *
+ * url
+ * property, which identifies the file which was loaded.
+ * Y.Get.script(
+ * ["http://yui.yahooapis.com/2.5.2/build/yahoo/yahoo-min.js",
+ * "http://yui.yahooapis.com/2.5.2/build/event/event-min.js"],
+ * {
+ * onSuccess: function(o) {
+ * this.log("won't cause error because Y is the context");
+ * // immediately
+ * },
+ * onFailure: function(o) {
+ * },
+ * onTimeout: function(o) {
+ * },
+ * data: "foo",
+ * timeout: 10000, // 10 second timeout
+ * context: Y, // make the YUI instance
+ * // win: otherframe // target another window/frame
+ * autopurge: true // allow the utility to choose when to
+ * // remove the nodes
+ * purgetheshold: 1 // purge previous transaction before
+ * // next transaction
+ * });.
+ *
+ * @return {tId: string} an object containing info about the
+ * transaction.
+ */
+ script: function(url, opts) {
+ return _queue(SCRIPT, url, opts);
+ },
+ /**
+ * Fetches and inserts one or more css link nodes into the
+ * head of the current document or the document in a specified
+ * window.
+ * @method css
+ * @static
+ * @param {string} url the url or urls to the css file(s).
+ * @param {object} opts Options:
+ *
+ *
+ *
+ * win
+ * url
property, which identifies the file which was loaded. Currently only useful for non Webkit/Gecko browsers,
+ * where onload for css is detected accurately.
+ * Y.Get.css("http://localhost/css/menu.css");
+ *
+ *
+ * Y.Get.css(
+ * ["http://localhost/css/menu.css",
+ * insertBefore: 'custom-styles' // nodes will be inserted
+ * // before the specified node
+ * });.
+ *
+ * @return {tId: string} an object containing info about the
+ * transaction.
+ */
+ css: function(url, opts) {
+ return _queue('css', url, opts);
+ }
+};
}, '@VERSION@' ,{requires:['yui-base']});
diff --git a/build/history-base/history-base-debug.js b/build/history-base/history-base-debug.js
index d8b5d259c77..e262e4e1ed6 100644
--- a/build/history-base/history-base-debug.js
+++ b/build/history-base/history-base-debug.js
@@ -25,6 +25,12 @@ YUI.add('history-base', function(Y) {
* zero or more of the following properties:
*
*
+ *
+ *
+ *
+ *
+ *
+ *
- * -1){t=q;q=q.split(j);c.Object.setValue(r,q,s);}else{if(typeof r[q]!="undefined"){r[q]=s;}}return s;};k.DEFAULT_GETTER=function(q){var r=this._stateProxy,s;if(q.indexOf&&q.indexOf(j)>-1){s=c.Object.getValue(r,q.split(j));}else{if(typeof r[q]!="undefined"){s=r[q];}}return s;};c.augment(k,c.EventTarget);c.mix(k.prototype,{toString:function(){var t=this[d]+": not bound to a node",s=this._node,q,u,r;if(s){q=s.attributes;u=(q&&q.id)?s.getAttribute("id"):null;r=(q&&q.className)?s.getAttribute("className"):null;t=s[e];if(u){t+="#"+u;}if(r){t+="."+r.replace(" ",".");}t+=" "+this[d];}return t;},get:function(q){var r;if(this._getAttr){r=this._getAttr(q);}else{r=this._get(q);}if(r){r=k.scrubVal(r,this);}else{if(r===null){r=null;}}return r;},_get:function(q){var r=k.ATTRS[q],s;if(r&&r.getter){s=r.getter.call(this);}else{if(k.re_aria.test(q)){s=this._node.getAttribute(q,2);}else{s=k.DEFAULT_GETTER.apply(this,arguments);}}return s;},set:function(q,s){var r=k.ATTRS[q];if(this._setAttr){this._setAttr.apply(this,arguments);}else{if(r&&r.setter){r.setter.call(this,s,q);}else{if(k.re_aria.test(q)){this._node.setAttribute(q,s);}else{k.DEFAULT_SETTER.apply(this,arguments);}}}return this;},setAttrs:function(q){if(this._setAttrs){this._setAttrs(q);}else{c.Object.each(q,function(r,s){this.set(s,r);},this);}return this;},getAttrs:function(r){var q={};if(this._getAttrs){this._getAttrs(r);}else{c.Array.each(r,function(s,t){q[s]=this.get(s);},this);}return q;},create:k.create,compareTo:function(q){var r=this._node;if(c.instanceOf(q,k)){q=q._node;}return r===q;},inDoc:function(r){var q=this._node;r=(r)?r._node||r:q[b];if(r.documentElement){return f.contains(r.documentElement,q);}},getById:function(s){var r=this._node,q=f.byId(s,r[b]);if(q&&f.contains(r,q)){q=c.one(q);}else{q=null;}return q;},ancestor:function(q,r){return c.one(f.ancestor(this._node,o(q),r));},ancestors:function(q,r){return c.all(f.ancestors(this._node,o(q),r));},previous:function(r,q){return c.one(f.elementByAxis(this._node,"previousSibling",o(r),q));},next:function(r,q){return c.one(f.elementByAxis(this._node,"nextSibling",o(r),q));},siblings:function(q){return c.all(f.siblings(this._node,o(q)));},one:function(q){return c.one(c.Selector.query(q,this._node,true));},all:function(q){var r=c.all(c.Selector.query(q,this._node));r._query=q;r._queryRoot=this._node;return r;},test:function(q){return c.Selector.test(this._node,q);},remove:function(q){var r=this._node;if(r&&r.parentNode){r.parentNode.removeChild(r);}if(q){this.destroy();}return this;},replace:function(q){var r=this._node;if(typeof q=="string"){q=k.create(q);}r.parentNode.replaceChild(k.getDOMNode(q),r);
return this;},replaceChild:function(r,q){if(typeof r=="string"){r=f.create(r);}return c.one(this._node.replaceChild(k.getDOMNode(r),k.getDOMNode(q)));},appendChild:function(q){return k.scrubVal(this._insert(q));},insertBefore:function(r,q){return c.Node.scrubVal(this._insert(r,q));},purge:function(r,q){c.Event.purgeElement(this._node,r,q);return this;},destroy:function(s){var r=c.config.doc.uniqueID?"uniqueID":"_yuid",q;this.purge();if(this.unplug){this.unplug();}this.clearData();if(s){c.NodeList.each(this.all("*"),function(t){q=k._instances[t[r]];if(q){q.destroy();}});}this._node=null;this._stateProxy=null;delete k._instances[this._yuid];},invoke:function(x,r,q,w,v,u){var t=this._node,s;if(r&&c.instanceOf(r,k)){r=r._node;}if(q&&c.instanceOf(q,k)){q=q._node;}s=t[x](r,q,w,v,u);return k.scrubVal(s,this);},insert:function(r,q){this._insert(r,q);return this;},_insert:function(t,r){var s=this._node,q=null;if(typeof r=="number"){r=this._node.childNodes[r];}else{if(r&&r._node){r=r._node;}}if(t&&typeof t!="string"){t=t._node||t._nodes||t;}q=f.addHTML(s,t,r);return q;},prepend:function(q){return this.insert(q,0);},append:function(q){return this.insert(q,null);},appendTo:function(q){c.one(q).append(this);return this;},setContent:function(q){this._insert(q,"replace");return this;},getContent:function(q){return this.get("innerHTML");},swap:c.config.doc.documentElement.swapNode?function(q){this._node.swapNode(k.getDOMNode(q));}:function(q){q=k.getDOMNode(q);var s=this._node,r=q.parentNode,t=q.nextSibling;if(t===s){r.insertBefore(s,q);}else{if(q===s.nextSibling){r.insertBefore(q,s);}else{s.parentNode.replaceChild(q,s);f.addHTML(r,s,t);}}return this;},getData:function(r){var q;this._data=this._data||{};if(arguments.length){q=this._data[r];}else{q=this._data;}return q;},setData:function(q,r){this._data=this._data||{};if(arguments.length>1){this._data[q]=r;}else{this._data=q;}return this;},clearData:function(q){if("_data" in this){if(q){delete this._data[q];}else{delete this._data;}}return this;},hasMethod:function(r){var q=this._node;return !!(q&&r in q&&typeof q[r]!="unknown"&&(typeof q[r]=="function"||String(q[r]).indexOf("function")===1));},SHOW_TRANSITION:null,HIDE_TRANSITION:null,show:function(q){q=arguments[arguments.length-1];this.toggleView(true,q);return this;},_show:function(){this.setStyle("display","");},_isHidden:function(){return c.DOM.getStyle(this._node,"display")==="none";},toggleView:function(q,r){this._toggleView.apply(this,arguments);},_toggleView:function(q,r){r=arguments[arguments.length-1];if(typeof q!="boolean"){q=(this._isHidden())?1:0;}if(q){this._show();}else{this._hide();}if(typeof r=="function"){r.call(this);}return this;},hide:function(q){q=arguments[arguments.length-1];this.toggleView(false,q);return this;},_hide:function(){this.setStyle("display","none");},isFragment:function(){return(this.get("nodeType")===11);},empty:function(){this.get("childNodes").remove().destroy(true);return this;},getDOMNode:function(){return this._node;}},true);c.Node=k;c.one=c.Node.one;var a=function(q){var r=[];if(typeof q==="string"){this._query=q;q=c.Selector.query(q);}else{if(q.nodeType||f.isWindow(q)){q=[q];}else{if(c.instanceOf(q,c.Node)){q=[q._node];}else{if(c.instanceOf(q[0],c.Node)){c.Array.each(q,function(s){if(s._node){r.push(s._node);}});q=r;}else{q=c.Array(q,0,true);}}}}this._nodes=q;};a.NAME="NodeList";a.getDOMNodes=function(q){return(q&&q._nodes)?q._nodes:q;};a.each=function(q,t,s){var r=q._nodes;if(r&&r.length){c.Array.each(r,t,s||q);}else{}};a.addMethod=function(q,s,r){if(q&&s){a.prototype[q]=function(){var u=[],t=arguments;c.Array.each(this._nodes,function(z){var y=(z.uniqueID&&z.nodeType!==9)?"uniqueID":"_yuid",w=c.Node._instances[z[y]],x,v;if(!w){w=a._getTempNode(z);}x=r||w;v=s.apply(x,t);if(v!==undefined&&v!==w){u[u.length]=v;}});return u.length?u:this;};}else{}};a.importMethod=function(s,q,r){if(typeof q==="string"){r=r||q;a.addMethod(q,s[q]);}else{c.Array.each(q,function(t){a.importMethod(s,t);});}};a._getTempNode=function(r){var q=a._tempNode;if(!q){q=c.Node.create("");a._tempNode=q;}q._node=r;q._stateProxy=r;return q;};c.mix(a.prototype,{item:function(q){return c.one((this._nodes||[])[q]);},each:function(s,r){var q=this;c.Array.each(this._nodes,function(u,t){u=c.one(u);return s.call(r||u,u,t,q);});return q;},batch:function(r,q){var s=this;c.Array.each(this._nodes,function(v,u){var t=c.Node._instances[v[d]];if(!t){t=a._getTempNode(v);}return r.call(q||t,t,u,s);});return s;},some:function(s,r){var q=this;return c.Array.some(this._nodes,function(u,t){u=c.one(u);r=r||u;return s.call(r,u,t,q);});},toFrag:function(){return c.one(c.DOM._nl2frag(this._nodes));},indexOf:function(q){return c.Array.indexOf(this._nodes,c.Node.getDOMNode(q));},filter:function(q){return c.all(c.Selector.filter(this._nodes,q));},modulus:function(t,s){s=s||0;var q=[];a.each(this,function(u,r){if(r%t===s){q.push(u);}});return c.all(q);},odd:function(){return this.modulus(2,1);},even:function(){return this.modulus(2);},destructor:function(){},refresh:function(){var t,r=this._nodes,s=this._query,q=this._queryRoot;if(s){if(!q){if(r&&r[0]&&r[0].ownerDocument){q=r[0].ownerDocument;}}this._nodes=c.Selector.query(s,q);}return this;},_prepEvtArgs:function(t,s,r){var q=c.Array(arguments,0,true);if(q.length<2){q[2]=this._nodes;}else{q.splice(2,0,this._nodes);}q[3]=r||this;return q;},on:function(s,r,q){return c.on.apply(c,this._prepEvtArgs.apply(this,arguments));},once:function(s,r,q){return c.once.apply(c,this._prepEvtArgs.apply(this,arguments));},after:function(s,r,q){return c.after.apply(c,this._prepEvtArgs.apply(this,arguments));},size:function(){return this._nodes.length;},isEmpty:function(){return this._nodes.length<1;},toString:function(){var t="",s=this[d]+": not bound to any nodes",q=this._nodes,r;if(q&&q[0]){r=q[0];t+=r[e];if(r.id){t+="#"+r.id;}if(r.className){t+="."+r.className.replace(" ",".");}if(q.length>1){t+="...["+q.length+" items]";}}return t||s;},getDOMNodes:function(){return this._nodes;
-}},true);a.importMethod(c.Node.prototype,["append","destroy","detach","detachAll","empty","insert","prepend","remove","set","setContent","show","hide","toggleView"]);a.prototype.get=function(r){var u=[],t=this._nodes,s=false,v=a._getTempNode,q,w;if(t[0]){q=c.Node._instances[t[0]._yuid]||v(t[0]);w=q._get(r);if(w&&w.nodeType){s=true;}}c.Array.each(t,function(x){q=c.Node._instances[x._yuid];if(!q){q=v(x);}w=q._get(r);if(!s){w=c.Node.scrubVal(w,q);}u.push(w);});return(s)?c.all(u):u;};c.NodeList=a;c.all=function(q){return new a(q);};c.Node.all=c.all;c.Array.each(["removeChild","hasChildNodes","cloneNode","hasAttribute","removeAttribute","scrollIntoView","getElementsByTagName","focus","blur","submit","reset","select","createCaption"],function(q){c.Node.prototype[q]=function(u,s,r){var t=this.invoke(q,u,s,r);return t;};});c.Node.importMethod(c.DOM,["contains","setAttribute","getAttribute","wrap","unwrap","generateID"]);c.NodeList.importMethod(c.Node.prototype,["getAttribute","setAttribute","removeAttribute","unwrap","wrap","generateID"]);(function(r){var q=["hasClass","addClass","removeClass","replaceClass","toggleClass"];r.Node.importMethod(r.DOM,q);r.NodeList.importMethod(r.Node.prototype,q);})(c);if(!c.config.doc.documentElement.hasAttribute){c.Node.prototype.hasAttribute=function(q){if(q==="value"){if(this.get("value")!==""){return true;}}return !!(this._node.attributes[q]&&this._node.attributes[q].specified);};}c.Node.prototype.focus=function(){try{this._node.focus();}catch(q){}return this;};c.Node.ATTRS.type={setter:function(r){if(r==="hidden"){try{this._node.type="hidden";}catch(q){this.setStyle("display","none");this._inputType="hidden";}}else{try{this._node.type=r;}catch(q){}}return r;},getter:function(){return this._inputType||this._node.type;},_bypassProxy:true};if(c.config.doc.createElement("form").elements.nodeType){c.Node.ATTRS.elements={getter:function(){return this.all("input, textarea, button, select");}};}c.mix(c.Node.ATTRS,{offsetHeight:{setter:function(q){c.DOM.setHeight(this._node,q);return q;},getter:function(){return this._node.offsetHeight;}},offsetWidth:{setter:function(q){c.DOM.setWidth(this._node,q);return q;},getter:function(){return this._node.offsetWidth;}}});c.mix(c.Node.prototype,{sizeTo:function(q,r){var s;if(arguments.length<2){s=c.one(q);q=s.get("offsetWidth");r=s.get("offsetHeight");}this.setAttrs({offsetWidth:q,offsetHeight:r});}});var l=c.NodeList,h=Array.prototype,g={"concat":1,"pop":0,"push":0,"shift":0,"slice":1,"splice":1,"unshift":0};c.Object.each(g,function(r,q){l.prototype[q]=function(){var u=[],v=0,s,t;while(typeof(s=arguments[v++])!="undefined"){u.push(s._node||s._nodes||s);}t=h[q].apply(this._nodes,u);if(r){t=c.all(t);}else{t=c.Node.scrubVal(t);}return t;};});},"@VERSION@",{requires:["dom-base","selector-css2","event-base"]});YUI.add("node-style",function(a){(function(c){var b=["getStyle","getComputedStyle","setStyle","setStyles"];c.Node.importMethod(c.DOM,b);c.NodeList.importMethod(c.Node.prototype,b);})(a);},"@VERSION@",{requires:["dom-style","node-base"]});YUI.add("node-screen",function(a){a.each(["winWidth","winHeight","docWidth","docHeight","docScrollX","docScrollY"],function(b){a.Node.ATTRS[b]={getter:function(){var c=Array.prototype.slice.call(arguments);c.unshift(a.Node.getDOMNode(this));return a.DOM[b].apply(this,c);}};});a.Node.ATTRS.scrollLeft={getter:function(){var b=a.Node.getDOMNode(this);return("scrollLeft" in b)?b.scrollLeft:a.DOM.docScrollX(b);},setter:function(c){var b=a.Node.getDOMNode(this);if(b){if("scrollLeft" in b){b.scrollLeft=c;}else{if(b.document||b.nodeType===9){a.DOM._getWin(b).scrollTo(c,a.DOM.docScrollY(b));}}}else{}}};a.Node.ATTRS.scrollTop={getter:function(){var b=a.Node.getDOMNode(this);return("scrollTop" in b)?b.scrollTop:a.DOM.docScrollY(b);},setter:function(c){var b=a.Node.getDOMNode(this);if(b){if("scrollTop" in b){b.scrollTop=c;}else{if(b.document||b.nodeType===9){a.DOM._getWin(b).scrollTo(a.DOM.docScrollX(b),c);}}}else{}}};a.Node.importMethod(a.DOM,["getXY","setXY","getX","setX","getY","setY","swapXY"]);a.Node.ATTRS.region={getter:function(){var b=a.Node.getDOMNode(this),c;if(b&&!b.tagName){if(b.nodeType===9){b=b.documentElement;}}if(b.alert){c=a.DOM.viewportRegion(b);}else{c=a.DOM.region(b);}return c;}};a.Node.ATTRS.viewportRegion={getter:function(){return a.DOM.viewportRegion(a.Node.getDOMNode(this));}};a.Node.importMethod(a.DOM,"inViewportRegion");a.Node.prototype.intersect=function(b,d){var c=a.Node.getDOMNode(this);if(a.instanceOf(b,a.Node)){b=a.Node.getDOMNode(b);}return a.DOM.intersect(c,b,d);};a.Node.prototype.inRegion=function(b,d,e){var c=a.Node.getDOMNode(this);if(a.instanceOf(b,a.Node)){b=a.Node.getDOMNode(b);}return a.DOM.inRegion(c,b,d,e);};},"@VERSION@",{requires:["node-base","dom-screen"]});YUI.add("node-pluginhost",function(a){a.Node.plug=function(){var b=a.Array(arguments);b.unshift(a.Node);a.Plugin.Host.plug.apply(a.Base,b);return a.Node;};a.Node.unplug=function(){var b=a.Array(arguments);b.unshift(a.Node);a.Plugin.Host.unplug.apply(a.Base,b);return a.Node;};a.mix(a.Node,a.Plugin.Host,false,null,1);a.NodeList.prototype.plug=function(){var b=arguments;a.NodeList.each(this,function(c){a.Node.prototype.plug.apply(a.one(c),b);});};a.NodeList.prototype.unplug=function(){var b=arguments;a.NodeList.each(this,function(c){a.Node.prototype.unplug.apply(a.one(c),b);});};},"@VERSION@",{requires:["node-base","pluginhost"]});YUI.add("node-event-delegate",function(a){a.Node.prototype.delegate=function(d){var c=a.Array(arguments,0,true),b=(a.Lang.isObject(d)&&!a.Lang.isArray(d))?1:2;c.splice(b,0,this._node);return a.delegate.apply(a,c);};},"@VERSION@",{requires:["node-base","event-delegate"]});YUI.add("node",function(a){},"@VERSION@",{use:["node-base","node-style","node-screen","node-pluginhost","node-event-delegate"],skinnable:false});
\ No newline at end of file
+}},true);a.importMethod(c.Node.prototype,["append","destroy","detach","detachAll","empty","insert","prepend","remove","set","setContent","show","hide","toggleView"]);a.prototype.get=function(r){var u=[],t=this._nodes,s=false,v=a._getTempNode,q,w;if(t[0]){q=c.Node._instances[t[0]._yuid]||v(t[0]);w=q._get(r);if(w&&w.nodeType){s=true;}}c.Array.each(t,function(x){q=c.Node._instances[x._yuid];if(!q){q=v(x);}w=q._get(r);if(!s){w=c.Node.scrubVal(w,q);}u.push(w);});return(s)?c.all(u):u;};c.NodeList=a;c.all=function(q){return new a(q);};c.Node.all=c.all;c.Array.each(["removeChild","hasChildNodes","cloneNode","hasAttribute","removeAttribute","scrollIntoView","getElementsByTagName","focus","blur","submit","reset","select","createCaption"],function(q){c.Node.prototype[q]=function(u,s,r){var t=this.invoke(q,u,s,r);return t;};});c.Node.importMethod(c.DOM,["contains","setAttribute","getAttribute","wrap","unwrap","generateID"]);c.NodeList.importMethod(c.Node.prototype,["getAttribute","setAttribute","removeAttribute","unwrap","wrap","generateID"]);(function(r){var q=["hasClass","addClass","removeClass","replaceClass","toggleClass"];r.Node.importMethod(r.DOM,q);r.NodeList.importMethod(r.Node.prototype,q);})(c);if(!c.config.doc.documentElement.hasAttribute){c.Node.prototype.hasAttribute=function(q){if(q==="value"){if(this.get("value")!==""){return true;}}return !!(this._node.attributes[q]&&this._node.attributes[q].specified);};}c.Node.prototype.focus=function(){try{this._node.focus();}catch(q){}return this;};c.Node.ATTRS.type={setter:function(r){if(r==="hidden"){try{this._node.type="hidden";}catch(q){this.setStyle("display","none");this._inputType="hidden";}}else{try{this._node.type=r;}catch(q){}}return r;},getter:function(){return this._inputType||this._node.type;},_bypassProxy:true};if(c.config.doc.createElement("form").elements.nodeType){c.Node.ATTRS.elements={getter:function(){return this.all("input, textarea, button, select");}};}c.mix(c.Node.ATTRS,{offsetHeight:{setter:function(q){c.DOM.setHeight(this._node,q);return q;},getter:function(){return this._node.offsetHeight;}},offsetWidth:{setter:function(q){c.DOM.setWidth(this._node,q);return q;},getter:function(){return this._node.offsetWidth;}}});c.mix(c.Node.prototype,{sizeTo:function(q,r){var s;if(arguments.length<2){s=c.one(q);q=s.get("offsetWidth");r=s.get("offsetHeight");}this.setAttrs({offsetWidth:q,offsetHeight:r});}});var l=c.NodeList,h=Array.prototype,g={"concat":1,"pop":0,"push":0,"shift":0,"slice":1,"splice":1,"unshift":0};c.Object.each(g,function(r,q){l.prototype[q]=function(){var u=[],v=0,s,t;while(typeof(s=arguments[v++])!="undefined"){u.push(s._node||s._nodes||s);}t=h[q].apply(this._nodes,u);if(r){t=c.all(t);}else{t=c.Node.scrubVal(t);}return t;};});},"@VERSION@",{requires:["dom-base","selector-css2","event-base"]});YUI.add("node-style",function(a){(function(c){var b=["getStyle","getComputedStyle","setStyle","setStyles"];c.Node.importMethod(c.DOM,b);c.NodeList.importMethod(c.Node.prototype,b);})(a);},"@VERSION@",{requires:["dom-style","node-base"]});YUI.add("node-screen",function(a){a.each(["winWidth","winHeight","docWidth","docHeight","docScrollX","docScrollY"],function(b){a.Node.ATTRS[b]={getter:function(){var c=Array.prototype.slice.call(arguments);c.unshift(a.Node.getDOMNode(this));return a.DOM[b].apply(this,c);}};});a.Node.ATTRS.scrollLeft={getter:function(){var b=a.Node.getDOMNode(this);return("scrollLeft" in b)?b.scrollLeft:a.DOM.docScrollX(b);},setter:function(c){var b=a.Node.getDOMNode(this);if(b){if("scrollLeft" in b){b.scrollLeft=c;}else{if(b.document||b.nodeType===9){a.DOM._getWin(b).scrollTo(c,a.DOM.docScrollY(b));}}}else{}}};a.Node.ATTRS.scrollTop={getter:function(){var b=a.Node.getDOMNode(this);return("scrollTop" in b)?b.scrollTop:a.DOM.docScrollY(b);},setter:function(c){var b=a.Node.getDOMNode(this);if(b){if("scrollTop" in b){b.scrollTop=c;}else{if(b.document||b.nodeType===9){a.DOM._getWin(b).scrollTo(a.DOM.docScrollX(b),c);}}}else{}}};a.Node.importMethod(a.DOM,["getXY","setXY","getX","setX","getY","setY","swapXY"]);a.Node.ATTRS.region={getter:function(){var b=this.getDOMNode(),c;if(b&&!b.tagName){if(b.nodeType===9){b=b.documentElement;}}if(a.DOM.isWindow(b)){c=a.DOM.viewportRegion(b);}else{c=a.DOM.region(b);}return c;}};a.Node.ATTRS.viewportRegion={getter:function(){return a.DOM.viewportRegion(a.Node.getDOMNode(this));}};a.Node.importMethod(a.DOM,"inViewportRegion");a.Node.prototype.intersect=function(b,d){var c=a.Node.getDOMNode(this);if(a.instanceOf(b,a.Node)){b=a.Node.getDOMNode(b);}return a.DOM.intersect(c,b,d);};a.Node.prototype.inRegion=function(b,d,e){var c=a.Node.getDOMNode(this);if(a.instanceOf(b,a.Node)){b=a.Node.getDOMNode(b);}return a.DOM.inRegion(c,b,d,e);};},"@VERSION@",{requires:["node-base","dom-screen"]});YUI.add("node-pluginhost",function(a){a.Node.plug=function(){var b=a.Array(arguments);b.unshift(a.Node);a.Plugin.Host.plug.apply(a.Base,b);return a.Node;};a.Node.unplug=function(){var b=a.Array(arguments);b.unshift(a.Node);a.Plugin.Host.unplug.apply(a.Base,b);return a.Node;};a.mix(a.Node,a.Plugin.Host,false,null,1);a.NodeList.prototype.plug=function(){var b=arguments;a.NodeList.each(this,function(c){a.Node.prototype.plug.apply(a.one(c),b);});};a.NodeList.prototype.unplug=function(){var b=arguments;a.NodeList.each(this,function(c){a.Node.prototype.unplug.apply(a.one(c),b);});};},"@VERSION@",{requires:["node-base","pluginhost"]});YUI.add("node-event-delegate",function(a){a.Node.prototype.delegate=function(d){var c=a.Array(arguments,0,true),b=(a.Lang.isObject(d)&&!a.Lang.isArray(d))?1:2;c.splice(b,0,this._node);return a.delegate.apply(a,c);};},"@VERSION@",{requires:["node-base","event-delegate"]});YUI.add("node",function(a){},"@VERSION@",{skinnable:false,use:["node-base","node-style","node-screen","node-pluginhost","node-event-delegate"]});
\ No newline at end of file
diff --git a/build/node/node-screen-debug.js b/build/node/node-screen-debug.js
index 4a947e08abf..1f2e325eea6 100644
--- a/build/node/node-screen-debug.js
+++ b/build/node/node-screen-debug.js
@@ -168,7 +168,7 @@ Y.Node.importMethod(Y.DOM, [
*/
Y.Node.ATTRS.region = {
getter: function() {
- var node = Y.Node.getDOMNode(this),
+ var node = this.getDOMNode(),
region;
if (node && !node.tagName) {
@@ -176,7 +176,7 @@ Y.Node.ATTRS.region = {
node = node.documentElement;
}
}
- if (node.alert) {
+ if (Y.DOM.isWindow(node)) {
region = Y.DOM.viewportRegion(node);
} else {
region = Y.DOM.region(node);
diff --git a/build/node/node-screen-min.js b/build/node/node-screen-min.js
index df5d73d83f4..82a47e0ae0b 100644
--- a/build/node/node-screen-min.js
+++ b/build/node/node-screen-min.js
@@ -1 +1 @@
-YUI.add("node-screen",function(a){a.each(["winWidth","winHeight","docWidth","docHeight","docScrollX","docScrollY"],function(b){a.Node.ATTRS[b]={getter:function(){var c=Array.prototype.slice.call(arguments);c.unshift(a.Node.getDOMNode(this));return a.DOM[b].apply(this,c);}};});a.Node.ATTRS.scrollLeft={getter:function(){var b=a.Node.getDOMNode(this);return("scrollLeft" in b)?b.scrollLeft:a.DOM.docScrollX(b);},setter:function(c){var b=a.Node.getDOMNode(this);if(b){if("scrollLeft" in b){b.scrollLeft=c;}else{if(b.document||b.nodeType===9){a.DOM._getWin(b).scrollTo(c,a.DOM.docScrollY(b));}}}else{}}};a.Node.ATTRS.scrollTop={getter:function(){var b=a.Node.getDOMNode(this);return("scrollTop" in b)?b.scrollTop:a.DOM.docScrollY(b);},setter:function(c){var b=a.Node.getDOMNode(this);if(b){if("scrollTop" in b){b.scrollTop=c;}else{if(b.document||b.nodeType===9){a.DOM._getWin(b).scrollTo(a.DOM.docScrollX(b),c);}}}else{}}};a.Node.importMethod(a.DOM,["getXY","setXY","getX","setX","getY","setY","swapXY"]);a.Node.ATTRS.region={getter:function(){var b=a.Node.getDOMNode(this),c;if(b&&!b.tagName){if(b.nodeType===9){b=b.documentElement;}}if(b.alert){c=a.DOM.viewportRegion(b);}else{c=a.DOM.region(b);}return c;}};a.Node.ATTRS.viewportRegion={getter:function(){return a.DOM.viewportRegion(a.Node.getDOMNode(this));}};a.Node.importMethod(a.DOM,"inViewportRegion");a.Node.prototype.intersect=function(b,d){var c=a.Node.getDOMNode(this);if(a.instanceOf(b,a.Node)){b=a.Node.getDOMNode(b);}return a.DOM.intersect(c,b,d);};a.Node.prototype.inRegion=function(b,d,e){var c=a.Node.getDOMNode(this);if(a.instanceOf(b,a.Node)){b=a.Node.getDOMNode(b);}return a.DOM.inRegion(c,b,d,e);};},"@VERSION@",{requires:["node-base","dom-screen"]});
\ No newline at end of file
+YUI.add("node-screen",function(a){a.each(["winWidth","winHeight","docWidth","docHeight","docScrollX","docScrollY"],function(b){a.Node.ATTRS[b]={getter:function(){var c=Array.prototype.slice.call(arguments);c.unshift(a.Node.getDOMNode(this));return a.DOM[b].apply(this,c);}};});a.Node.ATTRS.scrollLeft={getter:function(){var b=a.Node.getDOMNode(this);return("scrollLeft" in b)?b.scrollLeft:a.DOM.docScrollX(b);},setter:function(c){var b=a.Node.getDOMNode(this);if(b){if("scrollLeft" in b){b.scrollLeft=c;}else{if(b.document||b.nodeType===9){a.DOM._getWin(b).scrollTo(c,a.DOM.docScrollY(b));}}}else{}}};a.Node.ATTRS.scrollTop={getter:function(){var b=a.Node.getDOMNode(this);return("scrollTop" in b)?b.scrollTop:a.DOM.docScrollY(b);},setter:function(c){var b=a.Node.getDOMNode(this);if(b){if("scrollTop" in b){b.scrollTop=c;}else{if(b.document||b.nodeType===9){a.DOM._getWin(b).scrollTo(a.DOM.docScrollX(b),c);}}}else{}}};a.Node.importMethod(a.DOM,["getXY","setXY","getX","setX","getY","setY","swapXY"]);a.Node.ATTRS.region={getter:function(){var b=this.getDOMNode(),c;if(b&&!b.tagName){if(b.nodeType===9){b=b.documentElement;}}if(a.DOM.isWindow(b)){c=a.DOM.viewportRegion(b);}else{c=a.DOM.region(b);}return c;}};a.Node.ATTRS.viewportRegion={getter:function(){return a.DOM.viewportRegion(a.Node.getDOMNode(this));}};a.Node.importMethod(a.DOM,"inViewportRegion");a.Node.prototype.intersect=function(b,d){var c=a.Node.getDOMNode(this);if(a.instanceOf(b,a.Node)){b=a.Node.getDOMNode(b);}return a.DOM.intersect(c,b,d);};a.Node.prototype.inRegion=function(b,d,e){var c=a.Node.getDOMNode(this);if(a.instanceOf(b,a.Node)){b=a.Node.getDOMNode(b);}return a.DOM.inRegion(c,b,d,e);};},"@VERSION@",{requires:["node-base","dom-screen"]});
\ No newline at end of file
diff --git a/build/node/node-screen.js b/build/node/node-screen.js
index 596a70e68c3..28d1b5aacd7 100644
--- a/build/node/node-screen.js
+++ b/build/node/node-screen.js
@@ -166,7 +166,7 @@ Y.Node.importMethod(Y.DOM, [
*/
Y.Node.ATTRS.region = {
getter: function() {
- var node = Y.Node.getDOMNode(this),
+ var node = this.getDOMNode(),
region;
if (node && !node.tagName) {
@@ -174,7 +174,7 @@ Y.Node.ATTRS.region = {
node = node.documentElement;
}
}
- if (node.alert) {
+ if (Y.DOM.isWindow(node)) {
region = Y.DOM.viewportRegion(node);
} else {
region = Y.DOM.region(node);
diff --git a/build/node/node.js b/build/node/node.js
index 12c4c35b4e8..12238f71481 100644
--- a/build/node/node.js
+++ b/build/node/node.js
@@ -2509,7 +2509,7 @@ Y.Node.importMethod(Y.DOM, [
*/
Y.Node.ATTRS.region = {
getter: function() {
- var node = Y.Node.getDOMNode(this),
+ var node = this.getDOMNode(),
region;
if (node && !node.tagName) {
@@ -2517,7 +2517,7 @@ Y.Node.ATTRS.region = {
node = node.documentElement;
}
}
- if (node.alert) {
+ if (Y.DOM.isWindow(node)) {
region = Y.DOM.viewportRegion(node);
} else {
region = Y.DOM.region(node);
@@ -2684,5 +2684,5 @@ Y.Node.prototype.delegate = function(type) {
}, '@VERSION@' ,{requires:['node-base', 'event-delegate']});
-YUI.add('node', function(Y){}, '@VERSION@' ,{use:['node-base', 'node-style', 'node-screen', 'node-pluginhost', 'node-event-delegate'], skinnable:false});
+YUI.add('node', function(Y){}, '@VERSION@' ,{skinnable:false, use:['node-base', 'node-style', 'node-screen', 'node-pluginhost', 'node-event-delegate']});
diff --git a/build/oop/oop-debug.js b/build/oop/oop-debug.js
index 23420a9b81f..8e0a3ce6d5d 100644
--- a/build/oop/oop-debug.js
+++ b/build/oop/oop-debug.js
@@ -1,379 +1,397 @@
YUI.add('oop', function(Y) {
/**
- * Supplies object inheritance and manipulation utilities. This adds
- * additional functionaity to what is provided in yui-base, and the
- * methods are applied directly to the YUI instance. This module
- * is required for most YUI components.
- * @module oop
- */
+Supplies object inheritance and manipulation utilities.
-/**
- * The following methods are added to the YUI instance
- * @class YUI~oop
- */
+This adds additional functionaity to what is provided in `yui-base`, and the
+methods are applied directly to the YUI instance. This module is required for
+most YUI components.
- var L = Y.Lang,
- A = Y.Array,
- OP = Object.prototype,
- CLONE_MARKER = '_~yuim~_',
- EACH = 'each',
- SOME = 'some',
-
- dispatch = function(o, f, c, proto, action) {
- if (o && o[action] && o !== Y) {
- return o[action].call(o, f, c);
- } else {
- switch (A.test(o)) {
- case 1:
- return A[action](o, f, c);
- case 2:
- return A[action](Y.Array(o, 0, true), f, c);
- default:
- return Y.Object[action](o, f, c, proto);
- }
- }
- };
+@module oop
+**/
+/**
+These methods are added to the YUI instance by the `oop` module.
+
+@class YUI~oop
+**/
+
+var L = Y.Lang,
+ A = Y.Array,
+ OP = Object.prototype,
+ CLONE_MARKER = '_~yuim~_',
+
+ hasOwn = OP.hasOwnProperty,
+ toString = OP.toString;
+
+function dispatch(o, f, c, proto, action) {
+ if (o && o[action] && o !== Y) {
+ return o[action].call(o, f, c);
+ } else {
+ switch (A.test(o)) {
+ case 1:
+ return A[action](o, f, c);
+ case 2:
+ return A[action](Y.Array(o, 0, true), f, c);
+ default:
+ return Y.Object[action](o, f, c, proto);
+ }
+ }
+}
/**
- * Applies prototype properties from the supplier to the receiver.
- * The receiver can be a constructor or an instance.
- * @method augment
- * @param {function} r the object to receive the augmentation.
- * @param {function} s the object that supplies the properties to augment.
- * @param {boolean} ov if true, properties already on the receiver
- * will be overwritten if found on the supplier.
- * @param {string[]} wl a whitelist. If supplied, only properties in
- * this list will be applied to the receiver.
- * @param {Array | Any} args arg or arguments to apply to the supplier
- * constructor when initializing.
- * @return {object} the augmented object.
- *
- * @todo constructor optional?
- * @todo understanding what an instance is augmented with
- * @todo best practices for overriding sequestered methods.
- */
- Y.augment = function(r, s, ov, wl, args) {
- var sProto = s.prototype,
- newProto = null,
- construct = s,
- a = (args) ? Y.Array(args) : [],
- rProto = r.prototype,
- target = rProto || r,
- applyConstructor = false,
- sequestered, replacements;
-
- // working on a class, so apply constructor infrastructure
- if (rProto && construct) {
- sequestered = {};
+ Augments the _receiver_ with prototype properties from the _supplier_. The
+ receiver may be a constructor function or an object. The supplier must be a
+ constructor function.
+
+ If the _receiver_ is an object, then the _supplier_ constructor will be called
+ immediately after _receiver_ is augmented, with _receiver_ as the `this` object.
+
+ If the _receiver_ is a constructor function, then all prototype methods of
+ _supplier_ that are copied to _receiver_ will be sequestered, and the
+ _supplier_ constructor will not be called immediately. The first time any
+ sequestered method is called on the _receiver_'s prototype, all sequestered
+ methods will be immediately copied to the _receiver_'s prototype, the
+ _supplier_'s constructor will be executed, and finally the newly unsequestered
+ method that was called will be executed.
+
+ This sequestering logic sounds like a bunch of complicated voodoo, but it makes
+ it cheap to perform frequent augmentation by ensuring that suppliers'
+ constructors are only called if a supplied method is actually used. If none of
+ the supplied methods is ever used, then there's no need to take the performance
+ hit of calling the _supplier_'s constructor.
+
+ @method augment
+ @param {Function|Object} receiver Object or function to be augmented.
+ @param {Function} supplier Function that supplies the prototype properties with
+ which to augment the _receiver_.
+ @param {Boolean} [overwrite=false] If `true`, properties already on the receiver
+ will be overwritten if found on the supplier's prototype.
+ @param {String[]} [whitelist] An array of property names. If specified,
+ only the whitelisted prototype properties will be applied to the receiver, and
+ all others will be ignored.
+ @param {Array|any} [args] Argument or array of arguments to pass to the
+ supplier's constructor when initializing.
+ @return {Function} Augmented object.
+ **/
+ Y.augment = function (receiver, supplier, overwrite, whitelist, args) {
+ var rProto = receiver.prototype,
+ sequester = rProto && supplier,
+ sProto = supplier.prototype,
+ to = rProto || receiver,
+
+ copy,
+ newPrototype,
+ replacements,
+ sequestered,
+ unsequester;
+
+ args = args ? Y.Array(args) : [];
+
+ if (sequester) {
+ newPrototype = {};
replacements = {};
- newProto = {};
-
- // sequester all of the functions in the supplier and replace with
- // one that will restore all of them.
- Y.Object.each(sProto, function(v, k) {
- replacements[k] = function() {
-
- // Y.log('sequestered function "' + k +
- // '" executed. Initializing EventTarget');
- // overwrite the prototype with all of the sequestered functions,
- // but only if it hasn't been overridden
- for (var i in sequestered) {
- if (sequestered.hasOwnProperty(i) &&
- (this[i] === replacements[i])) {
- // Y.log('... restoring ' + k);
- this[i] = sequestered[i];
- }
- }
+ sequestered = {};
- // apply the constructor
- construct.apply(this, a);
+ copy = function (value, key) {
+ if (overwrite || !(key in rProto)) {
+ if (toString.call(value) === '[object Function]') {
+ sequestered[key] = value;
- // apply the original sequestered function
- return sequestered[k].apply(this, arguments);
- };
+ newPrototype[key] = replacements[key] = function () {
+ return unsequester(this, value, arguments);
+ };
+ } else {
+ newPrototype[key] = value;
+ }
+ }
+ };
- if ((!wl || (k in wl)) && (ov || !(k in this))) {
- // Y.log('augment: ' + k);
- if (L.isFunction(v)) {
- // sequester the function
- sequestered[k] = v;
+ unsequester = function (instance, fn, fnArgs) {
+ // Unsequester all sequestered functions.
+ for (var key in sequestered) {
+ if (hasOwn.call(sequestered, key)
+ && instance[key] === replacements[key]) {
-// replace the sequestered function with a function that will
-// restore all sequestered functions and exectue the constructor.
- this[k] = replacements[k];
- } else {
- // Y.log('augment() applying non-function: ' + k);
- this[k] = v;
+ instance[key] = sequestered[key];
}
}
- }, newProto, true);
+ // Execute the supplier constructor.
+ supplier.apply(instance, args);
- // augmenting an instance, so apply the constructor immediately
- } else {
- applyConstructor = true;
+ // Finally, execute the original sequestered function.
+ return fn.apply(instance, fnArgs);
+ };
+
+ if (whitelist) {
+ Y.Array.each(whitelist, function (name) {
+ if (name in sProto) {
+ copy(sProto[name], name);
+ }
+ });
+ } else {
+ Y.Object.each(sProto, copy, null, true);
+ }
}
- Y.mix(target, newProto || sProto, ov, wl);
+ Y.mix(to, newPrototype || sProto, overwrite, whitelist);
- if (applyConstructor) {
- s.apply(target, a);
+ if (!sequester) {
+ supplier.apply(to, args);
}
- return r;
+ return receiver;
};
- /**
- * Applies object properties from the supplier to the receiver. If
- * the target has the property, and the property is an object, the target
- * object will be augmented with the supplier's value. If the property
- * is an array, the suppliers value will be appended to the target.
- * @method aggregate
- * @param {function} r the object to receive the augmentation.
- * @param {function} s the object that supplies the properties to augment.
- * @param {boolean} ov if true, properties already on the receiver
- * will be overwritten if found on the supplier.
- * @param {string[]} wl a whitelist. If supplied, only properties in
- * this list will be applied to the receiver.
- * @return {object} the extended object.
- */
- Y.aggregate = function(r, s, ov, wl) {
- return Y.mix(r, s, ov, wl, 0, true);
- };
+/**
+ * Applies object properties from the supplier to the receiver. If
+ * the target has the property, and the property is an object, the target
+ * object will be augmented with the supplier's value. If the property
+ * is an array, the suppliers value will be appended to the target.
+ * @method aggregate
+ * @param {function} r the object to receive the augmentation.
+ * @param {function} s the object that supplies the properties to augment.
+ * @param {boolean} ov if true, properties already on the receiver
+ * will be overwritten if found on the supplier.
+ * @param {string[]} wl a whitelist. If supplied, only properties in
+ * this list will be applied to the receiver.
+ * @return {object} the extended object.
+ */
+Y.aggregate = function(r, s, ov, wl) {
+ return Y.mix(r, s, ov, wl, 0, true);
+};
- /**
- * Utility to set up the prototype, constructor and superclass properties to
- * support an inheritance strategy that can chain constructors and methods.
- * Static members will not be inherited.
- *
- * @method extend
- * @param {function} r the object to modify.
- * @param {function} s the object to inherit.
- * @param {object} px prototype properties to add/override.
- * @param {object} sx static properties to add/override.
- * @return {object} the extended object.
- */
- Y.extend = function(r, s, px, sx) {
- if (!s || !r) {
- Y.error('extend failed, verify dependencies');
- }
+/**
+ * Utility to set up the prototype, constructor and superclass properties to
+ * support an inheritance strategy that can chain constructors and methods.
+ * Static members will not be inherited.
+ *
+ * @method extend
+ * @param {function} r the object to modify.
+ * @param {function} s the object to inherit.
+ * @param {object} px prototype properties to add/override.
+ * @param {object} sx static properties to add/override.
+ * @return {object} the extended object.
+ */
+Y.extend = function(r, s, px, sx) {
+ if (!s || !r) {
+ Y.error('extend failed, verify dependencies');
+ }
- var sp = s.prototype, rp = Y.Object(sp);
- r.prototype = rp;
+ var sp = s.prototype, rp = Y.Object(sp);
+ r.prototype = rp;
- rp.constructor = r;
- r.superclass = sp;
+ rp.constructor = r;
+ r.superclass = sp;
- // assign constructor property
- if (s != Object && sp.constructor == OP.constructor) {
- sp.constructor = s;
- }
+ // assign constructor property
+ if (s != Object && sp.constructor == OP.constructor) {
+ sp.constructor = s;
+ }
- // add prototype overrides
- if (px) {
- Y.mix(rp, px, true);
- }
+ // add prototype overrides
+ if (px) {
+ Y.mix(rp, px, true);
+ }
- // add object overrides
- if (sx) {
- Y.mix(r, sx, true);
- }
+ // add object overrides
+ if (sx) {
+ Y.mix(r, sx, true);
+ }
- return r;
- };
+ return r;
+};
- /**
- * Executes the supplied function for each item in
- * a collection. Supports arrays, objects, and
- * Y.NodeLists
- * @method each
- * @param {object} o the object to iterate.
- * @param {function} f the function to execute. This function
- * receives the value, key, and object as parameters.
- * @param {object} c the execution context for the function.
- * @param {boolean} proto if true, prototype properties are
- * iterated on objects.
- * @return {YUI} the YUI instance.
- */
- Y.each = function(o, f, c, proto) {
- return dispatch(o, f, c, proto, EACH);
- };
+/**
+ * Executes the supplied function for each item in
+ * a collection. Supports arrays, objects, and
+ * Y.NodeLists
+ * @method each
+ * @param {object} o the object to iterate.
+ * @param {function} f the function to execute. This function
+ * receives the value, key, and object as parameters.
+ * @param {object} c the execution context for the function.
+ * @param {boolean} proto if true, prototype properties are
+ * iterated on objects.
+ * @return {YUI} the YUI instance.
+ */
+Y.each = function(o, f, c, proto) {
+ return dispatch(o, f, c, proto, 'each');
+};
- /**
- * Executes the supplied function for each item in
- * a collection. The operation stops if the function
- * returns true. Supports arrays, objects, and
- * Y.NodeLists.
- * @method some
- * @param {object} o the object to iterate.
- * @param {function} f the function to execute. This function
- * receives the value, key, and object as parameters.
- * @param {object} c the execution context for the function.
- * @param {boolean} proto if true, prototype properties are
- * iterated on objects.
- * @return {boolean} true if the function ever returns true,
- * false otherwise.
- */
- Y.some = function(o, f, c, proto) {
- return dispatch(o, f, c, proto, SOME);
- };
+/**
+ * Executes the supplied function for each item in
+ * a collection. The operation stops if the function
+ * returns true. Supports arrays, objects, and
+ * Y.NodeLists.
+ * @method some
+ * @param {object} o the object to iterate.
+ * @param {function} f the function to execute. This function
+ * receives the value, key, and object as parameters.
+ * @param {object} c the execution context for the function.
+ * @param {boolean} proto if true, prototype properties are
+ * iterated on objects.
+ * @return {boolean} true if the function ever returns true,
+ * false otherwise.
+ */
+Y.some = function(o, f, c, proto) {
+ return dispatch(o, f, c, proto, 'some');
+};
- /**
- * Deep obj/array copy. Function clones are actually
- * wrappers around the original function.
- * Array-like objects are treated as arrays.
- * Primitives are returned untouched. Optionally, a
- * function can be provided to handle other data types,
- * filter keys, validate values, etc.
- *
- * @method clone
- * @param {object} o what to clone.
- * @param {boolean} safe if true, objects will not have prototype
- * items from the source. If false, they will. In this case, the
- * original is initially protected, but the clone is not completely
- * immune from changes to the source object prototype. Also, cloned
- * prototype items that are deleted from the clone will result
- * in the value of the source prototype being exposed. If operating
- * on a non-safe clone, items should be nulled out rather than deleted.
- * @param {function} f optional function to apply to each item in a
- * collection; it will be executed prior to applying the value to
- * the new object. Return false to prevent the copy.
- * @param {object} c optional execution context for f.
- * @param {object} owner Owner object passed when clone is iterating
- * an object. Used to set up context for cloned functions.
- * @param {object} cloned hash of previously cloned objects to avoid
- * multiple clones.
- * @return {Array|Object} the cloned object.
- */
- Y.clone = function(o, safe, f, c, owner, cloned) {
-
- if (!L.isObject(o)) {
+/**
+ * Deep obj/array copy. Function clones are actually
+ * wrappers around the original function.
+ * Array-like objects are treated as arrays.
+ * Primitives are returned untouched. Optionally, a
+ * function can be provided to handle other data types,
+ * filter keys, validate values, etc.
+ *
+ * @method clone
+ * @param {object} o what to clone.
+ * @param {boolean} safe if true, objects will not have prototype
+ * items from the source. If false, they will. In this case, the
+ * original is initially protected, but the clone is not completely
+ * immune from changes to the source object prototype. Also, cloned
+ * prototype items that are deleted from the clone will result
+ * in the value of the source prototype being exposed. If operating
+ * on a non-safe clone, items should be nulled out rather than deleted.
+ * @param {function} f optional function to apply to each item in a
+ * collection; it will be executed prior to applying the value to
+ * the new object. Return false to prevent the copy.
+ * @param {object} c optional execution context for f.
+ * @param {object} owner Owner object passed when clone is iterating
+ * an object. Used to set up context for cloned functions.
+ * @param {object} cloned hash of previously cloned objects to avoid
+ * multiple clones.
+ * @return {Array|Object} the cloned object.
+ */
+Y.clone = function(o, safe, f, c, owner, cloned) {
+
+ if (!L.isObject(o)) {
+ return o;
+ }
+
+ // @todo cloning YUI instances doesn't currently work
+ if (Y.instanceOf(o, YUI)) {
+ return o;
+ }
+
+ var o2, marked = cloned || {}, stamp,
+ yeach = Y.each;
+
+ switch (L.type(o)) {
+ case 'date':
+ return new Date(o);
+ case 'regexp':
+ // if we do this we need to set the flags too
+ // return new RegExp(o.source);
return o;
- }
-
- // @todo cloning YUI instances doesn't currently work
- if (Y.instanceOf(o, YUI)) {
+ case 'function':
+ // o2 = Y.bind(o, owner);
+ // break;
return o;
- }
-
- var o2, marked = cloned || {}, stamp,
- yeach = Y.each;
-
- switch (L.type(o)) {
- case 'date':
- return new Date(o);
- case 'regexp':
- // if we do this we need to set the flags too
- // return new RegExp(o.source);
- return o;
- case 'function':
- // o2 = Y.bind(o, owner);
- // break;
- return o;
- case 'array':
- o2 = [];
- break;
- default:
+ case 'array':
+ o2 = [];
+ break;
+ default:
+
+ // #2528250 only one clone of a given object should be created.
+ if (o[CLONE_MARKER]) {
+ return marked[o[CLONE_MARKER]];
+ }
- // #2528250 only one clone of a given object should be created.
- if (o[CLONE_MARKER]) {
- return marked[o[CLONE_MARKER]];
- }
+ stamp = Y.guid();
- stamp = Y.guid();
+ o2 = (safe) ? {} : Y.Object(o);
- o2 = (safe) ? {} : Y.Object(o);
+ o[CLONE_MARKER] = stamp;
+ marked[stamp] = o;
+ }
- o[CLONE_MARKER] = stamp;
- marked[stamp] = o;
- }
-
- // #2528250 don't try to clone element properties
- if (!o.addEventListener && !o.attachEvent) {
- yeach(o, function(v, k) {
+ // #2528250 don't try to clone element properties
+ if (!o.addEventListener && !o.attachEvent) {
+ yeach(o, function(v, k) {
if ((k || k === 0) && (!f || (f.call(c || this, v, k, this, o) !== false))) {
- if (k !== CLONE_MARKER) {
- if (k == 'prototype') {
- // skip the prototype
- // } else if (o[k] === o) {
- // this[k] = this;
- } else {
- this[k] =
- Y.clone(v, safe, f, c, owner || o, marked);
- }
+ if (k !== CLONE_MARKER) {
+ if (k == 'prototype') {
+ // skip the prototype
+ // } else if (o[k] === o) {
+ // this[k] = this;
+ } else {
+ this[k] =
+ Y.clone(v, safe, f, c, owner || o, marked);
}
}
- }, o2);
- }
-
- if (!cloned) {
- Y.Object.each(marked, function(v, k) {
- if (v[CLONE_MARKER]) {
- try {
- delete v[CLONE_MARKER];
- } catch (e) {
- v[CLONE_MARKER] = null;
- }
+ }
+ }, o2);
+ }
+
+ if (!cloned) {
+ Y.Object.each(marked, function(v, k) {
+ if (v[CLONE_MARKER]) {
+ try {
+ delete v[CLONE_MARKER];
+ } catch (e) {
+ v[CLONE_MARKER] = null;
}
- }, this);
- marked = null;
- }
+ }
+ }, this);
+ marked = null;
+ }
- return o2;
- };
+ return o2;
+};
- /**
- * Returns a function that will execute the supplied function in the
- * supplied object's context, optionally adding any additional
- * supplied parameters to the beginning of the arguments collection the
- * supplied to the function.
- *
- * @method bind
- * @param {Function|String} f the function to bind, or a function name
- * to execute on the context object.
- * @param {object} c the execution context.
- * @param {any} args* 0..n arguments to include before the arguments the
- * function is executed with.
- * @return {function} the wrapped function.
- */
- Y.bind = function(f, c) {
- var xargs = arguments.length > 2 ?
- Y.Array(arguments, 2, true) : null;
- return function() {
- var fn = L.isString(f) ? c[f] : f,
- args = (xargs) ?
- xargs.concat(Y.Array(arguments, 0, true)) : arguments;
- return fn.apply(c || fn, args);
- };
+/**
+ * Returns a function that will execute the supplied function in the
+ * supplied object's context, optionally adding any additional
+ * supplied parameters to the beginning of the arguments collection the
+ * supplied to the function.
+ *
+ * @method bind
+ * @param {Function|String} f the function to bind, or a function name
+ * to execute on the context object.
+ * @param {object} c the execution context.
+ * @param {any} args* 0..n arguments to include before the arguments the
+ * function is executed with.
+ * @return {function} the wrapped function.
+ */
+Y.bind = function(f, c) {
+ var xargs = arguments.length > 2 ?
+ Y.Array(arguments, 2, true) : null;
+ return function() {
+ var fn = L.isString(f) ? c[f] : f,
+ args = (xargs) ?
+ xargs.concat(Y.Array(arguments, 0, true)) : arguments;
+ return fn.apply(c || fn, args);
};
+};
- /**
- * Returns a function that will execute the supplied function in the
- * supplied object's context, optionally adding any additional
- * supplied parameters to the end of the arguments the function
- * is executed with.
- *
- * @method rbind
- * @param {Function|String} f the function to bind, or a function name
- * to execute on the context object.
- * @param {object} c the execution context.
- * @param {any} args* 0..n arguments to append to the end of
- * arguments collection supplied to the function.
- * @return {function} the wrapped function.
- */
- Y.rbind = function(f, c) {
- var xargs = arguments.length > 2 ? Y.Array(arguments, 2, true) : null;
- return function() {
- var fn = L.isString(f) ? c[f] : f,
- args = (xargs) ?
- Y.Array(arguments, 0, true).concat(xargs) : arguments;
- return fn.apply(c || fn, args);
- };
+/**
+ * Returns a function that will execute the supplied function in the
+ * supplied object's context, optionally adding any additional
+ * supplied parameters to the end of the arguments the function
+ * is executed with.
+ *
+ * @method rbind
+ * @param {Function|String} f the function to bind, or a function name
+ * to execute on the context object.
+ * @param {object} c the execution context.
+ * @param {any} args* 0..n arguments to append to the end of
+ * arguments collection supplied to the function.
+ * @return {function} the wrapped function.
+ */
+Y.rbind = function(f, c) {
+ var xargs = arguments.length > 2 ? Y.Array(arguments, 2, true) : null;
+ return function() {
+ var fn = L.isString(f) ? c[f] : f,
+ args = (xargs) ?
+ Y.Array(arguments, 0, true).concat(xargs) : arguments;
+ return fn.apply(c || fn, args);
};
-
+};
}, '@VERSION@' ,{requires:['yui-base']});
diff --git a/build/oop/oop-min.js b/build/oop/oop-min.js
index a90793c0ff2..a8eec691a22 100644
--- a/build/oop/oop-min.js
+++ b/build/oop/oop-min.js
@@ -1 +1 @@
-YUI.add("oop",function(h){var d=h.Lang,c=h.Array,b=Object.prototype,a="_~yuim~_",e="each",g="some",f=function(l,k,m,i,j){if(l&&l[j]&&l!==h){return l[j].call(l,k,m);}else{switch(c.test(l)){case 1:return c[j](l,k,m);case 2:return c[j](h.Array(l,0,true),k,m);default:return h.Object[j](l,k,m,i);}}};h.augment=function(i,x,l,v,p){var n=x.prototype,t=null,w=x,q=(p)?h.Array(p):[],k=i.prototype,o=k||i,u=false,j,m;if(k&&w){j={};m={};t={};h.Object.each(n,function(s,r){m[r]=function(){for(var y in j){if(j.hasOwnProperty(y)&&(this[y]===m[y])){this[y]=j[y];}}w.apply(this,q);return j[r].apply(this,arguments);};if((!v||(r in v))&&(l||!(r in this))){if(d.isFunction(s)){j[r]=s;this[r]=m[r];}else{this[r]=s;}}},t,true);}else{u=true;}h.mix(o,t||n,l,v);if(u){x.apply(o,q);}return i;};h.aggregate=function(k,j,i,l){return h.mix(k,j,i,l,0,true);};h.extend=function(l,k,i,n){if(!k||!l){h.error("extend failed, verify dependencies");}var m=k.prototype,j=h.Object(m);l.prototype=j;j.constructor=l;l.superclass=m;if(k!=Object&&m.constructor==b.constructor){m.constructor=k;}if(i){h.mix(j,i,true);}if(n){h.mix(l,n,true);}return l;};h.each=function(k,j,l,i){return f(k,j,l,i,e);};h.some=function(k,j,l,i){return f(k,j,l,i,g);};h.clone=function(l,m,r,s,k,q){if(!d.isObject(l)){return l;}if(h.instanceOf(l,YUI)){return l;}var n,j=q||{},i,p=h.each;switch(d.type(l)){case"date":return new Date(l);case"regexp":return l;case"function":return l;case"array":n=[];break;default:if(l[a]){return j[l[a]];}i=h.guid();n=(m)?{}:h.Object(l);l[a]=i;j[i]=l;}if(!l.addEventListener&&!l.attachEvent){p(l,function(t,o){if((o||o===0)&&(!r||(r.call(s||this,t,o,this,l)!==false))){if(o!==a){if(o=="prototype"){}else{this[o]=h.clone(t,m,r,s,k||l,j);}}}},n);}if(!q){h.Object.each(j,function(t,o){if(t[a]){try{delete t[a];}catch(u){t[a]=null;}}},this);j=null;}return n;};h.bind=function(i,k){var j=arguments.length>2?h.Array(arguments,2,true):null;return function(){var m=d.isString(i)?k[i]:i,l=(j)?j.concat(h.Array(arguments,0,true)):arguments;return m.apply(k||m,l);};};h.rbind=function(i,k){var j=arguments.length>2?h.Array(arguments,2,true):null;return function(){var m=d.isString(i)?k[i]:i,l=(j)?h.Array(arguments,0,true).concat(j):arguments;return m.apply(k||m,l);};};},"@VERSION@",{requires:["yui-base"]});
\ No newline at end of file
+YUI.add("oop",function(h){var d=h.Lang,c=h.Array,b=Object.prototype,a="_~yuim~_",e=b.hasOwnProperty,g=b.toString;function f(l,k,m,i,j){if(l&&l[j]&&l!==h){return l[j].call(l,k,m);}else{switch(c.test(l)){case 1:return c[j](l,k,m);case 2:return c[j](h.Array(l,0,true),k,m);default:return h.Object[j](l,k,m,i);}}}h.augment=function(i,k,r,o,s){var n=i.prototype,m=n&&k,q=k.prototype,v=n||i,j,u,p,l,t;s=s?h.Array(s):[];if(m){u={};p={};l={};j=function(x,w){if(r||!(w in n)){if(g.call(x)==="[object Function]"){l[w]=x;u[w]=p[w]=function(){return t(this,x,arguments);};}else{u[w]=x;}}};t=function(w,y,z){for(var x in l){if(e.call(l,x)&&w[x]===p[x]){w[x]=l[x];}}k.apply(w,s);return y.apply(w,z);};if(o){h.Array.each(o,function(w){if(w in q){j(q[w],w);}});}else{h.Object.each(q,j,null,true);}}h.mix(v,u||q,r,o);if(!m){k.apply(v,s);}return i;};h.aggregate=function(k,j,i,l){return h.mix(k,j,i,l,0,true);};h.extend=function(l,k,i,n){if(!k||!l){h.error("extend failed, verify dependencies");}var m=k.prototype,j=h.Object(m);l.prototype=j;j.constructor=l;l.superclass=m;if(k!=Object&&m.constructor==b.constructor){m.constructor=k;}if(i){h.mix(j,i,true);}if(n){h.mix(l,n,true);}return l;};h.each=function(k,j,l,i){return f(k,j,l,i,"each");};h.some=function(k,j,l,i){return f(k,j,l,i,"some");};h.clone=function(l,m,r,s,k,q){if(!d.isObject(l)){return l;}if(h.instanceOf(l,YUI)){return l;}var n,j=q||{},i,p=h.each;switch(d.type(l)){case"date":return new Date(l);case"regexp":return l;case"function":return l;case"array":n=[];break;default:if(l[a]){return j[l[a]];}i=h.guid();n=(m)?{}:h.Object(l);l[a]=i;j[i]=l;}if(!l.addEventListener&&!l.attachEvent){p(l,function(t,o){if((o||o===0)&&(!r||(r.call(s||this,t,o,this,l)!==false))){if(o!==a){if(o=="prototype"){}else{this[o]=h.clone(t,m,r,s,k||l,j);}}}},n);}if(!q){h.Object.each(j,function(t,o){if(t[a]){try{delete t[a];}catch(u){t[a]=null;}}},this);j=null;}return n;};h.bind=function(i,k){var j=arguments.length>2?h.Array(arguments,2,true):null;return function(){var m=d.isString(i)?k[i]:i,l=(j)?j.concat(h.Array(arguments,0,true)):arguments;return m.apply(k||m,l);};};h.rbind=function(i,k){var j=arguments.length>2?h.Array(arguments,2,true):null;return function(){var m=d.isString(i)?k[i]:i,l=(j)?h.Array(arguments,0,true).concat(j):arguments;return m.apply(k||m,l);};};},"@VERSION@",{requires:["yui-base"]});
\ No newline at end of file
diff --git a/build/oop/oop.js b/build/oop/oop.js
index f38c2bc4c95..8e0a3ce6d5d 100644
--- a/build/oop/oop.js
+++ b/build/oop/oop.js
@@ -1,374 +1,397 @@
YUI.add('oop', function(Y) {
/**
- * Supplies object inheritance and manipulation utilities. This adds
- * additional functionaity to what is provided in yui-base, and the
- * methods are applied directly to the YUI instance. This module
- * is required for most YUI components.
- * @module oop
- */
+Supplies object inheritance and manipulation utilities.
-/**
- * The following methods are added to the YUI instance
- * @class YUI~oop
- */
+This adds additional functionaity to what is provided in `yui-base`, and the
+methods are applied directly to the YUI instance. This module is required for
+most YUI components.
- var L = Y.Lang,
- A = Y.Array,
- OP = Object.prototype,
- CLONE_MARKER = '_~yuim~_',
- EACH = 'each',
- SOME = 'some',
-
- dispatch = function(o, f, c, proto, action) {
- if (o && o[action] && o !== Y) {
- return o[action].call(o, f, c);
- } else {
- switch (A.test(o)) {
- case 1:
- return A[action](o, f, c);
- case 2:
- return A[action](Y.Array(o, 0, true), f, c);
- default:
- return Y.Object[action](o, f, c, proto);
- }
- }
- };
+@module oop
+**/
+/**
+These methods are added to the YUI instance by the `oop` module.
+
+@class YUI~oop
+**/
+
+var L = Y.Lang,
+ A = Y.Array,
+ OP = Object.prototype,
+ CLONE_MARKER = '_~yuim~_',
+
+ hasOwn = OP.hasOwnProperty,
+ toString = OP.toString;
+
+function dispatch(o, f, c, proto, action) {
+ if (o && o[action] && o !== Y) {
+ return o[action].call(o, f, c);
+ } else {
+ switch (A.test(o)) {
+ case 1:
+ return A[action](o, f, c);
+ case 2:
+ return A[action](Y.Array(o, 0, true), f, c);
+ default:
+ return Y.Object[action](o, f, c, proto);
+ }
+ }
+}
/**
- * Applies prototype properties from the supplier to the receiver.
- * The receiver can be a constructor or an instance.
- * @method augment
- * @param {function} r the object to receive the augmentation.
- * @param {function} s the object that supplies the properties to augment.
- * @param {boolean} ov if true, properties already on the receiver
- * will be overwritten if found on the supplier.
- * @param {string[]} wl a whitelist. If supplied, only properties in
- * this list will be applied to the receiver.
- * @param {Array | Any} args arg or arguments to apply to the supplier
- * constructor when initializing.
- * @return {object} the augmented object.
- *
- * @todo constructor optional?
- * @todo understanding what an instance is augmented with
- * @todo best practices for overriding sequestered methods.
- */
- Y.augment = function(r, s, ov, wl, args) {
- var sProto = s.prototype,
- newProto = null,
- construct = s,
- a = (args) ? Y.Array(args) : [],
- rProto = r.prototype,
- target = rProto || r,
- applyConstructor = false,
- sequestered, replacements;
-
- // working on a class, so apply constructor infrastructure
- if (rProto && construct) {
- sequestered = {};
+ Augments the _receiver_ with prototype properties from the _supplier_. The
+ receiver may be a constructor function or an object. The supplier must be a
+ constructor function.
+
+ If the _receiver_ is an object, then the _supplier_ constructor will be called
+ immediately after _receiver_ is augmented, with _receiver_ as the `this` object.
+
+ If the _receiver_ is a constructor function, then all prototype methods of
+ _supplier_ that are copied to _receiver_ will be sequestered, and the
+ _supplier_ constructor will not be called immediately. The first time any
+ sequestered method is called on the _receiver_'s prototype, all sequestered
+ methods will be immediately copied to the _receiver_'s prototype, the
+ _supplier_'s constructor will be executed, and finally the newly unsequestered
+ method that was called will be executed.
+
+ This sequestering logic sounds like a bunch of complicated voodoo, but it makes
+ it cheap to perform frequent augmentation by ensuring that suppliers'
+ constructors are only called if a supplied method is actually used. If none of
+ the supplied methods is ever used, then there's no need to take the performance
+ hit of calling the _supplier_'s constructor.
+
+ @method augment
+ @param {Function|Object} receiver Object or function to be augmented.
+ @param {Function} supplier Function that supplies the prototype properties with
+ which to augment the _receiver_.
+ @param {Boolean} [overwrite=false] If `true`, properties already on the receiver
+ will be overwritten if found on the supplier's prototype.
+ @param {String[]} [whitelist] An array of property names. If specified,
+ only the whitelisted prototype properties will be applied to the receiver, and
+ all others will be ignored.
+ @param {Array|any} [args] Argument or array of arguments to pass to the
+ supplier's constructor when initializing.
+ @return {Function} Augmented object.
+ **/
+ Y.augment = function (receiver, supplier, overwrite, whitelist, args) {
+ var rProto = receiver.prototype,
+ sequester = rProto && supplier,
+ sProto = supplier.prototype,
+ to = rProto || receiver,
+
+ copy,
+ newPrototype,
+ replacements,
+ sequestered,
+ unsequester;
+
+ args = args ? Y.Array(args) : [];
+
+ if (sequester) {
+ newPrototype = {};
replacements = {};
- newProto = {};
-
- // sequester all of the functions in the supplier and replace with
- // one that will restore all of them.
- Y.Object.each(sProto, function(v, k) {
- replacements[k] = function() {
-
- // overwrite the prototype with all of the sequestered functions,
- // but only if it hasn't been overridden
- for (var i in sequestered) {
- if (sequestered.hasOwnProperty(i) &&
- (this[i] === replacements[i])) {
- this[i] = sequestered[i];
- }
- }
+ sequestered = {};
- // apply the constructor
- construct.apply(this, a);
+ copy = function (value, key) {
+ if (overwrite || !(key in rProto)) {
+ if (toString.call(value) === '[object Function]') {
+ sequestered[key] = value;
- // apply the original sequestered function
- return sequestered[k].apply(this, arguments);
- };
+ newPrototype[key] = replacements[key] = function () {
+ return unsequester(this, value, arguments);
+ };
+ } else {
+ newPrototype[key] = value;
+ }
+ }
+ };
- if ((!wl || (k in wl)) && (ov || !(k in this))) {
- if (L.isFunction(v)) {
- // sequester the function
- sequestered[k] = v;
+ unsequester = function (instance, fn, fnArgs) {
+ // Unsequester all sequestered functions.
+ for (var key in sequestered) {
+ if (hasOwn.call(sequestered, key)
+ && instance[key] === replacements[key]) {
-// replace the sequestered function with a function that will
-// restore all sequestered functions and exectue the constructor.
- this[k] = replacements[k];
- } else {
- this[k] = v;
+ instance[key] = sequestered[key];
}
}
- }, newProto, true);
+ // Execute the supplier constructor.
+ supplier.apply(instance, args);
- // augmenting an instance, so apply the constructor immediately
- } else {
- applyConstructor = true;
+ // Finally, execute the original sequestered function.
+ return fn.apply(instance, fnArgs);
+ };
+
+ if (whitelist) {
+ Y.Array.each(whitelist, function (name) {
+ if (name in sProto) {
+ copy(sProto[name], name);
+ }
+ });
+ } else {
+ Y.Object.each(sProto, copy, null, true);
+ }
}
- Y.mix(target, newProto || sProto, ov, wl);
+ Y.mix(to, newPrototype || sProto, overwrite, whitelist);
- if (applyConstructor) {
- s.apply(target, a);
+ if (!sequester) {
+ supplier.apply(to, args);
}
- return r;
+ return receiver;
};
- /**
- * Applies object properties from the supplier to the receiver. If
- * the target has the property, and the property is an object, the target
- * object will be augmented with the supplier's value. If the property
- * is an array, the suppliers value will be appended to the target.
- * @method aggregate
- * @param {function} r the object to receive the augmentation.
- * @param {function} s the object that supplies the properties to augment.
- * @param {boolean} ov if true, properties already on the receiver
- * will be overwritten if found on the supplier.
- * @param {string[]} wl a whitelist. If supplied, only properties in
- * this list will be applied to the receiver.
- * @return {object} the extended object.
- */
- Y.aggregate = function(r, s, ov, wl) {
- return Y.mix(r, s, ov, wl, 0, true);
- };
+/**
+ * Applies object properties from the supplier to the receiver. If
+ * the target has the property, and the property is an object, the target
+ * object will be augmented with the supplier's value. If the property
+ * is an array, the suppliers value will be appended to the target.
+ * @method aggregate
+ * @param {function} r the object to receive the augmentation.
+ * @param {function} s the object that supplies the properties to augment.
+ * @param {boolean} ov if true, properties already on the receiver
+ * will be overwritten if found on the supplier.
+ * @param {string[]} wl a whitelist. If supplied, only properties in
+ * this list will be applied to the receiver.
+ * @return {object} the extended object.
+ */
+Y.aggregate = function(r, s, ov, wl) {
+ return Y.mix(r, s, ov, wl, 0, true);
+};
- /**
- * Utility to set up the prototype, constructor and superclass properties to
- * support an inheritance strategy that can chain constructors and methods.
- * Static members will not be inherited.
- *
- * @method extend
- * @param {function} r the object to modify.
- * @param {function} s the object to inherit.
- * @param {object} px prototype properties to add/override.
- * @param {object} sx static properties to add/override.
- * @return {object} the extended object.
- */
- Y.extend = function(r, s, px, sx) {
- if (!s || !r) {
- Y.error('extend failed, verify dependencies');
- }
+/**
+ * Utility to set up the prototype, constructor and superclass properties to
+ * support an inheritance strategy that can chain constructors and methods.
+ * Static members will not be inherited.
+ *
+ * @method extend
+ * @param {function} r the object to modify.
+ * @param {function} s the object to inherit.
+ * @param {object} px prototype properties to add/override.
+ * @param {object} sx static properties to add/override.
+ * @return {object} the extended object.
+ */
+Y.extend = function(r, s, px, sx) {
+ if (!s || !r) {
+ Y.error('extend failed, verify dependencies');
+ }
- var sp = s.prototype, rp = Y.Object(sp);
- r.prototype = rp;
+ var sp = s.prototype, rp = Y.Object(sp);
+ r.prototype = rp;
- rp.constructor = r;
- r.superclass = sp;
+ rp.constructor = r;
+ r.superclass = sp;
- // assign constructor property
- if (s != Object && sp.constructor == OP.constructor) {
- sp.constructor = s;
- }
+ // assign constructor property
+ if (s != Object && sp.constructor == OP.constructor) {
+ sp.constructor = s;
+ }
- // add prototype overrides
- if (px) {
- Y.mix(rp, px, true);
- }
+ // add prototype overrides
+ if (px) {
+ Y.mix(rp, px, true);
+ }
- // add object overrides
- if (sx) {
- Y.mix(r, sx, true);
- }
+ // add object overrides
+ if (sx) {
+ Y.mix(r, sx, true);
+ }
- return r;
- };
+ return r;
+};
- /**
- * Executes the supplied function for each item in
- * a collection. Supports arrays, objects, and
- * Y.NodeLists
- * @method each
- * @param {object} o the object to iterate.
- * @param {function} f the function to execute. This function
- * receives the value, key, and object as parameters.
- * @param {object} c the execution context for the function.
- * @param {boolean} proto if true, prototype properties are
- * iterated on objects.
- * @return {YUI} the YUI instance.
- */
- Y.each = function(o, f, c, proto) {
- return dispatch(o, f, c, proto, EACH);
- };
+/**
+ * Executes the supplied function for each item in
+ * a collection. Supports arrays, objects, and
+ * Y.NodeLists
+ * @method each
+ * @param {object} o the object to iterate.
+ * @param {function} f the function to execute. This function
+ * receives the value, key, and object as parameters.
+ * @param {object} c the execution context for the function.
+ * @param {boolean} proto if true, prototype properties are
+ * iterated on objects.
+ * @return {YUI} the YUI instance.
+ */
+Y.each = function(o, f, c, proto) {
+ return dispatch(o, f, c, proto, 'each');
+};
- /**
- * Executes the supplied function for each item in
- * a collection. The operation stops if the function
- * returns true. Supports arrays, objects, and
- * Y.NodeLists.
- * @method some
- * @param {object} o the object to iterate.
- * @param {function} f the function to execute. This function
- * receives the value, key, and object as parameters.
- * @param {object} c the execution context for the function.
- * @param {boolean} proto if true, prototype properties are
- * iterated on objects.
- * @return {boolean} true if the function ever returns true,
- * false otherwise.
- */
- Y.some = function(o, f, c, proto) {
- return dispatch(o, f, c, proto, SOME);
- };
+/**
+ * Executes the supplied function for each item in
+ * a collection. The operation stops if the function
+ * returns true. Supports arrays, objects, and
+ * Y.NodeLists.
+ * @method some
+ * @param {object} o the object to iterate.
+ * @param {function} f the function to execute. This function
+ * receives the value, key, and object as parameters.
+ * @param {object} c the execution context for the function.
+ * @param {boolean} proto if true, prototype properties are
+ * iterated on objects.
+ * @return {boolean} true if the function ever returns true,
+ * false otherwise.
+ */
+Y.some = function(o, f, c, proto) {
+ return dispatch(o, f, c, proto, 'some');
+};
- /**
- * Deep obj/array copy. Function clones are actually
- * wrappers around the original function.
- * Array-like objects are treated as arrays.
- * Primitives are returned untouched. Optionally, a
- * function can be provided to handle other data types,
- * filter keys, validate values, etc.
- *
- * @method clone
- * @param {object} o what to clone.
- * @param {boolean} safe if true, objects will not have prototype
- * items from the source. If false, they will. In this case, the
- * original is initially protected, but the clone is not completely
- * immune from changes to the source object prototype. Also, cloned
- * prototype items that are deleted from the clone will result
- * in the value of the source prototype being exposed. If operating
- * on a non-safe clone, items should be nulled out rather than deleted.
- * @param {function} f optional function to apply to each item in a
- * collection; it will be executed prior to applying the value to
- * the new object. Return false to prevent the copy.
- * @param {object} c optional execution context for f.
- * @param {object} owner Owner object passed when clone is iterating
- * an object. Used to set up context for cloned functions.
- * @param {object} cloned hash of previously cloned objects to avoid
- * multiple clones.
- * @return {Array|Object} the cloned object.
- */
- Y.clone = function(o, safe, f, c, owner, cloned) {
-
- if (!L.isObject(o)) {
+/**
+ * Deep obj/array copy. Function clones are actually
+ * wrappers around the original function.
+ * Array-like objects are treated as arrays.
+ * Primitives are returned untouched. Optionally, a
+ * function can be provided to handle other data types,
+ * filter keys, validate values, etc.
+ *
+ * @method clone
+ * @param {object} o what to clone.
+ * @param {boolean} safe if true, objects will not have prototype
+ * items from the source. If false, they will. In this case, the
+ * original is initially protected, but the clone is not completely
+ * immune from changes to the source object prototype. Also, cloned
+ * prototype items that are deleted from the clone will result
+ * in the value of the source prototype being exposed. If operating
+ * on a non-safe clone, items should be nulled out rather than deleted.
+ * @param {function} f optional function to apply to each item in a
+ * collection; it will be executed prior to applying the value to
+ * the new object. Return false to prevent the copy.
+ * @param {object} c optional execution context for f.
+ * @param {object} owner Owner object passed when clone is iterating
+ * an object. Used to set up context for cloned functions.
+ * @param {object} cloned hash of previously cloned objects to avoid
+ * multiple clones.
+ * @return {Array|Object} the cloned object.
+ */
+Y.clone = function(o, safe, f, c, owner, cloned) {
+
+ if (!L.isObject(o)) {
+ return o;
+ }
+
+ // @todo cloning YUI instances doesn't currently work
+ if (Y.instanceOf(o, YUI)) {
+ return o;
+ }
+
+ var o2, marked = cloned || {}, stamp,
+ yeach = Y.each;
+
+ switch (L.type(o)) {
+ case 'date':
+ return new Date(o);
+ case 'regexp':
+ // if we do this we need to set the flags too
+ // return new RegExp(o.source);
return o;
- }
-
- // @todo cloning YUI instances doesn't currently work
- if (Y.instanceOf(o, YUI)) {
+ case 'function':
+ // o2 = Y.bind(o, owner);
+ // break;
return o;
- }
-
- var o2, marked = cloned || {}, stamp,
- yeach = Y.each;
-
- switch (L.type(o)) {
- case 'date':
- return new Date(o);
- case 'regexp':
- // if we do this we need to set the flags too
- // return new RegExp(o.source);
- return o;
- case 'function':
- // o2 = Y.bind(o, owner);
- // break;
- return o;
- case 'array':
- o2 = [];
- break;
- default:
+ case 'array':
+ o2 = [];
+ break;
+ default:
+
+ // #2528250 only one clone of a given object should be created.
+ if (o[CLONE_MARKER]) {
+ return marked[o[CLONE_MARKER]];
+ }
- // #2528250 only one clone of a given object should be created.
- if (o[CLONE_MARKER]) {
- return marked[o[CLONE_MARKER]];
- }
+ stamp = Y.guid();
- stamp = Y.guid();
+ o2 = (safe) ? {} : Y.Object(o);
- o2 = (safe) ? {} : Y.Object(o);
+ o[CLONE_MARKER] = stamp;
+ marked[stamp] = o;
+ }
- o[CLONE_MARKER] = stamp;
- marked[stamp] = o;
- }
-
- // #2528250 don't try to clone element properties
- if (!o.addEventListener && !o.attachEvent) {
- yeach(o, function(v, k) {
+ // #2528250 don't try to clone element properties
+ if (!o.addEventListener && !o.attachEvent) {
+ yeach(o, function(v, k) {
if ((k || k === 0) && (!f || (f.call(c || this, v, k, this, o) !== false))) {
- if (k !== CLONE_MARKER) {
- if (k == 'prototype') {
- // skip the prototype
- // } else if (o[k] === o) {
- // this[k] = this;
- } else {
- this[k] =
- Y.clone(v, safe, f, c, owner || o, marked);
- }
+ if (k !== CLONE_MARKER) {
+ if (k == 'prototype') {
+ // skip the prototype
+ // } else if (o[k] === o) {
+ // this[k] = this;
+ } else {
+ this[k] =
+ Y.clone(v, safe, f, c, owner || o, marked);
}
}
- }, o2);
- }
-
- if (!cloned) {
- Y.Object.each(marked, function(v, k) {
- if (v[CLONE_MARKER]) {
- try {
- delete v[CLONE_MARKER];
- } catch (e) {
- v[CLONE_MARKER] = null;
- }
+ }
+ }, o2);
+ }
+
+ if (!cloned) {
+ Y.Object.each(marked, function(v, k) {
+ if (v[CLONE_MARKER]) {
+ try {
+ delete v[CLONE_MARKER];
+ } catch (e) {
+ v[CLONE_MARKER] = null;
}
- }, this);
- marked = null;
- }
+ }
+ }, this);
+ marked = null;
+ }
- return o2;
- };
+ return o2;
+};
- /**
- * Returns a function that will execute the supplied function in the
- * supplied object's context, optionally adding any additional
- * supplied parameters to the beginning of the arguments collection the
- * supplied to the function.
- *
- * @method bind
- * @param {Function|String} f the function to bind, or a function name
- * to execute on the context object.
- * @param {object} c the execution context.
- * @param {any} args* 0..n arguments to include before the arguments the
- * function is executed with.
- * @return {function} the wrapped function.
- */
- Y.bind = function(f, c) {
- var xargs = arguments.length > 2 ?
- Y.Array(arguments, 2, true) : null;
- return function() {
- var fn = L.isString(f) ? c[f] : f,
- args = (xargs) ?
- xargs.concat(Y.Array(arguments, 0, true)) : arguments;
- return fn.apply(c || fn, args);
- };
+/**
+ * Returns a function that will execute the supplied function in the
+ * supplied object's context, optionally adding any additional
+ * supplied parameters to the beginning of the arguments collection the
+ * supplied to the function.
+ *
+ * @method bind
+ * @param {Function|String} f the function to bind, or a function name
+ * to execute on the context object.
+ * @param {object} c the execution context.
+ * @param {any} args* 0..n arguments to include before the arguments the
+ * function is executed with.
+ * @return {function} the wrapped function.
+ */
+Y.bind = function(f, c) {
+ var xargs = arguments.length > 2 ?
+ Y.Array(arguments, 2, true) : null;
+ return function() {
+ var fn = L.isString(f) ? c[f] : f,
+ args = (xargs) ?
+ xargs.concat(Y.Array(arguments, 0, true)) : arguments;
+ return fn.apply(c || fn, args);
};
+};
- /**
- * Returns a function that will execute the supplied function in the
- * supplied object's context, optionally adding any additional
- * supplied parameters to the end of the arguments the function
- * is executed with.
- *
- * @method rbind
- * @param {Function|String} f the function to bind, or a function name
- * to execute on the context object.
- * @param {object} c the execution context.
- * @param {any} args* 0..n arguments to append to the end of
- * arguments collection supplied to the function.
- * @return {function} the wrapped function.
- */
- Y.rbind = function(f, c) {
- var xargs = arguments.length > 2 ? Y.Array(arguments, 2, true) : null;
- return function() {
- var fn = L.isString(f) ? c[f] : f,
- args = (xargs) ?
- Y.Array(arguments, 0, true).concat(xargs) : arguments;
- return fn.apply(c || fn, args);
- };
+/**
+ * Returns a function that will execute the supplied function in the
+ * supplied object's context, optionally adding any additional
+ * supplied parameters to the end of the arguments the function
+ * is executed with.
+ *
+ * @method rbind
+ * @param {Function|String} f the function to bind, or a function name
+ * to execute on the context object.
+ * @param {object} c the execution context.
+ * @param {any} args* 0..n arguments to append to the end of
+ * arguments collection supplied to the function.
+ * @return {function} the wrapped function.
+ */
+Y.rbind = function(f, c) {
+ var xargs = arguments.length > 2 ? Y.Array(arguments, 2, true) : null;
+ return function() {
+ var fn = L.isString(f) ? c[f] : f,
+ args = (xargs) ?
+ Y.Array(arguments, 0, true).concat(xargs) : arguments;
+ return fn.apply(c || fn, args);
};
-
+};
}, '@VERSION@' ,{requires:['yui-base']});
diff --git a/build/resize-plugin/resize-plugin-debug.js b/build/resize-plugin/resize-plugin-debug.js
index 90f42dccbe5..0c9b712ef5e 100644
--- a/build/resize-plugin/resize-plugin-debug.js
+++ b/build/resize-plugin/resize-plugin-debug.js
@@ -193,4 +193,4 @@ var ResizePlugin = function(config) {
Y.Plugin.Resize = ResizePlugin;
-}, '@VERSION@' ,{optional:['resize-constrain'], skinnable:false, requires:['resize-base', 'plugin']});
+}, '@VERSION@' ,{skinnable:false, optional:['resize-constrain'], requires:['resize-base', 'plugin']});
diff --git a/build/resize-plugin/resize-plugin-min.js b/build/resize-plugin/resize-plugin-min.js
index 97e9cccd753..5d641c10c1c 100644
--- a/build/resize-plugin/resize-plugin-min.js
+++ b/build/resize-plugin/resize-plugin-min.js
@@ -1 +1 @@
-YUI.add("resize-plugin",function(b){var a=function(c){c.node=((b.Widget&&c.host instanceof b.Widget)?c.host.get("boundingBox"):c.host);if(c.host instanceof b.Widget){c.widget=c.host;}else{c.widget=false;}a.superclass.constructor.call(this,c);};a.NAME="resize-plugin";a.NS="resize";a.ATTRS={node:{value:undefined,},widget:{value:undefined}};b.extend(a,b.Resize,{initializer:function(c){this.set("node",c.node);this.set("widget",c.widget);this.on("resize:resize",function(d){this._correctDimensions(d);});},_correctDimensions:function(f){var d=this.get("node"),c={old:d.getX(),cur:f.currentTarget.info.left},g={old:d.getY(),cur:f.currentTarget.info.top};if(this.get("widget")){this._setWidgetProperties(f,c,g);}if(this._isDifferent(c.old,c.cur)){d.set("x",c.cur);}if(this._isDifferent(g.old,g.cur)){d.set("y",g.cur);}},_setWidgetProperties:function(h,c,k){var g=this.get("widget"),j=g.get("height"),d=g.get("width"),f=h.currentTarget.info.offsetWidth-h.currentTarget.totalHSurrounding,i=h.currentTarget.info.offsetHeight-h.currentTarget.totalVSurrounding;if(this._isDifferent(j,i)){g.set("height",i);}if(this._isDifferent(d,f)){g.set("width",f);}if(g.hasImpl&&g.hasImpl(b.WidgetPosition)){if(this._isDifferent(g.get("x"),c.cur)){g.set("x",c.cur);}if(this._isDifferent(g.get("y"),k.cur)){g.set("y",k.cur);}}},_isDifferent:function(c,d){if(c!==d){return d;}else{return false;}}});b.namespace("Plugin");b.Plugin.Resize=a;},"@VERSION@",{optional:["resize-constrain"],skinnable:false,requires:["resize-base","plugin"]});
\ No newline at end of file
+YUI.add("resize-plugin",function(b){var a=function(c){c.node=((b.Widget&&c.host instanceof b.Widget)?c.host.get("boundingBox"):c.host);if(c.host instanceof b.Widget){c.widget=c.host;}else{c.widget=false;}a.superclass.constructor.call(this,c);};a.NAME="resize-plugin";a.NS="resize";a.ATTRS={node:{value:undefined,},widget:{value:undefined}};b.extend(a,b.Resize,{initializer:function(c){this.set("node",c.node);this.set("widget",c.widget);this.on("resize:resize",function(d){this._correctDimensions(d);});},_correctDimensions:function(f){var d=this.get("node"),c={old:d.getX(),cur:f.currentTarget.info.left},g={old:d.getY(),cur:f.currentTarget.info.top};if(this.get("widget")){this._setWidgetProperties(f,c,g);}if(this._isDifferent(c.old,c.cur)){d.set("x",c.cur);}if(this._isDifferent(g.old,g.cur)){d.set("y",g.cur);}},_setWidgetProperties:function(h,c,k){var g=this.get("widget"),j=g.get("height"),d=g.get("width"),f=h.currentTarget.info.offsetWidth-h.currentTarget.totalHSurrounding,i=h.currentTarget.info.offsetHeight-h.currentTarget.totalVSurrounding;if(this._isDifferent(j,i)){g.set("height",i);}if(this._isDifferent(d,f)){g.set("width",f);}if(g.hasImpl&&g.hasImpl(b.WidgetPosition)){if(this._isDifferent(g.get("x"),c.cur)){g.set("x",c.cur);}if(this._isDifferent(g.get("y"),k.cur)){g.set("y",k.cur);}}},_isDifferent:function(c,d){if(c!==d){return d;}else{return false;}}});b.namespace("Plugin");b.Plugin.Resize=a;},"@VERSION@",{skinnable:false,optional:["resize-constrain"],requires:["resize-base","plugin"]});
\ No newline at end of file
diff --git a/build/resize-plugin/resize-plugin.js b/build/resize-plugin/resize-plugin.js
index 90f42dccbe5..0c9b712ef5e 100644
--- a/build/resize-plugin/resize-plugin.js
+++ b/build/resize-plugin/resize-plugin.js
@@ -193,4 +193,4 @@ var ResizePlugin = function(config) {
Y.Plugin.Resize = ResizePlugin;
-}, '@VERSION@' ,{optional:['resize-constrain'], skinnable:false, requires:['resize-base', 'plugin']});
+}, '@VERSION@' ,{skinnable:false, optional:['resize-constrain'], requires:['resize-base', 'plugin']});
diff --git a/build/scrollview-paginator/scrollview-paginator-debug.js b/build/scrollview-paginator/scrollview-paginator-debug.js
index 06d6d912164..7969052344b 100644
--- a/build/scrollview-paginator/scrollview-paginator-debug.js
+++ b/build/scrollview-paginator/scrollview-paginator-debug.js
@@ -6,7 +6,7 @@ YUI.add('scrollview-paginator', function(Y) {
* @module scrollview-paginator
*/
-var UI = Y.ScrollView.UI_SRC,
+var UI = (Y.ScrollView) ? Y.ScrollView.UI_SRC : "ui",
INDEX = "index",
SCROLL_X = "scrollX",
TOTAL = "total",
diff --git a/build/scrollview-paginator/scrollview-paginator-min.js b/build/scrollview-paginator/scrollview-paginator-min.js
index 5e40a3d5933..904041cae49 100644
--- a/build/scrollview-paginator/scrollview-paginator-min.js
+++ b/build/scrollview-paginator/scrollview-paginator-min.js
@@ -1 +1 @@
-YUI.add("scrollview-paginator",function(h){var g=h.ScrollView.UI_SRC,d="index",a="scrollX",f="total",e="boundingBox",c="contentBox";function b(){b.superclass.constructor.apply(this,arguments);}b.NAME="pluginScrollViewPaginator";b.NS="pages";b.ATTRS={selector:{value:null},index:{value:0},total:{value:0}};h.extend(b,h.Plugin.Base,{initializer:function(){var i,j=this;i=j._host=j.get("host");j.beforeHostMethod("_flickFrame",j._flickFrame);j.afterHostMethod("_uiDimensionsChange",j._calcOffsets);j.afterHostEvent("scrollEnd",j._scrollEnded);j.afterHostEvent("render",j._afterRender);j.after("indexChange",j._afterIndexChange);},_calcOffsets:function(){var l=this._host,j=l.get(c),n=l.get(e),m=this.get("selector"),i,k;i=m?j.all(m):j.get("children");this.set(f,i.size());this._pgOff=k=i.get("offsetLeft");k.push(l._scrollWidth-n.get("offsetWidth"));},_flickFrame:function(){var l=this._host,k=l._currentVelocity,m=k<0,i=this.get(d),j=this.get(f);if(k){if(m&&i
- *
- *
- *
- *
- *
- *
- *
- *
- * Y.Get.script(
- * ["http://yui.yahooapis.com/2.5.2/build/yahoo/yahoo-min.js",
- * "http://yui.yahooapis.com/2.5.2/build/event/event-min.js"],
- * {
- * onSuccess: function(o) {
- * this.log("won't cause error because Y is the context");
- * Y.log(o.data); // foo
- * Y.log(o.nodes.length === 2) // true
- * // o.purge(); // optionally remove the script nodes
- * // immediately
- * },
- * onFailure: function(o) {
- * Y.log("transaction failed");
- * },
- * onTimeout: function(o) {
- * Y.log("transaction timed out");
- * },
- * data: "foo",
- * timeout: 10000, // 10 second timeout
- * context: Y, // make the YUI instance
- * // win: otherframe // target another window/frame
- * autopurge: true // allow the utility to choose when to
- * // remove the nodes
- * purgetheshold: 1 // purge previous transaction before
- * // next transaction
- * });.
- *
- * @return {tId: string} an object containing info about the
- * transaction.
- */
- script: function(url, opts) {
- return _queue('script', url, opts);
- },
+ purging = false;
+ },
- /**
- * Fetches and inserts one or more css link nodes into the
- * head of the current document or the document in a specified
- * window.
- * @method css
- * @static
- * @param {string} url the url or urls to the css file(s).
- * @param {object} opts Options:
- *
- *
- * win
- *
- * Y.Get.css("http://localhost/css/menu.css");
- *
- *
- * Y.Get.css(
- * ["http://localhost/css/menu.css",
- * "http://localhost/css/logger.css"], {
- * insertBefore: 'custom-styles' // nodes will be inserted
- * // before the specified node
- * });.
- *
- * @return {tId: string} an object containing info about the
- * transaction.
- */
- css: function(url, opts) {
- return _queue('css', url, opts);
+ /**
+ * Saves the state for the request and begins loading
+ * the requested urls
+ * @method queue
+ * @param {string} type the type of node to insert.
+ * @param {string} url the url to load.
+ * @param {object} opts the hash of options for this request.
+ * @return {object} transaction object.
+ * @private
+ */
+ _queue = function(type, url, opts) {
+
+ opts = opts || {};
+
+ var id = 'q' + (qidx++),
+ thresh = opts.purgethreshold || Y.Get.PURGE_THRESH,
+ q;
+
+ if (qidx % thresh === 0) {
+ _autoPurge();
+ }
+
+ // Merge to protect opts (grandfathered in).
+ q = queues[id] = Y.merge(opts);
+
+ // Avoid mix, merge overhead. Known set of props.
+ q.tId = id;
+ q.type = type;
+ q.url = url;
+ q.finished = false;
+ q.nodes = [];
+
+ q.win = q.win || Y.config.win;
+ q.context = q.context || q;
+ q.autopurge = (AUTOPURGE in q) ? q.autopurge : (type === SCRIPT) ? true : false;
+ q.attributes = q.attributes || {};
+ q.attributes.charset = opts.charset || q.attributes.charset || UTF8;
+
+ if (ASYNC in q && type === SCRIPT) {
+ q.attributes.async = q.async;
+ }
+
+ q.url = (L.isString(q.url)) ? [q.url] : q.url;
+
+ // TODO: Do we really need to account for this developer error?
+ // If the url is undefined, this is probably a trailing comma problem in IE.
+ if (!q.url[0]) {
+ q.url.shift();
+ Y.log('skipping empty url');
}
+
+ q.remaining = q.url.length;
+
+ _next(id);
+
+ return {
+ tId: id
+ };
};
-}();
+Y.Get = {
+
+ /**
+ * The number of request required before an automatic purge.
+ * Can be configured via the 'purgethreshold' config
+ * property PURGE_THRESH
+ * @static
+ * @type int
+ * @default 20
+ * @private
+ */
+ PURGE_THRESH: 20,
+
+ /**
+ * Abort a transaction
+ * @method abort
+ * @static
+ * @param {string|object} o Either the tId or the object returned from
+ * script() or css().
+ */
+ abort : function(o) {
+ var id = (L.isString(o)) ? o : o.tId,
+ q = queues[id];
+
+ if (q) {
+ Y.log('Aborting ' + id, 'info', 'get');
+ q.aborted = true;
+ }
+ },
+
+ /**
+ * Fetches and inserts one or more script nodes into the head
+ * of the current document or the document in a specified window.
+ *
+ * @method script
+ * @static
+ * @param {string|string[]} url the url or urls to the script(s).
+ * @param {object} opts Options:
+ *
+ *
+ *
+ *
+ *
+ *
+ *
+ *
+ * url
+ * property, which identifies the file which was loaded.
+ * Y.Get.script(
+ * ["http://yui.yahooapis.com/2.5.2/build/yahoo/yahoo-min.js",
+ * "http://yui.yahooapis.com/2.5.2/build/event/event-min.js"],
+ * {
+ * onSuccess: function(o) {
+ * this.log("won't cause error because Y is the context");
+ * Y.log(o.data); // foo
+ * Y.log(o.nodes.length === 2) // true
+ * // o.purge(); // optionally remove the script nodes
+ * // immediately
+ * },
+ * onFailure: function(o) {
+ * Y.log("transaction failed");
+ * },
+ * onTimeout: function(o) {
+ * Y.log("transaction timed out");
+ * },
+ * data: "foo",
+ * timeout: 10000, // 10 second timeout
+ * context: Y, // make the YUI instance
+ * // win: otherframe // target another window/frame
+ * autopurge: true // allow the utility to choose when to
+ * // remove the nodes
+ * purgetheshold: 1 // purge previous transaction before
+ * // next transaction
+ * });.
+ *
+ * @return {tId: string} an object containing info about the
+ * transaction.
+ */
+ script: function(url, opts) {
+ return _queue(SCRIPT, url, opts);
+ },
+
+ /**
+ * Fetches and inserts one or more css link nodes into the
+ * head of the current document or the document in a specified
+ * window.
+ * @method css
+ * @static
+ * @param {string} url the url or urls to the css file(s).
+ * @param {object} opts Options:
+ *
+ *
+ * win
+ * url
property, which identifies the file which was loaded. Currently only useful for non Webkit/Gecko browsers,
+ * where onload for css is detected accurately.
+ * Y.Get.css("http://localhost/css/menu.css");
+ *
+ *
+ * Y.Get.css(
+ * ["http://localhost/css/menu.css",
+ * "http://localhost/css/logger.css"], {
+ * insertBefore: 'custom-styles' // nodes will be inserted
+ * // before the specified node
+ * });.
+ *
+ * @return {tId: string} an object containing info about the
+ * transaction.
+ */
+ css: function(url, opts) {
+ return _queue('css', url, opts);
+ }
+};
+
}, '@VERSION@' ,{requires:['yui-base']});
YUI.add('features', function(Y) {
@@ -4371,12 +4586,19 @@ Y.later = function(when, o, fn, data, periodic) {
when = when || 0;
data = (!Y.Lang.isUndefined(data)) ? Y.Array(data) : data;
- var method = (o && Y.Lang.isString(fn)) ? o[fn] : fn,
+ var cancelled = false,
+ method = (o && Y.Lang.isString(fn)) ? o[fn] : fn,
wrapper = function() {
- if (!method.apply) {
- method(data[0], data[1], data[2], data[3]);
- } else {
- method.apply(o, data || NO_ARGS);
+ // IE 8- may execute a setInterval callback one last time
+ // after clearInterval was called, so in order to preserve
+ // the cancel() === no more runny-run, we have to jump through
+ // an extra hoop.
+ if (!cancelled) {
+ if (!method.apply) {
+ method(data[0], data[1], data[2], data[3]);
+ } else {
+ method.apply(o, data || NO_ARGS);
+ }
}
},
id = (periodic) ? setInterval(wrapper, when) : setTimeout(wrapper, when);
@@ -4385,6 +4607,7 @@ Y.later = function(when, o, fn, data, periodic) {
id: id,
interval: periodic,
cancel: function() {
+ cancelled = true;
if (this.interval) {
clearInterval(id);
} else {
@@ -5386,7 +5609,7 @@ Y.Loader.prototype = {
o.supersedes = o.supersedes || o.use;
o.ext = ('ext' in o) ? o.ext : (this._internal) ? false : true;
- o.requires = o.requires || [];
+ o.requires = this.filterRequires(o.requires) || [];
// Handle submodule logic
var subs = o.submodules, i, l, sup, s, smod, plugins, plug,
@@ -5569,9 +5792,9 @@ Y.Loader.prototype = {
* @param {string[] | string*} what the modules to load.
*/
require: function(what) {
- var a = (typeof what === 'string') ? arguments : what;
+ var a = (typeof what === 'string') ? YArray(arguments) : what;
this.dirty = true;
- this.required = Y.merge(this.required, YArray.hash(a));
+ this.required = Y.merge(this.required, YArray.hash(this.filterRequires(a)));
this._explodeRollups();
},
@@ -5585,17 +5808,17 @@ Y.Loader.prototype = {
* @method _explodeRollups
*/
_explodeRollups: function() {
- var self = this,
+ var self = this, m,
r = self.required;
if (!self.allowRollup) {
oeach(r, function(v, name) {
m = self.getModule(name);
if (m && m.use) {
- delete r[name];
+ //delete r[name];
YArray.each(m.use, function(v) {
m = self.getModule(v);
if (m && m.use) {
- delete r[v];
+ //delete r[v];
YArray.each(m.use, function(v) {
r[v] = true;
});
@@ -5609,7 +5832,27 @@ Y.Loader.prototype = {
}
},
-
+ filterRequires: function(r) {
+ if (r) {
+ if (!Y.Lang.isArray(r)) {
+ r = [r];
+ }
+ r = Y.Array(r);
+ var c = [];
+ for (var i = 0; i < r.length; i++) {
+ var mod = this.getModule(r[i]);
+ if (mod && mod.use) {
+ for (var o = 0; o < mod.use.length; o++) {
+ c.push(mod.use[o]);
+ }
+ } else {
+ c.push(r[i]);
+ }
+ }
+ r = c;
+ }
+ return r;
+ },
/**
* Returns an object containing properties for all modules required
* in order to load the requested module
@@ -5627,7 +5870,7 @@ Y.Loader.prototype = {
var i, m, j, add, packName, lang, testresults = this.testresults,
name = mod.name, cond, go,
adddef = ON_PAGE[name] && ON_PAGE[name].details,
- d,
+ d, k, m1,
r, old_mod,
o, skinmod, skindef,
intl = mod.lang || mod.intl,
@@ -5658,7 +5901,7 @@ Y.Loader.prototype = {
d = [];
hash = {};
- r = mod.requires;
+ r = this.filterRequires(mod.requires);
o = mod.optional;
// Y.log("getRequires: " + name + " (dirty:" + this.dirty +
@@ -5982,6 +6225,9 @@ Y.Loader.prototype = {
// the setup phase is over, all modules have been created
self.dirty = false;
+
+ self._explodeRollups();
+ r = self.required;
oeach(r, function(v, name) {
if (!done[name]) {
@@ -6085,7 +6331,6 @@ Y.log('Undefined module: ' + mname + ', matched a pattern: ' +
}
}
}
- // Y.log('required now: ' + YObject.keys(r));
return r;
},
@@ -6760,47 +7005,13 @@ YUI.add('loader-yui3', function(Y) {
* @submodule yui3
*/
YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
+ "align-plugin": {
+ "requires": [
+ "node-screen",
+ "node-pluginhost"
+ ]
+ },
"anim": {
- "submodules": {
- "anim-base": {
- "requires": [
- "base-base",
- "node-style"
- ]
- },
- "anim-color": {
- "requires": [
- "anim-base"
- ]
- },
- "anim-curve": {
- "requires": [
- "anim-xy"
- ]
- },
- "anim-easing": {
- "requires": [
- "anim-base"
- ]
- },
- "anim-node-plugin": {
- "requires": [
- "node-pluginhost",
- "anim-base"
- ]
- },
- "anim-scroll": {
- "requires": [
- "anim-base"
- ]
- },
- "anim-xy": {
- "requires": [
- "anim-base",
- "node-screen"
- ]
- }
- },
"use": [
"anim-base",
"anim-color",
@@ -6811,43 +7022,45 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"anim-xy"
]
},
+ "anim-base": {
+ "requires": [
+ "base-base",
+ "node-style"
+ ]
+ },
+ "anim-color": {
+ "requires": [
+ "anim-base"
+ ]
+ },
+ "anim-curve": {
+ "requires": [
+ "anim-xy"
+ ]
+ },
+ "anim-easing": {
+ "requires": [
+ "anim-base"
+ ]
+ },
+ "anim-node-plugin": {
+ "requires": [
+ "node-pluginhost",
+ "anim-base"
+ ]
+ },
+ "anim-scroll": {
+ "requires": [
+ "anim-base"
+ ]
+ },
+ "anim-xy": {
+ "requires": [
+ "anim-base",
+ "node-screen"
+ ]
+ },
"app": {
- "submodules": {
- "controller": {
- "optional": [
- "querystring-parse"
- ],
- "requires": [
- "array-extras",
- "base-build",
- "history",
- "json"
- ]
- },
- "model": {
- "requires": [
- "base-build",
- "escape",
- "json-parse"
- ]
- },
- "model-list": {
- "requires": [
- "array-extras",
- "array-invoke",
- "arraylist",
- "base-build",
- "json-parse",
- "model"
- ]
- },
- "view": {
- "requires": [
- "base-build",
- "node-event-delegate"
- ]
- }
- },
"use": [
"controller",
"model",
@@ -6855,6 +7068,19 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"view"
]
},
+ "array-extras": {},
+ "array-invoke": {},
+ "arraylist": {},
+ "arraylist-add": {
+ "requires": [
+ "arraylist"
+ ]
+ },
+ "arraylist-filter": {
+ "requires": [
+ "arraylist"
+ ]
+ },
"arraysort": {
"requires": [
"yui-base"
@@ -6866,85 +7092,93 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
]
},
"attribute": {
- "submodules": {
- "attribute-base": {
- "requires": [
- "event-custom"
- ]
- },
- "attribute-complex": {
- "requires": [
- "attribute-base"
- ]
- }
- },
"use": [
"attribute-base",
"attribute-complex"
]
},
+ "attribute-base": {
+ "requires": [
+ "event-custom"
+ ]
+ },
+ "attribute-complex": {
+ "requires": [
+ "attribute-base"
+ ]
+ },
"autocomplete": {
- "submodules": {
- "autocomplete-base": {
- "optional": [
- "autocomplete-sources"
- ],
- "plugins": {
- "autocomplete-filters": {
- "path": "autocomplete/autocomplete-filters-min.js",
- "requires": [
- "array-extras",
- "text-wordbreak"
- ]
- },
- "autocomplete-filters-accentfold": {
- "path": "autocomplete/autocomplete-filters-accentfold-min.js",
- "requires": [
- "array-extras",
- "text-accentfold",
- "text-wordbreak"
- ]
- },
- "autocomplete-highlighters": {
- "path": "autocomplete/autocomplete-highlighters-min.js",
- "requires": [
- "array-extras",
- "highlight-base"
- ]
- },
- "autocomplete-highlighters-accentfold": {
- "path": "autocomplete/autocomplete-highlighters-accentfold-min.js",
- "requires": [
- "array-extras",
- "highlight-accentfold"
- ]
- }
- },
- "requires": [
- "array-extras",
- "base-build",
- "escape",
- "event-valuechange",
- "node-base"
- ]
- },
- "autocomplete-list": {
- "after": [
- "autocomplete-sources"
- ],
- "lang": [
- "en"
- ],
- "plugins": {
- "autocomplete-list-keys": {
- "condition": {
- "name": "autocomplete-list-keys",
- "test": function (Y) {
- // Only add keyboard support to autocomplete-list if this doesn't appear to
- // be an iOS or Android-based mobile device.
- //
- // There's currently no feasible way to actually detect whether a device has
- // a hardware keyboard, so this sniff will have to do. It can easily be
+ "use": [
+ "autocomplete-base",
+ "autocomplete-sources",
+ "autocomplete-list",
+ "autocomplete-plugin"
+ ]
+ },
+ "autocomplete-base": {
+ "optional": [
+ "autocomplete-sources"
+ ],
+ "requires": [
+ "array-extras",
+ "base-build",
+ "escape",
+ "event-valuechange",
+ "node-base"
+ ]
+ },
+ "autocomplete-filters": {
+ "requires": [
+ "array-extras",
+ "text-wordbreak"
+ ]
+ },
+ "autocomplete-filters-accentfold": {
+ "requires": [
+ "array-extras",
+ "text-accentfold",
+ "text-wordbreak"
+ ]
+ },
+ "autocomplete-highlighters": {
+ "requires": [
+ "array-extras",
+ "highlight-base"
+ ]
+ },
+ "autocomplete-highlighters-accentfold": {
+ "requires": [
+ "array-extras",
+ "highlight-accentfold"
+ ]
+ },
+ "autocomplete-list": {
+ "after": [
+ "autocomplete-sources"
+ ],
+ "lang": [
+ "en"
+ ],
+ "requires": [
+ "autocomplete-base",
+ "event-resize",
+ "selector-css3",
+ "shim-plugin",
+ "widget",
+ "widget-position",
+ "widget-position-align"
+ ],
+ "skinnable": true
+ },
+ "autocomplete-list-keys": {
+ "condition": {
+ "name": "autocomplete-list-keys",
+ "test": function (Y) {
+ // Only add keyboard support to autocomplete-list if this doesn't appear to
+ // be an iOS or Android-based mobile device.
+ //
+ // There's currently no feasible way to actually detect whether a device has
+ // a hardware keyboard, so this sniff will have to do. It can easily be
// overridden by manually loading the autocomplete-list-keys module.
//
// Worth noting: even though iOS supports bluetooth keyboards, Mobile Safari
@@ -6953,106 +7187,80 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
// available.
return !(Y.UA.ios || Y.UA.android);
},
- "trigger": "autocomplete-list"
- },
- "path": "autocomplete/autocomplete-list-keys-min.js",
- "requires": [
- "autocomplete-list",
- "base-build"
- ]
- },
- "autocomplete-plugin": {
- "path": "autocomplete/autocomplete-plugin-min.js",
- "requires": [
- "autocomplete-list",
- "node-pluginhost"
- ]
- }
- },
- "requires": [
- "autocomplete-base",
- "event-resize",
- "selector-css3",
- "shim-plugin",
- "widget",
- "widget-position",
- "widget-position-align"
- ],
- "skinnable": true
- },
- "autocomplete-sources": {
- "optional": [
- "io-base",
- "json-parse",
- "jsonp",
- "yql"
- ],
- "requires": [
- "autocomplete-base"
- ]
- }
+ "trigger": "autocomplete-list"
},
- "use": [
- "autocomplete-base",
- "autocomplete-sources",
+ "requires": [
"autocomplete-list",
- "autocomplete-plugin"
+ "base-build"
+ ]
+ },
+ "autocomplete-plugin": {
+ "requires": [
+ "autocomplete-list",
+ "node-pluginhost"
+ ]
+ },
+ "autocomplete-sources": {
+ "optional": [
+ "io-base",
+ "json-parse",
+ "jsonp",
+ "yql"
+ ],
+ "requires": [
+ "autocomplete-base"
]
},
"base": {
- "submodules": {
- "base-base": {
- "after": [
- "attribute-complex"
- ],
- "requires": [
- "attribute-base"
- ]
- },
- "base-build": {
- "requires": [
- "base-base"
- ]
- },
- "base-pluginhost": {
- "requires": [
- "base-base",
- "pluginhost"
- ]
- }
- },
"use": [
"base-base",
"base-pluginhost",
"base-build"
]
},
+ "base-base": {
+ "after": [
+ "attribute-complex"
+ ],
+ "requires": [
+ "attribute-base"
+ ]
+ },
+ "base-build": {
+ "requires": [
+ "base-base"
+ ]
+ },
+ "base-pluginhost": {
+ "requires": [
+ "base-base",
+ "pluginhost"
+ ]
+ },
"cache": {
- "submodules": {
- "cache-base": {
- "requires": [
- "base"
- ]
- },
- "cache-offline": {
- "requires": [
- "cache-base",
- "json"
- ]
- },
- "cache-plugin": {
- "requires": [
- "plugin",
- "cache-base"
- ]
- }
- },
"use": [
"cache-base",
"cache-offline",
"cache-plugin"
]
},
+ "cache-base": {
+ "requires": [
+ "base"
+ ]
+ },
+ "cache-offline": {
+ "requires": [
+ "cache-base",
+ "json"
+ ]
+ },
+ "cache-plugin": {
+ "requires": [
+ "plugin",
+ "cache-base"
+ ]
+ },
"charts": {
"requires": [
"dom",
@@ -7069,22 +7277,12 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"yui-base"
]
},
+ "clickable-rail": {
+ "requires": [
+ "slider-base"
+ ]
+ },
"collection": {
- "submodules": {
- "array-extras": {},
- "array-invoke": {},
- "arraylist": {},
- "arraylist-add": {
- "requires": [
- "arraylist"
- ]
- },
- "arraylist-filter": {
- "requires": [
- "arraylist"
- ]
- }
- },
"use": [
"array-extras",
"arraylist",
@@ -7106,15 +7304,6 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"en",
"es"
],
- "plugins": {
- "console-filters": {
- "requires": [
- "plugin",
- "console"
- ],
- "skinnable": true
- }
- },
"requires": [
"yui-log",
"widget",
@@ -7122,11 +7311,33 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
],
"skinnable": true
},
+ "console-filters": {
+ "requires": [
+ "plugin",
+ "console"
+ ],
+ "skinnable": true
+ },
+ "controller": {
+ "optional": [
+ "querystring-parse"
+ ],
+ "requires": [
+ "array-extras",
+ "base-build",
+ "history"
+ ]
+ },
"cookie": {
"requires": [
"yui-base"
]
},
+ "createlink-base": {
+ "requires": [
+ "editor-base"
+ ]
+ },
"cssbase": {
"after": [
"cssreset",
@@ -7136,7 +7347,6 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"cssfonts-context",
"cssgrids-context"
],
- "path": "cssbase/base-min.css",
"type": "css"
},
"cssbase-context": {
@@ -7148,15 +7358,12 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"cssfonts-context",
"cssgrids-context"
],
- "path": "cssbase/base-context-min.css",
"type": "css"
},
"cssfonts": {
- "path": "cssfonts/fonts-min.css",
"type": "css"
},
"cssfonts-context": {
- "path": "cssfonts/fonts-context-min.css",
"type": "css"
},
"cssgrids": {
@@ -7164,14 +7371,12 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"cssreset",
"cssfonts"
],
- "path": "cssgrids/grids-min.css",
"type": "css"
},
"cssgrids-context-deprecated": {
"optional": [
"cssreset-context"
],
- "path": "cssgrids-deprecated/grids-context-min.css",
"requires": [
"cssfonts-context"
],
@@ -7181,49 +7386,18 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"optional": [
"cssreset"
],
- "path": "cssgrids-deprecated/grids-min.css",
"requires": [
"cssfonts"
],
"type": "css"
},
"cssreset": {
- "path": "cssreset/reset-min.css",
"type": "css"
},
"cssreset-context": {
- "path": "cssreset/reset-context-min.css",
"type": "css"
},
"dataschema": {
- "submodules": {
- "dataschema-array": {
- "requires": [
- "dataschema-base"
- ]
- },
- "dataschema-base": {
- "requires": [
- "base"
- ]
- },
- "dataschema-json": {
- "requires": [
- "dataschema-base",
- "json"
- ]
- },
- "dataschema-text": {
- "requires": [
- "dataschema-base"
- ]
- },
- "dataschema-xml": {
- "requires": [
- "dataschema-base"
- ]
- }
- },
"use": [
"dataschema-base",
"dataschema-json",
@@ -7232,71 +7406,33 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"dataschema-text"
]
},
+ "dataschema-array": {
+ "requires": [
+ "dataschema-base"
+ ]
+ },
+ "dataschema-base": {
+ "requires": [
+ "base"
+ ]
+ },
+ "dataschema-json": {
+ "requires": [
+ "dataschema-base",
+ "json"
+ ]
+ },
+ "dataschema-text": {
+ "requires": [
+ "dataschema-base"
+ ]
+ },
+ "dataschema-xml": {
+ "requires": [
+ "dataschema-base"
+ ]
+ },
"datasource": {
- "submodules": {
- "datasource-arrayschema": {
- "requires": [
- "datasource-local",
- "plugin",
- "dataschema-array"
- ]
- },
- "datasource-cache": {
- "requires": [
- "datasource-local",
- "plugin",
- "cache-base"
- ]
- },
- "datasource-function": {
- "requires": [
- "datasource-local"
- ]
- },
- "datasource-get": {
- "requires": [
- "datasource-local",
- "get"
- ]
- },
- "datasource-io": {
- "requires": [
- "datasource-local",
- "io-base"
- ]
- },
- "datasource-jsonschema": {
- "requires": [
- "datasource-local",
- "plugin",
- "dataschema-json"
- ]
- },
- "datasource-local": {
- "requires": [
- "base"
- ]
- },
- "datasource-polling": {
- "requires": [
- "datasource-local"
- ]
- },
- "datasource-textschema": {
- "requires": [
- "datasource-local",
- "plugin",
- "dataschema-text"
- ]
- },
- "datasource-xmlschema": {
- "requires": [
- "datasource-local",
- "plugin",
- "dataschema-xml"
- ]
- }
- },
"use": [
"datasource-local",
"datasource-io",
@@ -7310,42 +7446,69 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"datasource-polling"
]
},
+ "datasource-arrayschema": {
+ "requires": [
+ "datasource-local",
+ "plugin",
+ "dataschema-array"
+ ]
+ },
+ "datasource-cache": {
+ "requires": [
+ "datasource-local",
+ "plugin",
+ "cache-base"
+ ]
+ },
+ "datasource-function": {
+ "requires": [
+ "datasource-local"
+ ]
+ },
+ "datasource-get": {
+ "requires": [
+ "datasource-local",
+ "get"
+ ]
+ },
+ "datasource-io": {
+ "requires": [
+ "datasource-local",
+ "io-base"
+ ]
+ },
+ "datasource-jsonschema": {
+ "requires": [
+ "datasource-local",
+ "plugin",
+ "dataschema-json"
+ ]
+ },
+ "datasource-local": {
+ "requires": [
+ "base"
+ ]
+ },
+ "datasource-polling": {
+ "requires": [
+ "datasource-local"
+ ]
+ },
+ "datasource-textschema": {
+ "requires": [
+ "datasource-local",
+ "plugin",
+ "dataschema-text"
+ ]
+ },
+ "datasource-xmlschema": {
+ "requires": [
+ "datasource-local",
+ "plugin",
+ "dataschema-xml"
+ ]
+ },
"datatable": {
- "submodules": {
- "datatable-base": {
- "requires": [
- "recordset-base",
- "widget",
- "substitute",
- "event-mouseenter"
- ],
- "skinnable": true
- },
- "datatable-datasource": {
- "requires": [
- "datatable-base",
- "plugin",
- "datasource-local"
- ]
- },
- "datatable-scroll": {
- "requires": [
- "datatable-base",
- "plugin",
- "stylesheet"
- ]
- },
- "datatable-sort": {
- "lang": [
- "en"
- ],
- "requires": [
- "datatable-base",
- "plugin",
- "recordset-sort"
- ]
- }
- },
"use": [
"datatable-base",
"datatable-datasource",
@@ -7353,227 +7516,156 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"datatable-scroll"
]
},
+ "datatable-base": {
+ "requires": [
+ "recordset-base",
+ "widget",
+ "substitute",
+ "event-mouseenter"
+ ],
+ "skinnable": true
+ },
+ "datatable-datasource": {
+ "requires": [
+ "datatable-base",
+ "plugin",
+ "datasource-local"
+ ]
+ },
+ "datatable-scroll": {
+ "requires": [
+ "datatable-base",
+ "plugin",
+ "stylesheet"
+ ]
+ },
+ "datatable-sort": {
+ "lang": [
+ "en"
+ ],
+ "requires": [
+ "datatable-base",
+ "plugin",
+ "recordset-sort"
+ ]
+ },
"datatype": {
- "submodules": {
- "datatype-date": {
- "lang": [
- "ar",
- "ar-JO",
- "ca",
- "ca-ES",
- "da",
- "da-DK",
- "de",
- "de-AT",
- "de-DE",
- "el",
- "el-GR",
- "en",
- "en-AU",
- "en-CA",
- "en-GB",
- "en-IE",
- "en-IN",
- "en-JO",
- "en-MY",
- "en-NZ",
- "en-PH",
- "en-SG",
- "en-US",
- "es",
- "es-AR",
- "es-BO",
- "es-CL",
- "es-CO",
- "es-EC",
- "es-ES",
- "es-MX",
- "es-PE",
- "es-PY",
- "es-US",
- "es-UY",
- "es-VE",
- "fi",
- "fi-FI",
- "fr",
- "fr-BE",
- "fr-CA",
- "fr-FR",
- "hi",
- "hi-IN",
- "id",
- "id-ID",
- "it",
- "it-IT",
- "ja",
- "ja-JP",
- "ko",
- "ko-KR",
- "ms",
- "ms-MY",
- "nb",
- "nb-NO",
- "nl",
- "nl-BE",
- "nl-NL",
- "pl",
- "pl-PL",
- "pt",
- "pt-BR",
- "ro",
- "ro-RO",
- "ru",
- "ru-RU",
- "sv",
- "sv-SE",
- "th",
- "th-TH",
- "tr",
- "tr-TR",
- "vi",
- "vi-VN",
- "zh-Hans",
- "zh-Hans-CN",
- "zh-Hant",
- "zh-Hant-HK",
- "zh-Hant-TW"
- ],
- "submodules": {
- "datatype-date-format": {
- "path": "datatype/datatype-date-format-min.js"
- },
- "datatype-date-parse": {
- "path": "datatype/datatype-date-parse-min.js"
- }
- },
- "supersedes": [
- "datatype-date-format"
- ],
- "use2": [
- "datatype-date-parse",
- "datatype-date-format"
- ]
- },
- "datatype-number": {
- "submodules": {
- "datatype-number-format": {
- "path": "datatype/datatype-number-format-min.js"
- },
- "datatype-number-parse": {
- "path": "datatype/datatype-number-parse-min.js"
- }
- },
- "use": [
- "datatype-number-parse",
- "datatype-number-format"
- ]
- },
- "datatype-xml": {
- "submodules": {
- "datatype-xml-format": {
- "path": "datatype/datatype-xml-format-min.js"
- },
- "datatype-xml-parse": {
- "path": "datatype/datatype-xml-parse-min.js"
- }
- },
- "use": [
- "datatype-xml-parse",
- "datatype-xml-format"
- ]
- }
- },
"use": [
"datatype-number",
"datatype-date",
"datatype-xml"
]
},
+ "datatype-date": {
+ "lang": [
+ "ar",
+ "ar-JO",
+ "ca",
+ "ca-ES",
+ "da",
+ "da-DK",
+ "de",
+ "de-AT",
+ "de-DE",
+ "el",
+ "el-GR",
+ "en",
+ "en-AU",
+ "en-CA",
+ "en-GB",
+ "en-IE",
+ "en-IN",
+ "en-JO",
+ "en-MY",
+ "en-NZ",
+ "en-PH",
+ "en-SG",
+ "en-US",
+ "es",
+ "es-AR",
+ "es-BO",
+ "es-CL",
+ "es-CO",
+ "es-EC",
+ "es-ES",
+ "es-MX",
+ "es-PE",
+ "es-PY",
+ "es-US",
+ "es-UY",
+ "es-VE",
+ "fi",
+ "fi-FI",
+ "fr",
+ "fr-BE",
+ "fr-CA",
+ "fr-FR",
+ "hi",
+ "hi-IN",
+ "id",
+ "id-ID",
+ "it",
+ "it-IT",
+ "ja",
+ "ja-JP",
+ "ko",
+ "ko-KR",
+ "ms",
+ "ms-MY",
+ "nb",
+ "nb-NO",
+ "nl",
+ "nl-BE",
+ "nl-NL",
+ "pl",
+ "pl-PL",
+ "pt",
+ "pt-BR",
+ "ro",
+ "ro-RO",
+ "ru",
+ "ru-RU",
+ "sv",
+ "sv-SE",
+ "th",
+ "th-TH",
+ "tr",
+ "tr-TR",
+ "vi",
+ "vi-VN",
+ "zh-Hans",
+ "zh-Hans-CN",
+ "zh-Hant",
+ "zh-Hant-HK",
+ "zh-Hant-TW"
+ ],
+ "supersedes": [
+ "datatype-date-format"
+ ],
+ "use2": [
+ "datatype-date-parse",
+ "datatype-date-format"
+ ]
+ },
+ "datatype-date-format": {},
+ "datatype-date-parse": {},
+ "datatype-number": {
+ "use": [
+ "datatype-number-parse",
+ "datatype-number-format"
+ ]
+ },
+ "datatype-number-format": {},
+ "datatype-number-parse": {},
+ "datatype-xml": {
+ "use": [
+ "datatype-xml-parse",
+ "datatype-xml-format"
+ ]
+ },
+ "datatype-xml-format": {},
+ "datatype-xml-parse": {},
"dd": {
- "plugins": {
- "dd-drop-plugin": {
- "requires": [
- "dd-drop"
- ]
- },
- "dd-gestures": {
- "condition": {
- "name": "dd-gestures",
- "test": function(Y) {
- return (Y.config.win && ('ontouchstart' in Y.config.win && !Y.UA.chrome));
-},
- "trigger": "dd-drag"
- },
- "requires": [
- "dd-drag",
- "event-synthetic",
- "event-gestures"
- ]
- },
- "dd-plugin": {
- "optional": [
- "dd-constrain",
- "dd-proxy"
- ],
- "requires": [
- "dd-drag"
- ]
- }
- },
- "submodules": {
- "dd-constrain": {
- "requires": [
- "dd-drag"
- ]
- },
- "dd-ddm": {
- "requires": [
- "dd-ddm-base",
- "event-resize"
- ]
- },
- "dd-ddm-base": {
- "requires": [
- "node",
- "base",
- "yui-throttle",
- "classnamemanager"
- ]
- },
- "dd-ddm-drop": {
- "requires": [
- "dd-ddm"
- ]
- },
- "dd-delegate": {
- "requires": [
- "dd-drag",
- "dd-drop-plugin",
- "event-mouseenter"
- ]
- },
- "dd-drag": {
- "requires": [
- "dd-ddm-base"
- ]
- },
- "dd-drop": {
- "requires": [
- "dd-drag",
- "dd-ddm-drop"
- ]
- },
- "dd-proxy": {
- "requires": [
- "dd-drag"
- ]
- },
- "dd-scroll": {
- "requires": [
- "dd-drag"
- ]
- }
- },
"use": [
"dd-ddm-base",
"dd-ddm",
@@ -7586,40 +7678,178 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"dd-delegate"
]
},
- "dial": {
- "lang": [
- "en",
- "es"
- ],
+ "dd-constrain": {
"requires": [
- "widget",
- "dd-drag",
- "substitute",
- "event-mouseenter",
- "event-move",
- "transition",
- "intl"
- ],
- "skinnable": true
+ "dd-drag"
+ ]
},
- "dom": {
- "plugins": {
- "dom-deprecated": {
- "requires": [
- "dom-core"
- ]
- },
- "dom-style-ie": {
- "condition": {
- "name": "dom-style-ie",
- "test": function (Y) {
-
- var testFeature = Y.Features.test,
- addFeature = Y.Features.add,
- WINDOW = Y.config.win,
- DOCUMENT = Y.config.doc,
- DOCUMENT_ELEMENT = 'documentElement',
- ret = false;
+ "dd-ddm": {
+ "requires": [
+ "dd-ddm-base",
+ "event-resize"
+ ]
+ },
+ "dd-ddm-base": {
+ "requires": [
+ "node",
+ "base",
+ "yui-throttle",
+ "classnamemanager"
+ ]
+ },
+ "dd-ddm-drop": {
+ "requires": [
+ "dd-ddm"
+ ]
+ },
+ "dd-delegate": {
+ "requires": [
+ "dd-drag",
+ "dd-drop-plugin",
+ "event-mouseenter"
+ ]
+ },
+ "dd-drag": {
+ "requires": [
+ "dd-ddm-base"
+ ]
+ },
+ "dd-drop": {
+ "requires": [
+ "dd-drag",
+ "dd-ddm-drop"
+ ]
+ },
+ "dd-drop-plugin": {
+ "requires": [
+ "dd-drop"
+ ]
+ },
+ "dd-gestures": {
+ "condition": {
+ "name": "dd-gestures",
+ "test": function(Y) {
+ return (Y.config.win && ('ontouchstart' in Y.config.win && !Y.UA.chrome));
+},
+ "trigger": "dd-drag"
+ },
+ "requires": [
+ "dd-drag",
+ "event-synthetic",
+ "event-gestures"
+ ]
+ },
+ "dd-plugin": {
+ "optional": [
+ "dd-constrain",
+ "dd-proxy"
+ ],
+ "requires": [
+ "dd-drag"
+ ]
+ },
+ "dd-proxy": {
+ "requires": [
+ "dd-drag"
+ ]
+ },
+ "dd-scroll": {
+ "requires": [
+ "dd-drag"
+ ]
+ },
+ "dial": {
+ "lang": [
+ "en",
+ "es"
+ ],
+ "requires": [
+ "widget",
+ "dd-drag",
+ "substitute",
+ "event-mouseenter",
+ "event-move",
+ "transition",
+ "intl"
+ ],
+ "skinnable": true
+ },
+ "dom": {
+ "use": [
+ "dom-core",
+ "dom-base",
+ "dom-attrs",
+ "dom-create",
+ "dom-class",
+ "dom-size",
+ "dom-screen",
+ "dom-style",
+ "selector-native",
+ "selector"
+ ]
+ },
+ "dom-attrs": {
+ "requires": [
+ "dom-core"
+ ]
+ },
+ "dom-base": {
+ "requires": [
+ "dom-core",
+ "dom-attrs",
+ "dom-create",
+ "dom-class",
+ "dom-size"
+ ]
+ },
+ "dom-class": {
+ "requires": [
+ "dom-core"
+ ]
+ },
+ "dom-core": {
+ "requires": [
+ "oop",
+ "features"
+ ]
+ },
+ "dom-create": {
+ "requires": [
+ "dom-core"
+ ]
+ },
+ "dom-deprecated": {
+ "requires": [
+ "dom-core"
+ ]
+ },
+ "dom-screen": {
+ "requires": [
+ "dom-core",
+ "dom-style"
+ ]
+ },
+ "dom-size": {
+ "requires": [
+ "dom-core"
+ ]
+ },
+ "dom-style": {
+ "requires": [
+ "dom-core"
+ ]
+ },
+ "dom-style-ie": {
+ "condition": {
+ "name": "dom-style-ie",
+ "test": function (Y) {
+
+ var testFeature = Y.Features.test,
+ addFeature = Y.Features.add,
+ WINDOW = Y.config.win,
+ DOCUMENT = Y.config.doc,
+ DOCUMENT_ELEMENT = 'documentElement',
+ ret = false;
addFeature('style', 'computedStyle', {
test: function() {
@@ -7638,167 +7868,14 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
return ret;
},
- "trigger": "dom-style"
- },
- "requires": [
- "dom-style"
- ]
- },
- "selector-css2": {
- "condition": {
- "name": "selector-css2",
- "test": function (Y) {
- var DOCUMENT = Y.config.doc,
- ret = DOCUMENT && !('querySelectorAll' in DOCUMENT);
-
- return ret;
-},
- "trigger": "selector"
- },
- "requires": [
- "selector-native"
- ]
- },
- "selector-css3": {
- "requires": [
- "selector-native",
- "selector-css2"
- ]
- }
- },
- "submodules": {
- "dom-attrs": {
- "requires": [
- "dom-core"
- ]
- },
- "dom-base": {
- "requires": [
- "dom-core",
- "dom-attrs",
- "dom-create",
- "dom-class",
- "dom-size"
- ]
- },
- "dom-class": {
- "requires": [
- "dom-core"
- ]
- },
- "dom-core": {
- "requires": [
- "oop",
- "features"
- ]
- },
- "dom-create": {
- "requires": [
- "dom-core"
- ]
- },
- "dom-screen": {
- "requires": [
- "dom-core",
- "dom-style"
- ]
- },
- "dom-size": {
- "requires": [
- "dom-core"
- ]
- },
- "dom-style": {
- "requires": [
- "dom-core"
- ]
- },
- "selector": {
- "requires": [
- "selector-native"
- ]
- },
- "selector-native": {
- "requires": [
- "dom-core"
- ]
- }
+ "trigger": "dom-style"
},
- "use": [
- "dom-core",
- "dom-base",
- "dom-attrs",
- "dom-create",
- "dom-class",
- "dom-size",
- "dom-screen",
- "dom-style",
- "selector-native",
- "selector"
+ "requires": [
+ "dom-style"
]
},
"dump": {},
"editor": {
- "submodules": {
- "createlink-base": {
- "requires": [
- "editor-base"
- ]
- },
- "editor-base": {
- "requires": [
- "base",
- "frame",
- "node",
- "exec-command",
- "selection"
- ]
- },
- "editor-bidi": {
- "requires": [
- "editor-base"
- ]
- },
- "editor-br": {
- "requires": [
- "editor-base"
- ]
- },
- "editor-lists": {
- "requires": [
- "editor-base"
- ]
- },
- "editor-para": {
- "requires": [
- "editor-base"
- ]
- },
- "editor-tab": {
- "requires": [
- "editor-base"
- ]
- },
- "exec-command": {
- "requires": [
- "frame"
- ]
- },
- "frame": {
- "requires": [
- "base",
- "node",
- "selector-css3",
- "substitute",
- "yui-throttle"
- ]
- },
- "selection": {
- "requires": [
- "node"
- ]
- }
- },
"use": [
"frame",
"selection",
@@ -7811,85 +7888,45 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"createlink-base"
]
},
+ "editor-base": {
+ "requires": [
+ "base",
+ "frame",
+ "node",
+ "exec-command",
+ "selection"
+ ]
+ },
+ "editor-bidi": {
+ "requires": [
+ "editor-base"
+ ]
+ },
+ "editor-br": {
+ "requires": [
+ "editor-base"
+ ]
+ },
+ "editor-lists": {
+ "requires": [
+ "editor-base"
+ ]
+ },
+ "editor-para": {
+ "requires": [
+ "editor-base"
+ ]
+ },
+ "editor-tab": {
+ "requires": [
+ "editor-base"
+ ]
+ },
"escape": {},
"event": {
"after": [
"node-base"
],
- "plugins": {
- "event-base-ie": {
- "after": [
- "event-base"
- ],
- "condition": {
- "name": "event-base-ie",
- "test": function(Y) {
- var imp = Y.config.doc && Y.config.doc.implementation;
- return (imp && (!imp.hasFeature('Events', '2.0')));
-},
- "trigger": "node-base"
- },
- "requires": [
- "node-base"
- ]
- },
- "event-touch": {
- "requires": [
- "node-base"
- ]
- }
- },
- "submodules": {
- "event-base": {
- "after": [
- "node-base"
- ],
- "requires": [
- "event-custom-base"
- ]
- },
- "event-delegate": {
- "requires": [
- "node-base"
- ]
- },
- "event-focus": {
- "requires": [
- "event-synthetic"
- ]
- },
- "event-hover": {
- "requires": [
- "event-mouseenter"
- ]
- },
- "event-key": {
- "requires": [
- "event-synthetic"
- ]
- },
- "event-mouseenter": {
- "requires": [
- "event-synthetic"
- ]
- },
- "event-mousewheel": {
- "requires": [
- "node-base"
- ]
- },
- "event-resize": {
- "requires": [
- "node-base"
- ]
- },
- "event-synthetic": {
- "requires": [
- "node-base",
- "event-custom-complex"
- ]
- }
- },
"use": [
"event-base",
"event-delegate",
@@ -7902,129 +7939,213 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"event-hover"
]
},
- "event-custom": {
- "submodules": {
- "event-custom-base": {
- "requires": [
- "oop"
- ]
- },
- "event-custom-complex": {
- "requires": [
- "event-custom-base"
- ]
- }
+ "event-base": {
+ "after": [
+ "node-base"
+ ],
+ "requires": [
+ "event-custom-base"
+ ]
+ },
+ "event-base-ie": {
+ "after": [
+ "event-base"
+ ],
+ "condition": {
+ "name": "event-base-ie",
+ "test": function(Y) {
+ var imp = Y.config.doc && Y.config.doc.implementation;
+ return (imp && (!imp.hasFeature('Events', '2.0')));
+},
+ "trigger": "node-base"
},
+ "requires": [
+ "node-base"
+ ]
+ },
+ "event-custom": {
"use": [
"event-custom-base",
"event-custom-complex"
]
},
+ "event-custom-base": {
+ "requires": [
+ "oop"
+ ]
+ },
+ "event-custom-complex": {
+ "requires": [
+ "event-custom-base"
+ ]
+ },
+ "event-delegate": {
+ "requires": [
+ "node-base"
+ ]
+ },
+ "event-flick": {
+ "requires": [
+ "node-base",
+ "event-touch",
+ "event-synthetic"
+ ]
+ },
+ "event-focus": {
+ "requires": [
+ "event-synthetic"
+ ]
+ },
"event-gestures": {
- "submodules": {
- "event-flick": {
- "requires": [
- "node-base",
- "event-touch",
- "event-synthetic"
- ]
- },
- "event-move": {
- "requires": [
- "node-base",
- "event-touch",
- "event-synthetic"
- ]
- }
- },
"use": [
"event-flick",
"event-move"
]
},
+ "event-hover": {
+ "requires": [
+ "event-mouseenter"
+ ]
+ },
+ "event-key": {
+ "requires": [
+ "event-synthetic"
+ ]
+ },
+ "event-mouseenter": {
+ "requires": [
+ "event-synthetic"
+ ]
+ },
+ "event-mousewheel": {
+ "requires": [
+ "node-base"
+ ]
+ },
+ "event-move": {
+ "requires": [
+ "node-base",
+ "event-touch",
+ "event-synthetic"
+ ]
+ },
+ "event-resize": {
+ "requires": [
+ "node-base"
+ ]
+ },
"event-simulate": {
"requires": [
"event-base"
]
},
+ "event-synthetic": {
+ "requires": [
+ "node-base",
+ "event-custom-complex"
+ ]
+ },
+ "event-touch": {
+ "requires": [
+ "node-base"
+ ]
+ },
"event-valuechange": {
"requires": [
"event-focus",
"event-synthetic"
]
},
+ "exec-command": {
+ "requires": [
+ "frame"
+ ]
+ },
+ "features": {
+ "requires": [
+ "yui-base"
+ ]
+ },
+ "frame": {
+ "requires": [
+ "base",
+ "node",
+ "selector-css3",
+ "substitute",
+ "yui-throttle"
+ ]
+ },
+ "get": {
+ "requires": [
+ "yui-base"
+ ]
+ },
"highlight": {
- "submodules": {
- "highlight-accentfold": {
- "requires": [
- "highlight-base",
- "text-accentfold"
- ]
- },
- "highlight-base": {
- "requires": [
- "array-extras",
- "escape",
- "text-wordbreak"
- ]
- }
- },
"use": [
"highlight-base",
"highlight-accentfold"
]
},
- "history": {
- "plugins": {
- "history-hash-ie": {
- "condition": {
- "name": "history-hash-ie",
- "test": function (Y) {
+ "highlight-accentfold": {
+ "requires": [
+ "highlight-base",
+ "text-accentfold"
+ ]
+ },
+ "highlight-base": {
+ "requires": [
+ "array-extras",
+ "escape",
+ "text-wordbreak"
+ ]
+ },
+ "history": {
+ "use": [
+ "history-base",
+ "history-hash",
+ "history-hash-ie",
+ "history-html5"
+ ]
+ },
+ "history-base": {
+ "requires": [
+ "event-custom-complex"
+ ]
+ },
+ "history-hash": {
+ "after": [
+ "history-html5"
+ ],
+ "requires": [
+ "event-synthetic",
+ "history-base",
+ "yui-later"
+ ]
+ },
+ "history-hash-ie": {
+ "condition": {
+ "name": "history-hash-ie",
+ "test": function (Y) {
var docMode = Y.config.doc && Y.config.doc.documentMode;
return Y.UA.ie && (!('onhashchange' in Y.config.win) ||
!docMode || docMode < 8);
},
- "trigger": "history-hash"
- },
- "requires": [
- "history-hash",
- "node-base"
- ]
- }
+ "trigger": "history-hash"
},
- "submodules": {
- "history-base": {
- "requires": [
- "event-custom-complex"
- ]
- },
- "history-hash": {
- "after": [
- "history-html5"
- ],
- "requires": [
- "event-synthetic",
- "history-base",
- "yui-later"
- ]
- },
- "history-html5": {
- "optional": [
- "json"
- ],
- "requires": [
- "event-base",
- "history-base",
- "node-base"
- ]
- }
- },
- "use": [
- "history-base",
+ "requires": [
"history-hash",
- "history-hash-ie",
- "history-html5"
+ "node-base"
+ ]
+ },
+ "history-html5": {
+ "optional": [
+ "json"
+ ],
+ "requires": [
+ "event-base",
+ "history-base",
+ "node-base"
]
},
"imageloader": {
@@ -8040,39 +8161,12 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"event-custom"
]
},
+ "intl-base": {
+ "requires": [
+ "yui-base"
+ ]
+ },
"io": {
- "submodules": {
- "io-base": {
- "requires": [
- "event-custom-base",
- "querystring-stringify-simple"
- ]
- },
- "io-form": {
- "requires": [
- "io-base",
- "node-base"
- ]
- },
- "io-queue": {
- "requires": [
- "io-base",
- "queue-promote"
- ]
- },
- "io-upload-iframe": {
- "requires": [
- "io-base",
- "node-base"
- ]
- },
- "io-xdr": {
- "requires": [
- "io-base",
- "datatype-xml"
- ]
- }
- },
"use": [
"io-base",
"io-xdr",
@@ -8081,118 +8175,95 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"io-queue"
]
},
+ "io-base": {
+ "requires": [
+ "event-custom-base",
+ "querystring-stringify-simple"
+ ]
+ },
+ "io-form": {
+ "requires": [
+ "io-base",
+ "node-base"
+ ]
+ },
+ "io-queue": {
+ "requires": [
+ "io-base",
+ "queue-promote"
+ ]
+ },
+ "io-upload-iframe": {
+ "requires": [
+ "io-base",
+ "node-base"
+ ]
+ },
+ "io-xdr": {
+ "requires": [
+ "io-base",
+ "datatype-xml"
+ ]
+ },
"json": {
- "submodules": {
- "json-parse": {},
- "json-stringify": {}
- },
"use": [
"json-parse",
"json-stringify"
]
},
+ "json-parse": {},
+ "json-stringify": {},
"jsonp": {
- "plugins": {
- "jsonp-url": {
- "requires": [
- "jsonp"
- ]
- }
- },
"requires": [
"get",
"oop"
]
},
+ "jsonp-url": {
+ "requires": [
+ "jsonp"
+ ]
+ },
"loader": {
- "submodules": {
- "loader-base": {
- "requires": [
- "get"
- ]
- },
- "loader-rollup": {
- "requires": [
- "loader-base"
- ]
- },
- "loader-yui3": {
- "requires": [
- "loader-base"
- ]
- }
- },
"use": [
"loader-base",
"loader-rollup",
"loader-yui3"
]
},
+ "loader-base": {
+ "requires": [
+ "get"
+ ]
+ },
+ "loader-rollup": {
+ "requires": [
+ "loader-base"
+ ]
+ },
+ "loader-yui3": {
+ "requires": [
+ "loader-base"
+ ]
+ },
+ "model": {
+ "requires": [
+ "base-build",
+ "escape",
+ "json-parse"
+ ]
+ },
+ "model-list": {
+ "requires": [
+ "array-extras",
+ "array-invoke",
+ "arraylist",
+ "base-build",
+ "json-parse",
+ "model"
+ ]
+ },
"node": {
- "plugins": {
- "align-plugin": {
- "requires": [
- "node-screen",
- "node-pluginhost"
- ]
- },
- "node-deprecated": {
- "requires": [
- "node-base"
- ]
- },
- "node-event-simulate": {
- "requires": [
- "node-base",
- "event-simulate"
- ]
- },
- "node-load": {
- "requires": [
- "node-base",
- "io-base"
- ]
- },
- "shim-plugin": {
- "requires": [
- "node-style",
- "node-pluginhost"
- ]
- }
- },
- "submodules": {
- "node-base": {
- "requires": [
- "dom-base",
- "selector-css2",
- "event-base"
- ]
- },
- "node-event-delegate": {
- "requires": [
- "node-base",
- "event-delegate"
- ]
- },
- "node-pluginhost": {
- "requires": [
- "node-base",
- "pluginhost"
- ]
- },
- "node-screen": {
- "requires": [
- "dom-screen",
- "node-base"
- ]
- },
- "node-style": {
- "requires": [
- "dom-style",
- "node-base"
- ]
- }
- },
"use": [
"node-base",
"node-event-delegate",
@@ -8201,6 +8272,30 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"node-style"
]
},
+ "node-base": {
+ "requires": [
+ "dom-base",
+ "selector-css2",
+ "event-base"
+ ]
+ },
+ "node-deprecated": {
+ "requires": [
+ "node-base"
+ ]
+ },
+ "node-event-delegate": {
+ "requires": [
+ "node-base",
+ "event-delegate"
+ ]
+ },
+ "node-event-simulate": {
+ "requires": [
+ "node-base",
+ "event-simulate"
+ ]
+ },
"node-flick": {
"requires": [
"classnamemanager",
@@ -8220,6 +8315,12 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"event-focus"
]
},
+ "node-load": {
+ "requires": [
+ "node-base",
+ "io-base"
+ ]
+ },
"node-menunav": {
"requires": [
"node",
@@ -8229,6 +8330,24 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
],
"skinnable": true
},
+ "node-pluginhost": {
+ "requires": [
+ "node-base",
+ "pluginhost"
+ ]
+ },
+ "node-screen": {
+ "requires": [
+ "dom-screen",
+ "node-base"
+ ]
+ },
+ "node-style": {
+ "requires": [
+ "dom-style",
+ "node-base"
+ ]
+ },
"oop": {
"requires": [
"yui-base"
@@ -8246,68 +8365,59 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"skinnable": true
},
"plugin": {
- "plugins": {
- "pluginattr": {
- "path": "plugin/pluginattr-min.js",
- "requires": [
- "plugin"
- ]
- }
- },
"requires": [
"base-base"
]
},
+ "pluginattr": {
+ "requires": [
+ "plugin"
+ ]
+ },
"pluginhost": {
- "submodules": {
- "pluginhost-base": {
- "requires": [
- "yui-base"
- ]
- },
- "pluginhost-config": {
- "requires": [
- "pluginhost-base"
- ]
- }
- },
"use": [
"pluginhost-base",
"pluginhost-config"
]
},
+ "pluginhost-base": {
+ "requires": [
+ "yui-base"
+ ]
+ },
+ "pluginhost-config": {
+ "requires": [
+ "pluginhost-base"
+ ]
+ },
"profiler": {
"requires": [
"yui-base"
]
},
"querystring": {
- "submodules": {
- "querystring-parse": {
- "requires": [
- "yui-base",
- "array-extras"
- ]
- },
- "querystring-stringify": {
- "requires": [
- "yui-base"
- ]
- }
- },
"use": [
"querystring-parse",
"querystring-stringify"
]
},
+ "querystring-parse": {
+ "requires": [
+ "yui-base",
+ "array-extras"
+ ]
+ },
"querystring-parse-simple": {
- "path": "querystring/querystring-parse-simple-min.js",
+ "requires": [
+ "yui-base"
+ ]
+ },
+ "querystring-stringify": {
"requires": [
"yui-base"
]
},
"querystring-stringify-simple": {
- "path": "querystring/querystring-stringify-simple-min.js",
"requires": [
"yui-base"
]
@@ -8317,35 +8427,14 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"yui-base"
]
},
+ "range-slider": {
+ "requires": [
+ "slider-base",
+ "slider-value-range",
+ "clickable-rail"
+ ]
+ },
"recordset": {
- "submodules": {
- "recordset-base": {
- "requires": [
- "base",
- "arraylist"
- ]
- },
- "recordset-filter": {
- "requires": [
- "recordset-base",
- "array-extras",
- "plugin"
- ]
- },
- "recordset-indexer": {
- "requires": [
- "recordset-base",
- "plugin"
- ]
- },
- "recordset-sort": {
- "requires": [
- "arraysort",
- "recordset-base",
- "plugin"
- ]
- }
- },
"use": [
"recordset-base",
"recordset-sort",
@@ -8353,119 +8442,159 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"recordset-indexer"
]
},
+ "recordset-base": {
+ "requires": [
+ "base",
+ "arraylist"
+ ]
+ },
+ "recordset-filter": {
+ "requires": [
+ "recordset-base",
+ "array-extras",
+ "plugin"
+ ]
+ },
+ "recordset-indexer": {
+ "requires": [
+ "recordset-base",
+ "plugin"
+ ]
+ },
+ "recordset-sort": {
+ "requires": [
+ "arraysort",
+ "recordset-base",
+ "plugin"
+ ]
+ },
"resize": {
- "plugins": {
- "resize-plugin": {
- "optional": [
- "resize-constrain"
- ],
- "requires": [
- "resize-base",
- "plugin"
- ]
- }
- },
- "submodules": {
- "resize-base": {
- "requires": [
- "base",
- "widget",
- "substitute",
- "event",
- "oop",
- "dd-drag",
- "dd-delegate",
- "dd-drop"
- ],
- "skinnable": true
- },
- "resize-constrain": {
- "requires": [
- "plugin",
- "resize-base"
- ]
- },
- "resize-proxy": {
- "requires": [
- "plugin",
- "resize-base"
- ]
- }
- },
"use": [
"resize-base",
"resize-proxy",
"resize-constrain"
]
},
+ "resize-base": {
+ "requires": [
+ "base",
+ "widget",
+ "substitute",
+ "event",
+ "oop",
+ "dd-drag",
+ "dd-delegate",
+ "dd-drop"
+ ],
+ "skinnable": true
+ },
+ "resize-constrain": {
+ "requires": [
+ "plugin",
+ "resize-base"
+ ]
+ },
+ "resize-plugin": {
+ "optional": [
+ "resize-constrain"
+ ],
+ "requires": [
+ "resize-base",
+ "plugin"
+ ]
+ },
+ "resize-proxy": {
+ "requires": [
+ "plugin",
+ "resize-base"
+ ]
+ },
+ "rls": {
+ "requires": [
+ "get",
+ "features"
+ ]
+ },
"scrollview": {
- "plugins": {
- "scrollview-base": {
- "path": "scrollview/scrollview-base-min.js",
- "requires": [
- "widget",
- "event-gestures",
- "transition"
- ],
- "skinnable": true
- },
- "scrollview-base-ie": {
- "condition": {
- "name": "scrollview-base-ie",
- "trigger": "scrollview-base",
- "ua": "ie"
- },
- "requires": [
- "scrollview-base"
- ]
- },
- "scrollview-paginator": {
- "path": "scrollview/scrollview-paginator-min.js",
- "requires": [
- "plugin"
- ]
- },
- "scrollview-scrollbars": {
- "path": "scrollview/scrollview-scrollbars-min.js",
- "requires": [
- "plugin"
- ],
- "skinnable": true
- }
- },
"requires": [
"scrollview-base",
"scrollview-scrollbars"
]
},
- "slider": {
- "submodules": {
- "clickable-rail": {
- "requires": [
- "slider-base"
- ]
- },
- "range-slider": {
- "requires": [
- "slider-base",
- "slider-value-range",
- "clickable-rail"
- ]
- },
- "slider-base": {
- "requires": [
- "widget",
- "dd-constrain",
- "substitute"
- ],
- "skinnable": true
- },
- "slider-value-range": {
- "requires": [
- "slider-base"
- ]
- }
+ "scrollview-base": {
+ "requires": [
+ "widget",
+ "event-gestures",
+ "transition"
+ ],
+ "skinnable": true
+ },
+ "scrollview-base-ie": {
+ "condition": {
+ "name": "scrollview-base-ie",
+ "trigger": "scrollview-base",
+ "ua": "ie"
+ },
+ "requires": [
+ "scrollview-base"
+ ]
+ },
+ "scrollview-paginator": {
+ "requires": [
+ "plugin"
+ ]
+ },
+ "scrollview-scrollbars": {
+ "requires": [
+ "classnamemanager",
+ "transition",
+ "plugin"
+ ],
+ "skinnable": true
+ },
+ "selection": {
+ "requires": [
+ "node"
+ ]
+ },
+ "selector": {
+ "requires": [
+ "selector-native"
+ ]
+ },
+ "selector-css2": {
+ "condition": {
+ "name": "selector-css2",
+ "test": function (Y) {
+ var DOCUMENT = Y.config.doc,
+ ret = DOCUMENT && !('querySelectorAll' in DOCUMENT);
+
+ return ret;
+},
+ "trigger": "selector"
},
+ "requires": [
+ "selector-native"
+ ]
+ },
+ "selector-css3": {
+ "requires": [
+ "selector-native",
+ "selector-css2"
+ ]
+ },
+ "selector-native": {
+ "requires": [
+ "dom-core"
+ ]
+ },
+ "shim-plugin": {
+ "requires": [
+ "node-style",
+ "node-pluginhost"
+ ]
+ },
+ "slider": {
"use": [
"slider-base",
"slider-value-range",
@@ -8473,21 +8602,32 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"range-slider"
]
},
+ "slider-base": {
+ "requires": [
+ "widget",
+ "dd-constrain",
+ "substitute"
+ ],
+ "skinnable": true
+ },
+ "slider-value-range": {
+ "requires": [
+ "slider-base"
+ ]
+ },
"sortable": {
- "plugins": {
- "sortable-scroll": {
- "requires": [
- "dd-scroll",
- "sortable"
- ]
- }
- },
"requires": [
"dd-delegate",
"dd-drop-plugin",
"dd-proxy"
]
},
+ "sortable-scroll": {
+ "requires": [
+ "dd-scroll",
+ "sortable"
+ ]
+ },
"stylesheet": {},
"substitute": {
"optional": [
@@ -8503,20 +8643,6 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
},
"swfdetect": {},
"tabview": {
- "plugins": {
- "tabview-base": {
- "requires": [
- "node-event-delegate",
- "classnamemanager",
- "skin-sam-tabview"
- ]
- },
- "tabview-plugin": {
- "requires": [
- "tabview-base"
- ]
- }
- },
"requires": [
"widget",
"widget-parent",
@@ -8527,6 +8653,18 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
],
"skinnable": true
},
+ "tabview-base": {
+ "requires": [
+ "node-event-delegate",
+ "classnamemanager",
+ "skin-sam-tabview"
+ ]
+ },
+ "tabview-plugin": {
+ "requires": [
+ "tabview-base"
+ ]
+ },
"test": {
"requires": [
"event-simulate",
@@ -8537,46 +8675,42 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"skinnable": true
},
"text": {
- "submodules": {
- "text-accentfold": {
- "requires": [
- "array-extras",
- "text-data-accentfold"
- ]
- },
- "text-data-accentfold": {},
- "text-data-wordbreak": {},
- "text-wordbreak": {
- "requires": [
- "array-extras",
- "text-data-wordbreak"
- ]
- }
- },
"use": [
"text-accentfold",
"text-wordbreak"
]
},
+ "text-accentfold": {
+ "requires": [
+ "array-extras",
+ "text-data-accentfold"
+ ]
+ },
+ "text-data-accentfold": {},
+ "text-data-wordbreak": {},
+ "text-wordbreak": {
+ "requires": [
+ "array-extras",
+ "text-data-wordbreak"
+ ]
+ },
"transition": {
- "submodules": {
- "transition-native": {
- "requires": [
- "node-base"
- ]
- },
- "transition-timer": {
- "requires": [
- "transition-native",
- "node-style"
- ]
- }
- },
"use": [
"transition-native",
"transition-timer"
]
},
+ "transition-native": {
+ "requires": [
+ "node-base"
+ ]
+ },
+ "transition-timer": {
+ "requires": [
+ "transition-native",
+ "node-style"
+ ]
+ },
"uploader": {
"requires": [
"event-custom",
@@ -8585,92 +8719,14 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"swf"
]
},
+ "view": {
+ "requires": [
+ "base-build",
+ "node-event-delegate"
+ ]
+ },
"widget": {
- "plugins": {
- "widget-base-ie": {
- "condition": {
- "name": "widget-base-ie",
- "trigger": "widget-base",
- "ua": "ie"
- },
- "requires": [
- "widget-base"
- ]
- },
- "widget-child": {
- "requires": [
- "base-build",
- "widget"
- ]
- },
- "widget-parent": {
- "requires": [
- "base-build",
- "arraylist",
- "widget"
- ]
- },
- "widget-position": {
- "requires": [
- "base-build",
- "node-screen",
- "widget"
- ]
- },
- "widget-position-align": {
- "requires": [
- "widget-position"
- ]
- },
- "widget-position-constrain": {
- "requires": [
- "widget-position"
- ]
- },
- "widget-stack": {
- "requires": [
- "base-build",
- "widget"
- ],
- "skinnable": true
- },
- "widget-stdmod": {
- "requires": [
- "base-build",
- "widget"
- ]
- }
- },
"skinnable": true,
- "submodules": {
- "widget-base": {
- "requires": [
- "attribute",
- "event-focus",
- "base-base",
- "base-pluginhost",
- "node-base",
- "node-style",
- "classnamemanager"
- ]
- },
- "widget-htmlparser": {
- "requires": [
- "widget-base"
- ]
- },
- "widget-skin": {
- "requires": [
- "widget-base"
- ]
- },
- "widget-uievents": {
- "requires": [
- "widget-base",
- "node-event-delegate"
- ]
- }
- },
"use": [
"widget-base",
"widget-htmlparser",
@@ -8685,12 +8741,100 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"widget"
]
},
+ "widget-base": {
+ "requires": [
+ "attribute",
+ "event-focus",
+ "base-base",
+ "base-pluginhost",
+ "node-base",
+ "node-style",
+ "classnamemanager"
+ ]
+ },
+ "widget-base-ie": {
+ "condition": {
+ "name": "widget-base-ie",
+ "trigger": "widget-base",
+ "ua": "ie"
+ },
+ "requires": [
+ "widget-base"
+ ]
+ },
+ "widget-child": {
+ "requires": [
+ "base-build",
+ "widget"
+ ]
+ },
+ "widget-htmlparser": {
+ "requires": [
+ "widget-base"
+ ]
+ },
"widget-locale": {
- "path": "widget/widget-locale-min.js",
"requires": [
"widget-base"
]
},
+ "widget-modality": {
+ "requires": [
+ "widget",
+ "plugin",
+ "gallery-outside-events",
+ "base-build"
+ ],
+ "skinnable": false
+ },
+ "widget-parent": {
+ "requires": [
+ "base-build",
+ "arraylist",
+ "widget"
+ ]
+ },
+ "widget-position": {
+ "requires": [
+ "base-build",
+ "node-screen",
+ "widget"
+ ]
+ },
+ "widget-position-align": {
+ "requires": [
+ "widget-position"
+ ]
+ },
+ "widget-position-constrain": {
+ "requires": [
+ "widget-position"
+ ]
+ },
+ "widget-skin": {
+ "requires": [
+ "widget-base"
+ ]
+ },
+ "widget-stack": {
+ "requires": [
+ "base-build",
+ "widget"
+ ],
+ "skinnable": true
+ },
+ "widget-stdmod": {
+ "requires": [
+ "base-build",
+ "widget"
+ ]
+ },
+ "widget-uievents": {
+ "requires": [
+ "widget-base",
+ "node-event-delegate"
+ ]
+ },
"yql": {
"requires": [
"jsonp",
@@ -8698,51 +8842,6 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
]
},
"yui": {
- "submodules": {
- "features": {
- "requires": [
- "yui-base"
- ]
- },
- "get": {
- "requires": [
- "yui-base"
- ]
- },
- "intl-base": {
- "requires": [
- "yui-base"
- ]
- },
- "rls": {
- "requires": [
- "get",
- "features"
- ]
- },
- "yui-base": {},
- "yui-later": {
- "requires": [
- "yui-base"
- ]
- },
- "yui-log": {
- "requires": [
- "yui-base"
- ]
- },
- "yui-rls": {
- "use": [
- "yui-base",
- "get",
- "features",
- "intl-base",
- "rls",
- "yui-log",
- "yui-later"
- ]
- }
- },
"use": [
"yui-base",
"get",
@@ -8755,13 +8854,35 @@ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || {
"loader-yui3"
]
},
+ "yui-base": {},
+ "yui-later": {
+ "requires": [
+ "yui-base"
+ ]
+ },
+ "yui-log": {
+ "requires": [
+ "yui-base"
+ ]
+ },
+ "yui-rls": {
+ "use": [
+ "yui-base",
+ "get",
+ "features",
+ "intl-base",
+ "rls",
+ "yui-log",
+ "yui-later"
+ ]
+ },
"yui-throttle": {
"requires": [
"yui-base"
]
}
};
-YUI.Env[Y.version].md5 = '8cddfeca586b80c7fb7245817b42fa87';
+YUI.Env[Y.version].md5 = '8deea7d26f0f85ddcacf3aa4da9bfed6';
}, '@VERSION@' ,{requires:['loader-base']});
@@ -8772,379 +8893,397 @@ YUI.add('yui', function(Y){}, '@VERSION@' ,{use:['yui-base','get','features','in
YUI.add('oop', function(Y) {
/**
- * Supplies object inheritance and manipulation utilities. This adds
- * additional functionaity to what is provided in yui-base, and the
- * methods are applied directly to the YUI instance. This module
- * is required for most YUI components.
- * @module oop
- */
+Supplies object inheritance and manipulation utilities.
+
+This adds additional functionaity to what is provided in `yui-base`, and the
+methods are applied directly to the YUI instance. This module is required for
+most YUI components.
+
+@module oop
+**/
/**
- * The following methods are added to the YUI instance
- * @class YUI~oop
- */
+These methods are added to the YUI instance by the `oop` module.
- var L = Y.Lang,
- A = Y.Array,
- OP = Object.prototype,
- CLONE_MARKER = '_~yuim~_',
- EACH = 'each',
- SOME = 'some',
+@class YUI~oop
+**/
- dispatch = function(o, f, c, proto, action) {
- if (o && o[action] && o !== Y) {
- return o[action].call(o, f, c);
- } else {
- switch (A.test(o)) {
- case 1:
- return A[action](o, f, c);
- case 2:
- return A[action](Y.Array(o, 0, true), f, c);
- default:
- return Y.Object[action](o, f, c, proto);
- }
- }
- };
+var L = Y.Lang,
+ A = Y.Array,
+ OP = Object.prototype,
+ CLONE_MARKER = '_~yuim~_',
+
+ hasOwn = OP.hasOwnProperty,
+ toString = OP.toString;
+function dispatch(o, f, c, proto, action) {
+ if (o && o[action] && o !== Y) {
+ return o[action].call(o, f, c);
+ } else {
+ switch (A.test(o)) {
+ case 1:
+ return A[action](o, f, c);
+ case 2:
+ return A[action](Y.Array(o, 0, true), f, c);
+ default:
+ return Y.Object[action](o, f, c, proto);
+ }
+ }
+}
/**
- * Applies prototype properties from the supplier to the receiver.
- * The receiver can be a constructor or an instance.
- * @method augment
- * @param {function} r the object to receive the augmentation.
- * @param {function} s the object that supplies the properties to augment.
- * @param {boolean} ov if true, properties already on the receiver
- * will be overwritten if found on the supplier.
- * @param {string[]} wl a whitelist. If supplied, only properties in
- * this list will be applied to the receiver.
- * @param {Array | Any} args arg or arguments to apply to the supplier
- * constructor when initializing.
- * @return {object} the augmented object.
- *
- * @todo constructor optional?
- * @todo understanding what an instance is augmented with
- * @todo best practices for overriding sequestered methods.
- */
- Y.augment = function(r, s, ov, wl, args) {
- var sProto = s.prototype,
- newProto = null,
- construct = s,
- a = (args) ? Y.Array(args) : [],
- rProto = r.prototype,
- target = rProto || r,
- applyConstructor = false,
- sequestered, replacements;
-
- // working on a class, so apply constructor infrastructure
- if (rProto && construct) {
- sequestered = {};
+ Augments the _receiver_ with prototype properties from the _supplier_. The
+ receiver may be a constructor function or an object. The supplier must be a
+ constructor function.
+
+ If the _receiver_ is an object, then the _supplier_ constructor will be called
+ immediately after _receiver_ is augmented, with _receiver_ as the `this` object.
+
+ If the _receiver_ is a constructor function, then all prototype methods of
+ _supplier_ that are copied to _receiver_ will be sequestered, and the
+ _supplier_ constructor will not be called immediately. The first time any
+ sequestered method is called on the _receiver_'s prototype, all sequestered
+ methods will be immediately copied to the _receiver_'s prototype, the
+ _supplier_'s constructor will be executed, and finally the newly unsequestered
+ method that was called will be executed.
+
+ This sequestering logic sounds like a bunch of complicated voodoo, but it makes
+ it cheap to perform frequent augmentation by ensuring that suppliers'
+ constructors are only called if a supplied method is actually used. If none of
+ the supplied methods is ever used, then there's no need to take the performance
+ hit of calling the _supplier_'s constructor.
+
+ @method augment
+ @param {Function|Object} receiver Object or function to be augmented.
+ @param {Function} supplier Function that supplies the prototype properties with
+ which to augment the _receiver_.
+ @param {Boolean} [overwrite=false] If `true`, properties already on the receiver
+ will be overwritten if found on the supplier's prototype.
+ @param {String[]} [whitelist] An array of property names. If specified,
+ only the whitelisted prototype properties will be applied to the receiver, and
+ all others will be ignored.
+ @param {Array|any} [args] Argument or array of arguments to pass to the
+ supplier's constructor when initializing.
+ @return {Function} Augmented object.
+ **/
+ Y.augment = function (receiver, supplier, overwrite, whitelist, args) {
+ var rProto = receiver.prototype,
+ sequester = rProto && supplier,
+ sProto = supplier.prototype,
+ to = rProto || receiver,
+
+ copy,
+ newPrototype,
+ replacements,
+ sequestered,
+ unsequester;
+
+ args = args ? Y.Array(args) : [];
+
+ if (sequester) {
+ newPrototype = {};
replacements = {};
- newProto = {};
-
- // sequester all of the functions in the supplier and replace with
- // one that will restore all of them.
- Y.Object.each(sProto, function(v, k) {
- replacements[k] = function() {
-
- // Y.log('sequestered function "' + k +
- // '" executed. Initializing EventTarget');
- // overwrite the prototype with all of the sequestered functions,
- // but only if it hasn't been overridden
- for (var i in sequestered) {
- if (sequestered.hasOwnProperty(i) &&
- (this[i] === replacements[i])) {
- // Y.log('... restoring ' + k);
- this[i] = sequestered[i];
- }
- }
+ sequestered = {};
- // apply the constructor
- construct.apply(this, a);
+ copy = function (value, key) {
+ if (overwrite || !(key in rProto)) {
+ if (toString.call(value) === '[object Function]') {
+ sequestered[key] = value;
- // apply the original sequestered function
- return sequestered[k].apply(this, arguments);
- };
+ newPrototype[key] = replacements[key] = function () {
+ return unsequester(this, value, arguments);
+ };
+ } else {
+ newPrototype[key] = value;
+ }
+ }
+ };
- if ((!wl || (k in wl)) && (ov || !(k in this))) {
- // Y.log('augment: ' + k);
- if (L.isFunction(v)) {
- // sequester the function
- sequestered[k] = v;
+ unsequester = function (instance, fn, fnArgs) {
+ // Unsequester all sequestered functions.
+ for (var key in sequestered) {
+ if (hasOwn.call(sequestered, key)
+ && instance[key] === replacements[key]) {
-// replace the sequestered function with a function that will
-// restore all sequestered functions and exectue the constructor.
- this[k] = replacements[k];
- } else {
- // Y.log('augment() applying non-function: ' + k);
- this[k] = v;
+ instance[key] = sequestered[key];
}
}
- }, newProto, true);
+ // Execute the supplier constructor.
+ supplier.apply(instance, args);
- // augmenting an instance, so apply the constructor immediately
- } else {
- applyConstructor = true;
+ // Finally, execute the original sequestered function.
+ return fn.apply(instance, fnArgs);
+ };
+
+ if (whitelist) {
+ Y.Array.each(whitelist, function (name) {
+ if (name in sProto) {
+ copy(sProto[name], name);
+ }
+ });
+ } else {
+ Y.Object.each(sProto, copy, null, true);
+ }
}
- Y.mix(target, newProto || sProto, ov, wl);
+ Y.mix(to, newPrototype || sProto, overwrite, whitelist);
- if (applyConstructor) {
- s.apply(target, a);
+ if (!sequester) {
+ supplier.apply(to, args);
}
- return r;
+ return receiver;
};
- /**
- * Applies object properties from the supplier to the receiver. If
- * the target has the property, and the property is an object, the target
- * object will be augmented with the supplier's value. If the property
- * is an array, the suppliers value will be appended to the target.
- * @method aggregate
- * @param {function} r the object to receive the augmentation.
- * @param {function} s the object that supplies the properties to augment.
- * @param {boolean} ov if true, properties already on the receiver
- * will be overwritten if found on the supplier.
- * @param {string[]} wl a whitelist. If supplied, only properties in
- * this list will be applied to the receiver.
- * @return {object} the extended object.
- */
- Y.aggregate = function(r, s, ov, wl) {
- return Y.mix(r, s, ov, wl, 0, true);
- };
+/**
+ * Applies object properties from the supplier to the receiver. If
+ * the target has the property, and the property is an object, the target
+ * object will be augmented with the supplier's value. If the property
+ * is an array, the suppliers value will be appended to the target.
+ * @method aggregate
+ * @param {function} r the object to receive the augmentation.
+ * @param {function} s the object that supplies the properties to augment.
+ * @param {boolean} ov if true, properties already on the receiver
+ * will be overwritten if found on the supplier.
+ * @param {string[]} wl a whitelist. If supplied, only properties in
+ * this list will be applied to the receiver.
+ * @return {object} the extended object.
+ */
+Y.aggregate = function(r, s, ov, wl) {
+ return Y.mix(r, s, ov, wl, 0, true);
+};
- /**
- * Utility to set up the prototype, constructor and superclass properties to
- * support an inheritance strategy that can chain constructors and methods.
- * Static members will not be inherited.
- *
- * @method extend
- * @param {function} r the object to modify.
- * @param {function} s the object to inherit.
- * @param {object} px prototype properties to add/override.
- * @param {object} sx static properties to add/override.
- * @return {object} the extended object.
- */
- Y.extend = function(r, s, px, sx) {
- if (!s || !r) {
- Y.error('extend failed, verify dependencies');
- }
+/**
+ * Utility to set up the prototype, constructor and superclass properties to
+ * support an inheritance strategy that can chain constructors and methods.
+ * Static members will not be inherited.
+ *
+ * @method extend
+ * @param {function} r the object to modify.
+ * @param {function} s the object to inherit.
+ * @param {object} px prototype properties to add/override.
+ * @param {object} sx static properties to add/override.
+ * @return {object} the extended object.
+ */
+Y.extend = function(r, s, px, sx) {
+ if (!s || !r) {
+ Y.error('extend failed, verify dependencies');
+ }
- var sp = s.prototype, rp = Y.Object(sp);
- r.prototype = rp;
+ var sp = s.prototype, rp = Y.Object(sp);
+ r.prototype = rp;
- rp.constructor = r;
- r.superclass = sp;
+ rp.constructor = r;
+ r.superclass = sp;
- // assign constructor property
- if (s != Object && sp.constructor == OP.constructor) {
- sp.constructor = s;
- }
+ // assign constructor property
+ if (s != Object && sp.constructor == OP.constructor) {
+ sp.constructor = s;
+ }
- // add prototype overrides
- if (px) {
- Y.mix(rp, px, true);
- }
+ // add prototype overrides
+ if (px) {
+ Y.mix(rp, px, true);
+ }
- // add object overrides
- if (sx) {
- Y.mix(r, sx, true);
- }
+ // add object overrides
+ if (sx) {
+ Y.mix(r, sx, true);
+ }
- return r;
- };
+ return r;
+};
- /**
- * Executes the supplied function for each item in
- * a collection. Supports arrays, objects, and
- * Y.NodeLists
- * @method each
- * @param {object} o the object to iterate.
- * @param {function} f the function to execute. This function
- * receives the value, key, and object as parameters.
- * @param {object} c the execution context for the function.
- * @param {boolean} proto if true, prototype properties are
- * iterated on objects.
- * @return {YUI} the YUI instance.
- */
- Y.each = function(o, f, c, proto) {
- return dispatch(o, f, c, proto, EACH);
- };
+/**
+ * Executes the supplied function for each item in
+ * a collection. Supports arrays, objects, and
+ * Y.NodeLists
+ * @method each
+ * @param {object} o the object to iterate.
+ * @param {function} f the function to execute. This function
+ * receives the value, key, and object as parameters.
+ * @param {object} c the execution context for the function.
+ * @param {boolean} proto if true, prototype properties are
+ * iterated on objects.
+ * @return {YUI} the YUI instance.
+ */
+Y.each = function(o, f, c, proto) {
+ return dispatch(o, f, c, proto, 'each');
+};
- /**
- * Executes the supplied function for each item in
- * a collection. The operation stops if the function
- * returns true. Supports arrays, objects, and
- * Y.NodeLists.
- * @method some
- * @param {object} o the object to iterate.
- * @param {function} f the function to execute. This function
- * receives the value, key, and object as parameters.
- * @param {object} c the execution context for the function.
- * @param {boolean} proto if true, prototype properties are
- * iterated on objects.
- * @return {boolean} true if the function ever returns true,
- * false otherwise.
- */
- Y.some = function(o, f, c, proto) {
- return dispatch(o, f, c, proto, SOME);
- };
+/**
+ * Executes the supplied function for each item in
+ * a collection. The operation stops if the function
+ * returns true. Supports arrays, objects, and
+ * Y.NodeLists.
+ * @method some
+ * @param {object} o the object to iterate.
+ * @param {function} f the function to execute. This function
+ * receives the value, key, and object as parameters.
+ * @param {object} c the execution context for the function.
+ * @param {boolean} proto if true, prototype properties are
+ * iterated on objects.
+ * @return {boolean} true if the function ever returns true,
+ * false otherwise.
+ */
+Y.some = function(o, f, c, proto) {
+ return dispatch(o, f, c, proto, 'some');
+};
- /**
- * Deep obj/array copy. Function clones are actually
- * wrappers around the original function.
- * Array-like objects are treated as arrays.
- * Primitives are returned untouched. Optionally, a
- * function can be provided to handle other data types,
- * filter keys, validate values, etc.
- *
- * @method clone
- * @param {object} o what to clone.
- * @param {boolean} safe if true, objects will not have prototype
- * items from the source. If false, they will. In this case, the
- * original is initially protected, but the clone is not completely
- * immune from changes to the source object prototype. Also, cloned
- * prototype items that are deleted from the clone will result
- * in the value of the source prototype being exposed. If operating
- * on a non-safe clone, items should be nulled out rather than deleted.
- * @param {function} f optional function to apply to each item in a
- * collection; it will be executed prior to applying the value to
- * the new object. Return false to prevent the copy.
- * @param {object} c optional execution context for f.
- * @param {object} owner Owner object passed when clone is iterating
- * an object. Used to set up context for cloned functions.
- * @param {object} cloned hash of previously cloned objects to avoid
- * multiple clones.
- * @return {Array|Object} the cloned object.
- */
- Y.clone = function(o, safe, f, c, owner, cloned) {
-
- if (!L.isObject(o)) {
- return o;
- }
+/**
+ * Deep obj/array copy. Function clones are actually
+ * wrappers around the original function.
+ * Array-like objects are treated as arrays.
+ * Primitives are returned untouched. Optionally, a
+ * function can be provided to handle other data types,
+ * filter keys, validate values, etc.
+ *
+ * @method clone
+ * @param {object} o what to clone.
+ * @param {boolean} safe if true, objects will not have prototype
+ * items from the source. If false, they will. In this case, the
+ * original is initially protected, but the clone is not completely
+ * immune from changes to the source object prototype. Also, cloned
+ * prototype items that are deleted from the clone will result
+ * in the value of the source prototype being exposed. If operating
+ * on a non-safe clone, items should be nulled out rather than deleted.
+ * @param {function} f optional function to apply to each item in a
+ * collection; it will be executed prior to applying the value to
+ * the new object. Return false to prevent the copy.
+ * @param {object} c optional execution context for f.
+ * @param {object} owner Owner object passed when clone is iterating
+ * an object. Used to set up context for cloned functions.
+ * @param {object} cloned hash of previously cloned objects to avoid
+ * multiple clones.
+ * @return {Array|Object} the cloned object.
+ */
+Y.clone = function(o, safe, f, c, owner, cloned) {
- // @todo cloning YUI instances doesn't currently work
- if (Y.instanceOf(o, YUI)) {
- return o;
- }
+ if (!L.isObject(o)) {
+ return o;
+ }
- var o2, marked = cloned || {}, stamp,
- yeach = Y.each;
+ // @todo cloning YUI instances doesn't currently work
+ if (Y.instanceOf(o, YUI)) {
+ return o;
+ }
- switch (L.type(o)) {
- case 'date':
- return new Date(o);
- case 'regexp':
- // if we do this we need to set the flags too
- // return new RegExp(o.source);
- return o;
- case 'function':
- // o2 = Y.bind(o, owner);
- // break;
- return o;
- case 'array':
- o2 = [];
- break;
- default:
+ var o2, marked = cloned || {}, stamp,
+ yeach = Y.each;
- // #2528250 only one clone of a given object should be created.
- if (o[CLONE_MARKER]) {
- return marked[o[CLONE_MARKER]];
- }
+ switch (L.type(o)) {
+ case 'date':
+ return new Date(o);
+ case 'regexp':
+ // if we do this we need to set the flags too
+ // return new RegExp(o.source);
+ return o;
+ case 'function':
+ // o2 = Y.bind(o, owner);
+ // break;
+ return o;
+ case 'array':
+ o2 = [];
+ break;
+ default:
- stamp = Y.guid();
+ // #2528250 only one clone of a given object should be created.
+ if (o[CLONE_MARKER]) {
+ return marked[o[CLONE_MARKER]];
+ }
- o2 = (safe) ? {} : Y.Object(o);
+ stamp = Y.guid();
- o[CLONE_MARKER] = stamp;
- marked[stamp] = o;
- }
+ o2 = (safe) ? {} : Y.Object(o);
+
+ o[CLONE_MARKER] = stamp;
+ marked[stamp] = o;
+ }
- // #2528250 don't try to clone element properties
- if (!o.addEventListener && !o.attachEvent) {
- yeach(o, function(v, k) {
+ // #2528250 don't try to clone element properties
+ if (!o.addEventListener && !o.attachEvent) {
+ yeach(o, function(v, k) {
if ((k || k === 0) && (!f || (f.call(c || this, v, k, this, o) !== false))) {
- if (k !== CLONE_MARKER) {
- if (k == 'prototype') {
- // skip the prototype
- // } else if (o[k] === o) {
- // this[k] = this;
- } else {
- this[k] =
- Y.clone(v, safe, f, c, owner || o, marked);
- }
+ if (k !== CLONE_MARKER) {
+ if (k == 'prototype') {
+ // skip the prototype
+ // } else if (o[k] === o) {
+ // this[k] = this;
+ } else {
+ this[k] =
+ Y.clone(v, safe, f, c, owner || o, marked);
}
}
- }, o2);
- }
+ }
+ }, o2);
+ }
- if (!cloned) {
- Y.Object.each(marked, function(v, k) {
- if (v[CLONE_MARKER]) {
- try {
- delete v[CLONE_MARKER];
- } catch (e) {
- v[CLONE_MARKER] = null;
- }
+ if (!cloned) {
+ Y.Object.each(marked, function(v, k) {
+ if (v[CLONE_MARKER]) {
+ try {
+ delete v[CLONE_MARKER];
+ } catch (e) {
+ v[CLONE_MARKER] = null;
}
- }, this);
- marked = null;
- }
+ }
+ }, this);
+ marked = null;
+ }
- return o2;
- };
+ return o2;
+};
- /**
- * Returns a function that will execute the supplied function in the
- * supplied object's context, optionally adding any additional
- * supplied parameters to the beginning of the arguments collection the
- * supplied to the function.
- *
- * @method bind
- * @param {Function|String} f the function to bind, or a function name
- * to execute on the context object.
- * @param {object} c the execution context.
- * @param {any} args* 0..n arguments to include before the arguments the
- * function is executed with.
- * @return {function} the wrapped function.
- */
- Y.bind = function(f, c) {
- var xargs = arguments.length > 2 ?
- Y.Array(arguments, 2, true) : null;
- return function() {
- var fn = L.isString(f) ? c[f] : f,
- args = (xargs) ?
- xargs.concat(Y.Array(arguments, 0, true)) : arguments;
- return fn.apply(c || fn, args);
- };
+/**
+ * Returns a function that will execute the supplied function in the
+ * supplied object's context, optionally adding any additional
+ * supplied parameters to the beginning of the arguments collection the
+ * supplied to the function.
+ *
+ * @method bind
+ * @param {Function|String} f the function to bind, or a function name
+ * to execute on the context object.
+ * @param {object} c the execution context.
+ * @param {any} args* 0..n arguments to include before the arguments the
+ * function is executed with.
+ * @return {function} the wrapped function.
+ */
+Y.bind = function(f, c) {
+ var xargs = arguments.length > 2 ?
+ Y.Array(arguments, 2, true) : null;
+ return function() {
+ var fn = L.isString(f) ? c[f] : f,
+ args = (xargs) ?
+ xargs.concat(Y.Array(arguments, 0, true)) : arguments;
+ return fn.apply(c || fn, args);
};
+};
- /**
- * Returns a function that will execute the supplied function in the
- * supplied object's context, optionally adding any additional
- * supplied parameters to the end of the arguments the function
- * is executed with.
- *
- * @method rbind
- * @param {Function|String} f the function to bind, or a function name
- * to execute on the context object.
- * @param {object} c the execution context.
- * @param {any} args* 0..n arguments to append to the end of
- * arguments collection supplied to the function.
- * @return {function} the wrapped function.
- */
- Y.rbind = function(f, c) {
- var xargs = arguments.length > 2 ? Y.Array(arguments, 2, true) : null;
- return function() {
- var fn = L.isString(f) ? c[f] : f,
- args = (xargs) ?
- Y.Array(arguments, 0, true).concat(xargs) : arguments;
- return fn.apply(c || fn, args);
- };
+/**
+ * Returns a function that will execute the supplied function in the
+ * supplied object's context, optionally adding any additional
+ * supplied parameters to the end of the arguments the function
+ * is executed with.
+ *
+ * @method rbind
+ * @param {Function|String} f the function to bind, or a function name
+ * to execute on the context object.
+ * @param {object} c the execution context.
+ * @param {any} args* 0..n arguments to append to the end of
+ * arguments collection supplied to the function.
+ * @return {function} the wrapped function.
+ */
+Y.rbind = function(f, c) {
+ var xargs = arguments.length > 2 ? Y.Array(arguments, 2, true) : null;
+ return function() {
+ var fn = L.isString(f) ? c[f] : f,
+ args = (xargs) ?
+ Y.Array(arguments, 0, true).concat(xargs) : arguments;
+ return fn.apply(c || fn, args);
};
-
+};
}, '@VERSION@' ,{requires:['yui-base']});
@@ -17901,7 +18040,7 @@ Y.Node.importMethod(Y.DOM, [
*/
Y.Node.ATTRS.region = {
getter: function() {
- var node = Y.Node.getDOMNode(this),
+ var node = this.getDOMNode(),
region;
if (node && !node.tagName) {
@@ -17909,7 +18048,7 @@ Y.Node.ATTRS.region = {
node = node.documentElement;
}
}
- if (node.alert) {
+ if (Y.DOM.isWindow(node)) {
region = Y.DOM.viewportRegion(node);
} else {
region = Y.DOM.region(node);
@@ -18076,7 +18215,7 @@ Y.Node.prototype.delegate = function(type) {
}, '@VERSION@' ,{requires:['node-base', 'event-delegate']});
-YUI.add('node', function(Y){}, '@VERSION@' ,{use:['node-base', 'node-style', 'node-screen', 'node-pluginhost', 'node-event-delegate'], skinnable:false});
+YUI.add('node', function(Y){}, '@VERSION@' ,{skinnable:false, use:['node-base', 'node-style', 'node-screen', 'node-pluginhost', 'node-event-delegate']});
YUI.add('event-delegate', function(Y) {
diff --git a/build/simpleyui/simpleyui-min.js b/build/simpleyui/simpleyui-min.js
index f8ed16ffe58..12840da107f 100644
--- a/build/simpleyui/simpleyui-min.js
+++ b/build/simpleyui/simpleyui-min.js
@@ -1,25 +1,27 @@
-if(typeof YUI!="undefined"){YUI._YUI=YUI;}var YUI=function(){var c=0,f=this,b=arguments,a=b.length,e=function(h,g){return(h&&h.hasOwnProperty&&(h instanceof g));},d=(typeof YUI_config!=="undefined")&&YUI_config;if(!(e(f,YUI))){f=new YUI();}else{f._init();if(YUI.GlobalConfig){f.applyConfig(YUI.GlobalConfig);}if(d){f.applyConfig(d);}if(!a){f._setup();}}if(a){for(;c-1){r="3.3.0";}q={applyConfig:function(E){E=E||l;var z,B,A=this.config,C=A.modules,y=A.groups,D=A.rls,x=this.Env._loader;for(B in E){if(E.hasOwnProperty(B)){z=E[B];if(C&&B=="modules"){p(C,z);}else{if(y&&B=="groups"){p(y,z);}else{if(D&&B=="rls"){p(D,z);}else{if(B=="win"){A[B]=z.contentWindow||z;A.doc=A[B].document;}else{if(B=="_yuid"){}else{A[B]=z;}}}}}}}if(x){x._config(E);}},_config:function(x){this.applyConfig(x);},_init:function(){var z,A=this,x=YUI.Env,y=A.Env,B;A.version=r;if(!y){A.Env={mods:{},versions:{},base:o,cdn:o+r+"/build/",_idx:0,_used:{},_attached:{},_missed:[],_yidx:0,_uidx:0,_guidp:"y",_loaded:{},getBase:x&&x.getBase||function(H,G){var C,D,F,I,E;D=(w&&w.getElementsByTagName("script"))||[];for(F=0;F=g.rollup);if(e){break;}}}}if(e){b[k]=true;d=true;this.getRequires(g);}}}}if(!d){break;}}};},"@VERSION@",{requires:["loader-base"]});YUI.add("loader-yui3",function(a){YUI.Env[a.version].modules=YUI.Env[a.version].modules||{"anim":{"submodules":{"anim-base":{"requires":["base-base","node-style"]},"anim-color":{"requires":["anim-base"]},"anim-curve":{"requires":["anim-xy"]},"anim-easing":{"requires":["anim-base"]},"anim-node-plugin":{"requires":["node-pluginhost","anim-base"]},"anim-scroll":{"requires":["anim-base"]},"anim-xy":{"requires":["anim-base","node-screen"]}},"use":["anim-base","anim-color","anim-curve","anim-easing","anim-node-plugin","anim-scroll","anim-xy"]},"app":{"submodules":{"controller":{"optional":["querystring-parse"],"requires":["array-extras","base-build","history","json"]},"model":{"requires":["base-build","escape","json-parse"]},"model-list":{"requires":["array-extras","array-invoke","arraylist","base-build","json-parse","model"]},"view":{"requires":["base-build","node-event-delegate"]}},"use":["controller","model","model-list","view"]},"arraysort":{"requires":["yui-base"]},"async-queue":{"requires":["event-custom"]},"attribute":{"submodules":{"attribute-base":{"requires":["event-custom"]},"attribute-complex":{"requires":["attribute-base"]}},"use":["attribute-base","attribute-complex"]},"autocomplete":{"submodules":{"autocomplete-base":{"optional":["autocomplete-sources"],"plugins":{"autocomplete-filters":{"path":"autocomplete/autocomplete-filters-min.js","requires":["array-extras","text-wordbreak"]},"autocomplete-filters-accentfold":{"path":"autocomplete/autocomplete-filters-accentfold-min.js","requires":["array-extras","text-accentfold","text-wordbreak"]},"autocomplete-highlighters":{"path":"autocomplete/autocomplete-highlighters-min.js","requires":["array-extras","highlight-base"]},"autocomplete-highlighters-accentfold":{"path":"autocomplete/autocomplete-highlighters-accentfold-min.js","requires":["array-extras","highlight-accentfold"]}},"requires":["array-extras","base-build","escape","event-valuechange","node-base"]},"autocomplete-list":{"after":["autocomplete-sources"],"lang":["en"],"plugins":{"autocomplete-list-keys":{"condition":{"name":"autocomplete-list-keys","test":function(b){return !(b.UA.ios||b.UA.android);},"trigger":"autocomplete-list"},"path":"autocomplete/autocomplete-list-keys-min.js","requires":["autocomplete-list","base-build"]},"autocomplete-plugin":{"path":"autocomplete/autocomplete-plugin-min.js","requires":["autocomplete-list","node-pluginhost"]}},"requires":["autocomplete-base","event-resize","selector-css3","shim-plugin","widget","widget-position","widget-position-align"],"skinnable":true},"autocomplete-sources":{"optional":["io-base","json-parse","jsonp","yql"],"requires":["autocomplete-base"]}},"use":["autocomplete-base","autocomplete-sources","autocomplete-list","autocomplete-plugin"]},"base":{"submodules":{"base-base":{"after":["attribute-complex"],"requires":["attribute-base"]},"base-build":{"requires":["base-base"]},"base-pluginhost":{"requires":["base-base","pluginhost"]}},"use":["base-base","base-pluginhost","base-build"]},"cache":{"submodules":{"cache-base":{"requires":["base"]},"cache-offline":{"requires":["cache-base","json"]},"cache-plugin":{"requires":["plugin","cache-base"]}},"use":["cache-base","cache-offline","cache-plugin"]},"charts":{"requires":["dom","datatype","event-custom","event-mouseenter","widget","widget-position","widget-stack"]},"classnamemanager":{"requires":["yui-base"]},"collection":{"submodules":{"array-extras":{},"array-invoke":{},"arraylist":{},"arraylist-add":{"requires":["arraylist"]},"arraylist-filter":{"requires":["arraylist"]}},"use":["array-extras","arraylist","arraylist-add","arraylist-filter","array-invoke"]},"compat":{"requires":["event-base","dom","dump","substitute"]},"console":{"lang":["en","es"],"plugins":{"console-filters":{"requires":["plugin","console"],"skinnable":true}},"requires":["yui-log","widget","substitute"],"skinnable":true},"cookie":{"requires":["yui-base"]},"cssbase":{"after":["cssreset","cssfonts","cssgrids","cssreset-context","cssfonts-context","cssgrids-context"],"path":"cssbase/base-min.css","type":"css"},"cssbase-context":{"after":["cssreset","cssfonts","cssgrids","cssreset-context","cssfonts-context","cssgrids-context"],"path":"cssbase/base-context-min.css","type":"css"},"cssfonts":{"path":"cssfonts/fonts-min.css","type":"css"},"cssfonts-context":{"path":"cssfonts/fonts-context-min.css","type":"css"},"cssgrids":{"optional":["cssreset","cssfonts"],"path":"cssgrids/grids-min.css","type":"css"},"cssgrids-context-deprecated":{"optional":["cssreset-context"],"path":"cssgrids-deprecated/grids-context-min.css","requires":["cssfonts-context"],"type":"css"},"cssgrids-deprecated":{"optional":["cssreset"],"path":"cssgrids-deprecated/grids-min.css","requires":["cssfonts"],"type":"css"},"cssreset":{"path":"cssreset/reset-min.css","type":"css"},"cssreset-context":{"path":"cssreset/reset-context-min.css","type":"css"},"dataschema":{"submodules":{"dataschema-array":{"requires":["dataschema-base"]},"dataschema-base":{"requires":["base"]},"dataschema-json":{"requires":["dataschema-base","json"]},"dataschema-text":{"requires":["dataschema-base"]},"dataschema-xml":{"requires":["dataschema-base"]}},"use":["dataschema-base","dataschema-json","dataschema-xml","dataschema-array","dataschema-text"]},"datasource":{"submodules":{"datasource-arrayschema":{"requires":["datasource-local","plugin","dataschema-array"]},"datasource-cache":{"requires":["datasource-local","plugin","cache-base"]},"datasource-function":{"requires":["datasource-local"]},"datasource-get":{"requires":["datasource-local","get"]},"datasource-io":{"requires":["datasource-local","io-base"]},"datasource-jsonschema":{"requires":["datasource-local","plugin","dataschema-json"]},"datasource-local":{"requires":["base"]},"datasource-polling":{"requires":["datasource-local"]},"datasource-textschema":{"requires":["datasource-local","plugin","dataschema-text"]},"datasource-xmlschema":{"requires":["datasource-local","plugin","dataschema-xml"]}},"use":["datasource-local","datasource-io","datasource-get","datasource-function","datasource-cache","datasource-jsonschema","datasource-xmlschema","datasource-arrayschema","datasource-textschema","datasource-polling"]},"datatable":{"submodules":{"datatable-base":{"requires":["recordset-base","widget","substitute","event-mouseenter"],"skinnable":true},"datatable-datasource":{"requires":["datatable-base","plugin","datasource-local"]},"datatable-scroll":{"requires":["datatable-base","plugin","stylesheet"]},"datatable-sort":{"lang":["en"],"requires":["datatable-base","plugin","recordset-sort"]}},"use":["datatable-base","datatable-datasource","datatable-sort","datatable-scroll"]},"datatype":{"submodules":{"datatype-date":{"lang":["ar","ar-JO","ca","ca-ES","da","da-DK","de","de-AT","de-DE","el","el-GR","en","en-AU","en-CA","en-GB","en-IE","en-IN","en-JO","en-MY","en-NZ","en-PH","en-SG","en-US","es","es-AR","es-BO","es-CL","es-CO","es-EC","es-ES","es-MX","es-PE","es-PY","es-US","es-UY","es-VE","fi","fi-FI","fr","fr-BE","fr-CA","fr-FR","hi","hi-IN","id","id-ID","it","it-IT","ja","ja-JP","ko","ko-KR","ms","ms-MY","nb","nb-NO","nl","nl-BE","nl-NL","pl","pl-PL","pt","pt-BR","ro","ro-RO","ru","ru-RU","sv","sv-SE","th","th-TH","tr","tr-TR","vi","vi-VN","zh-Hans","zh-Hans-CN","zh-Hant","zh-Hant-HK","zh-Hant-TW"],"submodules":{"datatype-date-format":{"path":"datatype/datatype-date-format-min.js"},"datatype-date-parse":{"path":"datatype/datatype-date-parse-min.js"}},"supersedes":["datatype-date-format"],"use2":["datatype-date-parse","datatype-date-format"]},"datatype-number":{"submodules":{"datatype-number-format":{"path":"datatype/datatype-number-format-min.js"},"datatype-number-parse":{"path":"datatype/datatype-number-parse-min.js"}},"use":["datatype-number-parse","datatype-number-format"]},"datatype-xml":{"submodules":{"datatype-xml-format":{"path":"datatype/datatype-xml-format-min.js"},"datatype-xml-parse":{"path":"datatype/datatype-xml-parse-min.js"}},"use":["datatype-xml-parse","datatype-xml-format"]}},"use":["datatype-number","datatype-date","datatype-xml"]},"dd":{"plugins":{"dd-drop-plugin":{"requires":["dd-drop"]},"dd-gestures":{"condition":{"name":"dd-gestures","test":function(b){return(b.config.win&&("ontouchstart" in b.config.win&&!b.UA.chrome));
-},"trigger":"dd-drag"},"requires":["dd-drag","event-synthetic","event-gestures"]},"dd-plugin":{"optional":["dd-constrain","dd-proxy"],"requires":["dd-drag"]}},"submodules":{"dd-constrain":{"requires":["dd-drag"]},"dd-ddm":{"requires":["dd-ddm-base","event-resize"]},"dd-ddm-base":{"requires":["node","base","yui-throttle","classnamemanager"]},"dd-ddm-drop":{"requires":["dd-ddm"]},"dd-delegate":{"requires":["dd-drag","dd-drop-plugin","event-mouseenter"]},"dd-drag":{"requires":["dd-ddm-base"]},"dd-drop":{"requires":["dd-drag","dd-ddm-drop"]},"dd-proxy":{"requires":["dd-drag"]},"dd-scroll":{"requires":["dd-drag"]}},"use":["dd-ddm-base","dd-ddm","dd-ddm-drop","dd-drag","dd-proxy","dd-constrain","dd-drop","dd-scroll","dd-delegate"]},"dial":{"lang":["en","es"],"requires":["widget","dd-drag","substitute","event-mouseenter","event-move","transition","intl"],"skinnable":true},"dom":{"plugins":{"dom-deprecated":{"requires":["dom-core"]},"dom-style-ie":{"condition":{"name":"dom-style-ie","test":function(h){var f=h.Features.test,g=h.Features.add,d=h.config.win,e=h.config.doc,b="documentElement",c=false;g("style","computedStyle",{test:function(){return d&&"getComputedStyle" in d;}});g("style","opacity",{test:function(){return e&&"opacity" in e[b].style;}});c=(!f("style","opacity")&&!f("style","computedStyle"));return c;},"trigger":"dom-style"},"requires":["dom-style"]},"selector-css2":{"condition":{"name":"selector-css2","test":function(d){var c=d.config.doc,b=c&&!("querySelectorAll" in c);return b;},"trigger":"selector"},"requires":["selector-native"]},"selector-css3":{"requires":["selector-native","selector-css2"]}},"submodules":{"dom-attrs":{"requires":["dom-core"]},"dom-base":{"requires":["dom-core","dom-attrs","dom-create","dom-class","dom-size"]},"dom-class":{"requires":["dom-core"]},"dom-core":{"requires":["oop","features"]},"dom-create":{"requires":["dom-core"]},"dom-screen":{"requires":["dom-core","dom-style"]},"dom-size":{"requires":["dom-core"]},"dom-style":{"requires":["dom-core"]},"selector":{"requires":["selector-native"]},"selector-native":{"requires":["dom-core"]}},"use":["dom-core","dom-base","dom-attrs","dom-create","dom-class","dom-size","dom-screen","dom-style","selector-native","selector"]},"dump":{},"editor":{"submodules":{"createlink-base":{"requires":["editor-base"]},"editor-base":{"requires":["base","frame","node","exec-command","selection"]},"editor-bidi":{"requires":["editor-base"]},"editor-br":{"requires":["editor-base"]},"editor-lists":{"requires":["editor-base"]},"editor-para":{"requires":["editor-base"]},"editor-tab":{"requires":["editor-base"]},"exec-command":{"requires":["frame"]},"frame":{"requires":["base","node","selector-css3","substitute","yui-throttle"]},"selection":{"requires":["node"]}},"use":["frame","selection","exec-command","editor-base","editor-para","editor-br","editor-bidi","editor-tab","createlink-base"]},"escape":{},"event":{"after":["node-base"],"plugins":{"event-base-ie":{"after":["event-base"],"condition":{"name":"event-base-ie","test":function(c){var b=c.config.doc&&c.config.doc.implementation;return(b&&(!b.hasFeature("Events","2.0")));},"trigger":"node-base"},"requires":["node-base"]},"event-touch":{"requires":["node-base"]}},"submodules":{"event-base":{"after":["node-base"],"requires":["event-custom-base"]},"event-delegate":{"requires":["node-base"]},"event-focus":{"requires":["event-synthetic"]},"event-hover":{"requires":["event-mouseenter"]},"event-key":{"requires":["event-synthetic"]},"event-mouseenter":{"requires":["event-synthetic"]},"event-mousewheel":{"requires":["node-base"]},"event-resize":{"requires":["node-base"]},"event-synthetic":{"requires":["node-base","event-custom-complex"]}},"use":["event-base","event-delegate","event-synthetic","event-mousewheel","event-mouseenter","event-key","event-focus","event-resize","event-hover"]},"event-custom":{"submodules":{"event-custom-base":{"requires":["oop"]},"event-custom-complex":{"requires":["event-custom-base"]}},"use":["event-custom-base","event-custom-complex"]},"event-gestures":{"submodules":{"event-flick":{"requires":["node-base","event-touch","event-synthetic"]},"event-move":{"requires":["node-base","event-touch","event-synthetic"]}},"use":["event-flick","event-move"]},"event-simulate":{"requires":["event-base"]},"event-valuechange":{"requires":["event-focus","event-synthetic"]},"highlight":{"submodules":{"highlight-accentfold":{"requires":["highlight-base","text-accentfold"]},"highlight-base":{"requires":["array-extras","escape","text-wordbreak"]}},"use":["highlight-base","highlight-accentfold"]},"history":{"plugins":{"history-hash-ie":{"condition":{"name":"history-hash-ie","test":function(c){var b=c.config.doc&&c.config.doc.documentMode;return c.UA.ie&&(!("onhashchange" in c.config.win)||!b||b<8);},"trigger":"history-hash"},"requires":["history-hash","node-base"]}},"submodules":{"history-base":{"requires":["event-custom-complex"]},"history-hash":{"after":["history-html5"],"requires":["event-synthetic","history-base","yui-later"]},"history-html5":{"optional":["json"],"requires":["event-base","history-base","node-base"]}},"use":["history-base","history-hash","history-hash-ie","history-html5"]},"imageloader":{"requires":["base-base","node-style","node-screen"]},"intl":{"requires":["intl-base","event-custom"]},"io":{"submodules":{"io-base":{"requires":["event-custom-base","querystring-stringify-simple"]},"io-form":{"requires":["io-base","node-base"]},"io-queue":{"requires":["io-base","queue-promote"]},"io-upload-iframe":{"requires":["io-base","node-base"]},"io-xdr":{"requires":["io-base","datatype-xml"]}},"use":["io-base","io-xdr","io-form","io-upload-iframe","io-queue"]},"json":{"submodules":{"json-parse":{},"json-stringify":{}},"use":["json-parse","json-stringify"]},"jsonp":{"plugins":{"jsonp-url":{"requires":["jsonp"]}},"requires":["get","oop"]},"loader":{"submodules":{"loader-base":{"requires":["get"]},"loader-rollup":{"requires":["loader-base"]},"loader-yui3":{"requires":["loader-base"]}},"use":["loader-base","loader-rollup","loader-yui3"]},"node":{"plugins":{"align-plugin":{"requires":["node-screen","node-pluginhost"]},"node-deprecated":{"requires":["node-base"]},"node-event-simulate":{"requires":["node-base","event-simulate"]},"node-load":{"requires":["node-base","io-base"]},"shim-plugin":{"requires":["node-style","node-pluginhost"]}},"submodules":{"node-base":{"requires":["dom-base","selector-css2","event-base"]},"node-event-delegate":{"requires":["node-base","event-delegate"]},"node-pluginhost":{"requires":["node-base","pluginhost"]},"node-screen":{"requires":["dom-screen","node-base"]},"node-style":{"requires":["dom-style","node-base"]}},"use":["node-base","node-event-delegate","node-pluginhost","node-screen","node-style"]},"node-flick":{"requires":["classnamemanager","transition","event-flick","plugin"],"skinnable":true},"node-focusmanager":{"requires":["attribute","node","plugin","node-event-simulate","event-key","event-focus"]},"node-menunav":{"requires":["node","classnamemanager","plugin","node-focusmanager"],"skinnable":true},"oop":{"requires":["yui-base"]},"overlay":{"requires":["widget","widget-stdmod","widget-position","widget-position-align","widget-stack","widget-position-constrain"],"skinnable":true},"plugin":{"plugins":{"pluginattr":{"path":"plugin/pluginattr-min.js","requires":["plugin"]}},"requires":["base-base"]},"pluginhost":{"submodules":{"pluginhost-base":{"requires":["yui-base"]},"pluginhost-config":{"requires":["pluginhost-base"]}},"use":["pluginhost-base","pluginhost-config"]},"profiler":{"requires":["yui-base"]},"querystring":{"submodules":{"querystring-parse":{"requires":["yui-base","array-extras"]},"querystring-stringify":{"requires":["yui-base"]}},"use":["querystring-parse","querystring-stringify"]},"querystring-parse-simple":{"path":"querystring/querystring-parse-simple-min.js","requires":["yui-base"]},"querystring-stringify-simple":{"path":"querystring/querystring-stringify-simple-min.js","requires":["yui-base"]},"queue-promote":{"requires":["yui-base"]},"recordset":{"submodules":{"recordset-base":{"requires":["base","arraylist"]},"recordset-filter":{"requires":["recordset-base","array-extras","plugin"]},"recordset-indexer":{"requires":["recordset-base","plugin"]},"recordset-sort":{"requires":["arraysort","recordset-base","plugin"]}},"use":["recordset-base","recordset-sort","recordset-filter","recordset-indexer"]},"resize":{"plugins":{"resize-plugin":{"optional":["resize-constrain"],"requires":["resize-base","plugin"]}},"submodules":{"resize-base":{"requires":["base","widget","substitute","event","oop","dd-drag","dd-delegate","dd-drop"],"skinnable":true},"resize-constrain":{"requires":["plugin","resize-base"]},"resize-proxy":{"requires":["plugin","resize-base"]}},"use":["resize-base","resize-proxy","resize-constrain"]},"scrollview":{"plugins":{"scrollview-base":{"path":"scrollview/scrollview-base-min.js","requires":["widget","event-gestures","transition"],"skinnable":true},"scrollview-base-ie":{"condition":{"name":"scrollview-base-ie","trigger":"scrollview-base","ua":"ie"},"requires":["scrollview-base"]},"scrollview-paginator":{"path":"scrollview/scrollview-paginator-min.js","requires":["plugin"]},"scrollview-scrollbars":{"path":"scrollview/scrollview-scrollbars-min.js","requires":["plugin"],"skinnable":true}},"requires":["scrollview-base","scrollview-scrollbars"]},"slider":{"submodules":{"clickable-rail":{"requires":["slider-base"]},"range-slider":{"requires":["slider-base","slider-value-range","clickable-rail"]},"slider-base":{"requires":["widget","dd-constrain","substitute"],"skinnable":true},"slider-value-range":{"requires":["slider-base"]}},"use":["slider-base","slider-value-range","clickable-rail","range-slider"]},"sortable":{"plugins":{"sortable-scroll":{"requires":["dd-scroll","sortable"]}},"requires":["dd-delegate","dd-drop-plugin","dd-proxy"]},"stylesheet":{},"substitute":{"optional":["dump"]},"swf":{"requires":["event-custom","node","swfdetect"]},"swfdetect":{},"tabview":{"plugins":{"tabview-base":{"requires":["node-event-delegate","classnamemanager","skin-sam-tabview"]},"tabview-plugin":{"requires":["tabview-base"]}},"requires":["widget","widget-parent","widget-child","tabview-base","node-pluginhost","node-focusmanager"],"skinnable":true},"test":{"requires":["event-simulate","event-custom","substitute","json-stringify"],"skinnable":true},"text":{"submodules":{"text-accentfold":{"requires":["array-extras","text-data-accentfold"]},"text-data-accentfold":{},"text-data-wordbreak":{},"text-wordbreak":{"requires":["array-extras","text-data-wordbreak"]}},"use":["text-accentfold","text-wordbreak"]},"transition":{"submodules":{"transition-native":{"requires":["node-base"]},"transition-timer":{"requires":["transition-native","node-style"]}},"use":["transition-native","transition-timer"]},"uploader":{"requires":["event-custom","node","base","swf"]},"widget":{"plugins":{"widget-base-ie":{"condition":{"name":"widget-base-ie","trigger":"widget-base","ua":"ie"},"requires":["widget-base"]},"widget-child":{"requires":["base-build","widget"]},"widget-parent":{"requires":["base-build","arraylist","widget"]},"widget-position":{"requires":["base-build","node-screen","widget"]},"widget-position-align":{"requires":["widget-position"]},"widget-position-constrain":{"requires":["widget-position"]},"widget-stack":{"requires":["base-build","widget"],"skinnable":true},"widget-stdmod":{"requires":["base-build","widget"]}},"skinnable":true,"submodules":{"widget-base":{"requires":["attribute","event-focus","base-base","base-pluginhost","node-base","node-style","classnamemanager"]},"widget-htmlparser":{"requires":["widget-base"]},"widget-skin":{"requires":["widget-base"]},"widget-uievents":{"requires":["widget-base","node-event-delegate"]}},"use":["widget-base","widget-htmlparser","widget-uievents","widget-skin"]},"widget-anim":{"requires":["plugin","anim-base","widget"]},"widget-locale":{"path":"widget/widget-locale-min.js","requires":["widget-base"]},"yql":{"requires":["jsonp","jsonp-url"]},"yui":{"submodules":{"features":{"requires":["yui-base"]},"get":{"requires":["yui-base"]},"intl-base":{"requires":["yui-base"]},"rls":{"requires":["get","features"]},"yui-base":{},"yui-later":{"requires":["yui-base"]},"yui-log":{"requires":["yui-base"]},"yui-rls":{"use":["yui-base","get","features","intl-base","rls","yui-log","yui-later"]}},"use":["yui-base","get","features","intl-base","yui-log","yui-later","loader-base","loader-rollup","loader-yui3"]},"yui-throttle":{"requires":["yui-base"]}};
-YUI.Env[a.version].md5="8cddfeca586b80c7fb7245817b42fa87";},"@VERSION@",{requires:["loader-base"]});YUI.add("yui",function(a){},"@VERSION@",{use:["yui-base","get","features","intl-base","yui-log","yui-later","loader-base","loader-rollup","loader-yui3"]});YUI.add("oop",function(h){var d=h.Lang,c=h.Array,b=Object.prototype,a="_~yuim~_",e="each",g="some",f=function(l,k,n,i,j){if(l&&l[j]&&l!==h){return l[j].call(l,k,n);}else{switch(c.test(l)){case 1:return c[j](l,k,n);case 2:return c[j](h.Array(l,0,true),k,n);default:return h.Object[j](l,k,n,i);}}};h.augment=function(i,y,l,w,q){var o=y.prototype,u=null,x=y,t=(q)?h.Array(q):[],k=i.prototype,p=k||i,v=false,j,n;if(k&&x){j={};n={};u={};h.Object.each(o,function(s,r){n[r]=function(){for(var z in j){if(j.hasOwnProperty(z)&&(this[z]===n[z])){this[z]=j[z];}}x.apply(this,t);return j[r].apply(this,arguments);};if((!w||(r in w))&&(l||!(r in this))){if(d.isFunction(s)){j[r]=s;this[r]=n[r];}else{this[r]=s;}}},u,true);}else{v=true;}h.mix(p,u||o,l,w);if(v){y.apply(p,t);}return i;};h.aggregate=function(k,j,i,l){return h.mix(k,j,i,l,0,true);};h.extend=function(l,k,i,o){if(!k||!l){h.error("extend failed, verify dependencies");}var n=k.prototype,j=h.Object(n);l.prototype=j;j.constructor=l;l.superclass=n;if(k!=Object&&n.constructor==b.constructor){n.constructor=k;}if(i){h.mix(j,i,true);}if(o){h.mix(l,o,true);}return l;};h.each=function(k,j,l,i){return f(k,j,l,i,e);};h.some=function(k,j,l,i){return f(k,j,l,i,g);};h.clone=function(l,n,s,t,k,r){if(!d.isObject(l)){return l;}if(h.instanceOf(l,YUI)){return l;}var p,j=r||{},i,q=h.each;switch(d.type(l)){case"date":return new Date(l);case"regexp":return l;case"function":return l;case"array":p=[];break;default:if(l[a]){return j[l[a]];}i=h.guid();p=(n)?{}:h.Object(l);l[a]=i;j[i]=l;}if(!l.addEventListener&&!l.attachEvent){q(l,function(u,o){if((o||o===0)&&(!s||(s.call(t||this,u,o,this,l)!==false))){if(o!==a){if(o=="prototype"){}else{this[o]=h.clone(u,n,s,t,k||l,j);}}}},p);}if(!r){h.Object.each(j,function(u,o){if(u[a]){try{delete u[a];}catch(w){u[a]=null;}}},this);j=null;}return p;};h.bind=function(i,k){var j=arguments.length>2?h.Array(arguments,2,true):null;return function(){var n=d.isString(i)?k[i]:i,l=(j)?j.concat(h.Array(arguments,0,true)):arguments;return n.apply(k||n,l);};};h.rbind=function(i,k){var j=arguments.length>2?h.Array(arguments,2,true):null;return function(){var n=d.isString(i)?k[i]:i,l=(j)?h.Array(arguments,0,true).concat(j):arguments;return n.apply(k||n,l);};};},"@VERSION@",{requires:["yui-base"]});YUI.add("dom-core",function(e){var o="nodeType",c="ownerDocument",b="documentElement",a="defaultView",g="parentWindow",j="tagName",k="parentNode",i="previousSibling",l="nextSibling",h="contains",d="compareDocumentPosition",n=[],f={byId:function(q,p){return f.allById(q,p)[0]||null;},ancestor:function(q,r,s){var p=null;if(s){p=(!r||r(q))?q:null;}return p||f.elementByAxis(q,k,r,null);},ancestors:function(r,s,t){var q=f.ancestor.apply(f,arguments),p=(q)?[q]:[];while((q=f.ancestor(q,s))){if(q){p.unshift(q);}}return p;},elementByAxis:function(p,s,r,q){while(p&&(p=p[s])){if((q||p[j])&&(!r||r(p))){return p;}}return null;},contains:function(q,r){var p=false;if(!r||!q||!r[o]||!q[o]){p=false;}else{if(q[h]){if(e.UA.opera||r[o]===1){p=q[h](r);}else{p=f._bruteContains(q,r);}}else{if(q[d]){if(q===r||!!(q[d](r)&16)){p=true;}}}}return p;},inDoc:function(r,s){var q=false,p;if(r&&r.nodeType){(s)||(s=r[c]);p=s[b];if(p&&p.contains&&r.tagName){q=p.contains(r);}else{q=f.contains(p,r);}}return q;},allById:function(u,p){p=p||e.config.doc;var q=[],r=[],s,t;if(p.querySelectorAll){r=p.querySelectorAll('[id="'+u+'"]');}else{if(p.all){q=p.all(u);if(q){if(q.nodeName){if(q.id===u){r.push(q);q=n;}else{q=[q];}}if(q.length){for(s=0;t=q[s++];){if(t.id===u||(t.attributes&&t.attributes.id&&t.attributes.id.value===u)){r.push(t);}}}}}else{r=[f._getDoc(p).getElementById(u)];}}return r;},isWindow:function(p){return !!(p&&p.alert&&p.document);},_removeChildNodes:function(p){while(p.firstChild){p.removeChild(p.firstChild);}},siblings:function(s,r){var p=[],q=s;while((q=q[i])){if(q[j]&&(!r||r(q))){p.unshift(q);}}q=s;while((q=q[l])){if(q[j]&&(!r||r(q))){p.push(q);}}return p;},_bruteContains:function(p,q){while(q){if(p===q){return true;}q=q.parentNode;}return false;},_getRegExp:function(q,p){p=p||"";f._regexCache=f._regexCache||{};if(!f._regexCache[q+p]){f._regexCache[q+p]=new RegExp(q,p);}return f._regexCache[q+p];},_getDoc:function(p){var q=e.config.doc;if(p){q=(p[o]===9)?p:p[c]||p.document||e.config.doc;}return q;},_getWin:function(p){var q=f._getDoc(p);return q[a]||q[g]||e.config.win;},_batch:function(p,x,v,u,t,r){x=(typeof x==="string")?f[x]:x;var y,s=0,q,w;if(x&&p){while((q=p[s++])){y=y=x.call(f,q,v,u,t,r);if(typeof y!=="undefined"){(w)||(w=[]);w.push(y);}}}return(typeof w!=="undefined")?w:p;},wrap:function(s,q){var r=e.DOM.create(q),p=r.getElementsByTagName("*");if(p.length){r=p[p.length-1];}if(s.parentNode){s.parentNode.replaceChild(r,s);}r.appendChild(s);},unwrap:function(s){var q=s.parentNode,r=q.lastChild,p=s,t;if(q){t=q.parentNode;if(t){while(s!==r){p=s.nextSibling;t.insertBefore(s,q);s=p;}t.replaceChild(r,q);}else{q.removeChild(s);}}},generateID:function(p){var q=p.id;if(!q){q=e.stamp(p);p.id=q;}return q;}};e.DOM=f;},"@VERSION@",{requires:["oop","features"]});YUI.add("dom-attrs",function(h){var e=h.config.doc.documentElement,b=h.DOM,a="tagName",g="ownerDocument",c="",f=h.Features.add,d=h.Features.test;h.mix(b,{getText:(e.textContent!==undefined)?function(j){var i="";if(j){i=j.textContent;}return i||"";}:function(j){var i="";if(j){i=j.innerText||j.nodeValue;}return i||"";},setText:(e.textContent!==undefined)?function(i,j){if(i){i.textContent=j;}}:function(i,j){if("innerText" in i){i.innerText=j;}else{if("nodeValue" in i){i.nodeValue=j;}}},CUSTOM_ATTRIBUTES:(!e.hasAttribute)?{"for":"htmlFor","class":"className"}:{"htmlFor":"for","className":"class"},setAttribute:function(k,i,l,j){if(k&&i&&k.setAttribute){i=b.CUSTOM_ATTRIBUTES[i]||i;k.setAttribute(i,l,j);
-}},getAttribute:function(l,i,k){k=(k!==undefined)?k:2;var j="";if(l&&i&&l.getAttribute){i=b.CUSTOM_ATTRIBUTES[i]||i;j=l.getAttribute(i,k);if(j===null){j="";}}return j;},VALUE_SETTERS:{},VALUE_GETTERS:{},getValue:function(k){var j="",i;if(k&&k[a]){i=b.VALUE_GETTERS[k[a].toLowerCase()];if(i){j=i(k);}else{j=k.value;}}if(j===c){j=c;}return(typeof j==="string")?j:"";},setValue:function(i,j){var k;if(i&&i[a]){k=b.VALUE_SETTERS[i[a].toLowerCase()];if(k){k(i,j);}else{i.value=j;}}},creators:{}});f("value-set","select",{test:function(){var i=h.config.doc.createElement("select");i.innerHTML="";i.value="2";return(i.value&&i.value==="2");}});if(!d("value-set","select")){b.VALUE_SETTERS.select=function(n,o){for(var k=0,j=n.getElementsByTagName("option"),l;l=j[k++];){if(b.getValue(l)===o){l.selected=true;break;}}};}h.mix(b.VALUE_GETTERS,{button:function(i){return(i.attributes&&i.attributes.value)?i.attributes.value.value:"";}});h.mix(b.VALUE_SETTERS,{button:function(j,k){var i=j.attributes.value;if(!i){i=j[g].createAttribute("value");j.setAttributeNode(i);}i.value=k;}});h.mix(b.VALUE_GETTERS,{option:function(j){var i=j.attributes;return(i.value&&i.value.specified)?j.value:j.text;},select:function(j){var k=j.value,i=j.options;if(i&&i.length){if(j.multiple){}else{k=b.getValue(i[j.selectedIndex]);}}return k;}});},"@VERSION@",{requires:["dom-core"]});YUI.add("dom-create",function(a){var c=/<([a-z]+)/i,d=a.DOM,i=a.Features.add,g=a.Features.test,f={},e=function(n,k){var o=a.config.doc.createElement("div"),l=true;o.innerHTML=n;if(!o.firstChild||o.firstChild.tagName!==k.toUpperCase()){l=false;}return l;},j=/(?:\/(?:thead|tfoot|tbody|caption|col|colgroup)>)+\s*",h="";a.mix(a.DOM,{_fragClones:{},_create:function(l,n,k){k=k||"div";var o=d._fragClones[k];if(o){o=o.cloneNode(false);}else{o=d._fragClones[k]=n.createElement(k);}o.innerHTML=l;return o;},create:function(p,s){if(typeof p==="string"){p=a.Lang.trim(p);}s=s||a.config.doc;var o=c.exec(p),q=d._create,l=f,r=null,n,t,k;if(p!=undefined){if(o&&o[1]){n=l[o[1].toLowerCase()];if(typeof n==="function"){q=n;}else{t=n;}}k=q(p,s,t).childNodes;if(k.length===1){r=k[0].parentNode.removeChild(k[0]);}else{if(k[0]&&k[0].className==="yui3-big-dummy"){if(k.length===2){r=k[0].nextSibling;}else{k[0].parentNode.removeChild(k[0]);r=d._nl2frag(k,s);}}else{r=d._nl2frag(k,s);}}}return r;},_nl2frag:function(l,p){var n=null,o,k;if(l&&(l.push||l.item)&&l[0]){p=p||l[0].ownerDocument;n=p.createDocumentFragment();if(l.item){l=a.Array(l,0,true);}for(o=0,k=l.length;o
","tr");}});i("innerhtml-div","script",{test:function(){return e("
+
+
+
+
+
+