woocommerce/assets/js/jquery-ui.min.js

4 lines
19 KiB
JavaScript
Raw Normal View History

2011-12-02 11:11:33 +00:00
/*
* jQuery UI 1.8.16
*/
(function(e,d){function b(f,c){var g=f.nodeName.toLowerCase();if("area"===g){c=f.parentNode;g=c.name;if(!f.href||!g||c.nodeName.toLowerCase()!=="map"){return false}f=e("img[usemap=#"+g+"]")[0];return !!f&&a(f)}return(/input|select|textarea|button|object/.test(g)?!f.disabled:"a"==g?f.href||c:c)&&a(f)}function a(c){return !e(c).parents().andSelf().filter(function(){return e.curCSS(this,"visibility")==="hidden"||e.expr.filters.hidden(this)}).length}e.ui=e.ui||{};if(!e.ui.version){e.extend(e.ui,{version:"1.8.16",keyCode:{ALT:18,BACKSPACE:8,CAPS_LOCK:20,COMMA:188,COMMAND:91,COMMAND_LEFT:91,COMMAND_RIGHT:93,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,MENU:93,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SHIFT:16,SPACE:32,TAB:9,UP:38,WINDOWS:91}});e.fn.extend({propAttr:e.fn.prop||e.fn.attr,_focus:e.fn.focus,focus:function(f,c){return typeof f==="number"?this.each(function(){var g=this;setTimeout(function(){e(g).focus();c&&c.call(g)},f)}):this._focus.apply(this,arguments)},scrollParent:function(){var c;c=e.browser.msie&&/(static|relative)/.test(this.css("position"))||/absolute/.test(this.css("position"))?this.parents().filter(function(){return/(relative|absolute|fixed)/.test(e.curCSS(this,"position",1))&&/(auto|scroll)/.test(e.curCSS(this,"overflow",1)+e.curCSS(this,"overflow-y",1)+e.curCSS(this,"overflow-x",1))}).eq(0):this.parents().filter(function(){return/(auto|scroll)/.test(e.curCSS(this,"overflow",1)+e.curCSS(this,"overflow-y",1)+e.curCSS(this,"overflow-x",1))}).eq(0);return/fixed/.test(this.css("position"))||!c.length?e(document):c},zIndex:function(f){if(f!==d){return this.css("zIndex",f)}if(this.length){f=e(this[0]);for(var c;f.length&&f[0]!==document;){c=f.css("position");if(c==="absolute"||c==="relative"||c==="fixed"){c=parseInt(f.css("zIndex"),10);if(!isNaN(c)&&c!==0){return c}}f=f.parent()}}return 0},disableSelection:function(){return this.bind((e.support.selectstart?"selectstart":"mousedown")+".ui-disableSelection",function(c){c.preventDefault()})},enableSelection:function(){return this.unbind(".ui-disableSelection")}});e.each(["Width","Height"],function(f,c){function l(o,i,h,p){e.each(k,function(){i-=parseFloat(e.curCSS(o,"padding"+this,true))||0;if(h){i-=parseFloat(e.curCSS(o,"border"+this+"Width",true))||0}if(p){i-=parseFloat(e.curCSS(o,"margin"+this,true))||0}});return i}var k=c==="Width"?["Left","Right"]:["Top","Bottom"],j=c.toLowerCase(),g={innerWidth:e.fn.innerWidth,innerHeight:e.fn.innerHeight,outerWidth:e.fn.outerWidth,outerHeight:e.fn.outerHeight};e.fn["inner"+c]=function(h){if(h===d){return g["inner"+c].call(this)}return this.each(function(){e(this).css(j,l(this,h)+"px")})};e.fn["outer"+c]=function(i,h){if(typeof i!=="number"){return g["outer"+c].call(this,i)}return this.each(function(){e(this).css(j,l(this,i,true,h)+"px")})}});e.extend(e.expr[":"],{data:function(f,c,g){return !!e.data(f,g[3])},focusable:function(c){return b(c,!isNaN(e.attr(c,"tabindex")))},tabbable:function(f){var c=e.attr(f,"tabindex"),g=isNaN(c);return(g||c>=0)&&b(f,!g)}});e(function(){var f=document.body,c=f.appendChild(c=document.createElement("div"));e.extend(c.style,{minHeight:"100px",height:"auto",padding:0,borderWidth:0});e.support.minHeight=c.offsetHeight===100;e.support.selectstart="onselectstart" in c;f.removeChild(c).style.display="none"});e.extend(e.ui,{plugin:{add:function(f,c,h){f=e.ui[f].prototype;for(var g in h){f.plugins[g]=f.plugins[g]||[];f.plugins[g].push([c,h[g]])}},call:function(f,c,h){if((c=f.plugins[c])&&f.element[0].parentNode){for(var g=0;g<c.length;g++){f.options[c[g][0]]&&c[g][1].apply(f.element,h)}}}},contains:function(f,c){return document.compareDocumentPosition?f.compareDocumentPosition(c)&16:f!==c&&f.contains(c)},hasScroll:function(f,c){if(e(f).css("overflow")==="hidden"){return false}c=c&&c==="left"?"scrollLeft":"scrollTop";var g=false;if(f[c]>0){return true}f[c]=1;g=f[c]>0;f[c]=0;return g},isOverAxis:function(f,c,g){return f>c&&f<c+g},isOver:function(f,c,l,k,j,