[ Index ]

PHP Cross Reference of WordPress

title

Body

[close]

/wp-includes/js/jquery/ui/ -> core.min.js (source)

   1  /*! jQuery UI - v1.12.1 - 2020-09-25
   2  * http://jqueryui.com
   3  * Includes: data.js, disable-selection.js, escape-selector.js, focusable.js, form-reset-mixin.js, form.js, ie.js, jquery-1-7.js, keycode.js, labels.js, plugin.js, position.js, safe-active-element.js, safe-blur.js, scroll-parent.js, tabbable.js, unique-id.js, version.js, widget.js
   4  * Copyright jQuery Foundation and other contributors; Licensed  */
   5  !function(t){"function"==typeof define&&define.amd?define(["jquery"],t):t(jQuery)}(function(x){var t,e,o,W,C,n,s,r,l,a,i,h;function E(t,e,i){return[parseFloat(t[0])*(a.test(t[0])?e/100:1),parseFloat(t[1])*(a.test(t[1])?i/100:1)]}function H(t,e){return parseInt(x.css(t,e),10)||0}x.ui=x.ui||{},x.ui.version="1.12.1",
   6  /*!
   7   * jQuery UI :data 1.12.1
   8   * http://jqueryui.com
   9   *
  10   * Copyright jQuery Foundation and other contributors
  11   * Released under the MIT license.
  12   * http://jquery.org/license
  13   */
  14  x.extend(x.expr[":"],{data:x.expr.createPseudo?x.expr.createPseudo(function(e){return function(t){return!!x.data(t,e)}}):function(t,e,i){return!!x.data(t,i[3])}}),
  15  /*!
  16   * jQuery UI Disable Selection 1.12.1
  17   * http://jqueryui.com
  18   *
  19   * Copyright jQuery Foundation and other contributors
  20   * Released under the MIT license.
  21   * http://jquery.org/license
  22   */
  23  x.fn.extend({disableSelection:(t="onselectstart"in document.createElement("div")?"selectstart":"mousedown",function(){return this.on(t+".ui-disableSelection",function(t){t.preventDefault()})}),enableSelection:function(){return this.off(".ui-disableSelection")}}),x.ui.escapeSelector=(e=/([!"#$%&'()*+,./:;<=>?@[\]^`{|}~])/g,function(t){return t.replace(e,"\\$1")}),
  24  /*!
  25   * jQuery UI Focusable 1.12.1
  26   * http://jqueryui.com
  27   *
  28   * Copyright jQuery Foundation and other contributors
  29   * Released under the MIT license.
  30   * http://jquery.org/license
  31   */
  32  x.ui.focusable=function(t,e){var i,n,o,s,r,l=t.nodeName.toLowerCase();return"area"===l?(n=(i=t.parentNode).name,!(!t.href||!n||"map"!==i.nodeName.toLowerCase())&&(0<(o=x("img[usemap='#"+n+"']")).length&&o.is(":visible"))):(/^(input|select|textarea|button|object)$/.test(l)?(s=!t.disabled)&&(r=x(t).closest("fieldset")[0])&&(s=!r.disabled):s="a"===l&&t.href||e,s&&x(t).is(":visible")&&function(t){var e=t.css("visibility");for(;"inherit"===e;)t=t.parent(),e=t.css("visibility");return"hidden"!==e}(x(t)))},x.extend(x.expr[":"],{focusable:function(t){return x.ui.focusable(t,null!=x.attr(t,"tabindex"))}}),x.fn.form=function(){return"string"==typeof this[0].form?this.closest("form"):x(this[0].form)},
  33  /*!
  34   * jQuery UI Form Reset Mixin 1.12.1
  35   * http://jqueryui.com
  36   *
  37   * Copyright jQuery Foundation and other contributors
  38   * Released under the MIT license.
  39   * http://jquery.org/license
  40   */
  41  x.ui.formResetMixin={_formResetHandler:function(){var e=x(this);setTimeout(function(){var t=e.data("ui-form-reset-instances");x.each(t,function(){this.refresh()})})},_bindFormResetHandler:function(){if(this.form=this.element.form(),this.form.length){var t=this.form.data("ui-form-reset-instances")||[];t.length||this.form.on("reset.ui-form-reset",this._formResetHandler),t.push(this),this.form.data("ui-form-reset-instances",t)}},_unbindFormResetHandler:function(){if(this.form.length){var t=this.form.data("ui-form-reset-instances");t.splice(x.inArray(this,t),1),t.length?this.form.data("ui-form-reset-instances",t):this.form.removeData("ui-form-reset-instances").off("reset.ui-form-reset")}}},x.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase()),
  42  /*!
  43   * jQuery UI Support for jQuery core 1.7.x 1.12.1
  44   * http://jqueryui.com
  45   *
  46   * Copyright jQuery Foundation and other contributors
  47   * Released under the MIT license.
  48   * http://jquery.org/license
  49   *
  50   */
  51  "1.7"===x.fn.jquery.substring(0,3)&&(x.each(["Width","Height"],function(t,i){var o="Width"===i?["Left","Right"]:["Top","Bottom"],n=i.toLowerCase(),s={innerWidth:x.fn.innerWidth,innerHeight:x.fn.innerHeight,outerWidth:x.fn.outerWidth,outerHeight:x.fn.outerHeight};function r(t,e,i,n){return x.each(o,function(){e-=parseFloat(x.css(t,"padding"+this))||0,i&&(e-=parseFloat(x.css(t,"border"+this+"Width"))||0),n&&(e-=parseFloat(x.css(t,"margin"+this))||0)}),e}x.fn["inner"+i]=function(t){return void 0===t?s["inner"+i].call(this):this.each(function(){x(this).css(n,r(this,t)+"px")})},x.fn["outer"+i]=function(t,e){return"number"!=typeof t?s["outer"+i].call(this,t):this.each(function(){x(this).css(n,r(this,t,!0,e)+"px")})}}),x.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),
  52  /*!
  53   * jQuery UI Keycode 1.12.1
  54   * http://jqueryui.com
  55   *
  56   * Copyright jQuery Foundation and other contributors
  57   * Released under the MIT license.
  58   * http://jquery.org/license
  59   */
  60  x.ui.keyCode={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38},
  61  /*!
  62   * jQuery UI Labels 1.12.1
  63   * http://jqueryui.com
  64   *
  65   * Copyright jQuery Foundation and other contributors
  66   * Released under the MIT license.
  67   * http://jquery.org/license
  68   */
  69  x.fn.labels=function(){var t,e,i,n,o;return this[0].labels&&this[0].labels.length?this.pushStack(this[0].labels):(n=this.eq(0).parents("label"),(i=this.attr("id"))&&(o=(t=this.eq(0).parents().last()).add(t.length?t.siblings():this.siblings()),e="label[for='"+x.ui.escapeSelector(i)+"']",n=n.add(o.find(e).addBack(e))),this.pushStack(n))},x.ui.plugin={add:function(t,e,i){var n,o=x.ui[t].prototype;for(n in i)o.plugins[n]=o.plugins[n]||[],o.plugins[n].push([e,i[n]])},call:function(t,e,i,n){var o,s=t.plugins[e];if(s&&(n||t.element[0].parentNode&&11!==t.element[0].parentNode.nodeType))for(o=0;o<s.length;o++)t.options[s[o][0]]&&s[o][1].apply(t.element,i)}},
  70  /*!
  71   * jQuery UI Position 1.12.1
  72   * http://jqueryui.com
  73   *
  74   * Copyright jQuery Foundation and other contributors
  75   * Released under the MIT license.
  76   * http://jquery.org/license
  77   *
  78   * http://api.jqueryui.com/position/
  79   */
  80  W=Math.max,C=Math.abs,n=/left|center|right/,s=/top|center|bottom/,r=/[\+\-]\d+(\.[\d]+)?%?/,l=/^\w+/,a=/%$/,i=x.fn.position,x.position={scrollbarWidth:function(){if(void 0!==o)return o;var t,e,i=x("<div style='display:block;position:absolute;width:50px;height:50px;overflow:hidden;'><div style='height:100px;width:auto;'></div></div>"),n=i.children()[0];return x("body").append(i),t=n.offsetWidth,i.css("overflow","scroll"),t===(e=n.offsetWidth)&&(e=i[0].clientWidth),i.remove(),o=t-e},getScrollInfo:function(t){var e=t.isWindow||t.isDocument?"":t.element.css("overflow-x"),i=t.isWindow||t.isDocument?"":t.element.css("overflow-y"),n="scroll"===e||"auto"===e&&t.width<t.element[0].scrollWidth;return{width:"scroll"===i||"auto"===i&&t.height<t.element[0].scrollHeight?x.position.scrollbarWidth():0,height:n?x.position.scrollbarWidth():0}},getWithinInfo:function(t){var e=x(t||window),i=x.isWindow(e[0]),n=!!e[0]&&9===e[0].nodeType;return{element:e,isWindow:i,isDocument:n,offset:i||n?{left:0,top:0}:x(t).offset(),scrollLeft:e.scrollLeft(),scrollTop:e.scrollTop(),width:e.outerWidth(),height:e.outerHeight()}}},x.fn.position=function(f){if(!f||!f.of)return i.apply(this,arguments);f=x.extend({},f);var u,d,p,g,m,t,v=x(f.of),b=x.position.getWithinInfo(f.within),w=x.position.getScrollInfo(b),y=(f.collision||"flip").split(" "),_={};return t=function(t){var e=t[0];return 9===e.nodeType?{width:t.width(),height:t.height(),offset:{top:0,left:0}}:x.isWindow(e)?{width:t.width(),height:t.height(),offset:{top:t.scrollTop(),left:t.scrollLeft()}}:e.preventDefault?{width:0,height:0,offset:{top:e.pageY,left:e.pageX}}:{width:t.outerWidth(),height:t.outerHeight(),offset:t.offset()}}(v),v[0].preventDefault&&(f.at="left top"),d=t.width,p=t.height,g=t.offset,m=x.extend({},g),x.each(["my","at"],function(){var t,e,i=(f[this]||"").split(" ");1===i.length&&(i=n.test(i[0])?i.concat(["center"]):s.test(i[0])?["center"].concat(i):["center","center"]),i[0]=n.test(i[0])?i[0]:"center",i[1]=s.test(i[1])?i[1]:"center",t=r.exec(i[0]),e=r.exec(i[1]),_[this]=[t?t[0]:0,e?e[0]:0],f[this]=[l.exec(i[0])[0],l.exec(i[1])[0]]}),1===y.length&&(y[1]=y[0]),"right"===f.at[0]?m.left+=d:"center"===f.at[0]&&(m.left+=d/2),"bottom"===f.at[1]?m.top+=p:"center"===f.at[1]&&(m.top+=p/2),u=E(_.at,d,p),m.left+=u[0],m.top+=u[1],this.each(function(){var i,t,r=x(this),l=r.outerWidth(),a=r.outerHeight(),e=H(this,"marginLeft"),n=H(this,"marginTop"),o=l+e+H(this,"marginRight")+w.width,s=a+n+H(this,"marginBottom")+w.height,h=x.extend({},m),c=E(_.my,r.outerWidth(),r.outerHeight());"right"===f.my[0]?h.left-=l:"center"===f.my[0]&&(h.left-=l/2),"bottom"===f.my[1]?h.top-=a:"center"===f.my[1]&&(h.top-=a/2),h.left+=c[0],h.top+=c[1],i={marginLeft:e,marginTop:n},x.each(["left","top"],function(t,e){x.ui.position[y[t]]&&x.ui.position[y[t]][e](h,{targetWidth:d,targetHeight:p,elemWidth:l,elemHeight:a,collisionPosition:i,collisionWidth:o,collisionHeight:s,offset:[u[0]+c[0],u[1]+c[1]],my:f.my,at:f.at,within:b,elem:r})}),f.using&&(t=function(t){var e=g.left-h.left,i=e+d-l,n=g.top-h.top,o=n+p-a,s={target:{element:v,left:g.left,top:g.top,width:d,height:p},element:{element:r,left:h.left,top:h.top,width:l,height:a},horizontal:i<0?"left":0<e?"right":"center",vertical:o<0?"top":0<n?"bottom":"middle"};d<l&&C(e+i)<d&&(s.horizontal="center"),p<a&&C(n+o)<p&&(s.vertical="middle"),W(C(e),C(i))>W(C(n),C(o))?s.important="horizontal":s.important="vertical",f.using.call(this,t,s)}),r.offset(x.extend(h,{using:t}))})},x.ui.position={fit:{left:function(t,e){var i,n=e.within,o=n.isWindow?n.scrollLeft:n.offset.left,s=n.width,r=t.left-e.collisionPosition.marginLeft,l=o-r,a=r+e.collisionWidth-s-o;e.collisionWidth>s?0<l&&a<=0?(i=t.left+l+e.collisionWidth-s-o,t.left+=l-i):t.left=0<a&&l<=0?o:a<l?o+s-e.collisionWidth:o:0<l?t.left+=l:0<a?t.left-=a:t.left=W(t.left-r,t.left)},top:function(t,e){var i,n=e.within,o=n.isWindow?n.scrollTop:n.offset.top,s=e.within.height,r=t.top-e.collisionPosition.marginTop,l=o-r,a=r+e.collisionHeight-s-o;e.collisionHeight>s?0<l&&a<=0?(i=t.top+l+e.collisionHeight-s-o,t.top+=l-i):t.top=0<a&&l<=0?o:a<l?o+s-e.collisionHeight:o:0<l?t.top+=l:0<a?t.top-=a:t.top=W(t.top-r,t.top)}},flip:{left:function(t,e){var i,n,o=e.within,s=o.offset.left+o.scrollLeft,r=o.width,l=o.isWindow?o.scrollLeft:o.offset.left,a=t.left-e.collisionPosition.marginLeft,h=a-l,c=a+e.collisionWidth-r-l,f="left"===e.my[0]?-e.elemWidth:"right"===e.my[0]?e.elemWidth:0,u="left"===e.at[0]?e.targetWidth:"right"===e.at[0]?-e.targetWidth:0,d=-2*e.offset[0];h<0?((i=t.left+f+u+d+e.collisionWidth-r-s)<0||i<C(h))&&(t.left+=f+u+d):0<c&&(0<(n=t.left-e.collisionPosition.marginLeft+f+u+d-l)||C(n)<c)&&(t.left+=f+u+d)},top:function(t,e){var i,n,o=e.within,s=o.offset.top+o.scrollTop,r=o.height,l=o.isWindow?o.scrollTop:o.offset.top,a=t.top-e.collisionPosition.marginTop,h=a-l,c=a+e.collisionHeight-r-l,f="top"===e.my[1]?-e.elemHeight:"bottom"===e.my[1]?e.elemHeight:0,u="top"===e.at[1]?e.targetHeight:"bottom"===e.at[1]?-e.targetHeight:0,d=-2*e.offset[1];h<0?((n=t.top+f+u+d+e.collisionHeight-r-s)<0||n<C(h))&&(t.top+=f+u+d):0<c&&(0<(i=t.top-e.collisionPosition.marginTop+f+u+d-l)||C(i)<c)&&(t.top+=f+u+d)}},flipfit:{left:function(){x.ui.position.flip.left.apply(this,arguments),x.ui.position.fit.left.apply(this,arguments)},top:function(){x.ui.position.flip.top.apply(this,arguments),x.ui.position.fit.top.apply(this,arguments)}}},x.ui.safeActiveElement=function(e){var i;try{i=e.activeElement}catch(t){i=e.body}return(i=i||e.body).nodeName||(i=e.body),i},x.ui.safeBlur=function(t){t&&"body"!==t.nodeName.toLowerCase()&&x(t).trigger("blur")},
  81  /*!
  82   * jQuery UI Scroll Parent 1.12.1
  83   * http://jqueryui.com
  84   *
  85   * Copyright jQuery Foundation and other contributors
  86   * Released under the MIT license.
  87   * http://jquery.org/license
  88   */
  89  x.fn.scrollParent=function(t){var e=this.css("position"),i="absolute"===e,n=t?/(auto|scroll|hidden)/:/(auto|scroll)/,o=this.parents().filter(function(){var t=x(this);return(!i||"static"!==t.css("position"))&&n.test(t.css("overflow")+t.css("overflow-y")+t.css("overflow-x"))}).eq(0);return"fixed"!==e&&o.length?o:x(this[0].ownerDocument||document)},
  90  /*!
  91   * jQuery UI Tabbable 1.12.1
  92   * http://jqueryui.com
  93   *
  94   * Copyright jQuery Foundation and other contributors
  95   * Released under the MIT license.
  96   * http://jquery.org/license
  97   */
  98  x.extend(x.expr[":"],{tabbable:function(t){var e=x.attr(t,"tabindex"),i=null!=e;return(!i||0<=e)&&x.ui.focusable(t,i)}}),
  99  /*!
 100   * jQuery UI Unique ID 1.12.1
 101   * http://jqueryui.com
 102   *
 103   * Copyright jQuery Foundation and other contributors
 104   * Released under the MIT license.
 105   * http://jquery.org/license
 106   */
 107  x.fn.extend({uniqueId:(h=0,function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++h)})}),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id)&&x(this).removeAttr("id")})}});
 108  /*!
 109   * jQuery UI Widget 1.12.1
 110   * http://jqueryui.com
 111   *
 112   * Copyright jQuery Foundation and other contributors
 113   * Released under the MIT license.
 114   * http://jquery.org/license
 115   */
 116  var c,f=0,u=Array.prototype.slice;x.cleanData=(c=x.cleanData,function(t){var e,i,n;for(n=0;null!=(i=t[n]);n++)try{(e=x._data(i,"events"))&&e.remove&&x(i).triggerHandler("remove")}catch(t){}c(t)}),x.widget=function(t,i,e){var n,o,s,r={},l=t.split(".")[0],a=l+"-"+(t=t.split(".")[1]);return e||(e=i,i=x.Widget),x.isArray(e)&&(e=x.extend.apply(null,[{}].concat(e))),x.expr[":"][a.toLowerCase()]=function(t){return!!x.data(t,a)},x[l]=x[l]||{},n=x[l][t],o=x[l][t]=function(t,e){if(!this._createWidget)return new o(t,e);arguments.length&&this._createWidget(t,e)},x.extend(o,n,{version:e.version,_proto:x.extend({},e),_childConstructors:[]}),(s=new i).options=x.widget.extend({},s.options),x.each(e,function(e,n){function o(){return i.prototype[e].apply(this,arguments)}function s(t){return i.prototype[e].apply(this,t)}x.isFunction(n)?r[e]=function(){var t,e=this._super,i=this._superApply;return this._super=o,this._superApply=s,t=n.apply(this,arguments),this._super=e,this._superApply=i,t}:r[e]=n}),o.prototype=x.widget.extend(s,{widgetEventPrefix:n&&s.widgetEventPrefix||t},r,{constructor:o,namespace:l,widgetName:t,widgetFullName:a}),n?(x.each(n._childConstructors,function(t,e){var i=e.prototype;x.widget(i.namespace+"."+i.widgetName,o,e._proto)}),delete n._childConstructors):i._childConstructors.push(o),x.widget.bridge(t,o),o},x.widget.extend=function(t){for(var e,i,n=u.call(arguments,1),o=0,s=n.length;o<s;o++)for(e in n[o])i=n[o][e],n[o].hasOwnProperty(e)&&void 0!==i&&(x.isPlainObject(i)?t[e]=x.isPlainObject(t[e])?x.widget.extend({},t[e],i):x.widget.extend({},i):t[e]=i);return t},x.widget.bridge=function(s,e){var r=e.prototype.widgetFullName||s;x.fn[s]=function(i){var t="string"==typeof i,n=u.call(arguments,1),o=this;return t?this.length||"instance"!==i?this.each(function(){var t,e=x.data(this,r);return"instance"===i?(o=e,!1):e?x.isFunction(e[i])&&"_"!==i.charAt(0)?(t=e[i].apply(e,n))!==e&&void 0!==t?(o=t&&t.jquery?o.pushStack(t.get()):t,!1):void 0:x.error("no such method '"+i+"' for "+s+" widget instance"):x.error("cannot call methods on "+s+" prior to initialization; attempted to call method '"+i+"'")}):o=void 0:(n.length&&(i=x.widget.extend.apply(null,[i].concat(n))),this.each(function(){var t=x.data(this,r);t?(t.option(i||{}),t._init&&t._init()):x.data(this,r,new e(i,this))})),o}},x.Widget=function(){},x.Widget._childConstructors=[],x.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"<div>",options:{classes:{},disabled:!1,create:null},_createWidget:function(t,e){e=x(e||this.defaultElement||this)[0],this.element=x(e),this.uuid=f++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=x(),this.hoverable=x(),this.focusable=x(),this.classesElementLookup={},e!==this&&(x.data(e,this.widgetFullName,this),this._on(!0,this.element,{remove:function(t){t.target===e&&this.destroy()}}),this.document=x(e.style?e.ownerDocument:e.document||e),this.window=x(this.document[0].defaultView||this.document[0].parentWindow)),this.options=x.widget.extend({},this.options,this._getCreateOptions(),t),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:x.noop,_create:x.noop,_init:x.noop,destroy:function(){var i=this;this._destroy(),x.each(this.classesElementLookup,function(t,e){i._removeClass(e,t)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:x.noop,widget:function(){return this.element},option:function(t,e){var i,n,o,s=t;if(0===arguments.length)return x.widget.extend({},this.options);if("string"==typeof t)if(s={},t=(i=t.split(".")).shift(),i.length){for(n=s[t]=x.widget.extend({},this.options[t]),o=0;o<i.length-1;o++)n[i[o]]=n[i[o]]||{},n=n[i[o]];if(t=i.pop(),1===arguments.length)return void 0===n[t]?null:n[t];n[t]=e}else{if(1===arguments.length)return void 0===this.options[t]?null:this.options[t];s[t]=e}return this._setOptions(s),this},_setOptions:function(t){var e;for(e in t)this._setOption(e,t[e]);return this},_setOption:function(t,e){return"classes"===t&&this._setOptionClasses(e),this.options[t]=e,"disabled"===t&&this._setOptionDisabled(e),this},_setOptionClasses:function(t){var e,i,n;for(e in t)n=this.classesElementLookup[e],t[e]!==this.options.classes[e]&&n&&n.length&&(i=x(n.get()),this._removeClass(n,e),i.addClass(this._classes({element:i,keys:e,classes:t,add:!0})))},_setOptionDisabled:function(t){this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,!!t),t&&(this._removeClass(this.hoverable,null,"ui-state-hover"),this._removeClass(this.focusable,null,"ui-state-focus"))},enable:function(){return this._setOptions({disabled:!1})},disable:function(){return this._setOptions({disabled:!0})},_classes:function(o){var s=[],r=this;function t(t,e){var i,n;for(n=0;n<t.length;n++)i=r.classesElementLookup[t[n]]||x(),i=o.add?x(x.unique(i.get().concat(o.element.get()))):x(i.not(o.element).get()),r.classesElementLookup[t[n]]=i,s.push(t[n]),e&&o.classes[t[n]]&&s.push(o.classes[t[n]])}return o=x.extend({element:this.element,classes:this.options.classes||{}},o),this._on(o.element,{remove:"_untrackClassesElement"}),o.keys&&t(o.keys.match(/\S+/g)||[],!0),o.extra&&t(o.extra.match(/\S+/g)||[]),s.join(" ")},_untrackClassesElement:function(i){var n=this;x.each(n.classesElementLookup,function(t,e){-1!==x.inArray(i.target,e)&&(n.classesElementLookup[t]=x(e.not(i.target).get()))})},_removeClass:function(t,e,i){return this._toggleClass(t,e,i,!1)},_addClass:function(t,e,i){return this._toggleClass(t,e,i,!0)},_toggleClass:function(t,e,i,n){n="boolean"==typeof n?n:i;var o="string"==typeof t||null===t,s={extra:o?e:i,keys:o?t:e,element:o?this.element:t,add:n};return s.element.toggleClass(this._classes(s),n),this},_on:function(r,l,t){var a,h=this;"boolean"!=typeof r&&(t=l,l=r,r=!1),t?(l=a=x(l),this.bindings=this.bindings.add(l)):(t=l,l=this.element,a=this.widget()),x.each(t,function(t,e){function i(){if(r||!0!==h.options.disabled&&!x(this).hasClass("ui-state-disabled"))return("string"==typeof e?h[e]:e).apply(h,arguments)}"string"!=typeof e&&(i.guid=e.guid=e.guid||i.guid||x.guid++);var n=t.match(/^([\w:-]*)\s*(.*)$/),o=n[1]+h.eventNamespace,s=n[2];s?a.on(o,s,i):l.on(o,i)})},_off:function(t,e){e=(e||"").split(" ").join(this.eventNamespace+" ")+this.eventNamespace,t.off(e).off(e),this.bindings=x(this.bindings.not(t).get()),this.focusable=x(this.focusable.not(t).get()),this.hoverable=x(this.hoverable.not(t).get())},_delay:function(t,e){var i=this;return setTimeout(function(){return("string"==typeof t?i[t]:t).apply(i,arguments)},e||0)},_hoverable:function(t){this.hoverable=this.hoverable.add(t),this._on(t,{mouseenter:function(t){this._addClass(x(t.currentTarget),null,"ui-state-hover")},mouseleave:function(t){this._removeClass(x(t.currentTarget),null,"ui-state-hover")}})},_focusable:function(t){this.focusable=this.focusable.add(t),this._on(t,{focusin:function(t){this._addClass(x(t.currentTarget),null,"ui-state-focus")},focusout:function(t){this._removeClass(x(t.currentTarget),null,"ui-state-focus")}})},_trigger:function(t,e,i){var n,o,s=this.options[t];if(i=i||{},(e=x.Event(e)).type=(t===this.widgetEventPrefix?t:this.widgetEventPrefix+t).toLowerCase(),e.target=this.element[0],o=e.originalEvent)for(n in o)n in e||(e[n]=o[n]);return this.element.trigger(e,i),!(x.isFunction(s)&&!1===s.apply(this.element[0],[e].concat(i))||e.isDefaultPrevented())}},x.each({show:"fadeIn",hide:"fadeOut"},function(s,r){x.Widget.prototype["_"+s]=function(e,t,i){var n;"string"==typeof t&&(t={effect:t});var o=t?!0===t||"number"==typeof t?r:t.effect||r:s;"number"==typeof(t=t||{})&&(t={duration:t}),n=!x.isEmptyObject(t),t.complete=i,t.delay&&e.delay(t.delay),n&&x.effects&&x.effects.effect[o]?e[s](t):o!==s&&e[o]?e[o](t.duration,t.easing,i):e.queue(function(t){x(this)[s](),i&&i.call(e[0]),t()})}})});


Generated: Sun Nov 29 01:00:04 2020 Cross-referenced by PHPXref 0.7.1