/*
 =======================================================================*\
|| ###################################################################### ||
|| # vBulletin 6.2.3
|| # ------------------------------------------------------------------ # ||
|| # Copyright 2000-2026 MH Sub I, LLC dba vBulletin. All Rights Reserved.  # ||
|| # This file may not be redistributed in whole or significant part.   # ||
|| # ----------------- VBULLETIN IS NOT FREE SOFTWARE ----------------- # ||
|| # http://www.vbulletin.com | http://www.vbulletin.com/license.html   # ||
|| ###################################################################### ||
\*========================================================================*/
// ***************************
// js.compressed/jquery-fallback.js
// ***************************
if(!window.jQuery){let a=vBulletin.data().jqueryversion;document.write('<script type="text/javascript" src="js/jquery/jquery-'+a+'.min.js">\x3c/script>')};
;

// ***************************
// js.compressed/jquery/jquery-ui-1.13.2.custom.min.js
// ***************************
/*
 jQuery UI - v1.13.2 - 2023-09-13
 http://jqueryui.com
 Includes: widget.js, position.js, data.js, disable-selection.js, focusable.js, form-reset-mixin.js, keycode.js, labels.js, scroll-parent.js, tabbable.js, unique-id.js, widgets/draggable.js, widgets/droppable.js, widgets/resizable.js, widgets/sortable.js, widgets/accordion.js, widgets/autocomplete.js, widgets/button.js, widgets/checkboxradio.js, widgets/controlgroup.js, widgets/dialog.js, widgets/menu.js, widgets/mouse.js, widgets/slider.js, widgets/tabs.js
 Copyright jQuery Foundation and other contributors; Licensed MIT  jQuery UI Widget 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Position 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license

 http://api.jqueryui.com/position/
 jQuery UI :data 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Disable Selection 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Focusable 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Form Reset Mixin 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Keycode 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Labels 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Scroll Parent 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Tabbable 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Unique ID 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Mouse 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Draggable 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Droppable 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Resizable 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Sortable 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Accordion 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Menu 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Autocomplete 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Controlgroup 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Checkboxradio 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Button 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Dialog 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Slider 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
 jQuery UI Tabs 1.13.2
 http://jqueryui.com

 Copyright jQuery Foundation and other contributors
 Released under the MIT license.
 http://jquery.org/license
*/
(function(d){"function"===typeof define&&define.amd?define(["jquery"],d):d(jQuery)})(function(d){d.ui=d.ui||{};d.ui.version="1.13.2";var E=0,F=Array.prototype.hasOwnProperty,C=Array.prototype.slice;d.cleanData=function(a){return function(b){var c,e,f;for(f=0;null!=(e=b[f]);f++)(c=d._data(e,"events"))&&c.remove&&d(e).triggerHandler("remove");a(b)}}(d.cleanData);d.widget=function(a,b,c){var e={},f=a.split(".")[0];a=a.split(".")[1];var g=f+"-"+a;c||(c=b,b=d.Widget);Array.isArray(c)&&(c=
d.extend.apply(null,[{}].concat(c)));d.expr.pseudos[g.toLowerCase()]=function(a){return!!d.data(a,g)};d[f]=d[f]||{};var h=d[f][a];var k=d[f][a]=function(a,b){if(!this||!this._createWidget)return new k(a,b);arguments.length&&this._createWidget(a,b)};d.extend(k,h,{version:c.version,_proto:d.extend({},c),_childConstructors:[]});var l=new b;l.options=d.widget.extend({},l.options);d.each(c,function(a,c){e[a]="function"!==typeof c?c:function(){function d(){return b.prototype[a].apply(this,arguments)}function e(c){return b.prototype[a].apply(this,
c)}return function(){var a=this._super,b=this._superApply;this._super=d;this._superApply=e;var f=c.apply(this,arguments);this._super=a;this._superApply=b;return f}}()});k.prototype=d.widget.extend(l,{widgetEventPrefix:h?l.widgetEventPrefix||a:a},e,{constructor:k,namespace:f,widgetName:a,widgetFullName:g});h?(d.each(h._childConstructors,function(a,b){a=b.prototype;d.widget(a.namespace+"."+a.widgetName,k,b._proto)}),delete h._childConstructors):b._childConstructors.push(k);d.widget.bridge(a,k);return k};
d.widget.extend=function(a){for(var b=C.call(arguments,1),c=0,e=b.length,f,g;c<e;c++)for(f in b[c])g=b[c][f],F.call(b[c],f)&&void 0!==g&&(d.isPlainObject(g)?a[f]=d.isPlainObject(a[f])?d.widget.extend({},a[f],g):d.widget.extend({},g):a[f]=g);return a};d.widget.bridge=function(a,b){var c=b.prototype.widgetFullName||a;d.fn[a]=function(e){var f="string"===typeof e,g=C.call(arguments,1),h=this;f?this.length||"instance"!==e?this.each(function(){var b=d.data(this,c);if("instance"===e)return h=b,!1;if(!b)return d.error("cannot call methods on "+
a+" prior to initialization; attempted to call method '"+e+"'");if("function"!==typeof b[e]||"_"===e.charAt(0))return d.error("no such method '"+e+"' for "+a+" widget instance");var f=b[e].apply(b,g);if(f!==b&&void 0!==f)return h=f&&f.jquery?h.pushStack(f.get()):f,!1}):h=void 0:(g.length&&(e=d.widget.extend.apply(null,[e].concat(g))),this.each(function(){var a=d.data(this,c);a?(a.option(e||{}),a._init&&a._init()):d.data(this,c,new b(e,this))}));return h}};d.Widget=function(){};d.Widget._childConstructors=
[];d.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"<div>",options:{classes:{},disabled:!1,create:null},_createWidget:function(a,b){b=d(b||this.defaultElement||this)[0];this.element=d(b);this.uuid=E++;this.eventNamespace="."+this.widgetName+this.uuid;this.bindings=d();this.hoverable=d();this.focusable=d();this.classesElementLookup={};b!==this&&(d.data(b,this.widgetFullName,this),this._on(!0,this.element,{remove:function(a){a.target===b&&this.destroy()}}),this.document=
d(b.style?b.ownerDocument:b.document||b),this.window=d(this.document[0].defaultView||this.document[0].parentWindow));this.options=d.widget.extend({},this.options,this._getCreateOptions(),a);this._create();this.options.disabled&&this._setOptionDisabled(this.options.disabled);this._trigger("create",null,this._getCreateEventData());this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:d.noop,_create:d.noop,_init:d.noop,destroy:function(){var a=this;this._destroy();d.each(this.classesElementLookup,
function(b,c){a._removeClass(c,b)});this.element.off(this.eventNamespace).removeData(this.widgetFullName);this.widget().off(this.eventNamespace).removeAttr("aria-disabled");this.bindings.off(this.eventNamespace)},_destroy:d.noop,widget:function(){return this.element},option:function(a,b){var c=a,e;if(0===arguments.length)return d.widget.extend({},this.options);if("string"===typeof a){c={};var f=a.split(".");a=f.shift();if(f.length){var g=c[a]=d.widget.extend({},this.options[a]);for(e=0;e<f.length-
1;e++)g[f[e]]=g[f[e]]||{},g=g[f[e]];a=f.pop();if(1===arguments.length)return void 0===g[a]?null:g[a];g[a]=b}else{if(1===arguments.length)return void 0===this.options[a]?null:this.options[a];c[a]=b}}this._setOptions(c);return this},_setOptions:function(a){for(var b in a)this._setOption(b,a[b]);return this},_setOption:function(a,b){"classes"===a&&this._setOptionClasses(b);this.options[a]=b;"disabled"===a&&this._setOptionDisabled(b);return this},_setOptionClasses:function(a){var b;for(b in a){var c=
this.classesElementLookup[b];if(a[b]!==this.options.classes[b]&&c&&c.length){var e=d(c.get());this._removeClass(c,b);e.addClass(this._classes({element:e,keys:b,classes:a,add:!0}))}}},_setOptionDisabled:function(a){this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,!!a);a&&(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(a){function b(){var b=[];a.element.each(function(a,c){d.map(f.classesElementLookup,function(a){return a}).some(function(a){return a.is(c)})||b.push(c)});f._on(d(b),{remove:"_untrackClassesElement"})}function c(c,h){var g;for(g=0;g<c.length;g++){var l=f.classesElementLookup[c[g]]||d();a.add?(b(),l=d(d.uniqueSort(l.get().concat(a.element.get())))):l=d(l.not(a.element).get());f.classesElementLookup[c[g]]=l;e.push(c[g]);h&&a.classes[c[g]]&&e.push(a.classes[c[g]])}}var e=[],f=this;a=
d.extend({element:this.element,classes:this.options.classes||{}},a);a.keys&&c(a.keys.match(/\S+/g)||[],!0);a.extra&&c(a.extra.match(/\S+/g)||[]);return e.join(" ")},_untrackClassesElement:function(a){var b=this;d.each(b.classesElementLookup,function(c,e){-1!==d.inArray(a.target,e)&&(b.classesElementLookup[c]=d(e.not(a.target).get()))});this._off(d(a.target))},_removeClass:function(a,b,c){return this._toggleClass(a,b,c,!1)},_addClass:function(a,b,c){return this._toggleClass(a,b,c,!0)},_toggleClass:function(a,
b,c,d){d="boolean"===typeof d?d:c;var e="string"===typeof a||null===a;a={extra:e?b:c,keys:e?a:b,element:e?this.element:a,add:d};a.element.toggleClass(this._classes(a),d);return this},_on:function(a,b,c){var e,f=this;"boolean"!==typeof a&&(c=b,b=a,a=!1);c?(b=e=d(b),this.bindings=this.bindings.add(b)):(c=b,b=this.element,e=this.widget());d.each(c,function(c,h){function g(){if(a||!0!==f.options.disabled&&!d(this).hasClass("ui-state-disabled"))return("string"===typeof h?f[h]:h).apply(f,arguments)}"string"!==
typeof h&&(g.guid=h.guid=h.guid||g.guid||d.guid++);var l=c.match(/^([\w:-]*)\s*(.*)$/);c=l[1]+f.eventNamespace;if(l=l[2])e.on(c,l,g);else b.on(c,g)})},_off:function(a,b){b=(b||"").split(" ").join(this.eventNamespace+" ")+this.eventNamespace;a.off(b);this.bindings=d(this.bindings.not(a).get());this.focusable=d(this.focusable.not(a).get());this.hoverable=d(this.hoverable.not(a).get())},_delay:function(a,b){var c=this;return setTimeout(function(){return("string"===typeof a?c[a]:a).apply(c,arguments)},
b||0)},_hoverable:function(a){this.hoverable=this.hoverable.add(a);this._on(a,{mouseenter:function(a){this._addClass(d(a.currentTarget),null,"ui-state-hover")},mouseleave:function(a){this._removeClass(d(a.currentTarget),null,"ui-state-hover")}})},_focusable:function(a){this.focusable=this.focusable.add(a);this._on(a,{focusin:function(a){this._addClass(d(a.currentTarget),null,"ui-state-focus")},focusout:function(a){this._removeClass(d(a.currentTarget),null,"ui-state-focus")}})},_trigger:function(a,
b,c){var e,f=this.options[a];c=c||{};b=d.Event(b);b.type=(a===this.widgetEventPrefix?a:this.widgetEventPrefix+a).toLowerCase();b.target=this.element[0];if(a=b.originalEvent)for(e in a)e in b||(b[e]=a[e]);this.element.trigger(b,c);return!("function"===typeof f&&!1===f.apply(this.element[0],[b].concat(c))||b.isDefaultPrevented())}};d.each({show:"fadeIn",hide:"fadeOut"},function(a,b){d.Widget.prototype["_"+a]=function(c,e,f){"string"===typeof e&&(e={effect:e});var g=e?!0===e||"number"===typeof e?b:e.effect||
b:a;e=e||{};"number"===typeof e?e={duration:e}:!0===e&&(e={});var h=!d.isEmptyObject(e);e.complete=f;e.delay&&c.delay(e.delay);if(h&&d.effects&&d.effects.effect[g])c[a](e);else if(g!==a&&c[g])c[g](e.duration,e.easing,f);else c.queue(function(b){d(this)[a]();f&&f.call(c[0]);b()})}});(function(){function a(a,b,c){return[parseFloat(a[0])*(m.test(a[0])?b/100:1),parseFloat(a[1])*(m.test(a[1])?c/100:1)]}function b(a){var b=a[0];return 9===b.nodeType?{width:a.width(),height:a.height(),offset:{top:0,left:0}}:
null!=b&&b===b.window?{width:a.width(),height:a.height(),offset:{top:a.scrollTop(),left:a.scrollLeft()}}:b.preventDefault?{width:0,height:0,offset:{top:b.pageY,left:b.pageX}}:{width:a.outerWidth(),height:a.outerHeight(),offset:a.offset()}}var c,e=Math.max,f=Math.abs,g=/left|center|right/,h=/top|center|bottom/,k=/[\+\-]\d+(\.[\d]+)?%?/,l=/^\w+/,m=/%$/,n=d.fn.position;d.position={scrollbarWidth:function(){if(void 0!==c)return c;var a=d("<div style='display:block;position:absolute;width:200px;height:200px;overflow:hidden;'><div style='height:300px;width:auto;'></div></div>");
var b=a.children()[0];d("body").append(a);var e=b.offsetWidth;a.css("overflow","scroll");b=b.offsetWidth;e===b&&(b=a[0].clientWidth);a.remove();return c=e-b},getScrollInfo:function(a){var b=a.isWindow||a.isDocument?"":a.element.css("overflow-x"),c=a.isWindow||a.isDocument?"":a.element.css("overflow-y");b="scroll"===b||"auto"===b&&a.width<a.element[0].scrollWidth;return{width:"scroll"===c||"auto"===c&&a.height<a.element[0].scrollHeight?d.position.scrollbarWidth():0,height:b?d.position.scrollbarWidth():
0}},getWithinInfo:function(a){var b=d(a||window);var c=b[0];c=null!=c&&c===c.window;var e=!!b[0]&&9===b[0].nodeType;return{element:b,isWindow:c,isDocument:e,offset:c||e?{left:0,top:0}:d(a).offset(),scrollLeft:b.scrollLeft(),scrollTop:b.scrollTop(),width:b.outerWidth(),height:b.outerHeight()}}};d.fn.position=function(c){if(!c||!c.of)return n.apply(this,arguments);c=d.extend({},c);var v="string"===typeof c.of?d(document).find(c.of):d(c.of),m=d.position.getWithinInfo(c.within),p=d.position.getScrollInfo(m),
r=(c.collision||"flip").split(" "),t={};var w=b(v);v[0].preventDefault&&(c.at="left top");var x=w.width;var A=w.height;var B=w.offset;var u=d.extend({},B);d.each(["my","at"],function(){var a=(c[this]||"").split(" ");1===a.length&&(a=g.test(a[0])?a.concat(["center"]):h.test(a[0])?["center"].concat(a):["center","center"]);a[0]=g.test(a[0])?a[0]:"center";a[1]=h.test(a[1])?a[1]:"center";var b=k.exec(a[0]);var d=k.exec(a[1]);t[this]=[b?b[0]:0,d?d[0]:0];c[this]=[l.exec(a[0])[0],l.exec(a[1])[0]]});1===r.length&&
(r[1]=r[0]);"right"===c.at[0]?u.left+=x:"center"===c.at[0]&&(u.left+=x/2);"bottom"===c.at[1]?u.top+=A:"center"===c.at[1]&&(u.top+=A/2);var z=a(t.at,x,A);u.left+=z[0];u.top+=z[1];return this.each(function(){var b,g=d(this),h=g.outerWidth(),k=g.outerHeight(),l=parseInt(d.css(this,"marginLeft"),10)||0,y=parseInt(d.css(this,"marginTop"),10)||0,n=h+l+(parseInt(d.css(this,"marginRight"),10)||0)+p.width,w=k+y+(parseInt(d.css(this,"marginBottom"),10)||0)+p.height,q=d.extend({},u),D=a(t.my,g.outerWidth(),
g.outerHeight());"right"===c.my[0]?q.left-=h:"center"===c.my[0]&&(q.left-=h/2);"bottom"===c.my[1]?q.top-=k:"center"===c.my[1]&&(q.top-=k/2);q.left+=D[0];q.top+=D[1];var C={marginLeft:l,marginTop:y};d.each(["left","top"],function(a,b){if(d.ui.position[r[a]])d.ui.position[r[a]][b](q,{targetWidth:x,targetHeight:A,elemWidth:h,elemHeight:k,collisionPosition:C,collisionWidth:n,collisionHeight:w,offset:[z[0]+D[0],z[1]+D[1]],my:c.my,at:c.at,within:m,elem:g})});c.using&&(b=function(a){var b=B.left-q.left,
d=b+x-h,l=B.top-q.top,m=l+A-k,p={target:{element:v,left:B.left,top:B.top,width:x,height:A},element:{element:g,left:q.left,top:q.top,width:h,height:k},horizontal:0>d?"left":0<b?"right":"center",vertical:0>m?"top":0<l?"bottom":"middle"};x<h&&f(b+d)<x&&(p.horizontal="center");A<k&&f(l+m)<A&&(p.vertical="middle");e(f(b),f(d))>e(f(l),f(m))?p.important="horizontal":p.important="vertical";c.using.call(this,a,p)});g.offset(d.extend(q,{using:b}))})};d.ui.position={fit:{left:function(a,b){var c=b.within,d=
c.isWindow?c.scrollLeft:c.offset.left,f=c.width,g=a.left-b.collisionPosition.marginLeft;c=d-g;var h=g+b.collisionWidth-f-d;b.collisionWidth>f?0<c&&0>=h?(b=a.left+c+b.collisionWidth-f-d,a.left+=c-b):a.left=0<h&&0>=c?d:c>h?d+f-b.collisionWidth:d:a.left=0<c?a.left+c:0<h?a.left-h:e(a.left-g,a.left)},top:function(a,b){var c=b.within,d=c.isWindow?c.scrollTop:c.offset.top,f=b.within.height,g=a.top-b.collisionPosition.marginTop;c=d-g;var h=g+b.collisionHeight-f-d;b.collisionHeight>f?0<c&&0>=h?(b=a.top+c+
b.collisionHeight-f-d,a.top+=c-b):a.top=0<h&&0>=c?d:c>h?d+f-b.collisionHeight:d:a.top=0<c?a.top+c:0<h?a.top-h:e(a.top-g,a.top)}},flip:{left:function(a,b){var c=b.within,d=c.offset.left+c.scrollLeft,e=c.width,g=c.isWindow?c.scrollLeft:c.offset.left,h=a.left-b.collisionPosition.marginLeft;c=h-g;var k=h+b.collisionWidth-e-g;h="left"===b.my[0]?-b.elemWidth:"right"===b.my[0]?b.elemWidth:0;var l="left"===b.at[0]?b.targetWidth:"right"===b.at[0]?-b.targetWidth:0,m=-2*b.offset[0];if(0>c){if(b=a.left+h+l+m+
b.collisionWidth-e-d,0>b||b<f(c))a.left+=h+l+m}else 0<k&&(b=a.left-b.collisionPosition.marginLeft+h+l+m-g,0<b||f(b)<k)&&(a.left+=h+l+m)},top:function(a,b){var c=b.within,d=c.offset.top+c.scrollTop,e=c.height,g=c.isWindow?c.scrollTop:c.offset.top,h=a.top-b.collisionPosition.marginTop;c=h-g;var k=h+b.collisionHeight-e-g;h="top"===b.my[1]?-b.elemHeight:"bottom"===b.my[1]?b.elemHeight:0;var l="top"===b.at[1]?b.targetHeight:"bottom"===b.at[1]?-b.targetHeight:0,m=-2*b.offset[1];if(0>c){if(b=a.top+h+l+m+
b.collisionHeight-e-d,0>b||b<f(c))a.top+=h+l+m}else 0<k&&(b=a.top-b.collisionPosition.marginTop+h+l+m-g,0<b||f(b)<k)&&(a.top+=h+l+m)}},flipfit:{left:function(){d.ui.position.flip.left.apply(this,arguments);d.ui.position.fit.left.apply(this,arguments)},top:function(){d.ui.position.flip.top.apply(this,arguments);d.ui.position.fit.top.apply(this,arguments)}}}})();d.extend(d.expr.pseudos,{data:d.expr.createPseudo?d.expr.createPseudo(function(a){return function(b){return!!d.data(b,a)}}):function(a,b,c){return!!d.data(a,
c[3])}});d.fn.extend({disableSelection:function(){var a="onselectstart"in document.createElement("div")?"selectstart":"mousedown";return function(){return this.on(a+".ui-disableSelection",function(a){a.preventDefault()})}}(),enableSelection:function(){return this.off(".ui-disableSelection")}});d.ui.focusable=function(a,b){var c=a.nodeName.toLowerCase();if("area"===c){b=a.parentNode;c=b.name;if(!a.href||!c||"map"!==b.nodeName.toLowerCase())return!1;a=d("img[usemap='#"+c+"']");return 0<a.length&&a.is(":visible")}/^(input|select|textarea|button|object)$/.test(c)?
(b=!a.disabled)&&(c=d(a).closest("fieldset")[0])&&(b=!c.disabled):b="a"===c?a.href||b:b;if(b=b&&d(a).is(":visible")){a=d(a);for(b=a.css("visibility");"inherit"===b;)a=a.parent(),b=a.css("visibility");b="visible"===b}return b};d.extend(d.expr.pseudos,{focusable:function(a){return d.ui.focusable(a,null!=d.attr(a,"tabindex"))}});d.fn._form=function(){return"string"===typeof this[0].form?this.closest("form"):d(this[0].form)};d.ui.formResetMixin={_formResetHandler:function(){var a=d(this);setTimeout(function(){var b=
a.data("ui-form-reset-instances");d.each(b,function(){this.refresh()})})},_bindFormResetHandler:function(){this.form=this.element._form();if(this.form.length){var a=this.form.data("ui-form-reset-instances")||[];if(!a.length)this.form.on("reset.ui-form-reset",this._formResetHandler);a.push(this);this.form.data("ui-form-reset-instances",a)}},_unbindFormResetHandler:function(){if(this.form.length){var a=this.form.data("ui-form-reset-instances");a.splice(d.inArray(this,a),1);a.length?this.form.data("ui-form-reset-instances",
a):this.form.removeData("ui-form-reset-instances").off("reset.ui-form-reset")}}};d.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};d.fn.labels=function(){var a;if(!this.length)return this.pushStack([]);if(this[0].labels&&this[0].labels.length)return this.pushStack(this[0].labels);var b=this.eq(0).parents("label");if(a=this.attr("id")){var c=this.eq(0).parents().last();c=c.add(c.length?c.siblings():
this.siblings());a="label[for='"+d.escapeSelector(a)+"']";b=b.add(c.find(a).addBack(a))}return this.pushStack(b)};d.fn.scrollParent=function(a){var b=this.css("position"),c="absolute"===b,e=a?/(auto|scroll|hidden)/:/(auto|scroll)/;a=this.parents().filter(function(){var a=d(this);return c&&"static"===a.css("position")?!1:e.test(a.css("overflow")+a.css("overflow-y")+a.css("overflow-x"))}).eq(0);return"fixed"!==b&&a.length?a:d(this[0].ownerDocument||document)};d.extend(d.expr.pseudos,{tabbable:function(a){var b=
d.attr(a,"tabindex"),c=null!=b;return(!c||0<=b)&&d.ui.focusable(a,c)}});d.fn.extend({uniqueId:function(){var a=0;return function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++a)})}}(),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id)&&d(this).removeAttr("id")})}});d.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase());var z=!1;d(document).on("mouseup",function(){z=!1});d.widget("ui.mouse",{version:"1.13.2",options:{cancel:"input, textarea, button, select, option",
distance:1,delay:0},_mouseInit:function(){var a=this;this.element.on("mousedown."+this.widgetName,function(b){return a._mouseDown(b)}).on("click."+this.widgetName,function(b){if(!0===d.data(b.target,a.widgetName+".preventClickEvent"))return d.removeData(b.target,a.widgetName+".preventClickEvent"),b.stopImmediatePropagation(),!1});this.started=!1},_mouseDestroy:function(){this.element.off("."+this.widgetName);this._mouseMoveDelegate&&this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+
this.widgetName,this._mouseUpDelegate)},_mouseDown:function(a){if(!z){this._mouseMoved=!1;this._mouseStarted&&this._mouseUp(a);this._mouseDownEvent=a;var b=this,c=1===a.which,e="string"===typeof this.options.cancel&&a.target.nodeName?d(a.target).closest(this.options.cancel).length:!1;if(!c||e||!this._mouseCapture(a))return!0;this.mouseDelayMet=!this.options.delay;this.mouseDelayMet||(this._mouseDelayTimer=setTimeout(function(){b.mouseDelayMet=!0},this.options.delay));if(this._mouseDistanceMet(a)&&
this._mouseDelayMet(a)&&(this._mouseStarted=!1!==this._mouseStart(a),!this._mouseStarted))return a.preventDefault(),!0;!0===d.data(a.target,this.widgetName+".preventClickEvent")&&d.removeData(a.target,this.widgetName+".preventClickEvent");this._mouseMoveDelegate=function(a){return b._mouseMove(a)};this._mouseUpDelegate=function(a){return b._mouseUp(a)};this.document.on("mousemove."+this.widgetName,this._mouseMoveDelegate).on("mouseup."+this.widgetName,this._mouseUpDelegate);a.preventDefault();return z=
!0}},_mouseMove:function(a){if(this._mouseMoved){if(d.ui.ie&&(!document.documentMode||9>document.documentMode)&&!a.button)return this._mouseUp(a);if(!a.which)if(a.originalEvent.altKey||a.originalEvent.ctrlKey||a.originalEvent.metaKey||a.originalEvent.shiftKey)this.ignoreMissingWhich=!0;else if(!this.ignoreMissingWhich)return this._mouseUp(a)}if(a.which||a.button)this._mouseMoved=!0;if(this._mouseStarted)return this._mouseDrag(a),a.preventDefault();this._mouseDistanceMet(a)&&this._mouseDelayMet(a)&&
((this._mouseStarted=!1!==this._mouseStart(this._mouseDownEvent,a))?this._mouseDrag(a):this._mouseUp(a));return!this._mouseStarted},_mouseUp:function(a){this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate);this._mouseStarted&&(this._mouseStarted=!1,a.target===this._mouseDownEvent.target&&d.data(a.target,this.widgetName+".preventClickEvent",!0),this._mouseStop(a));this._mouseDelayTimer&&(clearTimeout(this._mouseDelayTimer),delete this._mouseDelayTimer);
z=this.ignoreMissingWhich=!1;a.preventDefault()},_mouseDistanceMet:function(a){return Math.max(Math.abs(this._mouseDownEvent.pageX-a.pageX),Math.abs(this._mouseDownEvent.pageY-a.pageY))>=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return!0}});d.ui.plugin={add:function(a,b,c){var e;a=d.ui[a].prototype;for(e in c)a.plugins[e]=a.plugins[e]||[],a.plugins[e].push([b,c[e]])},
call:function(a,b,c,d){if((b=a.plugins[b])&&(d||a.element[0].parentNode&&11!==a.element[0].parentNode.nodeType))for(d=0;d<b.length;d++)a.options[b[d][0]]&&b[d][1].apply(a.element,c)}};d.ui.safeActiveElement=function(a){try{var b=a.activeElement}catch(c){b=a.body}b||(b=a.body);b.nodeName||(b=a.body);return b};d.ui.safeBlur=function(a){a&&"body"!==a.nodeName.toLowerCase()&&d(a).trigger("blur")};d.widget("ui.draggable",d.ui.mouse,{version:"1.13.2",widgetEventPrefix:"drag",options:{addClasses:!0,appendTo:"parent",
axis:!1,connectToSortable:!1,containment:!1,cursor:"auto",cursorAt:!1,grid:!1,handle:!1,helper:"original",iframeFix:!1,opacity:!1,refreshPositions:!1,revert:!1,revertDuration:500,scope:"default",scroll:!0,scrollSensitivity:20,scrollSpeed:20,snap:!1,snapMode:"both",snapTolerance:20,stack:!1,zIndex:!1,drag:null,start:null,stop:null},_create:function(){"original"===this.options.helper&&this._setPositionRelative();this.options.addClasses&&this._addClass("ui-draggable");this._setHandleClassName();this._mouseInit()},
_setOption:function(a,b){this._super(a,b);"handle"===a&&(this._removeHandleClassName(),this._setHandleClassName())},_destroy:function(){(this.helper||this.element).is(".ui-draggable-dragging")?this.destroyOnClear=!0:(this._removeHandleClassName(),this._mouseDestroy())},_mouseCapture:function(a){var b=this.options;if(this.helper||b.disabled||0<d(a.target).closest(".ui-resizable-handle").length)return!1;this.handle=this._getHandle(a);if(!this.handle)return!1;this._blurActiveElement(a);this._blockFrames(!0===
b.iframeFix?"iframe":b.iframeFix);return!0},_blockFrames:function(a){this.iframeBlocks=this.document.find(a).map(function(){var a=d(this);return d("<div>").css("position","absolute").appendTo(a.parent()).outerWidth(a.outerWidth()).outerHeight(a.outerHeight()).offset(a.offset())[0]})},_unblockFrames:function(){this.iframeBlocks&&(this.iframeBlocks.remove(),delete this.iframeBlocks)},_blurActiveElement:function(a){var b=d.ui.safeActiveElement(this.document[0]);d(a.target).closest(b).length||d.ui.safeBlur(b)},
_mouseStart:function(a){var b=this.options;this.helper=this._createHelper(a);this._addClass(this.helper,"ui-draggable-dragging");this._cacheHelperProportions();d.ui.ddmanager&&(d.ui.ddmanager.current=this);this._cacheMargins();this.cssPosition=this.helper.css("position");this.scrollParent=this.helper.scrollParent(!0);this.offsetParent=this.helper.offsetParent();this.hasFixedAncestor=0<this.helper.parents().filter(function(){return"fixed"===d(this).css("position")}).length;this.positionAbs=this.element.offset();
this._refreshOffsets(a);this.originalPosition=this.position=this._generatePosition(a,!1);this.originalPageX=a.pageX;this.originalPageY=a.pageY;b.cursorAt&&this._adjustOffsetFromHelper(b.cursorAt);this._setContainment();if(!1===this._trigger("start",a))return this._clear(),!1;this._cacheHelperProportions();d.ui.ddmanager&&!b.dropBehaviour&&d.ui.ddmanager.prepareOffsets(this,a);this._mouseDrag(a,!0);d.ui.ddmanager&&d.ui.ddmanager.dragStart(this,a);return!0},_refreshOffsets:function(a){this.offset={top:this.positionAbs.top-
this.margins.top,left:this.positionAbs.left-this.margins.left,scroll:!1,parent:this._getParentOffset(),relative:this._getRelativeOffset()};this.offset.click={left:a.pageX-this.offset.left,top:a.pageY-this.offset.top}},_mouseDrag:function(a,b){this.hasFixedAncestor&&(this.offset.parent=this._getParentOffset());this.position=this._generatePosition(a,!0);this.positionAbs=this._convertPositionTo("absolute");if(!b){b=this._uiHash();if(!1===this._trigger("drag",a,b))return this._mouseUp(new d.Event("mouseup",
a)),!1;this.position=b.position}this.helper[0].style.left=this.position.left+"px";this.helper[0].style.top=this.position.top+"px";d.ui.ddmanager&&d.ui.ddmanager.drag(this,a);return!1},_mouseStop:function(a){var b=this,c=!1;d.ui.ddmanager&&!this.options.dropBehaviour&&(c=d.ui.ddmanager.drop(this,a));this.dropped&&(c=this.dropped,this.dropped=!1);"invalid"===this.options.revert&&!c||"valid"===this.options.revert&&c||!0===this.options.revert||"function"===typeof this.options.revert&&this.options.revert.call(this.element,
c)?d(this.helper).animate(this.originalPosition,parseInt(this.options.revertDuration,10),function(){!1!==b._trigger("stop",a)&&b._clear()}):!1!==this._trigger("stop",a)&&this._clear();return!1},_mouseUp:function(a){this._unblockFrames();d.ui.ddmanager&&d.ui.ddmanager.dragStop(this,a);this.handleElement.is(a.target)&&this.element.trigger("focus");return d.ui.mouse.prototype._mouseUp.call(this,a)},cancel:function(){this.helper.is(".ui-draggable-dragging")?this._mouseUp(new d.Event("mouseup",{target:this.element[0]})):
this._clear();return this},_getHandle:function(a){return this.options.handle?!!d(a.target).closest(this.element.find(this.options.handle)).length:!0},_setHandleClassName:function(){this.handleElement=this.options.handle?this.element.find(this.options.handle):this.element;this._addClass(this.handleElement,"ui-draggable-handle")},_removeHandleClassName:function(){this._removeClass(this.handleElement,"ui-draggable-handle")},_createHelper:function(a){var b=this.options,c="function"===typeof b.helper;
a=c?d(b.helper.apply(this.element[0],[a])):"clone"===b.helper?this.element.clone().removeAttr("id"):this.element;a.parents("body").length||a.appendTo("parent"===b.appendTo?this.element[0].parentNode:b.appendTo);c&&a[0]===this.element[0]&&this._setPositionRelative();a[0]===this.element[0]||/(fixed|absolute)/.test(a.css("position"))||a.css("position","absolute");return a},_setPositionRelative:function(){/^(?:r|a|f)/.test(this.element.css("position"))||(this.element[0].style.position="relative")},_adjustOffsetFromHelper:function(a){"string"===
typeof a&&(a=a.split(" "));Array.isArray(a)&&(a={left:+a[0],top:+a[1]||0});"left"in a&&(this.offset.click.left=a.left+this.margins.left);"right"in a&&(this.offset.click.left=this.helperProportions.width-a.right+this.margins.left);"top"in a&&(this.offset.click.top=a.top+this.margins.top);"bottom"in a&&(this.offset.click.top=this.helperProportions.height-a.bottom+this.margins.top)},_isRootNode:function(a){return/(html|body)/i.test(a.tagName)||a===this.document[0]},_getParentOffset:function(){var a=
this.offsetParent.offset(),b=this.document[0];"absolute"===this.cssPosition&&this.scrollParent[0]!==b&&d.contains(this.scrollParent[0],this.offsetParent[0])&&(a.left+=this.scrollParent.scrollLeft(),a.top+=this.scrollParent.scrollTop());this._isRootNode(this.offsetParent[0])&&(a={top:0,left:0});return{top:a.top+(parseInt(this.offsetParent.css("borderTopWidth"),10)||0),left:a.left+(parseInt(this.offsetParent.css("borderLeftWidth"),10)||0)}},_getRelativeOffset:function(){if("relative"!==this.cssPosition)return{top:0,
left:0};var a=this.element.position(),b=this._isRootNode(this.scrollParent[0]);return{top:a.top-(parseInt(this.helper.css("top"),10)||0)+(b?0:this.scrollParent.scrollTop()),left:a.left-(parseInt(this.helper.css("left"),10)||0)+(b?0:this.scrollParent.scrollLeft())}},_cacheMargins:function(){this.margins={left:parseInt(this.element.css("marginLeft"),10)||0,top:parseInt(this.element.css("marginTop"),10)||0,right:parseInt(this.element.css("marginRight"),10)||0,bottom:parseInt(this.element.css("marginBottom"),
10)||0}},_cacheHelperProportions:function(){this.helperProportions={width:this.helper.outerWidth(),height:this.helper.outerHeight()}},_setContainment:function(){var a;var b=this.options;var c=this.document[0];this.relativeContainer=null;if(b.containment)if("window"===b.containment)this.containment=[d(window).scrollLeft()-this.offset.relative.left-this.offset.parent.left,d(window).scrollTop()-this.offset.relative.top-this.offset.parent.top,d(window).scrollLeft()+d(window).width()-this.helperProportions.width-
this.margins.left,d(window).scrollTop()+(d(window).height()||c.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top];else if("document"===b.containment)this.containment=[0,0,d(c).width()-this.helperProportions.width-this.margins.left,(d(c).height()||c.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top];else if(b.containment.constructor===Array)this.containment=b.containment;else{if("parent"===b.containment&&(b.containment=this.helper[0].parentNode),
c=d(b.containment),a=c[0])b=/(scroll|auto)/.test(c.css("overflow")),this.containment=[(parseInt(c.css("borderLeftWidth"),10)||0)+(parseInt(c.css("paddingLeft"),10)||0),(parseInt(c.css("borderTopWidth"),10)||0)+(parseInt(c.css("paddingTop"),10)||0),(b?Math.max(a.scrollWidth,a.offsetWidth):a.offsetWidth)-(parseInt(c.css("borderRightWidth"),10)||0)-(parseInt(c.css("paddingRight"),10)||0)-this.helperProportions.width-this.margins.left-this.margins.right,(b?Math.max(a.scrollHeight,a.offsetHeight):a.offsetHeight)-
(parseInt(c.css("borderBottomWidth"),10)||0)-(parseInt(c.css("paddingBottom"),10)||0)-this.helperProportions.height-this.margins.top-this.margins.bottom],this.relativeContainer=c}else this.containment=null},_convertPositionTo:function(a,b){b||(b=this.position);a="absolute"===a?1:-1;var c=this._isRootNode(this.scrollParent[0]);return{top:b.top+this.offset.relative.top*a+this.offset.parent.top*a-("fixed"===this.cssPosition?-this.offset.scroll.top:c?0:this.offset.scroll.top)*a,left:b.left+this.offset.relative.left*
a+this.offset.parent.left*a-("fixed"===this.cssPosition?-this.offset.scroll.left:c?0:this.offset.scroll.left)*a}},_generatePosition:function(a,b){var c=this.options,d=this._isRootNode(this.scrollParent[0]);var f=a.pageX;var g=a.pageY;d&&this.offset.scroll||(this.offset.scroll={top:this.scrollParent.scrollTop(),left:this.scrollParent.scrollLeft()});if(b){if(this.containment){if(this.relativeContainer){var h=this.relativeContainer.offset();h=[this.containment[0]+h.left,this.containment[1]+h.top,this.containment[2]+
h.left,this.containment[3]+h.top]}else h=this.containment;a.pageX-this.offset.click.left<h[0]&&(f=h[0]+this.offset.click.left);a.pageY-this.offset.click.top<h[1]&&(g=h[1]+this.offset.click.top);a.pageX-this.offset.click.left>h[2]&&(f=h[2]+this.offset.click.left);a.pageY-this.offset.click.top>h[3]&&(g=h[3]+this.offset.click.top)}c.grid&&(g=c.grid[1]?this.originalPageY+Math.round((g-this.originalPageY)/c.grid[1])*c.grid[1]:this.originalPageY,g=h?g-this.offset.click.top>=h[1]||g-this.offset.click.top>
h[3]?g:g-this.offset.click.top>=h[1]?g-c.grid[1]:g+c.grid[1]:g,f=c.grid[0]?this.originalPageX+Math.round((f-this.originalPageX)/c.grid[0])*c.grid[0]:this.originalPageX,f=h?f-this.offset.click.left>=h[0]||f-this.offset.click.left>h[2]?f:f-this.offset.click.left>=h[0]?f-c.grid[0]:f+c.grid[0]:f);"y"===c.axis&&(f=this.originalPageX);"x"===c.axis&&(g=this.originalPageY)}return{top:g-this.offset.click.top-this.offset.relative.top-this.offset.parent.top+("fixed"===this.cssPosition?-this.offset.scroll.top:
d?0:this.offset.scroll.top),left:f-this.offset.click.left-this.offset.relative.left-this.offset.parent.left+("fixed"===this.cssPosition?-this.offset.scroll.left:d?0:this.offset.scroll.left)}},_clear:function(){this._removeClass(this.helper,"ui-draggable-dragging");this.helper[0]===this.element[0]||this.cancelHelperRemoval||this.helper.remove();this.helper=null;this.cancelHelperRemoval=!1;this.destroyOnClear&&this.destroy()},_trigger:function(a,b,c){c=c||this._uiHash();d.ui.plugin.call(this,a,[b,c,
this],!0);/^(drag|start|stop)/.test(a)&&(this.positionAbs=this._convertPositionTo("absolute"),c.offset=this.positionAbs);return d.Widget.prototype._trigger.call(this,a,b,c)},plugins:{},_uiHash:function(){return{helper:this.helper,position:this.position,originalPosition:this.originalPosition,offset:this.positionAbs}}});d.ui.plugin.add("draggable","connectToSortable",{start:function(a,b,c){var e=d.extend({},b,{item:c.element});c.sortables=[];d(c.options.connectToSortable).each(function(){var b=d(this).sortable("instance");
b&&!b.options.disabled&&(c.sortables.push(b),b.refreshPositions(),b._trigger("activate",a,e))})},stop:function(a,b,c){var e=d.extend({},b,{item:c.element});c.cancelHelperRemoval=!1;d.each(c.sortables,function(){this.isOver?(this.isOver=0,c.cancelHelperRemoval=!0,this.cancelHelperRemoval=!1,this._storedCSS={position:this.placeholder.css("position"),top:this.placeholder.css("top"),left:this.placeholder.css("left")},this._mouseStop(a),this.options.helper=this.options._helper):(this.cancelHelperRemoval=
!0,this._trigger("deactivate",a,e))})},drag:function(a,b,c){d.each(c.sortables,function(){var e=!1,f=this;f.positionAbs=c.positionAbs;f.helperProportions=c.helperProportions;f.offset.click=c.offset.click;f._intersectsWith(f.containerCache)&&(e=!0,d.each(c.sortables,function(){this.positionAbs=c.positionAbs;this.helperProportions=c.helperProportions;this.offset.click=c.offset.click;this!==f&&this._intersectsWith(this.containerCache)&&d.contains(f.element[0],this.element[0])&&(e=!1);return e}));e?(f.isOver||
(f.isOver=1,c._parent=b.helper.parent(),f.currentItem=b.helper.appendTo(f.element).data("ui-sortable-item",!0),f.options._helper=f.options.helper,f.options.helper=function(){return b.helper[0]},a.target=f.currentItem[0],f._mouseCapture(a,!0),f._mouseStart(a,!0,!0),f.offset.click.top=c.offset.click.top,f.offset.click.left=c.offset.click.left,f.offset.parent.left-=c.offset.parent.left-f.offset.parent.left,f.offset.parent.top-=c.offset.parent.top-f.offset.parent.top,c._trigger("toSortable",a),c.dropped=
f.element,d.each(c.sortables,function(){this.refreshPositions()}),c.currentItem=c.element,f.fromOutside=c),f.currentItem&&(f._mouseDrag(a),b.position=f.position)):f.isOver&&(f.isOver=0,f.cancelHelperRemoval=!0,f.options._revert=f.options.revert,f.options.revert=!1,f._trigger("out",a,f._uiHash(f)),f._mouseStop(a,!0),f.options.revert=f.options._revert,f.options.helper=f.options._helper,f.placeholder&&f.placeholder.remove(),b.helper.appendTo(c._parent),c._refreshOffsets(a),b.position=c._generatePosition(a,
!0),c._trigger("fromSortable",a),c.dropped=!1,d.each(c.sortables,function(){this.refreshPositions()}))})}});d.ui.plugin.add("draggable","cursor",{start:function(a,b,c){a=d("body");c=c.options;a.css("cursor")&&(c._cursor=a.css("cursor"));a.css("cursor",c.cursor)},stop:function(a,b,c){a=c.options;a._cursor&&d("body").css("cursor",a._cursor)}});d.ui.plugin.add("draggable","opacity",{start:function(a,b,c){a=d(b.helper);c=c.options;a.css("opacity")&&(c._opacity=a.css("opacity"));a.css("opacity",c.opacity)},
stop:function(a,b,c){a=c.options;a._opacity&&d(b.helper).css("opacity",a._opacity)}});d.ui.plugin.add("draggable","scroll",{start:function(a,b,c){c.scrollParentNotHidden||(c.scrollParentNotHidden=c.helper.scrollParent(!1));c.scrollParentNotHidden[0]!==c.document[0]&&"HTML"!==c.scrollParentNotHidden[0].tagName&&(c.overflowOffset=c.scrollParentNotHidden.offset())},drag:function(a,b,c){b=c.options;var e=!1,f=c.scrollParentNotHidden[0],g=c.document[0];f!==g&&"HTML"!==f.tagName?(b.axis&&"x"===b.axis||
(c.overflowOffset.top+f.offsetHeight-a.pageY<b.scrollSensitivity?f.scrollTop=e=f.scrollTop+b.scrollSpeed:a.pageY-c.overflowOffset.top<b.scrollSensitivity&&(f.scrollTop=e=f.scrollTop-b.scrollSpeed)),b.axis&&"y"===b.axis||(c.overflowOffset.left+f.offsetWidth-a.pageX<b.scrollSensitivity?f.scrollLeft=e=f.scrollLeft+b.scrollSpeed:a.pageX-c.overflowOffset.left<b.scrollSensitivity&&(f.scrollLeft=e=f.scrollLeft-b.scrollSpeed))):(b.axis&&"x"===b.axis||(a.pageY-d(g).scrollTop()<b.scrollSensitivity?e=d(g).scrollTop(d(g).scrollTop()-
b.scrollSpeed):d(window).height()-(a.pageY-d(g).scrollTop())<b.scrollSensitivity&&(e=d(g).scrollTop(d(g).scrollTop()+b.scrollSpeed))),b.axis&&"y"===b.axis||(a.pageX-d(g).scrollLeft()<b.scrollSensitivity?e=d(g).scrollLeft(d(g).scrollLeft()-b.scrollSpeed):d(window).width()-(a.pageX-d(g).scrollLeft())<b.scrollSensitivity&&(e=d(g).scrollLeft(d(g).scrollLeft()+b.scrollSpeed))));!1!==e&&d.ui.ddmanager&&!b.dropBehaviour&&d.ui.ddmanager.prepareOffsets(c,a)}});d.ui.plugin.add("draggable","snap",{start:function(a,
b,c){a=c.options;c.snapElements=[];d(a.snap.constructor!==String?a.snap.items||":data(ui-draggable)":a.snap).each(function(){var a=d(this),b=a.offset();this!==c.element[0]&&c.snapElements.push({item:this,width:a.outerWidth(),height:a.outerHeight(),top:b.top,left:b.left})})},drag:function(a,b,c){var e,f=c.options,g=f.snapTolerance,h=b.offset.left,k=h+c.helperProportions.width,l=b.offset.top,m=l+c.helperProportions.height;for(e=c.snapElements.length-1;0<=e;e--){var n=c.snapElements[e].left-c.margins.left;
var p=n+c.snapElements[e].width;var v=c.snapElements[e].top-c.margins.top;var y=v+c.snapElements[e].height;if(k<n-g||h>p+g||m<v-g||l>y+g||!d.contains(c.snapElements[e].item.ownerDocument,c.snapElements[e].item))c.snapElements[e].snapping&&c.options.snap.release&&c.options.snap.release.call(c.element,a,d.extend(c._uiHash(),{snapItem:c.snapElements[e].item})),c.snapElements[e].snapping=!1;else{if("inner"!==f.snapMode){var q=Math.abs(v-m)<=g;var r=Math.abs(y-l)<=g;var t=Math.abs(n-k)<=g;var w=Math.abs(p-
h)<=g;q&&(b.position.top=c._convertPositionTo("relative",{top:v-c.helperProportions.height,left:0}).top);r&&(b.position.top=c._convertPositionTo("relative",{top:y,left:0}).top);t&&(b.position.left=c._convertPositionTo("relative",{top:0,left:n-c.helperProportions.width}).left);w&&(b.position.left=c._convertPositionTo("relative",{top:0,left:p}).left)}var x=q||r||t||w;"outer"!==f.snapMode&&(q=Math.abs(v-l)<=g,r=Math.abs(y-m)<=g,t=Math.abs(n-h)<=g,w=Math.abs(p-k)<=g,q&&(b.position.top=c._convertPositionTo("relative",
{top:v,left:0}).top),r&&(b.position.top=c._convertPositionTo("relative",{top:y-c.helperProportions.height,left:0}).top),t&&(b.position.left=c._convertPositionTo("relative",{top:0,left:n}).left),w&&(b.position.left=c._convertPositionTo("relative",{top:0,left:p-c.helperProportions.width}).left));!c.snapElements[e].snapping&&(q||r||t||w||x)&&c.options.snap.snap&&c.options.snap.snap.call(c.element,a,d.extend(c._uiHash(),{snapItem:c.snapElements[e].item}));c.snapElements[e].snapping=q||r||t||w||x}}}});
d.ui.plugin.add("draggable","stack",{start:function(a,b,c){a=d.makeArray(d(c.options.stack)).sort(function(a,b){return(parseInt(d(a).css("zIndex"),10)||0)-(parseInt(d(b).css("zIndex"),10)||0)});if(a.length){var e=parseInt(d(a[0]).css("zIndex"),10)||0;d(a).each(function(a){d(this).css("zIndex",e+a)});this.css("zIndex",e+a.length)}}});d.ui.plugin.add("draggable","zIndex",{start:function(a,b,c){a=d(b.helper);c=c.options;a.css("zIndex")&&(c._zIndex=a.css("zIndex"));a.css("zIndex",c.zIndex)},stop:function(a,
b,c){a=c.options;a._zIndex&&d(b.helper).css("zIndex",a._zIndex)}});d.widget("ui.droppable",{version:"1.13.2",widgetEventPrefix:"drop",options:{accept:"*",addClasses:!0,greedy:!1,scope:"default",tolerance:"intersect",activate:null,deactivate:null,drop:null,out:null,over:null},_create:function(){var a,b=this.options,c=b.accept;this.isover=!1;this.isout=!0;this.accept="function"===typeof c?c:function(a){return a.is(c)};this.proportions=function(){if(arguments.length)a=arguments[0];else return a?a:a=
{width:this.element[0].offsetWidth,height:this.element[0].offsetHeight}};this._addToManager(b.scope);b.addClasses&&this._addClass("ui-droppable")},_addToManager:function(a){d.ui.ddmanager.droppables[a]=d.ui.ddmanager.droppables[a]||[];d.ui.ddmanager.droppables[a].push(this)},_splice:function(a){for(var b=0;b<a.length;b++)a[b]===this&&a.splice(b,1)},_destroy:function(){this._splice(d.ui.ddmanager.droppables[this.options.scope])},_setOption:function(a,b){"accept"===a?this.accept="function"===typeof b?
b:function(a){return a.is(b)}:"scope"===a&&(this._splice(d.ui.ddmanager.droppables[this.options.scope]),this._addToManager(b));this._super(a,b)},_activate:function(a){var b=d.ui.ddmanager.current;this._addActiveClass();b&&this._trigger("activate",a,this.ui(b))},_deactivate:function(a){var b=d.ui.ddmanager.current;this._removeActiveClass();b&&this._trigger("deactivate",a,this.ui(b))},_over:function(a){var b=d.ui.ddmanager.current;b&&(b.currentItem||b.element)[0]!==this.element[0]&&this.accept.call(this.element[0],
b.currentItem||b.element)&&(this._addHoverClass(),this._trigger("over",a,this.ui(b)))},_out:function(a){var b=d.ui.ddmanager.current;b&&(b.currentItem||b.element)[0]!==this.element[0]&&this.accept.call(this.element[0],b.currentItem||b.element)&&(this._removeHoverClass(),this._trigger("out",a,this.ui(b)))},_drop:function(a,b){var c=b||d.ui.ddmanager.current,e=!1;if(!c||(c.currentItem||c.element)[0]===this.element[0])return!1;this.element.find(":data(ui-droppable)").not(".ui-draggable-dragging").each(function(){var b=
d(this).droppable("instance");if(b.options.greedy&&!b.options.disabled&&b.options.scope===c.options.scope&&b.accept.call(b.element[0],c.currentItem||c.element)&&d.ui.intersect(c,d.extend(b,{offset:b.element.offset()}),b.options.tolerance,a))return e=!0,!1});return e?!1:this.accept.call(this.element[0],c.currentItem||c.element)?(this._removeActiveClass(),this._removeHoverClass(),this._trigger("drop",a,this.ui(c)),this.element):!1},ui:function(a){return{draggable:a.currentItem||a.element,helper:a.helper,
position:a.position,offset:a.positionAbs}},_addHoverClass:function(){this._addClass("ui-droppable-hover")},_removeHoverClass:function(){this._removeClass("ui-droppable-hover")},_addActiveClass:function(){this._addClass("ui-droppable-active")},_removeActiveClass:function(){this._removeClass("ui-droppable-active")}});d.ui.intersect=function(){return function(a,b,c,d){if(!b.offset)return!1;var e=(a.positionAbs||a.position.absolute).left+a.margins.left,g=(a.positionAbs||a.position.absolute).top+a.margins.top,
h=e+a.helperProportions.width,k=g+a.helperProportions.height,l=b.offset.left,m=b.offset.top,n=l+b.proportions().width,p=m+b.proportions().height;switch(c){case "fit":return l<=e&&h<=n&&m<=g&&k<=p;case "intersect":return l<e+a.helperProportions.width/2&&h-a.helperProportions.width/2<n&&m<g+a.helperProportions.height/2&&k-a.helperProportions.height/2<p;case "pointer":a=d.pageY;c=b.proportions().height;if(m=a>=m&&a<m+c)d=d.pageX,b=b.proportions().width,m=d>=l&&d<l+b;return m;case "touch":return(g>=m&&
g<=p||k>=m&&k<=p||g<m&&k>p)&&(e>=l&&e<=n||h>=l&&h<=n||e<l&&h>n);default:return!1}}}();d.ui.ddmanager={current:null,droppables:{"default":[]},prepareOffsets:function(a,b){var c,e=d.ui.ddmanager.droppables[a.options.scope]||[],f=b?b.type:null,g=(a.currentItem||a.element).find(":data(ui-droppable)").addBack();var h=0;a:for(;h<e.length;h++)if(!(e[h].options.disabled||a&&!e[h].accept.call(e[h].element[0],a.currentItem||a.element))){for(c=0;c<g.length;c++)if(g[c]===e[h].element[0]){e[h].proportions().height=
0;continue a}e[h].visible="none"!==e[h].element.css("display");e[h].visible&&("mousedown"===f&&e[h]._activate.call(e[h],b),e[h].offset=e[h].element.offset(),e[h].proportions({width:e[h].element[0].offsetWidth,height:e[h].element[0].offsetHeight}))}},drop:function(a,b){var c=!1;d.each((d.ui.ddmanager.droppables[a.options.scope]||[]).slice(),function(){this.options&&(!this.options.disabled&&this.visible&&d.ui.intersect(a,this,this.options.tolerance,b)&&(c=this._drop.call(this,b)||c),!this.options.disabled&&
this.visible&&this.accept.call(this.element[0],a.currentItem||a.element)&&(this.isout=!0,this.isover=!1,this._deactivate.call(this,b)))});return c},dragStart:function(a,b){a.element.parentsUntil("body").on("scroll.droppable",function(){a.options.refreshPositions||d.ui.ddmanager.prepareOffsets(a,b)})},drag:function(a,b){a.options.refreshPositions&&d.ui.ddmanager.prepareOffsets(a,b);d.each(d.ui.ddmanager.droppables[a.options.scope]||[],function(){if(!this.options.disabled&&!this.greedyChild&&this.visible){var c=
d.ui.intersect(a,this,this.options.tolerance,b);var e=!c&&this.isover?"isout":c&&!this.isover?"isover":null;if(e){if(this.options.greedy){var f=this.options.scope;c=this.element.parents(":data(ui-droppable)").filter(function(){return d(this).droppable("instance").options.scope===f});if(c.length){var g=d(c[0]).droppable("instance");g.greedyChild="isover"===e}}g&&"isover"===e&&(g.isover=!1,g.isout=!0,g._out.call(g,b));this[e]=!0;this["isout"===e?"isover":"isout"]=!1;this["isover"===e?"_over":"_out"].call(this,
b);g&&"isout"===e&&(g.isout=!1,g.isover=!0,g._over.call(g,b))}}})},dragStop:function(a,b){a.element.parentsUntil("body").off("scroll.droppable");a.options.refreshPositions||d.ui.ddmanager.prepareOffsets(a,b)}};!1!==d.uiBackCompat&&d.widget("ui.droppable",d.ui.droppable,{options:{hoverClass:!1,activeClass:!1},_addActiveClass:function(){this._super();this.options.activeClass&&this.element.addClass(this.options.activeClass)},_removeActiveClass:function(){this._super();this.options.activeClass&&this.element.removeClass(this.options.activeClass)},
_addHoverClass:function(){this._super();this.options.hoverClass&&this.element.addClass(this.options.hoverClass)},_removeHoverClass:function(){this._super();this.options.hoverClass&&this.element.removeClass(this.options.hoverClass)}});d.widget("ui.resizable",d.ui.mouse,{version:"1.13.2",widgetEventPrefix:"resize",options:{alsoResize:!1,animate:!1,animateDuration:"slow",animateEasing:"swing",aspectRatio:!1,autoHide:!1,classes:{"ui-resizable-se":"ui-icon ui-icon-gripsmall-diagonal-se"},containment:!1,
ghost:!1,grid:!1,handles:"e,s,se",helper:!1,maxHeight:null,maxWidth:null,minHeight:10,minWidth:10,zIndex:90,resize:null,start:null,stop:null},_num:function(a){return parseFloat(a)||0},_isNumber:function(a){return!isNaN(parseFloat(a))},_hasScroll:function(a,b){if("hidden"===d(a).css("overflow"))return!1;b=b&&"left"===b?"scrollLeft":"scrollTop";var c=!1;if(0<a[b])return!0;try{a[b]=1,c=0<a[b],a[b]=0}catch(e){}return c},_create:function(){var a=this.options,b=this;this._addClass("ui-resizable");d.extend(this,
{_aspectRatio:!!a.aspectRatio,aspectRatio:a.aspectRatio,originalElement:this.element,_proportionallyResizeElements:[],_helper:a.helper||a.ghost||a.animate?a.helper||"ui-resizable-helper":null});if(this.element[0].nodeName.match(/^(canvas|textarea|input|select|button|img)$/i)){this.element.wrap(d("<div class='ui-wrapper'></div>").css({overflow:"hidden",position:this.element.css("position"),width:this.element.outerWidth(),height:this.element.outerHeight(),top:this.element.css("top"),left:this.element.css("left")}));
this.element=this.element.parent().data("ui-resizable",this.element.resizable("instance"));this.elementIsWrapper=!0;var c={marginTop:this.originalElement.css("marginTop"),marginRight:this.originalElement.css("marginRight"),marginBottom:this.originalElement.css("marginBottom"),marginLeft:this.originalElement.css("marginLeft")};this.element.css(c);this.originalElement.css("margin",0);this.originalResizeStyle=this.originalElement.css("resize");this.originalElement.css("resize","none");this._proportionallyResizeElements.push(this.originalElement.css({position:"static",
zoom:1,display:"block"}));this.originalElement.css(c);this._proportionallyResize()}this._setupHandles();if(a.autoHide)d(this.element).on("mouseenter",function(){a.disabled||(b._removeClass("ui-resizable-autohide"),b._handles.show())}).on("mouseleave",function(){a.disabled||b.resizing||(b._addClass("ui-resizable-autohide"),b._handles.hide())});this._mouseInit()},_destroy:function(){this._mouseDestroy();this._addedHandles.remove();var a=function(a){d(a).removeData("resizable").removeData("ui-resizable").off(".resizable")};
if(this.elementIsWrapper){a(this.element);var b=this.element;this.originalElement.css({position:b.css("position"),width:b.outerWidth(),height:b.outerHeight(),top:b.css("top"),left:b.css("left")}).insertAfter(b);b.remove()}this.originalElement.css("resize",this.originalResizeStyle);a(this.originalElement);return this},_setOption:function(a,b){this._super(a,b);switch(a){case "handles":this._removeHandles();this._setupHandles();break;case "aspectRatio":this._aspectRatio=!!b}},_setupHandles:function(){var a=
this.options,b,c=this;this.handles=a.handles||(d(".ui-resizable-handle",this.element).length?{n:".ui-resizable-n",e:".ui-resizable-e",s:".ui-resizable-s",w:".ui-resizable-w",se:".ui-resizable-se",sw:".ui-resizable-sw",ne:".ui-resizable-ne",nw:".ui-resizable-nw"}:"e,s,se");this._handles=d();this._addedHandles=d();if(this.handles.constructor===String){"all"===this.handles&&(this.handles="n,e,s,w,se,sw,ne,nw");var e=this.handles.split(",");this.handles={};for(b=0;b<e.length;b++){var f=String.prototype.trim.call(e[b]);
var g="ui-resizable-"+f;var h=d("<div>");this._addClass(h,"ui-resizable-handle "+g);h.css({zIndex:a.zIndex});this.handles[f]=".ui-resizable-"+f;this.element.children(this.handles[f]).length||(this.element.append(h),this._addedHandles=this._addedHandles.add(h))}}this._renderAxis=function(a){var b;a=a||this.element;for(b in this.handles){if(this.handles[b].constructor===String)this.handles[b]=this.element.children(this.handles[b]).first().show();else if(this.handles[b].jquery||this.handles[b].nodeType)this.handles[b]=
d(this.handles[b]),this._on(this.handles[b],{mousedown:c._mouseDown});if(this.elementIsWrapper&&this.originalElement[0].nodeName.match(/^(textarea|input|select|button)$/i)){var e=d(this.handles[b],this.element);var f=/sw|ne|nw|se|n|s/.test(b)?e.outerHeight():e.outerWidth();e=["padding",/ne|nw|n/.test(b)?"Top":/se|sw|s/.test(b)?"Bottom":/^e$/.test(b)?"Right":"Left"].join("");a.css(e,f);this._proportionallyResize()}this._handles=this._handles.add(this.handles[b])}};this._renderAxis(this.element);this._handles=
this._handles.add(this.element.find(".ui-resizable-handle"));this._handles.disableSelection();this._handles.on("mouseover",function(){c.resizing||(this.className&&(h=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i)),c.axis=h&&h[1]?h[1]:"se")});a.autoHide&&(this._handles.hide(),this._addClass("ui-resizable-autohide"))},_removeHandles:function(){this._addedHandles.remove()},_mouseCapture:function(a){var b,c=!1;for(b in this.handles){var e=d(this.handles[b])[0];if(e===a.target||d.contains(e,
a.target))c=!0}return!this.options.disabled&&c},_mouseStart:function(a){var b=this.options,c=this.element;this.resizing=!0;this._renderProxy();var e=this._num(this.helper.css("left"));var f=this._num(this.helper.css("top"));b.containment&&(e+=d(b.containment).scrollLeft()||0,f+=d(b.containment).scrollTop()||0);this.offset=this.helper.offset();this.position={left:e,top:f};this.size=this._helper?{width:this.helper.width(),height:this.helper.height()}:{width:c.width(),height:c.height()};this.originalSize=
this._helper?{width:c.outerWidth(),height:c.outerHeight()}:{width:c.width(),height:c.height()};this.sizeDiff={width:c.outerWidth()-c.width(),height:c.outerHeight()-c.height()};this.originalPosition={left:e,top:f};this.originalMousePosition={left:a.pageX,top:a.pageY};this.aspectRatio="number"===typeof b.aspectRatio?b.aspectRatio:this.originalSize.width/this.originalSize.height||1;e=d(".ui-resizable-"+this.axis).css("cursor");d("body").css("cursor","auto"===e?this.axis+"-resize":e);this._addClass("ui-resizable-resizing");
this._propagate("start",a);return!0},_mouseDrag:function(a){var b=this.originalMousePosition;var c=a.pageX-b.left||0;b=a.pageY-b.top||0;var e=this._change[this.axis];this._updatePrevProperties();if(!e)return!1;c=e.apply(this,[a,c,b]);this._updateVirtualBoundaries(a.shiftKey);if(this._aspectRatio||a.shiftKey)c=this._updateRatio(c,a);c=this._respectSize(c,a);this._updateCache(c);this._propagate("resize",a);c=this._applyChanges();!this._helper&&this._proportionallyResizeElements.length&&this._proportionallyResize();
d.isEmptyObject(c)||(this._updatePrevProperties(),this._trigger("resize",a,this.ui()),this._applyChanges());return!1},_mouseStop:function(a){this.resizing=!1;var b,c=this.options;if(this._helper){var e=this._proportionallyResizeElements;e=(b=e.length&&/textarea/i.test(e[0].nodeName))&&this._hasScroll(e[0],"left")?0:this.sizeDiff.height;b=b?0:this.sizeDiff.width;b={width:this.helper.width()-b,height:this.helper.height()-e};e=parseFloat(this.element.css("left"))+(this.position.left-this.originalPosition.left)||
null;var f=parseFloat(this.element.css("top"))+(this.position.top-this.originalPosition.top)||null;c.animate||this.element.css(d.extend(b,{top:f,left:e}));this.helper.height(this.size.height);this.helper.width(this.size.width);this._helper&&!c.animate&&this._proportionallyResize()}d("body").css("cursor","auto");this._removeClass("ui-resizable-resizing");this._propagate("stop",a);this._helper&&this.helper.remove();return!1},_updatePrevProperties:function(){this.prevPosition={top:this.position.top,
left:this.position.left};this.prevSize={width:this.size.width,height:this.size.height}},_applyChanges:function(){var a={};this.position.top!==this.prevPosition.top&&(a.top=this.position.top+"px");this.position.left!==this.prevPosition.left&&(a.left=this.position.left+"px");this.size.width!==this.prevSize.width&&(a.width=this.size.width+"px");this.size.height!==this.prevSize.height&&(a.height=this.size.height+"px");this.helper.css(a);return a},_updateVirtualBoundaries:function(a){var b=this.options;
b={minWidth:this._isNumber(b.minWidth)?b.minWidth:0,maxWidth:this._isNumber(b.maxWidth)?b.maxWidth:Infinity,minHeight:this._isNumber(b.minHeight)?b.minHeight:0,maxHeight:this._isNumber(b.maxHeight)?b.maxHeight:Infinity};if(this._aspectRatio||a){a=b.minHeight*this.aspectRatio;var c=b.minWidth/this.aspectRatio;var d=b.maxHeight*this.aspectRatio;var f=b.maxWidth/this.aspectRatio;a>b.minWidth&&(b.minWidth=a);c>b.minHeight&&(b.minHeight=c);d<b.maxWidth&&(b.maxWidth=d);f<b.maxHeight&&(b.maxHeight=f)}this._vBoundaries=
b},_updateCache:function(a){this.offset=this.helper.offset();this._isNumber(a.left)&&(this.position.left=a.left);this._isNumber(a.top)&&(this.position.top=a.top);this._isNumber(a.height)&&(this.size.height=a.height);this._isNumber(a.width)&&(this.size.width=a.width)},_updateRatio:function(a){var b=this.position,c=this.size,d=this.axis;this._isNumber(a.height)?a.width=a.height*this.aspectRatio:this._isNumber(a.width)&&(a.height=a.width/this.aspectRatio);"sw"===d&&(a.left=b.left+(c.width-a.width),a.top=
null);"nw"===d&&(a.top=b.top+(c.height-a.height),a.left=b.left+(c.width-a.width));return a},_respectSize:function(a){var b=this._vBoundaries,c=this.axis,d=this._isNumber(a.width)&&b.maxWidth&&b.maxWidth<a.width,f=this._isNumber(a.height)&&b.maxHeight&&b.maxHeight<a.height,g=this._isNumber(a.width)&&b.minWidth&&b.minWidth>a.width,h=this._isNumber(a.height)&&b.minHeight&&b.minHeight>a.height,k=this.originalPosition.left+this.originalSize.width,l=this.originalPosition.top+this.originalSize.height,m=
/sw|nw|w/.test(c);c=/nw|ne|n/.test(c);g&&(a.width=b.minWidth);h&&(a.height=b.minHeight);d&&(a.width=b.maxWidth);f&&(a.height=b.maxHeight);g&&m&&(a.left=k-b.minWidth);d&&m&&(a.left=k-b.maxWidth);h&&c&&(a.top=l-b.minHeight);f&&c&&(a.top=l-b.maxHeight);a.width||a.height||a.left||!a.top?a.width||a.height||a.top||!a.left||(a.left=null):a.top=null;return a},_getPaddingPlusBorderDimensions:function(a){var b=0,c=[],d=[a.css("borderTopWidth"),a.css("borderRightWidth"),a.css("borderBottomWidth"),a.css("borderLeftWidth")];
for(a=[a.css("paddingTop"),a.css("paddingRight"),a.css("paddingBottom"),a.css("paddingLeft")];4>b;b++)c[b]=parseFloat(d[b])||0,c[b]+=parseFloat(a[b])||0;return{height:c[0]+c[2],width:c[1]+c[3]}},_proportionallyResize:function(){if(this._proportionallyResizeElements.length)for(var a,b=0,c=this.helper||this.element;b<this._proportionallyResizeElements.length;b++)a=this._proportionallyResizeElements[b],this.outerDimensions||(this.outerDimensions=this._getPaddingPlusBorderDimensions(a)),a.css({height:c.height()-
this.outerDimensions.height||0,width:c.width()-this.outerDimensions.width||0})},_renderProxy:function(){var a=this.options;this.elementOffset=this.element.offset();this._helper?(this.helper=this.helper||d("<div></div>").css({overflow:"hidden"}),this._addClass(this.helper,this._helper),this.helper.css({width:this.element.outerWidth(),height:this.element.outerHeight(),position:"absolute",left:this.elementOffset.left+"px",top:this.elementOffset.top+"px",zIndex:++a.zIndex}),this.helper.appendTo("body").disableSelection()):
this.helper=this.element},_change:{e:function(a,b){return{width:this.originalSize.width+b}},w:function(a,b){return{left:this.originalPosition.left+b,width:this.originalSize.width-b}},n:function(a,b,c){return{top:this.originalPosition.top+c,height:this.originalSize.height-c}},s:function(a,b,c){return{height:this.originalSize.height+c}},se:function(a,b,c){return d.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[a,b,c]))},sw:function(a,b,c){return d.extend(this._change.s.apply(this,
arguments),this._change.w.apply(this,[a,b,c]))},ne:function(a,b,c){return d.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[a,b,c]))},nw:function(a,b,c){return d.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[a,b,c]))}},_propagate:function(a,b){d.ui.plugin.call(this,a,[b,this.ui()]);"resize"!==a&&this._trigger(a,b,this.ui())},plugins:{},ui:function(){return{originalElement:this.originalElement,element:this.element,helper:this.helper,position:this.position,
size:this.size,originalSize:this.originalSize,originalPosition:this.originalPosition}}});d.ui.plugin.add("resizable","animate",{stop:function(a){var b=d(this).resizable("instance"),c=b.options,e=b._proportionallyResizeElements,f=e.length&&/textarea/i.test(e[0].nodeName),g=f&&b._hasScroll(e[0],"left")?0:b.sizeDiff.height;f={width:b.size.width-(f?0:b.sizeDiff.width),height:b.size.height-g};g=parseFloat(b.element.css("left"))+(b.position.left-b.originalPosition.left)||null;var h=parseFloat(b.element.css("top"))+
(b.position.top-b.originalPosition.top)||null;b.element.animate(d.extend(f,h&&g?{top:h,left:g}:{}),{duration:c.animateDuration,easing:c.animateEasing,step:function(){var c={width:parseFloat(b.element.css("width")),height:parseFloat(b.element.css("height")),top:parseFloat(b.element.css("top")),left:parseFloat(b.element.css("left"))};e&&e.length&&d(e[0]).css({width:c.width,height:c.height});b._updateCache(c);b._propagate("resize",a)}})}});d.ui.plugin.add("resizable","containment",{start:function(){var a=
d(this).resizable("instance"),b=a.element;var c=a.options.containment;if(b=c instanceof d?c.get(0):/parent/.test(c)?b.parent().get(0):c)if(a.containerElement=d(b),/document/.test(c)||c===document)a.containerOffset={left:0,top:0},a.containerPosition={left:0,top:0},a.parentData={element:d(document),left:0,top:0,width:d(document).width(),height:d(document).height()||document.body.parentNode.scrollHeight};else{var e=d(b);var f=[];d(["Top","Right","Left","Bottom"]).each(function(b,c){f[b]=a._num(e.css("padding"+
c))});a.containerOffset=e.offset();a.containerPosition=e.position();a.containerSize={height:e.innerHeight()-f[3],width:e.innerWidth()-f[1]};c=a.containerOffset;var g=a.containerSize.height;var h=a.containerSize.width;h=a._hasScroll(b,"left")?b.scrollWidth:h;g=a._hasScroll(b)?b.scrollHeight:g;a.parentData={element:b,left:c.left,top:c.top,width:h,height:g}}},resize:function(a){var b=d(this).resizable("instance");var c=b.options;var e=b.containerOffset;var f=b.position;a=b._aspectRatio||a.shiftKey;var g=
{top:0,left:0},h=b.containerElement,k=!0;h[0]!==document&&/static/.test(h.css("position"))&&(g=e);f.left<(b._helper?e.left:0)&&(b.size.width+=b._helper?b.position.left-e.left:b.position.left-g.left,a&&(b.size.height=b.size.width/b.aspectRatio,k=!1),b.position.left=c.helper?e.left:0);f.top<(b._helper?e.top:0)&&(b.size.height+=b._helper?b.position.top-e.top:b.position.top,a&&(b.size.width=b.size.height*b.aspectRatio,k=!1),b.position.top=b._helper?e.top:0);c=b.containerElement.get(0)===b.element.parent().get(0);
f=/relative|absolute/.test(b.containerElement.css("position"));c&&f?(b.offset.left=b.parentData.left+b.position.left,b.offset.top=b.parentData.top+b.position.top):(b.offset.left=b.element.offset().left,b.offset.top=b.element.offset().top);c=Math.abs(b.sizeDiff.width+(b._helper?b.offset.left-g.left:b.offset.left-e.left));e=Math.abs(b.sizeDiff.height+(b._helper?b.offset.top-g.top:b.offset.top-e.top));c+b.size.width>=b.parentData.width&&(b.size.width=b.parentData.width-c,a&&(b.size.height=b.size.width/
b.aspectRatio,k=!1));e+b.size.height>=b.parentData.height&&(b.size.height=b.parentData.height-e,a&&(b.size.width=b.size.height*b.aspectRatio,k=!1));k||(b.position.left=b.prevPosition.left,b.position.top=b.prevPosition.top,b.size.width=b.prevSize.width,b.size.height=b.prevSize.height)},stop:function(){var a=d(this).resizable("instance"),b=a.options,c=a.containerOffset,e=a.containerPosition,f=a.containerElement,g=d(a.helper),h=g.offset(),k=g.outerWidth()-a.sizeDiff.width;g=g.outerHeight()-a.sizeDiff.height;
a._helper&&!b.animate&&/relative/.test(f.css("position"))&&d(this).css({left:h.left-e.left-c.left,width:k,height:g});a._helper&&!b.animate&&/static/.test(f.css("position"))&&d(this).css({left:h.left-e.left-c.left,width:k,height:g})}});d.ui.plugin.add("resizable","alsoResize",{start:function(){var a=d(this).resizable("instance").options;d(a.alsoResize).each(function(){var a=d(this);a.data("ui-resizable-alsoresize",{width:parseFloat(a.width()),height:parseFloat(a.height()),left:parseFloat(a.css("left")),
top:parseFloat(a.css("top"))})})},resize:function(a,b){a=d(this).resizable("instance");var c=a.originalSize,e=a.originalPosition,f={height:a.size.height-c.height||0,width:a.size.width-c.width||0,top:a.position.top-e.top||0,left:a.position.left-e.left||0};d(a.options.alsoResize).each(function(){var a=d(this),c=d(this).data("ui-resizable-alsoresize"),e={},l=a.parents(b.originalElement[0]).length?["width","height"]:["width","height","top","left"];d.each(l,function(a,b){(a=(c[b]||0)+(f[b]||0))&&0<=a&&
(e[b]=a||null)});a.css(e)})},stop:function(){d(this).removeData("ui-resizable-alsoresize")}});d.ui.plugin.add("resizable","ghost",{start:function(){var a=d(this).resizable("instance"),b=a.size;a.ghost=a.originalElement.clone();a.ghost.css({opacity:.25,display:"block",position:"relative",height:b.height,width:b.width,margin:0,left:0,top:0});a._addClass(a.ghost,"ui-resizable-ghost");!1!==d.uiBackCompat&&"string"===typeof a.options.ghost&&a.ghost.addClass(this.options.ghost);a.ghost.appendTo(a.helper)},
resize:function(){var a=d(this).resizable("instance");a.ghost&&a.ghost.css({position:"relative",height:a.size.height,width:a.size.width})},stop:function(){var a=d(this).resizable("instance");a.ghost&&a.helper&&a.helper.get(0).removeChild(a.ghost.get(0))}});d.ui.plugin.add("resizable","grid",{resize:function(){var a=d(this).resizable("instance"),b=a.options,c=a.size,e=a.originalSize,f=a.originalPosition,g=a.axis,h="number"===typeof b.grid?[b.grid,b.grid]:b.grid,k=h[0]||1,l=h[1]||1,m=Math.round((c.width-
e.width)/k)*k;c=Math.round((c.height-e.height)/l)*l;var n=e.width+m,p=e.height+c,v=b.maxWidth&&b.maxWidth<n,y=b.maxHeight&&b.maxHeight<p,q=b.minWidth&&b.minWidth>n,r=b.minHeight&&b.minHeight>p;b.grid=h;q&&(n+=k);r&&(p+=l);v&&(n-=k);y&&(p-=l);if(/^(se|s|e)$/.test(g))a.size.width=n,a.size.height=p;else if(/^(ne)$/.test(g))a.size.width=n,a.size.height=p,a.position.top=f.top-c;else if(/^(sw)$/.test(g))a.size.width=n,a.size.height=p,a.position.left=f.left-m;else{if(0>=p-l||0>=n-k)var t=a._getPaddingPlusBorderDimensions(this);
0<p-l?(a.size.height=p,a.position.top=f.top-c):(p=l-t.height,a.size.height=p,a.position.top=f.top+e.height-p);0<n-k?(a.size.width=n,a.position.left=f.left-m):(n=k-t.width,a.size.width=n,a.position.left=f.left+e.width-n)}}});d.widget("ui.sortable",d.ui.mouse,{version:"1.13.2",widgetEventPrefix:"sort",ready:!1,options:{appendTo:"parent",axis:!1,connectWith:!1,containment:!1,cursor:"auto",cursorAt:!1,dropOnEmpty:!0,forcePlaceholderSize:!1,forceHelperSize:!1,grid:!1,handle:!1,helper:"original",items:"> *",
opacity:!1,placeholder:!1,revert:!1,scroll:!0,scrollSensitivity:20,scrollSpeed:20,scope:"default",tolerance:"intersect",zIndex:1E3,activate:null,beforeStop:null,change:null,deactivate:null,out:null,over:null,receive:null,remove:null,sort:null,start:null,stop:null,update:null},_isOverAxis:function(a,b,c){return a>=b&&a<b+c},_isFloating:function(a){return/left|right/.test(a.css("float"))||/inline|table-cell/.test(a.css("display"))},_create:function(){this.containerCache={};this._addClass("ui-sortable");
this.refresh();this.offset=this.element.offset();this._mouseInit();this._setHandleClassName();this.ready=!0},_setOption:function(a,b){this._super(a,b);"handle"===a&&this._setHandleClassName()},_setHandleClassName:function(){var a=this;this._removeClass(this.element.find(".ui-sortable-handle"),"ui-sortable-handle");d.each(this.items,function(){a._addClass(this.instance.options.handle?this.item.find(this.instance.options.handle):this.item,"ui-sortable-handle")})},_destroy:function(){this._mouseDestroy();
for(var a=this.items.length-1;0<=a;a--)this.items[a].item.removeData(this.widgetName+"-item");return this},_mouseCapture:function(a,b){var c=null,e=!1,f=this;if(this.reverting||this.options.disabled||"static"===this.options.type)return!1;this._refreshItems(a);d(a.target).parents().each(function(){if(d.data(this,f.widgetName+"-item")===f)return c=d(this),!1});d.data(a.target,f.widgetName+"-item")===f&&(c=d(a.target));if(!c||this.options.handle&&!b&&(d(this.options.handle,c).find("*").addBack().each(function(){this===
a.target&&(e=!0)}),!e))return!1;this.currentItem=c;this._removeCurrentsFromItems();return!0},_mouseStart:function(a,b,c){b=this.options;this.currentContainer=this;this.refreshPositions();this.appendTo=d("parent"!==b.appendTo?b.appendTo:this.currentItem.parent());this.helper=this._createHelper(a);this._cacheHelperProportions();this._cacheMargins();this.offset=this.currentItem.offset();this.offset={top:this.offset.top-this.margins.top,left:this.offset.left-this.margins.left};d.extend(this.offset,{click:{left:a.pageX-
this.offset.left,top:a.pageY-this.offset.top},relative:this._getRelativeOffset()});this.helper.css("position","absolute");this.cssPosition=this.helper.css("position");b.cursorAt&&this._adjustOffsetFromHelper(b.cursorAt);this.domPosition={prev:this.currentItem.prev()[0],parent:this.currentItem.parent()[0]};this.helper[0]!==this.currentItem[0]&&this.currentItem.hide();this._createPlaceholder();this.scrollParent=this.placeholder.scrollParent();d.extend(this.offset,{parent:this._getParentOffset()});b.containment&&
this._setContainment();if(b.cursor&&"auto"!==b.cursor){var e=this.document.find("body");this.storedCursor=e.css("cursor");e.css("cursor",b.cursor);this.storedStylesheet=d("<style>*{ cursor: "+b.cursor+" !important; }</style>").appendTo(e)}b.zIndex&&(this.helper.css("zIndex")&&(this._storedZIndex=this.helper.css("zIndex")),this.helper.css("zIndex",b.zIndex));b.opacity&&(this.helper.css("opacity")&&(this._storedOpacity=this.helper.css("opacity")),this.helper.css("opacity",b.opacity));this.scrollParent[0]!==
this.document[0]&&"HTML"!==this.scrollParent[0].tagName&&(this.overflowOffset=this.scrollParent.offset());this._trigger("start",a,this._uiHash());this._preserveHelperProportions||this._cacheHelperProportions();if(!c)for(c=this.containers.length-1;0<=c;c--)this.containers[c]._trigger("activate",a,this._uiHash(this));d.ui.ddmanager&&(d.ui.ddmanager.current=this);d.ui.ddmanager&&!b.dropBehaviour&&d.ui.ddmanager.prepareOffsets(this,a);this.dragging=!0;this._addClass(this.helper,"ui-sortable-helper");
this.helper.parent().is(this.appendTo)||(this.helper.detach().appendTo(this.appendTo),this.offset.parent=this._getParentOffset());this.position=this.originalPosition=this._generatePosition(a);this.originalPageX=a.pageX;this.originalPageY=a.pageY;this.lastPositionAbs=this.positionAbs=this._convertPositionTo("absolute");this._mouseDrag(a);return!0},_scroll:function(a){var b=this.options,c=!1;this.scrollParent[0]!==this.document[0]&&"HTML"!==this.scrollParent[0].tagName?(this.overflowOffset.top+this.scrollParent[0].offsetHeight-
a.pageY<b.scrollSensitivity?this.scrollParent[0].scrollTop=c=this.scrollParent[0].scrollTop+b.scrollSpeed:a.pageY-this.overflowOffset.top<b.scrollSensitivity&&(this.scrollParent[0].scrollTop=c=this.scrollParent[0].scrollTop-b.scrollSpeed),this.overflowOffset.left+this.scrollParent[0].offsetWidth-a.pageX<b.scrollSensitivity?this.scrollParent[0].scrollLeft=c=this.scrollParent[0].scrollLeft+b.scrollSpeed:a.pageX-this.overflowOffset.left<b.scrollSensitivity&&(this.scrollParent[0].scrollLeft=c=this.scrollParent[0].scrollLeft-
b.scrollSpeed)):(a.pageY-this.document.scrollTop()<b.scrollSensitivity?c=this.document.scrollTop(this.document.scrollTop()-b.scrollSpeed):this.window.height()-(a.pageY-this.document.scrollTop())<b.scrollSensitivity&&(c=this.document.scrollTop(this.document.scrollTop()+b.scrollSpeed)),a.pageX-this.document.scrollLeft()<b.scrollSensitivity?c=this.document.scrollLeft(this.document.scrollLeft()-b.scrollSpeed):this.window.width()-(a.pageX-this.document.scrollLeft())<b.scrollSensitivity&&(c=this.document.scrollLeft(this.document.scrollLeft()+
b.scrollSpeed)));return c},_mouseDrag:function(a){var b;var c=this.options;this.position=this._generatePosition(a);this.positionAbs=this._convertPositionTo("absolute");this.options.axis&&"y"===this.options.axis||(this.helper[0].style.left=this.position.left+"px");this.options.axis&&"x"===this.options.axis||(this.helper[0].style.top=this.position.top+"px");c.scroll&&!1!==this._scroll(a)&&(this._refreshItemPositions(!0),d.ui.ddmanager&&!c.dropBehaviour&&d.ui.ddmanager.prepareOffsets(this,a));this.dragDirection=
{vertical:this._getDragVerticalDirection(),horizontal:this._getDragHorizontalDirection()};for(c=this.items.length-1;0<=c;c--){var e=this.items[c];var f=e.item[0];if((b=this._intersectsWithPointer(e))&&e.instance===this.currentContainer&&f!==this.currentItem[0]&&this.placeholder[1===b?"next":"prev"]()[0]!==f&&!d.contains(this.placeholder[0],f)&&("semi-dynamic"===this.options.type?!d.contains(this.element[0],f):1)){this.direction=1===b?"down":"up";if("pointer"===this.options.tolerance||this._intersectsWithSides(e))this._rearrange(a,
e);else break;this._trigger("change",a,this._uiHash());break}}this._contactContainers(a);d.ui.ddmanager&&d.ui.ddmanager.drag(this,a);this._trigger("sort",a,this._uiHash());this.lastPositionAbs=this.positionAbs;return!1},_mouseStop:function(a,b){if(a){d.ui.ddmanager&&!this.options.dropBehaviour&&d.ui.ddmanager.drop(this,a);if(this.options.revert){var c=this;b=this.placeholder.offset();var e=this.options.axis,f={};e&&"x"!==e||(f.left=b.left-this.offset.parent.left-this.margins.left+(this.offsetParent[0]===
this.document[0].body?0:this.offsetParent[0].scrollLeft));e&&"y"!==e||(f.top=b.top-this.offset.parent.top-this.margins.top+(this.offsetParent[0]===this.document[0].body?0:this.offsetParent[0].scrollTop));this.reverting=!0;d(this.helper).animate(f,parseInt(this.options.revert,10)||500,function(){c._clear(a)})}else this._clear(a,b);return!1}},cancel:function(){if(this.dragging){this._mouseUp(new d.Event("mouseup",{target:null}));"original"===this.options.helper?(this.currentItem.css(this._storedCSS),
this._removeClass(this.currentItem,"ui-sortable-helper")):this.currentItem.show();for(var a=this.containers.length-1;0<=a;a--)this.containers[a]._trigger("deactivate",null,this._uiHash(this)),this.containers[a].containerCache.over&&(this.containers[a]._trigger("out",null,this._uiHash(this)),this.containers[a].containerCache.over=0)}this.placeholder&&(this.placeholder[0].parentNode&&this.placeholder[0].parentNode.removeChild(this.placeholder[0]),"original"!==this.options.helper&&this.helper&&this.helper[0].parentNode&&
this.helper.remove(),d.extend(this,{helper:null,dragging:!1,reverting:!1,_noFinalSort:null}),this.domPosition.prev?d(this.domPosition.prev).after(this.currentItem):d(this.domPosition.parent).prepend(this.currentItem));return this},serialize:function(a){var b=this._getItemsAsjQuery(a&&a.connected),c=[];a=a||{};d(b).each(function(){var b=(d(a.item||this).attr(a.attribute||"id")||"").match(a.expression||/(.+)[\-=_](.+)/);b&&c.push((a.key||b[1]+"[]")+"="+(a.key&&a.expression?b[1]:b[2]))});!c.length&&
a.key&&c.push(a.key+"=");return c.join("&")},toArray:function(a){var b=this._getItemsAsjQuery(a&&a.connected),c=[];a=a||{};b.each(function(){c.push(d(a.item||this).attr(a.attribute||"id")||"")});return c},_intersectsWith:function(a){var b=this.positionAbs.left,c=b+this.helperProportions.width,d=this.positionAbs.top,f=d+this.helperProportions.height,g=a.left,h=g+a.width,k=a.top,l=k+a.height,m=this.offset.click.top,n=this.offset.click.left;m="x"===this.options.axis||d+m>k&&d+m<l;n="y"===this.options.axis||
b+n>g&&b+n<h;return"pointer"===this.options.tolerance||this.options.forcePointerForContainers||"pointer"!==this.options.tolerance&&this.helperProportions[this.floating?"width":"height"]>a[this.floating?"width":"height"]?m&&n:g<b+this.helperProportions.width/2&&c-this.helperProportions.width/2<h&&k<d+this.helperProportions.height/2&&f-this.helperProportions.height/2<l},_intersectsWithPointer:function(a){var b="x"===this.options.axis||this._isOverAxis(this.positionAbs.top+this.offset.click.top,a.top,
a.height);a="y"===this.options.axis||this._isOverAxis(this.positionAbs.left+this.offset.click.left,a.left,a.width);if(!b||!a)return!1;b=this.dragDirection.vertical;a=this.dragDirection.horizontal;return this.floating?"right"===a||"down"===b?2:1:b&&("down"===b?2:1)},_intersectsWithSides:function(a){var b=this._isOverAxis(this.positionAbs.top+this.offset.click.top,a.top+a.height/2,a.height);a=this._isOverAxis(this.positionAbs.left+this.offset.click.left,a.left+a.width/2,a.width);var c=this.dragDirection.vertical,
d=this.dragDirection.horizontal;return this.floating&&d?"right"===d&&a||"left"===d&&!a:c&&("down"===c&&b||"up"===c&&!b)},_getDragVerticalDirection:function(){var a=this.positionAbs.top-this.lastPositionAbs.top;return 0!==a&&(0<a?"down":"up")},_getDragHorizontalDirection:function(){var a=this.positionAbs.left-this.lastPositionAbs.left;return 0!==a&&(0<a?"right":"left")},refresh:function(a){this._refreshItems(a);this._setHandleClassName();this.refreshPositions();return this},_connectWith:function(){var a=
this.options;return a.connectWith.constructor===String?[a.connectWith]:a.connectWith},_getItemsAsjQuery:function(a){function b(){f.push(this)}var c,e,f=[],g=[],h=this._connectWith();if(h&&a)for(a=h.length-1;0<=a;a--){var k=d(h[a],this.document[0]);for(c=k.length-1;0<=c;c--)(e=d.data(k[c],this.widgetFullName))&&e!==this&&!e.options.disabled&&g.push(["function"===typeof e.options.items?e.options.items.call(e.element):d(e.options.items,e.element).not(".ui-sortable-helper").not(".ui-sortable-placeholder"),
e])}g.push(["function"===typeof this.options.items?this.options.items.call(this.element,null,{options:this.options,item:this.currentItem}):d(this.options.items,this.element).not(".ui-sortable-helper").not(".ui-sortable-placeholder"),this]);for(a=g.length-1;0<=a;a--)g[a][0].each(b);return d(f)},_removeCurrentsFromItems:function(){var a=this.currentItem.find(":data("+this.widgetName+"-item)");this.items=d.grep(this.items,function(b){for(var c=0;c<a.length;c++)if(a[c]===b.item[0])return!1;return!0})},
_refreshItems:function(a){this.items=[];this.containers=[this];var b,c,e,f,g=this.items,h=[["function"===typeof this.options.items?this.options.items.call(this.element[0],a,{item:this.currentItem}):d(this.options.items,this.element),this]];if((f=this._connectWith())&&this.ready)for(b=f.length-1;0<=b;b--){var k=d(f[b],this.document[0]);for(c=k.length-1;0<=c;c--)(e=d.data(k[c],this.widgetFullName))&&e!==this&&!e.options.disabled&&(h.push(["function"===typeof e.options.items?e.options.items.call(e.element[0],
a,{item:this.currentItem}):d(e.options.items,e.element),e]),this.containers.push(e))}for(b=h.length-1;0<=b;b--)for(a=h[b][1],k=h[b][0],c=0,f=k.length;c<f;c++)e=d(k[c]),e.data(this.widgetName+"-item",a),g.push({item:e,instance:a,width:0,height:0,left:0,top:0})},_refreshItemPositions:function(a){var b;for(b=this.items.length-1;0<=b;b--){var c=this.items[b];if(!this.currentContainer||c.instance===this.currentContainer||c.item[0]===this.currentItem[0]){var e=this.options.toleranceElement?d(this.options.toleranceElement,
c.item):c.item;a||(c.width=e.outerWidth(),c.height=e.outerHeight());e=e.offset();c.left=e.left;c.top=e.top}}},refreshPositions:function(a){this.floating=this.items.length?"x"===this.options.axis||this._isFloating(this.items[0].item):!1;this.offsetParent&&this.helper&&(this.offset.parent=this._getParentOffset());this._refreshItemPositions(a);if(this.options.custom&&this.options.custom.refreshContainers)this.options.custom.refreshContainers.call(this);else for(a=this.containers.length-1;0<=a;a--){var b=
this.containers[a].element.offset();this.containers[a].containerCache.left=b.left;this.containers[a].containerCache.top=b.top;this.containers[a].containerCache.width=this.containers[a].element.outerWidth();this.containers[a].containerCache.height=this.containers[a].element.outerHeight()}return this},_createPlaceholder:function(a){a=a||this;var b=a.options;if(!b.placeholder||b.placeholder.constructor===String){var c=b.placeholder;var e=a.currentItem[0].nodeName.toLowerCase();b.placeholder={element:function(){var b=
d("<"+e+">",a.document[0]);a._addClass(b,"ui-sortable-placeholder",c||a.currentItem[0].className)._removeClass(b,"ui-sortable-helper");"tbody"===e?a._createTrPlaceholder(a.currentItem.find("tr").eq(0),d("<tr>",a.document[0]).appendTo(b)):"tr"===e?a._createTrPlaceholder(a.currentItem,b):"img"===e&&b.attr("src",a.currentItem.attr("src"));c||b.css("visibility","hidden");return b},update:function(d,g){if(!c||b.forcePlaceholderSize)g.height()&&(!b.forcePlaceholderSize||"tbody"!==e&&"tr"!==e)||g.height(a.currentItem.innerHeight()-
parseInt(a.currentItem.css("paddingTop")||0,10)-parseInt(a.currentItem.css("paddingBottom")||0,10)),g.width()||g.width(a.currentItem.innerWidth()-parseInt(a.currentItem.css("paddingLeft")||0,10)-parseInt(a.currentItem.css("paddingRight")||0,10))}}}a.placeholder=d(b.placeholder.element.call(a.element,a.currentItem));a.currentItem.after(a.placeholder);b.placeholder.update(a,a.placeholder)},_createTrPlaceholder:function(a,b){var c=this;a.children().each(function(){d("<td>&#160;</td>",c.document[0]).attr("colspan",
d(this).attr("colspan")||1).appendTo(b)})},_contactContainers:function(a){var b,c,e,f=e=null;for(b=this.containers.length-1;0<=b;b--)d.contains(this.currentItem[0],this.containers[b].element[0])||(this._intersectsWith(this.containers[b].containerCache)?e&&d.contains(this.containers[b].element[0],e.element[0])||(e=this.containers[b],f=b):this.containers[b].containerCache.over&&(this.containers[b]._trigger("out",a,this._uiHash(this)),this.containers[b].containerCache.over=0));if(e)if(1===this.containers.length)this.containers[f].containerCache.over||
(this.containers[f]._trigger("over",a,this._uiHash(this)),this.containers[f].containerCache.over=1);else{b=1E4;var g=null;e=(c=e.floating||this._isFloating(this.currentItem))?"left":"top";var h=c?"width":"height";var k=c?"pageX":"pageY";for(c=this.items.length-1;0<=c;c--)if(d.contains(this.containers[f].element[0],this.items[c].item[0])&&this.items[c].item[0]!==this.currentItem[0]){var l=this.items[c].item.offset()[e];var m=!1;a[k]-l>this.items[c][h]/2&&(m=!0);Math.abs(a[k]-l)<b&&(b=Math.abs(a[k]-
l),g=this.items[c],this.direction=m?"up":"down")}if(g||this.options.dropOnEmpty)this.currentContainer===this.containers[f]?this.currentContainer.containerCache.over||(this.containers[f]._trigger("over",a,this._uiHash()),this.currentContainer.containerCache.over=1):(g?this._rearrange(a,g,null,!0):this._rearrange(a,null,this.containers[f].element,!0),this._trigger("change",a,this._uiHash()),this.containers[f]._trigger("change",a,this._uiHash(this)),this.currentContainer=this.containers[f],this.options.placeholder.update(this.currentContainer,
this.placeholder),this.scrollParent=this.placeholder.scrollParent(),this.scrollParent[0]!==this.document[0]&&"HTML"!==this.scrollParent[0].tagName&&(this.overflowOffset=this.scrollParent.offset()),this.containers[f]._trigger("over",a,this._uiHash(this)),this.containers[f].containerCache.over=1)}},_createHelper:function(a){var b=this.options;a="function"===typeof b.helper?d(b.helper.apply(this.element[0],[a,this.currentItem])):"clone"===b.helper?this.currentItem.clone():this.currentItem;a.parents("body").length||
this.appendTo[0].appendChild(a[0]);a[0]===this.currentItem[0]&&(this._storedCSS={width:this.currentItem[0].style.width,height:this.currentItem[0].style.height,position:this.currentItem.css("position"),top:this.currentItem.css("top"),left:this.currentItem.css("left")});a[0].style.width&&!b.forceHelperSize||a.width(this.currentItem.width());a[0].style.height&&!b.forceHelperSize||a.height(this.currentItem.height());return a},_adjustOffsetFromHelper:function(a){"string"===typeof a&&(a=a.split(" "));Array.isArray(a)&&
(a={left:+a[0],top:+a[1]||0});"left"in a&&(this.offset.click.left=a.left+this.margins.left);"right"in a&&(this.offset.click.left=this.helperProportions.width-a.right+this.margins.left);"top"in a&&(this.offset.click.top=a.top+this.margins.top);"bottom"in a&&(this.offset.click.top=this.helperProportions.height-a.bottom+this.margins.top)},_getParentOffset:function(){this.offsetParent=this.helper.offsetParent();var a=this.offsetParent.offset();"absolute"===this.cssPosition&&this.scrollParent[0]!==this.document[0]&&
d.contains(this.scrollParent[0],this.offsetParent[0])&&(a.left+=this.scrollParent.scrollLeft(),a.top+=this.scrollParent.scrollTop());if(this.offsetParent[0]===this.document[0].body||this.offsetParent[0].tagName&&"html"===this.offsetParent[0].tagName.toLowerCase()&&d.ui.ie)a={top:0,left:0};return{top:a.top+(parseInt(this.offsetParent.css("borderTopWidth"),10)||0),left:a.left+(parseInt(this.offsetParent.css("borderLeftWidth"),10)||0)}},_getRelativeOffset:function(){if("relative"===this.cssPosition){var a=
this.currentItem.position();return{top:a.top-(parseInt(this.helper.css("top"),10)||0)+this.scrollParent.scrollTop(),left:a.left-(parseInt(this.helper.css("left"),10)||0)+this.scrollParent.scrollLeft()}}return{top:0,left:0}},_cacheMargins:function(){this.margins={left:parseInt(this.currentItem.css("marginLeft"),10)||0,top:parseInt(this.currentItem.css("marginTop"),10)||0}},_cacheHelperProportions:function(){this.helperProportions={width:this.helper.outerWidth(),height:this.helper.outerHeight()}},_setContainment:function(){var a=
this.options;"parent"===a.containment&&(a.containment=this.helper[0].parentNode);if("document"===a.containment||"window"===a.containment)this.containment=[0-this.offset.relative.left-this.offset.parent.left,0-this.offset.relative.top-this.offset.parent.top,"document"===a.containment?this.document.width():this.window.width()-this.helperProportions.width-this.margins.left,("document"===a.containment?this.document.height()||document.body.parentNode.scrollHeight:this.window.height()||this.document[0].body.parentNode.scrollHeight)-
this.helperProportions.height-this.margins.top];if(!/^(document|window|parent)$/.test(a.containment)){var b=d(a.containment)[0];a=d(a.containment).offset();var c="hidden"!==d(b).css("overflow");this.containment=[a.left+(parseInt(d(b).css("borderLeftWidth"),10)||0)+(parseInt(d(b).css("paddingLeft"),10)||0)-this.margins.left,a.top+(parseInt(d(b).css("borderTopWidth"),10)||0)+(parseInt(d(b).css("paddingTop"),10)||0)-this.margins.top,a.left+(c?Math.max(b.scrollWidth,b.offsetWidth):b.offsetWidth)-(parseInt(d(b).css("borderLeftWidth"),
10)||0)-(parseInt(d(b).css("paddingRight"),10)||0)-this.helperProportions.width-this.margins.left,a.top+(c?Math.max(b.scrollHeight,b.offsetHeight):b.offsetHeight)-(parseInt(d(b).css("borderTopWidth"),10)||0)-(parseInt(d(b).css("paddingBottom"),10)||0)-this.helperProportions.height-this.margins.top]}},_convertPositionTo:function(a,b){b||(b=this.position);a="absolute"===a?1:-1;var c="absolute"!==this.cssPosition||this.scrollParent[0]!==this.document[0]&&d.contains(this.scrollParent[0],this.offsetParent[0])?
this.scrollParent:this.offsetParent,e=/(html|body)/i.test(c[0].tagName);return{top:b.top+this.offset.relative.top*a+this.offset.parent.top*a-("fixed"===this.cssPosition?-this.scrollParent.scrollTop():e?0:c.scrollTop())*a,left:b.left+this.offset.relative.left*a+this.offset.parent.left*a-("fixed"===this.cssPosition?-this.scrollParent.scrollLeft():e?0:c.scrollLeft())*a}},_generatePosition:function(a){var b=this.options;var c=a.pageX;var e=a.pageY;var f="absolute"!==this.cssPosition||this.scrollParent[0]!==
this.document[0]&&d.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent,g=/(html|body)/i.test(f[0].tagName);"relative"!==this.cssPosition||this.scrollParent[0]!==this.document[0]&&this.scrollParent[0]!==this.offsetParent[0]||(this.offset.relative=this._getRelativeOffset());this.originalPosition&&(this.containment&&(a.pageX-this.offset.click.left<this.containment[0]&&(c=this.containment[0]+this.offset.click.left),a.pageY-this.offset.click.top<this.containment[1]&&
(e=this.containment[1]+this.offset.click.top),a.pageX-this.offset.click.left>this.containment[2]&&(c=this.containment[2]+this.offset.click.left),a.pageY-this.offset.click.top>this.containment[3]&&(e=this.containment[3]+this.offset.click.top)),b.grid&&(e=this.originalPageY+Math.round((e-this.originalPageY)/b.grid[1])*b.grid[1],e=this.containment?e-this.offset.click.top>=this.containment[1]&&e-this.offset.click.top<=this.containment[3]?e:e-this.offset.click.top>=this.containment[1]?e-b.grid[1]:e+b.grid[1]:
e,c=this.originalPageX+Math.round((c-this.originalPageX)/b.grid[0])*b.grid[0],c=this.containment?c-this.offset.click.left>=this.containment[0]&&c-this.offset.click.left<=this.containment[2]?c:c-this.offset.click.left>=this.containment[0]?c-b.grid[0]:c+b.grid[0]:c));return{top:e-this.offset.click.top-this.offset.relative.top-this.offset.parent.top+("fixed"===this.cssPosition?-this.scrollParent.scrollTop():g?0:f.scrollTop()),left:c-this.offset.click.left-this.offset.relative.left-this.offset.parent.left+
("fixed"===this.cssPosition?-this.scrollParent.scrollLeft():g?0:f.scrollLeft())}},_rearrange:function(a,b,c,d){c?c[0].appendChild(this.placeholder[0]):b.item[0].parentNode.insertBefore(this.placeholder[0],"down"===this.direction?b.item[0]:b.item[0].nextSibling);var e=this.counter=this.counter?++this.counter:1;this._delay(function(){e===this.counter&&this.refreshPositions(!d)})},_clear:function(a,b){function c(a,b,c){return function(d){c._trigger(a,d,b._uiHash(b))}}this.reverting=!1;var d,f=[];!this._noFinalSort&&
this.currentItem.parent().length&&this.placeholder.before(this.currentItem);this._noFinalSort=null;if(this.helper[0]===this.currentItem[0]){for(d in this._storedCSS)if("auto"===this._storedCSS[d]||"static"===this._storedCSS[d])this._storedCSS[d]="";this.currentItem.css(this._storedCSS);this._removeClass(this.currentItem,"ui-sortable-helper")}else this.currentItem.show();this.fromOutside&&!b&&f.push(function(a){this._trigger("receive",a,this._uiHash(this.fromOutside))});!this.fromOutside&&this.domPosition.prev===
this.currentItem.prev().not(".ui-sortable-helper")[0]&&this.domPosition.parent===this.currentItem.parent()[0]||b||f.push(function(a){this._trigger("update",a,this._uiHash())});this===this.currentContainer||b||(f.push(function(a){this._trigger("remove",a,this._uiHash())}),f.push(function(a){return function(b){a._trigger("receive",b,this._uiHash(this))}}.call(this,this.currentContainer)),f.push(function(a){return function(b){a._trigger("update",b,this._uiHash(this))}}.call(this,this.currentContainer)));
for(d=this.containers.length-1;0<=d;d--)b||f.push(c("deactivate",this,this.containers[d])),this.containers[d].containerCache.over&&(f.push(c("out",this,this.containers[d])),this.containers[d].containerCache.over=0);this.storedCursor&&(this.document.find("body").css("cursor",this.storedCursor),this.storedStylesheet.remove());this._storedOpacity&&this.helper.css("opacity",this._storedOpacity);this._storedZIndex&&this.helper.css("zIndex","auto"===this._storedZIndex?"":this._storedZIndex);this.dragging=
!1;b||this._trigger("beforeStop",a,this._uiHash());this.placeholder[0].parentNode.removeChild(this.placeholder[0]);this.cancelHelperRemoval||(this.helper[0]!==this.currentItem[0]&&this.helper.remove(),this.helper=null);if(!b){for(d=0;d<f.length;d++)f[d].call(this,a);this._trigger("stop",a,this._uiHash())}this.fromOutside=!1;return!this.cancelHelperRemoval},_trigger:function(){!1===d.Widget.prototype._trigger.apply(this,arguments)&&this.cancel()},_uiHash:function(a){var b=a||this;return{helper:b.helper,
placeholder:b.placeholder||d([]),position:b.position,originalPosition:b.originalPosition,offset:b.positionAbs,item:b.currentItem,sender:a?a.element:null}}});d.widget("ui.accordion",{version:"1.13.2",options:{active:0,animate:{},classes:{"ui-accordion-header":"ui-corner-top","ui-accordion-header-collapsed":"ui-corner-all","ui-accordion-content":"ui-corner-bottom"},collapsible:!1,event:"click",header:function(a){return a.find("> li > :first-child").add(a.find("> :not(li)").even())},heightStyle:"auto",
icons:{activeHeader:"ui-icon-triangle-1-s",header:"ui-icon-triangle-1-e"},activate:null,beforeActivate:null},hideProps:{borderTopWidth:"hide",borderBottomWidth:"hide",paddingTop:"hide",paddingBottom:"hide",height:"hide"},showProps:{borderTopWidth:"show",borderBottomWidth:"show",paddingTop:"show",paddingBottom:"show",height:"show"},_create:function(){var a=this.options;this.prevShow=this.prevHide=d();this._addClass("ui-accordion","ui-widget ui-helper-reset");this.element.attr("role","tablist");a.collapsible||
!1!==a.active&&null!=a.active||(a.active=0);this._processPanels();0>a.active&&(a.active+=this.headers.length);this._refresh()},_getCreateEventData:function(){return{header:this.active,panel:this.active.length?this.active.next():d()}},_createIcons:function(){var a=this.options.icons;if(a){var b=d("<span>");this._addClass(b,"ui-accordion-header-icon","ui-icon "+a.header);b.prependTo(this.headers);b=this.active.children(".ui-accordion-header-icon");this._removeClass(b,a.header)._addClass(b,null,a.activeHeader)._addClass(this.headers,
"ui-accordion-icons")}},_destroyIcons:function(){this._removeClass(this.headers,"ui-accordion-icons");this.headers.children(".ui-accordion-header-icon").remove()},_destroy:function(){this.element.removeAttr("role");this.headers.removeAttr("role aria-expanded aria-selected aria-controls tabIndex").removeUniqueId();this._destroyIcons();var a=this.headers.next().css("display","").removeAttr("role aria-hidden aria-labelledby").removeUniqueId();"content"!==this.options.heightStyle&&a.css("height","")},
_setOption:function(a,b){"active"===a?this._activate(b):("event"===a&&(this.options.event&&this._off(this.headers,this.options.event),this._setupEvents(b)),this._super(a,b),"collapsible"!==a||b||!1!==this.options.active||this._activate(0),"icons"===a&&(this._destroyIcons(),b&&this._createIcons()))},_setOptionDisabled:function(a){this._super(a);this.element.attr("aria-disabled",a);this._toggleClass(null,"ui-state-disabled",!!a);this._toggleClass(this.headers.add(this.headers.next()),null,"ui-state-disabled",
!!a)},_keydown:function(a){if(!a.altKey&&!a.ctrlKey){var b=d.ui.keyCode,c=this.headers.length,e=this.headers.index(a.target),f=!1;switch(a.keyCode){case b.RIGHT:case b.DOWN:f=this.headers[(e+1)%c];break;case b.LEFT:case b.UP:f=this.headers[(e-1+c)%c];break;case b.SPACE:case b.ENTER:this._eventHandler(a);break;case b.HOME:f=this.headers[0];break;case b.END:f=this.headers[c-1]}f&&(d(a.target).attr("tabIndex",-1),d(f).attr("tabIndex",0),d(f).trigger("focus"),a.preventDefault())}},_panelKeyDown:function(a){a.keyCode===
d.ui.keyCode.UP&&a.ctrlKey&&d(a.currentTarget).prev().trigger("focus")},refresh:function(){var a=this.options;this._processPanels();!1===a.active&&!0===a.collapsible||!this.headers.length?(a.active=!1,this.active=d()):!1===a.active?this._activate(0):this.active.length&&!d.contains(this.element[0],this.active[0])?this.headers.length===this.headers.find(".ui-state-disabled").length?(a.active=!1,this.active=d()):this._activate(Math.max(0,a.active-1)):a.active=this.headers.index(this.active);this._destroyIcons();
this._refresh()},_processPanels:function(){var a=this.headers,b=this.panels;this.headers="function"===typeof this.options.header?this.options.header(this.element):this.element.find(this.options.header);this._addClass(this.headers,"ui-accordion-header ui-accordion-header-collapsed","ui-state-default");this.panels=this.headers.next().filter(":not(.ui-accordion-content-active)").hide();this._addClass(this.panels,"ui-accordion-content","ui-helper-reset ui-widget-content");b&&(this._off(a.not(this.headers)),
this._off(b.not(this.panels)))},_refresh:function(){var a=this.options,b=a.heightStyle,c=this.element.parent();this.active=this._findActive(a.active);this._addClass(this.active,"ui-accordion-header-active","ui-state-active")._removeClass(this.active,"ui-accordion-header-collapsed");this._addClass(this.active.next(),"ui-accordion-content-active");this.active.next().show();this.headers.attr("role","tab").each(function(){var a=d(this),b=a.uniqueId().attr("id"),c=a.next(),e=c.uniqueId().attr("id");a.attr("aria-controls",
e);c.attr("aria-labelledby",b)}).next().attr("role","tabpanel");this.headers.not(this.active).attr({"aria-selected":"false","aria-expanded":"false",tabIndex:-1}).next().attr({"aria-hidden":"true"}).hide();this.active.length?this.active.attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0}).next().attr({"aria-hidden":"false"}):this.headers.eq(0).attr("tabIndex",0);this._createIcons();this._setupEvents(a.event);if("fill"===b){var e=c.height();this.element.siblings(":visible").each(function(){var a=
d(this),b=a.css("position");"absolute"!==b&&"fixed"!==b&&(e-=a.outerHeight(!0))});this.headers.each(function(){e-=d(this).outerHeight(!0)});this.headers.next().each(function(){d(this).height(Math.max(0,e-d(this).innerHeight()+d(this).height()))}).css("overflow","auto")}else"auto"===b&&(e=0,this.headers.next().each(function(){var a=d(this).is(":visible");a||d(this).show();e=Math.max(e,d(this).css("height","").height());a||d(this).hide()}).height(e))},_activate:function(a){a=this._findActive(a)[0];
a!==this.active[0]&&(a=a||this.active[0],this._eventHandler({target:a,currentTarget:a,preventDefault:d.noop}))},_findActive:function(a){return"number"===typeof a?this.headers.eq(a):d()},_setupEvents:function(a){var b={keydown:"_keydown"};a&&d.each(a.split(" "),function(a,d){b[d]="_eventHandler"});this._off(this.headers.add(this.headers.next()));this._on(this.headers,b);this._on(this.headers.next(),{keydown:"_panelKeyDown"});this._hoverable(this.headers);this._focusable(this.headers)},_eventHandler:function(a){var b,
c=this.options,e=this.active,f=d(a.currentTarget),g=(b=f[0]===e[0])&&c.collapsible,h=g?d():f.next(),k=e.next();h={oldHeader:e,oldPanel:k,newHeader:g?d():f,newPanel:h};a.preventDefault();b&&!c.collapsible||!1===this._trigger("beforeActivate",a,h)||(c.active=g?!1:this.headers.index(f),this.active=b?d():f,this._toggle(h),this._removeClass(e,"ui-accordion-header-active","ui-state-active"),c.icons&&(a=e.children(".ui-accordion-header-icon"),this._removeClass(a,null,c.icons.activeHeader)._addClass(a,null,
c.icons.header)),b||(this._removeClass(f,"ui-accordion-header-collapsed")._addClass(f,"ui-accordion-header-active","ui-state-active"),c.icons&&(b=f.children(".ui-accordion-header-icon"),this._removeClass(b,null,c.icons.header)._addClass(b,null,c.icons.activeHeader)),this._addClass(f.next(),"ui-accordion-content-active")))},_toggle:function(a){var b=a.newPanel,c=this.prevShow.length?this.prevShow:a.oldPanel;this.prevShow.add(this.prevHide).stop(!0,!0);this.prevShow=b;this.prevHide=c;this.options.animate?
this._animate(b,c,a):(c.hide(),b.show(),this._toggleComplete(a));c.attr({"aria-hidden":"true"});c.prev().attr({"aria-selected":"false","aria-expanded":"false"});b.length&&c.length?c.prev().attr({tabIndex:-1,"aria-expanded":"false"}):b.length&&this.headers.filter(function(){return 0===parseInt(d(this).attr("tabIndex"),10)}).attr("tabIndex",-1);b.attr("aria-hidden","false").prev().attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0})},_animate:function(a,b,c){var d,f,g=this,h=0,k=a.css("box-sizing"),
l=a.length&&(!b.length||a.index()<b.index()),m=this.options.animate||{};l=l&&m.down||m;var n=function(){g._toggleComplete(c)};"number"===typeof l&&(f=l);"string"===typeof l&&(d=l);d=d||l.easing||m.easing;f=f||l.duration||m.duration;if(!b.length)return a.animate(this.showProps,f,d,n);if(!a.length)return b.animate(this.hideProps,f,d,n);var p=a.show().outerHeight();b.animate(this.hideProps,{duration:f,easing:d,step:function(a,b){b.now=Math.round(a)}});a.hide().animate(this.showProps,{duration:f,easing:d,
complete:n,step:function(a,c){c.now=Math.round(a);"height"!==c.prop?"content-box"===k&&(h+=c.now):"content"!==g.options.heightStyle&&(c.now=Math.round(p-b.outerHeight()-h),h=0)}})},_toggleComplete:function(a){var b=a.oldPanel,c=b.prev();this._removeClass(b,"ui-accordion-content-active");this._removeClass(c,"ui-accordion-header-active")._addClass(c,"ui-accordion-header-collapsed");b.length&&(b.parent()[0].className=b.parent()[0].className);this._trigger("activate",null,a)}});d.widget("ui.menu",{version:"1.13.2",
defaultElement:"<ul>",delay:300,options:{icons:{submenu:"ui-icon-caret-1-e"},items:"> *",menus:"ul",position:{my:"left top",at:"right top"},role:"menu",blur:null,focus:null,select:null},_create:function(){this.activeMenu=this.element;this.mouseHandled=!1;this.lastMousePosition={x:null,y:null};this.element.uniqueId().attr({role:this.options.role,tabIndex:0});this._addClass("ui-menu","ui-widget ui-widget-content");this._on({"mousedown .ui-menu-item":function(a){a.preventDefault();this._activateItem(a)},
"click .ui-menu-item":function(a){var b=d(a.target),c=d(d.ui.safeActiveElement(this.document[0]));!this.mouseHandled&&b.not(".ui-state-disabled").length&&(this.select(a),a.isPropagationStopped()||(this.mouseHandled=!0),b.has(".ui-menu").length?this.expand(a):!this.element.is(":focus")&&c.closest(".ui-menu").length&&(this.element.trigger("focus",[!0]),this.active&&1===this.active.parents(".ui-menu").length&&clearTimeout(this.timer)))},"mouseenter .ui-menu-item":"_activateItem","mousemove .ui-menu-item":"_activateItem",
mouseleave:"collapseAll","mouseleave .ui-menu":"collapseAll",focus:function(a,b){var c=this.active||this._menuItems().first();b||this.focus(a,c)},blur:function(a){this._delay(function(){d.contains(this.element[0],d.ui.safeActiveElement(this.document[0]))||this.collapseAll(a)})},keydown:"_keydown"});this.refresh();this._on(this.document,{click:function(a){this._closeOnDocumentClick(a)&&this.collapseAll(a,!0);this.mouseHandled=!1}})},_activateItem:function(a){if(!this.previousFilter&&(a.clientX!==this.lastMousePosition.x||
a.clientY!==this.lastMousePosition.y)){this.lastMousePosition={x:a.clientX,y:a.clientY};var b=d(a.target).closest(".ui-menu-item"),c=d(a.currentTarget);b[0]!==c[0]||c.is(".ui-state-active")||(this._removeClass(c.siblings().children(".ui-state-active"),null,"ui-state-active"),this.focus(a,c))}},_destroy:function(){var a=this.element.find(".ui-menu-item").removeAttr("role aria-disabled").children(".ui-menu-item-wrapper").removeUniqueId().removeAttr("tabIndex role aria-haspopup");this.element.removeAttr("aria-activedescendant").find(".ui-menu").addBack().removeAttr("role aria-labelledby aria-expanded aria-hidden aria-disabled tabIndex").removeUniqueId().show();
a.children().each(function(){var a=d(this);a.data("ui-menu-submenu-caret")&&a.remove()})},_keydown:function(a){var b=!0;switch(a.keyCode){case d.ui.keyCode.PAGE_UP:this.previousPage(a);break;case d.ui.keyCode.PAGE_DOWN:this.nextPage(a);break;case d.ui.keyCode.HOME:this._move("first","first",a);break;case d.ui.keyCode.END:this._move("last","last",a);break;case d.ui.keyCode.UP:this.previous(a);break;case d.ui.keyCode.DOWN:this.next(a);break;case d.ui.keyCode.LEFT:this.collapse(a);break;case d.ui.keyCode.RIGHT:this.active&&
!this.active.is(".ui-state-disabled")&&this.expand(a);break;case d.ui.keyCode.ENTER:case d.ui.keyCode.SPACE:this._activate(a);break;case d.ui.keyCode.ESCAPE:this.collapse(a);break;default:b=!1;var c=this.previousFilter||"";var e=!1;var f=96<=a.keyCode&&105>=a.keyCode?(a.keyCode-96).toString():String.fromCharCode(a.keyCode);clearTimeout(this.filterTimer);f===c?e=!0:f=c+f;c=this._filterMenuItems(f);c=e&&-1!==c.index(this.active.next())?this.active.nextAll(".ui-menu-item"):c;c.length||(f=String.fromCharCode(a.keyCode),
c=this._filterMenuItems(f));c.length?(this.focus(a,c),this.previousFilter=f,this.filterTimer=this._delay(function(){delete this.previousFilter},1E3)):delete this.previousFilter}b&&a.preventDefault()},_activate:function(a){this.active&&!this.active.is(".ui-state-disabled")&&(this.active.children("[aria-haspopup='true']").length?this.expand(a):this.select(a))},refresh:function(){var a=this,b=this.options.icons.submenu;var c=this.element.find(this.options.menus);this._toggleClass("ui-menu-icons",null,
!!this.element.find(".ui-icon").length);var e=c.filter(":not(.ui-menu)").hide().attr({role:this.options.role,"aria-hidden":"true","aria-expanded":"false"}).each(function(){var c=d(this),e=c.prev(),f=d("<span>").data("ui-menu-submenu-caret",!0);a._addClass(f,"ui-menu-icon","ui-icon "+b);e.attr("aria-haspopup","true").prepend(f);c.attr("aria-labelledby",e.attr("id"))});this._addClass(e,"ui-menu","ui-widget ui-widget-content ui-front");e=c.add(this.element).find(this.options.items);e.not(".ui-menu-item").each(function(){var b=
d(this);a._isDivider(b)&&a._addClass(b,"ui-menu-divider","ui-widget-content")});c=e.not(".ui-menu-item, .ui-menu-divider");var f=c.children().not(".ui-menu").uniqueId().attr({tabIndex:-1,role:this._itemRole()});this._addClass(c,"ui-menu-item")._addClass(f,"ui-menu-item-wrapper");e.filter(".ui-state-disabled").attr("aria-disabled","true");this.active&&!d.contains(this.element[0],this.active[0])&&this.blur()},_itemRole:function(){return{menu:"menuitem",listbox:"option"}[this.options.role]},_setOption:function(a,
b){if("icons"===a){var c=this.element.find(".ui-menu-icon");this._removeClass(c,null,this.options.icons.submenu)._addClass(c,null,b.submenu)}this._super(a,b)},_setOptionDisabled:function(a){this._super(a);this.element.attr("aria-disabled",String(a));this._toggleClass(null,"ui-state-disabled",!!a)},focus:function(a,b){this.blur(a,a&&"focus"===a.type);this._scrollIntoView(b);this.active=b.first();var c=this.active.children(".ui-menu-item-wrapper");this._addClass(c,null,"ui-state-active");this.options.role&&
this.element.attr("aria-activedescendant",c.attr("id"));c=this.active.parent().closest(".ui-menu-item").children(".ui-menu-item-wrapper");this._addClass(c,null,"ui-state-active");a&&"keydown"===a.type?this._close():this.timer=this._delay(function(){this._close()},this.delay);c=b.children(".ui-menu");c.length&&a&&/^mouse/.test(a.type)&&this._startOpening(c);this.activeMenu=b.parent();this._trigger("focus",a,{item:b})},_scrollIntoView:function(a){if(this._hasScroll()){var b=parseFloat(d.css(this.activeMenu[0],
"borderTopWidth"))||0;var c=parseFloat(d.css(this.activeMenu[0],"paddingTop"))||0;b=a.offset().top-this.activeMenu.offset().top-b-c;c=this.activeMenu.scrollTop();var e=this.activeMenu.height();a=a.outerHeight();0>b?this.activeMenu.scrollTop(c+b):b+a>e&&this.activeMenu.scrollTop(c+b-e+a)}},blur:function(a,b){b||clearTimeout(this.timer);this.active&&(this._removeClass(this.active.children(".ui-menu-item-wrapper"),null,"ui-state-active"),this._trigger("blur",a,{item:this.active}),this.active=null)},
_startOpening:function(a){clearTimeout(this.timer);"true"===a.attr("aria-hidden")&&(this.timer=this._delay(function(){this._close();this._open(a)},this.delay))},_open:function(a){var b=d.extend({of:this.active},this.options.position);clearTimeout(this.timer);this.element.find(".ui-menu").not(a.parents(".ui-menu")).hide().attr("aria-hidden","true");a.show().removeAttr("aria-hidden").attr("aria-expanded","true").position(b)},collapseAll:function(a,b){clearTimeout(this.timer);this.timer=this._delay(function(){var c=
b?this.element:d(a&&a.target).closest(this.element.find(".ui-menu"));c.length||(c=this.element);this._close(c);this.blur(a);this._removeClass(c.find(".ui-state-active"),null,"ui-state-active");this.activeMenu=c},b?0:this.delay)},_close:function(a){a||(a=this.active?this.active.parent():this.element);a.find(".ui-menu").hide().attr("aria-hidden","true").attr("aria-expanded","false")},_closeOnDocumentClick:function(a){return!d(a.target).closest(".ui-menu").length},_isDivider:function(a){return!/[^\-\u2014\u2013\s]/.test(a.text())},
collapse:function(a){var b=this.active&&this.active.parent().closest(".ui-menu-item",this.element);b&&b.length&&(this._close(),this.focus(a,b))},expand:function(a){var b=this.active&&this._menuItems(this.active.children(".ui-menu")).first();b&&b.length&&(this._open(b.parent()),this._delay(function(){this.focus(a,b)}))},next:function(a){this._move("next","first",a)},previous:function(a){this._move("prev","last",a)},isFirstItem:function(){return this.active&&!this.active.prevAll(".ui-menu-item").length},
isLastItem:function(){return this.active&&!this.active.nextAll(".ui-menu-item").length},_menuItems:function(a){return(a||this.element).find(this.options.items).filter(".ui-menu-item")},_move:function(a,b,c){var d;this.active&&(d="first"===a||"last"===a?this.active["first"===a?"prevAll":"nextAll"](".ui-menu-item").last():this.active[a+"All"](".ui-menu-item").first());d&&d.length&&this.active||(d=this._menuItems(this.activeMenu)[b]());this.focus(c,d)},nextPage:function(a){var b;if(!this.active)this.next(a);
else if(!this.isLastItem())if(this._hasScroll()){var c=this.active.offset().top;var e=this.element.innerHeight();0===d.fn.jquery.indexOf("3.2.")&&(e+=this.element[0].offsetHeight-this.element.outerHeight());this.active.nextAll(".ui-menu-item").each(function(){b=d(this);return 0>b.offset().top-c-e});this.focus(a,b)}else this.focus(a,this._menuItems(this.activeMenu)[this.active?"last":"first"]())},previousPage:function(a){var b;if(!this.active)this.next(a);else if(!this.isFirstItem())if(this._hasScroll()){var c=
this.active.offset().top;var e=this.element.innerHeight();0===d.fn.jquery.indexOf("3.2.")&&(e+=this.element[0].offsetHeight-this.element.outerHeight());this.active.prevAll(".ui-menu-item").each(function(){b=d(this);return 0<b.offset().top-c+e});this.focus(a,b)}else this.focus(a,this._menuItems(this.activeMenu).first())},_hasScroll:function(){return this.element.outerHeight()<this.element.prop("scrollHeight")},select:function(a){this.active=this.active||d(a.target).closest(".ui-menu-item");var b={item:this.active};
this.active.has(".ui-menu").length||this.collapseAll(a,!0);this._trigger("select",a,b)},_filterMenuItems:function(a){a=a.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&");var b=new RegExp("^"+a,"i");return this.activeMenu.find(this.options.items).filter(".ui-menu-item").filter(function(){return b.test(String.prototype.trim.call(d(this).children(".ui-menu-item-wrapper").text()))})}});d.widget("ui.autocomplete",{version:"1.13.2",defaultElement:"<input>",options:{appendTo:null,autoFocus:!1,delay:300,minLength:1,
position:{my:"left top",at:"left bottom",collision:"none"},source:null,change:null,close:null,focus:null,open:null,response:null,search:null,select:null},requestIndex:0,pending:0,liveRegionTimer:null,_create:function(){var a,b,c,e=this.element[0].nodeName.toLowerCase(),f="textarea"===e;e="input"===e;this.isMultiLine=f||!e&&this._isContentEditable(this.element);this.valueMethod=this.element[f||e?"val":"text"];this.isNewMenu=!0;this._addClass("ui-autocomplete-input");this.element.attr("autocomplete",
"off");this._on(this.element,{keydown:function(e){if(this.element.prop("readOnly"))b=c=a=!0;else{b=c=a=!1;var f=d.ui.keyCode;switch(e.keyCode){case f.PAGE_UP:a=!0;this._move("previousPage",e);break;case f.PAGE_DOWN:a=!0;this._move("nextPage",e);break;case f.UP:a=!0;this._keyEvent("previous",e);break;case f.DOWN:a=!0;this._keyEvent("next",e);break;case f.ENTER:this.menu.active&&(a=!0,e.preventDefault(),this.menu.select(e));break;case f.TAB:this.menu.active&&this.menu.select(e);break;case f.ESCAPE:this.menu.element.is(":visible")&&
(this.isMultiLine||this._value(this.term),this.close(e),e.preventDefault());break;default:b=!0,this._searchTimeout(e)}}},keypress:function(c){if(a)a=!1,this.isMultiLine&&!this.menu.element.is(":visible")||c.preventDefault();else if(!b){var e=d.ui.keyCode;switch(c.keyCode){case e.PAGE_UP:this._move("previousPage",c);break;case e.PAGE_DOWN:this._move("nextPage",c);break;case e.UP:this._keyEvent("previous",c);break;case e.DOWN:this._keyEvent("next",c)}}},input:function(a){c?(c=!1,a.preventDefault()):
this._searchTimeout(a)},focus:function(){this.selectedItem=null;this.previous=this._value()},blur:function(a){clearTimeout(this.searching);this.close(a);this._change(a)}});this._initSource();this.menu=d("<ul>").appendTo(this._appendTo()).menu({role:null}).hide().attr({unselectable:"on"}).menu("instance");this._addClass(this.menu.element,"ui-autocomplete","ui-front");this._on(this.menu.element,{mousedown:function(a){a.preventDefault()},menufocus:function(a,b){var c;if(this.isNewMenu&&(this.isNewMenu=
!1,a.originalEvent&&/^mouse/.test(a.originalEvent.type))){this.menu.blur();this.document.one("mousemove",function(){d(a.target).trigger(a.originalEvent)});return}var e=b.item.data("ui-autocomplete-item");!1!==this._trigger("focus",a,{item:e})&&a.originalEvent&&/^key/.test(a.originalEvent.type)&&this._value(e.value);(c=b.item.attr("aria-label")||e.value)&&String.prototype.trim.call(c).length&&(clearTimeout(this.liveRegionTimer),this.liveRegionTimer=this._delay(function(){this.liveRegion.html(d("<div>").text(c))},
100))},menuselect:function(a,b){var c=b.item.data("ui-autocomplete-item"),e=this.previous;this.element[0]!==d.ui.safeActiveElement(this.document[0])&&(this.element.trigger("focus"),this.previous=e,this._delay(function(){this.previous=e;this.selectedItem=c}));!1!==this._trigger("select",a,{item:c})&&this._value(c.value);this.term=this._value();this.close(a);this.selectedItem=c}});this.liveRegion=d("<div>",{role:"status","aria-live":"assertive","aria-relevant":"additions"}).appendTo(this.document[0].body);
this._addClass(this.liveRegion,null,"ui-helper-hidden-accessible");this._on(this.window,{beforeunload:function(){this.element.removeAttr("autocomplete")}})},_destroy:function(){clearTimeout(this.searching);this.element.removeAttr("autocomplete");this.menu.element.remove();this.liveRegion.remove()},_setOption:function(a,b){this._super(a,b);"source"===a&&this._initSource();"appendTo"===a&&this.menu.element.appendTo(this._appendTo());"disabled"===a&&b&&this.xhr&&this.xhr.abort()},_isEventTargetInWidget:function(a){var b=
this.menu.element[0];return a.target===this.element[0]||a.target===b||d.contains(b,a.target)},_closeOnClickOutside:function(a){this._isEventTargetInWidget(a)||this.close()},_appendTo:function(){var a=this.options.appendTo;a&&(a=a.jquery||a.nodeType?d(a):this.document.find(a).eq(0));a&&a[0]||(a=this.element.closest(".ui-front, dialog"));a.length||(a=this.document[0].body);return a},_initSource:function(){var a=this;if(Array.isArray(this.options.source)){var b=this.options.source;this.source=function(a,
c){c(d.ui.autocomplete.filter(b,a.term))}}else if("string"===typeof this.options.source){var c=this.options.source;this.source=function(b,f){a.xhr&&a.xhr.abort();a.xhr=d.ajax({url:c,data:b,dataType:"json",success:function(a){f(a)},error:function(){f([])}})}}else this.source=this.options.source},_searchTimeout:function(a){clearTimeout(this.searching);this.searching=this._delay(function(){var b=this.term===this._value(),c=this.menu.element.is(":visible"),d=a.altKey||a.ctrlKey||a.metaKey||a.shiftKey;
if(!b||b&&!c&&!d)this.selectedItem=null,this.search(null,a)},this.options.delay)},search:function(a,b){a=null!=a?a:this._value();this.term=this._value();if(a.length<this.options.minLength)return this.close(b);if(!1!==this._trigger("search",b))return this._search(a)},_search:function(a){this.pending++;this._addClass("ui-autocomplete-loading");this.cancelSearch=!1;this.source({term:a},this._response())},_response:function(){var a=++this.requestIndex;return function(b){a===this.requestIndex&&this.__response(b);
this.pending--;this.pending||this._removeClass("ui-autocomplete-loading")}.bind(this)},__response:function(a){a&&(a=this._normalize(a));this._trigger("response",null,{content:a});!this.options.disabled&&a&&a.length&&!this.cancelSearch?(this._suggest(a),this._trigger("open")):this._close()},close:function(a){this.cancelSearch=!0;this._close(a)},_close:function(a){this._off(this.document,"mousedown");this.menu.element.is(":visible")&&(this.menu.element.hide(),this.menu.blur(),this.isNewMenu=!0,this._trigger("close",
a))},_change:function(a){this.previous!==this._value()&&this._trigger("change",a,{item:this.selectedItem})},_normalize:function(a){return a.length&&a[0].label&&a[0].value?a:d.map(a,function(a){return"string"===typeof a?{label:a,value:a}:d.extend({},a,{label:a.label||a.value,value:a.value||a.label})})},_suggest:function(a){var b=this.menu.element.empty();this._renderMenu(b,a);this.isNewMenu=!0;this.menu.refresh();b.show();this._resizeMenu();b.position(d.extend({of:this.element},this.options.position));
this.options.autoFocus&&this.menu.next();this._on(this.document,{mousedown:"_closeOnClickOutside"})},_resizeMenu:function(){var a=this.menu.element;a.outerWidth(Math.max(a.width("").outerWidth()+1,this.element.outerWidth()))},_renderMenu:function(a,b){var c=this;d.each(b,function(b,d){c._renderItemData(a,d)})},_renderItemData:function(a,b){return this._renderItem(a,b).data("ui-autocomplete-item",b)},_renderItem:function(a,b){return d("<li>").append(d("<div>").text(b.label)).appendTo(a)},_move:function(a,
b){if(this.menu.element.is(":visible"))if(this.menu.isFirstItem()&&/^previous/.test(a)||this.menu.isLastItem()&&/^next/.test(a))this.isMultiLine||this._value(this.term),this.menu.blur();else this.menu[a](b);else this.search(null,b)},widget:function(){return this.menu.element},_value:function(){return this.valueMethod.apply(this.element,arguments)},_keyEvent:function(a,b){if(!this.isMultiLine||this.menu.element.is(":visible"))this._move(a,b),b.preventDefault()},_isContentEditable:function(a){if(!a.length)return!1;
var b=a.prop("contentEditable");return"inherit"===b?this._isContentEditable(a.parent()):"true"===b}});d.extend(d.ui.autocomplete,{escapeRegex:function(a){return a.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")},filter:function(a,b){var c=new RegExp(d.ui.autocomplete.escapeRegex(b),"i");return d.grep(a,function(a){return c.test(a.label||a.value||a)})}});d.widget("ui.autocomplete",d.ui.autocomplete,{options:{messages:{noResults:"No search results.",results:function(a){return a+(1<a?" results are":" result is")+
" available, use up and down arrow keys to navigate."}}},__response:function(a){this._superApply(arguments);if(!this.options.disabled&&!this.cancelSearch){var b=a&&a.length?this.options.messages.results(a.length):this.options.messages.noResults;clearTimeout(this.liveRegionTimer);this.liveRegionTimer=this._delay(function(){this.liveRegion.html(d("<div>").text(b))},100)}}});var G=/ui-corner-([a-z]){2,6}/g;d.widget("ui.controlgroup",{version:"1.13.2",defaultElement:"<div>",options:{direction:"horizontal",
disabled:null,onlyVisible:!0,items:{button:"input[type=button], input[type=submit], input[type=reset], button, a",controlgroupLabel:".ui-controlgroup-label",checkboxradio:"input[type='checkbox'], input[type='radio']",selectmenu:"select",spinner:".ui-spinner-input"}},_create:function(){this._enhance()},_enhance:function(){this.element.attr("role","toolbar");this.refresh()},_destroy:function(){this._callChildMethod("destroy");this.childWidgets.removeData("ui-controlgroup-data");this.element.removeAttr("role");
this.options.items.controlgroupLabel&&this.element.find(this.options.items.controlgroupLabel).find(".ui-controlgroup-label-contents").contents().unwrap()},_initWidgets:function(){var a=this,b=[];d.each(this.options.items,function(c,e){var f={};e&&("controlgroupLabel"===c?(e=a.element.find(e),e.each(function(){var a=d(this);a.children(".ui-controlgroup-label-contents").length||a.contents().wrapAll("<span class='ui-controlgroup-label-contents'></span>")}),a._addClass(e,null,"ui-widget ui-widget-content ui-state-default"),
b=b.concat(e.get())):d.fn[c]&&(f=a["_"+c+"Options"]?a["_"+c+"Options"]("middle"):{classes:{}},a.element.find(e).each(function(){var e=d(this),h=e[c]("instance"),k=d.widget.extend({},f);"button"===c&&e.parent(".ui-spinner").length||(h||(h=e[c]()[c]("instance")),h&&(k.classes=a._resolveClassesValues(k.classes,h)),e[c](k),k=e[c]("widget"),d.data(k[0],"ui-controlgroup-data",h?h:e[c]("instance")),b.push(k[0]))})))});this.childWidgets=d(d.uniqueSort(b));this._addClass(this.childWidgets,"ui-controlgroup-item")},
_callChildMethod:function(a){this.childWidgets.each(function(){var b=d(this).data("ui-controlgroup-data");if(b&&b[a])b[a]()})},_updateCornerClass:function(a,b){b=this._buildSimpleOptions(b,"label").classes.label;this._removeClass(a,null,"ui-corner-top ui-corner-bottom ui-corner-left ui-corner-right ui-corner-all");this._addClass(a,null,b)},_buildSimpleOptions:function(a,b){var c="vertical"===this.options.direction,d={classes:{}};d.classes[b]={middle:"",first:"ui-corner-"+(c?"top":"left"),last:"ui-corner-"+
(c?"bottom":"right"),only:"ui-corner-all"}[a];return d},_spinnerOptions:function(a){a=this._buildSimpleOptions(a,"ui-spinner");a.classes["ui-spinner-up"]="";a.classes["ui-spinner-down"]="";return a},_buttonOptions:function(a){return this._buildSimpleOptions(a,"ui-button")},_checkboxradioOptions:function(a){return this._buildSimpleOptions(a,"ui-checkboxradio-label")},_selectmenuOptions:function(a){var b="vertical"===this.options.direction;return{width:b?"auto":!1,classes:{middle:{"ui-selectmenu-button-open":"",
"ui-selectmenu-button-closed":""},first:{"ui-selectmenu-button-open":"ui-corner-"+(b?"top":"tl"),"ui-selectmenu-button-closed":"ui-corner-"+(b?"top":"left")},last:{"ui-selectmenu-button-open":b?"":"ui-corner-tr","ui-selectmenu-button-closed":"ui-corner-"+(b?"bottom":"right")},only:{"ui-selectmenu-button-open":"ui-corner-top","ui-selectmenu-button-closed":"ui-corner-all"}}[a]}},_resolveClassesValues:function(a,b){var c={};d.each(a,function(d){var e=b.options.classes[d]||"";e=String.prototype.trim.call(e.replace(G,
""));c[d]=(e+" "+a[d]).replace(/\s+/g," ")});return c},_setOption:function(a,b){"direction"===a&&this._removeClass("ui-controlgroup-"+this.options.direction);this._super(a,b);"disabled"===a?this._callChildMethod(b?"disable":"enable"):this.refresh()},refresh:function(){var a=this;this._addClass("ui-controlgroup ui-controlgroup-"+this.options.direction);"horizontal"===this.options.direction&&this._addClass(null,"ui-helper-clearfix");this._initWidgets();var b=this.childWidgets;this.options.onlyVisible&&
(b=b.filter(":visible"));b.length&&(d.each(["first","last"],function(c,d){(c=b[d]().data("ui-controlgroup-data"))&&a["_"+c.widgetName+"Options"]?(d=a["_"+c.widgetName+"Options"](1===b.length?"only":d),d.classes=a._resolveClassesValues(d.classes,c),c.element[c.widgetName](d)):a._updateCornerClass(b[d](),d)}),this._callChildMethod("refresh"))}});d.widget("ui.checkboxradio",[d.ui.formResetMixin,{version:"1.13.2",options:{disabled:null,label:null,icon:!0,classes:{"ui-checkboxradio-label":"ui-corner-all",
"ui-checkboxradio-icon":"ui-corner-all"}},_getCreateOptions:function(){var a=this._super()||{};this._readType();var b=this.element.labels();this.label=d(b[b.length-1]);this.label.length||d.error("No label found for checkboxradio widget");this.originalLabel="";b=this.label.contents().not(this.element[0]);b.length&&(this.originalLabel+=b.clone().wrapAll("<div></div>").parent().html());this.originalLabel&&(a.label=this.originalLabel);b=this.element[0].disabled;null!=b&&(a.disabled=b);return a},_create:function(){var a=
this.element[0].checked;this._bindFormResetHandler();null==this.options.disabled&&(this.options.disabled=this.element[0].disabled);this._setOption("disabled",this.options.disabled);this._addClass("ui-checkboxradio","ui-helper-hidden-accessible");this._addClass(this.label,"ui-checkboxradio-label","ui-button ui-widget");"radio"===this.type&&this._addClass(this.label,"ui-checkboxradio-radio-label");this.options.label&&this.options.label!==this.originalLabel?this._updateLabel():this.originalLabel&&(this.options.label=
this.originalLabel);this._enhance();a&&this._addClass(this.label,"ui-checkboxradio-checked","ui-state-active");this._on({change:"_toggleClasses",focus:function(){this._addClass(this.label,null,"ui-state-focus ui-visual-focus")},blur:function(){this._removeClass(this.label,null,"ui-state-focus ui-visual-focus")}})},_readType:function(){var a=this.element[0].nodeName.toLowerCase();this.type=this.element[0].type;"input"===a&&/radio|checkbox/.test(this.type)||d.error("Can't create checkboxradio on element.nodeName="+
a+" and element.type="+this.type)},_enhance:function(){this._updateIcon(this.element[0].checked)},widget:function(){return this.label},_getRadioGroup:function(){var a=this.element[0].name,b="input[name='"+d.escapeSelector(a)+"']";return a?(this.form.length?d(this.form[0].elements).filter(b):d(b).filter(function(){return 0===d(this)._form().length})).not(this.element):d([])},_toggleClasses:function(){var a=this.element[0].checked;this._toggleClass(this.label,"ui-checkboxradio-checked","ui-state-active",
a);this.options.icon&&"checkbox"===this.type&&this._toggleClass(this.icon,null,"ui-icon-check ui-state-checked",a)._toggleClass(this.icon,null,"ui-icon-blank",!a);"radio"===this.type&&this._getRadioGroup().each(function(){var a=d(this).checkboxradio("instance");a&&a._removeClass(a.label,"ui-checkboxradio-checked","ui-state-active")})},_destroy:function(){this._unbindFormResetHandler();this.icon&&(this.icon.remove(),this.iconSpace.remove())},_setOption:function(a,b){if("label"!==a||b)this._super(a,
b),"disabled"===a?(this._toggleClass(this.label,null,"ui-state-disabled",b),this.element[0].disabled=b):this.refresh()},_updateIcon:function(a){var b="ui-icon ui-icon-background ";this.options.icon?(this.icon||(this.icon=d("<span>"),this.iconSpace=d("<span> </span>"),this._addClass(this.iconSpace,"ui-checkboxradio-icon-space")),"checkbox"===this.type?(b+=a?"ui-icon-check ui-state-checked":"ui-icon-blank",this._removeClass(this.icon,null,a?"ui-icon-blank":"ui-icon-check")):b+="ui-icon-blank",this._addClass(this.icon,
"ui-checkboxradio-icon",b),a||this._removeClass(this.icon,null,"ui-icon-check ui-state-checked"),this.icon.prependTo(this.label).after(this.iconSpace)):void 0!==this.icon&&(this.icon.remove(),this.iconSpace.remove(),delete this.icon)},_updateLabel:function(){var a=this.label.contents().not(this.element[0]);this.icon&&(a=a.not(this.icon[0]));this.iconSpace&&(a=a.not(this.iconSpace[0]));a.remove();this.label.append(this.options.label)},refresh:function(){var a=this.element[0].checked,b=this.element[0].disabled;
this._updateIcon(a);this._toggleClass(this.label,"ui-checkboxradio-checked","ui-state-active",a);null!==this.options.label&&this._updateLabel();b!==this.options.disabled&&this._setOptions({disabled:b})}}]);d.widget("ui.button",{version:"1.13.2",defaultElement:"<button>",options:{classes:{"ui-button":"ui-corner-all"},disabled:null,icon:null,iconPosition:"beginning",label:null,showLabel:!0},_getCreateOptions:function(){var a=this._super()||{};this.isInput=this.element.is("input");var b=this.element[0].disabled;
null!=b&&(a.disabled=b);if(this.originalLabel=this.isInput?this.element.val():this.element.html())a.label=this.originalLabel;return a},_create:function(){!this.option.showLabel&!this.options.icon&&(this.options.showLabel=!0);null==this.options.disabled&&(this.options.disabled=this.element[0].disabled||!1);this.hasTitle=!!this.element.attr("title");this.options.label&&this.options.label!==this.originalLabel&&(this.isInput?this.element.val(this.options.label):this.element.html(this.options.label));
this._addClass("ui-button","ui-widget");this._setOption("disabled",this.options.disabled);this._enhance();this.element.is("a")&&this._on({keyup:function(a){a.keyCode===d.ui.keyCode.SPACE&&(a.preventDefault(),this.element[0].click?this.element[0].click():this.element.trigger("click"))}})},_enhance:function(){this.element.is("button")||this.element.attr("role","button");this.options.icon&&(this._updateIcon("icon",this.options.icon),this._updateTooltip())},_updateTooltip:function(){this.title=this.element.attr("title");
this.options.showLabel||this.title||this.element.attr("title",this.options.label)},_updateIcon:function(a,b){var c=(a="iconPosition"!==a)?this.options.iconPosition:b,e="top"===c||"bottom"===c;this.icon?a&&this._removeClass(this.icon,null,this.options.icon):(this.icon=d("<span>"),this._addClass(this.icon,"ui-button-icon","ui-icon"),this.options.showLabel||this._addClass("ui-button-icon-only"));a&&this._addClass(this.icon,null,b);this._attachIcon(c);e?(this._addClass(this.icon,null,"ui-widget-icon-block"),
this.iconSpace&&this.iconSpace.remove()):(this.iconSpace||(this.iconSpace=d("<span> </span>"),this._addClass(this.iconSpace,"ui-button-icon-space")),this._removeClass(this.icon,null,"ui-wiget-icon-block"),this._attachIconSpace(c))},_destroy:function(){this.element.removeAttr("role");this.icon&&this.icon.remove();this.iconSpace&&this.iconSpace.remove();this.hasTitle||this.element.removeAttr("title")},_attachIconSpace:function(a){this.icon[/^(?:end|bottom)/.test(a)?"before":"after"](this.iconSpace)},
_attachIcon:function(a){this.element[/^(?:end|bottom)/.test(a)?"append":"prepend"](this.icon)},_setOptions:function(a){var b=void 0===a.icon?this.options.icon:a.icon;(void 0===a.showLabel?this.options.showLabel:a.showLabel)||b||(a.showLabel=!0);this._super(a)},_setOption:function(a,b){"icon"===a&&(b?this._updateIcon(a,b):this.icon&&(this.icon.remove(),this.iconSpace&&this.iconSpace.remove()));"iconPosition"===a&&this._updateIcon(a,b);"showLabel"===a&&(this._toggleClass("ui-button-icon-only",null,
!b),this._updateTooltip());"label"===a&&(this.isInput?this.element.val(b):(this.element.html(b),this.icon&&(this._attachIcon(this.options.iconPosition),this._attachIconSpace(this.options.iconPosition))));this._super(a,b);"disabled"===a&&(this._toggleClass(null,"ui-state-disabled",b),(this.element[0].disabled=b)&&this.element.trigger("blur"))},refresh:function(){var a=this.element.is("input, button")?this.element[0].disabled:this.element.hasClass("ui-button-disabled");a!==this.options.disabled&&this._setOptions({disabled:a});
this._updateTooltip()}});!1!==d.uiBackCompat&&(d.widget("ui.button",d.ui.button,{options:{text:!0,icons:{primary:null,secondary:null}},_create:function(){this.options.showLabel&&!this.options.text&&(this.options.showLabel=this.options.text);!this.options.showLabel&&this.options.text&&(this.options.text=this.options.showLabel);this.options.icon||!this.options.icons.primary&&!this.options.icons.secondary?this.options.icon&&(this.options.icons.primary=this.options.icon):this.options.icons.primary?this.options.icon=
this.options.icons.primary:(this.options.icon=this.options.icons.secondary,this.options.iconPosition="end");this._super()},_setOption:function(a,b){"text"===a?this._super("showLabel",b):("showLabel"===a&&(this.options.text=b),"icon"===a&&(this.options.icons.primary=b),"icons"===a&&(b.primary?(this._super("icon",b.primary),this._super("iconPosition","beginning")):b.secondary&&(this._super("icon",b.secondary),this._super("iconPosition","end"))),this._superApply(arguments))}}),d.fn.button=function(a){return function(b){var c=
"string"===typeof b,e=Array.prototype.slice.call(arguments,1),f=this;c?this.length||"instance"!==b?this.each(function(){var a=d(this).attr("type");var c=d.data(this,"ui-"+("checkbox"!==a&&"radio"!==a?"button":"checkboxradio"));if("instance"===b)return f=c,!1;if(!c)return d.error("cannot call methods on button prior to initialization; attempted to call method '"+b+"'");if("function"!==typeof c[b]||"_"===b.charAt(0))return d.error("no such method '"+b+"' for button widget instance");a=c[b].apply(c,
e);if(a!==c&&void 0!==a)return f=a&&a.jquery?f.pushStack(a.get()):a,!1}):f=void 0:(e.length&&(b=d.widget.extend.apply(null,[b].concat(e))),this.each(function(){var c=d(this).attr("type");c="checkbox"!==c&&"radio"!==c?"button":"checkboxradio";var e=d.data(this,"ui-"+c);e?(e.option(b||{}),e._init&&e._init()):"button"===c?a.call(d(this),b):d(this).checkboxradio(d.extend({icon:!1},b))}));return f}}(d.fn.button),d.fn.buttonset=function(){d.ui.controlgroup||d.error("Controlgroup widget missing");if("option"===
arguments[0]&&"items"===arguments[1]&&arguments[2])return this.controlgroup.apply(this,[arguments[0],"items.button",arguments[2]]);if("option"===arguments[0]&&"items"===arguments[1])return this.controlgroup.apply(this,[arguments[0],"items.button"]);"object"===typeof arguments[0]&&arguments[0].items&&(arguments[0].items={button:arguments[0].items});return this.controlgroup.apply(this,arguments)});d.widget("ui.dialog",{version:"1.13.2",options:{appendTo:"body",autoOpen:!0,buttons:[],classes:{"ui-dialog":"ui-corner-all",
"ui-dialog-titlebar":"ui-corner-all"},closeOnEscape:!0,closeText:"Close",showCloseButton:!0,showTitleBar:!0,draggable:!0,hide:null,height:"auto",maxHeight:null,maxWidth:null,minHeight:150,minWidth:150,modal:!1,position:{my:"center",at:"center",of:window,collision:"fit",using:function(a){var b=d(this).css(a).offset().top;0>b&&d(this).css("top",a.top-b)}},resizable:!0,show:null,title:null,width:300,beforeClose:null,close:null,drag:null,dragStart:null,dragStop:null,focus:null,open:null,resize:null,resizeStart:null,
resizeStop:null},sizeRelatedOptions:{buttons:!0,height:!0,maxHeight:!0,maxWidth:!0,minHeight:!0,minWidth:!0,width:!0},resizableRelatedOptions:{maxHeight:!0,maxWidth:!0,minHeight:!0,minWidth:!0},_create:function(){this.originalCss={display:this.element[0].style.display,width:this.element[0].style.width,minHeight:this.element[0].style.minHeight,maxHeight:this.element[0].style.maxHeight,height:this.element[0].style.height};this.originalPosition={parent:this.element.parent(),index:this.element.parent().children().index(this.element)};
this.originalTitle=this.element.attr("title");null==this.options.title&&null!=this.originalTitle&&(this.options.title=this.originalTitle);this.options.disabled&&(this.options.disabled=!1);this._createWrapper();this.element.show().removeAttr("title").appendTo(this.uiDialog);this._addClass("ui-dialog-content","ui-widget-content");this._createTitlebar();this._createButtonPane();this.options.draggable&&d.fn.draggable&&this._makeDraggable();this.options.resizable&&d.fn.resizable&&this._makeResizable();
this._isOpen=!1;this._trackFocus()},_init:function(){this.options.autoOpen&&this.open()},_appendTo:function(){var a=this.options.appendTo;return a&&(a.jquery||a.nodeType)?d(a):this.document.find(a||"body").eq(0)},_destroy:function(){var a=this.originalPosition;this._untrackInstance();this._destroyOverlay();this.element.removeUniqueId().css(this.originalCss).detach();this.uiDialog.remove();this.originalTitle&&this.element.attr("title",this.originalTitle);var b=a.parent.children().eq(a.index);b.length&&
b[0]!==this.element[0]?b.before(this.element):a.parent.append(this.element)},widget:function(){return this.uiDialog},disable:d.noop,enable:d.noop,close:function(a){var b=this;this._isOpen&&!1!==this._trigger("beforeClose",a)&&(this._isOpen=!1,this._focusedElement=null,this._destroyOverlay(),this._untrackInstance(),this.opener.filter(":focusable").trigger("focus").length||d.ui.safeBlur(d.ui.safeActiveElement(this.document[0])),this._hide(this.uiDialog,this.options.hide,function(){b._trigger("close",
a)}))},isOpen:function(){return this._isOpen},moveToTop:function(){this._moveToTop()},_moveToTop:function(a,b){var c=!1,e=this.uiDialog.siblings(".ui-front:visible").map(function(){return+d(this).css("z-index")}).get();e=Math.max.apply(null,e);e>=+this.uiDialog.css("z-index")&&(this.uiDialog.css("z-index",e+1),c=!0);c&&!b&&this._trigger("focus",a);return c},open:function(){var a=this;this._isOpen?this._moveToTop()&&this._focusTabbable():(this._isOpen=!0,this.opener=d(d.ui.safeActiveElement(this.document[0])),
this._size(),this._position(),this._createOverlay(),this._moveToTop(null,!0),this.overlay&&this.overlay.css("z-index",this.uiDialog.css("z-index")-1),this._show(this.uiDialog,this.options.show,function(){a._focusTabbable();a._trigger("focus")}),this._makeFocusTarget(),this._trigger("open"))},_focusTabbable:function(){var a=this._focusedElement;a||(a=this.element.find("[autofocus]"));a.length||(a=this.element.find(":tabbable"));a.length||(a=this.uiDialogButtonPane.find(":tabbable"));a.length||(a=this.uiDialogTitlebarClose.filter(":tabbable"));
a.length||(a=this.uiDialog);a.eq(0).trigger("focus")},_restoreTabbableFocus:function(){var a=d.ui.safeActiveElement(this.document[0]);this.uiDialog[0]===a||d.contains(this.uiDialog[0],a)||this._focusTabbable()},_keepFocus:function(a){a.preventDefault();this._restoreTabbableFocus();this._delay(this._restoreTabbableFocus)},_createWrapper:function(){this.uiDialog=d("<div>").hide().attr({tabIndex:-1,role:"dialog"}).appendTo(this._appendTo());this._addClass(this.uiDialog,"ui-dialog","ui-widget ui-widget-content ui-front");
this._on(this.uiDialog,{keydown:function(a){if(this.options.closeOnEscape&&!a.isDefaultPrevented()&&a.keyCode&&a.keyCode===d.ui.keyCode.ESCAPE)a.preventDefault(),this.close(a);else if(a.keyCode===d.ui.keyCode.TAB&&!a.isDefaultPrevented()){var b=this.uiDialog.find(":tabbable"),c=b.first(),e=b.last();a.target!==e[0]&&a.target!==this.uiDialog[0]||a.shiftKey?a.target!==c[0]&&a.target!==this.uiDialog[0]||!a.shiftKey||(this._delay(function(){e.trigger("focus")}),a.preventDefault()):(this._delay(function(){c.trigger("focus")}),
a.preventDefault())}},mousedown:function(a){this._moveToTop(a)&&this._focusTabbable()}});this.element.find("[aria-describedby]").length||this.uiDialog.attr({"aria-describedby":this.element.uniqueId().attr("id")})},_createTitlebar:function(){this.uiDialogTitlebar=d("<div>");this._addClass(this.uiDialogTitlebar,"ui-dialog-titlebar","ui-widget-header ui-helper-clearfix"+(this.options.showTitleBar?"":" ui-helper-hidden"));this._on(this.uiDialogTitlebar,{mousedown:function(a){d(a.target).closest(".ui-dialog-titlebar-close")||
this.uiDialog.trigger("focus")}});this.uiDialogTitlebarClose=d("<button type='button'></button>").button({label:d("<a>").text(this.options.closeText).html(),icon:"ui-icon-closethick",showLabel:!1}).appendTo(this.uiDialogTitlebar);this._addClass(this.uiDialogTitlebarClose,"ui-dialog-titlebar-close"+(this.options.showCloseButton?"":" ui-helper-hidden"));this._on(this.uiDialogTitlebarClose,{click:function(a){a.preventDefault();this.close(a)}});var a=d("<span>").uniqueId().prependTo(this.uiDialogTitlebar);
this._addClass(a,"ui-dialog-title");this._title(a);this.uiDialogTitlebar.prependTo(this.uiDialog);this.uiDialog.attr({"aria-labelledby":a.attr("id")})},_title:function(a){this.options.title?a.text(this.options.title):a.html("&#160;")},_createButtonPane:function(){this.uiDialogButtonPane=d("<div>");this._addClass(this.uiDialogButtonPane,"ui-dialog-buttonpane","ui-widget-content ui-helper-clearfix");this.uiButtonSet=d("<div>").appendTo(this.uiDialogButtonPane);this._addClass(this.uiButtonSet,"ui-dialog-buttonset");
this._createButtons()},_createButtons:function(){var a=this,b=this.options.buttons;this.uiDialogButtonPane.remove();this.uiButtonSet.empty();d.isEmptyObject(b)||Array.isArray(b)&&!b.length?this._removeClass(this.uiDialog,"ui-dialog-buttons"):(d.each(b,function(b,e){e="function"===typeof e?{click:e,text:b}:e;e=d.extend({type:"button"},e);var c=e.click;b={icon:e.icon,iconPosition:e.iconPosition,showLabel:e.showLabel,icons:e.icons,text:e.text};delete e.click;delete e.icon;delete e.iconPosition;delete e.showLabel;
delete e.icons;"boolean"===typeof e.text&&delete e.text;d("<button></button>",e).button(b).appendTo(a.uiButtonSet).on("click",function(){c.apply(a.element[0],arguments)})}),this._addClass(this.uiDialog,"ui-dialog-buttons"),this.uiDialogButtonPane.appendTo(this.uiDialog))},_makeDraggable:function(){function a(a){return{position:a.position,offset:a.offset}}var b=this,c=this.options;this.uiDialog.draggable({cancel:".ui-dialog-content, .ui-dialog-titlebar-close",handle:".ui-dialog-titlebar",containment:"document",
start:function(c,f){b._addClass(d(this),"ui-dialog-dragging");b._blockFrames();b._trigger("dragStart",c,a(f))},drag:function(c,d){b._trigger("drag",c,a(d))},stop:function(e,f){var g=f.offset.left-b.document.scrollLeft(),h=f.offset.top-b.document.scrollTop();c.position={my:"left top",at:"left"+(0<=g?"+":"")+g+" top"+(0<=h?"+":"")+h,of:b.window};b._removeClass(d(this),"ui-dialog-dragging");b._unblockFrames();b._trigger("dragStop",e,a(f))}})},_makeResizable:function(){function a(a){return{originalPosition:a.originalPosition,
originalSize:a.originalSize,position:a.position,size:a.size}}var b=this,c=this.options,e=c.resizable,f=this.uiDialog.css("position");e="string"===typeof e?e:"n,e,s,w,se,sw,ne,nw";this.uiDialog.resizable({cancel:".ui-dialog-content",containment:"document",alsoResize:this.element,maxWidth:c.maxWidth,maxHeight:c.maxHeight,minWidth:c.minWidth,minHeight:this._minHeight(),handles:e,start:function(c,e){b._addClass(d(this),"ui-dialog-resizing");b._blockFrames();b._trigger("resizeStart",c,a(e))},resize:function(c,
d){b._trigger("resize",c,a(d))},stop:function(e,f){var g=b.uiDialog.offset(),h=g.left-b.document.scrollLeft();g=g.top-b.document.scrollTop();c.height=b.uiDialog.height();c.width=b.uiDialog.width();c.position={my:"left top",at:"left"+(0<=h?"+":"")+h+" top"+(0<=g?"+":"")+g,of:b.window};b._removeClass(d(this),"ui-dialog-resizing");b._unblockFrames();b._trigger("resizeStop",e,a(f))}}).css("position",f)},_trackFocus:function(){this._on(this.widget(),{focusin:function(a){this._makeFocusTarget();this._focusedElement=
d(a.target)}})},_makeFocusTarget:function(){this._untrackInstance();this._trackingInstances().unshift(this)},_untrackInstance:function(){var a=this._trackingInstances(),b=d.inArray(this,a);-1!==b&&a.splice(b,1)},_trackingInstances:function(){var a=this.document.data("ui-dialog-instances");a||(a=[],this.document.data("ui-dialog-instances",a));return a},_minHeight:function(){var a=this.options;return"auto"===a.height?a.minHeight:Math.min(a.minHeight,a.height)},_position:function(){var a=this.uiDialog.is(":visible");
a||this.uiDialog.show();this.uiDialog.position(this.options.position);a||this.uiDialog.hide()},_setOptions:function(a){var b=this,c=!1,e={};d.each(a,function(a,d){b._setOption(a,d);a in b.sizeRelatedOptions&&(c=!0);a in b.resizableRelatedOptions&&(e[a]=d)});c&&(this._size(),this._position());this.uiDialog.is(":data(ui-resizable)")&&this.uiDialog.resizable("option",e)},_setOption:function(a,b){var c,e=this.uiDialog;"disabled"!==a&&(this._super(a,b),"appendTo"===a&&this.uiDialog.appendTo(this._appendTo()),
"buttons"===a&&this._createButtons(),"closeText"===a&&this.uiDialogTitlebarClose.button({label:d("<a>").text(""+this.options.closeText).html()}),"showCloseButton"===a&&this._toggleClass(this.uiDialogTitlebar.find(".ui-dialog-titlebar-close"),null,"ui-helper-hidden",!b),"showTitleBar"===a&&this._toggleClass(this.uiDialogTitlebar,null,"ui-helper-hidden",!b),"draggable"===a&&((c=e.is(":data(ui-draggable)"))&&!b&&e.draggable("destroy"),!c&&b&&this._makeDraggable()),"position"===a&&this._position(),"resizable"===
a&&((c=e.is(":data(ui-resizable)"))&&!b&&e.resizable("destroy"),c&&"string"===typeof b&&e.resizable("option","handles",b),c||!1===b||this._makeResizable()),"title"===a&&this._title(this.uiDialogTitlebar.find(".ui-dialog-title")))},_size:function(){var a=this.options;this.element.show().css({width:"auto",minHeight:0,maxHeight:"none",height:0});a.minWidth>a.width&&(a.width=a.minWidth);var b=this.uiDialog.css({height:"auto",width:a.width}).outerHeight();var c=Math.max(0,a.minHeight-b);var d="number"===
typeof a.maxHeight?Math.max(0,a.maxHeight-b):"none";"auto"===a.height?this.element.css({minHeight:c,maxHeight:d,height:"auto"}):this.element.height(Math.max(0,a.height-b));this.uiDialog.is(":data(ui-resizable)")&&this.uiDialog.resizable("option","minHeight",this._minHeight())},_blockFrames:function(){this.iframeBlocks=this.document.find("iframe").map(function(){var a=d(this);return d("<div>").css({position:"absolute",width:a.outerWidth(),height:a.outerHeight()}).appendTo(a.parent()).offset(a.offset())[0]})},
_unblockFrames:function(){this.iframeBlocks&&(this.iframeBlocks.remove(),delete this.iframeBlocks)},_allowInteraction:function(a){return d(a.target).closest(".ui-dialog").length?!0:!!d(a.target).closest(".ui-datepicker").length},_createOverlay:function(){if(this.options.modal){var a=d.fn.jquery.substring(0,4),b=!0;this._delay(function(){b=!1});if(!this.document.data("ui-dialog-overlays"))this.document.on("focusin.ui-dialog",function(c){if(!b){var d=this._trackingInstances()[0];d._allowInteraction(c)||
(c.preventDefault(),d._focusTabbable(),"3.4."!==a&&"3.5."!==a||d._delay(d._restoreTabbableFocus))}}.bind(this));this.overlay=d("<div>").appendTo(this._appendTo());this._addClass(this.overlay,null,"ui-widget-overlay ui-front");this._on(this.overlay,{mousedown:"_keepFocus"});this.document.data("ui-dialog-overlays",(this.document.data("ui-dialog-overlays")||0)+1)}},_destroyOverlay:function(){if(this.options.modal&&this.overlay){var a=this.document.data("ui-dialog-overlays")-1;a?this.document.data("ui-dialog-overlays",
a):(this.document.off("focusin.ui-dialog"),this.document.removeData("ui-dialog-overlays"));this.overlay.remove();this.overlay=null}}});!1!==d.uiBackCompat&&d.widget("ui.dialog",d.ui.dialog,{options:{dialogClass:""},_createWrapper:function(){this._super();this.uiDialog.addClass(this.options.dialogClass)},_setOption:function(a,b){"dialogClass"===a&&this.uiDialog.removeClass(this.options.dialogClass).addClass(b);this._superApply(arguments)}});d.widget("ui.slider",d.ui.mouse,{version:"1.13.2",widgetEventPrefix:"slide",
options:{animate:!1,classes:{"ui-slider":"ui-corner-all","ui-slider-handle":"ui-corner-all","ui-slider-range":"ui-corner-all ui-widget-header"},distance:0,max:100,min:0,orientation:"horizontal",range:!1,step:1,value:0,values:null,change:null,slide:null,start:null,stop:null},numPages:5,_create:function(){this._mouseSliding=this._keySliding=!1;this._animateOff=!0;this._handleIndex=null;this._detectOrientation();this._mouseInit();this._calculateNewMax();this._addClass("ui-slider ui-slider-"+this.orientation,
"ui-widget ui-widget-content");this._refresh();this._animateOff=!1},_refresh:function(){this._createRange();this._createHandles();this._setupEvents();this._refreshValue()},_createHandles:function(){var a=this.options;var b=this.element.find(".ui-slider-handle"),c=[];var e=a.values&&a.values.length||1;b.length>e&&(b.slice(e).remove(),b=b.slice(0,e));for(a=b.length;a<e;a++)c.push("<span tabindex='0'></span>");this.handles=b.add(d(c.join("")).appendTo(this.element));this._addClass(this.handles,"ui-slider-handle",
"ui-state-default");this.handle=this.handles.eq(0);this.handles.each(function(a){d(this).data("ui-slider-handle-index",a).attr("tabIndex",0)})},_createRange:function(){var a=this.options;a.range?(!0===a.range&&(a.values?a.values.length&&2!==a.values.length?a.values=[a.values[0],a.values[0]]:Array.isArray(a.values)&&(a.values=a.values.slice(0)):a.values=[this._valueMin(),this._valueMin()]),this.range&&this.range.length?(this._removeClass(this.range,"ui-slider-range-min ui-slider-range-max"),this.range.css({left:"",
bottom:""})):(this.range=d("<div>").appendTo(this.element),this._addClass(this.range,"ui-slider-range")),"min"!==a.range&&"max"!==a.range||this._addClass(this.range,"ui-slider-range-"+a.range)):(this.range&&this.range.remove(),this.range=null)},_setupEvents:function(){this._off(this.handles);this._on(this.handles,this._handleEvents);this._hoverable(this.handles);this._focusable(this.handles)},_destroy:function(){this.handles.remove();this.range&&this.range.remove();this._mouseDestroy()},_mouseCapture:function(a){var b,
c,e=this,f=this.options;if(f.disabled)return!1;this.elementSize={width:this.element.outerWidth(),height:this.element.outerHeight()};this.elementOffset=this.element.offset();var g=this._normValueFromMouse({x:a.pageX,y:a.pageY});var h=this._valueMax()-this._valueMin()+1;this.handles.each(function(a){var k=Math.abs(g-e.values(a));if(h>k||h===k&&(a===e._lastChangedValue||e.values(a)===f.min))h=k,b=d(this),c=a});if(!1===this._start(a,c))return!1;this._mouseSliding=!0;this._handleIndex=c;this._addClass(b,
null,"ui-state-active");b.trigger("focus");var k=b.offset();this._clickOffset=d(a.target).parents().addBack().is(".ui-slider-handle")?{left:a.pageX-k.left-b.width()/2,top:a.pageY-k.top-b.height()/2-(parseInt(b.css("borderTopWidth"),10)||0)-(parseInt(b.css("borderBottomWidth"),10)||0)+(parseInt(b.css("marginTop"),10)||0)}:{left:0,top:0};this.handles.hasClass("ui-state-hover")||this._slide(a,c,g);return this._animateOff=!0},_mouseStart:function(){return!0},_mouseDrag:function(a){var b=this._normValueFromMouse({x:a.pageX,
y:a.pageY});this._slide(a,this._handleIndex,b);return!1},_mouseStop:function(a){this._removeClass(this.handles,null,"ui-state-active");this._mouseSliding=!1;this._stop(a,this._handleIndex);this._change(a,this._handleIndex);this._clickOffset=this._handleIndex=null;return this._animateOff=!1},_detectOrientation:function(){this.orientation="vertical"===this.options.orientation?"vertical":"horizontal"},_normValueFromMouse:function(a){if("horizontal"===this.orientation){var b=this.elementSize.width;a=
a.x-this.elementOffset.left-(this._clickOffset?this._clickOffset.left:0)}else b=this.elementSize.height,a=a.y-this.elementOffset.top-(this._clickOffset?this._clickOffset.top:0);b=a/b;1<b&&(b=1);0>b&&(b=0);"vertical"===this.orientation&&(b=1-b);a=this._valueMax()-this._valueMin();b=this._valueMin()+b*a;return this._trimAlignValue(b)},_uiHash:function(a,b,c){var d={handle:this.handles[a],handleIndex:a,value:void 0!==b?b:this.value()};this._hasMultipleValues()&&(d.value=void 0!==b?b:this.values(a),d.values=
c||this.values());return d},_hasMultipleValues:function(){return this.options.values&&this.options.values.length},_start:function(a,b){return this._trigger("start",a,this._uiHash(b))},_slide:function(a,b,c){var d=this.value(),f=this.values();if(this._hasMultipleValues()){var g=this.values(b?0:1);d=this.values(b);2===this.options.values.length&&!0===this.options.range&&(c=0===b?Math.min(g,c):Math.max(g,c));f[b]=c}c!==d&&!1!==this._trigger("slide",a,this._uiHash(b,c,f))&&(this._hasMultipleValues()?
this.values(b,c):this.value(c))},_stop:function(a,b){this._trigger("stop",a,this._uiHash(b))},_change:function(a,b){this._keySliding||this._mouseSliding||(this._lastChangedValue=b,this._trigger("change",a,this._uiHash(b)))},value:function(a){if(arguments.length)this.options.value=this._trimAlignValue(a),this._refreshValue(),this._change(null,0);else return this._value()},values:function(a,b){var c;if(1<arguments.length)this.options.values[a]=this._trimAlignValue(b),this._refreshValue(),this._change(null,
a);else if(arguments.length)if(Array.isArray(arguments[0])){var d=this.options.values;var f=arguments[0];for(c=0;c<d.length;c+=1)d[c]=this._trimAlignValue(f[c]),this._change(null,c);this._refreshValue()}else return this._hasMultipleValues()?this._values(a):this.value();else return this._values()},_setOption:function(a,b){var c=0;"range"===a&&!0===this.options.range&&("min"===b?(this.options.value=this._values(0),this.options.values=null):"max"===b&&(this.options.value=this._values(this.options.values.length-
1),this.options.values=null));Array.isArray(this.options.values)&&(c=this.options.values.length);this._super(a,b);switch(a){case "orientation":this._detectOrientation();this._removeClass("ui-slider-horizontal ui-slider-vertical")._addClass("ui-slider-"+this.orientation);this._refreshValue();this.options.range&&this._refreshRange(b);this.handles.css("horizontal"===b?"bottom":"left","");break;case "value":this._animateOff=!0;this._refreshValue();this._change(null,0);this._animateOff=!1;break;case "values":this._animateOff=
!0;this._refreshValue();for(a=c-1;0<=a;a--)this._change(null,a);this._animateOff=!1;break;case "step":case "min":case "max":this._animateOff=!0;this._calculateNewMax();this._refreshValue();this._animateOff=!1;break;case "range":this._animateOff=!0,this._refresh(),this._animateOff=!1}},_setOptionDisabled:function(a){this._super(a);this._toggleClass(null,"ui-state-disabled",!!a)},_value:function(){var a=this.options.value;return a=this._trimAlignValue(a)},_values:function(a){var b;if(arguments.length){var c=
this.options.values[a];return c=this._trimAlignValue(c)}if(this._hasMultipleValues()){c=this.options.values.slice();for(b=0;b<c.length;b+=1)c[b]=this._trimAlignValue(c[b]);return c}return[]},_trimAlignValue:function(a){if(a<=this._valueMin())return this._valueMin();if(a>=this._valueMax())return this._valueMax();var b=0<this.options.step?this.options.step:1,c=(a-this._valueMin())%b;a-=c;2*Math.abs(c)>=b&&(a+=0<c?b:-b);return parseFloat(a.toFixed(5))},_calculateNewMax:function(){var a=this.options.max,
b=this._valueMin(),c=this.options.step;a=Math.round((a-b)/c)*c+b;a>this.options.max&&(a-=c);this.max=parseFloat(a.toFixed(this._precision()))},_precision:function(){var a=this._precisionOf(this.options.step);null!==this.options.min&&(a=Math.max(a,this._precisionOf(this.options.min)));return a},_precisionOf:function(a){a=a.toString();var b=a.indexOf(".");return-1===b?0:a.length-b-1},_valueMin:function(){return this.options.min},_valueMax:function(){return this.max},_refreshRange:function(a){"vertical"===
a&&this.range.css({width:"",left:""});"horizontal"===a&&this.range.css({height:"",bottom:""})},_refreshValue:function(){var a,b=this.options.range,c=this.options,e=this,f=this._animateOff?!1:c.animate,g={};if(this._hasMultipleValues())this.handles.each(function(b){m=(e.values(b)-e._valueMin())/(e._valueMax()-e._valueMin())*100;g["horizontal"===e.orientation?"left":"bottom"]=m+"%";d(this).stop(1,1)[f?"animate":"css"](g,c.animate);if(!0===e.options.range)if("horizontal"===e.orientation){if(0===b)e.range.stop(1,
1)[f?"animate":"css"]({left:m+"%"},c.animate);if(1===b)e.range[f?"animate":"css"]({width:m-a+"%"},{queue:!1,duration:c.animate})}else{if(0===b)e.range.stop(1,1)[f?"animate":"css"]({bottom:m+"%"},c.animate);if(1===b)e.range[f?"animate":"css"]({height:m-a+"%"},{queue:!1,duration:c.animate})}a=m});else{var h=this.value();var k=this._valueMin();var l=this._valueMax();var m=l!==k?(h-k)/(l-k)*100:0;g["horizontal"===this.orientation?"left":"bottom"]=m+"%";this.handle.stop(1,1)[f?"animate":"css"](g,c.animate);
if("min"===b&&"horizontal"===this.orientation)this.range.stop(1,1)[f?"animate":"css"]({width:m+"%"},c.animate);if("max"===b&&"horizontal"===this.orientation)this.range.stop(1,1)[f?"animate":"css"]({width:100-m+"%"},c.animate);if("min"===b&&"vertical"===this.orientation)this.range.stop(1,1)[f?"animate":"css"]({height:m+"%"},c.animate);if("max"===b&&"vertical"===this.orientation)this.range.stop(1,1)[f?"animate":"css"]({height:100-m+"%"},c.animate)}},_handleEvents:{keydown:function(a){var b,c=d(a.target).data("ui-slider-handle-index");
switch(a.keyCode){case d.ui.keyCode.HOME:case d.ui.keyCode.END:case d.ui.keyCode.PAGE_UP:case d.ui.keyCode.PAGE_DOWN:case d.ui.keyCode.UP:case d.ui.keyCode.RIGHT:case d.ui.keyCode.DOWN:case d.ui.keyCode.LEFT:if(a.preventDefault(),!this._keySliding){this._keySliding=!0;this._addClass(d(a.target),null,"ui-state-active");var e=this._start(a,c);if(!1===e)return}}var f=this.options.step;e=this._hasMultipleValues()?b=this.values(c):b=this.value();switch(a.keyCode){case d.ui.keyCode.HOME:b=this._valueMin();
break;case d.ui.keyCode.END:b=this._valueMax();break;case d.ui.keyCode.PAGE_UP:b=this._trimAlignValue(e+(this._valueMax()-this._valueMin())/this.numPages);break;case d.ui.keyCode.PAGE_DOWN:b=this._trimAlignValue(e-(this._valueMax()-this._valueMin())/this.numPages);break;case d.ui.keyCode.UP:case d.ui.keyCode.RIGHT:if(e===this._valueMax())return;b=this._trimAlignValue(e+f);break;case d.ui.keyCode.DOWN:case d.ui.keyCode.LEFT:if(e===this._valueMin())return;b=this._trimAlignValue(e-f)}this._slide(a,c,
b)},keyup:function(a){var b=d(a.target).data("ui-slider-handle-index");this._keySliding&&(this._keySliding=!1,this._stop(a,b),this._change(a,b),this._removeClass(d(a.target),null,"ui-state-active"))}}});d.widget("ui.tabs",{version:"1.13.2",delay:300,options:{active:null,classes:{"ui-tabs":"ui-corner-all","ui-tabs-nav":"ui-corner-all","ui-tabs-panel":"ui-corner-bottom","ui-tabs-tab":"ui-corner-top"},collapsible:!1,event:"click",heightStyle:"content",hide:null,show:null,activate:null,beforeActivate:null,
beforeLoad:null,load:null},_isLocal:function(){var a=/#.*$/;return function(b){var c=b.href.replace(a,"");var d=location.href.replace(a,"");try{c=decodeURIComponent(c)}catch(f){}try{d=decodeURIComponent(d)}catch(f){}return 1<b.hash.length&&c===d}}(),_create:function(){var a=this,b=this.options;this.running=!1;this._addClass("ui-tabs","ui-widget ui-widget-content");this._toggleClass("ui-tabs-collapsible",null,b.collapsible);this._processTabs();b.active=this._initialActive();Array.isArray(b.disabled)&&
(b.disabled=d.uniqueSort(b.disabled.concat(d.map(this.tabs.filter(".ui-state-disabled"),function(b){return a.tabs.index(b)}))).sort());this.active=!1!==this.options.active&&this.anchors.length?this._findActive(b.active):d();this._refresh();this.active.length&&this.load(b.active)},_initialActive:function(){var a=this.options.active,b=this.options.collapsible,c=location.hash.substring(1);null===a&&(c&&this.tabs.each(function(b,f){if(d(f).attr("aria-controls")===c)return a=b,!1}),null===a&&(a=this.tabs.index(this.tabs.filter(".ui-tabs-active"))),
null===a||-1===a)&&(a=this.tabs.length?0:!1);!1!==a&&(a=this.tabs.index(this.tabs.eq(a)),-1===a&&(a=b?!1:0));!b&&!1===a&&this.anchors.length&&(a=0);return a},_getCreateEventData:function(){return{tab:this.active,panel:this.active.length?this._getPanelForTab(this.active):d()}},_tabKeydown:function(a){var b=d(d.ui.safeActiveElement(this.document[0])).closest("li"),c=this.tabs.index(b),e=!0;if(!this._handlePageNav(a)){switch(a.keyCode){case d.ui.keyCode.RIGHT:case d.ui.keyCode.DOWN:c++;break;case d.ui.keyCode.UP:case d.ui.keyCode.LEFT:e=
!1;c--;break;case d.ui.keyCode.END:c=this.anchors.length-1;break;case d.ui.keyCode.HOME:c=0;break;case d.ui.keyCode.SPACE:a.preventDefault();clearTimeout(this.activating);this._activate(c);return;case d.ui.keyCode.ENTER:a.preventDefault();clearTimeout(this.activating);this._activate(c===this.options.active?!1:c);return;default:return}a.preventDefault();clearTimeout(this.activating);c=this._focusNextTab(c,e);a.ctrlKey||a.metaKey||(b.attr("aria-selected","false"),this.tabs.eq(c).attr("aria-selected",
"true"),this.activating=this._delay(function(){this.option("active",c)},this.delay))}},_panelKeydown:function(a){!this._handlePageNav(a)&&a.ctrlKey&&a.keyCode===d.ui.keyCode.UP&&(a.preventDefault(),this.active.trigger("focus"))},_handlePageNav:function(a){if(a.altKey&&a.keyCode===d.ui.keyCode.PAGE_UP)return this._activate(this._focusNextTab(this.options.active-1,!1)),!0;if(a.altKey&&a.keyCode===d.ui.keyCode.PAGE_DOWN)return this._activate(this._focusNextTab(this.options.active+1,!0)),!0},_findNextTab:function(a,
b){function c(){a>e&&(a=0);0>a&&(a=e);return a}for(var e=this.tabs.length-1;-1!==d.inArray(c(),this.options.disabled);)a=b?a+1:a-1;return a},_focusNextTab:function(a,b){a=this._findNextTab(a,b);this.tabs.eq(a).trigger("focus");return a},_setOption:function(a,b){"active"===a?this._activate(b):(this._super(a,b),"collapsible"===a&&(this._toggleClass("ui-tabs-collapsible",null,b),b||!1!==this.options.active||this._activate(0)),"event"===a&&this._setupEvents(b),"heightStyle"===a&&this._setupHeightStyle(b))},
_sanitizeSelector:function(a){return a?a.replace(/[!"$%&'()*+,.\/:;<=>?@\[\]\^`{|}~]/g,"\\$&"):""},refresh:function(){var a=this.options,b=this.tablist.children(":has(a[href])");a.disabled=d.map(b.filter(".ui-state-disabled"),function(a){return b.index(a)});this._processTabs();!1!==a.active&&this.anchors.length?this.active.length&&!d.contains(this.tablist[0],this.active[0])?this.tabs.length===a.disabled.length?(a.active=!1,this.active=d()):this._activate(this._findNextTab(Math.max(0,a.active-1),!1)):
a.active=this.tabs.index(this.active):(a.active=!1,this.active=d());this._refresh()},_refresh:function(){this._setOptionDisabled(this.options.disabled);this._setupEvents(this.options.event);this._setupHeightStyle(this.options.heightStyle);this.tabs.not(this.active).attr({"aria-selected":"false","aria-expanded":"false",tabIndex:-1});this.panels.not(this._getPanelForTab(this.active)).hide().attr({"aria-hidden":"true"});this.active.length?(this.active.attr({"aria-selected":"true","aria-expanded":"true",
tabIndex:0}),this._addClass(this.active,"ui-tabs-active","ui-state-active"),this._getPanelForTab(this.active).show().attr({"aria-hidden":"false"})):this.tabs.eq(0).attr("tabIndex",0)},_processTabs:function(){var a=this,b=this.tabs,c=this.anchors,e=this.panels;this.tablist=this._getList().attr("role","tablist");this._addClass(this.tablist,"ui-tabs-nav","ui-helper-reset ui-helper-clearfix ui-widget-header");this.tablist.on("mousedown"+this.eventNamespace,"> li",function(a){d(this).is(".ui-state-disabled")&&
a.preventDefault()}).on("focus"+this.eventNamespace,".ui-tabs-anchor",function(){d(this).closest("li").is(".ui-state-disabled")&&this.blur()});this.tabs=this.tablist.find("> li:has(a[href])").attr({role:"tab",tabIndex:-1});this._addClass(this.tabs,"ui-tabs-tab","ui-state-default");this.anchors=this.tabs.map(function(){return d("a",this)[0]}).attr({tabIndex:-1});this._addClass(this.anchors,"ui-tabs-anchor");this.panels=d();this.anchors.each(function(b,c){var e=d(c).uniqueId().attr("id"),f=d(c).closest("li"),
g=f.attr("aria-controls");if(a._isLocal(c)){b=c.hash;c=b.substring(1);var m=a.element.find(a._sanitizeSelector(b))}else c=f.attr("aria-controls")||d({}).uniqueId()[0].id,m=a.element.find("#"+c),m.length||(m=a._createPanel(c),m.insertAfter(a.panels[b-1]||a.tablist)),m.attr("aria-live","polite");m.length&&(a.panels=a.panels.add(m));g&&f.data("ui-tabs-aria-controls",g);f.attr({"aria-controls":c,"aria-labelledby":e});m.attr("aria-labelledby",e)});this.panels.attr("role","tabpanel");this._addClass(this.panels,
"ui-tabs-panel","ui-widget-content");b&&(this._off(b.not(this.tabs)),this._off(c.not(this.anchors)),this._off(e.not(this.panels)))},_getList:function(){return this.tablist||this.element.find("ol:not(.ui-tabs-skip),ul:not(.ui-tabs-skip)").eq(0)},_createPanel:function(a){return d("<div>").attr("id",a).data("ui-tabs-destroy",!0)},_setOptionDisabled:function(a){var b,c;Array.isArray(a)&&(a.length?a.length===this.anchors.length&&(a=!0):a=!1);for(c=0;b=this.tabs[c];c++)b=d(b),!0===a||-1!==d.inArray(c,a)?
(b.attr("aria-disabled","true"),this._addClass(b,null,"ui-state-disabled")):(b.removeAttr("aria-disabled"),this._removeClass(b,null,"ui-state-disabled"));this.options.disabled=a;this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,!0===a)},_setupEvents:function(a){var b={};a&&d.each(a.split(" "),function(a,d){b[d]="_eventHandler"});this._off(this.anchors.add(this.tabs).add(this.panels));this._on(!0,this.anchors,{click:function(a){a.preventDefault()}});this._on(this.anchors,b);this._on(this.tabs,
{keydown:"_tabKeydown"});this._on(this.panels,{keydown:"_panelKeydown"});this._focusable(this.tabs);this._hoverable(this.tabs)},_setupHeightStyle:function(a){var b=this.element.parent();if("fill"===a){var c=b.height();c-=this.element.outerHeight()-this.element.height();this.element.siblings(":visible").each(function(){var a=d(this),b=a.css("position");"absolute"!==b&&"fixed"!==b&&(c-=a.outerHeight(!0))});this.element.children().not(this.panels).each(function(){c-=d(this).outerHeight(!0)});this.panels.each(function(){d(this).height(Math.max(0,
c-d(this).innerHeight()+d(this).height()))}).css("overflow","auto")}else"auto"===a&&(c=0,this.panels.each(function(){c=Math.max(c,d(this).height("").height())}).height(c))},_eventHandler:function(a){var b=this.options,c=this.active,e=d(a.currentTarget).closest("li"),f=e[0]===c[0],g=f&&b.collapsible,h=g?d():this._getPanelForTab(e),k=c.length?this._getPanelForTab(c):d();c={oldTab:c,oldPanel:k,newTab:g?d():e,newPanel:h};a.preventDefault();e.hasClass("ui-state-disabled")||e.hasClass("ui-tabs-loading")||
this.running||f&&!b.collapsible||!1===this._trigger("beforeActivate",a,c)||(b.active=g?!1:this.tabs.index(e),this.active=f?d():e,this.xhr&&this.xhr.abort(),k.length||h.length||d.error("jQuery UI Tabs: Mismatching fragment identifier."),h.length&&this.load(this.tabs.index(e),a),this._toggle(a,c))},_toggle:function(a,b){function c(){f.running=!1;f._trigger("activate",a,b)}function e(){f._addClass(b.newTab.closest("li"),"ui-tabs-active","ui-state-active");g.length&&f.options.show?f._show(g,f.options.show,
c):(g.show(),c())}var f=this,g=b.newPanel,h=b.oldPanel;this.running=!0;h.length&&this.options.hide?this._hide(h,this.options.hide,function(){f._removeClass(b.oldTab.closest("li"),"ui-tabs-active","ui-state-active");e()}):(this._removeClass(b.oldTab.closest("li"),"ui-tabs-active","ui-state-active"),h.hide(),e());h.attr("aria-hidden","true");b.oldTab.attr({"aria-selected":"false","aria-expanded":"false"});g.length&&h.length?b.oldTab.attr("tabIndex",-1):g.length&&this.tabs.filter(function(){return 0===
d(this).attr("tabIndex")}).attr("tabIndex",-1);g.attr("aria-hidden","false");b.newTab.attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0})},_activate:function(a){a=this._findActive(a);a[0]!==this.active[0]&&(a.length||(a=this.active),a=a.find(".ui-tabs-anchor")[0],this._eventHandler({target:a,currentTarget:a,preventDefault:d.noop}))},_findActive:function(a){return!1===a?d():this.tabs.eq(a)},_getIndex:function(a){"string"===typeof a&&(a=this.anchors.index(this.anchors.filter("[href$='"+
d.escapeSelector(a)+"']")));return a},_destroy:function(){this.xhr&&this.xhr.abort();this.tablist.removeAttr("role").off(this.eventNamespace);this.anchors.removeAttr("role tabIndex").removeUniqueId();this.tabs.add(this.panels).each(function(){d.data(this,"ui-tabs-destroy")?d(this).remove():d(this).removeAttr("role tabIndex aria-live aria-busy aria-selected aria-labelledby aria-hidden aria-expanded")});this.tabs.each(function(){var a=d(this),b=a.data("ui-tabs-aria-controls");b?a.attr("aria-controls",
b).removeData("ui-tabs-aria-controls"):a.removeAttr("aria-controls")});this.panels.show();"content"!==this.options.heightStyle&&this.panels.css("height","")},enable:function(a){var b=this.options.disabled;!1!==b&&(void 0===a?b=!1:(a=this._getIndex(a),b=Array.isArray(b)?d.map(b,function(b){return b!==a?b:null}):d.map(this.tabs,function(b,d){return d!==a?d:null})),this._setOptionDisabled(b))},disable:function(a){var b=this.options.disabled;if(!0!==b){if(void 0===a)b=!0;else{a=this._getIndex(a);if(-1!==
d.inArray(a,b))return;b=Array.isArray(b)?d.merge([a],b).sort():[a]}this._setOptionDisabled(b)}},load:function(a,b){a=this._getIndex(a);var c=this,e=this.tabs.eq(a);a=e.find(".ui-tabs-anchor");var f=this._getPanelForTab(e),g={tab:e,panel:f},h=function(a,b){"abort"===b&&c.panels.stop(!1,!0);c._removeClass(e,"ui-tabs-loading");f.removeAttr("aria-busy");a===c.xhr&&delete c.xhr};this._isLocal(a[0])||(this.xhr=d.ajax(this._ajaxSettings(a,b,g)))&&"canceled"!==this.xhr.statusText&&(this._addClass(e,"ui-tabs-loading"),
f.attr("aria-busy","true"),this.xhr.done(function(a,d,e){setTimeout(function(){f.html(a);c._trigger("load",b,g);h(e,d)},1)}).fail(function(a,b){setTimeout(function(){h(a,b)},1)}))},_ajaxSettings:function(a,b,c){var e=this;return{url:a.attr("href").replace(/#.*$/,""),beforeSend:function(a,g){return e._trigger("beforeLoad",b,d.extend({jqXHR:a,ajaxSettings:g},c))}}},_getPanelForTab:function(a){a=d(a).attr("aria-controls");return this.element.find(this._sanitizeSelector("#"+a))}});!1!==d.uiBackCompat&&
d.widget("ui.tabs",d.ui.tabs,{_processTabs:function(){this._superApply(arguments);this._addClass(this.tabs,"ui-tab")}})});
;

// ***************************
// js.compressed/jquery/jquery.ui.touch-punch.min.js
// ***************************
/*
 jQuery UI Touch Punch 0.2.3

 Copyright 2011-2014, Dave Furfero
 Dual licensed under the MIT or GPL Version 2 licenses.

 Depends:
  jquery.ui.widget.js
  jquery.ui.mouse.js
*/
(function(c){function b(a,c){if(!(1<a.originalEvent.touches.length)){a.preventDefault();var b=a.originalEvent.changedTouches[0],d=document.createEvent("MouseEvents");d.initMouseEvent(c,!0,!0,window,1,b.screenX,b.screenY,b.clientX,b.clientY,!1,!1,!1,!1,0,null);a.target.dispatchEvent(d)}}c.support.touch="ontouchend"in document;if(c.support.touch){var d=c.ui.mouse.prototype,f=d._mouseInit,g=d._mouseDestroy,e;d._touchStart=function(a){!e&&this._mouseCapture(a.originalEvent.changedTouches[0])&&
(e=!0,this._touchMoved=!1,b(a,"mouseover"),b(a,"mousemove"),b(a,"mousedown"))};d._touchMove=function(a){e&&(this._touchMoved=!0,b(a,"mousemove"))};d._touchEnd=function(a){e&&(b(a,"mouseup"),b(a,"mouseout"),this._touchMoved||b(a,"click"),e=!1)};d._mouseInit=function(){this.element.bind({touchstart:c.proxy(this,"_touchStart"),touchmove:c.proxy(this,"_touchMove"),touchend:c.proxy(this,"_touchEnd")});f.call(this)};d._mouseDestroy=function(){this.element.unbind({touchstart:c.proxy(this,"_touchStart"),
touchmove:c.proxy(this,"_touchMove"),touchend:c.proxy(this,"_touchEnd")});g.call(this)}}})(jQuery);
;

// ***************************
// js.compressed/jquery/js.cookie.min.js
// ***************************
/*! js-cookie v3.0.4 | MIT */
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self,function(){var n=e.Cookies,o=e.Cookies=t();o.noConflict=function(){return e.Cookies=n,o}}())}(this,(function(){"use strict";function e(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var o in n)e[o]=n[o]}return e}var t=function t(n,o){function r(t,r,i){if("undefined"!=typeof document){"number"==typeof(i=e({},o,i)).expires&&(i.expires=new Date(Date.now()+864e5*i.expires)),i.expires&&(i.expires=i.expires.toUTCString()),t=encodeURIComponent(t).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var c="";for(var u in i)i[u]&&(c+="; "+u,!0!==i[u]&&(c+="="+i[u].split(";")[0]));return document.cookie=t+"="+n.write(r,t)+c}}return Object.create({set:r,get:function(e){if("undefined"!=typeof document&&(!arguments.length||e)){for(var t=document.cookie?document.cookie.split("; "):[],o={},r=0;r<t.length;r++){var i=t[r].split("="),c=i.slice(1).join("=");try{var u=decodeURIComponent(i[0]);if(o[u]=n.read(c,u),e===u)break}catch(e){}}return e?o[e]:o}},remove:function(t,n){r(t,"",e({},n,{expires:-1}))},withAttributes:function(n){return t(this.converter,e({},this.attributes,n))},withConverter:function(n){return t(e({},this.converter,n),this.attributes)}},{attributes:{value:Object.freeze(o)},converter:{value:Object.freeze(n)}})}({read:function(e){return'"'===e[0]&&(e=e.slice(1,-1)),e.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(e){return encodeURIComponent(e).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}},{path:"/"});return t}));
;

// ***************************
// js.compressed/responsive.js
// ***************************
/*
 jQuery throttle / debounce - v1.1 - 3/7/2010
 http://benalman.com/projects/jquery-throttle-debounce-plugin/

 Copyright (c) 2010 "Cowboy" Ben Alman
 Dual licensed under the MIT and GPL licenses.
 http://benalman.com/about/license/
*/
vBulletin.ensureObj("Responsive");
(function(d){function u(g,h){return g.find(h).addBack(h)}function B(){q.MediaQueries.setResizeEvent();q.MediaQueries.handleResizeEvent();let g=q.ChannelContent,h=(n,a=!1)=>{if(a||u(n,".conversation-toolbar-wrapper").length)g.cloneAndMoveToolbarButtons(),g.initToolbarShrink(n),g.initPmToolbarShrink(l);p.checkShrinkEvent()},l=d(document);h(l,!0);l.on("vb-instrument",n=>{h(d(n.target))});C();x();D()}function D(){if(d("html").hasClass("touch")){var g=navigator.userAgent.toLowerCase();firefoxIndex=g.indexOf("firefox");
windows7Index=g.indexOf("windows nt 6.1");-1!==firefoxIndex&&-1!==windows7Index&&d("html").removeClass("touch").addClass("no-touch")}}function C(){var g=d(".search-results-widget .conversation-toolbar");g.addClass("desktop");if(g.find(".toolbar-pagenav").length){var h=d("<div>").addClass("conversation-toolbar mobile-search-results");h.insertAfter(g);h.append(g.find(".toolset-right").clone(!0,!0))}}function x(){d(".conversation-content .videoscontainer").each(function(){d(this).siblings("div.post-signature").length||
d(this).addClass("no-signature")})}let q=vBulletin.Responsive,p=q.Debounce,y=0;q.scrollToFixedBreakPoint=480;q.ChannelContent={cloneAndMoveToolbarButtons:function(){function g(){var f=parseInt(d(this).data("js-movable-button-clone-id")||0,10);c=Math.max(c,f)}var h=d(".js-movable-toolbar-button"),l=d(".js-movable-toolbar-button-clone"),n=h,a=d(".js-movable-toolbar-button-container"),c=0,b={};h.each(g);l.each(g);++c;h=h.filter(function(){var f=d(this),m="uniq-"+f.attr("class").split(/\s+/).sort().join("-")+
"-"+f.attr("id");m=m.replace("-h-hide-on-small","");return b[m]?(f.addClass("h-hide-on-small"),!1):b[m]=!0});if(1>a.length){var e=!1;if(0<h.length){console.warn("Responsive warning: .js-movable-toolbar-button-container is not available.");var k=h.eq(0).closest(".canvas-widget");1==k.length&&(a=d("<div />").addClass("h-right h-clear hide-on-editmode b-button-group b-button-group--wrap h-margin-bottom-l js-movable-toolbar-button-container h-hide-on-large"),k.is(".b-module--contiguous")?(e=k.closest(".canvas-layout-row"),
a.removeClass("h-right").addClass("b-button-group--contiguous-layout").prependTo(e),d("<div />").addClass("js-movable-toolbar-button-container-marker-desktop h-hide-imp").prependTo(e),d("<div />").addClass("js-movable-toolbar-button-container-marker-small h-hide-imp").insertBefore(k)):a.prependTo(k),console.log("Responsive: Created .js-movable-toolbar-button-container"),e=!0)}if(!e)return}h=h.filter(function(){var f=d(this).data("js-movable-button-clone-id");if(f){var m=!1;l.each(function(){if(d(this).data("js-movable-button-clone-id")==
f)return m=!0,!1});if(m)return!1}return!0});l.each(function(){var f=d(this),m=f.data("js-movable-button-clone-id"),r=!1;n.each(function(v,t){if(d(t).data("js-movable-button-clone-id")==m)return r=!0,!1});r||f.remove()});h=h.reverse();h.each(function(){var f=d(this);f.data("js-movable-button-clone-id")||(f.clone().removeAttr("id").removeClass("js-movable-toolbar-button").addClass("h-hide-on-large js-movable-toolbar-button-clone").data("js-movable-button-clone-id",c).off("click").on("click",function(){f.trigger("click")}).prependTo(a),
f.addClass("h-hide-on-small").data("js-movable-button-clone-id",c),++c)})},initToolbarShrink:function(g){function h(b){d(".js-movable-toolbar-button-clone").toggleClass("h-hide-on-large",b);d(".js-movable-toolbar-button, .js-button-filter-my-label").toggleClass("h-hide-imp",!b)}function l(b,e){e=e.closest(".conversation-toolbar-wrapper").next(".js-under-toolbar-pagenav");1==e.length&&e.parent().is(":visible")&&(d(".js-toolbar-pagenav").toggleClass("h-hide-on-xsmall",b).toggleClass("h-hide-imp",!b),
e.toggleClass("h-show-on-xsmall",b),d(".js-subtoolbar-list-header").toggleClass("h-hide-imp",!b))}function n(b){l(!1,b);h(!0)}function a(b){l(!0,b);h(!1)}function c(b){l(!1,b);h(!1)}u(g,".conversation-toolbar > .js-shrink-event-parent").on("vbulletin:shrink vbulletin:unshrink",function(){var b=d(this),e=[n,a,c];l(!0,b);h(!0);for(const k of e){if("need_shrink"!=p.checkElementShrinkRequirement(b))break;k(b)}})},initPmToolbarShrink:function(g){function h(l){d(".js-movable-toolbar-button-container, .js-movable-toolbar-button-clone").toggleClass("h-hide-on-large",
l);d(".js-movable-toolbar-button, .js-button-filter-my-label").toggleClass("h-hide-imp",!l)}u(g,".js-pm-floating-toolbar-content.js-shrink-event-parent, .js-pm-floating-toolbar-content > .js-shrink-event-parent").on("vbulletin:shrink vbulletin:unshrink",function(){h(!0);"need_shrink"==p.checkElementShrinkRequirement(d(this))&&h(!1)})},movePmToolbarButtonContainer:function(){var g=d(".js-movable-toolbar-button-container.b-button-group--contiguous-layout");g.length&&(d("body").is(".l-small")?g.insertAfter(".js-movable-toolbar-button-container-marker-small"):
g.insertAfter(".js-movable-toolbar-button-container-marker-desktop"))}};q.MediaQueries={setResizeEvent:function(){var g=this.handleResizeEvent;d(window).on("resize orientationchange",g)},handleResizeEvent:function(){var g=d("#vb-page-body").width();g!=y&&(y=g,(g=vBulletin.contentslider)&&"function"==typeof g.handleWindowResize&&g.handleWindowResize())}};q.checkForVideoSignature=x;(function(){function g(a){if(2>a.length)return!0;let c=a.last(),b=c.position().top,e=c.outerHeight()/2+b,k=!0;a.each(function(f,
m){f=d(m);m=f.position().top;if(m!=b&&(f=f.outerHeight()/2+m,2<Math.abs(f-e)))return k=!1});return k}function h(a){var c=!1;a.each(function(b,e){if(b<a.length-1){var k=d(e),f=a.eq(b+1);b=k.offset();e=f.offset();k=k[0].getBoundingClientRect();f=f[0].getBoundingClientRect();b.bottom=b.top+k.height-1;b.right=b.left+k.width-1;e.bottom=e.top+f.height-1;e.right=e.left+f.width-1;if(!(b.right<e.left||b.bottom<e.top||e.right<b.left||e.bottom<b.top))return c=!0,!1}});return c}function l(a){p.callbacks.push(a)}
function n(){var a=p.callbacks.length,c;for(c=0;c<a;++c)p.callbacks[c]()}(function(a,c){"$:nomunge";var b=a.jQuery||a.Cowboy||(a.Cowboy={}),e;b.throttle=e=function(k,f,m,r){function v(){function w(){z=+new Date;m.apply(E,F)}function G(){t=c}var E=this,A=+new Date-z,F=arguments;r&&!t&&w();t&&clearTimeout(t);r===c&&A>k?w():!0!==f&&(t=setTimeout(r?G:w,r===c?k-A:k))}var t,z=0;"boolean"!==typeof f&&(r=m,m=f,f=c);b.guid&&(v.guid=m.guid=m.guid||b.guid++);return v};b.debounce=function(k,f,m){return m===c?
e(k,f,!1):e(k,m,!1!==f)}})(this);d.extend(p,{areElementsOnOneRow:g,checkElementShrinkRequirement:function(a){var c=a.is(".js-shrink-event-parent");let b=a.is("ul"),e="1"==a.data("vbulletin-shrink-triggered");c=c?a.find("> .js-shrink-event-child").filter(":visible"):b?a.find("> li").filter(":visible"):{length:0};return 1>c.length?e?"need_unshrink":"no_children":!g(c)||h(c)?(a.data("vbulletin-shrink-triggered","1"),"need_shrink"):e?"need_unshrink":"no_change"},checkShrinkEvent:function(a){"undefined"==
typeof a&&(a=d(".js-shrink-event-parent"));let c={need_shrink:"vbulletin:shrink",need_unshrink:"vbulletin:unshrink"};a.each((b,e)=>{b=d(e);e=p.checkElementShrinkRequirement(b);e in c&&b.trigger(c[e])})},init:function(){l(p.checkBrowserSize);l(function(){var a=d(".l-row");1>a.length||a.reverse().each(function(){var c=d(this);if(768<=c.width())return c.removeClass("l-small"),!0;var b=c.find("> .l-col__flex-1, > .l-col__flex-2, > .l-col__flex-3, > .l-col__flex-4, > .l-col__flex-5, > .l-col__flex-6"),
e=!1;c.removeClass("l-small");b.reverse().each(function(){if(this.offsetWidth<this.scrollWidth)return e=!0,!1});e&&c.addClass("l-small")})});l(function(){var a=d(".l-row > .l-col__large-1, .l-row > .l-col__large-2, .l-row > .l-col__large-3, .l-row > .l-col__large-4, .l-row > .l-col__large-5, .l-row > .l-col__large-6, .l-row > .l-col__large-7, .l-row > .l-col__large-8, .l-row > .l-col__large-9, .l-row > .l-col__large-10, .l-row > .l-col__large-11, .l-row > .l-col__large-12, .l-row > .l-col__fixed-1, .l-row > .l-col__flex-1, .l-row > .l-col__fixed-2, .l-row > .l-col__flex-2, .l-row > .l-col__fixed-3, .l-row > .l-col__flex-3, .l-row > .l-col__fixed-4, .l-row > .l-col__flex-4, .l-row > .l-col__fixed-5, .l-row > .l-col__flex-5, .l-row > .l-col__fixed-6, .l-row > .l-col__flex-6, .l-row > .l-col__small-1, .l-row > .l-col__small-2, .l-row > .l-col__small-3, .l-row > .l-col__small-4");
1>a.length||a.reverse().each(function(){var c=d(this),b=c.width(),e=parseInt(c.css("marginLeft"),10),k=parseInt(c.css("marginRight"),10);0>e&&(b+=e);0>k&&(b+=k);c.toggleClass("l-column-xsmall",480>b);c.toggleClass("l-column-small",768>b);c.toggleClass("l-column-desktop",768<=b)})});l(function(){d(".ui-dialog:visible .ui-dialog-content").each(function(a,c){a=d(c);a.trigger("vbulletin:dialogresize");a.dialog("option","position",{my:"center",at:"center",of:window,collision:"flipfit"});if(!a.is(".js-no-responsive-resize")){a.closest(".ui-dialog").hide();
c=d(window).width();a.closest(".ui-dialog").show();var b=a.dialog("option","width");if(b>c)a.data("original-dialog-width")||a.data("original-dialog-width",b),a.dialog("option","width",c);else if(b<c){var e=a.data("original-dialog-width");e&&b<e&&a.dialog("option","width",Math.min(e,c))}}})});l(p.checkShrinkEvent);l(q.ChannelContent.movePmToolbarButtonContainer);d(window).on("resize",d.debounce(300,n));n()},callbacks:[],registerCallback:l,runCallbacks:n,registerCallbackOnce:function(a){var c=!1;d.each(p.callbacks,
function(){if(a==this||""+a==""+this)return c=!0,!1});c||l(a)}})})();d(function(){B();p.init()})})(jQuery);
;

// ***************************
// js.compressed/jquery/jquery.autogrow.min.js
// ***************************
/*
 jQuery Textarea AutoGrow plugin
 Author: Bruno Sampaio
 Licensed under the MIT license
*/
(function(f){function g(b,c){if("TEXTAREA"===b.tagName){var a=f(b),d=f("<div></div>");d.addClass("autogrow-mirror");void 0!==c.id&&d.attr("id",0==index?c.id:c.id+"-"+index);void 0!==c.classes&&d.addClass(c.classes);a.addClass("autogrow-field").on("input keyup",function(e){(e=a.val())&&"\n"!=e.charAt(e.length-1)||(e+=" ");e=e.replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/ /g,"&nbsp;").replace(/\n/g,"<br/>");d.html(e);
a.height(d.height())}).off("autogrow.resize").on("autogrow.resize",function(){d.css({border:a.css("border"),"font-family":a.css("font-family"),"font-size":a.css("font-size"),"font-weight":a.css("font-weight"),"letter-spacing":a.css("letter-spacing"),"line-height":a.css("line-height"),padding:a.css("padding"),position:"absolute",visibility:"hidden","white-space":"normal",width:a.css("width"),"word-break":"break-word","z-index":-1,zoom:a.css("zoom")})}).trigger("autogrow.resize").after(d)}}f.fn.autogrow=
function(b,c){var a=this,d=this.context;void 0===c&&(c=b instanceof Object?b:{});"string"!==typeof b&&(b=null);b&&(a=f(b,d),f(document).on("DOMNodeInserted",function(a){a=a.target;f(a,d).is(b)&&g(a,c)}));a.each(function(a,b){g(b,c)});return this}})(jQuery);
;

// ***************************
// js.compressed/jquery/jquery.form.min.js
// ***************************
/*!
 * jQuery Form Plugin
 * version: 4.3.0
 * Requires jQuery v1.7.2 or later
 * Project repository: https://github.com/jquery-form/form

 * Copyright 2017 Kevin Morris
 * Copyright 2006 M. Alsup

 * Dual licensed under the LGPL-2.1+ or MIT licenses
 * https://github.com/jquery-form/form#license

 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 */
!function(r){"function"==typeof define&&define.amd?define(["jquery"],r):"object"==typeof module&&module.exports?module.exports=function(e,t){return void 0===t&&(t="undefined"!=typeof window?require("jquery"):require("jquery")(e)),r(t),t}:r(jQuery)}(function(q){"use strict";var m=/\r?\n/g,S={};S.fileapi=void 0!==q('<input type="file">').get(0).files,S.formdata=void 0!==window.FormData;var _=!!q.fn.prop;function o(e){var t=e.data;e.isDefaultPrevented()||(e.preventDefault(),q(e.target).closest("form").ajaxSubmit(t))}function i(e){var t=e.target,r=q(t);if(!r.is("[type=submit],[type=image]")){var a=r.closest("[type=submit]");if(0===a.length)return;t=a[0]}var n,o=t.form;"image"===(o.clk=t).type&&(void 0!==e.offsetX?(o.clk_x=e.offsetX,o.clk_y=e.offsetY):"function"==typeof q.fn.offset?(n=r.offset(),o.clk_x=e.pageX-n.left,o.clk_y=e.pageY-n.top):(o.clk_x=e.pageX-t.offsetLeft,o.clk_y=e.pageY-t.offsetTop)),setTimeout(function(){o.clk=o.clk_x=o.clk_y=null},100)}function N(){var e;q.fn.ajaxSubmit.debug&&(e="[jquery.form] "+Array.prototype.join.call(arguments,""),window.console&&window.console.log?window.console.log(e):window.opera&&window.opera.postError&&window.opera.postError(e))}q.fn.attr2=function(){if(!_)return this.attr.apply(this,arguments);var e=this.prop.apply(this,arguments);return e&&e.jquery||"string"==typeof e?e:this.attr.apply(this,arguments)},q.fn.ajaxSubmit=function(M,e,t,r){if(!this.length)return N("ajaxSubmit: skipping submit process - no element selected"),this;var O,a,n,o,X=this;"function"==typeof M?M={success:M}:"string"==typeof M||!1===M&&0<arguments.length?(M={url:M,data:e,dataType:t},"function"==typeof r&&(M.success=r)):void 0===M&&(M={}),O=M.method||M.type||this.attr2("method"),n=(n=(n="string"==typeof(a=M.url||this.attr2("action"))?q.trim(a):"")||window.location.href||"")&&(n.match(/^([^#]+)/)||[])[1],o=/(MSIE|Trident)/.test(navigator.userAgent||"")&&/^https/i.test(window.location.href||"")?"javascript:false":"about:blank",M=q.extend(!0,{url:n,success:q.ajaxSettings.success,type:O||q.ajaxSettings.type,iframeSrc:o},M);var i={};if(this.trigger("form-pre-serialize",[this,M,i]),i.veto)return N("ajaxSubmit: submit vetoed via form-pre-serialize trigger"),this;if(M.beforeSerialize&&!1===M.beforeSerialize(this,M))return N("ajaxSubmit: submit aborted via beforeSerialize callback"),this;var s=M.traditional;void 0===s&&(s=q.ajaxSettings.traditional);var u,c,C=[],l=this.formToArray(M.semantic,C,M.filtering);if(M.data&&(c=q.isFunction(M.data)?M.data(l):M.data,M.extraData=c,u=q.param(c,s)),M.beforeSubmit&&!1===M.beforeSubmit(l,this,M))return N("ajaxSubmit: submit aborted via beforeSubmit callback"),this;if(this.trigger("form-submit-validate",[l,this,M,i]),i.veto)return N("ajaxSubmit: submit vetoed via form-submit-validate trigger"),this;var f=q.param(l,s);u&&(f=f?f+"&"+u:u),"GET"===M.type.toUpperCase()?(M.url+=(0<=M.url.indexOf("?")?"&":"?")+f,M.data=null):M.data=f;var d,m,p,h=[];M.resetForm&&h.push(function(){X.resetForm()}),M.clearForm&&h.push(function(){X.clearForm(M.includeHidden)}),!M.dataType&&M.target?(d=M.success||function(){},h.push(function(e,t,r){var a=arguments,n=M.replaceTarget?"replaceWith":"html";q(M.target)[n](e).each(function(){d.apply(this,a)})})):M.success&&(q.isArray(M.success)?q.merge(h,M.success):h.push(M.success)),M.success=function(e,t,r){for(var a=M.context||this,n=0,o=h.length;n<o;n++)h[n].apply(a,[e,t,r||X,X])},M.error&&(m=M.error,M.error=function(e,t,r){var a=M.context||this;m.apply(a,[e,t,r,X])}),M.complete&&(p=M.complete,M.complete=function(e,t){var r=M.context||this;p.apply(r,[e,t,X])});var v=0<q("input[type=file]:enabled",this).filter(function(){return""!==q(this).val()}).length,g="multipart/form-data",x=X.attr("enctype")===g||X.attr("encoding")===g,y=S.fileapi&&S.formdata;N("fileAPI :"+y);var b,T=(v||x)&&!y;!1!==M.iframe&&(M.iframe||T)?M.closeKeepAlive?q.get(M.closeKeepAlive,function(){b=w(l)}):b=w(l):b=(v||x)&&y?function(e){for(var r=new FormData,t=0;t<e.length;t++)r.append(e[t].name,e[t].value);if(M.extraData){var a=function(e){var t,r,a=q.param(e,M.traditional).split("&"),n=a.length,o=[];for(t=0;t<n;t++)a[t]=a[t].replace(/\+/g," "),r=a[t].split("="),o.push([decodeURIComponent(r[0]),decodeURIComponent(r[1])]);return o}(M.extraData);for(t=0;t<a.length;t++)a[t]&&r.append(a[t][0],a[t][1])}M.data=null;var n=q.extend(!0,{},q.ajaxSettings,M,{contentType:!1,processData:!1,cache:!1,type:O||"POST"});M.uploadProgress&&(n.xhr=function(){var e=q.ajaxSettings.xhr();return e.upload&&e.upload.addEventListener("progress",function(e){var t=0,r=e.loaded||e.position,a=e.total;e.lengthComputable&&(t=Math.ceil(r/a*100)),M.uploadProgress(e,r,a,t)},!1),e});n.data=null;var o=n.beforeSend;return n.beforeSend=function(e,t){M.formData?t.data=M.formData:t.data=r,o&&o.call(this,e,t)},q.ajax(n)}(l):q.ajax(M),X.removeData("jqxhr").data("jqxhr",b);for(var j=0;j<C.length;j++)C[j]=null;return this.trigger("form-submit-notify",[this,M]),this;function w(e){var t,r,l,f,o,d,m,p,a,n,h,v,i=X[0],g=q.Deferred();if(g.abort=function(e){p.abort(e)},e)for(r=0;r<C.length;r++)t=q(C[r]),_?t.prop("disabled",!1):t.removeAttr("disabled");(l=q.extend(!0,{},q.ajaxSettings,M)).context=l.context||l,o="jqFormIO"+(new Date).getTime();var s=i.ownerDocument,u=X.closest("body");if(l.iframeTarget?(n=(d=q(l.iframeTarget,s)).attr2("name"))?o=n:d.attr2("name",o):(d=q('<iframe name="'+o+'" src="'+l.iframeSrc+'" />',s)).css({position:"absolute",top:"-1000px",left:"-1000px"}),m=d[0],p={aborted:0,responseText:null,responseXML:null,status:0,statusText:"n/a",getAllResponseHeaders:function(){},getResponseHeader:function(){},setRequestHeader:function(){},abort:function(e){var t="timeout"===e?"timeout":"aborted";N("aborting upload... "+t),this.aborted=1;try{m.contentWindow.document.execCommand&&m.contentWindow.document.execCommand("Stop")}catch(e){}d.attr("src",l.iframeSrc),p.error=t,l.error&&l.error.call(l.context,p,t,e),f&&q.event.trigger("ajaxError",[p,l,t]),l.complete&&l.complete.call(l.context,p,t)}},(f=l.global)&&0==q.active++&&q.event.trigger("ajaxStart"),f&&q.event.trigger("ajaxSend",[p,l]),l.beforeSend&&!1===l.beforeSend.call(l.context,p,l))return l.global&&q.active--,g.reject(),g;if(p.aborted)return g.reject(),g;(a=i.clk)&&(n=a.name)&&!a.disabled&&(l.extraData=l.extraData||{},l.extraData[n]=a.value,"image"===a.type&&(l.extraData[n+".x"]=i.clk_x,l.extraData[n+".y"]=i.clk_y));var x=1,y=2;function b(t){var r=null;try{t.contentWindow&&(r=t.contentWindow.document)}catch(e){N("cannot get iframe.contentWindow document: "+e)}if(r)return r;try{r=t.contentDocument?t.contentDocument:t.document}catch(e){N("cannot get iframe.contentDocument: "+e),r=t.document}return r}var c=q("meta[name=csrf-token]").attr("content"),T=q("meta[name=csrf-param]").attr("content");function j(){var e=X.attr2("target"),t=X.attr2("action"),r=X.attr("enctype")||X.attr("encoding")||"multipart/form-data";i.setAttribute("target",o),O&&!/post/i.test(O)||i.setAttribute("method","POST"),t!==l.url&&i.setAttribute("action",l.url),l.skipEncodingOverride||O&&!/post/i.test(O)||X.attr({encoding:"multipart/form-data",enctype:"multipart/form-data"}),l.timeout&&(v=setTimeout(function(){h=!0,A(x)},l.timeout));var a=[];try{if(l.extraData)for(var n in l.extraData)l.extraData.hasOwnProperty(n)&&(q.isPlainObject(l.extraData[n])&&l.extraData[n].hasOwnProperty("name")&&l.extraData[n].hasOwnProperty("value")?a.push(q('<input type="hidden" name="'+l.extraData[n].name+'">',s).val(l.extraData[n].value).appendTo(i)[0]):a.push(q('<input type="hidden" name="'+n+'">',s).val(l.extraData[n]).appendTo(i)[0]));l.iframeTarget||d.appendTo(u),m.attachEvent?m.attachEvent("onload",A):m.addEventListener("load",A,!1),setTimeout(function e(){try{var t=b(m).readyState;N("state = "+t),t&&"uninitialized"===t.toLowerCase()&&setTimeout(e,50)}catch(e){N("Server abort: ",e," (",e.name,")"),A(y),v&&clearTimeout(v),v=void 0}},15);try{i.submit()}catch(e){document.createElement("form").submit.apply(i)}}finally{i.setAttribute("action",t),i.setAttribute("enctype",r),e?i.setAttribute("target",e):X.removeAttr("target"),q(a).remove()}}T&&c&&(l.extraData=l.extraData||{},l.extraData[T]=c),l.forceSync?j():setTimeout(j,10);var w,S,k,D=50;function A(e){if(!p.aborted&&!k){if((S=b(m))||(N("cannot access response document"),e=y),e===x&&p)return p.abort("timeout"),void g.reject(p,"timeout");if(e===y&&p)return p.abort("server abort"),void g.reject(p,"error","server abort");if(S&&S.location.href!==l.iframeSrc||h){m.detachEvent?m.detachEvent("onload",A):m.removeEventListener("load",A,!1);var t,r="success";try{if(h)throw"timeout";var a="xml"===l.dataType||S.XMLDocument||q.isXMLDoc(S);if(N("isXml="+a),!a&&window.opera&&(null===S.body||!S.body.innerHTML)&&--D)return N("requeing onLoad callback, DOM not available"),void setTimeout(A,250);var n=S.body?S.body:S.documentElement;p.responseText=n?n.innerHTML:null,p.responseXML=S.XMLDocument?S.XMLDocument:S,a&&(l.dataType="xml"),p.getResponseHeader=function(e){return{"content-type":l.dataType}[e.toLowerCase()]},n&&(p.status=Number(n.getAttribute("status"))||p.status,p.statusText=n.getAttribute("statusText")||p.statusText);var o,i,s,u=(l.dataType||"").toLowerCase(),c=/(json|script|text)/.test(u);c||l.textarea?(o=S.getElementsByTagName("textarea")[0])?(p.responseText=o.value,p.status=Number(o.getAttribute("status"))||p.status,p.statusText=o.getAttribute("statusText")||p.statusText):c&&(i=S.getElementsByTagName("pre")[0],s=S.getElementsByTagName("body")[0],i?p.responseText=i.textContent?i.textContent:i.innerText:s&&(p.responseText=s.textContent?s.textContent:s.innerText)):"xml"===u&&!p.responseXML&&p.responseText&&(p.responseXML=F(p.responseText));try{w=E(p,u,l)}catch(e){r="parsererror",p.error=t=e||r}}catch(e){N("error caught: ",e),r="error",p.error=t=e||r}p.aborted&&(N("upload aborted"),r=null),p.status&&(r=200<=p.status&&p.status<300||304===p.status?"success":"error"),"success"===r?(l.success&&l.success.call(l.context,w,"success",p),g.resolve(p.responseText,"success",p),f&&q.event.trigger("ajaxSuccess",[p,l])):r&&(void 0===t&&(t=p.statusText),l.error&&l.error.call(l.context,p,r,t),g.reject(p,"error",t),f&&q.event.trigger("ajaxError",[p,l,t])),f&&q.event.trigger("ajaxComplete",[p,l]),f&&!--q.active&&q.event.trigger("ajaxStop"),l.complete&&l.complete.call(l.context,p,r),k=!0,l.timeout&&clearTimeout(v),setTimeout(function(){l.iframeTarget?d.attr("src",l.iframeSrc):d.remove(),p.responseXML=null},100)}}}var F=q.parseXML||function(e,t){return window.ActiveXObject?((t=new ActiveXObject("Microsoft.XMLDOM")).async="false",t.loadXML(e)):t=(new DOMParser).parseFromString(e,"text/xml"),t&&t.documentElement&&"parsererror"!==t.documentElement.nodeName?t:null},L=q.parseJSON||function(e){return window.eval("("+e+")")},E=function(e,t,r){var a=e.getResponseHeader("content-type")||"",n=("xml"===t||!t)&&0<=a.indexOf("xml"),o=n?e.responseXML:e.responseText;return n&&"parsererror"===o.documentElement.nodeName&&q.error&&q.error("parsererror"),r&&r.dataFilter&&(o=r.dataFilter(o,t)),"string"==typeof o&&(("json"===t||!t)&&0<=a.indexOf("json")?o=L(o):("script"===t||!t)&&0<=a.indexOf("javascript")&&q.globalEval(o)),o};return g}},q.fn.ajaxForm=function(e,t,r,a){if(("string"==typeof e||!1===e&&0<arguments.length)&&(e={url:e,data:t,dataType:r},"function"==typeof a&&(e.success=a)),(e=e||{}).delegation=e.delegation&&q.isFunction(q.fn.on),e.delegation||0!==this.length)return e.delegation?(q(document).off("submit.form-plugin",this.selector,o).off("click.form-plugin",this.selector,i).on("submit.form-plugin",this.selector,e,o).on("click.form-plugin",this.selector,e,i),this):(e.beforeFormUnbind&&e.beforeFormUnbind(this,e),this.ajaxFormUnbind().on("submit.form-plugin",e,o).on("click.form-plugin",e,i));var n={s:this.selector,c:this.context};return!q.isReady&&n.s?(N("DOM not ready, queuing ajaxForm"),q(function(){q(n.s,n.c).ajaxForm(e)})):N("terminating; zero elements found by selector"+(q.isReady?"":" (DOM not ready)")),this},q.fn.ajaxFormUnbind=function(){return this.off("submit.form-plugin click.form-plugin")},q.fn.formToArray=function(e,t,r){var a=[];if(0===this.length)return a;var n,o,i,s,u,c,l,f,d,m,p=this[0],h=this.attr("id"),v=(v=e||void 0===p.elements?p.getElementsByTagName("*"):p.elements)&&q.makeArray(v);if(h&&(e||/(Edge|Trident)\//.test(navigator.userAgent))&&(n=q(':input[form="'+h+'"]').get()).length&&(v=(v||[]).concat(n)),!v||!v.length)return a;for(q.isFunction(r)&&(v=q.map(v,r)),o=0,c=v.length;o<c;o++)if((m=(u=v[o]).name)&&!u.disabled)if(e&&p.clk&&"image"===u.type)p.clk===u&&(a.push({name:m,value:q(u).val(),type:u.type}),a.push({name:m+".x",value:p.clk_x},{name:m+".y",value:p.clk_y}));else if((s=q.fieldValue(u,!0))&&s.constructor===Array)for(t&&t.push(u),i=0,l=s.length;i<l;i++)a.push({name:m,value:s[i]});else if(S.fileapi&&"file"===u.type){t&&t.push(u);var g=u.files;if(g.length)for(i=0;i<g.length;i++)a.push({name:m,value:g[i],type:u.type});else a.push({name:m,value:"",type:u.type})}else null!=s&&(t&&t.push(u),a.push({name:m,value:s,type:u.type,required:u.required}));return e||!p.clk||(m=(d=(f=q(p.clk))[0]).name)&&!d.disabled&&"image"===d.type&&(a.push({name:m,value:f.val()}),a.push({name:m+".x",value:p.clk_x},{name:m+".y",value:p.clk_y})),a},q.fn.formSerialize=function(e){return q.param(this.formToArray(e))},q.fn.fieldSerialize=function(n){var o=[];return this.each(function(){var e=this.name;if(e){var t=q.fieldValue(this,n);if(t&&t.constructor===Array)for(var r=0,a=t.length;r<a;r++)o.push({name:e,value:t[r]});else null!=t&&o.push({name:this.name,value:t})}}),q.param(o)},q.fn.fieldValue=function(e){for(var t=[],r=0,a=this.length;r<a;r++){var n=this[r],o=q.fieldValue(n,e);null==o||o.constructor===Array&&!o.length||(o.constructor===Array?q.merge(t,o):t.push(o))}return t},q.fieldValue=function(e,t){var r=e.name,a=e.type,n=e.tagName.toLowerCase();if(void 0===t&&(t=!0),t&&(!r||e.disabled||"reset"===a||"button"===a||("checkbox"===a||"radio"===a)&&!e.checked||("submit"===a||"image"===a)&&e.form&&e.form.clk!==e||"select"===n&&-1===e.selectedIndex))return null;if("select"!==n)return q(e).val().replace(m,"\r\n");var o=e.selectedIndex;if(o<0)return null;for(var i=[],s=e.options,u="select-one"===a,c=u?o+1:s.length,l=u?o:0;l<c;l++){var f=s[l];if(f.selected&&!f.disabled){var d=(d=f.value)||(f.attributes&&f.attributes.value&&!f.attributes.value.specified?f.text:f.value);if(u)return d;i.push(d)}}return i},q.fn.clearForm=function(e){return this.each(function(){q("input,select,textarea",this).clearFields(e)})},q.fn.clearFields=q.fn.clearInputs=function(r){var a=/^(?:color|date|datetime|email|month|number|password|range|search|tel|text|time|url|week)$/i;return this.each(function(){var e=this.type,t=this.tagName.toLowerCase();a.test(e)||"textarea"===t?this.value="":"checkbox"===e||"radio"===e?this.checked=!1:"select"===t?this.selectedIndex=-1:"file"===e?/MSIE/.test(navigator.userAgent)?q(this).replaceWith(q(this).clone(!0)):q(this).val(""):r&&(!0===r&&/hidden/.test(e)||"string"==typeof r&&q(this).is(r))&&(this.value="")})},q.fn.resetForm=function(){return this.each(function(){var t=q(this),e=this.tagName.toLowerCase();switch(e){case"input":this.checked=this.defaultChecked;case"textarea":return this.value=this.defaultValue,!0;case"option":case"optgroup":var r=t.parents("select");return r.length&&r[0].multiple?"option"===e?this.selected=this.defaultSelected:t.find("option").resetForm():r.resetForm(),!0;case"select":return t.find("option").each(function(e){if(this.selected=this.defaultSelected,this.defaultSelected&&!t[0].multiple)return t[0].selectedIndex=e,!1}),!0;case"label":var a=q(t.attr("for")),n=t.find("input,select,textarea");return a[0]&&n.unshift(a[0]),n.resetForm(),!0;case"form":return"function"!=typeof this.reset&&("object"!=typeof this.reset||this.reset.nodeType)||this.reset(),!0;default:return t.find("form,input,label,select,textarea").resetForm(),!0}})},q.fn.enable=function(e){return void 0===e&&(e=!0),this.each(function(){this.disabled=!e})},q.fn.selected=function(r){return void 0===r&&(r=!0),this.each(function(){var e,t=this.type;"checkbox"===t||"radio"===t?this.checked=r:"option"===this.tagName.toLowerCase()&&(e=q(this).parent("select"),r&&e[0]&&"select-one"===e[0].type&&e.find("option").selected(!1),this.selected=r)})},q.fn.ajaxSubmit.debug=!1});
;

// ***************************
// js.compressed/jquery/jquery.selectBox.min.js
// ***************************
/*
 jQuery selectBox - A cosmetic, styleable replacement for SELECT elements

  Copyright 2012 Cory LaViska for A Beautiful Site, LLC.

  https://github.com/claviska/jquery-selectBox

  Licensed under both the MIT license and the GNU GPLv2 (same as jQuery: http://jquery.org/license)


  Note: Modified for vBulletin. Grep for 'vBulletin' to see the changes.
*/
jQuery&&function(c){c.extend(c.fn,{selectBox:function(x,k){var y,p="",z=navigator.platform.match(/mac/i),E=function(a,b){if(navigator.userAgent.match(/iPad|iPhone|Android|IEMobile|BlackBerry/i)||"select"!==a.tagName.toLowerCase())return!1;a=c(a);if(a.data("selectBox-control")||a.is(":hidden")&&(!b||!b.allowHidden))return!1;var e=c('<a class="selectBox" />'),d=a.attr("multiple")||1<parseInt(a.attr("size"));b=b||{};e.addClass(a.attr("class")).attr("title",a.attr("title")||"").attr("tabindex",
parseInt(a.attr("tabindex"))).css("display","inline-block").on("focus.selectBox",function(){this!==document.activeElement&&document.body!==document.activeElement&&c(document.activeElement).blur();e.hasClass("selectBox-active")||(e.addClass("selectBox-active"),a.trigger("focus"))}).on("blur.selectBox",function(){e.hasClass("selectBox-active")&&(e.removeClass("selectBox-active"),a.trigger("blur"))});if(!c(window).data("selectBox-bindings"))c(window).data("selectBox-bindings",!0).on("scroll.selectBox",
l).on("resize.selectBox",l);a.attr("disabled")&&e.addClass("selectBox-disabled");a.on("click.selectBox",function(a){e.focus();a.preventDefault()});if(d){var f=t(a,"inline");e.append(f).data("selectBox-options",f).addClass("selectBox-inline selectBox-menuShowing").on("keydown.selectBox",function(b){A(a,b)}).on("keypress.selectBox",function(b){B(a,b)}).on("mousedown.selectBox",function(a){c(a.target).is("A.selectBox-inline")&&a.preventDefault();e.hasClass("selectBox-focus")||e.focus()}).insertAfter(a);
e.width(a.css("fontSize",e.css("fontSize")).outerWidth());if(!a[0].style.height){d=a.attr("size")?parseInt(a.attr("size")):5;var h=e.clone().removeAttr("id").css({position:"absolute",top:"-9999em"}).show().appendTo("body");h.find(".selectBox-options").html("<li><a> </a></li>");var g=parseInt(h.find(".selectBox-options A:first").html("&nbsp;").outerHeight());h.remove();e.height(g*d)}}else d=c('<span class="selectBox-label" />'),h=c('<span class="selectBox-arrow" />'),d.attr("class",C(a)).text(D(a)),
f=t(a,"dropdown"),f.appendTo("BODY"),e.data("selectBox-options",f).addClass("selectBox-dropdown").append(d).append(h).on("mousedown.selectBox",function(b){e.hasClass("selectBox-menuShowing")?l():(b.stopPropagation(),f.data("selectBox-down-at-x",b.screenX).data("selectBox-down-at-y",b.screenY),m(a))}).on("keydown.selectBox",function(b){A(a,b)}).on("keypress.selectBox",function(b){B(a,b)}).on("open.selectBox",function(b,c){c&&!0===c._selectBox||m(a)}).on("close.selectBox",function(a,b){b&&!0===b._selectBox||
l()}).insertAfter(a),g=a.addClass("h-pre-selectbox").outerWidth(),e.width(g),h=e.width()-h.outerWidth()-parseInt(d.css("paddingLeft"))-parseInt(d.css("paddingRight")),d.width(h);u(e);a.addClass("selectBox").data("selectBox-control",e).data("selectBox-settings",b).hide()},t=function(a,b){var e=function(a,b){a.children("OPTION, OPTGROUP").each(function(){if(c(this).is("OPTION"))if(0<c(this).length){var a=c(this),d=b,f=c("<li />"),h=c("<a />");f.addClass(a.attr("class"));f.data(a.data());h.attr("rel",
a.val()).text(a.text());f.append(h);a.attr("disabled")&&f.addClass("selectBox-disabled");a.prop("selected")&&f.addClass("selectBox-selected");d.append(f)}else b.append("<li> </li>");else a=c('<li class="selectBox-optgroup" />'),a.text(c(this).attr("label")),b.append(a),b=e(c(this),b)});return b};switch(b){case "inline":var d=c('<ul class="selectBox-options" />');d=e(a,d);d.find("A").on("mouseover.selectBox",function(b){n(a,c(this).parent())}).on("mouseout.selectBox",function(b){v(a,c(this).parent())}).on("mousedown.selectBox",
function(b){b.preventDefault();a.selectBox("control").hasClass("selectBox-active")||a.selectBox("control").focus()}).on("mouseup.selectBox",function(b){l();q(a,c(this).parent(),b)});u(d);return d;case "dropdown":d=c('<ul class="selectBox-dropdown-menu selectBox-options" />');d=e(a,d);d.data("selectBox-select",a).css("display","none").appendTo("BODY").find("A").on("mousedown.selectBox",function(a){a.preventDefault();a.screenX===d.data("selectBox-down-at-x")&&a.screenY===d.data("selectBox-down-at-y")&&
(d.removeData("selectBox-down-at-x").removeData("selectBox-down-at-y"),l())}).on("mouseup.selectBox",function(b){if(b.screenX!==d.data("selectBox-down-at-x")||b.screenY!==d.data("selectBox-down-at-y"))d.removeData("selectBox-down-at-x").removeData("selectBox-down-at-y"),q(a,c(this).parent()),l()}).on("mouseover.selectBox",function(b){n(a,c(this).parent())}).on("mouseout.selectBox",function(b){v(a,c(this).parent())});b=a.attr("class")||"";if(""!==b){b=b.split(" ");for(var f in b)d.addClass(b[f]+"-selectBox-dropdown-menu")}u(d);
return d}},C=function(a){return("selectBox-label "+(c(a).find("OPTION:selected").attr("class")||"")).replace(/\s+$/,"")},D=function(a){return c(a).find("OPTION:selected").text()||String.fromCharCode(160)},w=function(a){a=c(a);var b=a.data("selectBox-control");b&&b.find(".selectBox-label").attr("class",C(a)).text(D(a))},m=function(a){a=c(a);var b=a.data("selectBox-control")||c(),e=a.data("selectBox-settings")||{},d=b.data("selectBox-options")||c();if(b.hasClass("selectBox-disabled"))return!1;l();var f=
parseInt(b.css("borderBottomWidth"))||0;d.width(b.innerWidth()).css({top:b.offset().top+b.outerHeight()-f,left:b.offset().left});if(a.triggerHandler("beforeopen"))return!1;f=function(){a.triggerHandler("open",{_selectBox:!0});var e=c(window).scrollTop(),f=e+c(window).height(),k=d.offset().top,l=k+d.outerHeight();0<=k-e&&0<=f-l||d.css("top",parseFloat(d.css("top"))-(b.outerHeight()+d.outerHeight()))};switch(e.menuTransition){case "fade":d.fadeIn(e.menuSpeed,f);break;case "slide":d.slideDown(e.menuSpeed,
f);break;default:d.show(e.menuSpeed,f)}e.menuSpeed||f();e=d.find(".selectBox-selected:first");r(a,e,!0);n(a,e);b.addClass("selectBox-menuShowing");c(document).on("mousedown.selectBox",function(a){c(a.target).parents().addBack().hasClass("selectBox-options")||l()})},l=function(){0!==c(".selectBox-dropdown-menu:visible").length&&(c(document).off("mousedown.selectBox"),c(".selectBox-dropdown-menu").each(function(){var a=c(this),b=a.data("selectBox-select")||c(),e=b.data("selectBox-control")||c(),d=b.data("selectBox-settings")||
{};if(b.triggerHandler("beforeclose"))return!1;var f=function(){b.triggerHandler("close",{_selectBox:!0})};switch(d.menuTransition){case "fade":a.fadeOut(d.menuSpeed,f);break;case "slide":a.slideUp(d.menuSpeed,f);break;default:a.hide(d.menuSpeed,f)}d.menuSpeed||f();e.removeClass("selectBox-menuShowing")}))},q=function(a,b,e){a=c(a);b=c(b);var d=a.data("selectBox-control")||c();a.data("selectBox-settings");if(d.hasClass("selectBox-disabled")||0===b.length||b.hasClass("selectBox-disabled"))return!1;
a.attr("multiple")?e.shiftKey&&d.data("selectBox-last-selected")?(b.toggleClass("selectBox-selected"),e=b.index()>d.data("selectBox-last-selected").index()?b.siblings().slice(d.data("selectBox-last-selected").index(),b.index()):b.siblings().slice(b.index(),d.data("selectBox-last-selected").index()),e=e.not(".selectBox-optgroup, .selectBox-disabled"),b.hasClass("selectBox-selected")?e.addClass("selectBox-selected"):e.removeClass("selectBox-selected")):z&&e.metaKey||!z&&e.ctrlKey?b.toggleClass("selectBox-selected"):
(b.siblings().removeClass("selectBox-selected"),b.addClass("selectBox-selected")):(b.siblings().removeClass("selectBox-selected"),b.addClass("selectBox-selected"));d.hasClass("selectBox-dropdown")&&d.find(".selectBox-label").text(b.text());var f=0,h=[];a.attr("multiple")?d.find(".selectBox-selected A").each(function(){h[f++]=c(this).attr("rel")}):h=b.find("A").attr("rel");d.data("selectBox-last-selected",b);a.val()!==h&&(a.val(h),w(a),a.trigger("change"));return!0},n=function(a,b){a=c(a);b=c(b);((a.data("selectBox-control")||
c()).data("selectBox-options")||c()).find(".selectBox-hover").removeClass("selectBox-hover");b.addClass("selectBox-hover")},v=function(a,b){a=c(a);c(b);((a.data("selectBox-control")||c()).data("selectBox-options")||c()).find(".selectBox-hover").removeClass("selectBox-hover")},r=function(a,b,e){if(b&&0!==b.length){a=c(a);a=a.data("selectBox-control")||c();var d=a.data("selectBox-options")||c();a=a.hasClass("selectBox-dropdown")?d:d.parent();d=parseInt(b.offset().top-a.position().top);var f=parseInt(d+
b.outerHeight());e?a.scrollTop(b.offset().top-a.offset().top+a.scrollTop()-a.height()/2):(0>d&&a.scrollTop(b.offset().top-a.offset().top+a.scrollTop()),f>a.height()&&a.scrollTop(b.offset().top+b.outerHeight()-a.offset().top+a.scrollTop()-a.height()))}},A=function(a,b){a=c(a);var e=a.data("selectBox-control")||c(),d=e.data("selectBox-options")||c(),f=a.data("selectBox-settings")||{},h;if(!e.hasClass("selectBox-disabled"))switch(b.keyCode){case 8:b.preventDefault();p="";break;case 9:case 27:l();v(a);
break;case 13:e.hasClass("selectBox-menuShowing")?(q(a,d.find("LI.selectBox-hover:first"),b),e.hasClass("selectBox-dropdown")&&l()):m(a);break;case 38:case 37:b.preventDefault();if(e.hasClass("selectBox-menuShowing")){var g=d.find(".selectBox-hover").prev("LI");e=d.find("LI:not(.selectBox-optgroup)").length;for(h=0;(0===g.length||g.hasClass("selectBox-disabled")||g.hasClass("selectBox-optgroup"))&&!(g=g.prev("LI"),0===g.length&&(g=f.loopOptions?d.find("LI:last"):d.find("LI:first")),++h>=e););n(a,
g);q(a,g,b);r(a,g)}else m(a);break;case 40:case 39:if(b.preventDefault(),e.hasClass("selectBox-menuShowing")){g=d.find(".selectBox-hover").next("LI");e=d.find("LI:not(.selectBox-optgroup)").length;for(h=0;(0===g.length||g.hasClass("selectBox-disabled")||g.hasClass("selectBox-optgroup"))&&!(g=g.next("LI"),0===g.length&&(g=f.loopOptions?d.find("LI:first"):d.find("LI:last")),++h>=e););n(a,g);q(a,g,b);r(a,g)}else m(a)}},B=function(a,b){a=c(a);var e=a.data("selectBox-control")||c(),d=e.data("selectBox-options")||
c();if(!e.hasClass("selectBox-disabled"))switch(b.keyCode){case 9:case 27:case 13:case 38:case 37:case 40:case 39:break;default:e.hasClass("selectBox-menuShowing")||m(a),b.preventDefault(),clearTimeout(y),p+=String.fromCharCode(b.charCode||b.keyCode),d.find("A").each(function(){if(c(this).text().substr(0,p.length).toLowerCase()===p.toLowerCase())return n(a,c(this).parent()),r(a,c(this).parent()),!1}),y=setTimeout(function(){p=""},1E3)}},F=function(a,b){a=c(a);a.val(b);b=a.val();null!==b||a.attr("multiple")||
(a[0].selectedIndex=0,b=a.val());var e=a.data("selectBox-control");if(e){var d=a.data("selectBox-settings")||{};e=e.data("selectBox-options")||c();w(a);e.find(".selectBox-selected").removeClass("selectBox-selected");e.find("A").each(function(){if("object"===typeof b)for(var a=0;a<b.length;a++)c(this).attr("rel")==b[a]&&c(this).parent().addClass("selectBox-selected");else c(this).attr("rel")==b&&c(this).parent().addClass("selectBox-selected")});d.change&&d.change.call(a)}},u=function(a){c(a).css("MozUserSelect",
"none").on("selectstart",function(a){a.preventDefault()})};switch(x){case "control":return c(this).data("selectBox-control");case "settings":if(!k)return c(this).data("selectBox-settings");c(this).each(function(){c(this).data("selectBox-settings",c.extend(!0,c(this).data("selectBox-settings"),k))});break;case "options":if(void 0===k)return c(this).data("selectBox-control").data("selectBox-options");c(this).each(function(){var a=c(this);var b=a.data("selectBox-control")||c();a.data("selectBox-settings");
switch(typeof k){case "string":a.html(k);break;case "object":for(f in a.html(""),k)if(null!==k[f])if("object"===typeof k[f]){var e=c('<optgroup label="'+f+'" />');for(d in k[f])e.append('<option value="'+d+'">'+k[f][d]+"</option>");a.append(e)}else e=c('<option value="'+f+'">'+k[f]+"</option>"),a.append(e)}if(b){b.data("selectBox-options").remove();var d=b.hasClass("selectBox-dropdown")?"dropdown":"inline";var f=t(a,d);b.data("selectBox-options",f);switch(d){case "inline":b.append(f);break;case "dropdown":w(a),
c("BODY").append(f)}}});break;case "value":if(void 0===k)return c(this).val();c(this).each(function(){F(this,k)});break;case "refresh":c(this).each(function(){var a=c(this);a.selectBox("options",a.html())});break;case "enable":c(this).each(function(){var a=c(this);a.attr("disabled",!1);(a=a.data("selectBox-control"))&&a.removeClass("selectBox-disabled")});break;case "disable":c(this).each(function(){var a=c(this);a.attr("disabled",!0);(a=a.data("selectBox-control"))&&a.addClass("selectBox-disabled")});
break;case "destroy":c(this).each(function(){var a=c(this);var b=a.data("selectBox-control");b&&((b.data("selectBox-options")||c()).remove(),b.remove(),a.removeClass("selectBox").removeData("selectBox-control").data("selectBox-control",null).removeData("selectBox-settings").data("selectBox-settings",null).show())});break;default:c(this).each(function(){E(this,x)})}return c(this)}})}(jQuery);
;

// ***************************
// js.compressed/storage.js
// ***************************
vBulletin.createStorageTools=function(f,l){function g(a){if(!a.loaded){a.loaded=!0;try{var b=localStorage.getItem(f+a.name);if(b)if(b=JSON.parse(b),a.istimed){a.cache.values=b.values||a.cache.values;a.cache.times=b.times||a.cache.times;b=!1;var c=a.cache.values,d=a.cache.times,e;for(e in c)d[e]<a.latest&&(delete c[e],delete d[e],b=!0);b&&h(a)}else a.cache.values=b}catch(n){}}}function h(a){try{var b=f+a.name,c=a.cache;a.istimed||(c=c.values);localStorage.removeItem(b);localStorage.setItem(b,JSON.stringify(c))}catch(d){}}
function k(a,b,c,d){this.loaded=!1;this.name=a;this.cache={values:{},times:{}};if(this.istimed=!!b)this.latest=c,this.current=d}function m(a,b,c=!1,d=!0){let e={};c&&(!0===c&&(c=365),e.expires=c);l.set((d?f:"")+a,b,e)}try{localStorage.removeItem("vbcache-")}catch(a){}k.prototype={get:function(a){g(this);var b=this.cache.values;return b.hasOwnProperty(a)?b[a]:null},getAll:function(){g(this);return this.cache.values},isSet:function(a){g(this);return this.cache.values.hasOwnProperty(a)},set:function(a,
b){g(this);var c=a;$.isPlainObject(a)||(c={},c[a]=b);for(_key in c)this.cache.values[_key]=c[_key],this.istimed&&(this.cache.times[_key]=this.current);h(this)},unset:function(a){g(this);delete this.cache.values[a];delete this.cache.times[a];h(this)},unsetAll:function(){this.cache={values:{},times:{}};localStorage.removeItem(f+this.name)}};return{createStorage:a=>new k(a),createStorageTimed:(a,b,c)=>new k(a,!0,b,c),setCookie:m,getCookie:function(a,b=!0){return l.get((b?f:"")+a)},deleteCookie:(a,b=
!0)=>m(a,"",-1,b)}};
;

// ***************************
// js.compressed/sitedata.js
// ***************************
vBulletin.createSiteDataTools=function(v){function r(){var a=[],c=[];(new Set(g)).forEach(function(b){a.push(b)});a=a.filter(function(b){return!h.isSet(b)});(new Set(k)).forEach(function(b){c.push(b)});c=c.filter(function(b){return!l.isSet(b+n)});vBulletin.loadingIndicator.suppressNextAjaxIndicator();$.ajax({url:v+"/ajax/loaddata",async:!1,data:{options:a,phrases:c},type:"POST",dataType:"json",success:function(b){if(b&&!b.hasOwnProperty("errors")){g.length=0;k.length=0;var m={},p=b.options;$.each(a,
function(w,e){m[e]=p.hasOwnProperty(e)?p[e]:null});h.set(m);var t={},u=b.phrases;$.each(c,function(w,e){t[e+n]=u.hasOwnProperty(e)?u[e]:e});l.set(t)}else console.warn("Unexpected result when fetching options",b)},error:function(b,m,p){console.warn("Error when fetching options: {0}".format(p))}})}var q={},l,k,d,n,f={},h,g;q.init=function(a,c,b,m){d=a;n="-"+c;l=b;k=m};q.get=function(){if(1>arguments.length)return console.log("vBulletin.phrase.get() called with no parameters"),"";var a=arguments;Array.isArray(a[0])&&
(a=a[0]);var c=a[0]+n;l.isSet(c)||(k.push(a[0]),r());var b=l.get(c);if(!b)return c;b=b.replace(/\{sitename\}/g,f.get("bbtitle")).replace(/\{musername\}/g,d.musername).replace(/\{username\}/g,d.username).replace(/\{userid\}/g,d.userid).replace(/\{registerurl\}/g,d.registerurl).replace(/\{activationurl\}/g,d.activationurl).replace(/\{helpurl\}/g,d.helpurl).replace(/\{contacturl\}/g,d.contacturl).replace(/\{homeurl\}/g,d.baseurl).replace(/\{date\}/g,d.datenow).replace(/\{webmasteremail\}/g,f.get("webmasteremail")).replace(/\{register_page\}/g,
d.registerurl).replace(/\{activation_page\}/g,d.activationurl).replace(/\{help_page\}/g,d.helpurl).replace(/\{sessionurl\}/g,"").replace(/\{sessionurl_q\}/g,"");for(c=1;c<a.length;++c)b=b.replace(new RegExp("%"+c+"\\$s","gm"),a[c]);return b};q.register=function(a){$.merge(k,$.makeArray(a))};f.init=function(a,c){h=a;g=c};f.get=function(a){h.isSet(a)||(g.push(a),r(a));return h.get(a)};f.register=function(a){$.merge(g,$.makeArray(a))};return{phrase:q,options:f}};
;

// ***************************
// js.compressed/dialog.js
// ***************************
vBulletin.precache(["cancel","no","ok","yes"],[]);
vBulletin.createDialogTools=(f,y,k)=>{function u(a,b,c,d){a.data("created")||a.dialog({autoOpen:!1,modal:!0,resizable:!1,closeOnEscape:!1,showCloseButton:!1,create:()=>{a.data("created",!0)}});b={dialogClass:"dialog-container dialog-box "+(c||""),width:b||500};d&&(b.title=d);a.dialog("option",b);d&&a.closest(".ui-dialog").find(".ui-dialog-title").html(d);a.find(".js-button").toggleClass("b-button--sitebuilder",f("body").is(".edit-mode, .js-edit-mode-style"))}function z(a,b){a=a.find(".icon");a.removeClass((c,
d)=>(d.match(/b-icon\S+\b/g)||[]).join(" ")+" no-icon b-icon");switch(b){case "warning":case "error":a.addClass("b-icon b-icon__warning-l--red h-margin-right-xl");a.show();break;default:a.addClass("no-icon").hide()}}function v(a,b,c=d=>d){b&&a.find(".message").html(c(b))}function D(a){a=a||{};let b=f("#prompt-dialog");var c=b.find(".dialog-content");let d=b.find(".js-prompt-error");u(b,500,(a.dialogClass||"")+" prompt-dialog-container",a.title);v(c,a.message);let e=a.initialValue||"",g=!a.multiline,
h,n;g?(h="input",(n=Number(a.maxlength))||(n=""),d.insertBefore(c)):(h="textarea",n="",d.insertAfter(c));c.find(".input-box").addClass("h-hide");let m=c.find(h+".input-box").val(e).removeClass("h-hide");c.toggleClass("table",g).find("> div").toggleClass("td",g);m.attr("maxlength",n);c=a.buttonLabel||{};let E=f("#btnPromptDialogOK").html(c.okLabel||k.get("ok"));$cancelButton=f("#btnPromptDialogCancel").html(c.cancelLabel||k.get("cancel"));b.find(".js-button").toggleClass("b-button--sitebuilder",f("body").is(".edit-mode, .js-edit-mode-style"));
let r;b.offon("dialogopen",function(){E.offon("click",function(){var t=f.trim(m.val());if(a.validation){var p=a.validation;Array.isArray(p)||(p=[p]);for(let A of p)if("function"==typeof A&&(p=A.apply(b,[m,a]),!0!==p))return p&&d.html(k.get(p)).removeClass("h-hide"),m.trigger("select").trigger("focus"),!1;r=this}t=[t];if(!1===l(a.onClickOK).apply(r,t)||!1===l(a.onBeforeClose).apply(r,void 0))return!1;b.dialog("close")}).trigger("focus");$cancelButton.offon("click",function(){r=this;l(a.onClickCancel).apply(r,
void 0);l(a.onBeforeClose).apply(r,void 0);b.dialog("close")})});b.offon("dialogclose",function(){d.addClass("h-hide");var t=[b];l(a.onAfterClose).apply(r,t);m.val("")});b.dialog("open");m.trigger("focus");return b}function B(a){a=a||{};var b=f(".js-dialog-template");let c=b.clone().removeClass("js-dialog-template").addClass("js-dialog").insertAfter(b);u(c,a.width,(a.dialogClass||"")+" confirm-dialog-container",a.title);b=c.find(".dialog-content");z(b,a.iconType);v(b,a.message,g=>g.replace("\n","<br />"));
b=a.buttonLabel||{};let d=f(".js-button-primary",c).html(b.yesLabel||k.get("yes"));$noButton=f(".js-button-secondary",c).html(b.noLabel||k.get("no"));let e;c.offon("dialogopen",function(){a.handleEnter&&c.offon("keydown",'[type="text"], [type="password"]',h=>{13==h.which&&(h.preventDefault(),d.trigger("click"))});let g=function(h,n){e=n.currentTarget;if(!1===l(h).apply(e,[c])||!1===l(a.onBeforeClose).apply(e,[c]))return!1;c.dialog("close")};d.offon("click",g.bind(null,a.onClickYes)).trigger("focus");
$noButton.offon("click",g.bind(null,a.onClickNo))});c.offon("dialogclose",()=>{l(a.onAfterClose).apply(e,[c]);c.dialog("destroy");c.remove()});c.dialog("open");return c}function C(a){let b={title:q(a.title),message:q(a.message),buttonLabel:{yesLabel:q(a.yesPhrase),noLabel:q(a.noPhrase)}};var c="width dialogClass onAfterClose onClickYes onClickNo iconType handleEnter".split(" ");for(let d of c)b[d]=a[d];return B(b)}function w(a){a=a||{};let b=f("#alert-dialog");u(b,a.width,"alert-dialog-container",
a.title);var c=b.find(".dialog-content"),d=f("#btnAlertDialogOK"),e="",g="";z(c,a.iconType);v(c,a.message);a.maxHeight&&(e=a.maxHeight,g="auto");c.css({"max-height":e,overflow:g});d.html(a.buttonLabel||k.get("ok"));b.offon("dialogopen",function(){d.offon("click",function(){l(a.onBeforeClose).apply(this);b.dialog("close")}).trigger("focus");b.parent(".alert-dialog-container").css("z-index","10100")});b.offon("dialogclose",()=>{l(a.onAfterClose).apply(d)});b.dialog("open");return b}function x(a,b,c,
d){let e=d;e instanceof jQuery&&(e=()=>{d.trigger("focus")});w({title:k.get(a),message:k.get(b),iconType:c,onAfterClose:e})}let l=y.ensureFun;f.widget("ui.dialog",f.ui.dialog,{_allowInteraction:function(a){if(this._super(a)||a.target.ownerDocument!=this.document[0]||f(a.target).closest(".cke_dialog").length||f(a.target).closest(".cke").length)return!0}});(function(){var a=jQuery.fn.dialog;jQuery.fn.dialog=function(){if("object"==typeof arguments[0]){var b=function(){};"function"==typeof arguments[0].open&&
(b=arguments[0].open);arguments[0].open=function(){var d=f(this);setTimeout(function(){vBulletin.Responsive.Debounce.runCallbacks();d.closest(".ui-dialog").find(".ui-dialog-titlebar-close .ui-icon").removeClass("ui-icon ui-icon-closethick").addClass("b-icon b-icon__x-square--gray")},0);d.closest(".ui-dialog").find(".ui-dialog-content").removeClass("h-hide");return b.apply(this,arguments)};var c=function(){};"function"==typeof arguments[0].close&&(c=arguments[0].close);arguments[0].close=function(){f(this).closest(".ui-dialog").find(".ui-dialog-content").addClass("h-hide");
return c.apply(this,arguments)}}return a.apply(this,arguments)}})();let q=a=>a?k.get(a):"";return{openAlertDialog:w,openModalDialog:function(a,b){let c=f(a);b=b||{};u(c,b.width,b.dialogClass,k.get(b.title));c.offon("dialogopen",function(){l(b.onOpen).call(this,c)});c.offon("dialogclose",function(){l(b.onAfterClose).call(this,c)});c.dialog("open");return c},openConfirmDialog:B,openConfirmDialogSimple:C,openPromptDialogSimple:function(a){let b={title:q(a.title),message:q(a.message),buttonLabel:{okLabel:q(a.okPhrase),
cancelLabel:q(a.cancelPhrase)},onClickOK:a.onClickOk};var c="width dialogClass onAfterClose onClickCancel validation initialValue maxlength multiline".split(" ");for(let d of c)b[d]=a[d];return D(b)},openTemplateConfirmDialog:function(a,b,c){b.message="loading_ellipsis";b.dialogClass=(b.dialogClass||"")+" loading";let d=C(b),e=c.data||{};e.isAjaxTemplateRender=!0;e.isAjaxTemplateRenderWithData=!0;let g=c.call||"/ajax/render/"+(c.template||c.name);return new Promise((h,n)=>{a.ajax({call:g,data:e,success:m=>
{m=m.template||m;d.parent(".confirm-dialog-container").removeClass("loading");f(".dialog-content .message",d).html(m).trigger("vb-instrument");d.dialog("option","position",{of:window});f("select",d).selectBox();h(d)},api_error:c.api_error,title_phrase:b.title,error_phrase:"error_loading_dialog_form",after_error:()=>{n();d.dialog("close")}})})},openTemplateAlertDialog:function(a,b,c){return new Promise((d,e)=>{let g=f.extend(c,{success:h=>{b.title=k.get(b.title);b.message=h.template||h;b.buttonLabel=
k.get(b.okPhrase||"ok");h=w(b);f(".dialog-content .message",h).trigger("vb-instrument");d(h)},title_phrase:b.title,error_phrase:"error_loading_dialog_form",after_error:()=>{e()}});a.render(g)})},validationString:function(a,b){return(a=f.trim(a.val()))?b.multiline&&a.length>b.maxlength?["message_too_long",b.maxlength]:!0:"please_enter_a_value"},popupWindow:function(a,b,c,d){let e=window,g=document;a=e.open(a,b,"status=yes,resizable=yes,scrollbars=yes,width="+c+", height="+d+", top="+((e.innerHeight||
g.documentElement.clientHeight||screen.height)/2-d/2+(e.screenTop||screen.top))+", left="+((e.innerWidth||g.documentElement.clientWidth||screen.width)/2-c/2+(e.screenLeft||screen.left)));e.focus&&a.focus();return a},alert:x,warning:(a,b,c)=>x(a,b,"warning",c),error:(a,b,c)=>x(a,b,"error",c),showStatusMessage:function(a,b){let c=f(".conversation-status-message.notice");var d;if(0<c.length){a=k.get(a);let e=c.filter("."+b);c=1==e.length?e:1==(d=c.filter(".h-hide")).length?d:c.first().clone().removeClass().addClass("conversation-status-message notice").appendTo(".conversation-status-messages");
c=(1==e.length?e:c).show();y.isScrolledIntoView(c)?c.hasClass("h-hide")?c.hide().removeClass("h-hide").addClass(b+" show-x").find("span").html(a).end().fadeIn(800,"linear"):c.fadeOut("slow","linear",function(){c.find("span").html(a).end().addClass(b+" show-x").fadeIn("slow","linear")}):(d=c.offset().top-10,c.hide(),f("html,body").animate({scrollTop:d},"slow",function(){c.find("span").html(a).end().addClass(b+" show-x").fadeIn("slow","linear")}))}}}};
;

// ***************************
// js.compressed/ajax.js
// ***************************
vBulletin.precache(["login","cancel","error_information_x"],[]);
vBulletin.createAjaxTools=(u,l,k,v)=>{function n(a,c){if(Array.isArray(a))a.unshift(c);else{var b=a;a=function(...d){c.apply(this,d);"function"==typeof b&&b.apply(this,d)}}return a}function A(a){return'<textarea style="border:1px solid #999;margin-top:10px;height:120px;width:100%;">'+a+"</textarea>"}function B(a){for(var c=[],b=0;b<a.length;b++){var d=$.isArray(a[b])?a[b][0]:a[b],e=k.get(a[b]);1==$("#debug-information").length&&d!=e&&(e+=" ("+d+")");c.push(e)}return c}function C(a,c){return(b,d,e)=>
{var f="";"undefined"!=typeof b.status&&(f+=" "+b.status);null!=d&&(f+=" "+d);"undefined"!=typeof e&&(f+=" "+e);console.log(c+" Error callback: "+a.url);D(b,d,e);b=k.get(a.error_phrase)+"<br /><br />"+k.get("error_information_x",f);v.openAlertDialog({title:k.get(a.title_phrase),message:b,iconType:"error",onAfterClose:a.after_error})}}function E(a,c,b,d,e){(b=a.errors)||(b=[a.error]);if(!c.api_error||c.api_error.apply(d,[b,a,c])){var f=g=>{e.data=e.data.replace(/securitytoken=[^&]*(&|$)/,"securitytoken="+
g.newtoken+"$1");$.ajax(e)};if(0!=l){if(w(b,["inlinemodauth_required"])){x("inlinemod_auth",f,l,"cplogin");return}if(0==a.userid&&w(b,[/^humanverify_/,/^no_permission(?:_|$)/,"no_create_permissions","session_timed_out_login","not_logged_no_permission","no_delete_permissions","no_featured_permissions"])){a=()=>{x("login",f,l,c.cpaction?"cplogin":"")};L(f,a,l)||a();return}}y(b,a,c)}}function w(a,c){if(!$.isArray(a))return!1;var b=c;$.isArray(b)||(b=[c]);for(c=0;c<a.length;c++){var d=a[c];$.isArray(d)&&
(d=d[0]);for(var e=0;e<b.length;e++){var f=b[e];if("regexp"==$.type(f)){if(f.test(d))return!0}else if(f==d)return!0}}return!1}function y(a,c,b){var d={title_phrase:"error",after_error:null};$.extend(!0,d,b);a:{for(b=0;b<a.length;b++){var e=a[b];if($.isArray(e)&&"exception_trace"==e[0]){a.splice(b,1);b=e[1];break a}}b=""}a=B(a);1==$("#debug-information").length&&(b&&a.push(A(b)),a.push(A(JSON.stringify(c))));a="<ul>\n<li>"+a.join("</li>\n<li>")+"</li>\n</ul>";return v.openAlertDialog({title:k.get(d.title_phrase),
message:a,iconType:"error",onAfterClose:d.after_error})}function D(a,c,b){console.dir({textStatus:c,jqXHRStatus:a.status,jqXHRResponseText:a.responseText,errorThrown:b});console.trace()}function m(a){var c={type:"POST",dataType:"json",title_phrase:"error",error_phrase:"error",api_error:!1,after_error:null,silent:!1};a.data instanceof FormData&&(c.processData=!1,c.contentType=!1);$.extend(!0,c,a);c.call&&(c.url=u+c.call,c.call="");c.silent&&(c.error=$.noop,c.api_error=$.noop);c.error||(c.error=C(c,
"ajax"));var b=this;c.success=function(d,e,f){d||c.allowEmptyResponse||(d={errors:[["invalid_server_response_please_try_again"]]});d&&(d.errors||d.error)?E(d,c,a,b,this):a.success&&a.success.apply(this,arguments)};return $.ajax(c)}function F(a,c){let b={dataType:"json",title_phrase:"error",error_phrase:"error",api_error:!1,after_error:null,iframe:!1,silent:!1};$.extend(b,c);b.silent&&(b.error=$.noop,b.api_error=$.noop);b.error||(b.error=C(b,"ajaxForm"));b.beforeSubmit=function(d,e,f){if(c.beforeSubmit&&
!1===c.beforeSubmit.apply(this,arguments))return!1;var g=$("button, .b-button",e);g.prop("disabled",!0);$(document).one("ajaxComplete",()=>{g.prop("disabled",!1)});return!0};b.success=function(d,e,f,g){d||b.allowEmptyResponse||(d={errors:[["invalid_server_response_please_try_again"]]});d&&(d.errors||d.error)?E(d,b,c,g,this):c.success&&c.success.apply(this,arguments)};return b}function L(a,c,b){return"undefined"!=typeof vBfb&&vBfb.isFbLogin()?(vBfb.makeAuthEvent(d=>{m({call:"/auth/login-external",
data:{provider:"facebook",auth:d.accessToken,userid:b},success:e=>{vBulletin.doReplaceSecurityToken(e.newtoken);return a(e)},api_error:c})})(),!0):!1}function x(a,c,b,d){let e,f;v.openTemplateConfirmDialog(G,{title:a,width:400,yesPhrase:"login",noPhrase:"cancel",handleEnter:!0,onClickYes:g=>{f.text("").addClass("h-hide");m({call:"/auth/ajax-login",data:e.serializeArray(),success:h=>{g.trigger("vb-login",h)},api_error:h=>{f.html(k.get(h[0])).removeClass("h-hide");f.find("a").attr("target","_blank")},
title_phrase:a});return!1}},{call:"/auth/login-dialog",data:{logintype:d,userid:b},api_error:y}).then(g=>{e=g.find(".js-login-form");f=$(".js-error-box",e);$('[type="text"], [type="password"]',g).filter(":visible").first().trigger("focus");g.on("vb-login",(h,p)=>{h.stopPropagation();vBulletin.doReplaceSecurityToken(p.newtoken);g.dialog("close");return c(p)})})}$.ajaxSetup({contentType:"application/x-www-form-urlencoded; charset=UTF-8"});let z,H=!1,I=!0,q,r,t=[];$(()=>{z=$("#debug-information");(H=
0<z.length)?(q=z.find("#debug-ajax-request-count"),r=$("<ol />").attr("id","debug-ajax-request-list").hide().css({height:"150px",overflow:"auto",padding:"4px",border:"1px solid #CCC",background:"#EEE","margin-top":"2px","margin-bottom":"4px"}).appendTo(q.closest("li")),q.css("cursor","pointer").on("click",()=>{r.toggle()})):(I=!1,t=[])});$.ajaxPrefilter((a,c,b)=>{if(I){var d={url:a.url,startTimeStamp:Date.now(),endTimeStamp:0,finalTimeStamp:0,status:"UNKNOWN",errorThrown:""};t.push(d);a.success=n(a.success,
(e,f,g)=>{d.endTimeStamp=Date.now()});a.error=n(a.error,(e,f,g)=>{d.endTimeStamp=Date.now();d.errorThrown=g});a.complete=n(a.complete,(e,f)=>{d.finalTimeStamp=Date.now();d.status=f;if(H)for(e=t.length,q.text(e),f=0;f<e;f++){var g=t[f];let h="js-request-counter-"+f;if(0==r.find("."+h).length){let p=0==g.url.indexOf(u)?g.url.substring(u.length):g.url,J=g.endTimeStamp-g.startTimeStamp,K=g.finalTimeStamp-g.startTimeStamp;g='{0} <span style="font-size:x-small;">({1}, <span title="Request Time: {2}ms, Processing Time: {3}ms, Total Time: {4}ms" style="text-decoration:underline;">{2}ms, {3}ms</span>){5}</span>'.format(p,
g.status,J,K-J,K,g.errorThrown?" Error: "+g.errorThrown:"");$("<li />").addClass(h).html(g).appendTo(r)}}})}});var G={hasError:w,ajax:m,ajaxSilent:function(a){vBulletin.loadingIndicator.suppressNextAjaxIndicator();return m(a)},render:function(a){a.template&&(a.call="/ajax/render/"+a.template,a.template="");a.data.isAjaxTemplateRender=!0;a.data.isAjaxTemplateRenderWithData=!0;return m(a)},ajaxForm:function(a){this.ajaxForm(F(this,a))},initForm:function(a,c){a.ajaxForm(F(a,c))},logApiError:function(a){console.dir(B(a))},
logAjaxError:D,showApiError:y,runBeforeCallback:n,library:{inlineMod(a){x("inlinemod_auth",a,l,"cplogin")}}};return G};
;

// ***************************
// js.compressed/global.js
// ***************************
(function(a){function J(){vBulletin.AJAX({call:"/ajax/activate-sitebuilder",data:{pageid:pageData.pageid,nodeid:pageData.nodeid,userid:pageData.userid,loadMenu:!1,isAjaxTemplateRender:!0,isAjaxTemplateRenderWithData:!0},cache:!1,success:b=>{b.templates&&(a("#sitebuilder-wrapper").prepend(b.templates.main),a(".js-top-menu-sitebuilder").show(),a(".edit-switch-container .switch-control").addClass("on"),H.setCookie("sitebuilder_active","1"))}})}function M(b,c){var d=0,e=b.length;b.each(function(){if(this.complete&&
0<this.naturalHeight&&this.src)++d;else a(this).one("load",function(){++d;d==e&&c()})});d==e&&c()}function N(b,c,d,e,k){function l(p){p=p.position().top+p.outerHeight();p=Math.round(p);return[p-1,p,p+1]}function h(p,u){var n,q;for(n in p)for(q in u)if(p[n]===u[q])return!0;return!1}a(b).each(function(){var p=a(this);p.trigger("vbulletin:flexgridstart",{isResize:k});var u=a(c,p),n=u.last(),q=!1,w={},f=0,r=!1,x=!1,B=u.first();u.length&&(u.removeClass(d+" vb-temp-placeholder-grid-lastrow"),u.removeClass(e),
setTimeout(function(){q=l(n);u.each(function(){var z=a(this),D=l(z);h(q,D)?z.addClass("vb-temp-placeholder-grid-lastrow"):(r||(r=D),h(r,D)||(++f,B.addClass(e)),r=D,B=z,"undefined"==typeof w[f]&&(w[f]=0),++w[f])});B!=u.first()&&B.addClass(e);a.each(w,function(z,D){!1===x&&(x=D);D<x&&(x=D)});var A=u.filter(".vb-temp-placeholder-grid-lastrow");A.removeClass("vb-temp-placeholder-grid-lastrow");(!1===x||A.length<x)&&A.addClass(d);!1!==x&&A.length==x&&A.last().addClass(e);p.trigger("vbulletin:flexgridready",
{isResize:k})},0))})}function R(b,c,d,e,k,l,h){a(b).each(function(){var p=a(this),u=a(d,p);l?N(p,c,e,k,h):M(u,function(){N(p,c,e,k,h)})})}function U(b,c){function d(n,q,w){var f={},r=[];var x=n.data.length-32;var B=n.data;for(n=0;n<x;n+=32){var A=Math.round(B[n]/q);var z=Math.round(B[n+1]/q);var D=Math.round(B[n+2]/q);var E=Math.round(B[n+3]/q);A=A+100*z+1E4*D+1E6*E;f[A]?++f[A]:f[A]=1}for(n in f)r.push([n,f[n]]);r.sort(function(g,m){return g[1]>m[1]?-1:m[1]>g[1]?1:0});r.length>w&&(r=r.slice(0,w));
return r}function e(n){var q=Math.floor(n/1E6);var w=Math.floor(n/1E4)-100*q;var f=Math.floor(n/100)-1E4*q-100*w;return[n-1E6*q-1E4*w-100*f,f,w,q]}function k(n,q){n=e(n[0]);var w=e(q[0]);q=Math.min(n[0],n[1],n[2]);var f=Math.max(n[0],n[1],n[2]);n=Math.min(w[0],w[1],w[2]);w=Math.max(w[0],w[1],w[2]);q=f-q;n=w-n;return q>n?-1:n>q?1:0}function l(n,q){var w=0,f=0;n=e(n[0]);q=e(q[0]);n[0]!=n[1]&&++w;n[0]!=n[2]&&++w;n[1]!=n[2]&&++w;q[0]!=q[1]&&++f;q[0]!=q[2]&&++f;q[1]!=q[2]&&++f;return w>f?-1:f>w?1:0}function h(n,
q){n=a(c,q);var w=q.innerWidth();q=q.innerHeight();var f=n.outerWidth(),r=n.outerHeight();if(f>=w&&r>=q)switch(n.css("object-fit")){case "contain":return u(n);case "scale-down":return[w,q,f,r]=p(n),n=w<f&&q<r?!0:u(n),n;case "none":return[n,,w,q]=p(n),n<w||n<q;default:return!1}return!0}function p(n){return[n.prop("naturalWidth"),n.prop("naturalHeight"),n.prop("width"),n.prop("height")]}function u(n){var q;let w;[q,f,n,w]=p(n);q/=f;var f=w;let r=q*f;r>n&&(r=n,f=n/q);return n>r||w>f}a(b).each(function(n){var q=
a(this),w=a(c,q);w.length&&setTimeout(function(){M(w,function(){var f=a(c,q),r=f.data("bgStrat")||"primary-color";if(f.length&&h(f,q))switch(r){case "cover-blur":q.css("background-image","url('"+f.attr("src")+"')");q.css("background-size","cover");f.css("backdrop-filter","blur(10px)");break;default:var x=f.outerWidth(),B=f.outerHeight();f=f.get(0);r=document.createElement("canvas");var A=r.getContext&&r.getContext("2d");x=f.naturalWidth||x;B=f.naturalHeight||B;var z=!1;r.width=x;r.height=B;A.drawImage(f,
0,0);try{z=A.getImageData(0,0,x,B)}catch(D){}z&&z.data&&z.data.length&&(f=d(z,20,100),f.sort(k),f.sort(l),f=f.shift(),f=e(f[0]),f[0]*=20,f[1]*=20,f[2]*=20,f[3]*=20,245<=f[3]&&(f[3]=255),q.css("backgroundColor","rgba("+f.join(",")+")"))}})},0)})}function V(){function b(){var c=a(this);if(""==c.prop("title")){var d=c.get(0);d.scrollWidth>d.clientWidth&&(d=c.text().trim(),300<d.length&&(d=d.substr(0,297)+"..."),c.prop("title",d))}c.addClass("js-ellipsis-has-title")}a(document).off("mouseover",".ellipsis:not(.js-ellipsis-has-title)",
b).on("mouseover",".ellipsis:not(.js-ellipsis-has-title)",b)}const C=vBulletin;pageData=window.pageData||{};pageData=Object.assign(pageData,vBulletin.data());pageData.tzOffset=parseInt(pageData.tzOffset);pageData.dstauto=parseInt(pageData.dstauto);vBulletin.version=pageData.templateversion;a.fn.offon=function(b,c,d,e){null==e&&(e=d,null==d?(e=c,c=void 0):"string"!==typeof c&&(d=c,c=void 0));return this.off(b,c).on(b,c,d,e)};String.prototype.format=function(){for(var b=this,c=arguments.length;c--;)b=
b.replace(new RegExp("\\{"+c+"\\}","gm"),arguments[c]);return b};jQuery.fn.reverse=[].reverse;a(".js-module__hide-if-empty:not(:has(*))").each(function(){let b=a(this);/\s/.test(b.html())&&b.closest(".js-module").hide()});jQuery.ajaxPrefilter(function(b){b.crossDomain&&(b.contents.script=!1)});a.ajaxPrefilter("script",function(b){b.cache=!0});vBulletin.normalizeAjaxUrl=function(b){return 0==b.indexOf("http://")?b.substring(5):0==b.indexOf("https://")?b.substring(6):b};vBulletin.getAjaxBaseurl=function(){return vBulletin.normalizeAjaxUrl(pageData.baseurl)};
vBulletin.getAbsoluteUrl=function(){var b;return function(c){b||(b=document.createElement("a"));b.href=c;return b.href}}();vBulletin.regexEscape=function(b){return b.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")};let S=vBulletin.normalizeAjaxUrl(pageData.baseurl);vBulletin.isInternalUrl=function(){let b=new RegExp("^"+vBulletin.regexEscape(S));return function(c){c=vBulletin.normalizeAjaxUrl(vBulletin.getAbsoluteUrl(c));return b.test(c)}}();vBulletin.isInternalJSUrl=function(){let b=new RegExp("^"+vBulletin.regexEscape(S+
"/js/")+".*.js");return function(c){c=vBulletin.normalizeAjaxUrl(vBulletin.getAbsoluteUrl(c));return b.test(c)}}();vBulletin.isAbsoluteUrl=function(){var b=RegExp("^(?:[a-z]+:)?//","i");return function(c){return b.test(c)}}();vBulletin.isEmptyList=function(b){return a.isArray(b)&&0==b.length||a.isPlainObject(b)&&a.isEmptyObject(b)};C.ensureArray=b=>void 0===b?[]:Array.isArray(b)?b:[b];C.getFormData=(b,c)=>{let d={};for(const e of b.serializeArray()){let {name:k,value:l}=e;k in d?(d[k]=C.ensureArray(d[k]),
d[k].push(l)):d[k]=l}"undefined"!=typeof c&&a("input:checkbox:not(:disabled)",b).each((e,k)=>{d[k.name]||(d[k.name]=c)});return d};C.objSubset=(b,c)=>{let d={};for(let e of c)e in b&&(d[e]=b[e]);return d};a.ajaxPrefilter(function(b,c,d){if(!b.url||vBulletin.isInternalUrl(b.url)&&!vBulletin.isInternalJSUrl(b.url))if("undefined"==typeof b.data)b.data="securitytoken="+pageData.securitytoken,"undefined"!==typeof b.formData&&Array.isArray(b.formData)&&b.formData.push({name:"securitytoken",value:pageData.securitytoken});
else if("undefined"!==typeof FormData&&b.data instanceof FormData)b.data.append("securitytoken",pageData.securitytoken);else{var e=!0;c=b.data.split("&");a.each(c,function(k,l){if(l.match(/^securitytoken=/))return e=!1});e&&(b.data+="&securitytoken="+pageData.securitytoken)}});a.ajaxPrefilter(function(b,c,d){(function(){var e=vBulletin.getAjaxBaseurl();if(0==c.url.indexOf(e)&&0==c.url.substr(e.length).indexOf("/ajax/render/")||c&&c.data&&c.data.isAjaxTemplateRender){var k=b.success;b.success=function(){console.log("Intercept AJAX template render calls: Start (URL: {0})".format(b.url));
var l=arguments[0];if(!l||"object"!=typeof l||a.isEmptyObject(l))return"function"==typeof k?k.apply(this,arguments):!1;c.data&&c.data.isAjaxTemplateRenderWithData?arguments[0]=l:(arguments[0]=l.template,arguments[1]=l.errors);var h=l.css_links;if(h&&0!=h.length){console.log("Intercept AJAX template render calls: Has CSS");var p=/sheet=([^&]+)&/;l=h.pop();var u=null!=l.match(p);h.push(l);var n=function(A){var z=A.match(p),D={};z&&z[1]?a.each(z[1].split(","),function(E,g){D[g]=A}):D[A.replace(/^.*\//g,
"")]=A;return D},q={};a("head link[rel=stylesheet]").each(function(){a.extend(q,n(a(this).attr("href")))});var w={};a.each(h,function(A,z){a.extend(w,n(z))});var f=[];a.each(w,function(A,z){A&&"undefined"==typeof q[A]&&(u?f.push(A):f.push(z))});if(0==f.length){if(console.log("Intercept AJAX template render calls: Needed CSS is already on the page"),"function"==typeof k)return console.log("Intercept AJAX template render calls: Calling original success handler"),k.apply(this,arguments)}else{h=[];u?
(console.log("Intercept AJAX template render calls: found DB CSS"),h.push(l.replace(/sheet=[^&]+&/,"sheet="+f.join(",")+"&"))):(console.log("Intercept AJAX template render calls: found FS CSS"),h=f);var r=this,x=arguments;console.log("Intercept AJAX template render calls: Fetching CSS: {0}".format(h.join(", ")));var B=function(A){if(0==A.length)console.log("Intercept AJAX template render calls: Done. Calling original callback."),setTimeout(function(){if("function"==typeof k)return k.apply(r,x)},50);
else{var z=a("<div />").append(A.shift()).text();console.log("Intercept AJAX template render calls: Fetching CSS file: {0}".format(z));a.get(z,{cache:!0},function(D){D=a("<link />",{rel:"stylesheet",type:"text/css",href:z});var E=a(".js-additional-css");1==E.length?E.before(D):a("head").append(D)}).then(function(){console.log("Intercept AJAX template render calls: Fetched CSS file: {0}".format(z));if(0<a(".js-debug-css-template-list").length){var D=n(z),E=a("<ol />");a.each(D,function(g,m){u?E.append(a("<li />").append(g)):
E.append(a("<li />").append(m))});D=a(".js-debug-css-template-list").append(a("<li />").append(vBulletin.phrase.get("added_via_ajax_call")+":").append(E)).prev("b");D.text(parseInt(D.text(),10)+1)}B(A)},function(){console.warn("Intercept AJAX template render calls: Failed to fetch CSS file: {0}".format(z));B(A)})}};B(h)}}else if(console.log("Intercept AJAX template render calls: No CSS"),"function"==typeof k)return console.log("Intercept AJAX template render calls: Calling original success handler"),
k.apply(this,arguments)}}})()});vBulletin.isRtl=()=>"rtl"==a("html").attr("dir");let H=vBulletin.createStorageTools(pageData.cookie_prefix,Cookies.withAttributes({path:pageData.cookie_path,domain:pageData.cookie_domain,secure:"https"==pageData.baseurl.substr(0,5).toLowerCase()||"https:"==location.protocol}));vBulletin.storagetools=H;(function(){var b=jQuery.fn.selectBox;jQuery.fn.selectBox=function(){var c=a(this);"undefined"==typeof c.attr("tabindex")&&c.attr("tabindex","0");c=b.apply(this,arguments);
a(".selectBox-arrow").addClass("b-icon-fa b-icon-fa--12 fa-solid fa-caret-down");return c}})();(function(){(function(){var b=a(".js-login-menu");b.find(".js-comp-menu-dropdown__trigger").on("click",function(){setTimeout(function(){b.find(".js-login-username").trigger("focus")},0)});(function(){function c(l,h){a(l).toggleClass("h-hide-imp",!h)}var d=a(".js-top-menu-user--list"),e=[".js-header__notifications-label",".js-pmchat__messages-label",".js-menu__username-label"],k=e.slice(0).reverse();d.on("vbulletin:shrink",
function(){a.each(e,function(l,h){c(h,!1);if("need_shrink"!=vBulletin.Responsive.Debounce.checkElementShrinkRequirement(d))return!1})}).on("vbulletin:unshrink",function(){a.each(k,function(l,h){c(h,!0);if("need_shrink"==vBulletin.Responsive.Debounce.checkElementShrinkRequirement(d))return c(h,!1),!1})})})();(function(){var c=a(".js-top-menu-sitebuilder--list"),d=c.find(".b-top-menu__item"),e=d.find(".js-top-menu-link"),k=c.closest(".js-top-menu-sitebuilder"),l=[function(h){e.toggleClass("b-top-menu__item-link--compact",
h)},function(h){k.toggleClass("b-top-menu__background--compact",h)},function(h){vBulletin.CompMenuHorizontal.convertDropdownProgressive({$parent:c,$children:d,removeMenu:!h})}];c.on("vbulletin:shrink",function(){a.each(l,function(h,p){p(!0);if("need_shrink"!=vBulletin.Responsive.Debounce.checkElementShrinkRequirement(c))return!1})}).on("vbulletin:unshrink",function(){for(var h=l.length;0<=--h;)if(l[h](!1),"need_shrink"==vBulletin.Responsive.Debounce.checkElementShrinkRequirement(c)){l[h](!0);break}})})()})();
a(".ui-tabs .ui-tabs-nav > li").addClass("ui-state-disabled")})();vBulletin.pageHasSelectors=function(b){if(a.isArray(b)&&0<b.length&&""!=a.trim(b.toString())){var c=!1;a.each(b,function(d,e){if(0<a(e).length)return c=!0,!1});return c}return!0};vBulletin.areJsonObjectsEqual=function(b,c){var d=function(e,k){for(var l in e)if(e.hasOwnProperty(l)&&k.hasOwnProperty(l)){var h=e[l],p=k[l];if(h!=p)if(h instanceof Array&&p instanceof Array){if(0<a(h).not(p).length||0<a(p).not(h).length)return!1}else return!1}else return!1;
return!0};return Object.keys(b).length==Object.keys(c).length?d(b,c):!1};vBulletin.loadingIndicator=function(){function b(h){if(h){h=a(".js-loading-indicator");var p=h.outerWidth(),u=vBulletin.isRtl()?"margin-right":"margin-left";0<p&&h.css(u,-(p/2));h.removeClass("h-hide");a("body").css("cursor","wait")}else a(".js-loading-indicator").addClass("h-hide"),a("body").css("cursor","auto")}var c=0,d=!1,e=!1,k=0,l=0;return{init:function(){d||(a(document).ajaxStart(function(){vBulletin.loadingIndicator.show("ajaxStart")}),
a(document).ajaxStop(function(){vBulletin.loadingIndicator.hide("ajaxStop")}),d=!0)},show:function(h){0<k&&"ajaxStart"==h?(--k,++l,console.log("vBulletin.loadingIndicator.show ajax indicator suppressed")):(++c,console.log("vBulletin.loadingIndicator.show Counter: "+c+" Source: "+(h||"Unspecified")),0<c&&(e=setTimeout(function(){e&&(b(!0),e=!1)},1E3)))},hide:function(h){0<l&&"ajaxStop"==h?(--l,console.log("vBulletin.loadingIndicator.hide ajax indicator suppressed")):(--c,c=0>c?0:c,h||(c=0),console.log("vBulletin.loadingIndicator.hide Counter: "+
c+" Source: "+(h||"Unspecified")),1>c&&(e&&(clearTimeout(e),e=!1),b(!1)))},suppressNextAjaxIndicator:function(){++k}}}();vBulletin.precache("admin admin_auth april august cancel_edit close december done email_addresses_must_match error error_loading_ckeditor_script error_loading_editor error_posting_comment_code error_x existing_reply_will_be_deleted february follow follow_error following following_pending following_remove friday_min go_to_first_new_post hour inlinemod_auth_password_empty invalid_data invalid_data_requested invalid_email_address invalid_request invalid_server_response_please_try_again invalid_special_channel_subscribe_request invalid_username_specified invalid_username_specified_maxlength_x invalid_username_specified_minlength_x invalid_query_definition_x january join joined join_error july june leave loading logged_out_while_editing_post login login_success_admin_auth march may minute moderator monday_min new_posts no no_create_permissions no_icon no_leave_channel_permission no_permission no_update_permissions no_valid_tags_found not_logged_no_permission november now october phrase_passthrough physically_remove_blog physically_remove_comment physically_remove_media physically_remove_reply physically_remove_topic physically_remove_visitorMessage please_enter_your_comment please_enter_your_email_address please_provide_search_string post_comment post_history posttype_blog posttype_comment posttype_media posttype_reply posttype_topic posttype_visitorMessage preview refer_a_friend saturday_min search see_less see_more select_option_and_click_delete_button_blog select_option_and_click_delete_button_comment select_option_and_click_delete_button_media select_option_and_click_delete_button_reply select_option_and_click_delete_button_topic select_option_and_click_delete_button_visitorMessage send_report september soft_delete_blog soft_delete_comment soft_delete_media soft_delete_notes_blog soft_delete_notes_comment soft_delete_notes_media soft_delete_notes_reply soft_delete_notes_topic soft_delete_notes_visitorMessage soft_delete_reply soft_delete_topic soft_delete_visitorMessage sunday_min thanks_for_signing_up_log_in time tuesday_min thursday_min unable_to_check_admin_permissions unable_to_contact_server_please_try_again unexpected_error unfollow_error usernametaken wednesday_min".split(" "),
["bbtitle","markinglimit","threadpreview"]);var K=C.getAjaxBaseurl(),G=C.createSiteDataTools(K);G.phrase.init(pageData,pageData.languageid,H.createStorageTimed("phrase",pageData.phrasedate,pageData.current_server_datetime),C.phrase.precache);a.extend(C.phrase,G.phrase);G.options.init(H.createStorageTimed("options",pageData.optionsdate,pageData.current_server_datetime),C.options.precache);a.extend(C.options,G.options);G=C.createDialogTools(a,C,C.phrase);C.dialogtools=G;C.error=G.error;C.warning=G.warning;
C.alert=G.alert;C.openConfirmDialog=G.openConfirmDialog;window.openAlertDialog=G.openAlertDialog;window.openConfirmDialog=G.openConfirmDialog;let L=C.createAjaxTools(K,pageData.userid,C.phrase,C.dialogtools);C.ajaxtools=L;C.ajaxlib=L.library;C.AJAX=L.ajax;C.ajaxForm=L.ajaxForm;vBulletin.getScrollbarWidth=function(){if(a("body").data("scrollbar-width"))return a("body").data("scrollbar-width");var b=a('<div style="width:50px;height:50px;overflow:auto;position:absolute;top:-99999px;"><div /></div>').appendTo("body"),
c=b.children();c=c.innerWidth()-c.height(99).innerWidth();b.remove();a("body").data("scrollbar-width",c);return c};vBulletin.assertUserHasAdminPermission=function(b,c,d,e){if(a(c).data("in-progress"))return!1;a("body").css("cursor","wait");a(c).data("in-progress",!0);vBulletin.AJAX({call:"/ajax/api/user/currentUserHasAdminPermission",data:{adminPermission:b},complete:function(){a("body").css("cursor","auto");a(c).data("in-progress",null)},success:function(k){!0===k?d():(vBulletin.error("error","unable_to_check_admin_permissions"),
a("#config-dialog .loader").hide())},api_error:"undefined"==typeof e?void 0:function(k){return vBulletin.ajaxtools.hasError(k,"inlinemodauth_required")?(vBulletin.ajaxlib.inlineMod(e),!1):!0},error_phrase:"unable_to_check_admin_permissions"})};vBulletin.selectTabByIndex=function(b){var c=this instanceof a?this:a(this);c.length&&-1<b&&c.hasClass("ui-tabs")&&c.data("noPushState",!0).tabs("option","active",b).data("noPushState",null).find(".ui-tabs-nav li").removeClass("ui-state-focus").eq(b).addClass("ui-state-focus").find("a").trigger("focus")};
a.ui.tabs.prototype._isLocal=function(){return!0};(function(){var b=a.ui.tabs.prototype._processTabs;a.ui.tabs.prototype._processTabs=function(){var c=b.apply(this,arguments);this.panels.removeClass("h-hide");return c}})();vBulletin.getSelectedTabHashOrPath=function(b,c){return(c?b.find(".ui-tabs-nav > .ui-tabs-active > a").prop("hash"):b.find(".ui-tabs-nav > .ui-tabs-active > a").data("url-path"))||""};vBulletin.parseUrl=function(b){var c=document.createElement("a");c.href=b||"/";b=c.pathname;0!=
b.indexOf("/")&&(b="/"+b);return{protocol:c.protocol,hostname:c.hostname,port:c.port,pathname:b,search:c.search,hash:c.hash}};vBulletin.makeTabUrl=function(b,c,d,e,k){b?(b=vBulletin.parseUrl(b),d?(k=k||"tab",d=new RegExp("([?+|&+])"+k+"=\\w+[-\\w]*","i"),b=b.search.match(d)?b.pathname+b.search.replace(d,"$1{0}={1}".format(k,c)):b.search?"{0}{1}&{2}={3}".format(b.pathname,b.search,k,c):"{0}?{1}={2}".format(b.pathname,k,c)):(k=b.pathname.replace(/\/$/,""),d=k.split("/"),d="\\/"+d[d.length-(k.match(/\/page([0-9]+)/)?
2:1)]+"$",b=b.pathname.replace(new RegExp(d),"/"+c)+b.search)):b="/";e&&(b+="#"+e);return b};vBulletin.makePaginatedUrl=function(b,c){if(b){var d=b.match(/\/page[0-9]+/);d?b=1<c?b.replace(d[0],"/page"+c):b.replace(d[0],""):1<c&&(b=b.match(/\?/)?b.replace(/\?/,"/page"+c+"?"):b.match(/#/)?b.replace(/#.*/,"/page"+c):b+("/page"+c))}return b};vBulletin.makeFilterUrl=function(b,c,d,e,k,l){l=l||!1;b=b||location.href;var h=a(".filtered-by",e);b=vBulletin.parseUrl(b);var p=b.search,u=a(".js-button-filter.js-default-checked.js-checked",
e);u.data("filter-name")==c&&u.data("filter-value")==d&&(l=!0);!l&&(h.data("clicked")&&a('.toolbar-filter-overlay input[name="{0}"][value="{1}"]'.format(c,d),e).hasClass("js-default-checked")||a('.toolbar-search-form input[name="{0}"]'.format(c),e).length&&!d)&&(l=!0,h.data("clicked",null));b=b.pathname;if(p&&1<p.length)if(p.match(new RegExp(c+"=","i"))){if(e=vBulletin.parseQueryString(p),!a.isEmptyObject(e)){var n="";a.each(e,function(q,w){l&&q==c||(n+="{0}={1}&".format(q,q==c?d:w))});n&&(b+="?"+
n.substring(0,n.length-1))}}else b=l?b+p:b+(p+"&{0}={1}".format(c,encodeURIComponent(d)));else l||(b+="?{0}={1}".format(c,encodeURIComponent(d)));k&&(b+="#"+k);return b};vBulletin.getSelectedFilters=function(b,c){var d={};if(c){var e=b.parent().find(".filtered-by .filter-text").filter(":visible");b.find(":input:radio:checked").each(function(k,l){k=a(l);if((k.hasClass("js-default-checked")||1==k.data("bypass-filter-display"))&&(0==e.length||0==e.filter('[data-filter-name={0}][data-filter-value="{1}"]').length))return!0;
"[]"==l.name.slice(-2)?(k=l.name.split("[]"),d[k[0]]=d[k[0]]||[],d[k[0]].push(l.value)):d[l.name]=l.value})}else b=b.serializeArray(),a.each(b,function(k,l){"securitytoken"!=l.name&&("[]"==l.name.slice(-2)?(k=l.name.split("[]"),d[k[0]]=d[k[0]]||[],d[k[0]].push(l.value)):d[l.name]=l.value)});return d};vBulletin.parseQueryString=function(b,c){var d={};if(b&&1<b.length){var e=b.indexOf("?");c=c instanceof Array?c:[];-1!=e&&(b=b.substring(e+1).split("&"),a.each(b,function(k,l){k=l.split("=");if(0==c.length||
-1==a.inArray(k[0],c))d[k[0]]=decodeURIComponent(k[1]||"").replace(/\+/g," ")}))}return d};vBulletin.togglePageScrolling=function(b){function c(){d.scrollTop(e).scrollLeft(k)}var d=a(window),e=d.scrollTop(),k=d.scrollLeft();d.off("scroll.vbtogglepagescrolling");if(!b)d.on("scroll.vbtogglepagescrolling",c)};vBulletin.pagination=function(b){function c(){return parseInt((a(".pagetotal",this).html()||"").replace(/[^\d]+/g,""),10)||1}function d(f,r){var x=c.apply(this),B=a(".arrow[rel=next]",this),A=a(".arrow[rel=prev]",
this);1>f?f=1:f>x&&(f=x);a(".js-pagenum",this).val(f);f==x?B.addClass("h-disabled").removeAttr("href"):B.removeClass("h-disabled").attr("href",vBulletin.makePaginatedUrl(location.href,f+1));1==f?A.addClass("h-disabled").removeAttr("href"):A.removeClass("h-disabled").attr("href",vBulletin.makePaginatedUrl(location.href,f-1));"function"==typeof l.onPageChanged&&l.onPageChanged.apply(this,[f,r]);1<x&&u.isEnabled()&&!r&&(r=u.getState(),!r||!r.data||!r.data.from||a.inArray(r.data.from,-1==["filter_blogs",
"filter_groups"]))&&(w=1==f?a(".arrow[rel=next]",this).attr("href"):a(".arrow[rel=prev]",this).attr("href"))&&(w=vBulletin.makePaginatedUrl(w,f),f={from:"pagination",page:f,tab:l.tabParamAsQueryString?"#"+a(this).closest(".ui-tabs-panel").attr("id"):vBulletin.getSelectedTabHashOrPath(a(this).closest(".ui-tabs"),!1)},u.pushState(f,document.title,w))}function e(f){a("a.see-all-btn",this).closest(".pagenav-controls")[f?"addClass":"removeClass"]("h-hide")}function k(){a(l.context).off("click",".js-pagenav .js-pagenav-button").on("click",
".js-pagenav .js-pagenav-button",function(f){if(u.isEnabled()){f=a(this).data("page");var r=a(".pagenav-form",l.context).get(0);d.apply(r,[f,!1]);return!1}return!0}).off("mouseover",".js-pagenav .js-pagenav-button").on("mouseover",".js-pagenav .js-pagenav-button",function(f){f=a(this);f.prop("href")||f.prop("href",vBulletin.makePaginatedUrl(location.href,parseInt(f.data("page"),10)))});a(".js-pagenav .js-pagenav-button",l.context).each(function(){this.href=vBulletin.makePaginatedUrl(location.href,
parseInt(a(this).data("page")))});(function(){a(document).on("vbulletin:shrink vbulletin:unshrink",".js-pagenav",function(){var f=a(this),r=f.data("vbshrink-hidden-elements");"undefined"!=typeof r&&r.removeClass("h-hide-imp");r=f.find("> .js-pagenav-button").filter(":visible");var x=a(),B=a(),A=r.filter(".js-pagenav-current-button").data("page");r.each(function(z,D){z=a(D);var E=z.data("page");D=z.is(".js-pagenav-prev-button, .js-pagenav-current-button, .js-pagenav-next-button");var g=z.is(".js-pagenav-first-button, .js-pagenav-last-button");
E=E==A-1||E==A+1;g=g?"1":E?"2":"3";D||(x=x.add(z),z.data("vbshrink-priority",g))});a.each(["3","2","1"],function(z,D){x.each(function(E,g){E=a(g);if(E.data("vbshrink-priority")!=D)return!0;if("need_shrink"==vBulletin.Responsive.Debounce.checkElementShrinkRequirement(f))E.addClass("h-hide-imp"),B=B.add(E);else return!1})});f.data("vbshrink-hidden-elements",B)});vBulletin.Responsive.Debounce.checkShrinkEvent(a(".js-pagenav"))})()}var l={context:document,onPageChanged:null,tabParamAsQueryString:!0,allowHistory:!1};
b&&"object"==typeof b&&a.extend(l,b);var h=a(".pagenav-controls .pagenav-form",l.context),p=Number(a(".defaultpage",h).val())||Number(a(".js-pagenum",h).val())||1,u=new vBulletin.history.instance(l.allowHistory);h.data("object-instance",this);if(u.isEnabled()){b=vBulletin.parseQueryString(location.search,["_"]);var n=location.pathname.match(/\/page([0-9]+)/),q=u.getState();if(n&&1<Number(n[1])&&a.isEmptyObject(b)&&(!q||a.isEmptyObject(q.data))){var w=vBulletin.makePaginatedUrl(location.href,p);b=
{from:"pagination",page:p,tab:l.tabParamAsQueryString?"#"+h.closest(".ui-tabs-panel").attr("id"):vBulletin.getSelectedTabHashOrPath(h.closest(".ui-tabs"),!1)};u.setDefaultState(b,document.title,w)}u.setStateChange(function(f){f=u.getState();if("pagination"==f.data.from){u.log(f.data,f.title,f.url);if(location.search){var r=vBulletin.parseQueryString(location.search,["_"]);if(!a.isEmptyObject(r)||"groups-tab"==r.tab){delete r.tab;a(window).trigger("statechange.filter",["pagination",r]);return}}var x,
B;f.data.tab&&(x=l.tabParamAsQueryString?a(f.data.tab):a('.ui-tabs .ui-tabs-panel[data-url-path="'+f.data.tab+'"]'));r=x&&x.length&&x||l.context;(B=a(".conversation-toolbar .filter-wrapper",r).data("object-instance"))&&B.resetFilters(!0);if(f.data.tab&&(x=x.closest(".ui-tabs"),$tabAnchor=l.tabParamAsQueryString?x.find('.ui-tabs-nav > li > a[href*="{0}"]'.format(f.data.tab)):x.find('.ui-tabs-nav > li > a[data-url-path="'+f.data.tab+'"]'),!$tabAnchor.parent().hasClass("ui-tabs-active"))){f=$tabAnchor.parent().index();
vBulletin.selectTabByIndex.call(x,f);return}x=a(".pagenav-controls .pagenav-form",r);(r=x.data("object-instance"))&&"function"==typeof r.getOption&&"function"==typeof r.getOption("onPageChanged")&&(f=f.data.page||p,r.getOption("onPageChanged").apply(x.get(0),[f,!1,!location.search,location.search]))}},"pagination")}a(".arrow",h).off("click").on("click",function(f){var r=a(this);f=this.form||r.closest("form").get(0);if(!r.hasClass("h-disabled")){r=parseInt(a(".js-pagenum",f).val())+("next"==r.attr("rel")?
1:-1);if(!u.isEnabled()&&l.allowHistory)return this.href&&this.hash!=this.href||(this.href=vBulletin.makePaginatedUrl(location.href,r)),!0;d.apply(f,[r,!1])}return!1});k();a(".js-pagenum",h).offon("keypress",function(f){if(13==f.keyCode){f.preventDefault();f=a(this).val();f=isNaN(f)?1:parseInt(f,10);var r=c.apply(this.form);f>r&&(f=r);1>f&&(f=1);u.isEnabled()?d.apply(this.form,[f,!1]):l.allowHistory?location.href=vBulletin.makePaginatedUrl(location.href,f):d.apply(this.form,[f,!1])}});a(".js-pagenum",
h).offon("click",function(f){a(this).select()});this.updatePageInfo=function(f,r){if(f&&"object"==typeof f){var x=f.totalpages||1,B=a(".pagenav-controls .pagenav-form",l.context);a(".pagetotal",B).text(x);"undefined"!=typeof f.showseemore&&e.apply(B,[!f.showseemore]);f.perpage=C.conversation.POSTS_PER_PAGE;r&&0<a(".pagenav-container",l.context).length&&C.AJAX({call:"/ajax/render/pagenav",data:{pagenav:f,isAjaxTemplateRender:!0,isAjaxTemplateRenderWithData:!0},success:A=>{a(".pagenav-container",l.context).replaceWith(A.template);
k()}});B.length&&d.apply(B.get(0),[f.pagenumber,r])}};this.updateResultId=function(f){(f=parseInt(f))&&"number"===typeof f&&a("input[name=result-id]",h).val(f)};this.setOption=function(f,r){l[f]=r};this.getOption=function(f){return l[f]};this.updatePageNavigation=function(f,r,x){d.apply(f.get(0),[r,x])}};K=C.ensureObj("contentEntryBox");G=C.data("contententry-data");K.ATTACHLIMIT=Number(G.attachlimit||0)||0;vBulletin.isScrolledIntoView=function(b,c){let d=!1;a.isPlainObject(c)&&"[object Object]"==
c.toString()&&(d=!0,c.top=0,c.bottom=0);b=a(b);if(0==b.length)return!1;var e=a(window).scrollTop(),k=e+a(window).height();let l=b.offset().top;b=l+b.outerHeight();e=l-e;k-=b;d&&(c.top=e,c.bottom=k);return 0<=e&&0<=k};vBulletin.scrollToFixed=function(b){function c(l){e=a.extend({},e,l);if(e.element&&(e.element=e.element instanceof a?e.element:a(e.element),0<e.element.length)){a.inArray(e.fixedAt,["top","bottom"])&&(e.fixedAt="top");var h=e.element,p={width:h.width(),offset:h.offset(),"margin-top":parseInt(h.css("margin-top"),
10),"margin-bottom":parseInt(h.css("margin-bottom"),10),cssPosition:h.css("position"),coordinates:{left:h.css("left"),top:h.css("top"),right:h.css("right"),bottom:h.css("bottom")}},u=a("<div />").addClass("scrolltofixed-filler").hide().insertAfter(h);h.data("origOffsetTop",p.offset.top);h.css("z-index",e.zIndex);h.data("object-instance",d);l=a(window).off("scroll."+k).on("scroll."+k,function(){if(!h.is(":hidden")){var n=a(this).scrollTop();if(0<e.limit&&n>e.limit&&h.hasClass("scrolltofixed"))h.removeClass("scrolltofixed").css({position:"absolute",
left:"auto",right:"auto",top:"auto",bottom:"auto",width:p.width});else if(0<e.limit&&n<e.limit&&n>p.offset.top&&!h.hasClass("scrolltofixed")||0>=e.limit&&n>p.offset.top&&!h.hasClass("scrolltofixed")){if(u.css({display:h.css("display"),width:h.outerWidth(!0),height:h.outerHeight(!0),"float":h.css("float")}),n=vBulletin.Responsive&&vBulletin.Responsive.scrollToFixedBreakPoint?vBulletin.Responsive.scrollToFixedBreakPoint:0,a("#vb-page-body").width()>n?h.addClass("scrolltofixed").width(p.width).css({left:p.offset.left,
right:"auto",width:p.width,top:"top"==e.fixedAt?0:"auto",bottom:"bottom"==e.fixedAt?0:"auto",position:""}):u.hide(),n=p["margin-"+e.fixedAt]){var q={};q[e.fixedAt]=-n+"px";h.animate(q,"fast")}}else n<=p.offset.top&&h.hasClass("scrolltofixed")&&(u.hide(),h.removeClass("scrolltofixed").css({position:"",width:"",left:"",top:"",right:"",bottom:""}))}}).off("resize."+k).on("resize."+k,function(){h.removeClass("scrolltofixed").width("auto").css({position:"",left:""});p.width=h.width();p.offset=h.offset();
a(this).trigger("scroll."+k)});e.triggerOnload&&l.trigger("scroll."+k)}}var d=this,e={element:a(),fixedAt:"top",limit:0,triggerOnload:!0,zIndex:99},k=("scrollToFixed"+Math.random()).replace(".","");this.updateLimit=function(l){isNaN(Number(l))||(e.limit=l,a(window).trigger("scroll."+k))};this.addLimit=function(l){isNaN(Number(l))||(e.limit+=l,a(window).trigger("scroll."+k))};this.reset=function(l){c(l)};c(b)};vBulletin.scrollToAnchor=function(b){b=b.replace(/(:|\.|\[|\]|,|\/)/g,"\\$1");var c=a(b);
console.log("vBulletin.scrollToAnchor() hash: {0}, found: {1}".format(b,c.length));if(0<c.length){var d=c.show().offset().top-2;c.hide();var e=a("html,body"),k=a(".scrolltofixed-floating.scrolltofixed-top"),l=!1;0<k.length&&(1==a(".list-container .list-item:first > a.anchor"+b).length?(k.hasClass("scrolltofixed")&&k.removeClass("scrolltofixed"),d=k.offset().top,l=!0):k.hasClass("scrolltofixed")&&(d-=k.outerHeight()));function h(){e.stop(!0)}e.off("scroll mousedown wheel DOMMouseScroll mousewheel keyup",
h).one("scroll mousedown wheel DOMMouseScroll mousewheel keyup",h);e.animate({scrollTop:d},{duration:1E3,step:function(p,u){l||(p=c.show().offset().top,c.hide(),p-=k.hasClass("scrolltofixed")?k.outerHeight():0,u.end=Math.round(p))},always:function(){c.show();e.off("scroll mousedown wheel DOMMouseScroll mousewheel keyup",h)}});return!1}return!0};location.hash&&vBulletin.scrollToAnchor(location.hash);vBulletin.animateScrollTop=function(b,c){console.log("vBulletin.animateScrollTop({0})".format(b));var d=
a(".scrolltofixed-floating.scrolltofixed-top");if(0<d.length){var e=d.data("origOffsetTop")||d.offset().top;!d.hasClass("scrolltofixed")&&e<b&&(b-=d.outerHeight(!0));e<b&&(b-=d.outerHeight())}a("html, body").animate({scrollTop:b},c)};vBulletin.truncatePostContent=function(b){b=b instanceof a?b:a(b);b.length||(b=a("body"));a(".poll-desc.ellipsis, .message-body.ellipsis",b).each(function(){var c=a(this);truncatedHeight=c.height();c.removeClass("ellipsis");var d=c.height();c.addClass("ellipsis");if(d>
truncatedHeight)c.closest(".list-item-body").find(".post-links").removeClass("hide-see-link").find(".see-link").off("click").on("click",function(){var e=a(this);e.hasClass("more")?c.removeClass("ellipsis"):c.addClass("ellipsis");e.toggleClass("more less");var k=e.text();e.text(e.data("toggle-text")).data("toggle-text",k);return!1})});a(".list-item .see-link.more",b).each(function(c){var d=a(this).closest(".list-item"),e=a(d).find(".post-content");if(0<e.length){var k=!1,l=!1,h=a(this).text(),p="",
u=a(e).html(),n=this;a(this).on("click",function(){nodeid=a(d).attr("data-node-id");k?(a(n).text(h),a(e).html(u),k=!1):l?(a(n).text(vBulletin.phrase.get("see_less")),k=!0,a(e).html(p)):!l&&nodeid&&vBulletin.AJAX({call:"/activity/fetchText",data:{nodeid},success:function(q){p=q.nodeText;if(p.length<=u.length)a(n).addClass("ui-helper-hidden"),postLink=a(n).closest(".post-links").html().replace("<span>|</span>",""),a(n).closest(".post-links").html(postLink);else return a(e).html(p),a(n).text(vBulletin.phrase.get("see_less")),
console.log("loaded content for node "+nodeid),l=k=!0,!1},error:vBulletin.ajaxtools.logAjaxError,api_error:vBulletin.ajaxtools.logApiError});return!1})}})};const T=Number(pageData.userid);C.markchannelsread=function(b,c,d){const e=C.setChannelRead;if(parseInt(b))e(b,c);else if(pageData.channelid&&parseInt(pageData.channelid))e(pageData.channelid,c);else{var k=[];d=a(d).closest(".widget-content").find(".forum-list-container");b=d.find(".forum-item");d=d.find(".subforum-item");var l=function(h,p){(h=
parseInt(a(p).attr("data-channel-id"),10))&&k.push(h)};a.each(b,l);a.each(d,l);a.each(k,function(h,p){h>=k.length-1?e(p,c):e(p,[])})}};vBulletin.markRead=function(b,c=null){T&&(b={nodeid:b},c&&(b.readtime=c),vBulletin.AJAX({call:"/ajax/api/node/markRead",data:b,success:a.noop,api_error:a.noop,error:a.noop}))};vBulletin.markTopicAsRead=function(b){if(b){var c=a('.js-markread-context[data-starter="'+b+'"]'),d=0;a('.js-markread-candidate[data-starter="'+b+'"]',c).each((e,k)=>{e=k.dataset.publishdate||
0;e>d&&(d=e)});0<d&&vBulletin.markRead(b,d)}};C.setChannelRead=function(b,c){T&&(c=C.ensureFun(c.success),C.AJAX({call:"/ajax/api/node/markChannelsRead",data:{nodeid:b},success:c,api_error:L.logApiError}));return!0};vBulletin.ckeditor=vBulletin.ckeditor||{};window.CKEDITOR_BASEPATH=pageData.baseurl+"/js/ckeditor/";vBulletin.ckeditor.requiredScriptsLoaded=!1;vBulletin.ckeditor.requiredScriptsLoadFailed=!1;vBulletin.ckeditor.requiredScriptLoadingStarted=!1;vBulletin.ckeditor.checkEnvironment=function(){return!0};
vBulletin.ckeditor.fireCallbacks=function(b,c,d,e){"error"==d&&"function"==typeof c.error&&c.error(b);"success"==d&&"function"==typeof c.success&&c.success.apply(e,[b,e]);"function"==typeof c.complete&&c.complete(b)};vBulletin.ckeditor.initEditor=function(b,c){c=c||{};b=vBulletin.ckeditor.verifyEditorId(b);console.log("Ckeditor: initEditor({0})".format(b));if(vBulletin.ckeditor.checkEnvironment())vBulletin.ckeditor.requiredScriptsLoaded?vBulletin.ckeditor.doInitEditor(b,c):vBulletin.ckeditor.loadScripts(b,
c);else{var d=a("#"+b).closest(".js-content-entry");d.find("li[data-panel=b-content-entry-panel__content--toggle-editor]").addClass("h-hide");d.find("li[data-panel=b-content-entry-panel__content--smiley]").addClass("h-hide");d.find("form").append(a('<input type="hidden" name="nl2br" value="1" />'));vBulletin.ckeditor.fireCallbacks(b,c,"error")}};vBulletin.ckeditor.loadScripts=function(b,c,d){if(vBulletin.ckeditor.requiredScriptLoadingStarted)console.warn("Ckeditor: Trying to load required scripts more than once.");
else{vBulletin.ckeditor.requiredScriptLoadingStarted=!0;c=c||{};b=b||"";"undefined"===typeof c.hideLoadingDialog||c.hideLoadingDialog||vBulletin.ckeditor.showLoadingDialog(b);var e=function(){!c.showError&&vBulletin.ckeditor.requiredScriptsLoadFailed||vBulletin.warning("error","error_loading_ckeditor_script");vBulletin.loadingIndicator.hide();vBulletin.ckeditor.requiredScriptsLoadFailed=!0;vBulletin.ckeditor.fireCallbacks(b,c,"error")},k=function(){vBulletin.ckeditor.requiredScriptsLoadFailed?(vBulletin.ckeditor.fireCallbacks(b,
c,"error"),c.hideLoadingDialog||vBulletin.ckeditor.hideLoadingDialog(b)):("function"==typeof d&&d(),"function"==typeof vBulletin.ckeditor.doInitEditor&&window.CKEDITOR?(vBulletin.ckeditor.requiredScriptsLoaded=!0,vBulletin.ckeditor.doInitEditor(b,c)):setTimeout(k,10))};"function"==typeof vBulletin.ckeditor.doInitEditor||window.CKEDITOR?k():vBulletin.AJAX({url:vBulletin.getAjaxBaseurl()+"/ajax/render/ckeditor_javascript",success:function(l){for(var h=[],p=/src="([^"]+)"/g;match=p.exec(l);)h.push(match[1]);
var u=function(){0<h.length?(console.log("Ckeditor: Calling getScript for: {0}".format(h[0])),a.getScript(h[0],function(n,q,w){if("success"!=q)return console.warn("Ckeditor: Error loading "+h[0]),e(),!1;console.log("Ckeditor: Script loaded: "+h[0]);h.splice(0,1);u()}).fail(function(n,q,w){console.warn("Ckeditor: Error loading script: "+q+" Exception: "+w);e()})):k()};u()},error_phrase:"error_fetching_dialog"})}};vBulletin.ckeditor.editorExists=function(b){return!1};vBulletin.ckeditor.isEditorEmpty=
function(b){return!0};vBulletin.ckeditor.resetEditor=function(b){return!1};vBulletin.ckeditor.getEditorContent=function(b){b=vBulletin.ckeditor.verifyEditorId(b);return b?vBulletin.ckeditor.editorExists(b)?(b=vBulletin.ckeditor.getEditor(b))&&b.getData?a.trim(b.getData()):!1:a.trim(a("#"+b).val()):!1};vBulletin.ckeditor.focusEditor=function(b){if(b=vBulletin.ckeditor.verifyEditorId(b))vBulletin.ckeditor.editorExists(b)?(b=vBulletin.ckeditor.getEditor(b))&&b.focus():a("#"+b).trigger("focus")};vBulletin.ckeditor.loadingDialogStack=
{};vBulletin.ckeditor.showLoadingDialog=function(b){if("undefined"==typeof vBulletin.ckeditor.loadingDialogStack[b]||!vBulletin.ckeditor.loadingDialogStack[b]){vBulletin.ckeditor.loadingDialogStack[b]=!0;var c=a("#"+b);0<c.length&&c.is(":visible")&&c.prop("disabled",!0);vBulletin.loadingIndicator.show("vBulletin.ckeditor.showLoadingDialog editorId: "+b)}};vBulletin.ckeditor.hideLoadingDialog=function(b){"undefined"!=typeof vBulletin.ckeditor.loadingDialogStack[b]&&vBulletin.ckeditor.loadingDialogStack[b]&&
(vBulletin.ckeditor.loadingDialogStack[b]=!1,a("#"+b).prop("disabled",!1),vBulletin.loadingIndicator.hide("vBulletin.ckeditor.hideLoadingDialog editorId: "+b))};vBulletin.ckeditor.generatedIdCounter=0;vBulletin.ckeditor.verifyEditorId=function(b){b=b||"";if("string"==typeof b)return b;if("object"==typeof b&&"undefined"!=typeof b.checkDirty&&"undefined"!=typeof b.name)return b.name;b=b instanceof a?b:a(b);b.attr("id")||(++vBulletin.ckeditor.generatedIdCounter,b.attr("id","vb-cke-instance-"+vBulletin.ckeditor.generatedIdCounter));
return b.attr("id")};vBulletin.ckeditor.initEditorComponents=function(b,c){b=b||document;a(function(){a(".js-ckeditor-init-on-focus",b).off("focus").on("focus",function(){vBulletin.ckeditor.initEditor(a(this))});a(".js-ckeditor-init-on-page-load",b).each(function(){vBulletin.ckeditor.initEditor(a(this))});if(!c){var d=function(h){if(0==h)return a("<span />").html(vBulletin.phrase.get("no_icon")).get(0);var p=a(".js-content-entry-post-icons option",b).filter((n,q)=>a(q).val()==h),u=p.data("icon-url");
return u?(p=p.text(),a("<img />").attr("src",u).attr("alt","").attr("title",p).get(0)):""},e=a(".js-content-entry-post-icons",b);e.selectBox().on("change",function(){var h=a(this).val();a(".js-content-entry-post-icons.selectBox-dropdown .selectBox-label",b).html(d(h))});a(".js-content-entry-post-icons-selectBox-dropdown-menu li a").each(function(){var h=a(this).attr("rel");a(this).html(d(h))});e.trigger("change");a(".js-content-entry-prefixes",b).selectBox();e=a(".js-content-entry-event-highlights-container",
b);var k=e.is(".h-hide-imp");k&&e.removeClass("h-hide-imp");a(".js-content-entry-event-highlights",b).selectBox();k&&e.addClass("h-hide-imp");var l=[];a(".js-select-box",b).each(function(){for(var h=a(this),p;h.is(":hidden");){p=h.closest(".h-hide");if(1>p.length)break;l.push(p);p.removeClass("h-hide")}h.selectBox()});a.each(l,function(h,p){p.addClass("h-hide")})}})};vBulletin.ckeditor.initEditorComponents(document);a(".js-focus-on-page-load").first().trigger("focus");vBulletin.doReplaceSecurityToken=
function(b){"undefined"!=typeof b&&""!=b&&(a("form").each(function(){var c=a(this);if(this.action&&!vBulletin.isInternalUrl(this.action))return console.log("Skipping security token for external url (form action): "+this.action),!0;"undefined"!=typeof this.method&&"post"==this.method.toLowerCase()&&(c.find('input[name="securitytoken"]').length?c.find('input[name="securitytoken"]').val(b):c.append('<input type="hidden" name="securitytoken" value="'+b+'" />'))}),pageData.securitytoken=b,console.log("Securitytoken updated"))};
var O=null;vBulletin.flashMessage=function(b,c=5){var d=a(".js-flash-message"),e=d.find(".js-flash-message-content");clearTimeout(O);e.text(b);d.removeClass("h-hide").show();O=setTimeout(function(){d.fadeOut(function(){d.addClass("h-hide")})},1E3*c)};vBulletin.clearFlashMessage=()=>{let b=a(".js-flash-message");clearTimeout(O);b.addClass("h-hide")};vBulletin.flashPhrase=function(b,c=5){vBulletin.flashMessage(vBulletin.phrase.get(b),c)};vBulletin.sitebuilder=vBulletin.sitebuilder||{};vBulletin.sitebuilder.toggleSitebuilder=
function(b){b=a(this);b.hasClass("on")?(H.setCookie("sitebuilder_active",""),a(".js-top-menu-sitebuilder").slideUp("fast"),b.removeClass("on"),b.attr("aria-pressed","false")):(a(".js-top-menu-sitebuilder").slideDown("fast"),b.addClass("on"),b.attr("aria-pressed","true"),H.setCookie("sitebuilder_active","1"))};vBulletin.sitebuilder.setupMenuProxy=()=>{var b=a(".js-top-menu-sitebuilder--list");b.find(".js-top-menu-link:not(.js-top-menu-tab--admincp)").removeClass("b-top-menu__item-link--disabled");
b.on("click.menuproxy",".js-top-menu-link:not(.js-top-menu-tab--admincp)",c=>{J();vBulletin.ready(["sb_page","sb_page_style"]).then(()=>{b.off(".menuproxy");a(c.currentTarget).trigger("click")});return!1})};pageData.dstauto&&(K=(new Date).getTimezoneOffset()/60,1==Math.abs(pageData.tzOffset+K)&&vBulletin.AJAX({call:"/profile/save-dst",data:{userid:pageData.userid,clientUtcOffset:K},success:()=>location.reload(),api_error:a.noop,error:a.noop}));vBulletin.initFlexGridFixLastRowAll=function(b){function c(d){R(".js-flexgrid",
".js-flexgrid-item",".js-flexgrid-image","b-flexgrid__item--lastrow","b-flexgrid__item--lastinrow",!0,d);R(".js-photo-preview",".b-gallery-thumbnail-list__item",".b-gallery-thumbnail-list__thumbnail","b-gallery-thumbnail-list__item--lastrow","b-gallery-thumbnail-list__item--lastinrow",!1,d)}c("undefined"==typeof b?!1:b);vBulletin.Responsive.Debounce.registerCallbackOnce(function(){c(!0)})};vBulletin.initFrameImagesWithColor=function(){U(".js-frame-image-wrapper",".js-frame-image")};setTimeout(function(){function b(){clearTimeout(securitytoken_timeout);
if("guest"!=pageData.securitytoken){securitytoken_timeout=setTimeout(b,36E5);var d=function(){3==++securitytoken_errors&&vBulletin.doReplaceSecurityToken("guest")};vBulletin.AJAX({call:"/ajax/replace-securitytoken",data:{securitytoken:pageData.securitytoken},success:function(e){securitytoken_errors=0;vBulletin.doReplaceSecurityToken(e.newtoken)},api_error:d,error:d})}}a.support.selectstart||a.fn.extend({disableSelection:function(){return this.each(function(){a(this).css({"-moz-user-select":"-moz-none",
"-webkit-user-select":"none","-khtml-user-select":"none","-o-user-select":"none","user-select":"none"})})},enableSelection:function(){return this.each(function(){a(this).css({"-moz-user-select":"","-webkit-user-select":"","-khtml-user-select":"","-o-user-select":"","user-select":""})})}});(function(){function d(g){a("textarea.autogrow",g).css("min-height",function(){return a(this).css("height")}).autogrow()}function e(g){g.preventDefault();g=a(".js-refer-user-dialog");g.length?g.dialog("open"):vBulletin.AJAX({call:"/ajax/render/dialog_refer_user",
data:{isAjaxTemplateRenderWithData:!0},success:function(m){a(m.template).appendTo("body");a(".js-refer-user-dialog").dialog({title:vBulletin.phrase.get("refer_a_friend"),autoOpen:!0,modal:!0,resizable:!1,closeOnEscape:!0,showCloseButton:!1,width:500,dialogClass:"dialog-container dialog-box",create:function(){a(".js-close-button",this).on("click",function(v){v.preventDefault();a(this).closest(".js-refer-user-dialog").dialog("close")})},open:function(){function v(y){this.select()}var t=a(".js-referral-link",
this);t.val(t.data("link")).off("focus",v).on("focus",v).trigger("focus")}})}})}function k(g){var m=a(`.js-namecard-html[data-userid="${g}"]`);return new Promise((v,t)=>{0<m.length?v(m):vBulletin.AJAX({call:"/ajax/render/user_namecard",data:{userid:g,isAjaxTemplateRender:!0,isAjaxTemplateRenderWithData:!0},success:function(y){y.template&&(m=a(y.template).filter(".js-namecard-html"),m.appendTo(document.body),v(m))},after_error:()=>{t()}})})}function l(g){var m=parseInt(g.data("vbnamecard")||0);if(Number.isNaN(m))return!1;
k(m).then(v=>{vBulletin.qtip.apply(g,"",{content:function(t,y){t=a(v[0].outerHTML).removeClass("h-hide-imp");t.find(".js-close-qtip").click(()=>{y.hide()});return t},position:{my:"top center",at:"bottom center",viewport:a(window),adjust:{method:"shift flip"}},show:{solo:!1,ready:!0,event:!1},hide:{event:"unfocus",fixed:!0},style:{classes:"qtip--b-namecard"}})});return!0}function h(g){g.find("input.js-dependent-master").each(function(){var m=a(this),v=m.attr("type"),t=function(){var y=m.data("action"),
F=!m.is(":checked"),I=a(document).find(m.data("on"));"invisible"==y?I.toggleClass("h-invisible",F):"hide"==y?I.toggleClass("h-hide-imp",F):(I.find(":input").addBack(":input").prop("disabled",F),I.find("select").addBack("select").selectBox(F?"disable":"enable"))};if("checkbox"==v)m.on("change",t);else if("radio"==v)m.closest("form").find('input[name="'+m.attr("name")+'"]').on("change",t)})}function p(g){vBulletin.flashMessage(g);g=new URL(location.href);g.searchParams.delete("flashmsg");var m=document.title;
History.replaceState({},m,g.href);document.title=m}function u(){a(".js-full-height").each(function(){var g=a(this),m=g.parent();g.css("height","");g.outerHeight(Math.floor(m.height()),!0)})}function n(g){let m=v=>v.src="core/images/default/google-material/image_placeholder.svg";a("img.js-img-fallback",g).each((v,t)=>{!t.complete||t.naturalWidth&&t.naturalHeight||m(t);t.addEventListener("error",()=>m(t))})}vBulletin.loadingIndicator.init();const q=a(document),w=vBulletin.phrase;q.off("click","a.animate-scroll").on("click",
"a.animate-scroll",function(){vBulletin.scrollToAnchor(this.hash)&&(location.href=this.href);return!1});const f=H.createStorage("categoryCollapse"),r=w.get("expand"),x=w.get("collapse");let B=[];function A(g,m){return new Promise((v,t)=>{t=g.length;let y;1>t?v():(y=200/t,y=Math.max(y,1),B.forEach(F=>clearTimeout(F)),m||(g=g.reverse()),g.each((F,I)=>{const P=setTimeout(()=>{m?a(I).fadeIn(F*y):a(I).fadeOut(F*y)},F*y);B.push(P)}),t=setTimeout(()=>{v()},(t-1)*y),B.push(t))})}function z(g,m,v=!0,t=!0){const y=
a('.js-collapse-category-btn[data-nodeid="'+g+'"]'),F=a('.js-category-subitem[data-category-collapse-id="'+g+'"]'),I=a('.js-category-footer[data-category-collapse-id="'+g+'"]'),P=y.is(".js-legacy-tables"),Q=()=>I.toggleClass("category-collapsed",!m);y.toggleClass("collapsed expand",!m);y.toggleClass("collapse",m);I.toggleClass("with-animation",v);v?P?A(F,m).then(Q):(m?F.slideDown("fast"):F.slideUp("fast"),Q()):(F.toggle(m),Q());y.attr("title",m?x:r);t&&f.set(g,m?0:1)}q.offon("click",".js-collapse-category-btn",
g=>{g=a(g.currentTarget);const m=g.data("nodeid");isCollapsed=g.hasClass("collapsed");z(m,isCollapsed)});(function(){const g=f.getAll("categoryCollapse")||{};a(".js-collapse-category-btn").each((m,v)=>{m=v.dataset.nodeid;v=0<Number(v.dataset.collapsedDefault);var t=a('.js-category-subitem[data-category-collapse-id="'+m+'"]').first().closest(".forum-list-container");const y=t.is(".cards");t=t.is(".no-collapse-controls");y||t||(g.hasOwnProperty(m)?0<g[m]&&z(m,!1,!1,!1):v&&z(m,!1,!1,!1))})})();var D=
H.createStorage("collapse");q.offon("click",".canvas-widget .toggle-button",function(g,m){g=a(this);var v=g.closest(".canvas-widget"),t=a(".widget-content",v),y=v.data("widget-instance-id"),F=g.closest(".edit-mode").length;g.hasClass("expand")?(v.removeClass("collapsed"),m?t.show():t.slideDown("slow"),F||D.unset(y)):(m?(t.hide(),v.addClass("collapsed")):t.slideUp("slow",function(){v.addClass("collapsed")}),F||D.set(y,1));g.toggleClass("collapse expand");m=g.attr("title");g.attr("title",g.data("toggle-title")).data("toggle-title",
m);return!1});(function(){var g=D.getAll("collapse");g&&null!=g&&a.each(g,function(m,v){a("#widget_"+m+":not(.widget-no-header-buttons) .widget-header .toggle-button").trigger("click",[!0])})})();a(".conversation-toolbar-wrapper form.toolbar-filter-overlay").trigger("reset");d(q);q.on("vb-loadnewposts",function(g,m){d(q,m.insertedHtml)});a(".edit-switch-container .switch-control").on("click",vBulletin.sitebuilder.toggleSitebuilder);vBulletin.sitebuilder.setupMenuProxy();var E=(new URL(location.href)).searchParams.get("adminAction");
actionMap={quickConfig:".js-top-menu-tab--quicksetup",stylePanel:".js-top-menu-tab--style",editPage:".js-top-menu-tab--editpage"};$action=a(actionMap[E]);0<$action.length?($action.trigger("click"),"editPage"==E&&vBulletin.ready("history").then(()=>{let g=new URL(location.href),m=new vBulletin.history.instance(!0);g.searchParams.delete("adminAction");m.pushState({},document.title,g)})):0==pageData.userid&&actionMap[E]&&vBulletin.assertUserHasAdminPermission("canusesitebuilder",self,a.noop,function(){location.reload()});
a("select.custom-dropdown",".js-select-box").selectBox();q.off("keypress",".js-button").on("keypress",".js-button",function(g){if(32==g.which||13==g.which)g.target&&g.target.nodeName&&"label"==(g.target.nodeName+"").toLowerCase()&&1==a(g.target).find("input").length?a(g.target).find("input").trigger("click"):a(this).trigger("click"),g.preventDefault()});q.off("keypress",".js-link").on("keypress",".js-link",function(g){13==g.which&&(a(this).trigger("click"),g.preventDefault())});a(".js-debug-collapse-list").next("ol, ul").hide();
q.off("click",".js-debug-collapse-list").on("click",".js-debug-collapse-list",function(g){a(this).next("ol, ul").toggle()});q.off("click",".js-refer-user",e).on("click",".js-refer-user",e);q.off("click",".js-toggle-slider").on("click",".js-toggle-slider",function(){var g=a(this);g.is(".b-toggle-slider--yes")?(g.removeClass("b-toggle-slider--yes").addClass("b-toggle-slider--no"),g.find(".b-toggle-slider__radio--no").prop("checked",!0),g.data("value","0")):(g.removeClass("b-toggle-slider--no").addClass("b-toggle-slider--yes"),
g.find(".b-toggle-slider__radio--yes").prop("checked",!0),g.data("value","1"));var m=a(".js-toggle-slider, .js-toggle-slider__dependent"),v=m.index(g),t=!1;m.each(function(y,F){if(y==v)t=!0;else if(1==t)if(y=a(this),y.is(".js-toggle-slider__dependent"))y.toggleClass("h-hide");else return t=!1});g.trigger("change",g.data("value"));return!1});vBulletin.options.get("usenamecard")&&a(document).offon("click","a[data-vbnamecard]",function(g){l(a(g.currentTarget))&&g.preventDefault()});a(document).offon("click",
".js-follow-action",g=>{g=a(g.currentTarget);var m=parseInt(g.data("userid")),v=g.data("action");if("add"!=v&&"delete"!=v||isNaN(m))return!1;vBulletin.AJAX({call:"/ajax/api/user/changeUserRelation",data:{action:v,userid:m},success:function(t){if(1==t.follow||2==t.follow){var y=t.follow;"delete"==v&&(y=0);a(document).trigger("vb-userrelation-change",{newRelation:y,ignoring:t.ignoring,targetUserid:m})}},title_phrase:"profile_guser"})});a(document).offon("vb-userrelation-change",(g,m)=>{var v=parseInt(m.hasOwnProperty("targetUserid")?
m.targetUserid:"");g=m.hasOwnProperty("newRelation")?m.newRelation:null;m=m.hasOwnProperty("ignoring")?m.ignoring:null;var t=`.js-ignore-user[data-userid="${v}"][data-state="`,y=a(`${t}ignoring"]`);t=a(`${t}normal"]`);isNaN(v)||(null!==m&&(y.toggleClass("h-hide-imp",!m),t.toggleClass("h-hide-imp",m)),null!==g&&(y=`.js-follow-action[data-userid="${v}"]`,v=a(y),y=a(`${y}[data-state="${g}"]`),v.addClass("h-hide-imp"),y.removeClass("h-hide-imp"),0===g||m||t.addClass("h-hide-imp")))});a(document).offon("click",
".js-ignore-user",g=>{g=a(g.currentTarget);var m=parseInt(g.data("userid"));g=g.data("action");var v="ignore"==g?1:0;if("ignore"!=g&&"unignore"!=g||isNaN(m))return!1;vBulletin.AJAX({call:"/ajax/api/user/ignoreUser",data:{userid:m,add:v},success:function(t){t&&a(document).trigger("vb-userrelation-change",{ignoring:v,targetUserid:m})},title_phrase:"profile_guser"})});a(".channel-content-widget .new-conversation-btn").off("click").on("click",function(){location.href=pageData.baseurl+"/new-content/"+
pageData.channelid});a(".pagenav-form").on("submit",function(){var g=Number(this.page.value);0<g&&(location.href=this.action+"&p="+g);return!1}).trigger("reset");a(".toolbar-pagenav").off("keydown",".toolbar-pagenav input").on("keydown",".toolbar-pagenav input",function(g){var m=g.which;return g.shiftKey||g.altKey||g.ctrlKey||!(48<=m&&57>=m||96<=m&&105>=m||8==m||9==m||13==m||35==m||36==m||37==m||39==m||46==m||45==m)?!1:!0});a(document).offon("click",".js-post__manage",function(){if("undefined"==typeof vBulletin.inlinemod){var g=
vBulletin.getAjaxBaseurl()+"/js/inlinemod.js?c="+pageData.cachebuster;a.getScript(g,()=>{vBulletin.inlinemod.manage_deleted_form.apply(this)}).fail(()=>{vBulletin.warning("error","error_loading_inlinemod_script")})}else vBulletin.inlinemod.manage_deleted_form.apply(this)});a(document).offon("click",".js-post__show-hide",function(){var g=a(this),m=g.text(),v=g.data("toggle-text"),t=g.hasClass("js-post__show-hide--show");g.closest(".js-post").toggleClass("b-post--show-deleted-content",t);g.html(v).data("toggle-text",
m).toggleClass("js-post__show-hide--show",!t)});a(document).offon("click","a.video-frame",function(g){g.preventDefault();let m=a(g.currentTarget);L.render({template:"bbcode_video",data:m.data(),success:v=>{(v=v.template)&&m.replaceWith(v)}})});q.offon("click",".js-bookmark-toggle",g=>{const m=a(g.currentTarget),v=1!=m.data("bookmarked");g=m.data("nodeid");let t,y;v?(y="addBookmark",t=w.get("remove_bookmark")):(y="removeBookmark",t=w.get("add_bookmark"));C.AJAX({call:"/ajax/api/bookmark/"+y,data:{nodeid:g},
success(F){m.attr("title",t);m.attr("data-bookmarked",v?1:0);m.data("bookmarked",v?1:0)}})});a(document).offon("click","a.markchannelsread, a.navbar_mark_channels_read",function(){C.markchannelsread(0,{success:function(){location.reload()}},a(this));return!1});a(".js-footer-go-to-top").off("click").on("click",function(g){g.preventDefault();a("body,html").animate({scrollTop:0},800)});h(a(document));a("input.js-select-all-master").on("change",function(){var g=a(this);$list=a(document).find(g.data("list"));
$list.prop("checked",g.is(":checked"))});pageData.flash_message&&p(pageData.flash_message);a("input[placeholder]").each(function(){var g=a(this),m=g.attr("placeholder");m&&!g.attr("aria-label")&&g.attr("aria-label",m)});u();vBulletin.Responsive.Debounce.registerCallbackOnce(u);a(document).off("vb-filterposts",u).on("vb-filterposts",u);n(a(document));a(document).on("vb-instrument",g=>{g=a(g.target);n(g);h(g)});vBulletin.ready("global").resolve()})();a("#btnAdvSearch").off("click").on("click",function(d){d.preventDefault();
a(this).data("clicked2submit",1);d=a("#searchForm");a('<input type="hidden" name="AdvSearch" value="1" />').appendTo(d);d.submit()});a("#searchForm").off("submit.searchform").on("submit.searchform",function(d){function e(u,n,q){0<q.length&&q.prop("checked")&&(u[n]=q.val())}var k=a(this),l={},h=k.find("#q"),p=a.trim(h.val());if(0<p.length)l.keywords=p;else if(!a("#btnAdvSearch").data("clicked2submit"))return vBulletin.warning("search","please_provide_search_string",function(){h.trigger("focus")}),
d.stopPropagation(),!1;d=k.find(".searchPopupBody");e(l,"title_only",d.find(".searchFields_title_only"));e(l,"authorid",d.find(".searchFields_authorid"));e(l,"channel",d.find(".searchFields_channel"));k.find("input[name=searchJSON]").val(JSON.stringify(l));return!0});var c=H.getCookie("np_notices_displayed");c=c?c.split(","):[];c=c.concat(a('ul.notices li[data-notice-persistent="0"]').map((d,e)=>a(e).data("notice-id")).get());c=c.filter((d,e)=>c.indexOf(d)===e);0<c.length&&H.setCookie("np_notices_displayed",
c.join(","),!0);a("ul.notices > li > .close").off("click").on("click",function(d){var e=a(this).closest("li");d=e.attr("data-notice-id");vBulletin.AJAX({call:"/ajax/api/notice/dismiss",data:{noticeid:d},success:function(k){e.hide("slow",function(){var l=a(this).parent();0==l.find(">li:visible").length&&l.addClass("h-hide")})}})});a(".js-stylechooser a").off("click").on("click",function(){let d=a(this).data("styleid");H.setCookie("userstyleid",d,365);pageData.userid?L.ajaxSilent({call:"/ajax/apidetach/user/save",
data:{userid:pageData.userid,password:"",user:{styleid:d},options:[""],adminoptions:[""],userfield:[""]},success:()=>location.reload()}):location.reload();return!1});a(".js-languagechooser a").off("click").on("click",function(){H.setCookie("languageid",a(this).data("languageid"),365);location.reload();return!1});vBulletin.doReplaceSecurityToken(pageData.securitytoken);securitytoken_timeout=setTimeout(b,36E5);securitytoken_errors=0;vBulletin.initFlexGridFixLastRowAll();vBulletin.initFrameImagesWithColor();
V();vBulletin.ready("pushnotification").then(d=>{d.getExistingSubscription().then(e=>{const k=d.getEndpointFromCookie();e?k!=e.endpoint&&d.setEndpointToCookie(e.endpoint):d.setEndpointToCookie("")})});setTimeout(function(){""!=pageData.crontask&&vBulletin.ajaxtools.ajaxSilent({call:"/ajax/apidetach/cron/"+pageData.crontask,api_error:a.noop,error:vBulletin.ajaxtools.logAjaxError})},5)},1)})(jQuery);
function JShtmlEncode(a){var J="";a&&"undefined"!==typeof a&&0<a.length&&(J=$("<div/>").text(a).html());return J=String(J).replace(/"/g,"&quot;")}
function isValidEmailAddress(a){return(new RegExp(/(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])*")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?|\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21-\x5a\x53-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])+)\])/i)).test(a)}
function str_repeat(a,J){for(var M="",N=0;N<J;N++)M=M.concat(a);return M}vBulletin.htmlEntities=function(a){return String(a).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;")};vBulletin.htmlEntities_decode=function(a){return String(a).replace(/&amp;/g,"&").replace(/&lt;/g,"<").replace(/&gt;/g,">").replace(/&quot;/g,'"')};
;

// ***************************
// js.compressed/jquery/jquery.qtip.min.js
// ***************************
/*
 qTip2 - Pretty powerful tooltips - v3.0.3
 http://qtip2.com

 Copyright (c) 2016
 Released under the MIT licenses
 http://jquery.org/license

 Date: Wed May 11 2016 10:31 GMT+0100+0100
 Plugins: tips modal viewport svg imagemap ie6
 Styles: core basic css3
*/
(function(z,w,I){(function(e){"function"===typeof define&&define.amd?define(["jquery"],e):jQuery&&!jQuery.fn.qtip&&e(jQuery)})(function(e){function T(a,b,c,d){this.id=c;this.target=a;this.tooltip=null;this.elements={target:a};this._id="qtip-"+c;this.timers={img:{}};this.options=b;this.plugins={};this.cache={event:{},target:e(),disabled:!1,attr:d,onTooltip:!1,lastClass:""};this.rendered=this.destroyed=this.disabled=this.waiting=this.hiddenDuringWait=this.positioning=this.triggering=!1}
function A(a){return null===a||"object"!==e.type(a)}function X(a){return!(e.isFunction(a)||a&&a.attr||a.length||"object"===e.type(a)&&(a.jquery||a.then))}function O(a){var b;if(A(a))return!1;A(a.metadata)&&(a.metadata={type:a.metadata});if("content"in a){var c=a.content;if(A(c)||c.jquery||c.done){var d=X(c)?!1:c;c=a.content={text:d}}else d=c.text;if("ajax"in c){var h=(b=c.ajax)&&!1!==b.once;delete c.ajax;c.text=function(a,c){a=d||e(this).attr(c.options.content.attr)||"Loading...";var f=e.ajax(e.extend({},
b,{context:c})).then(b.success,null,b.error).then(function(a){a&&h&&c.set("content.text",a);return a},function(a,b,d){c.destroyed||0===a.status||c.set("content.text",b+": "+d)});return h?a:(c.set("content.text",a),f)}}"title"in c&&(e.isPlainObject(c.title)&&(c.button=c.title.button,c.title=c.title.text),X(c.title||!1)&&(c.title=!1))}"position"in a&&A(a.position)&&(a.position={my:a.position,at:a.position});"show"in a&&A(a.show)&&(a.show=a.show.jquery?{target:a.show}:!0===a.show?{ready:!0}:{event:a.show});
"hide"in a&&A(a.hide)&&(a.hide=a.hide.jquery?{target:a.hide}:{event:a.hide});"style"in a&&A(a.style)&&(a.style={classes:a.style});e.each(u,function(){this.sanitize&&this.sanitize(a)});return a}function Y(a,b){var c=0,d,e=a;for(b=b.split(".");e=e[b[c++]];)c<b.length&&(d=e);return[d||a,b.pop()]}function ia(a,b){var c,d,e;for(c in this.checks)if(this.checks.hasOwnProperty(c))for(d in this.checks[c])this.checks[c].hasOwnProperty(d)&&(e=(new RegExp(d,"i")).exec(a))&&(b.push(e),("builtin"===c||this.plugins[c])&&
this.checks[c][d].apply(this.plugins[c]||this,b))}function P(a){return ja.concat("").join(a?"-"+a+" ":" ")}function Q(a,b){if(0<b)return setTimeout(e.proxy(a,this),b);a.call(this)}function ka(a){this.tooltip.hasClass(x)||(clearTimeout(this.timers.show),clearTimeout(this.timers.hide),this.timers.show=Q.call(this,function(){this.toggle(!0,a)},this.options.show.delay))}function la(a){if(!this.tooltip.hasClass(x)&&!this.destroyed){var b=e(a.relatedTarget),c=b.closest(".qtip")[0]===this.tooltip[0],d=b[0]===
this.options.show.target[0];clearTimeout(this.timers.show);clearTimeout(this.timers.hide);if(this!==b[0]&&"mouse"===this.options.position.target&&c||this.options.hide.fixed&&/mouse(out|leave|move)/.test(a.type)&&(c||d))try{a.preventDefault(),a.stopImmediatePropagation()}catch(h){}else this.timers.hide=Q.call(this,function(){this.toggle(!1,a)},this.options.hide.delay,this)}}function U(a){!this.tooltip.hasClass(x)&&this.options.hide.inactive&&(clearTimeout(this.timers.inactive),this.timers.inactive=
Q.call(this,function(){this.hide(a)},this.options.hide.inactive))}function Z(a){this.rendered&&0<this.tooltip[0].offsetWidth&&this.reposition(a)}function aa(a,b,c){e(w.body).on((b.split?b:b.join(".qtip "))+".qtip",a,function(){var a=t.api[e.attr(this,"data-qtip-id")];a&&!a.disabled&&c.apply(a,arguments)})}function ma(a,b,c){var d,h=e(w.body),f=a[0]===w?h:a;var g=a.metadata?a.metadata(c.metadata):null;var k="html5"===c.metadata.type&&g?g[c.metadata.name]:null,m=a.data(c.metadata.name||"qtipopts");
try{m="string"===typeof m?e.parseJSON(m):m}catch(v){}g=e.extend(!0,{},t.defaults,c,"object"===typeof m?O(m):null,O(k||g));c=g.position;g.id=b;if("boolean"===typeof g.content.text){var n=a.attr(g.content.attr);if(!1!==g.content.attr&&n)g.content.text=n;else return!1}c.container.length||(c.container=h);!1===c.target&&(c.target=f);!1===g.show.target&&(g.show.target=f);!0===g.show.solo&&(g.show.solo=c.container.closest("body"));!1===g.hide.target&&(g.hide.target=f);!0===g.position.viewport&&(g.position.viewport=
c.container);c.container=c.container.eq(0);c.at=new B(c.at,!0);c.my=new B(c.my);if(a.data("qtip"))if(g.overwrite)a.qtip("destroy",!0);else if(!1===g.overwrite)return!1;a.attr("data-hasqtip",b);g.suppress&&(d=a.attr("title"))&&a.removeAttr("title").attr("oldtitle",d).attr("title","");b=new T(a,g,b,!!n);a.data("qtip",b);return b}function N(a){return a.charAt(0).toUpperCase()+a.slice(1)}function na(a,b){var c=b.charAt(0).toUpperCase()+b.slice(1);c=(b+" "+oa.join(c+" ")+c).split(" ");var d,e,f=0;if(V[b])return a.css(V[b]);
for(;d=c[f++];)if((e=a.css(d))!==I)return V[b]=d,e}function J(a,b){return Math.ceil(parseFloat(na(a,b)))}function ba(a,b){this._ns="tip";this.options=b;this.offset=b.offset;this.size=[b.width,b.height];this.qtip=a;this.init(a)}function ca(a,b){this.options=b;this._ns="-modal";this.qtip=a;this.init(a)}function da(a){this._ns="ie6";this.qtip=a;this.init(a)}var B,u={},ja=["ui-widget","ui-tooltip"],ea="click dblclick mousedown mouseup mousemove mouseleave mouseenter".split(" "),x="qtip-disabled",R,F=
function(){var a;var b=4;for(a=w.createElement("div");(a.innerHTML="\x3c!--[if gt IE "+b+"]><i></i><![endif]--\x3e")&&a.getElementsByTagName("i")[0];b+=1);return 4<b?b:NaN}(),D=parseFloat((""+(/CPU.*OS ([0-9_]{1,5})|(CPU like).*AppleWebKit.*Mobile/i.exec(navigator.userAgent)||[0,""])[1]).replace("undefined","3_2").replace("_",".").replace("_",""))||!1;var l=T.prototype;l._when=function(a){return e.when.apply(e,a)};l.render=function(a){if(this.rendered||this.destroyed)return this;var b=this,c=this.options,
d=this.cache,h=this.elements,f=c.content.text,g=c.content.title,k=c.content.button,m=c.position,n=[];e.attr(this.target[0],"aria-describedby",this._id);d.posClass=this._createPosClass((this.position={my:m.my,at:m.at}).my);this.tooltip=h.tooltip=e("<div/>",{id:this._id,"class":["qtip qtip-default",c.style.classes,d.posClass].join(" "),width:c.style.width||"",height:c.style.height||"",tracking:"mouse"===m.target&&m.adjust.mouse,role:"alert","aria-live":"polite","aria-atomic":!1,"aria-describedby":this._id+
"-content","aria-hidden":!0}).toggleClass(x,this.disabled).attr("data-qtip-id",this.id).data("qtip",this).appendTo(m.container).append(h.content=e("<div />",{"class":"qtip-content",id:this._id+"-content","aria-atomic":!0}));this.rendered=-1;this.positioning=!0;g&&(this._createTitle(),e.isFunction(g)||n.push(this._updateTitle(g,!1)));k&&this._createButton();e.isFunction(f)||n.push(this._updateContent(f,!1));this.rendered=!0;this._setWidget();e.each(u,function(a){var c;"render"===this.initialize&&(c=
this(b))&&(b.plugins[a]=c)});this._unassignEvents();this._assignEvents();this._when(n).then(function(){b._trigger("render");b.positioning=!1;b.hiddenDuringWait||!c.show.ready&&!a||b.toggle(!0,d.event,!1);b.hiddenDuringWait=!1});t.api[this.id]=this;return this};l.destroy=function(a){function b(){if(!this.destroyed){this.destroyed=!0;var a=this.target,b=a.attr("oldtitle"),h;this.rendered&&this.tooltip.stop(1,0).find("*").remove().end().remove();e.each(this.plugins,function(){this.destroy&&this.destroy()});
for(h in this.timers)this.timers.hasOwnProperty(h)&&clearTimeout(this.timers[h]);a.removeData("qtip").removeAttr("data-qtip-id").removeAttr("data-hasqtip").removeAttr("aria-describedby");this.options.suppress&&b&&a.attr("title",b).removeAttr("oldtitle");this._unassignEvents();this.options=this.elements=this.cache=this.timers=this.plugins=this.mouse=null;delete t.api[this.id]}}if(this.destroyed)return this.target;!0===a&&"hide"!==this.triggering||!this.rendered?b.call(this):(this.tooltip.one("tooltiphidden",
e.proxy(b,this)),!this.triggering&&this.hide());return this.target};var W=l.checks={builtin:{"^id$":function(a,b,c,d){c=!0===c?t.nextid:c;var h="qtip-"+c;!1!==c&&0<c.length&&!e("#"+h).length?(this._id=h,this.rendered&&(this.tooltip[0].id=this._id,this.elements.content[0].id=this._id+"-content",this.elements.title[0].id=this._id+"-title")):a[b]=d},"^prerender":function(a,b,c){c&&!this.rendered&&this.render(this.options.show.ready)},"^content.text$":function(a,b,c){this._updateContent(c)},"^content.attr$":function(a,
b,c,d){this.options.content.text===this.target.attr(d)&&this._updateContent(this.target.attr(c))},"^content.title$":function(a,b,c){if(!c)return this._removeTitle();c&&!this.elements.title&&this._createTitle();this._updateTitle(c)},"^content.button$":function(a,b,c){this._updateButton(c)},"^content.title.(text|button)$":function(a,b,c){this.set("content."+b,c)},"^position.(my|at)$":function(a,b,c){"string"===typeof c&&(this.position[b]=a[b]=new B(c,"at"===b))},"^position.container$":function(a,b,
c){this.rendered&&this.tooltip.appendTo(c)},"^show.ready$":function(a,b,c){c&&(!this.rendered&&this.render(!0)||this.toggle(!0))},"^style.classes$":function(a,b,c,d){this.rendered&&this.tooltip.removeClass(d).addClass(c)},"^style.(width|height)":function(a,b,c){this.rendered&&this.tooltip.css(b,c)},"^style.widget|content.title":function(){this.rendered&&this._setWidget()},"^style.def":function(a,b,c){this.rendered&&this.tooltip.toggleClass("qtip-default",!!c)},"^events.(render|show|move|hide|focus|blur)$":function(a,
b,c){this.rendered&&this.tooltip[(e.isFunction(c)?"":"un")+"bind"]("tooltip"+b,c)},"^(show|hide|position).(event|target|fixed|inactive|leave|distance|viewport|adjust)":function(){if(this.rendered){var a=this.options.position;this.tooltip.attr("tracking","mouse"===a.target&&a.adjust.mouse);this._unassignEvents();this._assignEvents()}}}};l.get=function(a){if(this.destroyed)return this;a=Y(this.options,a.toLowerCase());a=a[0][a[1]];return a.precedance?a.string():a};var pa=/^position\.(my|at|adjust|target|container|viewport)|style|content|show\.ready/i,
qa=/^prerender|show\.ready/i;l.set=function(a,b){if(this.destroyed)return this;var c=this.rendered,d=!1,h=this.options;if("string"===typeof a){var f=a;a={};a[f]=b}else a=e.extend({},a);e.each(a,function(b,f){if(c&&qa.test(b))delete a[b];else{var m=Y(h,b.toLowerCase());var g=m[0][m[1]];m[0][m[1]]=f&&f.nodeType?e(f):f;d=pa.test(b)||d;a[b]=[m[0],m[1],f,g]}});O(h);this.positioning=!0;e.each(a,e.proxy(ia,this));this.positioning=!1;this.rendered&&0<this.tooltip[0].offsetWidth&&d&&this.reposition("mouse"===
h.position.target?null:this.cache.event);return this};l._update=function(a,b){var c=this,d=this.cache;if(!this.rendered||!a)return!1;e.isFunction(a)&&(a=a.call(this.elements.target,d.event,this)||"");if(e.isFunction(a.then))return d.waiting=!0,a.then(function(a){d.waiting=!1;return c._update(a,b)},null,function(a){return c._update(a,b)});if(!1===a||!a&&""!==a)return!1;a.jquery&&0<a.length?b.empty().append(a.css({display:"block",visibility:"visible"})):b.html(a);return this._waitForContent(b).then(function(a){c.rendered&&
0<c.tooltip[0].offsetWidth&&c.reposition(d.event,!a.length)})};l._waitForContent=function(a){var b=this.cache;b.waiting=!0;return(e.fn.imagesLoaded?a.imagesLoaded():(new e.Deferred).resolve([])).done(function(){b.waiting=!1}).promise()};l._updateContent=function(a,b){this._update(a,this.elements.content,b)};l._updateTitle=function(a,b){!1===this._update(a,this.elements.title,b)&&this._removeTitle(!1)};l._createTitle=function(){var a=this.elements,b=this._id+"-title";a.titlebar&&this._removeTitle();
a.titlebar=e("<div />",{"class":"qtip-titlebar "+(this.options.style.widget?P("header"):"")}).append(a.title=e("<div />",{id:b,"class":"qtip-title","aria-atomic":!0})).insertBefore(a.content).on("mousedown keydown mouseup keyup mouseout",".qtip-close",function(a){e(this).toggleClass("ui-state-active ui-state-focus","down"===a.type.substr(-4))}).on("mouseover mouseout",".qtip-close",function(a){e(this).toggleClass("ui-state-hover","mouseover"===a.type)});this.options.content.button&&this._createButton()};
l._removeTitle=function(a){var b=this.elements;b.title&&(b.titlebar.remove(),b.titlebar=b.title=b.button=null,!1!==a&&this.reposition())};l._createPosClass=function(a){return"qtip-pos-"+(a||this.options.position.my).abbrev()};l.reposition=function(a,b){if(!this.rendered||this.positioning||this.destroyed)return this;this.positioning=!0;var c=this.cache,d=this.tooltip,h=this.options.position,f=h.target,g=h.my,k=h.at,m=h.viewport,n=h.container,v=h.adjust,p=v.method.split(" "),q=d.outerWidth(!1),H=d.outerHeight(!1),
l=0,K=0,t=d.css("position"),r={left:0,top:0},x=0<d[0].offsetWidth,B=a&&"scroll"===a.type,y=e(z),A=n[0].ownerDocument,E=this.mouse,C;if(e.isArray(f)&&2===f.length)k={x:"left",y:"top"},r={left:f[0],top:f[1]};else if("mouse"===f)k={x:"left",y:"top"},(!v.mouse||this.options.hide.distance)&&c.origin&&c.origin.pageX?a=c.origin:!a||a&&("resize"===a.type||"scroll"===a.type)?a=c.event:E&&E.pageX&&(a=E),"static"!==t&&(r=n.offset()),A.body.offsetWidth!==(z.innerWidth||A.documentElement.clientWidth)&&(C=e(w.body).offset()),
r={left:a.pageX-r.left+(C&&C.left||0),top:a.pageY-r.top+(C&&C.top||0)},v.mouse&&B&&E&&(r.left-=(E.scrollX||0)-y.scrollLeft(),r.top-=(E.scrollY||0)-y.scrollTop());else{"event"===f?a&&a.target&&"scroll"!==a.type&&"resize"!==a.type?c.target=e(a.target):a.target||(c.target=this.elements.target):"event"!==f&&(c.target=e(f.jquery?f:this.elements.target));f=c.target;f=e(f).eq(0);if(0===f.length)return this;if(f[0]===w||f[0]===z)l=D?z.innerWidth:f.width(),K=D?z.innerHeight:f.height(),f[0]===z&&(r={top:(m||
f).scrollTop(),left:(m||f).scrollLeft()});else if(u.imagemap&&f.is("area"))var G=u.imagemap(this,f,k,u.viewport?p:!1);else u.svg&&f&&f[0].ownerSVGElement?G=u.svg(this,f,k,u.viewport?p:!1):(l=f.outerWidth(!1),K=f.outerHeight(!1),r=f.offset());G&&(l=G.width,K=G.height,C=G.offset,r=G.position);r=this.reposition.offset(f,r,n);if(3.1<D&&4.1>D||4.3<=D&&4.33>D||!D&&"fixed"===t)r.left-=y.scrollLeft(),r.top-=y.scrollTop();if(!G||G&&!1!==G.adjustable)r.left+="right"===k.x?l:"center"===k.x?l/2:0,r.top+="bottom"===
k.y?K:"center"===k.y?K/2:0}r.left+=v.x+("right"===g.x?-q:"center"===g.x?-q/2:0);r.top+=v.y+("bottom"===g.y?-H:"center"===g.y?-H/2:0);u.viewport?(g=r.adjusted=u.viewport(this,r,h,l,K,q,H),C&&g.left&&(r.left+=C.left),C&&g.top&&(r.top+=C.top),g.my&&(this.position.my=g.my)):r.adjusted={left:0,top:0};c.posClass!==(C=this._createPosClass(this.position.my))&&(c.posClass=C,d.removeClass(c.posClass).addClass(C));if(!this._trigger("move",[r,m.elem||m],a))return this;delete r.adjusted;!1===b||!x||isNaN(r.left)||
isNaN(r.top)||"mouse"===f||!e.isFunction(h.effect)?d.css(r):e.isFunction(h.effect)&&(h.effect.call(d,this,e.extend({},r)),d.queue(function(a){e(this).css({opacity:"",height:""});F&&this.style.removeAttribute("filter");a()}));this.positioning=!1;return this};l.reposition.offset=function(a,b,c){if(!c[0])return b;a=e(a[0].ownerDocument);var d=!!F&&"CSS1Compat"!==w.compatMode;c=c[0];var h,f,g;do if("static"!==(f=e.css(c,"position"))){if("fixed"===f){f=c.getBoundingClientRect();var k=a;b.left+=-1*k.scrollLeft();
b.top+=-1*k.scrollTop()}else f=e(c).position(),f.left+=parseFloat(e.css(c,"borderLeftWidth"))||0,f.top+=parseFloat(e.css(c,"borderTopWidth"))||0;b.left-=f.left+(parseFloat(e.css(c,"marginLeft"))||0);b.top-=f.top+(parseFloat(e.css(c,"marginTop"))||0);h||"hidden"===(g=e.css(c,"overflow"))||"visible"===g||(h=e(c))}while(c=c.offsetParent);h&&(h[0]!==a[0]||d)&&(b.left+=1*h.scrollLeft(),b.top+=1*h.scrollTop());return b};var L=(B=l.reposition.Corner=function(a,b){a=(""+a).replace(/([A-Z])/," $1").replace(/middle/gi,
"center").toLowerCase();this.x=(a.match(/left|right/i)||a.match(/center/)||["inherit"])[0].toLowerCase();this.y=(a.match(/top|bottom|center/i)||["inherit"])[0].toLowerCase();this.forceY=!!b;a=a.charAt(0);this.precedance="t"===a||"b"===a?"y":"x"}).prototype;L.invert=function(a,b){this[a]="left"===this[a]?"right":"right"===this[a]?"left":b||this[a]};L.string=function(a){var b=this.x,c=this.y;b=b!==c?"center"===b||"center"!==c&&("y"===this.precedance||this.forceY)?[c,b]:[b,c]:[b];return!1!==a?b.join(" "):
b};L.abbrev=function(){var a=this.string(!1);return a[0].charAt(0)+(a[1]&&a[1].charAt(0)||"")};L.clone=function(){return new B(this.string(),this.forceY)};l.toggle=function(a,b,c){var d=this.cache,h=this.options,f=this.tooltip;if(b){if(/over|enter/.test(b.type)&&d.event&&/out|leave/.test(d.event.type)&&h.show.target.add(b.target).length===h.show.target.length&&f.has(b.relatedTarget).length)return this;d.event=e.event.fix(b)}this.waiting&&!a&&(this.hiddenDuringWait=!0);if(!this.rendered)return a?this.render(1):
this;if(this.destroyed||this.disabled)return this;h=a?"show":"hide";var g=this.options[h],k=this.options.position,m=this.options.content,n=this.tooltip.css("width"),v=this.tooltip.is(":visible"),p=a||1===g.target.length,q=!b||2>g.target.length||d.target[0]===b.target;(typeof a).search("boolean|number")&&(a=!v);q=(v=!f.is(":animated")&&v===a&&q)?null:!!this._trigger(h,[90]);if(this.destroyed)return this;!1!==q&&a&&this.focus(b);if(!q||v)return this;e.attr(f[0],"aria-hidden",!a);a?(this.mouse&&(d.origin=
e.event.fix(this.mouse)),e.isFunction(m.text)&&this._updateContent(m.text,!1),e.isFunction(m.title)&&this._updateTitle(m.title,!1),!R&&"mouse"===k.target&&k.adjust.mouse&&(e(w).on("mousemove.qtip",this._storeMouse),R=!0),n||f.css("width",f.outerWidth(!1)),this.reposition(b,c),n||f.css("width",""),g.solo&&("string"===typeof g.solo?e(g.solo):e(".qtip",g.solo)).not(f).not(g.target).qtip("hide",new e.Event("tooltipsolo"))):(clearTimeout(this.timers.show),delete d.origin,R&&!e('.qtip[tracking="true"]:visible',
g.solo).not(f).length&&(e(w).off("mousemove.qtip"),R=!1),this.blur(b));var H=e.proxy(function(){a?(F&&f[0].style.removeAttribute("filter"),f.css("overflow",""),"string"===typeof g.autofocus&&e(this.options.show.autofocus,f).focus(),this.options.show.target.trigger("qtip-"+this.id+"-inactive")):f.css({display:"",visibility:"",opacity:"",left:"",top:""});this._trigger(a?"visible":"hidden")},this);!1===g.effect||!1===p?(f[h](),H()):e.isFunction(g.effect)?(f.stop(1,1),g.effect.call(f,this),f.queue("fx",
function(a){H();a()})):f.fadeTo(90,a?1:0,H);a&&g.target.trigger("qtip-"+this.id+"-inactive");return this};l.show=function(a){return this.toggle(!0,a)};l.hide=function(a){return this.toggle(!1,a)};l.focus=function(a){if(!this.rendered||this.destroyed)return this;var b=e(".qtip"),c=this.tooltip,d=parseInt(c[0].style.zIndex,10),h=t.zindex+b.length;!c.hasClass("qtip-focus")&&this._trigger("focus",[h],a)&&(d!==h&&(b.each(function(){this.style.zIndex>d&&--this.style.zIndex}),b.filter(".qtip-focus").qtip("blur",
a)),c.addClass("qtip-focus")[0].style.zIndex=h);return this};l.blur=function(a){if(!this.rendered||this.destroyed)return this;this.tooltip.removeClass("qtip-focus");this._trigger("blur",[this.tooltip.css("zIndex")],a);return this};l.disable=function(a){if(this.destroyed)return this;"toggle"===a?a=!(this.rendered?this.tooltip.hasClass(x):this.disabled):"boolean"!==typeof a&&(a=!0);this.rendered&&this.tooltip.toggleClass(x,a).attr("aria-disabled",a);this.disabled=!!a;return this};l.enable=function(){return this.disable(!1)};
l._createButton=function(){var a=this,b=this.elements,c=b.tooltip,d=this.options.content.button,h="string"===typeof d?d:"Close tooltip";b.button&&b.button.remove();b.button=d.jquery?d:e("<a />",{"class":"qtip-close "+(this.options.style.widget?"":"qtip-icon"),title:h,"aria-label":h}).prepend(e("<span />",{"class":"ui-icon ui-icon-close",html:"&times;"}));b.button.appendTo(b.titlebar||c).attr("role","button").click(function(b){c.hasClass(x)||a.hide(b);return!1})};l._updateButton=function(a){if(!this.rendered)return!1;
var b=this.elements.button;a?this._createButton():b.remove()};l._setWidget=function(){var a=this.options.style.widget,b=this.elements,c=b.tooltip,d=c.hasClass(x);c.removeClass(x);x=a?"ui-state-disabled":"qtip-disabled";c.toggleClass(x,d);c.toggleClass("ui-helper-reset "+P(),a).toggleClass("qtip-default",this.options.style.def&&!a);b.content&&b.content.toggleClass(P("content"),a);b.titlebar&&b.titlebar.toggleClass(P("header"),a);b.button&&b.button.toggleClass("qtip-icon",!a)};l._storeMouse=function(a){(this.mouse=
e.event.fix(a)).type="mousemove";return this};l._bind=function(a,b,c,d,h){if(a&&c&&b.length)return d="."+this._id+(d?"-"+d:""),e(a).on((b.split?b:b.join(d+" "))+d,e.proxy(c,h||this)),this};l._unbind=function(a,b){a&&e(a).off("."+this._id+(b?"-"+b:""));return this};l._trigger=function(a,b,c){var d=new e.Event("tooltip"+a);d.originalEvent=c&&e.extend({},c)||this.cache.event||null;this.triggering=a;this.tooltip.trigger(d,[this].concat(b||[]));this.triggering=!1;return!d.isDefaultPrevented()};l._bindEvents=
function(a,b,c,d,h,f){var g=c.filter(d).add(d.filter(c)),k=[];g.length&&(e.each(b,function(b,c){b=e.inArray(c,a);-1<b&&k.push(a.splice(b,1)[0])}),k.length&&(this._bind(g,k,function(a){(this.rendered&&0<this.tooltip[0].offsetWidth?f:h).call(this,a)}),c=c.not(g),d=d.not(g)));this._bind(c,a,h);this._bind(d,b,f)};l._assignInitialEvents=function(a){function b(a){if(this.disabled||this.destroyed)return!1;this.cache.event=a&&e.event.fix(a);this.cache.target=a&&e(a.target);clearTimeout(this.timers.show);
this.timers.show=Q.call(this,function(){this.render("object"===typeof a||c.show.ready)},c.prerender?0:c.show.delay)}var c=this.options,d=c.show.target,h=c.hide.target,f=c.show.event?e.trim(""+c.show.event).split(" "):[],g=c.hide.event?e.trim(""+c.hide.event).split(" "):[];this._bind(this.elements.target,["remove","removeqtip"],function(){this.destroy(!0)},"destroy");/mouse(over|enter)/i.test(c.show.event)&&!/mouse(out|leave)/i.test(c.hide.event)&&g.push("mouseleave");this._bind(d,"mousemove",function(a){this._storeMouse(a);
this.cache.onTarget=!0});this._bindEvents(f,g,d,h,b,function(){if(!this.timers)return!1;clearTimeout(this.timers.show)});(c.show.ready||c.prerender)&&b.call(this,a)};l._assignEvents=function(){var a=this,b=this.options,c=b.position,d=this.tooltip,h=b.show.target,f=b.hide.target,g=c.container,k=c.viewport,m=e(w),n=e(z),v=b.show.event?e.trim(""+b.show.event).split(" "):[],p=b.hide.event?e.trim(""+b.hide.event).split(" "):[];e.each(b.events,function(b,c){a._bind(d,"toggle"===b?["tooltipshow","tooltiphide"]:
["tooltip"+b],c,null,d)});/mouse(out|leave)/i.test(b.hide.event)&&"window"===b.hide.leave&&this._bind(m,["mouseout","blur"],function(a){/select|option/.test(a.target.nodeName)||a.relatedTarget||this.hide(a)});b.hide.fixed?f=f.add(d.addClass("qtip-fixed")):/mouse(over|enter)/i.test(b.show.event)&&this._bind(f,"mouseleave",function(){clearTimeout(this.timers.show)});-1<(""+b.hide.event).indexOf("unfocus")&&this._bind(g.closest("html"),["mousedown","touchstart"],function(a){var b=e(a.target),c=this.rendered&&
!this.tooltip.hasClass(x)&&0<this.tooltip[0].offsetWidth,d=0<b.parents(".qtip").filter(this.tooltip[0]).length;b[0]===this.target[0]||b[0]===this.tooltip[0]||d||this.target.has(b[0]).length||!c||this.hide(a)});"number"===typeof b.hide.inactive&&(this._bind(h,"qtip-"+this.id+"-inactive",U,"inactive"),this._bind(f.add(d),t.inactiveEvents,U));this._bindEvents(v,p,h,f,ka,la);this._bind(h.add(d),"mousemove",function(a){if("number"===typeof b.hide.distance){var c=this.cache.origin||{},d=this.options.hide.distance,
f=Math.abs;(f(a.pageX-c.pageX)>=d||f(a.pageY-c.pageY)>=d)&&this.hide(a)}this._storeMouse(a)});"mouse"===c.target&&c.adjust.mouse&&(b.hide.event&&this._bind(h,["mouseenter","mouseleave"],function(a){if(!this.cache)return!1;this.cache.onTarget="mouseenter"===a.type}),this._bind(m,"mousemove",function(a){this.rendered&&this.cache.onTarget&&!this.tooltip.hasClass(x)&&0<this.tooltip[0].offsetWidth&&this.reposition(a)}));(c.adjust.resize||k.length)&&this._bind(e.event.special.resize?k:n,"resize",Z);c.adjust.scroll&&
this._bind(n.add(c.container),"scroll",Z)};l._unassignEvents=function(){var a=this.options,b=a.show.target,c=a.hide.target;a=e.grep([this.elements.target[0],this.rendered&&this.tooltip[0],a.position.container[0],a.position.viewport[0],a.position.container.closest("html")[0],z,w],function(a){return"object"===typeof a});b&&b.toArray&&(a=a.concat(b.toArray()));c&&c.toArray&&(a=a.concat(c.toArray()));this._unbind(a)._unbind(a,"destroy")._unbind(a,"inactive")};e(function(){aa(".qtip",["mouseenter","mouseleave"],
function(a){var b="mouseenter"===a.type,c=e(a.currentTarget),d=e(a.relatedTarget||a.target),h=this.options;b?(this.focus(a),c.hasClass("qtip-fixed")&&!c.hasClass(x)&&clearTimeout(this.timers.hide)):"mouse"===h.position.target&&h.position.adjust.mouse&&h.hide.event&&h.show.target&&!d.closest(h.show.target[0]).length&&this.hide(a);c.toggleClass("qtip-hover",b)});aa("[data-qtip-id]",ea,U)});var t=e.fn.qtip=function(a,b,c){var d=(""+a).toLowerCase(),h=null,f=e.makeArray(arguments).slice(1),g=f[f.length-
1],k=this[0]?e.data(this[0],"qtip"):null;if(!arguments.length&&k||"api"===d)return k;if("string"===typeof a)return this.each(function(){var a=e.data(this,"qtip");if(!a)return!0;g&&g.timeStamp&&(a.cache.event=g);if(!b||"option"!==d&&"options"!==d)a[d]&&a[d].apply(a,f);else if(c!==I||e.isPlainObject(b))a.set(b,c);else return h=a.get(b),!1}),null!==h?h:this;if("object"===typeof a||!arguments.length)return k=O(e.extend(!0,{},a)),this.each(function(a){a=e.isArray(k.id)?k.id[a]:k.id;a=!a||!1===a||1>a.length||
t.api[a]?t.nextid++:a;var b=ma(e(this),a,k);if(!1===b)return!0;t.api[a]=b;e.each(u,function(){"initialize"===this.initialize&&this(b)});b._assignInitialEvents(g)})};e.qtip=T;t.api={};e.each({attr:function(a,b){if(this.length){var c=this[0],d=e.data(c,"qtip");if("title"===a&&d&&d.options&&"object"===typeof d&&"object"===typeof d.options&&d.options.suppress){if(2>arguments.length)return e.attr(c,"oldtitle");d&&"title"===d.options.content.attr&&d.cache.attr&&d.set("content.text",b);return this.attr("oldtitle",
b)}}return e.fn.attr_replacedByqTip.apply(this,arguments)},clone:function(a){var b=e.fn.clone_replacedByqTip.apply(this,arguments);a||b.filter("[oldtitle]").attr("title",function(){return e.attr(this,"oldtitle")}).removeAttr("oldtitle");return b}},function(a,b){if(!b||e.fn[a+"_replacedByqTip"])return!0;var c=e.fn[a+"_replacedByqTip"]=e.fn[a];e.fn[a]=function(){return b.apply(this,arguments)||c.apply(this,arguments)}});e.ui||(e.cleanData_replacedByqTip=e.cleanData,e.cleanData=function(a){for(var b=
0,c;(c=e(a[b])).length;b++)if(c.attr("data-hasqtip"))try{c.triggerHandler("removeqtip")}catch(d){}e.cleanData_replacedByqTip.apply(this,arguments)});t.version="3.0.3";t.nextid=0;t.inactiveEvents=ea;t.zindex=15E3;t.defaults={prerender:!1,id:!1,overwrite:!0,suppress:!0,content:{text:!0,attr:"title",title:!1,button:!1},position:{my:"top left",at:"bottom right",target:!1,container:!1,viewport:!1,adjust:{x:0,y:0,mouse:!0,scroll:!0,resize:!0,method:"flipinvert flipinvert"},effect:function(a,b){e(this).animate(b,
{duration:200,queue:!1})}},show:{target:!1,event:"mouseenter",effect:!0,delay:90,solo:!1,ready:!1,autofocus:!1},hide:{target:!1,event:"mouseleave",effect:!0,delay:0,fixed:!1,inactive:!1,leave:"window",distance:!1},style:{classes:"",widget:!1,width:!1,height:!1,def:!0},events:{render:null,move:null,show:null,hide:null,toggle:null,visible:null,hidden:null,focus:null,blur:null}};var S=!!w.createElement("canvas").getContext,fa=/rgba?\(0, 0, 0(, 0)?\)|transparent|#123456/i,V={},oa=["Webkit","O","Moz",
"ms"];if(S){l=z.devicePixelRatio||1;L=function(){var a=w.createElement("canvas").getContext("2d");return a.backingStorePixelRatio||a.webkitBackingStorePixelRatio||a.mozBackingStorePixelRatio||a.msBackingStorePixelRatio||a.oBackingStorePixelRatio||1}();var M=l/L}else var ha=function(a,b,c){return"<qtipvml:"+a+' xmlns="urn:schemas-microsoft.com:vml" class="qtip-vml" '+(b||"")+' style="behavior: url(#default#VML); '+(c||"")+'" />'};e.extend(ba.prototype,{init:function(a){var b=this.element=a.elements.tip=
e("<div />",{"class":"qtip-tip"}).prependTo(a.tooltip);if(S){var c=e("<canvas />").appendTo(this.element)[0].getContext("2d");c.lineJoin="miter";c.miterLimit=1E5;c.save()}else c=ha("shape",'coordorigin="0,0"',"position:absolute;"),this.element.html(c+c),a._bind(e("*",b).add(b),["click","mousedown"],function(a){a.stopPropagation()},this._ns);a._bind(a.tooltip,"tooltipmove",this.reposition,this._ns,this);this.create()},_swapDimensions:function(){this.size[0]=this.options.height;this.size[1]=this.options.width},
_resetDimensions:function(){this.size[0]=this.options.width;this.size[1]=this.options.height},_useTitle:function(a){var b=this.qtip.elements.titlebar;return b&&("top"===a.y||"center"===a.y&&this.element.position().top+this.size[1]/2+this.options.offset<b.outerHeight(!0))},_parseCorner:function(a){var b=this.qtip.options.position.my;!1===a||!1===b?a=!1:!0===a?a=new B(b.string()):a.string||(a=new B(a),a.fixed=!0);return a},_parseWidth:function(a,b,c){var d=this.qtip.elements;b="border"+N(b)+"Width";
return(c?J(c,b):J(d.content,b)||J(this._useTitle(a)&&d.titlebar||d.content,b)||J(d.tooltip,b))||0},_parseRadius:function(a){var b=this.qtip.elements,c="border"+N(a.y)+N(a.x)+"Radius";return 9>F?0:J(this._useTitle(a)&&b.titlebar||b.content,c)||J(b.tooltip,c)||0},_invalidColour:function(a,b,c){b=a.css(b);return!b||c&&b===a.css(c)||fa.test(b)?!1:b},_parseColours:function(a){var b=this.qtip.elements,c=this.element.css("cssText",""),d="border"+N(a[a.precedance])+N("color");a=this._useTitle(a)&&b.titlebar||
b.content;var h=this._invalidColour,f=[];f[0]=h(c,"background-color")||h(a,"background-color")||h(b.content,"background-color")||h(b.tooltip,"background-color")||c.css("background-color");f[1]=h(c,d,"color")||h(a,d,"color")||h(b.content,d,"color")||h(b.tooltip,d,"color")||b.tooltip.css(d);e("*",c).add(c).css("cssText","background-color:transparent !important;border:0 !important;");return f},_calculateSize:function(a){var b="y"===a.precedance,c=this.options.width,d=this.options.height,e="c"===a.abbrev(),
f=(b?c:d)*(e?.5:1),g=Math.pow;a=Math.round;var k=Math.sqrt(g(f,2)+g(d,2));f=[this.border/f*k,this.border/d*k];f[2]=Math.sqrt(g(f[0],2)-g(this.border,2));f[3]=Math.sqrt(g(f[1],2)-g(this.border,2));e=(k+f[2]+f[3]+(e?0:f[0]))/k;c=[a(e*c),a(e*d)];return b?c:c.reverse()},_calculateTip:function(a,b,c){c=c||1;b=b||this.size;var d=b[0]*c;b=b[1]*c;c=Math.ceil(d/2);var e=Math.ceil(b/2);d={br:[0,0,d,b,d,0],bl:[0,0,d,0,0,b],tr:[0,b,d,0,d,b],tl:[0,0,0,b,d,b],tc:[0,b,c,0,d,b],bc:[0,0,d,0,c,b],rc:[0,0,d,e,0,b],
lc:[d,0,d,b,0,e]};d.lt=d.br;d.rt=d.bl;d.lb=d.tr;d.rb=d.tl;return d[a.abbrev()]},_drawCoords:function(a,b){a.beginPath();a.moveTo(b[0],b[1]);a.lineTo(b[2],b[3]);a.lineTo(b[4],b[5]);a.closePath()},create:function(){var a=this.corner=(S||F)&&this._parseCorner(this.options.corner);if(this.enabled=!!this.corner&&"c"!==this.corner.abbrev())this.qtip.cache.corner=a.clone(),this.update();this.element.toggle(this.enabled);return this.corner},update:function(a,b){if(!this.enabled)return this;var c=this.qtip.elements,
d=this.element,h=d.children(),f=this.options,g=this.size,k=f.mimic,m=Math.round;a||(a=this.qtip.cache.corner||this.corner);!1===k?k=a:(k=new B(k),k.precedance=a.precedance,"inherit"===k.x?k.x=a.x:"inherit"===k.y?k.y=a.y:k.x===k.y&&(k[a.precedance]=a[a.precedance]));var n=k.precedance;"x"===a.precedance?this._swapDimensions():this._resetDimensions();var v=this.color=this._parseColours(a);if("transparent"!==v[1]){var p=this.border=this._parseWidth(a,a[a.precedance]);f.border&&1>p&&!fa.test(v[1])&&(v[0]=
v[1]);this.border=p=!0!==f.border?f.border:p}else this.border=p=0;var q=this.size=this._calculateSize(a);d.css({width:q[0],height:q[1],lineHeight:q[1]+"px"});d="y"===a.precedance?[m("left"===k.x?p:"right"===k.x?q[0]-g[0]-p:(q[0]-g[0])/2),m("top"===k.y?q[1]-g[1]:0)]:[m("left"===k.x?q[0]-g[0]:0),m("top"===k.y?p:"bottom"===k.y?q[1]-g[1]-p:(q[1]-g[1])/2)];if(S){n=h[0].getContext("2d");n.restore();n.save();n.clearRect(0,0,6E3,6E3);var l=this._calculateTip(k,g,M);g=this._calculateTip(k,this.size,M);h.attr("width",
q[0]*M).attr("height",q[1]*M);h.css("width",q[0]).css("height",q[1]);this._drawCoords(n,g);n.fillStyle=v[1];n.fill();n.translate(d[0]*M,d[1]*M);this._drawCoords(n,l);n.fillStyle=v[0];n.fill()}else l=this._calculateTip(k),l="m"+l[0]+","+l[1]+" l"+l[2]+","+l[3]+" "+l[4]+","+l[5]+" xe",d[2]=p&&/^(r|b)/i.test(a.string())?8===F?2:1:0,h.css({coordsize:q[0]+p+" "+q[1]+p,antialias:""+(-1<k.string().indexOf("center")),left:d[0]-d[2]*Number("x"===n),top:d[1]-d[2]*Number("y"===n),width:q[0]+p,height:q[1]+p}).each(function(a){var b=
e(this);b[b.prop?"prop":"attr"]({coordsize:q[0]+p+" "+q[1]+p,path:l,fillcolor:v[0],filled:!!a,stroked:!a}).toggle(!(!p&&!a));!a&&b.html(ha("stroke",'weight="'+2*p+'px" color="'+v[1]+'" miterlimit="1000" joinstyle="miter"'))});z.opera&&setTimeout(function(){c.tip.css({display:"inline-block",visibility:"visible"})},1);!1!==b&&this.calculate(a,q)},calculate:function(a,b){if(!this.enabled)return!1;var c=this,d=this.qtip.elements,h=this.element,f=this.options.offset,g={};a=a||this.corner;var k=a.precedance;
b=b||this._calculateSize(a);var m=[a.x,a.y];"x"===k&&m.reverse();e.each(m,function(e,h){if("center"===h){var m="y"===k?"left":"top";g[m]="50%";g["margin-"+m]=-Math.round(b["y"===k?0:1]/2)+f}else{m=c._parseWidth(a,h,d.tooltip);var n=c._parseWidth(a,h,d.content);var l=c._parseRadius(a);g[h]=Math.max(-c.border,e?n:f+(l>m?l:-m))}});g[a[k]]-=b["x"===k?0:1];h.css({margin:"",top:"",bottom:"",left:"",right:""}).css(g);return g},reposition:function(a,b,c){function d(a,b,c,d,e){"shift"===a&&f.precedance===
b&&g[d]&&"center"!==f[c]?f.precedance="x"===f.precedance?"y":"x":"shift"!==a&&g[d]&&(f[b]="center"===f[b]?0<g[d]?d:e:f[b]===d?e:d)}function e(a,b,d){"center"===f[a]?n["margin-"+b]=m[a]=p["margin-"+b]-g[b]:(l=p[d]!==I?[g[b],-p[b]]:[-g[b],p[b]],(m[a]=Math.max(l[0],l[1]))>l[0]&&(c[b]-=g[b],m[b]=!1),n[p[d]!==I?d:b]=m[a])}if(this.enabled){a=b.cache;var f=this.corner.clone(),g=c.adjusted,k=b.options.position.adjust.method.split(" ");b=k[0];k=k[1]||k[0];var m={left:!1,top:!1,x:0,y:0},n={},l;!0!==this.corner.fixed&&
(d(b,"x","y","left","right"),d(k,"y","x","top","bottom"),f.string()===a.corner.string()&&a.cornerTop===g.top&&a.cornerLeft===g.left||this.update(f,!1));var p=this.calculate(f);p.right!==I&&(p.left=-p.right);p.bottom!==I&&(p.top=-p.bottom);p.user=this.offset;m.left="shift"===b&&!!g.left;m.left&&e("x","left","right");m.top="shift"===k&&!!g.top;m.top&&e("y","top","bottom");this.element.css(n).toggle(!(m.x&&m.y||"center"===f.x&&m.y||"center"===f.y&&m.x));c.left-=p.left.charAt?p.user:"shift"!==b||m.top||
!m.left&&!m.top?p.left+this.border:0;c.top-=p.top.charAt?p.user:"shift"!==k||m.left||!m.left&&!m.top?p.top+this.border:0;a.cornerLeft=g.left;a.cornerTop=g.top;a.corner=f.clone()}},destroy:function(){this.qtip._unbind(this.qtip.tooltip,this._ns);this.qtip.elements.tip&&this.qtip.elements.tip.find("*").remove().end().remove()}});l=u.tip=function(a){return new ba(a,a.options.style.tip)};l.initialize="render";l.sanitize=function(a){if(a.style&&"tip"in a.style){var b=a.style.tip;"object"!==typeof b&&(b=
a.style.tip={corner:b});/string|boolean/i.test(typeof b.corner)||(b.corner=!0)}};W.tip={"^position.my|style.tip.(corner|mimic|border)$":function(){this.create();this.qtip.reposition()},"^style.tip.(height|width)$":function(a){this.size=[a.width,a.height];this.update();this.qtip.reposition()},"^content.title|style.(classes|widget)$":function(){this.update()}};e.extend(!0,t.defaults,{style:{tip:{corner:!0,mimic:!1,width:6,height:6,border:!0,offset:0}}});var y=function(){function a(a){if(e.expr[":"].focusable)return e.expr[":"].focusable;
var b=!isNaN(e.attr(a,"tabindex")),c=a.nodeName&&a.nodeName.toLowerCase();if("area"===c){b=a.parentNode;c=b.name;if(!a.href||!c||"map"!==b.nodeName.toLowerCase())return!1;a=e("img[usemap=#"+c+"]")[0];return!!a&&a.is(":visible")}return/input|select|textarea|button|object/.test(c)?!a.disabled:"a"===c?a.href||b:b}function b(a){1>h.length&&a.length?a.not("body").blur():h.first().focus()}function c(a){if(k.is(":visible")){a=e(a.target);var c=f.tooltip,d=a.closest(".qtip");(1>d.length?0:parseInt(d[0].style.zIndex,
10)>parseInt(c[0].style.zIndex,10))||a.closest(".qtip")[0]===c[0]||b(a)}}var d=this,h={},f,g,k;e.extend(d,{init:function(){k=d.elem=e("<div />",{id:"qtip-overlay",html:"<div></div>"}).on("mousedown",!1).hide();e(w.body).on("focusin.qtip-modal",c);e(w).on("keydown.qtip-modal",function(a){f&&f.options.show.modal.escape&&27===a.keyCode&&f.hide(a)});k.on("click.qtip-modal",function(a){f&&f.options.show.modal.blur&&f.hide(a)});return d},update:function(b){f=b;h=!1!==b.options.show.modal.stealfocus?b.tooltip.find("*").filter(function(){return a(this)}):
[]},toggle:function(a,c,h){var m=a.tooltip,l=a.options.show.modal,n=l.effect,v=c?"show":"hide",u=k.is(":visible");m=e(".qtip-modal").filter(":visible:not(:animated)").not(m);d.update(a);c&&!1!==l.stealfocus&&b(e(":focus"));k.toggleClass("blurs",l.blur);c&&k.appendTo(w.body);if(k.is(":animated")&&u===c&&!1!==g||!c&&m.length)return d;k.stop(!0,!1);if(e.isFunction(n))n.call(k,c);else if(!1===n)k[v]();else k.fadeTo(parseInt(h,10)||90,c?1:0,function(){c||k.hide()});c||k.queue(function(a){k.css({left:"",
top:""});e(".qtip-modal").length||k.detach();a()});g=c;f.destroyed&&(f=null);return d}});d.init()};y=new y;e.extend(ca.prototype,{init:function(a){var b=a.tooltip;if(!this.options.on)return this;a.elements.overlay=y.elem;b.addClass("qtip-modal").css("z-index",t.modal_zindex+e(".qtip-modal").length);a._bind(b,["tooltipshow","tooltiphide"],function(a,d,h){d=a.originalEvent;if(a.target===b[0])if(d&&"tooltiphide"===a.type&&/mouse(leave|enter)/.test(d.type)&&e(d.relatedTarget).closest(y.elem[0]).length)try{a.preventDefault()}catch(f){}else(!d||
d&&"tooltipsolo"!==d.type)&&this.toggle(a,"tooltipshow"===a.type,h)},this._ns,this);a._bind(b,"tooltipfocus",function(a,d){if(!a.isDefaultPrevented()&&a.target===b[0]){var c=e(".qtip-modal"),f=t.modal_zindex+c.length,g=parseInt(b[0].style.zIndex,10);y.elem[0].style.zIndex=f-1;c.each(function(){this.style.zIndex>g&&--this.style.zIndex});c.filter(".qtip-focus").qtip("blur",a.originalEvent);b.addClass("qtip-focus")[0].style.zIndex=f;y.update(d);try{a.preventDefault()}catch(k){}}},this._ns,this);a._bind(b,
"tooltiphide",function(a){a.target===b[0]&&e(".qtip-modal").filter(":visible").not(b).last().qtip("focus",a)},this._ns,this)},toggle:function(a,b,c){if(a&&a.isDefaultPrevented())return this;y.toggle(this.qtip,!!b,c)},destroy:function(){this.qtip.tooltip.removeClass("qtip-modal");this.qtip._unbind(this.qtip.tooltip,this._ns);y.toggle(this.qtip,!1);delete this.qtip.elements.overlay}});l=u.modal=function(a){return new ca(a,a.options.show.modal)};l.sanitize=function(a){a.show&&("object"!==typeof a.show.modal?
a.show.modal={on:!!a.show.modal}:"undefined"===typeof a.show.modal.on&&(a.show.modal.on=!0))};t.modal_zindex=t.zindex-200;l.initialize="render";W.modal={"^show.modal.(on|blur)$":function(){this.destroy();this.init();this.qtip.elems.overlay.toggle(0<this.qtip.tooltip[0].offsetWidth)}};e.extend(!0,t.defaults,{show:{modal:{on:!1,effect:!0,blur:!0,stealfocus:!0,escape:!0}}});u.viewport=function(a,b,c,d,e,f,g){function h(a,c,d,e,f,h,g,k,m){var l=b[f],n=v[a],q=p[a],t=n===f?m:n===h?-m:-m/2,u=F[f]+D[f]-(r?
0:y[f]),w=u-l;m=l+m-("width"===g?A:B)-u;c=t-(v.precedance===a||n===v[c]?q===f?k:q===h?-k:-k/2:0)-("center"===q?k/2:0);"shift"===d?(c=(n===f?1:-1)*t,b[f]+=0<w?w:0<m?-m:0,b[f]=Math.max(-y[f]+D[f],l-c,Math.min(Math.max(-y[f]+D[f]+("width"===g?A:B),l+c),b[f],"center"===n?l-t:1E9))):(e*="flipinvert"===d?2:0,0<w&&(n!==f||0<m)?(b[f]-=c+e,E.invert(a,f)):0<m&&(n!==h||0<w)&&(b[f]-=("center"===n?-c:c)+e,E.invert(a,h)),b[f]<F[f]&&-b[f]>m&&(b[f]=l,E=v.clone()));return b[f]-l}var m=c.target,l=a.elements.tooltip,
v=c.my,p=c.at;a=c.adjust;var q=a.method.split(" "),u=q[0];q=q[1]||q[0];var t=c.viewport,x=c.container;c={left:0,top:0};if(!t.jquery||m[0]===z||m[0]===w.body||"none"===a.method)return c;var y=x.offset()||c;var r="static"===x.css("position");m=t[0]===z;l="fixed"===l.css("position");var A=m?t.width():t.outerWidth(!1);var B=m?t.height():t.outerHeight(!1);var F={left:l?0:t.scrollLeft(),top:l?0:t.scrollTop()};var D=!m&&t.offset()||c;if("shift"!==u||"shift"!==q)var E=v.clone();return c={left:"none"!==u?
h("x","y",u,a.x,"left","right","width",d,f):0,top:"none"!==q?h("y","x",q,a.y,"top","bottom","height",e,g):0,my:E}};u.polys={polygon:function(a,b){var c={width:0,height:0,position:{top:1E10,right:0,bottom:0,left:1E10},adjustable:!1},d,e=[],f=1,g=1;for(d=a.length;d--;){var k=[parseInt(a[--d],10),parseInt(a[d+1],10)];k[0]>c.position.right&&(c.position.right=k[0]);k[0]<c.position.left&&(c.position.left=k[0]);k[1]>c.position.bottom&&(c.position.bottom=k[1]);k[1]<c.position.top&&(c.position.top=k[1]);e.push(k)}var m=
c.width=Math.abs(c.position.right-c.position.left);var l=c.height=Math.abs(c.position.bottom-c.position.top);if("c"===b.abbrev())c.position={left:c.position.left+c.width/2,top:c.position.top+c.height/2};else{for(;0<m&&0<l&&0<f&&0<g;)for(m=Math.floor(m/2),l=Math.floor(l/2),f="left"===b.x?m:"right"===b.x?c.width-m:f+Math.floor(m/2),g="top"===b.y?l:"bottom"===b.y?c.height-l:g+Math.floor(l/2),d=e.length;d--&&!(2>e.length);)a=e[d][0]-c.position.left,k=e[d][1]-c.position.top,("left"===b.x&&a>=f||"right"===
b.x&&a<=f||"center"===b.x&&(a<f||a>c.width-f)||"top"===b.y&&k>=g||"bottom"===b.y&&k<=g||"center"===b.y&&(k<g||k>c.height-g))&&e.splice(d,1);c.position={left:e[0][0],top:e[0][1]}}return c},rect:function(a,b,c,d){return{width:Math.abs(c-a),height:Math.abs(d-b),position:{left:Math.min(a,c),top:Math.min(b,d)}}},_angles:{tc:1.5,tr:1.75,tl:1.25,bc:.5,br:.25,bl:.75,rc:2,lc:1,c:0},ellipse:function(a,b,c,d,e){var f=u.polys._angles[e.abbrev()];e=0===f?0:c*Math.cos(f*Math.PI);f=d*Math.sin(f*Math.PI);return{width:2*
c-Math.abs(e),height:2*d-Math.abs(f),position:{left:a+e,top:b+f},adjustable:!1}},circle:function(a,b,c,d){return u.polys.ellipse(a,b,c,c,d)}};u.svg=function(a,b,c){var d=b[0],h=e(d.ownerSVGElement),f=d.ownerDocument;b=(parseInt(b.css("stroke-width"),10)||0)/2;for(var g,k,m,l;!d.getBBox;)d=d.parentNode;if(!d.getBBox||!d.parentNode)return!1;switch(d.nodeName){case "ellipse":case "circle":b=u.polys.ellipse(d.cx.baseVal.value,d.cy.baseVal.value,(d.rx||d.r).baseVal.value+b,(d.ry||d.r).baseVal.value+b,
c);break;case "line":case "polygon":case "polyline":l=d.points||[{x:d.x1.baseVal.value,y:d.y1.baseVal.value},{x:d.x2.baseVal.value,y:d.y2.baseVal.value}];b=[];m=-1;for(g=l.numberOfItems||l.length;++m<g;)k=l.getItem?l.getItem(m):l[m],b.push.apply(b,[k.x,k.y]);b=u.polys.polygon(b,c);break;default:b=d.getBBox(),b={width:b.width,height:b.height,position:{left:b.x,top:b.y}}}c=b.position;h=h[0];h.createSVGPoint&&(d=d.getScreenCTM(),l=h.createSVGPoint(),l.x=c.left,l.y=c.top,h=l.matrixTransform(d),c.left=
h.x,c.top=h.y);f!==w&&"mouse"!==a.position.target&&(a=e((f.defaultView||f.parentWindow).frameElement).offset())&&(c.left+=a.left,c.top+=a.top);f=e(f);c.left+=f.scrollLeft();c.top+=f.scrollTop();return b};u.imagemap=function(a,b,c){b.jquery||(b=e(b));var d=(b.attr("shape")||"rect").toLowerCase().replace("poly","polygon");a=e('img[usemap="#'+b.parent("map").attr("name")+'"]');b=e.trim(b.attr("coords")).replace(/,$/,"").split(",");var h;if(!a.length)return!1;if("polygon"===d)d=u.polys.polygon(b,c);else if(u.polys[d]){var f=
-1;var g=b.length;for(h=[];++f<g;)h.push(parseInt(b[f],10));d=u.polys[d].apply(this,h.concat(c))}else return!1;c=a.offset();c.left+=Math.ceil((a.outerWidth(!1)-a.width())/2);c.top+=Math.ceil((a.outerHeight(!1)-a.height())/2);d.position.left+=c.left;d.position.top+=c.top;return d};e.extend(da.prototype,{_scroll:function(){var a=this.qtip.elements.overlay;a&&(a[0].style.top=e(z).scrollTop()+"px")},init:function(a){var b=a.tooltip;1>e("select, object").length&&(this.bgiframe=a.elements.bgiframe=e('<iframe class="qtip-bgiframe" frameborder="0" tabindex="-1" src="javascript:\'\';"  style="display:block; position:absolute; z-index:-1; filter:alpha(opacity=0); -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";"></iframe>').appendTo(b),
a._bind(b,"tooltipmove",this.adjustBGIFrame,this._ns,this));this.redrawContainer=e("<div/>",{id:"qtip-rcontainer"}).appendTo(w.body);a.elements.overlay&&a.elements.overlay.addClass("qtipmodal-ie6fix")&&(a._bind(z,["scroll","resize"],this._scroll,this._ns,this),a._bind(b,["tooltipshow"],this._scroll,this._ns,this));this.redraw()},adjustBGIFrame:function(){var a=this.qtip.tooltip,b={height:a.outerHeight(!1),width:a.outerWidth(!1)},c=this.qtip.plugins.tip,d=this.qtip.elements.tip;a=parseInt(a.css("borderLeftWidth"),
10)||0;a={left:-a,top:-a};c&&d&&(c="x"===c.corner.precedance?["width","left"]:["height","top"],a[c[1]]-=d[c[0]]());this.bgiframe.css(a).css(b)},redraw:function(){if(1>this.qtip.rendered||this.drawing)return this;var a=this.qtip.tooltip,b=this.qtip.options.style,c=this.qtip.options.position.container;this.qtip.drawing=1;b.height&&a.css("height",b.height);if(b.width)a.css("width",b.width);else{a.css("width","").appendTo(this.redrawContainer);var d=a.width();1>d%2&&(d+=1);var e=a.css("maxWidth")||"";
var f=a.css("minWidth")||"";b=-1<(e+f).indexOf("%")?c.width()/100:0;e=(-1<e.indexOf("%")?b:1*parseInt(e,10))||d;f=(-1<f.indexOf("%")?b:1*parseInt(f,10))||0;d=e+f?Math.min(Math.max(d,f),e):d;a.css("width",Math.round(d)).appendTo(c)}this.drawing=0;return this},destroy:function(){this.bgiframe&&this.bgiframe.remove();this.qtip._unbind([z,this.qtip.tooltip],this._ns)}});(u.ie6=function(a){return 6===F?new da(a):!1}).initialize="render";W.ie6={"^content|style$":function(){this.redraw()}}})})(window,document);
;

// ***************************
// js.compressed/qtip.js
// ***************************
vBulletin.precache(["no_preview_text_available","working_ellipsis"],["threadpreview"]);
vBulletin.qtip=function(a){function k(b,d,l){var g=["left","right"];vBulletin.isRtl()&&g.reverse();d={style:{classes:"qtip-shadow qtip-rounded "+d},position:{my:"top "+g[0],at:"bottom "+g[1],viewport:a(window)}};a.extend(d,l);b.qtip(d)}function m(b){k(a(".js-tooltip[title]",b))}(function(){function b(l,g){var e=g.elements.tooltip;window.setTimeout(function(){var c=parseInt(e.css("left"),10),f=a(window).scrollLeft();if(c<f)e.css("left",f+1);else{var h=e.outerWidth(),n=a(window).width();h=c+h;f+=n;
h>f&&e.css("left",c-(h-f)-1)}},0)}var d=a.fn.qtip;a.fn.qtip=function(){"object"==typeof arguments[0]&&("undefined"==typeof arguments[0].events&&(arguments[0].events={}),arguments[0].events.move="function"==typeof arguments[0].events.move?vBulletin.ajaxtools.runBeforeCallback(arguments[0].events.move,b):b);return d.apply(this,arguments)}})();m(a(document));a(document).on("vb-instrument",function(b){m(a(b.target))});(0<a(".channel-content-widget").length&&a(".channel-content-widget").eq(0).attr("data-canviewtopiccontent")||
0<a(".search-results-widget").length)&&a(document).offon("mouseover",".topic-list-container .topic-title, .conversation-list .post-title, .conversation-list .b-post__title",function(){if(0<vBulletin.options.get("threadpreview")){var b=a(this);if("1"!=b.data("vb-qtip-preview-initialized")){b.data("vb-qtip-preview-initialized","1");var d=parseInt(b.closest(".topic-item").attr("data-node-id")||b.closest(".js-post").attr("data-node-id"));vBulletin.isRtl();k(b,"qtip-topicpreview",{content:{text:function(l,
g){var e=function(c){var f=c?c:vBulletin.phrase.get("no_preview_text_available");g.set("content.text",f);return c};return d?(vBulletin.AJAX({call:"/ajax/fetch-node-preview",data:{nodeid:d},success:function(c){e(a.trim(c))},api_error:function(){e()},error:function(c,f,h){e(f+": "+h)}}),vBulletin.phrase.get("working_ellipsis")):e()}},show:{delay:500},hide:{event:"mouseleave click"}});b.trigger("mouseover")}}else a(document).off("mouseover",".topic-list-container .topic-title, .conversation-list .post-title, .conversation-list .b-post__title")});
return{apply:k}}(jQuery);
;

// ***************************
// js.compressed/jquery/jquery.jcarousel.custom.min.js
// ***************************
/*! jCarousel - v0.3.9 - 2018-07-30
* http://sorgalla.com/jcarousel/
* Copyright (c) 2006-2018 Jan Sorgalla; Licensed MIT */
!function(t){"use strict";var i=t.jCarousel={};i.version="0.3.9";var s=/^([+\-]=)?(.+)$/;i.parseTarget=function(t){var i=!1,e="object"!=typeof t?s.exec(t):null;return e?(t=parseInt(e[2],10)||0,e[1]&&(i=!0,"-="===e[1]&&(t*=-1))):"object"!=typeof t&&(t=parseInt(t,10)||0),{target:t,relative:i}},i.detectCarousel=function(t){for(var i;t.length>0;){if((i=t.filter("[data-jcarousel]")).length>0)return i;if((i=t.find("[data-jcarousel]")).length>0)return i;t=t.parent()}return null},i.base=function(s){return{version:i.version,_options:{},_element:null,_carousel:null,_init:t.noop,_create:t.noop,_destroy:t.noop,_reload:t.noop,create:function(){return this._element.attr("data-"+s.toLowerCase(),!0).data(s,this),!1===this._trigger("create")?this:(this._create(),this._trigger("createend"),this)},destroy:function(){return!1===this._trigger("destroy")?this:(this._destroy(),this._trigger("destroyend"),this._element.removeData(s).removeAttr("data-"+s.toLowerCase()),this)},reload:function(t){return!1===this._trigger("reload")?this:(t&&this.options(t),this._reload(),this._trigger("reloadend"),this)},element:function(){return this._element},options:function(i,s){if(0===arguments.length)return t.extend({},this._options);if("string"==typeof i){if(void 0===s)return void 0===this._options[i]?null:this._options[i];this._options[i]=s}else this._options=t.extend({},this._options,i);return this},carousel:function(){return this._carousel||(this._carousel=i.detectCarousel(this.options("carousel")||this._element),this._carousel||t.error('Could not detect carousel for plugin "'+s+'"')),this._carousel},_trigger:function(i,e,r){var n,o=!1;return r=[this].concat(r||[]),(e||this._element).each(function(){n=t.Event((s+":"+i).toLowerCase()),t(this).trigger(n,r),n.isDefaultPrevented()&&(o=!0)}),!o}}},i.plugin=function(s,e){var r=t[s]=function(i,s){this._element=t(i),this.options(s),this._init(),this.create()};return r.fn=r.prototype=t.extend({},i.base(s),e),t.fn[s]=function(i){var e=Array.prototype.slice.call(arguments,1),n=this;return"string"==typeof i?this.each(function(){var r=t(this).data(s);if(!r)return t.error("Cannot call methods on "+s+' prior to initialization; attempted to call method "'+i+'"');if(!t.isFunction(r[i])||"_"===i.charAt(0))return t.error('No such method "'+i+'" for '+s+" instance");var o=r[i].apply(r,e);return o!==r&&void 0!==o?(n=o,!1):void 0}):this.each(function(){var e=t(this).data(s);e instanceof r?e.reload(i):new r(this,i)}),n},r}}(jQuery),function(t,i){"use strict";var s=t(i),e=function(t){return parseFloat(t)||0};t.jCarousel.plugin("jcarousel",{animating:!1,tail:0,inTail:!1,resizeState:null,resizeTimer:null,lt:null,vertical:!1,rtl:!1,circular:!1,underflow:!1,relative:!1,_options:{list:function(){return this.element().children().eq(0)},items:function(){return this.list().children()},animation:400,transitions:!1,wrap:null,vertical:null,rtl:null,center:!1},_list:null,_items:null,_target:t(),_first:t(),_last:t(),_visible:t(),_fullyvisible:t(),_init:function(){var t=this;return t.resizeState=s.width()+"x"+s.height(),this.onWindowResize=function(){t.resizeTimer&&clearTimeout(t.resizeTimer),t.resizeTimer=setTimeout(function(){var i=s.width()+"x"+s.height();i!==t.resizeState&&(t.resizeState=i,t.reload())},100)},this},_create:function(){this._reload(),s.on("resize.jcarousel",this.onWindowResize)},_destroy:function(){s.off("resize.jcarousel",this.onWindowResize)},_reload:function(){this.vertical=this.options("vertical"),null==this.vertical&&(this.vertical=e(this.list().height())>e(this.list().width())),this.rtl=this.options("rtl"),null==this.rtl&&(this.rtl=function(i){if("rtl"===(""+i.attr("dir")).toLowerCase())return!0;var s=!1;return i.parents("[dir]").each(function(){if(/rtl/i.test(t(this).attr("dir")))return s=!0,!1}),s}(this._element)),this.lt=this.vertical?"top":"left",this.relative="relative"===this.list().css("position"),this._list=null,this._items=null;var i=this.index(this._target)>=0?this._target:this.closest();this.circular="circular"===this.options("wrap"),this.underflow=!1;var s={left:0,top:0};return i.length>0&&(this._prepare(i),this.list().find("[data-jcarousel-clone]").remove(),this._items=null,this.underflow=this._fullyvisible.length>=this.items().length,this.circular=this.circular&&!this.underflow,s[this.lt]=this._position(i)+"px"),this.move(s),this},list:function(){if(null===this._list){var i=this.options("list");this._list=t.isFunction(i)?i.call(this):this._element.find(i)}return this._list},items:function(){if(null===this._items){var i=this.options("items");this._items=(t.isFunction(i)?i.call(this):this.list().find(i)).not("[data-jcarousel-clone]")}return this._items},index:function(t){return this.items().index(t)},closest:function(){var i,s=this,r=this.list().position()[this.lt],n=t(),o=!1,l=this.vertical?"bottom":this.rtl&&!this.relative?"left":"right";return this.rtl&&this.relative&&!this.vertical&&(r+=e(this.list().width())-this.clipping()),this.items().each(function(){if(n=t(this),o)return!1;var a=s.dimension(n);if((r+=a)>=0){if(i=a-e(n.css("margin-"+l)),!(Math.abs(r)-a+i/2<=0))return!1;o=!0}}),n},target:function(){return this._target},first:function(){return this._first},last:function(){return this._last},visible:function(){return this._visible},fullyvisible:function(){return this._fullyvisible},hasNext:function(){if(!1===this._trigger("hasnext"))return!0;var t=this.options("wrap"),i=this.items().length-1,s=this.options("center")?this._target:this._last;return!!(i>=0&&!this.underflow&&(t&&"first"!==t||this.index(s)<i||this.tail&&!this.inTail))},hasPrev:function(){if(!1===this._trigger("hasprev"))return!0;var t=this.options("wrap");return!!(this.items().length>0&&!this.underflow&&(t&&"last"!==t||this.index(this._first)>0||this.tail&&this.inTail))},clipping:function(){return e(this._element["inner"+(this.vertical?"Height":"Width")]())},dimension:function(t){return e(t["outer"+(this.vertical?"Height":"Width")](!0))},scroll:function(i,s,e){if(this.animating)return this;if(!1===this._trigger("scroll",null,[i,s]))return this;t.isFunction(s)&&(e=s,s=!0);var r=t.jCarousel.parseTarget(i);if(r.relative){var n,o,l,a,h,u,c,f,d=this.items().length-1,_=Math.abs(r.target),p=this.options("wrap");if(r.target>0){var g=this.index(this._last);if(g>=d&&this.tail)this.inTail?"both"===p||"last"===p?this._scroll(0,s,e):t.isFunction(e)&&e.call(this,!1):this._scrollTail(s,e);else if(n=this.index(this._target),this.underflow&&n===d&&("circular"===p||"both"===p||"last"===p)||!this.underflow&&g===d&&("both"===p||"last"===p))this._scroll(0,s,e);else if(l=n+_,this.circular&&l>d){for(f=d,h=this.items().get(-1);f++<l;)h=this.items().eq(0),(u=this._visible.index(h)>=0)&&h.after(h.clone(!0).attr("data-jcarousel-clone",!0)),this.list().append(h),u||((c={})[this.lt]=this.dimension(h),this.moveBy(c)),this._items=null;this._scroll(h,s,e)}else this._scroll(Math.min(l,d),s,e)}else if(this.inTail)this._scroll(Math.max(this.index(this._first)-_+1,0),s,e);else if(o=this.index(this._first),n=this.index(this._target),l=(a=this.underflow?n:o)-_,a<=0&&(this.underflow&&"circular"===p||"both"===p||"first"===p))this._scroll(d,s,e);else if(this.circular&&l<0){for(f=l,h=this.items().get(0);f++<0;){h=this.items().eq(-1),(u=this._visible.index(h)>=0)&&h.after(h.clone(!0).attr("data-jcarousel-clone",!0)),this.list().prepend(h),this._items=null;var m=this.dimension(h);(c={})[this.lt]=-m,this.moveBy(c)}this._scroll(h,s,e)}else this._scroll(Math.max(l,0),s,e)}else this._scroll(r.target,s,e);return this._trigger("scrollend"),this},moveBy:function(t,i){var s=this.list().position(),r=1,n=0;return this.rtl&&!this.vertical&&(r=-1,this.relative&&(n=e(this.list().width())-this.clipping())),t.left&&(t.left=e(s.left)+n+e(t.left)*r+"px"),t.top&&(t.top=e(s.top)+n+e(t.top)*r+"px"),this.move(t,i)},move:function(i,s){s=s||{};var e=this.options("transitions"),r=!!e,n=!!e.transforms,o=!!e.transforms3d,l=s.duration||0,a=this.list();if(!r&&l>0)a.animate(i,s);else{var h=s.complete||t.noop,u={};if(r){var c={transitionDuration:a.css("transitionDuration"),transitionTimingFunction:a.css("transitionTimingFunction"),transitionProperty:a.css("transitionProperty")},f=h;h=function(){t(this).css(c),f.call(this)},u={transitionDuration:(l>0?l/1e3:0)+"s",transitionTimingFunction:e.easing||s.easing,transitionProperty:l>0?n||o?"all":i.left?"left":"top":"none",transform:"none"}}o?u.transform="translate3d("+(i.left||0)+","+(i.top||0)+",0)":n?u.transform="translate("+(i.left||0)+","+(i.top||0)+")":t.extend(u,i),r&&l>0&&a.one("transitionend webkitTransitionEnd oTransitionEnd otransitionend MSTransitionEnd",h),a.css(u),l<=0&&a.each(function(){h.call(this)})}},_scroll:function(i,s,r){if(this.animating)return t.isFunction(r)&&r.call(this,!1),this;if("object"!=typeof i?i=this.items().eq(i):void 0===i.jquery&&(i=t(i)),0===i.length)return t.isFunction(r)&&r.call(this,!1),this;this.inTail=!1,this._prepare(i);var n=this._position(i);if(n===e(this.list().position()[this.lt]))return t.isFunction(r)&&r.call(this,!1),this;var o={};return o[this.lt]=n+"px",this._animate(o,s,r),this},_scrollTail:function(i,s){if(this.animating||!this.tail)return t.isFunction(s)&&s.call(this,!1),this;var r=this.list().position()[this.lt];this.rtl&&this.relative&&!this.vertical&&(r+=e(this.list().width())-this.clipping()),this.rtl&&!this.vertical?r+=this.tail:r-=this.tail,this.inTail=!0;var n={};return n[this.lt]=r+"px",this._update({target:this._target.next(),fullyvisible:this._fullyvisible.slice(1).add(this._visible.last())}),this._animate(n,i,s),this},_animate:function(i,s,e){if(e=e||t.noop,!1===this._trigger("animate"))return e.call(this,!1),this;this.animating=!0;var r=this.options("animation"),n=t.proxy(function(){this.animating=!1;var t=this.list().find("[data-jcarousel-clone]");t.length>0&&(t.remove(),this._reload()),this._trigger("animateend"),e.call(this,!0)},this),o="object"==typeof r?t.extend({},r):{duration:r},l=o.complete||t.noop;return!1===s?o.duration=0:void 0!==t.fx.speeds[o.duration]&&(o.duration=t.fx.speeds[o.duration]),o.complete=function(){n(),l.call(this)},this.move(i,o),this},_prepare:function(i){var s,r,n,o=this.index(i),l=o,a=this.dimension(i),h=this.clipping(),u=this.vertical?"bottom":this.rtl?"left":"right",c=this.options("center"),f={target:i,first:i,last:i,visible:i,fullyvisible:a<=h?i:t()};if(c&&(a/=2,h/=2),a<h)for(;;){if(0===(s=this.items().eq(++l)).length){if(!this.circular)break;if(s=this.items().eq(0),i.get(0)===s.get(0))break;if((r=this._visible.index(s)>=0)&&s.after(s.clone(!0).attr("data-jcarousel-clone",!0)),this.list().append(s),!r){var d={};d[this.lt]=this.dimension(s),this.moveBy(d)}this._items=null}if(0===(n=this.dimension(s)))break;if(a+=n,f.last=s,f.visible=f.visible.add(s),a-e(s.css("margin-"+u))<=h&&(f.fullyvisible=f.fullyvisible.add(s)),a>=h)break}if(!this.circular&&!c&&a<h)for(l=o;!(--l<0||0===(s=this.items().eq(l)).length||0===(n=this.dimension(s))||(a+=n,f.first=s,f.visible=f.visible.add(s),a-e(s.css("margin-"+u))<=h&&(f.fullyvisible=f.fullyvisible.add(s)),a>=h)););return this._update(f),this.tail=0,c||"circular"===this.options("wrap")||"custom"===this.options("wrap")||this.index(f.last)!==this.items().length-1||(a-=e(f.last.css("margin-"+u)))>h&&(this.tail=a-h),this},_position:function(t){var i=this._first,s=e(i.position()[this.lt]),r=this.options("center"),n=r?this.clipping()/2-this.dimension(i)/2:0;return this.rtl&&!this.vertical?(this.relative?s-=e(this.list().width())-this.dimension(i):s-=this.clipping()-this.dimension(i),s+=n):s-=n,!r&&(this.index(t)>this.index(i)||this.inTail)&&this.tail?(s=this.rtl&&!this.vertical?s-this.tail:s+this.tail,this.inTail=!0):this.inTail=!1,-s},_update:function(i){var s,e=this,r={target:this._target,first:this._first,last:this._last,visible:this._visible,fullyvisible:this._fullyvisible},n=this.index(i.first||r.first)<this.index(r.first),o=function(s){var o=[],l=[];i[s].each(function(){r[s].index(this)<0&&o.push(this)}),r[s].each(function(){i[s].index(this)<0&&l.push(this)}),n?o=o.reverse():l=l.reverse(),e._trigger(s+"in",t(o)),e._trigger(s+"out",t(l)),e["_"+s]=i[s]};for(s in i)o(s);return this}})}(jQuery,window),function(t){"use strict";t.jcarousel.fn.scrollIntoView=function(i,s,e){var r,n=t.jCarousel.parseTarget(i),o=this.index(this._fullyvisible.first()),l=this.index(this._fullyvisible.last());if((r=n.relative?n.target<0?Math.max(0,o+n.target):l+n.target:"object"!=typeof n.target?n.target:this.index(n.target))<o)return this.scroll(r,s,e);if(r>=o&&r<=l)return t.isFunction(e)&&e.call(this,!1),this;for(var a,h=this.items(),u=this.clipping(),c=this.vertical?"bottom":this.rtl?"left":"right",f=0;0!==(a=h.eq(r)).length;){if((f+=this.dimension(a))>=u){f-(parseFloat(a.css("margin-"+c))||0)!==u&&r++;break}if(r<=0)break;r--}return this.scroll(r,s,e)}}(jQuery),function(t){"use strict";t.jCarousel.plugin("jcarouselControl",{_options:{target:"+=1",event:"click",method:"scroll"},_active:null,_init:function(){this.onDestroy=t.proxy(function(){this._destroy(),this.carousel().one("jcarousel:createend",t.proxy(this._create,this))},this),this.onReload=t.proxy(this._reload,this),this.onEvent=t.proxy(function(i){i.preventDefault();var s=this.options("method");t.isFunction(s)?s.call(this):this.carousel().jcarousel(this.options("method"),this.options("target"))},this)},_create:function(){this.carousel().one("jcarousel:destroy",this.onDestroy).on("jcarousel:reloadend jcarousel:scrollend",this.onReload),this._element.on(this.options("event")+".jcarouselcontrol",this.onEvent),this._reload()},_destroy:function(){this._element.off(".jcarouselcontrol",this.onEvent),this.carousel().off("jcarousel:destroy",this.onDestroy).off("jcarousel:reloadend jcarousel:scrollend",this.onReload)},_reload:function(){var i,s=t.jCarousel.parseTarget(this.options("target")),e=this.carousel();if(s.relative)i=e.jcarousel(s.target>0?"hasNext":"hasPrev");else{var r="object"!=typeof s.target?e.jcarousel("items").eq(s.target):s.target;i=e.jcarousel("target").index(r)>=0}return this._active!==i&&(this._trigger(i?"active":"inactive"),this._active=i),this}})}(jQuery),function(t){"use strict";t.jCarousel.plugin("jcarouselPagination",{_options:{perPage:null,item:function(t){return'<a href="#'+t+'">'+t+"</a>"},event:"click",method:"scroll"},_carouselItems:null,_pages:{},_items:{},_currentPage:null,_init:function(){this.onDestroy=t.proxy(function(){this._destroy(),this.carousel().one("jcarousel:createend",t.proxy(this._create,this))},this),this.onReload=t.proxy(this._reload,this),this.onScroll=t.proxy(this._update,this)},_create:function(){this.carousel().one("jcarousel:destroy",this.onDestroy).on("jcarousel:reloadend",this.onReload).on("jcarousel:scrollend",this.onScroll),this._reload()},_destroy:function(){this._clear(),this.carousel().off("jcarousel:destroy",this.onDestroy).off("jcarousel:reloadend",this.onReload).off("jcarousel:scrollend",this.onScroll),this._carouselItems=null},_reload:function(){var i=this.options("perPage");if(this._pages={},this._items={},t.isFunction(i)&&(i=i.call(this)),null==i)this._pages=this._calculatePages();else for(var s,e=parseInt(i,10)||0,r=this._getCarouselItems(),n=1,o=0;0!==(s=r.eq(o++)).length;)this._pages[n]?this._pages[n]=this._pages[n].add(s):this._pages[n]=s,o%e==0&&n++;this._clear();var l=this,a=this.carousel().data("jcarousel"),h=this._element,u=this.options("item"),c=this._getCarouselItems().length;t.each(this._pages,function(i,s){var e=l._items[i]=t(u.call(l,i,s));e.on(l.options("event")+".jcarouselpagination",t.proxy(function(){var t=s.eq(0);if(a.circular){var e=a.index(a.target()),r=a.index(t);parseFloat(i)>parseFloat(l._currentPage)?r<e&&(t="+="+(c-e+r)):r>e&&(t="-="+(e+(c-r)))}a[this.options("method")](t)},l)),h.append(e)}),this._update()},_update:function(){var i,s=this.carousel().jcarousel("target");t.each(this._pages,function(t,e){if(e.each(function(){if(s.is(this))return i=t,!1}),i)return!1}),this._currentPage!==i&&(this._trigger("inactive",this._items[this._currentPage]),this._trigger("active",this._items[i])),this._currentPage=i},items:function(){return this._items},reloadCarouselItems:function(){return this._carouselItems=null,this},_clear:function(){this._element.empty(),this._currentPage=null},_calculatePages:function(){for(var t,i,s=this.carousel().data("jcarousel"),e=this._getCarouselItems(),r=s.clipping(),n=0,o=0,l=1,a={};0!==(t=e.eq(o++)).length;)n+(i=s.dimension(t))>r&&(l++,n=0),n+=i,a[l]?a[l]=a[l].add(t):a[l]=t;return a},_getCarouselItems:function(){return this._carouselItems||(this._carouselItems=this.carousel().jcarousel("items")),this._carouselItems}})}(jQuery),function(t,i){"use strict";var s,e;t.each({hidden:"visibilitychange",mozHidden:"mozvisibilitychange",msHidden:"msvisibilitychange",webkitHidden:"webkitvisibilitychange"},function(t,r){if(void 0!==i[t])return s=t,e=r,!1}),t.jCarousel.plugin("jcarouselAutoscroll",{_options:{target:"+=1",interval:3e3,autostart:!0,method:"scroll"},_timer:null,_started:!1,_init:function(){this.onDestroy=t.proxy(function(){this._destroy(),this.carousel().one("jcarousel:createend",t.proxy(this._create,this))},this),this.onAnimateEnd=t.proxy(this._start,this),this.onVisibilityChange=t.proxy(function(){i[s]?this._stop():this._start()},this)},_create:function(){this.carousel().one("jcarousel:destroy",this.onDestroy),t(i).on(e,this.onVisibilityChange),this.options("autostart")&&this.start()},_destroy:function(){this._stop(),this.carousel().off("jcarousel:destroy",this.onDestroy),t(i).off(e,this.onVisibilityChange)},_start:function(){if(this._stop(),this._started)return this.carousel().one("jcarousel:animateend",this.onAnimateEnd),this._timer=setTimeout(t.proxy(function(){this.carousel().jcarousel(this.options("method"),this.options("target"))},this),this.options("interval")),this},_stop:function(){return this._timer&&(this._timer=clearTimeout(this._timer)),this.carousel().off("jcarousel:animateend",this.onAnimateEnd),this},start:function(){return this._started=!0,this._start(),this},stop:function(){return this._started=!1,this._stop(),this}})}(jQuery,document);;

// ***************************
// js.compressed/jquery/jquery.jcarousel-swipe.min.js
// ***************************
/*! jCarouselSwipe - v0.3.4 - 2016-02-18
* Copyright (c) 2015 Evgeniy Pelmenev; Licensed MIT */
!function(t){"use strict";t.jCarousel.plugin("jcarouselSwipe",{_options:{perSwipe:1,draggable:!0,method:"scroll"},_init:function(){var t=this;this.carousel().on("jcarousel:reloadend",function(){t._reload()})},_create:function(){this._instance=this.carousel().data("jcarousel"),this._instance._element.css("touch-action",this._instance.vertical?"pan-x":"pan-y"),this._carouselOffset=this.carousel().offset()[this._instance.lt]+parseInt(this.carousel().css(this._instance.vertical?"border-top-width":"border-left-width"))+parseInt(this.carousel().css(this._instance.vertical?"padding-top":"padding-left")),this._slidesCount=this._instance.items().length,this.carousel().find("img, a").attr("draggable",!1).css("user-select","none").on("dragstart",function(t){t.preventDefault()}),this._destroy(),this._instance.items().length>this._instance.fullyvisible().length&&this._initGestures()},_initGestures:function(){function e(e){var i,o,p;e=e.originalEvent||e||window.event,l=n(e);var f=Math.abs(r[u]-l[u]),d=Math.abs(r[_]-l[_]);h&&e.preventDefault(),d>10&&d>f&&!h?t(document).off("touchmove.jcarouselSwipe mousemove.jcarouselSwipe"):(!c._instance.animating&&f>10||h)&&(i=r[u]-l[u],h||(h=!0,c._addClones(),c._currentLT=c._getListPosition(),p=c._instance.options("items"),a=(t.isFunction(p)?p.call(c._instance):c._instance.list().find(p)).last(),s=c._instance.rtl&&!c._instance.vertical?c._instance.dimension(c._instance.list())-a.position()[c._instance.lt]-c._instance.clipping():-1*(a.position()[c._instance.lt]+c._instance.dimension(a)-c._instance.clipping())),o="circular"===c._instance._options.wrap?c._currentLT-i:c._instance.rtl&&!c._instance.vertical?Math.max(0,Math.min(c._currentLT-i,s)):Math.min(0,Math.max(c._currentLT-i,s)),c._setListPosition(o+"px"))}function i(e){e=e.originalEvent||e||window.event,l=n(e);var i=Math.abs(r[u]-l[u]),s=Math.abs(r[_]-l[_]);if(h||!c._options.draggable&&i>10&&i>s){var a=c._getNewTarget(r[u]-l[u]>0);a="circular"===c._instance._options.wrap?a.relative:a.static,o===e.target&&t(e.target).on("click.disable",function(e){e.stopImmediatePropagation(),e.stopPropagation(),e.preventDefault(),t(e.target).off("click.disable")}),"circular"===c._instance._options.wrap&&(c._removeClones(),c._instance._items=null),h=!1,c._instance[c._options.method](a,function(){"circular"!==c._instance._options.wrap&&(c._removeClones(),c._instance._items=null)})}t(document).off("touchmove.jcarouselSwipe mousemove.jcarouselSwipe"),t(document).off("touchend.jcarouselSwipe touchcancel.jcarouselSwipe mouseup.jcarouselSwipe")}function n(t){return void 0!==t.touches&&t.touches.length>0?{x:t.touches[0].pageX,y:t.touches[0].pageY}:void 0!==t.changedTouches&&t.changedTouches.length>0?{x:t.changedTouches[0].pageX,y:t.changedTouches[0].pageY}:void 0!==t.pageX?{x:t.pageX,y:t.pageY}:{x:t.clientX,y:t.clientY}}var s,a,o,c=this,r={},l={},h=!1,u=this._instance.vertical?"y":"x",_=this._instance.vertical?"x":"y";this._element.on("touchstart.jcarouselSwipe mousedown.jcarouselSwipe",function(s){s=s.originalEvent||s||window.event,r=n(s),o=s.target||s.srcElement,c._options.draggable&&!c._instance.animating&&t(document).on("touchmove.jcarouselSwipe mousemove.jcarouselSwipe",e),t(document).on("touchend.jcarouselSwipe touchcancel.jcarouselSwipe mouseup.jcarouselSwipe",i)})},_getNewTarget:function(t){var e,i=this._instance.target(),n=this._instance.index(i),s=0,a=this._instance.rtl&&!this._instance.vertical?!t:t;if(this._options.draggable)for(;;){if(e=this._instance.rtl&&!this._instance.vertical?i.offset()[this._instance.lt]+this._instance.dimension(i)-(this._carouselOffset+this._instance.clipping()):i.offset()[this._instance.lt]-this._carouselOffset,!i.length||t&&e>=0||!t&&e<=0)break;if(a){if(!(i=i.next()).length)break;n+=1}else{if(!(i=i.prev()).length)break;n-=1}s++}else n=a?n+1:n-1,s=1;return a?n+=Math.abs(s-this._options.perSwipe*Math.ceil(s/this._options.perSwipe)):n-=Math.abs(s-this._options.perSwipe*Math.ceil(s/this._options.perSwipe)),"first"===this._instance._options.wrap?n=Math.min(this._slidesCount-1,n):"last"===this._instance._options.wrap?n=Math.max(0,n):this._instance._options.wrap||(n=Math.max(0,Math.min(this._slidesCount-1,n))),n%=this._slidesCount,s=this._options.perSwipe*Math.ceil(s/this._options.perSwipe),{static:n,relative:(a?"+":"-")+"="+s}},_getListPosition:function(){var t=this._instance.list(),e=t.position();return this._instance.rtl&&(e.left=t.width()+e.left-this._carousel.width()),e[this._instance.lt]},_setListPosition:function(t){var e=this._instance.options("transitions"),i=!!e.transforms,n=!!e.transforms3d,s={},a="left"===this._instance.lt;t=t||0,n?s.transform="translate3d("+(a?t:0)+","+(a?0:t)+",0)":i?s.transform="translate("+(a?t:0)+","+(a?0:t)+")":s[this._instance.lt]=t,this._instance.list().css(s)},_addClones:function(){var e,i,n,s=this,a=this._instance,o=a.items(),c=a.first(),r=a.last(),l=a.dimension(t(window)),h=[],u=[],_=s._getListPosition(),p={};if(!a._options.wrap)return!1;if("last"!==a._options.wrap){for(i=0,n=0,e=c;i<l;)0===(e=e.prev()).length?(n=--n<-o.length?-1:n,i+=a.dimension(o.eq(n)),h.push(o.eq(n).clone().attr("data-jcarousel-clone",!0))):i+=a.dimension(e);_=(a.rtl?Math.max(_,i):Math.min(_,-i))+"px",a._items.first().before(h.reverse()),p[a.lt]=_,a.move(p)}if("first"!==a._options.wrap){for(i=0,n=-1,e=r;i<l;)0===(e=e.next()).length?(n=++n>o.length-1?0:n,i+=a.dimension(o.eq(n)),u.push(o.eq(n).clone().attr("data-jcarousel-clone",!0))):i+=a.dimension(e);a._items.last().after(u)}},_removeClones:function(){var t,e=this._instance.first().position()[this._instance.lt],i={};this._instance.list().find("[data-jcarousel-clone]").remove(),(t=e-this._instance.first().position()[this._instance.lt])&&(i[this._instance.lt]=this._getListPosition()+t+"px",this._instance.move(i))},_destroy:function(){this._element.off("touchstart.jcarouselSwipe mousedown.jcarouselSwipe"),t(document).off("touchmove.jcarouselSwipe mousemove.jcarouselSwipe touchend.jcarouselSwipe touchcancel.jcarouselSwipe mouseup.jcarouselSwipe")},_reload:function(){this._create()}})}(jQuery);
;

// ***************************
// js.compressed/jquery/history.min.js
// ***************************
/*
 2010-2011 Benjamin Arthur Lupton <contact@balupton.com>
 @license New BSD License <http://creativecommons.org/licenses/BSD/>

 ============ NOTE: This version contains patch from https://github.com/christanto/history.js/commit/b78af84fc2b6b5da573e5ee0bd72f4213e36bb18 ============
 Public Domain
 @author Benjamin Arthur Lupton <contact@balupton.com>
 @author James Padolsey <https://gist.github.com/527683>
 Public Domain
 @author Benjamin Arthur Lupton <contact@balupton.com>
*/
(function(f,n){var l=f.console||n,g=f.document,m=f.navigator,p=f.amplify||!1,t=f.setTimeout,u=f.clearTimeout,v=f.setInterval,x=f.clearInterval,k=f.JSON,a=f.History=f.History||{},q=f.history;k.stringify=k.stringify||k.encode;k.parse=k.parse||k.decode;if("undefined"!==typeof a.init)throw Error("History.js Core has already been loaded...");a.init=function(){if("undefined"===typeof a.Adapter)return!1;"undefined"!==typeof a.initCore&&a.initCore();"undefined"!==typeof a.initHtml4&&a.initHtml4();return!0};
a.initCore=function(){if("undefined"!==typeof a.initCore.initialized)return!1;a.initCore.initialized=!0;a.options=a.options||{};a.options.hashChangeInterval=a.options.hashChangeInterval||100;a.options.safariPollInterval=a.options.safariPollInterval||500;a.options.doubleCheckInterval=a.options.doubleCheckInterval||500;a.options.storeInterval=a.options.storeInterval||1E3;a.options.busyDelay=a.options.busyDelay||250;a.options.debug=a.options.debug||!1;a.options.initialTitle=a.options.initialTitle||g.title;
a.options.transformHash=a.options.transformHash||!0;a.intervalList=[];a.clearAllIntervals=function(){var b,c=a.intervalList;if("undefined"!==typeof c&&null!==c){for(b=0;b<c.length;b++)x(c[b]);a.intervalList=null}};a.Adapter.bind(f,"beforeunload",a.clearAllIntervals);a.Adapter.bind(f,"unload",a.clearAllIntervals);a.debug=function(){a.options.debug&&a.log.apply(a,arguments)};a.log=function(){var b=!("undefined"===typeof l||"undefined"===typeof l.log||"undefined"===typeof l.log.apply),c=g.getElementById("log"),
d;if(b){var e=Array.prototype.slice.call(arguments);var h=e.shift();"undefined"!==typeof l.debug?l.debug.apply(l,[h,e]):l.log.apply(l,[h,e])}else h="\n"+arguments[0]+"\n";e=1;for(d=arguments.length;e<d;++e){var r=arguments[e];if("object"===typeof r&&"undefined"!==typeof k)try{r=k.stringify(r)}catch(y){}h+="\n"+r+"\n"}c?(c.value+=h+"\n-----\n",c.scrollTop=c.scrollHeight-c.clientHeight):b||alert(h);return!0};a.getInternetExplorerMajorVersion=function(){var b=a.getInternetExplorerMajorVersion;if("undefined"!==
typeof a.getInternetExplorerMajorVersion.cached)var c=a.getInternetExplorerMajorVersion.cached;else{c=3;for(var d=g.createElement("div"),e=d.getElementsByTagName("i");(d.innerHTML="\x3c!--[if gt IE "+ ++c+"]><i></i><![endif]--\x3e")&&e[0];);c=4<c?c:!1}return b.cached=c};a.isInternetExplorer=function(){return a.isInternetExplorer.cached="undefined"!==typeof a.isInternetExplorer.cached?a.isInternetExplorer.cached:!!a.getInternetExplorerMajorVersion()};a.emulated={pushState:!(f.history&&f.history.pushState&&
f.history.replaceState&&!/ Mobile\/([1-7][a-z]|(8([abcde]|f(1[0-8]))))/i.test(m.userAgent)&&!/AppleWebKit\/5([0-2]|3[0-2])/i.test(m.userAgent)),hashChange:!(("onhashchange"in f||"onhashchange"in g)&&!(a.isInternetExplorer()&&8>a.getInternetExplorerMajorVersion()))};a.enabled=!a.emulated.pushState;a.bugs={setHash:!(a.emulated.pushState||"Apple Computer, Inc."!==m.vendor||!/AppleWebKit\/5([0-2]|3[0-3])/.test(m.userAgent)),safariPoll:!(a.emulated.pushState||"Apple Computer, Inc."!==m.vendor||!/AppleWebKit\/5([0-2]|3[0-3])/.test(m.userAgent)),
ieDoubleCheck:!!(a.isInternetExplorer()&&8>a.getInternetExplorerMajorVersion()),hashEscape:!!(a.isInternetExplorer()&&7>a.getInternetExplorerMajorVersion())};a.isEmptyObject=function(b){for(var c in b)return!1;return!0};a.cloneObject=function(b){b?(b=k.stringify(b),b=k.parse(b)):b={};return b};a.getRootUrl=function(){var b=g.location.protocol+"//"+(g.location.hostname||g.location.host);g.location.port&&(b+=":"+g.location.port);return b+"/"};a.getBaseHref=function(){var b=g.getElementsByTagName("base"),
c="";1===b.length&&(b=b[0],c=b.href.replace(/[^\/]+$/,""));(c=c.replace(/\/+$/,""))&&(c+="/");return c};a.getBaseUrl=function(){return a.getBaseHref()||a.getBasePageUrl()||a.getRootUrl()};a.getPageUrl=function(){return((a.getState(!1,!1)||{}).url||g.location.href).replace(/\/+$/,"").replace(/[^\/]+$/,function(b,c,d){return/\./.test(b)?b:b+"/"})};a.getBasePageUrl=function(){return g.location.href.replace(/[#\?].*/,"").replace(/[^\/]+$/,function(b,c,d){return/[^\/]$/.test(b)?"":b}).replace(/\/+$/,"")+
"/"};a.getFullUrl=function(b,c){var d=b,e=b.substring(0,1);c="undefined"===typeof c?!0:c;/[a-z]+:\/\//.test(b)||(d="/"===e?a.getRootUrl()+b.replace(/^\/+/,""):"#"===e?a.getPageUrl().replace(/#.*/,"")+b:"?"===e?a.getPageUrl().replace(/[\?#].*/,"")+b:c?a.getBaseUrl()+b.replace(/^(\.\/)+/,""):a.getBasePageUrl()+b.replace(/^(\.\/)+/,""));return d.replace(/#$/,"")};a.getShortUrl=function(b){var c=a.getBaseUrl(),d=a.getRootUrl();a.emulated.pushState&&(b=b.replace(c,""));b=b.replace(d,"/");a.isTraditionalAnchor(b)&&
(b="./"+b);return b=b.replace(/^(\.\/)+/g,"./").replace(/#$/,"")};a.store=p?p.store("History.store")||{}:{};a.store.idToState=a.store.idToState||{};a.store.urlToId=a.store.urlToId||{};a.store.stateToId=a.store.stateToId||{};a.idToState=a.idToState||{};a.stateToId=a.stateToId||{};a.urlToId=a.urlToId||{};a.storedStates=a.storedStates||[];a.savedStates=a.savedStates||[];a.getState=function(b,c){"undefined"===typeof b&&(b=!0);"undefined"===typeof c&&(c=!0);var d=a.getLastSavedState();!d&&c&&(d=a.createStateObject());
b&&(d=a.cloneObject(d),d.url=d.cleanUrl||d.url);return d};a.getIdByState=function(b){var c=a.extractId(b.url);if(!c){var d=a.getStateString(b);if("undefined"!==typeof a.stateToId[d])c=a.stateToId[d];else if("undefined"!==typeof a.store.stateToId[d])c=a.store.stateToId[d];else{for(;c=String(Math.floor(1E3*Math.random())),"undefined"!==typeof a.idToState[c]||"undefined"!==typeof a.store.idToState[c];);a.stateToId[d]=c;a.idToState[c]=b}}return c};a.normalizeState=function(b){b&&"object"===typeof b||
(b={});if("undefined"!==typeof b.normalized)return b;b.data&&"object"===typeof b.data||(b.data={});var c={normalized:!0};c.title=b.title||"";c.url=a.getFullUrl(a.unescapeString(b.url||g.location.href));c.hash=a.getShortUrl(c.url);c.data=a.cloneObject(b.data);c.id=a.getIdByState(c);c.cleanUrl=c.url.replace(/\??&_suid.*/,"");c.url=c.cleanUrl;b=!a.isEmptyObject(c.data);if(c.title||b)c.hash=a.getShortUrl(c.url).replace(/\??&_suid.*/,""),/\?/.test(c.hash)||(c.hash+="?"),c.hash+="&_suid="+c.id;c.hashedUrl=
a.getFullUrl(c.hash);(a.emulated.pushState||a.bugs.safariPoll)&&a.hasUrlDuplicate(c)&&(c.url=c.hashedUrl);return c};a.createStateObject=function(b,c,d){b={data:b,title:c,url:d};return b=a.normalizeState(b)};a.getStateById=function(b){b=String(b);return a.idToState[b]||a.store.idToState[b]||n};a.getStateString=function(b){b={data:a.normalizeState(b).data,title:b.title,url:b.url};return k.stringify(b)};a.getStateId=function(b){return a.normalizeState(b).id};a.getHashByState=function(b){return a.normalizeState(b).hash};
a.extractId=function(b){return((b=/(.*)&_suid=([0-9]+)$/.exec(b))?String(b[2]||""):"")||!1};a.isTraditionalAnchor=function(b){return!/[\/\?\.]/.test(b)};a.extractState=function(b,c){var d=null;c=c||!1;var e=a.extractId(b);e&&(d=a.getStateById(e));if(!d){var h=a.getFullUrl(b);(e=a.getIdByUrl(h)||!1)&&(d=a.getStateById(e));d||!c||a.isTraditionalAnchor(b)||(d=a.createStateObject(null,null,h))}return d};a.getIdByUrl=function(b){return a.urlToId[b]||a.store.urlToId[b]||n};a.getLastSavedState=function(){return a.savedStates[a.savedStates.length-
1]||n};a.getLastStoredState=function(){return a.storedStates[a.storedStates.length-1]||n};a.hasUrlDuplicate=function(b){var c=a.extractState(b.url);return c&&c.id!==b.id};a.storeState=function(b){a.urlToId[b.url]=b.id;a.storedStates.push(a.cloneObject(b));return b};a.isLastSavedState=function(b){var c=!1;a.savedStates.length&&(b=b.id,c=a.getLastSavedState().id,c=b===c);return c};a.saveState=function(b){if(a.isLastSavedState(b))return!1;a.savedStates.push(a.cloneObject(b));return!0};a.getStateByIndex=
function(b){return"undefined"===typeof b?a.savedStates[a.savedStates.length-1]:0>b?a.savedStates[a.savedStates.length+b]:a.savedStates[b]};a.getHash=function(){return a.unescapeHash(g.location.hash)};a.unescapeString=function(b){for(var c;;){c=f.unescape(b);if(c===b)break;b=c}return b};a.unescapeHash=function(b){b=a.normalizeHash(b);return b=a.unescapeString(b)};a.normalizeHash=function(b){return b.replace(/[^#]*#/,"").replace(/#.*/,"")};a.setHash=function(b,c){if(!1!==c&&a.busy())return a.pushQueue({scope:a,
callback:a.setHash,args:arguments,queue:c}),!1;var d=a.escapeHash(b);a.busy(!0);var e=a.extractState(b,!0);e&&!a.emulated.pushState?a.pushState(e.data,e.title,e.url,!1):g.location.hash!==d&&(a.bugs.setHash?(e=a.getPageUrl(),a.pushState(null,null,e+"#"+d,!1)):g.location.hash=d);return a};a.escapeHash=function(b){b=a.normalizeHash(b);b=f.escape(b);a.bugs.hashEscape||(b=b.replace(/%21/g,"!").replace(/%26/g,"&").replace(/%3D/g,"=").replace(/%3F/g,"?"));return b};a.getHashByUrl=function(b){b=String(b).replace(/([^#]*)#?([^#]*)#?(.*)/,
"$2");return b=a.unescapeHash(b)};a.setTitle=function(b){var c=b.title;if(!c){var d=a.getStateByIndex(0);d&&d.url===b.url&&(c=d.title||a.options.initialTitle)}try{g.getElementsByTagName("title")[0].innerHTML=c.replace("<","&lt;").replace(">","&gt;").replace(" & "," &amp; ")}catch(e){}g.title=c;return a};a.queues=[];a.busy=function(b){"undefined"!==typeof b?a.busy.flag=b:"undefined"===typeof a.busy.flag&&(a.busy.flag=!1);if(!a.busy.flag){u(a.busy.timeout);var c=function(){if(!a.busy.flag)for(var d=
a.queues.length-1;0<=d;--d){var e=a.queues[d];0!==e.length&&(e=e.shift(),a.fireQueueItem(e),a.busy.timeout=t(c,a.options.busyDelay))}};a.busy.timeout=t(c,a.options.busyDelay)}return a.busy.flag};a.fireQueueItem=function(b){return b.callback.apply(b.scope||a,b.args||[])};a.pushQueue=function(b){a.queues[b.queue||0]=a.queues[b.queue||0]||[];a.queues[b.queue||0].push(b);return a};a.queue=function(b,c){"function"===typeof b&&(b={callback:b});"undefined"!==typeof c&&(b.queue=c);a.busy()?a.pushQueue(b):
a.fireQueueItem(b);return a};a.clearQueue=function(){a.busy.flag=!1;a.queues=[];return a};a.stateChanged=!1;a.doubleChecker=!1;a.doubleCheckComplete=function(){a.stateChanged=!0;a.doubleCheckClear();return a};a.doubleCheckClear=function(){a.doubleChecker&&(u(a.doubleChecker),a.doubleChecker=!1);return a};a.doubleCheck=function(b){a.stateChanged=!1;a.doubleCheckClear();a.bugs.ieDoubleCheck&&(a.doubleChecker=t(function(){a.doubleCheckClear();a.stateChanged||b();return!0},a.options.doubleCheckInterval));
return a};a.safariStatePoll=function(){var b=a.extractState(g.location.href);if(!a.isLastSavedState(b))return b||a.createStateObject(),a.Adapter.trigger(f,"popstate"),a};a.back=function(b){if(!1!==b&&a.busy())return a.pushQueue({scope:a,callback:a.back,args:arguments,queue:b}),!1;a.busy(!0);a.doubleCheck(function(){a.back(!1)});q.go(-1);return!0};a.forward=function(b){if(!1!==b&&a.busy())return a.pushQueue({scope:a,callback:a.forward,args:arguments,queue:b}),!1;a.busy(!0);a.doubleCheck(function(){a.forward(!1)});
q.go(1);return!0};a.go=function(b,c){var d;if(0<b)for(d=1;d<=b;++d)a.forward(c);else if(0>b)for(d=-1;d>=b;--d)a.back(c);else throw Error("History.go: History.go requires a positive or negative integer passed.");return a};a.saveState(a.storeState(a.extractState(g.location.href,!0)));p&&(a.onUnload=function(){var b=p.store("History.store")||{},c;b.idToState=b.idToState||{};b.urlToId=b.urlToId||{};b.stateToId=b.stateToId||{};for(c in a.idToState)a.idToState.hasOwnProperty(c)&&(b.idToState[c]=a.idToState[c]);
for(c in a.urlToId)a.urlToId.hasOwnProperty(c)&&(b.urlToId[c]=a.urlToId[c]);for(c in a.stateToId)a.stateToId.hasOwnProperty(c)&&(b.stateToId[c]=a.stateToId[c]);a.store=b;p.store("History.store",b)},a.intervalList.push(v(a.onUnload,a.options.storeInterval)),a.Adapter.bind(f,"beforeunload",a.onUnload),a.Adapter.bind(f,"unload",a.onUnload));if(a.emulated.pushState){var w=function(){};a.pushState=a.pushState||w;a.replaceState=a.replaceState||w}else if(a.onPopState=function(b){a.doubleCheckComplete();
var c=a.getHash();if(c)return b=a.extractState(c||g.location.href,!0),a.options.transformHash&&b?a.replaceState(b.data,b.title,b.url,!1):(a.Adapter.trigger(f,"anchorchange"),a.busy(!1)),a.expectedStateId=!1;b=b||{};"undefined"===typeof b.state&&("undefined"!==typeof b.originalEvent&&"undefined"!==typeof b.originalEvent.state?b.state=b.originalEvent.state||!1:"undefined"!==typeof b.event&&"undefined"!==typeof b.event.state&&(b.state=b.event.state||!1));b.state=b.state||!1;(b=b.state?a.getStateById(b.state):
a.expectedStateId?a.getStateById(a.expectedStateId):a.extractState(g.location.href))||(b=a.createStateObject(null,null,g.location.href));a.expectedStateId=!1;if(a.isLastSavedState(b))return a.busy(!1),!1;a.storeState(b);a.saveState(b);a.setTitle(b);a.Adapter.trigger(f,"statechange");a.busy(!1);return!0},a.Adapter.bind(f,"popstate",a.onPopState),a.pushState=function(b,c,d,e){if(a.getHashByUrl(d)&&a.emulated.pushState)throw Error("History.js does not support states with fragement-identifiers (hashes/anchors).");
if(!1!==e&&a.busy())return a.pushQueue({scope:a,callback:a.pushState,args:arguments,queue:e}),!1;a.busy(!0);var h=a.createStateObject(b,c,d);a.isLastSavedState(h)?a.busy(!1):(a.storeState(h),a.expectedStateId=h.id,q.pushState(h.id,h.title,h.url),a.Adapter.trigger(f,"popstate"));return!0},a.replaceState=function(b,c,d,e){if(a.getHashByUrl(d)&&a.emulated.pushState)throw Error("History.js does not support states with fragement-identifiers (hashes/anchors).");if(!1!==e&&a.busy())return a.pushQueue({scope:a,
callback:a.replaceState,args:arguments,queue:e}),!1;a.busy(!0);var h=a.createStateObject(b,c,d);a.isLastSavedState(h)?a.busy(!1):(a.storeState(h),a.expectedStateId=h.id,q.replaceState(h.id,h.title,h.url),a.Adapter.trigger(f,"popstate"));return!0},a.bugs.safariPoll&&a.intervalList.push(v(a.safariStatePoll,a.options.safariPollInterval)),"Apple Computer, Inc."===m.vendor||"Mozilla"===(m.appCodeName||""))if(a.Adapter.bind(f,"hashchange",function(){a.Adapter.trigger(f,"popstate")}),a.getHash())a.Adapter.onDomLoad(function(){a.Adapter.trigger(f,
"hashchange")})};a.init()})(window);
;

// ***************************
// js.compressed/jquery/history.adapter.jquery.min.js
// ***************************
/*
 2010-2011 Benjamin Arthur Lupton <contact@balupton.com>
 @license New BSD License <http://creativecommons.org/licenses/BSD/>
*/
(function(c,a){a=c.History=c.History||{};var d=c.jQuery;if("undefined"!==typeof a.Adapter)throw Error("History.js Adapter has already been loaded...");a.Adapter={bind:function(b,e,f){d(b).on(e,f)},trigger:function(b,e){d(b).trigger(e)},onDomLoad:function(b){d(b)}};"undefined"!==typeof a.init&&a.init()})(window);
;

// ***************************
// js.compressed/history.js
// ***************************
(function(h){vBulletin.ensureObj("history");var d=window.History,k=d&&!!d.enabled;d.options.transformHash=!1;vBulletin.history.instance=function(l){var g=!0,e=!!l&&k;this.isEnabled=function(){return e};this.setDefaultState=function(b,a,c){if(e){g=!1;var f=vBulletin.parseUrl(c);try{c=decodeURI(f.pathname)+decodeURIComponent(f.search)+decodeURIComponent(f.hash),d.replaceState(b,a,c),g=!0}catch(m){console.error("Unable to parse and decode URL "+c)}}};this.setStateChange=function(b,a){e&&d.Adapter.bind(window,
"statechange"+(a?"."+a:""),function(c){g&&b.apply(this,h.makeArray(arguments))})};this.pushState=function(b,a,c){if(e){g=!1;var f=vBulletin.parseUrl(c);try{c=decodeURI(f.pathname)+decodeURIComponent(f.search)+decodeURIComponent(f.hash),d.pushState(b,a,c),g=!0}catch(m){console.error("Unable to parse and decode URL "+c)}}};this.getState=function(){if(e)return d.getState()};this.log=function(){e&&d.log.call(window,arguments)};e&&(h(window).data("hashchange.history")||d.Adapter.bind(window,"hashchange.history",
function(b){var a=location.hash;g&&a&&((b=a.match(/#post(\d+)/))&&Number(b[1])+""===b[1]&&1<Number(b[1])&&0==h(a).length&&h(".conversation-content-widget").length?(a=vBulletin.parseUrl(location.href),location.replace([a.pathname,a.search,a.search?"&":"?","p=",b[1],b[0]].join(""))):(setTimeout(function(){history.back()},0),(b=vBulletin.scrollToAnchor(a))&&window.scrollTo(0,0)))}),h(window).data("hashchange.history",!0));return this};vBulletin.ready("history").resolve()})(jQuery);
;

// ***************************
// js.compressed/autocomplete.js
// ***************************
function vBulletin_Autocomplete(L,g){var e=$(L),M=g.apiClass||null,N=g.apiFunction||"getAutocomplete",O=g.delay||500,u=g.minLength||3,z=g.maxItems||!1,A=e.attr("name")||"autocompleteElements",P=g.containerClass||"entry-field",B=g.placeholderText,Q="undefined"!=typeof g.autoFocus?g.autoFocus:!1,R="undefined"!=typeof g.appendTo?g.appendTo:"body",C=g.delimiter||",",k=[],q=e.parent(".autocomplete-container"),h=q.find(".autocompleteHelper"),v=!1,w=!1,r=e.siblings(".autocomplete-box"),D=g.beforeAdd||!1,
E=g.afterAdd||!1,F=g.beforeDelete||!1,G=g.afterDelete||!1,H=this,t=g.editorContext||null,I=function(a,f,d){if(""==a||"function"==typeof D&&!D.call(this,a,f))return!1;var b=!0;$(k).each(function(n,p){p.label==a&&(b=!1)});if(!b||z&&k.length>=z)return!1;var c=$("<div />").addClass("element-x b-link").prop("title","x").html('<span class="b-icon-fa b-icon-fa--16 fa-solid fa-circle-xmark" aria-hidden="true"></span>'),l=$("<div />").addClass("element-text").text(a);$("<div />").addClass("autocomplete").append(l).append(c).appendTo(r);
k.push({label:a,value:f});x();"function"==typeof E&&E.call(this,a,f,d);r.show();return!0},y=function(a){var f=a.length,d;for(d=0;d<f;++d)I(a[d])},J=function(){r.html("");h.val("");k=[];x()},x=function(){var a=[];$(k).each(function(f,d){a.push(d.label)});e.val(a.join(C))},K=function(a,f,d){if(t)switch(t.type){case "tags":t.context.addTag(a)}else H.addElement(a,a),h.val("");if("undefined"!==typeof f&&"undefined"!==typeof d)return d.preventDefault(),!1};(function(){0==q.length&&(e.wrap('<div class="autocomplete-container b-form-input__input" />'),
q=e.parent(".autocomplete-container"),q.addClass(P).on("mousedown",function(b){var c=this;setTimeout(function(){var l=$(".autocompleteHelper:visible",c);0<l.length&&l[0].focus()},10);return!1}));0==r.length&&(r=$("<div />").addClass("autocomplete-box").insertBefore(e));0==h.length&&(h=$('<input type="text" name="autocompleteHelper" />').addClass("autocompleteHelper b-form-input__input b-form-input__input--hide-clear-button").attr("placeholder",function(){return B?B:null}).attr("maxlength",function(){return e.attr("maxlength")?
e.attr("maxlength"):null}).insertAfter(r));h.attr("tabindex",e.attr("tabindex")||0);h.off("keydown").on("keydown",function(b){if(13==b.which){var c=$(b.target).val();c.length>=u&&K(c,!0,b)}});h.off("blur").on("blur",function(b){v=window.setTimeout(function(){if(!w){var c=h.val();c.length>=u&&K(c,!0,b)}v=w=!1},200)});h.off("focus").on("focus",function(b){w=v?!0:!1;return!1});var a="font-family font-size font-weight font-style color line-height height".split(" "),f;for(f=0;f<a.length;++f)q.css(a[f],
e.css(a[f]));a='<input type="hidden" name="'+A+'"';e.attr("id")&&(a+=' id="'+e.attr("id")+'"');e.attr("class")&&(a+=' class="'+e.attr("class")+'"');if(e.attr("data-value"))var d=e.attr("data-value").split(C);e.replaceWith(a+" />");e=q.find('[name="'+A+'"]');h.autocomplete({classes:{"ui-autocomplete":"dialog-container"},autoFocus:Q,appendTo:R,delay:O,minLength:u,source:function(b,c){vBulletin.AJAX({call:"/ajax/api/"+M+"/"+N,data:{searchStr:b.term},success:function(l){if(l&&$.isArray(l.suggestions)){var n=
[];$.each(l.suggestions,function(p,m){p={label:m.title};t&&"tags"==t.type?p.value=pageData.userid:(p.value=m.value,"id"in m&&m.id&&(p.id=m.id),m.hasOwnProperty("htmllabel")&&(p.htmllabel=m.htmllabel));n.push(p)});c(n)}else vBulletin.error("error","error_getting_suggestions")},error_phrase:"error_getting_suggestions"})},select:function(b,c){H.addElement(c.item.label,c.item.value,c.item);h.val("");b.preventDefault()},focus:function(b,c){h.val(c.item.label);b.preventDefault()},open:function(b){b=$(b.target).autocomplete("instance").menu.element;
var c=parseInt($(".dialog-box").css("z-index"),10);b.css("z-index",c+1)}});if(a=h.data("ui-autocomplete"))a._renderItem=function(b,c){c=c.hasOwnProperty("htmllabel")?$("<div>").html(c.htmllabel):$("<div>").text(c.label);return $("<li>").append(c).appendTo(b)};r.on("click",".element-x",function(b){b=$(this).closest(".autocomplete");var c=b.find(".element-text").text().toLowerCase(),l=[],n=!1;$(k).each(function(p,m){m.label.toLowerCase()==c?n=m:l.push(m)});if("function"==typeof F&&!F.call(this,n.label,
n.data))return!1;k=l;b.remove();x();"function"==typeof G&&G.call(this,n.label,n.data)});q.off("click").on("click",function(b){$(b.target).hasClass("ui-autocomplete-input")||$(".ui-autocomplete-input",$(this)).trigger("focus");return!1});d&&y.call(this,d)}).call(this);this.addElement=function(a,f,d){return I.call(this,a,f,d)};this.addElements=function(a){y.call(this,a)};this.setElements=function(a){J();y(a)};this.getElements=function(){return k};this.getLabels=function(){var a=[];$(k).each(function(f,
d){a.push(d.label)});return a};this.getValues=function(){var a=[];$(k).each(function(f,d){a.push(d.value)});return a};this.getInputField=function(){return h};this.clearElements=function(){return J.call(this)};this.countElements=function(){return $(k).length};this.getMinLength=function(){return u};this.close=function(){h.val("");h.autocomplete("close")}};
;

// ***************************
// js.compressed/poll.js
// ***************************
vBulletin.precache("vote_failed vote_now vote_first vote_error_retrieving vote_lower votes_lower voters voter".split(" "),["maxpolloptions"]);
(function(c){function r(h,m){const n=h.find(".js-change-vote"),d=h.find(".js-poll-option");h=h.find(".js-vote-now");n.toggleClass("h-hide-imp",m);h.toggleClass("h-hide-imp",!m);d.attr("disabled",!m)}c(function(){function h(d,g,a){d=c("<span />").addClass(g).text(vBulletin.phrase.get(d));m(d,a)}function m(d,g){g.html(d);g.fadeIn("slow");c("body").on("click.voterpopup",function(a){0==c(a.target).closest(".voter-icon").length&&(g.hide(),c("body").off("click.voterpopup"))})}function n(d,g){var a=d.parent(),
b=g.options,e;for(e in b){var f=c(".pollresults-option-"+b[e].polloptionid);f.find(".title").html(JShtmlEncode(b[e].title));f.find(".bar-container .bar").css("width",b[e].percentage+"%");f.find(".percentage").html(b[e].display_percentage+"%");f.find(".js-votes span").html(b[e].votes);var k=1==b[e].votes?"vote_lower":"votes_lower";f.find(".js-votes label").html(vBulletin.phrase.get(k))}c(".pollresults .pollvote-count span",a).html(g.poll_votes);k=1==g.poll_votes?"voter":"voters";c(".pollresults .pollvote-count label",
a).html(vBulletin.phrase.get(k));d.hide();c("div.pollresults",a).removeClass("h-hide-imp");r(d,!1)}vBulletin.conversation.bindEditFormEventHandlers("poll");(function(d){var g=function(a){a.find(".js-remove-button").prop("disabled",2>=a.find("li").length)};c(".b-poll-fieldset__poll-answers").each(function(){g(c(this))});d.offon("click",".js-poll__view-results",function(a){a.preventDefault();a=c(this).attr("data-nodeid");var b=c(this).closest("form");c.post(vBulletin.getAjaxBaseurl()+"/poll/get",{nodeid:a},
function(e){n(b,e)},"json")});d.offon("click",".js-poll__back-to-poll",function(a){a.preventDefault();a=c(this).closest(".js-poll__parent");a.find("div.pollresults").addClass("h-hide-imp");a.find("form.poll").show()});d.offon("click",".b-poll-fieldset__add-more",function(a){a=c(this);var b=a.prev(".b-poll-fieldset__poll-answers"),e=b.find("li").first().clone(!0),f=e.find(".b-form-input__input");f.val("").attr("name","polloptions[new][]");e.appendTo(b);f.trigger("focus");b.find("li").length==vBulletin.options.get("maxpolloptions")&&
a.addClass("h-hide");g(b);return!1});d.offon("click",".b-poll-fieldset__poll-answers .js-remove-button",function(){var a=c(this),b=a.closest(".b-poll-fieldset__poll-answers");a.closest("li").remove();b.next(".b-poll-fieldset__add-more").removeClass("h-hide");g(b);return!1});d.offon("click",".js-change-vote",a=>r(c(a.currentTarget).closest("form"),!0));d.offon("submit.formpoll","form.poll",function(a){a.preventDefault();let b=c(this);a=b.find('[name="polloptionid"]:checked').val();let e=[];b.find('[name="polloptionids[]"]:checked').each(function(){e.push(c(this).val())});
c.post(vBulletin.normalizeAjaxUrl(b.attr("action")),{polloptionid:a,"polloptionids[]":e},function(f){if(0==f)vBulletin.warning("vote_now","vote_failed");else{n(b,f);var k=b.parent();f.canchangevotes||c("div.pollresults",k).find(".js-poll__back-to-poll").remove()}},"json")});d.offon("click",".pollresults-data .voter-icon",a=>{a=c(a.currentTarget);var b=a.find(".voters");if(b.is(":visible"))return!1;c(".pollresults-data .voter-icon .voters").hide();var e=a.attr("data-node-id"),f=a.attr("data-polloption-id"),
k=a.closest("form");vBulletin.AJAX({call:"/poll/get-voters",data:{nodeid:e,polloptionid:f},success:l=>{var {options:{[f]:p}={}}=l;if(p)if(n(k,l),l=p.votersinfo,c.isEmptyObject(l))h("vote_first","note",b);else{p=[];for(let q of Object.values(l))p.push('<a href="{0}" data-vbnamecard="{1}">{2}</a>'.format(q.profileurl,q.userid,q.displayname_safe));m(p.join(", "),b)}else h("vote_error_retrieving","error",b)},api_error:l=>h(l[0],"error",b),error:()=>h("vote_error_retrieving","error",b)})});d.offon("click",
".pollresults-data .voter-icon .voters",a=>{a.stopPropagation();return!0})})(c(document))})})(jQuery);
;

// ***************************
// js.compressed/vbSlideshow.js
// ***************************
vBulletin.precache(["gallery_slideshow","no_photos_found_or_post_deleted"],[]);
(function(d,B){function C(a,b,c,f){var e=a.find(".caption");e.html("").hide();b.links&&e.append(d("<div />").addClass("links ellipsis").html(b.links));b.title&&e.append(d("<div />").addClass("title ellipsis").html(b.title));b.caption&&e.append(d("<div />").addClass("title ellipsis").html(b.caption));b=b.links&&b.title?15:b.links||b.title?35:50;c=a.find(".slideshow-wrapper .jcarousel-item-"+c+" img");e.css({marginBottom:b+"px",width:"100%",textAlign:"center",marginLeft:"auto",marginRight:"auto"});
c.one("load",function(){var g=d(this).outerWidth();e.css("width",g+"px")});f?e.fadeIn("fast",function(){a.trigger("click")}):e.show()}function D(a){var b=vBulletin.isRtl();37==a.which?k.jcarousel("scroll",b?"+=1":"-=1"):39==a.which&&k.jcarousel("scroll",b?"-=1":"+=1");if(33<=a.which&&40>=a.which)return!1;27==a.which&&h.dialog("instance")&&h.dialog("close")}function E(a){0<(a.originalEvent.wheelDelta||-a.originalEvent.detail)?k.jcarousel("scroll","-=1"):k.jcarousel("scroll","+=1");return!1}function L(){var a=
d("body"),b=a.css("overflow")||"auto";a.css("overflow","hidden");var c=d(window).innerWidth(),f=window.innerHeight;c=parseInt(c-0,10);f=parseInt(f-0,10);h.css({borderRadius:0,borderWidth:0});a.css("overflow",b);h.dialog("instance")&&(h.dialog("option","width",c),h.dialog("option","height",f))}function M(a){var b=a.closest(".js-slideshow__gallery-node"),c=0,f="",e=null,g=null;0<b.length&&(c=parseInt(b.attr("data-node-id")||b.attr("data-nodeid"),10),f=b.data("sort")||"",b=b.closest(".ui-widget-content"),
b=b.find(".toolbar-filter-overlay .filter-options"),b.length&&(e=d("input[name=filter_time]:checked",b).val(),g=d("input[name=filter_show]:checked",b).val()));0==c&&(b=a.closest(".js-post-sm"),0<b.length&&(c=parseInt(b.attr("data-nodeid"),10)));0==c&&(a=a.closest(".js-post"),0<a.length&&(c=parseInt(a.attr("data-node-id"),10)));return{nodeid:c,sort:f,filter_time:e,filter_show:g}}function N(a){var b=a.closest(".js-post__content-text"),c={photos:[]},f=0;(b.length&&b.find(".js-lightbox, .js-lightbox-participant")||
a).each(function(){var e=d(this),g=e.data("fullsize-url")||e.parent().attr("href")||e.attr("src")||"";let n=e.data("thumb-url")||g,v=e.data("title")||"";e=e.data("caption")||"";g&&(g={url:g,thumb:n,links:v,title:e},c.photos.push(g),this===a[0]&&(p=f),f++)});return c}async function O(a){if(a.hasClass("js-lightbox"))return N(a);let b=a.closest(".b-content-entry-panel__content--gallery").find(".js-photo-postdata input");if(0<b.length){let q={photos:[]};b.filter('[name="filedataid[]"]').each(function(){var r=
this.value;let z=pageData.baseurl+"/filedata/fetch?filedataid="+r;r={title:JShtmlEncode(b.filter('[name="title_'+r+'"]').val()),url:z,thumb:z+"&thumb=1"};q.photos.push(r)});return new Promise((r,z)=>{setTimeout(()=>{r(q)},10)})}let c=a.attr("data-channelid"),f=a.attr("src")||a.attr("href");var e=M(a);let g=e.nodeid,n=e.sort,v=e.filter_time;e=e.filter_show;let l={nodeid:g},F=parseInt(d(".albumSlideShowPageNo").val(),10),G=parseInt(d(".albumSlideShowPerPage").val(),10),H=d(".media-tab .media-filter-overlay .filter-options input:checked").val();
(a=a.closest(".js-slideshow__gallery-node").data("userid"))&&(l.userid=a);c&&(l.channelid=c);isNaN(F)||(l.pageno=F);isNaN(G)||(l.perpage=G);H&&(l.dateFilter=H);isNaN(p)||(l.startIndex=p);n&&(l.sort=n);v&&(l.dateFilter=v);e&&(l.showFilter=e);0<g&&(l.startIndex="");let w=JSON.stringify(l);0<g&&(t[g]=t[g]||[],t[g].push(w));x[w]||await vBulletin.AJAX({call:"/filedata/gallery",data:l}).always(q=>{!q&&f&&(q={photos:[{title:"",url:f,thumb:""}]});x[w]=q});return x[w]}function I(a){if(!a)return 1;const b=
a.jcarousel("target");return b&&a.jcarousel("items").index(b)||0}function P(a,b,c,f){let e=I(k);b!=e&&a.jcarousel("scroll",b,c,f)}function Q(){m.jcarousel("items").each((a,b)=>{let c=d(b);a=k.jcarousel("items").eq(a);a.length&&c.on("jcarouselcontrol:active",()=>{m.jcarousel("scrollIntoView",c);c.find(".image-wrapper").removeClass("dimmed")}).on("jcarouselcontrol:inactive",()=>{c.find(".image-wrapper").addClass("dimmed")}).jcarouselControl({target:a,carousel:k})});m.on("jcarousel:destroy",a=>{m.jcarousel("items").off("jcarouselcontrol:active jcarouselcontrol:inactive")})}
function J(a,b,c){const f=a.add(b);f.offon("jcarouselcontrol:inactive",(e,g)=>{d(e.currentTarget).addClass("b-icon--disabled")});f.offon("jcarouselcontrol:active",(e,g)=>{d(e.currentTarget).removeClass("b-icon--disabled")});b.jcarouselControl({target:c?"-=3":"-=1"});a.jcarouselControl({target:c?"+=3":"+=1"})}function R(){var a=h.find(".slideshow-wrapper");0==a.find(".slideshow-list").length&&a.append(d("<ul />").addClass("slideshow-list"));u.slideshow=a.jcarousel({list:".slideshow-list",items:".jcarousel-item",
vertical:!1,center:!0,wrap:null,animation:"fast",easing:"swing",scroll:1,rtl:vBulletin.isRtl()}).jcarouselSwipe();a=d("#slideshow-dialog .thumbnails");0==a.find(".thumbnail-list").length&&a.append(d("<ul />").addClass("thumbnail-list"));u.thumbnails=a.jcarousel({list:".thumbnail-list",items:".jcarousel-item",wrap:null,animation:"fast",easing:"swing",rtl:vBulletin.isRtl()}).jcarouselSwipe();k=u.slideshow;m=u.thumbnails;k.disableSelection();m.disableSelection()}function A(a){let b=d(a.currentTarget);
y=a&&a.currentTarget;if(1==b.closest("#preview-overlay").length)return!1;a&&a.preventDefault&&a.preventDefault();R();a=k.jcarousel("list").parent();!1===p&&(p=b.index());h.dialog("open");window.vBulletin.loadingIndicator.show();O(b).then(c=>{window.vBulletin.loadingIndicator.hide();S(c,k)});a.on("jcarousel:targetin","li",(c,f)=>{const e=h.data("image-data");if(e){c=f.index(c.currentTarget)||0;f=e.photos.length;var g;c=Math.max(Math.round(c,10),0);var n;(g=null!=(n=e.photos[c])?n:{})||console.warn("onBeforeAnimation() - no photoInfo found for index:",
c,"photoCount:",f,"imageData:",e);C(h,g,c,!0)}});return!1}function S(a,b){if(a&&a.photos){h.data("image-data",a);T(b,a,h);C(h,a.photos[0],1);1<a.photos.length&&vBulletin.gallery.thumbnails.jcarousel("first").find(".image-wrapper").removeClass("dimmed");var c=p;a=parseInt(d(".albumSlideShowPerPage").val(),10);isNaN(a)||(c=p%a);0<c&&P(k,c+1,!1,function(f){"undefined"!=typeof f&&(h.find(".slideshow-wrapper").css("visibility","hidden"),window.setTimeout(function(){d(".thumbnails .image-wrapper",h).eq(c).trigger("click",
[!1]);h.find(".slideshow-wrapper").css("visibility","")},0))});window.vBulletin.loadingIndicator.hide()}else vBulletin.warning("gallery_slideshow","no_photos_found_or_post_deleted")}function K(a,b){a=a.jcarousel("list");const c=d("<li/>").addClass("jcarousel-item");c.append(b);a.append(c)}function T(a,b,c){a.jcarousel("list").empty();var f=1<b.photos.length;d("#slideshow-dialog .thumbnails").toggle(f);f&&U(b);c.toggleClass("no-thumbnails",!f);d.each(b.photos,function(e,g){e=d("<a></a>").attr("href",
g.url);g=d('<img alt="{0}" class="image" />'.format(g.htmltitle||"")).attr("src",g.url);let n=d('<div class="image-wrapper"></div>');e.append(g);n.append(e);K(a,n)});a.jcarousel("reload");b=d(".js-jcarousel-next-button");c=d(".js-jcarousel-prev-button");J(b,c);if(f){Q();f=d(".js-jcarousel-thumb-next-button");b=d(".js-jcarousel-thumb-prev-button");c=m.jcarousel("items").length;const e=m.jcarousel("visible").length;c=c<=e;J(f,b,!0);f.toggleClass("h-hide-imp",c);b.toggleClass("h-hide-imp",c)}}function U(a){let b=
d("#slideshow-dialog .thumbnails .thumbnail-list");0==b.length&&(b=d("#slideshow-dialog .thumbnails").append(d("<ul />").addClass("thumbnail-list")));const c=m;c.jcarousel("list").empty();d.each(a.photos,function(f,e){f=d("<img />").addClass("thumbnail").on("load",function(){}).attr({src:e.thumb,alt:""}).appendTo(d("<div />").addClass("image-wrapper dimmed"));K(c,f.parent().get(0))});c.jcarousel("reload")}function V(){if(y){var a=y,b=p,c=I(k);c&&(b=c);h.dialog("close");p=b;A.call(a)}}B.ensureObj("gallery");
const h=d("#slideshow-dialog"),u=B.gallery;let k,m,p=!1,y=!1,x={},t={};u.clearCacheForNodeid=function(a){t.hasOwnProperty(a)&&t[a].forEach(b=>delete x[b]);t[a]=[]};d(function(){h.data("vb-lightbox-initialized")||(h.data("vb-lightbox-initialized",!0),d(document).offon("click","#slideshow-dialog .close-btn",function(){h.dialog("instance")&&h.dialog("close")}),h.dialog({autoOpen:!1,resizable:!1,closeOnEscape:!0,showTitleBar:!1,modal:!0,dialogClass:"slideshow-dialog",open:function(){L();d("body").css("overflow",
"hidden");d(".ui-widget-overlay").on("click",function(){h.dialog("close")});d(document).offon("keydown",D);d(document).offon("mousewheel DOMMouseScroll",E)},close:function(a,b){m&&(m.jcarousel("destroy"),m=null);k&&(k.jcarousel("destroy"),k=null);d("body").css("overflow","auto");d(document).off("keydown",D);d(document).off("mousewheel DOMMouseScroll",E);p=y=!1}}))});d(function(){d(document).offon("click",".js-slideshow--item",A);d(document).offon("click",".js-lightbox",A);h.addClass("js-no-responsive-resize");
d(window).on("resize",d.debounce(300,V))})})(jQuery,vBulletin);
;

// ***************************
// js.compressed/conversation_filter.js
// ***************************
vBulletin.precache(["invalid_request","invalid_search_syntax","invalid_server_response_please_try_again","unknown_error"],[]);vBulletin.ensureObj("conversation");
vBulletin.conversation=$.extend(vBulletin.conversation,function(a){let G=window.hasOwnProperty("WeakRef"),H=[];vBulletin.conversation.displaySelectedFilterText=function(p,t,A){var e=a(p);if(1!=e.data("bypass-filter-display")){A=A||e.closest(".conversation-toolbar-wrapper");var x=a(".filtered-by",A).removeClass("h-hide").find(".filter-text-wrapper").show(),u=a(".filter-text[data-filter-name={0}]".format(p.name),x);if("radio"==p.type){t=e.next("span").html();var v=a('<div class="filter-text" data-filter-name="{0}" data-filter-value="{1}"><span title="{2}">{3}</span><span class="js-remove-filter b-icon b-icon__x-circle"></span></div>'.format(p.name,
vBulletin.htmlEntities(p.value),e.closest(".filter-options").prev(".filter-header").html()+" - "+t,("filter_new_topics"==p.name||"filter_depth"==p.name||-1!=p.value.indexOf("_all")&&"time_all"!=p.value?(e.closest("li").find(".filter-header").html()||"")+" - ":"")+t))}else"text"==p.type&&(t="&quot;"+JShtmlEncode(t)+"&quot;",v=a('<div class="filter-text" data-filter-name="{0}" data-filter-value="{1}"><span title="{2}">{3}</span><span class="js-remove-filter b-icon b-icon__x-circle"></span></div>'.format(p.name,
vBulletin.htmlEntities(p.value),e.data("filter-name")+": "+t,t)).data("filter-type","text"),(e=e.attr("class").match(/js-.*/))&&v.data("filter-js-selector","."+e[0]));if(0<u.length)u.replaceWith(v);else{var w=[],b=!1;a(".toolbar-filter-overlay > ul > li",A).each(function(){w.push(a("input:first",this).attr("name"))});a(".filter-text",x).each(function(){var q=a(this);if(a.inArray(p.name,w)<a.inArray(q.attr("data-filter-name"),w))return q.before(v),b=!0,!1});b||x.append(v);1<a(".filter-text",x).length&&
x.next(".clear-all").removeClass("h-hide")}}};return{filter:function(p){function t(c,d=null,g="slow",f=null){var h=c.closest(".conversation-toolbar-wrapper");let k="conversation_filter"+(h.hasClass("bottom")?"bottom":"top"),m=a(".toolbar-filter-overlay",h);var n=a(".filter-wrapper",c),r=n.is(".selected");if(null==d)d=!r;else if(d==r)return;let C=()=>{b.closeOverlayOnScroll&&a(window).offon("scroll."+k,function(){t(c,!1,0,"scroll")})},B=l=>{l=Math.max(Math.min(l,100),0);m.css("clip-path",`polygon(0 0, 100% 0, 100% ${l}%, 0% ${l}%)`)};
n.toggleClass("selected",d);n.attr("aria-expanded",d);a(".js-expanded-indicator",c).toggleClass("fa-caret-down fa-caret-up");B(d?0:100);m.show();r=m.offsetParent();r=r.offset().left+r.outerWidth();n=n.offset().left+n.outerWidth();n=r-n;h=h.find(".conversation-toolbar").outerHeight();m.css("max-height",`calc(100vh - ${h}px)`);m.css("--js-filter-menu-right",`${n}px`);a({step:0}).animate({step:100},{step:(l,y)=>{"step"==y.prop&&B(d?l:100-l)},complete:(()=>{if(d){a("body").offon("click."+k,z=>{z=a(z.target);
0<z.closest(".toolbar-filter-overlay").length||0<z.closest(".toolbar-filter").length||(a("body").off("click."+k),a(window).off("scroll."+k),t(c,!1,"slow"))});var l=!0;if("scroll"!=f){l=a(".filtered-by",b.context);if(0==l.length||l.is(":hidden"))l=c;var y={};(l=vBulletin.isScrolledIntoView(l,y))||a("html,body").animate({scrollTop:"+="+Math.abs(y.bottom)},"fast",function(){setTimeout(function(){C()},50)})}l&&C()}else a("body").off("click."+k),a(window).off("scroll."+k)})(),duration:g})}function A(c,
d){vBulletin.conversation.displaySelectedFilterText(c,d,b.context)}let e=this,x=null,u=0,v=!1,w=!1,b={context:document,autoCheck:!1,checkInterval:15E3,scrollToTop:null,customFilter:null,onContentLoad:null,closeOverlayOnScroll:!1,pagination:null,allowHistory:!1,tabParamAsQueryString:!0,hash:"",beforeApplyFilters:null,afterResetFilters:null};p&&"object"==typeof p&&a.extend(b,p);var q=new vBulletin.history.instance(b.allowHistory);this.closeFilterMenu=()=>{a(".toolbar-filter",b.context).each((c,d)=>
{t(a(d),!1,"fast")})};(function(){a(".toolbar-filter-overlay input[type=radio]",b.context).off("change.conversation_filter").on("change.conversation_filter",function(c,d,g){c=a(this);var f=a(this.form);if(!q.isEnabled()&&b.allowHistory)return c=vBulletin.makePaginatedUrl(location.href,1),location.href=vBulletin.makeFilterUrl(c,this.name,this.value,b.context,b.hash),!0;v=!0;b.customFilter=null;c.data("bypass-filter-display")||A(this);c=c.closest(".conversation-toolbar-wrapper");1<a(".conversation-toolbar-wrapper",
b.context).length&&$toolbarWrappers.filter("."+(c.hasClass("top")?"bottom":"top")).find("input[name={0}][value={1}]".format(this.name,this.value)).prop("checked",!0);"conversations_on"==this.value?(w=b.autoCheck=!0,u=1):(clearTimeout(u),w="filter_show"==this.name);a(".new-conversations-strip",b.context).hide();e.updatePageNumber(g||1);g=a('.filtered-by .filter-text[data-filter-name="q"]',b.context);if(g.length){var h=e.getSelectedFilters(f);h.q=g.data("filter-value");e.setOption("customFilter",h);
e.forceApplyFilters()}else e.applyFilters(!1);q.isEnabled()&&!d&&(h=e.getSelectedFilters(f),f=this.name,g=this.value,d=a(".filtered-by",c),h={from:"filter",page:1,tab:b.tabParamAsQueryString?"#"+c.closest(".ui-tabs-panel").attr("id"):vBulletin.getSelectedTabHashOrPath(c.closest(".ui-tabs"),!1),filters:h,filtervalue:g,filtername:f},d.data("reset")?(c=location.pathname.replace(/\/page[0-9]+/,""),b.tabParamAsQueryString&&(f=vBulletin.parseQueryString(location.search),f.tab?c+="?tab="+f.tab:f.view&&(c+=
"?view="+f.view))):(c=vBulletin.makePaginatedUrl(location.href,1),c=vBulletin.makeFilterUrl(c,f,g,b.context)),q.pushState(h,document.title,c),d.data("reset",null))});a(".new-conversations-strip",b.context).off("click.conversation_filter").on("click.conversation_filter",function(){a(this).hide();w=!0;e.updatePageNumber(1);e.applyFilters(!1,!0)});a(".toolbar-filter",b.context).offon("click.conversation_filter",(c,d="slow",g=null)=>{t(a(c.currentTarget),null,d,g)});a(".filtered-by",b.context).offon("click.conversation_filter",
".js-remove-filter",function(){var c=a(this),d=c.closest(".filtered-by"),g=c.closest(".filter-text"),f=g.data("filter-name");a();d.data("clicked",!0);if(!q.isEnabled()&&b.allowHistory)return"text"==g.data("filter-type")&&g.data("filter-js-selector")?(d=vBulletin.makePaginatedUrl(location.href,1),location.href=vBulletin.makeFilterUrl(d,"q","",b.context,b.hash,!0)):(d=vBulletin.makePaginatedUrl(location.href,1),location.href=vBulletin.makeFilterUrl(d,f,g.data("filter-value"),b.context,b.hash,!0)),!1;
var h=a(".toolbar-filter-overlay .filter-options input[name={0}]".format(f),b.context).prop("checked",!1).filter(".js-default-checked");e.updatePageNumber(1);if("text"==g.data("filter-type")&&g.data("filter-js-selector")){a(g.data("filter-js-selector")).val("");var k=e.getSelectedFilters(a("form.toolbar-filter-overlay",b.context));delete k[f];e.setOption("customFilter",k)}g.remove();g=d.find(".filter-text").length;0==g?(d.addClass("h-hide"),d.data("reset",!0)):1==g&&d.find(".clear-all").addClass("h-hide");
1==h.length?(h.data("bypass-filter-display",!0),h.trigger("click.conversation_filter"),h.data("bypass-filter-display",null)):(k&&(d=vBulletin.makePaginatedUrl(location.href,1),d=vBulletin.makeFilterUrl(d,"q","",b.context),q.pushState({from:"filter",page:1,tab:b.tabParamAsQueryString?"#"+c.closest(".ui-tabs-panel").attr("id"):vBulletin.getSelectedTabHashOrPath(c.closest(".ui-tabs"),!1),filters:k},document.title,d)),e.forceApplyFilters(),k&&e.setOption("customFilter",null))});a(".filtered-by",b.context).offon("click.conversation_filter",
".clear-all",function(c){var d=a(this).closest(".conversation-toolbar-wrapper");a(this).data("clicked",!0);e.setOption("customFilter",null);e.resetFilters(!1,!1,d);c.preventDefault()});a(".conversation-toolbar .filter-wrapper",b.context).data("object-instance",e);a(".js-conversation-showmore-button",b.context).off("click").on("click",function(){var c=parseInt(a('form.toolbar-filter-overlay input[name="pagenum"]',b.context).val());w=!1;e.updatePageNumber(c+1);e.applyFilters(!1,!0,!0)});a(".conversation-toolbar .toolbar-search-form",
b.context).off("submit.filtersearch").on("submit.filtersearch",function(){var c=a(this.elements.q),d=a.trim(c.val()),g=a(this).closest(".conversation-toolbar-wrapper");c.val(d);if(!q.isEnabled()&&b.allowHistory){var f=vBulletin.makePaginatedUrl(location.href,1);location.href=vBulletin.makeFilterUrl(f,"q",d,g);return!1}c=b.tabParamAsQueryString?"#"+a(this).closest(".ui-tabs-panel").attr("id"):vBulletin.getSelectedTabHashOrPath(a(this).closest(".ui-tabs"),!1);if(d){var h=e.getSelectedFilters(g.find(".toolbar-filter-overlay"));
f={};f.q=d;a.extend(h,f);e.setOption("customFilter",h);e.forceApplyFilters();e.displayCustomFilterText(this.elements.q);q.isEnabled()&&(f=vBulletin.makePaginatedUrl(location.href,1),f=vBulletin.makeFilterUrl(f,"q",d,g),q.pushState({from:"filter",page:1,tab:c,filters:h},document.title,f))}else f=g.find('.filter-text[data-filter-name="{0}"]'.format("q")),f.length&&(h=e.getSelectedFilters(g.find(".toolbar-filter-overlay")),e.setOption("customFilter",h),a(".x",f).trigger("click"),q.isEnabled()&&(f=vBulletin.makePaginatedUrl(location.href,
1),f=vBulletin.makeFilterUrl(f,"q",d,g),q.pushState({from:"filter",page:1,tab:c,filters:h},document.title,f)));return!1})})();this.isFilterSelected=function(c){return a('.toolbar-filter-overlay input[value="'+c+'"]',b.context).is(":checked")};this.getSelectedFilters=function(c){return vBulletin.getSelectedFilters(c,!1)};this.resetFilterForms=function(c){if(!c||c instanceof a&&!c.length)c=b.context;a(".toolbar-filter-overlay .js-default-checked",c).prop("checked",!0);a(".toolbar-search-form .js-filter-search",
c).val("")};a(".toolbar-filter-overlay, .toolbar-search-form",b.context).trigger("reset");if(q.isEnabled()){p=q.getState();if(!p||a.isEmptyObject(p.data)){a(b.context).hasClass("ui-tabs-panel")?a(b.context).attr("id"):a(".conversation-toolbar-wrapper",b.context).closest(".ui-tabs-panel").attr("id");var E={from:"filter",page:Number(a(".pagenav-form .defaultpage",b.context).val())||1,tab:vBulletin.getSelectedTabHashOrPath(a(b.context).closest(".ui-tabs"),b.tabParamAsQueryString),filters:e.getSelectedFilters(a("form.toolbar-filter-overlay",
b.context))};q.setDefaultState(E,document.title,location.href)}q.setStateChange(function(c,d,g){var f=q.getState();if("filter"==f.data.from||"pagination"==d||"tabs"==d){q.log(f.data,f.title,f.url);var h;f.data.tab&&(h=b.tabParamAsQueryString?a(f.data.tab):a('.ui-tabs .ui-tabs-panel[data-url-path="'+f.data.tab+'"]'));c=h&&h.length&&h||b.context;if("pagination"==d){if(g){d=a(".filtered-by",c);var k=a(".toolbar-filter-overlay .filter-options-list",c),m=!1;a(".filter-text",d).filter('[data-filter-name!="q"]').remove();
a(".clear-all",d).addClass("h-hide");k.find(".js-default-checked").prop("checked",!0);a.each(g,function(n,r){n=a('input[name="{0}"][value="{1}"]'.format(n,r),k);n.length&&(n.prop("checked",!0).trigger("change",[!0,f.data.page]),m=!0)});m||(k.first().data("bypass-filter-display",!0).trigger("change",[!0,f.data.page]).data("bypass-filter-display",null),d.addClass("h-hide"))}}else g=a(c).closest(".ui-tabs"),d=b.tabParamAsQueryString?g.find('.ui-tabs-nav > li > a[href*="{0}"]'.format(f.data.tab)):g.find('.ui-tabs-nav > li > a[data-url-path="'+
f.data.tab+'"]'),d.parent().hasClass("ui-tabs-active")?(g=e.getSelectedFilters(a(".toolbar-filter-overlay",c)),d=a(".conversation-toolbar .filter-wrapper",c).data("object-instance")||e,vBulletin.areJsonObjectsEqual(g,f.data.filters)||(d.setOption("context",c),d.updatePageNumber(f.data.page),d.applyHistoryFilters(f.data))):(c=d.parent().index(),vBulletin.selectTabByIndex.call(g,c))}},"filter")}this.displayCustomFilterText=function(c,d){A(c,d||a(c).val())};this.isHistoryEnabled=function(){return q.isEnabled()};
this.resetFilters=function(c,d,g){if(!g||g instanceof a&&!g.length)g=b.context;var f=a(".filtered-by",g).addClass("h-hide"),h=location.pathname.replace(/\/page[0-9]+/,"");if(b.tabParamAsQueryString){var k=vBulletin.parseQueryString(location.search);k.tab?h+="?tab="+k.tab:k.view&&(h+="?view="+k.view)}a(".clear-all",f).addClass("h-hide");a(".filter-text",f).remove();e.resetFilterForms(g);if(!c)if(q.isEnabled()){f.data("reset",!0);e.updatePageNumber(1);k=e.getSelectedFilters(a("form.toolbar-filter-overlay",
g));if(d){var m=a(".toolbar-search-form .js-filter-search",g).val("");delete k[m.attr("name")];e.setOption("customFilter",k)}e.forceApplyFilters();E={from:"filter",page:1,tab:b.tabParamAsQueryString?"#"+f.closest(".ui-tabs-panel").attr("id"):vBulletin.getSelectedTabHashOrPath(f.closest(".ui-tabs"),!1),filters:k};q.pushState(E,document.title,h)}else b.allowHistory&&(location.href=h);"function"==typeof b.afterResetFilters&&b.afterResetFilters.apply(this,arguments);return e};this.applyHistoryFilters=
function(c){if(c&&c.filters&&!a.isEmptyObject(c.filters)){var d=b.tabParamAsQueryString?a(c.tab):a('.ui-tabs .ui-tabs-panel[data-url-path="'+c.tab+'"]'),g=a(".toolbar-filter-overlay",d);"undefined"!=typeof e.lastFilters&&delete e.lastFilters;e.resetFilters(!0,!1,d);a.each(c.filters,function(m,n){m=a('[name="'+m+'"]',g);"hidden"==m.attr("type")?m.val(n):"radio"==m.attr("type")&&n!=c.filtervalue&&m.filter('[value="'+n+'"]').prop("checked",!0)});var f=vBulletin.parseQueryString(location.href),h=!0,k=
function(){a(".toolbar-search-form .js-filter-search",d).val("")};a.isEmptyObject(f)?k():a.each(f,function(m,n){var r=a('.filter-options-list input[name="{0}"][value="{1}"]'.format(m,n),g);r.length?c.filtername==m&&c.filtervalue==n?(h=!1,r.prop("checked",!0).trigger("change",[!0])):A(r.get(0)):(r=a('.toolbar-search-form .js-toolbar-search-inner input[name="{0}"]'.format(m),d),r.length&&n?(A(r.get(0),n),r.val(n)):k())});h&&(e.setOption("customFilter",c.filters),e.forceApplyFilters(),e.setOption("customFilter",
null))}return e};this.forceApplyFilters=function(){"undefined"!=typeof e.lastFilters&&delete e.lastFilters;w=!0;e.applyFilters(!1,!0);return e};this.applyFilters=function(c,d,g,f){if("function"==typeof b.beforeApplyFilters&&!1===b.beforeApplyFilters.apply(this,arguments))return e;var h=a(".toolbar-filter-overlay",b.context);d&&clearTimeout(u);var k={filters:b.customFilter?b.customFilter:e.getSelectedFilters(h),isAjaxTemplateRender:!0,isAjaxTemplateRenderWithData:!0};if(a.isEmptyObject(k.filters))return e;
c&&(k.filters.checkSince=x,k.filters.pagenum=1);f?w=!0:h.find('input[name="result-id"]').val(0).length&&(k.filters["result-id"]=0);if("undefined"!=typeof this.lastFilters&&vBulletin.areJsonObjectsEqual(this.lastFilters.filters,k.filters)&&!c)return e;this.lastFilters=k;var m=a(".conversation-empty",b.context),n=a(".conversation-toolbar-wrapper",b.context);n.addClass("h-disabled");m.addClass("h-invisible");c&&window.vBulletin.loadingIndicator.suppressNextAjaxIndicator();var r=vBulletin.normalizeAjaxUrl(h.attr("action"))||
vBulletin.getAjaxBaseurl()+"/activity/get",C=h.closest(".conversation-toolbar-wrapper").find('form.pagenav-form input[name="article_display_columns"]');1==C.length&&(k.article_display_columns=C.val());var B=a(".conversation-list",b.context);vBulletin.AJAX({url:r,data:k,api_error:function(l){B.addClass("h-hide");m.removeClass("h-hide h-invisible");return!0},success:function(l){m.addClass("h-hide");if(c)!v&&0<l.total&&!a("body").hasClass("edit-mode")&&(a(".new-conversations-strip span",b.context).html(l.total),
a(".new-conversations-strip",b.context).fadeIn("slow")),0==a(".conversation-list li.list-item",b.context).length&&m.removeClass("h-hide");else{var y=a(".js-conversation-showmore",b.context);a(".new-conversations-strip",b.context).hide();if((0<l.total_with_sticky||0<l.total)&&l.template){l.resultId&&(a('input[name="result-id"]',h).val(l.resultId).length&&this.lastFilters&&(this.lastFilters.filters["result-id"]=l.resultId),b.pagination&&b.pagination.updateResultId(l.resultId));g?B.append(l.template):
(m.addClass("h-hide"),B.html(l.template).removeClass("h-hide"));l.fixFlexGrid&&vBulletin.initFlexGridFixLastRowAll();var z=k.filters,D=parseInt(z.maxpages);z=parseInt(z.pagenum);var F=l.pageinfo;D=D&&z>=D||F&&(z>=parseInt(F.totalpages)||!1===F.showseemore);y.toggleClass("h-hide",D)}else g||(m.removeClass("h-hide"),B.addClass("h-hide").empty());0==l.total_with_sticky&&y.addClass("h-hide");w&&b.scrollToTop&&(y=b.scrollToTop instanceof a?b.scrollToTop:a(b.scrollToTop),0<y.length&&a("body,html").animate({scrollTop:y.offset().top},
"slow"));x=l.lastDate;"function"==typeof b.onContentLoad&&b.onContentLoad.apply(B.get(0),[l]);l.pageinfo&&(e.updatePageNumber(l.pageinfo.pagenumber||1),b.pagination&&"function"==typeof b.pagination.updatePageInfo&&(b.pagination.setOption("context",b.context),b.pagination.updatePageInfo(l.pageinfo,!0)));a(document).trigger("vb-postpagination",{ajaxResult:l});vBulletin.inlinemod&&"function"==typeof vBulletin.inlinemod.init&&0<a(".moderationmenu_container",b.context).length&&vBulletin.inlinemod.init(b.context);
a(document).trigger("vb-filterposts",{parentOfInsertedHtml:B})}v&&(v=!1)},error_phrase:"unable_to_contact_server_please_try_again",complete:function(){n.removeClass("h-disabled");m.removeClass("h-invisible");!v&&b.autoCheck&&u&&(u=setTimeout(e.checkNewConversations,b.checkInterval))}});return e};this.updatePageNumber=function(c){c=Number(c);0<c&&a('form.toolbar-filter-overlay input[name="pagenum"]',b.context).val(c);return e};this.checkNewConversations=function(){a("body").hasClass("edit-mode")||
(console.log("Checking for new activity since "+x),e.applyFilters(!0));return e};this.toggleNewConversations=function(c){c?(b.autoCheck=!0,u=setTimeout(e.checkNewConversations,b.checkInterval)):(b.autoCheck=!1,clearTimeout(u));return e};this.hideFilterOverlay=function(){a(".conversation-toolbar-wrapper .toolbar-filter-overlay",b.context).filter(":visible").each(function(){a(this).prev(".conversation-toolbar").find(".toolbar-filter").triggerHandler("click.conversation_filter",[0])});return e};this.getOption=
function(c){return b[c]};this.setOption=function(c,d){b[c]=d;return e};b.autoCheck&&(x=pageData.current_server_datetime,u=setTimeout(e.checkNewConversations,b.checkInterval));H.push(G?new WeakRef(this):this)},closeFilterMenus:function(){for(const p of H){const t=G?p.deref():p;t&&t.closeFilterMenu()}}}}(jQuery));
;

// ***************************
// js.compressed/conversationcommon.js
// ***************************
vBulletin.precache("answer_must_be_approved_published conversation compare_versions edit_conversation error_loading_post flag_a_post onbeforeunload_message_while_editing_post people_who_liked please_enter_your_reason_why_you_want_to_flag_this_post send_report the_report_has_been_sent topic_answered you_have_a_pending_edit_unsaved".split(" "),[]);vBulletin.ensureObj("conversation");
$.extend(vBulletin.conversation,function(b,g,y,t,u,w){function G(a){function c(k,r,n,v){r=b.Event("afterSave");v.trigger(r,k);if(r.isDefaultPrevented())w.destroyEditor(h);else{if(k&&k.warnings){if(y.hasError(k.warnings,"warning_spam_post")){y.showApiError(k.warnings,k,{title_phrase:"warning",after_error:function(){k.warningReturnUrl?location.href=k.warningReturnUrl:location.reload(!0)}});return}g.flashPhrase(k.warnings[0])}r=v.data("content-type");n=v.closest(".js-content-entry").data("current-channelid");
v=v.find('input[name="parentid"]:checked').val();0<n&&0<v&&n!=v?location.reload(!0):(w.destroyEditor(h),H(m,p,q,d,e.closest(".js-post"),r))}}var e=b(this),d,f=e.closest(".conversation-list");0<e.closest(".js-comments").length&&(d="comment");var l=b(".edit-conversation-container form",f);if(0<l.length)t.warning("edit_conversation","you_have_a_pending_edit_unsaved",function(){g.animateScrollTop(l.closest(".js-post").offset().top,{duration:"slow"})});else{a.preventDefault();var m=e.parent().attr("data-node-id"),
h="comment"==d?e.closest(".js-comment"):e.closest(".js-post__content-wrapper");var p=f.hasClass("thread-view")?"thread":f.hasClass("full-activity-view")?"full-activity-stream":f.hasClass("activity-view")?"activity-stream":"stream";d=d||h.attr("data-node-type")||"";a=b(".js-show-post-link",h).text()||"1";var q=Number(a.replace("#",""));("comment"!=d||"thread"!=p&&1!=f.closest(".blog-conversation-content-widget").length)&&q--;g.AJAX({call:"/create-content/loadeditor",data:{nodeid:m,type:d,view:p,isAjaxTemplateRender:!0,
isAjaxTemplateRenderWithData:!0},success:function(k){var r=function(){if("upload"in g&&"tagEditor"in g&&"initEntryBox"in w){h.addClass("b-post--edit");h.find(".js-post__content").first().addClass("b-post__content--edit");h.find(".b-post__footer").first().addClass("b-post__footer--edit");$container=h.find(".edit-conversation-container").first();h.closest(".js-album-detail").find(".conversation-body, .profile-media-uploadphotos, .js-photo-preview").addClass("h-hide-imp");var n=$container.find(".js-content-entry");
0<n.length||(n=$container.find("#newTextForm"));w.initEntryBox(n,!1,c);$container.show();n=$container.find(".js-attach-list");g.tagEditor.initEditTagsContent(".js-post[data-node-id={0}] .tag-editor-container .tag-input".format(m));0<n.data("attach-count")&&(n=$container.find(".b-toolbar__item").filter(function(){return"b-content-entry-panel__content--attachment"==b(this).data("panel")}),n.hasClass("b-toolbar__item--active")||n.trigger("click"));w.afterPanelChange(h);g.flatpickr&&g.flatpickr.initPickers()}else u.loadScripts("",
{},r)};b(".edit-conversation-container",h).first().hide().html(k.template);k=b(".edit-conversation-container form",h).data("content-type");b(window).offon("beforeunload.editPost",()=>g.phrase.get("onbeforeunload_message_while_editing_post"));b("body").trigger(k+"_editform_onload",[h,r])},title_phrase:"edit_conversation"})}}function H(a,c,e,d,f,l){let m=pageData;m["posts-perpage"]=A;"thread"==c&&(m["comments-perpage"]=B);g.AJAX({call:"/create-content/loadnode",data:{nodeid:a,view:c,index:e,page:m,
type:d,isAjaxTemplateRender:!0,isAjaxTemplateRenderWithData:!0},success:function(h){var p=b(h.template),q=f.parent();f.replaceWith(p);p=q.find(".js-post").filter((r,n)=>b(n).data("node-id")==a);if(h.hasOwnProperty("template_article_title_info")){q=b(".js-update-article-title-info");var k=b(h.template_article_title_info);0<q.length&&q.empty().append(k)}b("body").trigger(l+"_newcontent_onload",[p]);b(document).trigger("vb-loadnode",{insertedHtml:p,context:"conversationcommon"});p.hasClass("js-conversation-starter")&&
(q=b(".js-post-title",p).first().text(),k=q+" - "+g.options.get("bbtitle"),"topic_url"in h&&(h=pageData.baseurl+h.topic_url,h!=location.href&&window.history.replaceState({},k,h)),document.title=k,b(".page-title-widget .js-main-title").text(q));b(".js-select-box",p).selectBox();g.animateScrollTop(p.offset().top,{duration:"slow"})},title_phrase:"conversation",error_phrase:"error_loading_post"})}function C(a,c=3){var e=0,d=b("ul.poll li",a),f=parseInt(d.css("line-height"),10);d.each(function(l){b(this).removeClass("h-hide");
l=b(this).height();e+=l/f;e>c?b(this).addClass("h-hide"):b(this).css("display","")});d=e>c;b(".view-more-ctrl",a).toggleClass("h-hide-imp",!d).next(".js-button-group").toggleClass("h-hide",d).next(".view-less-ctrl").toggleClass("h-hide-imp",d)}function z(a){return a.closest(".js-post").data("node-id")}function I(){var a=b(this),c=a.data("post-ip");a.data("post-host");x.register(["ip_info","ip_address_is","host_name_is","no_ip_found"]);c?(t.openAlertDialog({title:x.get("ip_info"),message:x.get("ip_address_is")+
": "+c+"<br />"+x.get("host_name_is")+': <span class="ip-host-name loading">...</span>',iconType:"none"}),g.AJAX({call:"/ajax/api/node/getHostName",data:{ip:c},success:function(e){b(".ip-host-name").removeClass("loading").html(e)}})):g.alert("ip_info","no_ip_found");return!1}function J(){var a=z(b(this)),c=t.openPromptDialogSimple({title:"flag_a_post",message:"please_enter_your_reason_why_you_want_to_flag_this_post",okPhrase:"send_report",multiline:!0,validation:t.validationString,onClickOk:function(e){g.AJAX({call:"/report/report",
data:{reason:e,reportnodeid:a},success:function(d){c.dialog("close");g.alert("flag_a_post","the_report_has_been_sent")},api_error:d=>{c.find(".js-prompt-error").html(x.get(d[0])).removeClass("h-hide")},error_phrase:"unable_to_contact_server_please_try_again"});return!1}});return!1}function K(){var a=b(this).closest(".js-comment-entry__parent").find(".js-comment-entry");a.slideToggle("fast",function(){var c=b(this).find(".js-comment-entry__textbox");c.is(":visible")&&c.trigger("focus")});a.find(".js-comment-entry__cancel").offon("click.convocom",
function(c){a.slideToggle();return!1});return!1}function L(){let a=z(b(this));t.openTemplateConfirmDialog(y,{title:"post_history",width:800,yesPhrase:"compare_versions",noPhrase:"cancel",onClickYes:c=>{c=g.getFormData(c.find(".post-history-form"));t.openTemplateAlertDialog(y,{title:"post_history",width:800,okPhrase:"close"},{template:"post_history_form",data:{oldpost:c.old||1,newpost:c["new"]||1,nodeid:a}});return!1}},{template:"post_history_form",data:{nodeid:a}})}function M(){var a=b(this),c=z(a);
a=!a.closest(".js-post").hasClass("isanswer");var e=vBulletin.getSelectedFilters(b(".toolbar-filter-overlay"));b("body").css("cursor","wait");g.AJAX({call:"/create-content/setExclusiveAnswer",data:{nodeid:c,set:a?1:0,searchFilters:e,isAjaxTemplateRender:!0,isAjaxTemplateRenderWithData:!0},success:function(d){b(".js-post.isanswer").toggleClass("isanswer",!1);d.answers&&0<d.answers.length&&d.answers.forEach(m=>{b(".js-post[data-node-id="+parseInt(m,10)+"]").toggleClass("isanswer",!0)});let f=b(".js-post.pinned-answer");
f.length&&f.hide("slow",()=>{f.remove()});if(d.template){var l=b(".js-conversation-starter");d=b(d.template);d.hide();d.insertAfter(l).show("slow")}},complete:function(){b("body").css("cursor","default")},error_phrase:"unable_to_contact_server_please_try_again",title_phrase:"setasanswer"});return!1}function N(a,c){if(g.isFun(c)){console.log("Edit mode: initializeEditor");var e=a.find(".js-editor");0<e.length?u.initEditor(e,{success:function(d){c();w.afterPanelChange(a);u.initEditorComponents(a);var f=
this;setTimeout(function(){f.setData(e.prev(".js-editor-parsed-text").html(),function(){var l=u.getEditor(d);u.fixTableFunctionality.call(u,{},l);setTimeout(function(){u.modifyImagePaths(b(l.container.$))},0);l.focus()})},0)},error:function(d){c();e.prop("disabled",!1).removeClass("ckeditor-load-on-focus").closest(".js-content-entry").addClass("b-content-entry--no-ckeditor");d=e.prev(".js-editor-parsed-text").html();""!=d&&vBulletin.AJAX({call:"/ajax/api/editor/convertHtmlToBbcode",data:{nodeid:pageData.nodeid,
data:d,allowsmilie:1,securitytoken:pageData.securitytoken},success:function(f){e.html(f.data)},error_phrase:"error_converting_message"})},hideLoadingDialog:!1}):g.isFun(c)&&(c(),e.trigger("focus"))}}const D=g.data("conversation-data"),E=(a,c,e)=>Number(a[c]||a["default_"+c]||e)||0,B=E(D,"comments_per_page",25),A=E(D,"posts_per_page",15);let x=g.phrase,F=a=>0<a.length?1:0;return{postComment:function(a,c){let e=this;a=b(e);let d=a.closest(".js-comment-entry"),f=d.find(".js-comment-entry__textbox"),
l=b.trim(f.val());if(!l)return t.warning("post_comment","please_enter_your_comment",f),!1;a.blur();let m=a.closest(".js-comment-entry__parent"),h=F(a.closest(".js-comment-entry--blog")),p=F(a.closest(".js-comment-entry--article")),q={text:l,parentid:m.attr("data-node-id"),postindex:m.find(".js-post__content .js-show-post-link").text().replace("#",""),view:m.parent().hasClass("stream-view")?"stream":"thread",redirecturl:f.hasClass(".reload-on-post")?1:0,isblogcomment:h,isarticlecomment:p};d.find('[name^="humanverify"]').each((k,
r)=>{k=b(r);q[k.attr("name")]=k.val()});vBulletin.AJAX({call:"/ajax/post-comment",data:q,complete:()=>{g.hv.reset()},success:function(k,r,n){g.ensureFun(c).apply(e,[k]);h||p||d.slideToggle();g.subscribe.updateSubscribeButton(k.topic_subscribed)},api_error:vBulletin.hv.resetOnError,title_phrase:"conversation",error_phrase:"error_posting_comment_code"})},initContentEvents:function(a){a.offon("click.convocom",".js-post-control__ip-address",I);a.offon("click.convocom",".js-post-control__edit",G);a.offon("click.convocom",
".js-post-control__flag",J);a.offon("click.convocom",".js-post-control__comment",K);a.offon("click.convocom",".js-post__history",L);a.offon("click.convocom",".js-post-control__answer",M)},initPollEvents:function(a){a.offon("click.convocom",".list-item-poll .view-more-ctrl",function(c){var e=b(this).closest("form.poll");c=e.find("ul.poll");b(this).addClass("h-hide-imp");c.css("max-height","none").find("li.h-hide").slideDown(100,function(){e.find(".js-button-group").removeClass("h-hide").next(".view-less-ctrl").removeClass("h-hide-imp");
g.animateScrollTop(e.offset().top,{duration:"fast"})});return!1});a.offon("click.convocom",".list-item-poll .view-less-ctrl",function(c){c=b(this).closest("form.poll");C(c,3);c.find("ul.poll").css("max-height","").find("li.h-hide").slideUp(100);return!1})},limitVisiblePollOptionsInAPost:C,bindEditFormEventHandlers:function(a){function c(f){b("body").offon(f+"_newcontent_onload",function(l,m){0<m.closest(".conversation-list.stream-view.activity-view").length&&g.truncatePostContent(m)});b("body").offon(f+
"_editform_onload",function(l,m,h){N(m,h)})}a=a?a.toLowerCase():"";let e={comment:function(){b("body").offon("comment_editform_onload",function(f,l,m){g.isFun(m)&&(m(),b(".js-editor",l).trigger("focus").filter(".autogrow").css("min-height",function(){return b(this).css("height")}).autogrow())})},poll:function(){b("body").offon("poll_newcontent_onload",function(f,l){0<l.closest(".conversation-list.stream-view.activity-view").length&&(g.truncatePostContent(l),conversation.limitVisiblePollOptionsInAPost(b("form.poll",
l),3))})}},d="text gallery video event poll link".split(" ");if("all"==a){for(const f of d)c(f);for(const f in e)e[f]()}else if(d.includes(a)&&c(a),a in e)e[a]()},COMMENTS_PER_PAGE:B,POSTS_PER_PAGE:A}}(jQuery,vBulletin,vBulletin.ajaxtools,vBulletin.dialogtools,vBulletin.ckeditor,vBulletin.contentEntryBox));
;

// ***************************
// js.compressed/channel_conversation.js
// ***************************
vBulletin.precache(["closed","this_topic_is_closed"],[]);
(function(b){if(!vBulletin.pageHasSelectors([".forum-channel-content-widget",".blog-channel-content-widget",".sg-channel-content-widget",".search-results-widget .topic-list-container"]))return!1;var v={};vBulletin.conversation.editTopicTitle=function(k){k=b(k.target).closest(".js-topic-item");var a=k.find(".js-topic-wrapper"),n=k.data("node-id");k.data("can-edit-title")&&!v[n]&&(v[n]="edit",0==a.find(".js-loading-icon").length&&b('<img class="loading-icon js-loading-icon" src="'+pageData.baseurl+
'/images/misc/progress.gif" />').appendTo(a),a.find(".js-loading-icon").show(),vBulletin.AJAX({call:"/create-content/loadtitleedit",data:{nodeid:n,isAjaxTemplateRender:!0},success:function(e){a.find(".js-topic-title").hide();a.find(".js-loading-icon").hide();a.find(".js-topic-title").after(e);e=a.find(".js-topic-title-edit");e.data("original-title",e.val());var q=30;a.find(".js-prefix, .js-post-icon, .js-topic-prefix, .js-go-to-first-unread").each(function(){q+=b(this).outerWidth(!0)});e.outerWidth(e.outerWidth()-
q);a.find(".js-topic-title-edit-form").on("submit",vBulletin.conversation.saveTopicTitle);e.on("blur",vBulletin.conversation.saveTopicTitle);e.trigger("select").trigger("focus")}}))};vBulletin.conversation.saveTopicTitle=function(k){k.preventDefault();var a=b(k.target).closest(".js-topic-wrapper");k=a.find(".js-topic-title-edit-form");var n=k.find(".js-node-id").val(),e=k.find(".js-topic-title-edit").val();"save"!=v[n]&&(v[n]="save",a.find(".js-topic-title-edit").data("original-title")==e?(a.find(".js-loading-icon").remove(),
a.find(".js-topic-title-edit-form").remove(),a.find(".js-topic-title").show(),v[n]=!1):(a.find(".js-loading-icon").appendTo(k).show(),vBulletin.AJAX({call:"/create-content/savetitleedit",data:{nodeid:n,title:e},success:function(q){a.find(".js-topic-title-edit-form").remove();a.find(".js-topic-title").html(q.title).show()},complete:function(){a.find(".js-loading-icon").remove();v[n]=!1}})))};vBulletin.conversation.openOrCloseTopic=function(k){k.stopPropagation();var a=b(this),n=a.closest(".js-topic-item"),
e=n.find(".js-topic-wrapper");k=n.data("node-id");var q=n.hasClass("closed");0==e.find(".js-loading-icon").length&&b('<img class="loading-icon js-loading-icon" src="'+pageData.baseurl+'/images/misc/progress.gif" />').appendTo(e);var w=e.find(".js-loading-icon");w.show();vBulletin.AJAX({call:"/ajax/api/node/"+(q?"openNode":"closeNode"),data:{nodeid:k},error_phrase:"error_open_close_topic",api_error:function(h){var g=vBulletin.ajaxtools;if(g.hasError(h,"inlinemodauth_required"))return!0;g.logApiError(h)},
complete:function(){w.hide()},success:function(h){n.toggleClass("closed",!q);h=a.attr("title")||"";var g=vBulletin.phrase.get("this_topic_is_closed");subStrIndex=h.indexOf(g);q&&0<=subStrIndex?(h=(h.slice(0,subStrIndex)+h.slice(subStrIndex+g.length)).trim(),a.attr("title",h)):!q&&0>subStrIndex&&a.attr("title",g+" "+h);h=e.find(".js-prefix");g=[];var x=vBulletin.phrase.get("closed");if(h.length){var l=h.text().trim();":"==l.charAt(l.length-1)&&(l=l.substring(0,l.length-1));0<l.length&&(g=l.split(", "));
if(!q)g.push(x);else if(0<g.length)for(l=g.length-1;0<=l;l--)g[l]==x&&g.splice(l,1)}else h=b('<span class="prefix js-prefix"></span>'),l=e.find(".js-go-to-first-unread"),l.length?h.insertAfter(l):h.prependTo(e),q||g.push(x);h.text(g.join(", ")+": ");h.toggle(0!=g.length)}})};b(function(){vBulletin.conversation=vBulletin.conversation||{};let k=vBulletin.tabtools,a=b(".channel-content-widget .channel-conversation-list-wrapper"),n=b("#media-tab",a),e,q,w=!0,h=b("#video-tab",a),g,x,l=!0,y,D,z,A,E,G;var t=
a.find(".widget-tabs-nav .ui-tabs-nav > li");let H=t.filter(".ui-tabs-active"),I=H.index(),B,C="1"==t.parent().data("allow-history"),L=new vBulletin.history.instance(C);-1==I&&(I=0,H=t.first());B=H.find("> a").attr("href");var F=function(c){return a.offset().top+(a.outerHeight()-parseFloat(a.css("border-bottom-width")))-c.height()},J=function(c,r){var u=r.filter;r.pagination&&r.pagination.setOption("context",c);u.setOption("context",c);"undefined"!=typeof u.lastFilters&&0<b(".conversation-empty:not(.h-hide)",
c).length&&delete u.lastFilters},K=function(c,r,u,f,m,p,d){p=b(".conversation-list",c);return k.newTab(c,r,u,f,m,p,d,b.noop,C)};k.initTabs(a,L,t,C,I,B,[A,D,G],!0,function(c,r,u){var f=b(u),m="#"+f.prop("id");c=B==m;"#activity-stream-tab"!=m&&"#article-tab"!=m&&z&&A.toggleNewConversations(!1);"#topic-tab"!=m&&y&&D.toggleNewConversations(!1);if("#activity-stream-tab"==m||"#article-tab"==m)z?J(f,z):(z=K(f,a,!0,!0,c,null),A=z.filter),A.applyFilters(!1,!0);else if("#subscribed-tab"==m)E?J(f,E):(E=K(f,
a,!0,!0,c,null),G=E.filter),G.applyFilters(!1,!1);else if("#topic-tab"==m)y?J(f,y):(y=K(f,a,!0,!0,c),D=y.filter),D.applyFilters(!1,!0);else if("#media-tab"==m){if(e)w=!0;else{e=b(".conversation-toolbar-wrapper.scrolltofixed-floating",n);q=new vBulletin.scrollToFixed({element:e,limit:F(e)});var p=new vBulletin.history.instance(C);if(p.isEnabled()){c=p.getState();if(!c||b.isEmptyObject(c.data))c={from:"filter",page:1,tab:m,filters:vBulletin.getSelectedFilters(b("form.toolbar-filter-overlay",f))},p.setDefaultState(c,
document.title,location.href);p.setStateChange(function(d,M,N){d=p.getState();"filter"==d.data.from&&(p.log(d.data,d.title,d.url),m!=d.data.tab?vBulletin.selectTabByIndex.call(b(r).closest(".ui-tabs-nav"),r.index()):(d=b('.media-filter-overlay input[name="filter_time"][value="{0}"]'.format(d.data.filters.filter_time),f).prop("checked",!0),d.hasClass("js-default-checked")&&d.prop("defaultChecked")?b(".filtered-by .x",f).trigger("click"):d.trigger("change",[!0])))},"filter")}B==m&&(w=!1)}w&&0==f.find(".profileMediaDetailContainer .js-album-detail",
f).length&&vBulletin.media.loadGalleryById(f.find(".js-profile-media-container"),{nodeid:-2,channelid:pageData.channelid,pageno:1,dateFilter:b(".filter-options input[name=filter_time]:checked",f).val()||"time_lastweek",perpage:"default"},{complete:function(){b(".profile-toolbar .media-toolbar-filter",n).removeClass("h-hide");q.updateLimit(F(e))}})}else if("#video-tab"==m){if(g)l=!0;else{g=b(".conversation-toolbar-wrapper.scrolltofixed-floating",h);x=new vBulletin.scrollToFixed({element:g,limit:F(g)});
p=new vBulletin.history.instance(C);if(p.isEnabled()){c=p.getState();if(!c||b.isEmptyObject(c.data))c={from:"filter",page:1,tab:m,filters:vBulletin.getSelectedFilters(b("form.toolbar-filter-overlay",f))},p.setDefaultState(c,document.title,location.href);p.setStateChange(function(d,M,N){d=p.getState();"filter"==d.data.from&&(p.log(d.data,d.title,d.url),m!=d.data.tab?vBulletin.selectTabByIndex.call(b(r).closest(".ui-tabs-nav"),r.index()):(d=b('.media-filter-overlay input[name="filter_time"][value="{0}"]'.format(d.data.filters.filter_time),
f).prop("checked",!0),d.hasClass("js-default-checked")&&d.prop("defaultChecked")?b(".filtered-by .x",f).trigger("click"):d.trigger("change",[!0])))},"filter")}B==m&&(l=!1)}l&&0==f.find(".profileMediaDetailContainer .media-video-list",f).length&&vBulletin.media.loadGalleryById(f.find(".js-profile-media-container"),{nodeid:-1,channelid:pageData.channelid,pageno:1,dateFilter:b(".filter-options input[name=filter_time]:checked",f).val()||"time_lastweek",perpage:"default"},{complete:function(){b(".profile-toolbar .media-toolbar-filter",
h).removeClass("h-hide");x.updateLimit(F(g))}})}});t=b(".conversation-list",a);vBulletin.conversation.initPollEvents(t);vBulletin.conversation.initContentEvents(t);t.off("click",".js-comment-entry__post").on("click",".js-comment-entry__post",function(c){vBulletin.conversation.postComment.apply(this,[c,function(){A.updatePageNumber(1).applyFilters(!1,!0)}])});vBulletin.conversation.bindEditFormEventHandlers("all");b(document).offon("dblclick",".js-cell-topic a",c=>c.stopPropagation());b(document).offon("dblclick",
".js-cell-topic",vBulletin.conversation.editTopicTitle);b(document).offon("dblclick",".js-open-close-topic",vBulletin.conversation.openOrCloseTopic)})})(jQuery);
;

// ***************************
// js.compressed/tabs.js
// ***************************
/*/

/*
 This is intended to be self contained and should not refer to the
 vBulletin object, pageData or other framework.

 The filters for the toolbars are intimately connected to the tabs and are so included here.
 Not calling it tabfiltertools for brevity.

 This depends on the jquery ui tabs widget
*/
vBulletin.tabtools=function(t,y,F,G,H){function z(a){var b=$(".conversation-toolbar-wrapper",a);return"1"==(b.length?b:a).data("allow-history")}function A(a,b,l,f,n){var d=location.pathname.replace(/\/$/,"").replace(/\/page[0-9]+/,""),c=$(".toolbar-filter-overlay",a),k=I(c,!0);c=$(".pagenav-form .js-pagenum",a).val()||1;var p=$(".toolbar-search-form .js-filter-search",a).val()||"",e=$(a).closest(".canvas-widget"),g=z(a);g=new y.instance(g);e=e.data("widget-default-tab")||e.find(".ui-tabs-nav > li:first-child a").attr("href");
$.isEmptyObject(k)&&$(".conversation-toolbar .js-button-filters",a).each(function(){var h=$(".js-button-filter.js-checked:not(.js-default-checked)",this);h.length&&(k[h.data("filter-name")]=h.data("filter-name"))});l||(a=new RegExp("\\/("+f.join("|")+")/?$"),d=(a=d.match(a))?d.replace(new RegExp(a[0]),"/"+b):d+("/"+b));1<c&&g.isEnabled()&&(d+="/page"+c);l&&b&&e!="#"+b&&(k.tab=b,g.isEnabled()||(d+="?tab="+b));if(!g.isEnabled())return d+(n?"#"+n:"");p&&(k.q=p);b=$.param(k);return d+(b?"?"+b:"")+(n?
"#"+n:"")}function J(a,b,l,f,n,d){var c=$(this);if(c.length){var k=a instanceof y.instance;if(k&&a.isEnabled()){var p=d.create;d.create=function(g,h){var q=B(location.search,["_"]),w=Object.keys(q).length,u=K(c,f),v=a.getState();!(f&&1<w&&"undefined"!=typeof q.tab||!f&&0<w)||v&&!$.isEmptyObject(v.data)||a.setDefaultState({from:"tabs",tab:u},document.title,location.href);a.setStateChange(function(m){m=a.getState();if("tabs"==m.data.from){a.log(m.data,m.title,m.url);var C=l(m.data.tab),x=B(m.url,["tab",
"_"]);if(c.tabs("option","selected")!=C)L.call(c,C),$.isEmptyObject(x)||$(window).trigger("statechange.filter",["tabs",x]);else if($.isEmptyObject(x)){var r;m.data.tab&&(r=f?$(m.data.tab):$('.ui-tabs .ui-tabs-panel[data-url-path="'+m.data.tab+'"]'));r=r&&r.length&&r||$(c.closest(".canvas-widget").data("widget-default-tab"));m=$(".toolbar-filter-overlay .filter-options .js-default-checked",r);m.length?(m.prop("checked",!0).first().data("bypass-filter-display",!0).trigger("change",[!0]).data("bypass-filter-display",
null),$(".filtered-by",r).addClass("h-hide").find(".filter-text-wrapper").empty()):$(".conversation-toolbar .js-default-checked",r).first().trigger("click",[!0])}else $(window).trigger("statechange.filter",["tabs",x])}},"tabs");p.call(c[0],g,h)}}if(b&&k){var e=d.beforeActivate;d.beforeActivate=function(g,h){var q=h.newPanel,w=h.newTab;if(!1===e.call(this,g,h))return!1;h=f?q.attr("id"):w.find(".ui-tabs-anchor").data("url-path");var u=void 0;f||(u=[],c.find(".ui-tabs-nav > li > a, .widget-tabs-panel").each(function(v,
m){v=$(this).data("url-path");-1==$.inArray(v,u)&&u.push(v)}));if(!a.isEnabled())return q=A(q,h,f,u,n),location.href=q,!1;c.data("noPushState")?c.data("noPushState",null):(g={from:"tabs",tab:"#"+h},q=A(q,h,f,u),a.pushState(g,document.title,q))}}c.tabs(d);c.trigger("vb-tabinit")}return c}function D(a,b){return a.offset().top+(a.outerHeight()-parseFloat(a.css("border-bottom-width")))-b.height()}function M(a,b,l,f,n,d){f=$(".conversation-toolbar-wrapper.scrolltofixed-floating",a);var c=null,k=null,p=
null;b&&0<f.length&&(c=new H({element:f,limit:D(b,f)}));l&&(p=new G({context:a,allowHistory:n,onPageChanged:function(e,g){k.updatePageNumber(e);g||k.applyFilters(!1,!0,!1,!0)}}));k=new F({context:a,autoCheck:!1,scrollToTop:b,pagination:p,allowHistory:n,onContentLoad:d});return{$bar:f,$floating:c,pagination:p,filter:k}}function N(a){a.css("border-bottom","").filter(".stream-view.activity-view").find(".list-item-poll form.poll").each(function(b,l){$(this).is(":visible")&&$(".view-less-ctrl",this).hasClass("h-hide-imp")&&
O(this,3)})}function E(a){a&&(P(a),N(a))}var B=t.parseQueryString,P=t.truncatePostContent,O=t.conversation.limitVisiblePollOptionsInAPost,K=t.getSelectedTabHashOrPath,I=t.getSelectedFilters,L=t.selectTabByIndex;ensureFun=t.ensureFun;return{initTabs:function(a,b,l,f,n,d,c,k,p){l.removeClass("ui-state-disabled");J.call(a,b,f,function(e){e=e||d;return l.filter('li:has(a[href*="'+e+'"])').first().index()},k,a.find(".js-module-top-anchor").prop("id"),{active:n,beforeActivate:function(e,g){for(var h;h<
c.length;h++)c[h]&&c[h].hideFilterOverlay()},create:function(e,g){p($(this),g.tab,g.panel)},activate:function(e,g){p($(this),g.newTab,g.newPanel)}})},newTab:function(a,b,l,f,n,d,c,k,p){var e=M(a,b,l,f,p,function(){e.$floating&&e.$floating.updateLimit(D(b,e.$bar));E(d);ensureFun(c)()});n&&(l=e.filter,E(d),ensureFun(k)(),l.lastFilters={filters:l.getSelectedFilters($(".toolbar-filter-overlay",a))});return e},tabAllowHistory:z}}(vBulletin,vBulletin.history,vBulletin.conversation.filter,vBulletin.pagination,
vBulletin.scrollToFixed);
;

// ***************************
// js.compressed/media.js
// ***************************
vBulletin.precache(["saving"],["commentminchars"]);
vBulletin.media=function(d,k,r,E){function t(a){return a.is(".js-profile-media-container")?a:a.closest(".js-profile-media-container")}function w(a){return d(".js-profile-media-container",a)}function n(a=null){return z[t(a).data("key")]}function l(a){a=parseInt(a,10);Number.isNaN(a)&&(a=0);return a}function F(a){let b=a.data("photos-perpage")||50;if(A)return b;let c=a.is(":visible");c||a.removeClass("h-hide");let e=Math.floor(a.width()/128);c||a.addClass("h-hide");return 0==b%e||b<=e?b:b-b%e}function u(a,
b){let c=n(a);r.render({template:"profile_media_content",data:{userid:a.data("user-id"),pageno:b,perpage:a.data("perpage")},success:function(e){d(".js-mediacontent",a).html(e.template).removeClass("h-hide");d(".profileMediaDetailContainer",a).empty();x(a,!1);c.galleryData.currentMediaPage=b;v(a,"a");e=a.closest(".tabs").find(".widget-tabs-nav");e.length&&!k.isScrolledIntoView(e)&&d("html,body").animate({scrollTop:e.offset().top},"slow")},title_phrase:"profile_media"})}function y(a,b,c,e){d(a.currentTarget);
a=e.galleryData;var f=l(e.$mediaPageCount.html());let g=d(".profileMediaDetailContainer",c).is(":visible"),h=g?a.currentGalleryPage:a.currentMediaPage;b="current"==b?l(e.$mediaCurrentPage.val()):h+b;if(0<b&&b<=f)if(g){if(!a.currentNodeId&&!a.currentUserId)return!1;q(c,{pageno:b,perpage:"default"})}else u(c,b),c=c.closest(".tab"),e=e.filterHistory,a=k.makePaginatedUrl(location.href,b),c.length&&e.isEnabled()?(f=c.data("url-path"),b={from:"media_filter",page:b||1,tab:f?f:"#"+c.attr("id")},e.pushState(b,
document.title,a)):allowHistory&&(location.href=a);else B(e,h,f);return!1}function B(a,b,c){a.$mediaPrevPage.toggleClass("h-disabled",1>=b);a.$mediaNextPage.toggleClass("h-disabled",b>=c);a.$mediaCurrentPage.val(b);a.$mediaPageCount.text(c)}function v(a,b){if("a"==b){var c=".js-medialist";b="currentMediaPage"}else c="v"==b?".media-video-list":".js-album-detail",b="currentGalleryPage";c=d(c,a);a=n(a);b=a.galleryData[b];c=Number(c.data("totalpages"))||Math.max(b,1);B(a,b,c)}function G(a){let b=w(a),
c=n(b),e="1"==a.find(".conversation-toolbar-wrapper").data("allow-history"),f=new k.history.instance(e);c.allowHistory=e;c.filterHistory=f;f.isEnabled()&&f.setStateChange(function(g){g=f.getState();if("media_filter"==g.data.from){f.log(g.data,g.title,g.url);let h=a.closest(".ui-tabs"),m=h.find(".ui-tabs-nav > li").filter('li:has(a[href*="#{0}"])'.format(a.attr("id")));m.hasClass("ui-tabs-active")?u(b,g.data.page):k.selectTabByIndex.call(h,m.index())}},"media_filter")}function x(a,b){d(".profileMediaDetailContainer",
a).toggleClass("h-hide",!b);d(".profileMediaContainer",a).toggleClass("h-hide",b);d('.js-media-toggle[data-show-on="in-album"]',a).toggleClass("h-hide-imp",!b);d('.js-media-toggle[data-show-on="mediahome"]',a).toggleClass("h-hide-imp",b)}function q(a,b,c={}){let e=t(a),f=d(".profileMediaDetailContainer",e),g=n(e).galleryData;a={nodeid:g.currentNodeId,userid:g.currentUserId,channelid:g.currentChannelid,pageno:1,dateFilter:e.find(".media-filter-overlay input[name=filter_time]:checked").val(),albumid:0};
let h=d(".media-tab");b=d.extend({},a,b);isNaN(b.nodeid)||("default"==b.perpage&&(b.perpage=F(f)),0!=b.nodeid&&r.render({template:-1==b.nodeid?"profile_media_videolist":"profile_textphotodetail",data:b,success:function(m){let H=b.pageno;g.currentNodeId=b.nodeid;g.currentUserId=b.userid;g.currentGalleryPage=H;f.html(m.template);f.addClass("list-item").attr("data-nodeid",b.nodeid);d(".profile-media-uploadphotos",f).on("click",I);x(e,!0);b.perpage&&(h.data("perpage",b.perpage),h.data("callbacks",c));
k.initFlexGridFixLastRowAll();v(e,-1==b.nodeid?"v":"p");k.ensureFun(c.success)()},after_error:function(){k.ensureFun(c.error)()},complete:function(){k.ensureFun(c.complete)()},title_phrase:"profile_media"}))}function I(a){let b=d(a.currentTarget),c=p.getUploadedPhotosDlg(!1,b.closest(".js-album-detail"));(a=l(c.data("nodeid")))&&r.render({template:"media_addphotos",data:{nodeid:a},success:function(e){c.html(e.template);p.initializePhotoUpload(c.parent());e=c.find(".js-save-button");e.offon("click",
f=>J(f,c,t(b)));c.find(".js-cancel-button").offon("click",function(f){c.dialog("close")});p.relocateLastInRowClass(c.find(".photo-item-wrapper"));0<d(".photo-display .photo-item-wrapper:not(.h-hide)",c).length?(p.setUploadButtonText(c,"upload_more"),e.show()):e.hide();c.dialog("open");p.adjustPhotoDialogForScrollbar(c)},after_error:function(){c.dialog("close")},title_phrase:"profile_media"})}function J(a,b,c){let e=d(a.currentTarget),f=e.closest("form");b=d(a.target).closest(".profile-media-photoupload-dialog");
if(0<f.length){e.closest(".photo-display-container").find(".photo-item-wrapper:not(.h-hide)").each(function(h,m){h=parseInt(d(m).find(".filedataid").val(),10);isNaN(h)||(f.append('<input type="hidden" name="filedataid[]" value="'+h+'"/>'),d('<input type="hidden" name="title_'+h+'" />').val(d(m).find("textarea").val()).appendTo(f))});let g=d("button",f).prop("disabled",!0);r.ajax({url:f.attr("action"),data:f.serializeArray(),success:function(){b.dialog("close");q(c,n(c).galleryData.currentFilter)},
complete:function(){g.prop("disabled",!1)},title_phrase:"profile_media"})}else b.dialog("close")}function C(a){let b=t(a),c=d(".profileMediaContainer",b);c.is(":visible")||(c=d(".profileMediaDetailContainer",b));a={nodeid:l(a.data("nodeid"))||l(c.attr("data-nodeid")),userid:l(c.data("userid")),channelid:l(c.data("channelid")),albumid:l(a.data("albumid"))};0<a.nodeid&&(a.userid=0);return a}function D(a){let b=K(a);a.offon("click",".profile-media-backbtn",c=>{x(a,!1);a.find(".filtered-by").addClass("h-hide").find(".filter-text-wrapper").empty();
v(a,"a")});a.offon("change",".mediaCurrentPage",c=>y(c,"current",a,b));a.offon("click",".mediaPreviousPage",c=>y(c,-1,a,b));a.offon("click",".mediaNextPage",c=>y(c,1,a,b));a.offon("click",".albumLink",c=>{c=d(c.currentTarget);let e=C(c);e.pageno=1;e.perpage="default";b.galleryData.currentFilter=e;q(c,e)});L(a);M(a);d(".profileMediaContainer",a).length||N(a)}function K(a){let b=a.data("key");b||(b=O++,a.data("key",b));let c={};c.$mediaCurrentPage=d(".mediaCurrentPage",a);c.$mediaPageCount=d(".mediaPageCount",
a);c.$mediaPrevPage=d(".mediaPreviousPage",a);c.$mediaNextPage=d(".mediaNextPage",a);c.allowHistory=!1;c.filterHistory={};c.galleryData={mediaTypeFilter:!1,currentMediaPage:l(c.$mediaCurrentPage.val())||1,currentGalleryPage:1,currentNodeId:0,currentUserId:0,currentChannelid:0};return z[b]=c}function L(a){let b=a.closest(".tab");if(b.length){G(b);let c=a.closest(".canvas-widget").find(".js-module-top-anchor").attr("id");b.offon("click",".toolbar-filter",function(e){let f=d(".filter-wrapper",this);
f.toggleClass("selected");f.attr("aria-expanded",f.is(".selected"));d(".js-expanded-indicator",this).toggleClass("fa-caret-down fa-caret-up");d(e.target).closest(".conversation-toolbar-wrapper").find(".toolbar-filter-overlay").slideToggle("slow",function(){if(d(this).is(":visible")){d("body").off("click.media_filter").on("click.media_filter",function(h){0==d(h.target).closest(".toolbar-filter-overlay").length&&0==d(h.target).closest(".toolbar-filter").length&&(d("body").off("click.media_filter"),
d(".toolbar-filter",b).trigger("click"))});var g={};k.isScrolledIntoView(this,g)||d("html,body").animate({scrollTop:"+="+Math.abs(g.bottom)},"fast")}else d("body").off("click.media_filter")})});d("form.media-filter-overlay",b).trigger("reset");b.offon("change",".media-filter-overlay input[type=radio]",function(e,f){var g=n(w(b));let h=g.filterHistory;var m=h.isEnabled();if(!m&&g.allowHistory)return url=k.makePaginatedUrl(location.href,1),location.href=k.makeFilterUrl(url,this.name,this.value,b,c),
!0;e=C(d(e.target));b.data("perpage")&&(e.perpage=b.data("perpage"));q(a,e,b.data("callbacks"));d(this).data("bypass-filter-display")||k.conversation.displaySelectedFilterText(this,this.value);m&&!f&&(g=k.getSelectedFilters(d("form.toolbar-filter-overlay",b)),f=this.name,m=this.value,e=d(".conversation-toolbar-wrapper .filtered-by",b),g={from:"filter",page:1,tab:b.data("url-path")?b.data("url-path"):"#"+b.attr("id"),filters:g,filtervalue:m,filtername:f},e.data("reset")?url=location.pathname.replace(/\/page[0-9]+/,
""):(url=k.makePaginatedUrl(location.href,1),url=k.makeFilterUrl(url,f,m,b)),h.pushState(g,document.title,url),e.data("reset",null))});b.offon("click",".filtered-by .js-remove-filter",function(e){var f=n(w(b));e=d(this).closest(".filtered-by");let g=d(this).closest(".filter-text"),h=g.data("filter-name");if(!f.filterHistory.isEnabled()&&f.allowHistory)return location.href=k.makeFilterUrl(location.href,h,g.data("filter-value"),b,c),!1;$defaultSelectedFilter=d(".toolbar-filter-overlay .filter-options input[name={0}]".format(h),
b).prop("checked",!1).filter(".js-default-checked");g.remove();f=e.find(".filter-text").length;0==f?(e.addClass("h-hide"),e.data("reset",!0)):1==f&&e.find(".clear-all").addClass("h-hide");1==$defaultSelectedFilter.length&&($defaultSelectedFilter.data("bypass-filter-display",!0),$defaultSelectedFilter.trigger("click"),$defaultSelectedFilter.data("bypass-filter-display",null))})}}function M(a){let b=d(document),c=!1,e;a.offon("click",".profile-media-createvideo, .profile-media-upload",function(f){e=
d(f.currentTarget).is(".profile-media-upload")?"gallery":"video";c?c.dialog("open"):c=E.openModalDialog(d(".profileMediaEditContainer",a),{width:800,title:"profile_media",dialogClass:"js-profile-media",onOpen:function(g){k.ckeditor.initEditor(g.find(".js-ckeditor-init-on-focus"));p.initializePhotoUpload(g);let h="b-content-entry-panel__content--"+e;g.find('.b-toolbar__item[data-panel="'+h+'"]:not(.b-toolbar__item--active)').trigger("click");k.ckeditor.initEditorComponents(g);b.data("gallery-container",
d("."+h,g))},onClose:function(){b.data("gallery-container",null)}})});a.offon("afterSave",".js-album-detail",function(f,g){f=d(f.currentTarget);q(f,n(f).galleryData.currentFilter);return!1});a.offon("afterCancel",".js-album-detail",function(f){d(f.currentTarget).closest(".js-album-detail").find(".js-photo-preview").removeClass("h-hide-imp");return!0});b.offon("afterSave",".js-profile-media",function(f,g){if("b-content-entry-panel__content--gallery"==d(".b-toolbar__item--active",this).data("panel")){f=
l(d(".js-medialist",a).data("totalcount"));let h=l(d(".profileMediaContainer",a).data("albums-perpage"));f=Math.ceil((f+1)/h);g.alert&&k.alert("media",g.alert,"alert");u(a,f)}else u(a,1);return!1})}function N(a){var b=d(".profileMediaDetailContainer",a);let c=l(b.data("channelid")),e=l(b.data("nodeid"));if(c&&e){let f=n(a);b=l(b.find(".albumSlideShowPageNo").val())||1;f.galleryData.currentNodeId=e;f.galleryData.currentChannelid=c;f.galleryData.currentGalleryPage=b;v(a,"p");A=!0}}let p;if(!k.pageHasSelectors(["#media-tab",
"#video-tab",".album-widget"]))return!1;let O=1,z={};var A=!1;d(()=>{p=k.upload;let a=d(document);$mediacontainers=d(".js-profile-media-container");a.on("vb-instrument",b=>{b=d(b.target);b.is(".js-profile-media-container")&&D(b)});$mediacontainers.each((b,c)=>D(d(c)));k.initFlexGridFixLastRowAll()});return{loadGalleryById:q,getCurrentPage:function(a){return l(n(a).$mediaCurrentPage.val())}}}(jQuery,vBulletin,vBulletin.ajaxtools,vBulletin.dialogtools);
;

// ***************************
// js.compressed/sb_activity.js
// ***************************
vBulletin.precache(["blog_memberblogLabel","forum"],[]);
(function(b,w){if(!vBulletin.pageHasSelectors([".forum-activity-stream-widget",".bloghome-widget",".search-widget"]))return!1;b(function(){vBulletin.conversation=vBulletin.conversation||{};let h=b(".activity-stream-widget"),x,q,y,p,k,B,C;if(h.hasClass("forum-activity-stream-widget")||h.hasClass("bloghome-widget")){var l=h.find(".widget-tabs-nav .ui-tabs-nav > li"),z=l.filter(".ui-tabs-active"),A=z.index(),r={},D="1"==l.parent().data("allow-history"),Q=new vBulletin.history.instance(D),E=!1,F=null,
G=null;-1==A&&(A=0,z=l.first());var t=z.find("> a").attr("href");var H=function(c,a){var f=a.filter;a.pagination&&a.pagination.setOption("context",c);f.setOption("context",c);"undefined"!=typeof f.lastFilters&&0<b(".conversation-empty:not(.h-hide)",c).length&&delete f.lastFilters},I=function(c,a,f,d,e,g,m){var n=b(".conversation-list",c);return w.newTab(c,a,d,e,g,n,m,b.noop,f)},K=function(c,a){vBulletin.conversation.filter({context:a,autoCheck:!1,scrollToTop:c,pagination:!1,allowHistory:!1,tabParamAsQueryString:!0,
beforeApplyFilters:function(){J();return!1},afterResetFilters:function(){J()}})},L=function(c){var a=b(".toolbar-pagenav",c);0<a.length&&new vBulletin.pagination({context:c,allowHistory:void 0,onPageChanged:function(f,d){if(!d){d=b(".js-button-filter-my.js-checked",c).data("filter-value");var e=b(".js-button-filter-display-blogs.js-checked",c).data("filter-value"),g=a.closest(".activity-stream-widget");u(g,c,f,d,!1,!0,e)}}})},M=function(c,a){vBulletin.memberChannel.updateToolbarPagination(c);vBulletin.memberChannel.updateToolbarButtonPressState(c);
a&&K(b(".bloghome-widget"),b("#memberblog-tab"));a=c.find(".js-button-filter-display-blogs.js-checked").data("filter-value")||"display_grid";c.find(".js-flexgrid").toggleClass("b-groupgrid b-flexgrid","display_grid"==a);vBulletin.initFlexGridFixLastRowAll(!0);vBulletin.initFrameImagesWithColor()},J=function(){var c=b("#memberblog-tab .js-pagenum").val()||1,a=b(".js-button-filter-my.js-checked").data("filter-value"),f=b(".js-button-filter-display-blogs.js-checked").data("filter-value");u(F,G,c,a,!1,
!1,f)},u=function(c,a,f,d,e,g,m){f=f||1;d=d||"show_all";m=m||"display_grid";var n=vBulletin.makePaginatedUrl(location.href,f);!e&&k.isEnabled()&&(n=vBulletin.makeFilterUrl(n,"filter_blogs",d,a),e=k.getState(),k[e&&e.data&&e.data.from&&"filter_blogs"!=e.data.from?"setDefaultState":"pushState"]({from:"filter_blogs",page:f,filters:{filter_blogs:d}},document.title,n));n={tab:a.prop("id"),filter_blogs:"show_all"==d?void 0:d,display_blogs:"display_grid"==m?void 0:m};var v=b(".toolbar-filter-overlay",a);
e=v.find('input[name="filter_sort"]:checked').val();v=v.find('input[name="filter_order"]:checked').val();vBulletin.AJAX({call:"/ajax/render/blogmember_tab",data:{from:f,my:d,display_blogs:m,noToolbar:g,page:n,blogChannelId:c.data("blog-channel-id"),sort_field:e,sort_order:v},error_phrase:"unable_to_contact_server_please_try_again",success:function(N){let O=b(N);O.filter(".conversation-toolbar-wrapper").length?(a.html(N),L(a),a.trigger("vb-instrument")):(b(".blogmember-list",a).hide().replaceWith(O).show(),
b(".conversation-toolbar-wrapper",a).removeClass("h-hide"));M(c,!E);E=!0}})};w.initTabs(h,Q,l,D,A,t,[p,q],!0,function(c,a,f){F=c;G=f;var d=b(f);a="#"+d.prop("id");f=t==a;a in r||(r[a]=w.tabAllowHistory(d));p&&"#activity-stream-tab"!=a&&"#article-tab"!=a&&p.toggleNewConversations(!1);q&&"#subscribed-tab"==a&&q.toggleNewConversations(!1);if("#memberblog-tab"==a){d.off("click",".js-button-filter").on("click",".js-button-filter",function(e,g){e=b(this);var m=b(".js-button-filter-my.js-checked").data("filter-value"),
n=b(".js-button-filter-display-blogs.js-checked").data("filter-value");e.is(".js-button-filter-my")?(m=e.data("filter-value"),b(".js-button-filter-my").removeClass("js-checked")):(n=e.data("filter-value"),b(".js-button-filter-display-blogs").removeClass("js-checked"));e.addClass("js-checked");u(c,d,1,m,g,!0,n)});K(b(".bloghome-widget"),b("#memberblog-tab"));if(!k&&(k=vBulletin.history.instance(r[a]),k.isEnabled())){f=k.getState();if(!f||b.isEmptyObject(f.data))f={from:"filter_blogs",page:Number(b(".pagenav-form .defaultpage",
d).val())||1,tab:a,filters:{filter_blogs:b(".js-button-filter-my.js-checked",d).data("filter-value"),filter_display_blogs:b(".js-button-filter-display-blogs.js-checked",d).data("filter-value")}},k.setDefaultState(f,document.title,location.href);k.setStateChange(function(e){e=k.getState();if("filter_blogs"==e.data.from||"display_blogs"==e.data.from){k.log(e.data,e.title,e.url);var g=c.tabs("option","selected");c.find(".ui-tabs-nav > li").eq(g).find("a").attr("href")!=e.data.tab?(e=getTabIndexByHash(e.data.tab),
vBulletin.selectTabByIndex.call(c,e)):u(c,d,e.data.page,e.data.filters.filter_blogs,!0,!0,e.data.filters.display_blogs)}},"filter")}t==a&&L(d);M(c,!1);if(!b(".conversation-list",d).hasClass("dataLoaded")){if(t==a&&!C)return C=!0,!1;b(".conversation-empty",d).addClass("h-hide");u(c,d)}}else if("#activity-stream-tab"==a||"#article-tab"==a)p?H(d,y):(y=I(d,h,r[a],!0,!0,f,null),p=y.filter),p.applyFilters(!1,!0);else if("#subscribed-tab"==a)q?H(d,x):(x=I(d,h,r[a],!0,!0,f,null),q=x.filter),q.applyFilters(!1,
!0);else if("#forum-tab"==a){if(d.hasClass("dataLoaded"))return!1;if(t==a&&!B)return B=!0,!1;b(".conversation-empty",d).addClass("h-hide");vBulletin.AJAX({call:"/ajax/render/display_Forums_tab",data:{isAjaxTemplateRenderWithData:!0,channelDepth:d.data("channelDepth")},success:function(e){d.html(e.template).addClass(function(){var g=b(".conversation-empty",this);if(0==g.length)return"dataLoaded";g.removeClass("h-hide");return""})}})}});var P=0;h.find(".ui-tabs-nav li").each(function(){P+=b(this).width()});
l=h.find(".ui-tabs-nav").width();P>l&&h.find(".widget-tabs-nav, .module-title").height(h.find(".ui-tabs-nav").height())}vBulletin.truncatePostContent(".search-widget");l=b(".conversation-list",h);vBulletin.conversation.initPollEvents(l);vBulletin.conversation.initContentEvents(l);l.off("click",".js-comment-entry__post").on("click",".js-comment-entry__post",function(c){vBulletin.conversation.postComment.apply(this,[c,function(){p.updatePageNumber(1).applyFilters(!1,!0)}])});vBulletin.conversation.bindEditFormEventHandlers("all")})})(jQuery,
vBulletin.tabtools);
;

// ***************************
// js.compressed/hv.js
// ***************************
vBulletin.hv=((d,f,h)=>{function l(a){var b=d(".humanverify.humanverify_image");if(0<b.length)m(b),a&&b.find(".imageregt").trigger("focus");else if(0<d(".js-humanverify-recaptcha2").length)window.grecaptcha&&grecaptcha.ready(()=>{grecaptcha.reset()});else if(b=d(".js-humanverify-recaptcha3-response"),0<b.length)b.val("");else{d(".js-humanverify-turnstile-response").each((e,k)=>{f.ready("hvlibraryready").then(()=>{let g=d(k).data("cfwidgetid");g&&turnstile.reset(g)})});var c=d(".humanverify.humanverify_question");
0<c.length&&h.render({template:"humanverify",data:{action:"register"},success:e=>{e=d(e.template);c.replaceWith(e);a&&e.find(".answer").trigger("focus")}})}}function n(a){let b=d(".humanverify_image",a);d(".imagereg, .refresh_imagereg",b).offon("click",()=>m(b)).removeClass("h-hide")}function m(a){h.ajax({call:"/ajax/api/hv/generateToken",success:function(b){b=b.hash;d("input.hash",a).val(b);d(".imagereg",a).attr("src",pageData.baseurl+"/hv/image?hash="+b);d(".imageregt",a).val("")},api_error:()=>
{}});return!1}function p(a){f.ready("hvlibraryready").then(()=>{let b=a.find(".js-humanverify-turnstile-response"),c=turnstile.render(b.get(0),{});b.data("cfwidgetid",c)})}function q(a,b){try{f.ready("hvlibraryready").then(()=>{grecaptcha.execute(a.data("key"),{action:a.data("action")}).then(c=>{a.val(c);b.trigger("submit")})})}catch(c){f.dialogtools.error("error",["phrase_passthrough",c])}}window.recaptcha2callback=a=>{d(".js-humanverify-recaptcha2-response").val(a)};window.hvlibraryready=a=>{f.ready("hvlibraryready").resolve()};
return{reset:l,resetOnError:function(a,b,c){return h.hasError(a,/^humanverify_.*/)?(c.after_error=h.runBeforeCallback(c.after_error,function(){l(!0)}),h.showApiError(a,b,c),!1):!0},initForm:function(a,b){let c=a.find(".js-humanverify-recaptcha3-response");if(0<c.length){let e=f.ensureFun(b);b=(k,...g)=>""==c.val()?(q(c,a),!1):e(k,...g)}p(a);n(a);a.on("submit",b)},initAjaxForm:function(a,b){let c=a.find(".js-humanverify-recaptcha3-response");if(0<c.length){let e=f.ensureFun(b.beforeSubmit);b.beforeSubmit=
(k,g,r)=>{if(!1===e(k,g,r))return!1;if(""!=c.val())return!0;q(c,g);return!1}}p(a);n(a);h.initForm(a,b)}}})(jQuery,vBulletin,vBulletin.ajaxtools);
;

// ***************************
// js.compressed/css_b_comp_menu_horizontal.js
// ***************************
vBulletin.precache(["more_options","advanced_search","search","more"],[]);
vBulletin.CompMenuHorizontal=function(d,r){function k(a,c,b){a.each(function(){var e=d(this);d.each(c,function(f,g){e.is("."+g)&&(e.removeClass(g),f=e.data("removed-classes")||[],-1==d.inArray(g,f)&&f.push(g),e.data("removed-classes",f))});d.each(b,function(f,g){e.is("."+g)||(e.addClass(g),f=e.data("added-classes")||[],-1==d.inArray(g,f)&&f.push(g),e.data("added-classes",f))})})}function q(a){a.each(function(){var c=d(this),b=c.data("added-classes")||[],e=c.data("removed-classes")||[];b.length&&c.removeClass(b.join(" "));
e.length&&c.addClass(e.join(" "))})}function p(a){x.push(a)}function y(a,c,b){x.map(e=>e(a,c,b))}function t(a,c){if("dropdown"==c){var b=a.data("dropdown-icon-classes")||"",e=b?" b-comp-menu-dropdown__trigger--icon-trigger":"";e=(a.data("dropdown-trigger-classes")||"")+e;let g=a.data("dropdown-trigger-phrase")||"more_options";b='<div class="b-comp-menu-dropdown js-comp-menu-dropdown '+(a.data("dropdown-menu-classes")||"")+'"> <div class="b-comp-menu-dropdown__trigger js-comp-menu-dropdown__trigger js-button '+
e+'" tabindex="0"> <span class="'+b+' b-comp-menu-dropdown__trigger-icon"> '+vBulletin.phrase.get(g)+" </span>  </div> </div>";let h=d(b);h.insertAfter(a);y(a,h,c);b=a.find("li");e=a.find("a");d.each(["h-right","h-left"],function(l,m){a.is("."+m)&&h.addClass(m)});c=a.data("dropdown-content-classes");var f=["b-comp-menu-dropdown__content","js-comp-menu-dropdown__content"];c=c?c.split(" "):[];d.each(c,function(l,m){f.push(m)});k(a,"h-margin-top-s h-right b-comp-menu-horizontal channel-tabbar-list h-hide-on-small nav-list".split(" "),
f);k(b,["h-margin-top-xs","b-post-control"],["b-comp-menu-dropdown__content-item"]);k(e,["h-left"],["h-block"]);a.appendTo(h);vBulletin.CompMenuDropdown.init();a.data("is-dropdown-menu",1)}else vBulletin.CompMenuDropdown.updateMenuAsSelectElement(),b=a.find("li"),e=a.find("a"),q(a),q(b),q(e),b=a.closest(".js-comp-menu-dropdown"),vBulletin.CompMenuDropdown.setMenuColumnCount(b,a,1),a.removeClass("b-comp-menu-dropdown__content--left b-comp-menu-dropdown__content--right"),a.insertAfter(b),y(a,b,c),(c=
a.next(".vb-select-el"))&&c.length&&c.selectBox("destroy").remove(),b.remove(),a.data("is-dropdown-menu","")}function u(a){if(a.length){let c=d("body"),b=c.is(".l-small"),e=c.is(".l-xsmall");a.each((f,g)=>{f=d(g);g=f.find("li").not(".b-post-control--disabled").length;var h=!1;isDropdown=f.data("is-dropdown-menu");if(!(f.is(".js-comp-menu-column")||isDropdown&&f.closest(".js-comp-menu-dropdown").is(".b-comp-menu-dropdown--open"))){isDropdown&&(t(f,"horizontal"),isDropdown=!1);var l=h=!1;for(let m of[f,
f.parent()])if(m.is(".js-shrink-event-parent")&&(h=!0,"need_shrink"==r.checkElementShrinkRequirement(m))){l=!0;break}f.is(".js-comp-menu-dropdown__content--main-menu")&&!l&&(h=!0,"need_shrink"==r.checkElementShrinkRequirement(d(".js-channel-subtabbar-list"))&&(l=!0));h=h?l:"need_shrink"==r.checkElementShrinkRequirement(f)?!0:void 0}(b&&f.is(".js-comp-menu--dropdown-on-small")||e&&f.is(".js-comp-menu--dropdown-on-xsmall")||h)&&0<g?isDropdown||t(f,"dropdown"):isDropdown&&t(f,"horizontal")})}}var v=
vBulletin.ensureObj("jsexec.css_b_comp_menu_horizontal",{exec:0,init:0});v.exec++;var x=[];p(function(a,c,b){a.is(".js-comp-menu-dropdown__content--main-menu")&&("dropdown"==b?(b=a.find(".current").addClass("b-comp-menu-dropdown__content-item--current"),c.addClass("b-comp-menu-dropdown--main-menu").find(".js-comp-menu-dropdown__trigger").addClass("b-comp-menu-dropdown__trigger--icon-trigger").html('<span class="b-icon b-icon__hamburger b-comp-menu-dropdown__trigger-icon"></span>'),a.find("li").first().addClass("b-comp-menu-dropdown__content-item--divider"),
c='<li class="js-search-item b-comp-menu-dropdown__content-item--no-hover js-comp-menu-dropdown__content-maintain-menu"><form action="'+d("#searchForm").attr("action")+'" class="search-box"><input type="text" autocomplete="off" class="b-form-input__input search-term" placeholder="'+vBulletin.phrase.get("search")+'..." name="q"><button title="'+vBulletin.phrase.get("search")+'" class="search-btn b-button b-button--primary" type="submit"><span class="b-icon-fa b-icon-fa--24 fa-solid fa-magnifying-glass"></span></button></form></li><li class="js-search-item"><a href="'+
pageData.baseurl+'/search">'+vBulletin.phrase.get("advanced_search")+"</a></li>",d(c).prependTo(a),d(".js-channel-subtabbar-list li").addClass("js-subtabbar-item b-comp-menu-dropdown__content-item--indent1").insertAfter(b),d(".js-channel-subtabbar").addClass("h-hide")):(a.find("li").removeClass("b-comp-menu-dropdown__content-item--divider b-comp-menu-dropdown__content-item--current b-comp-menu-dropdown__content-item--indent1"),a.find(".js-search-item").remove(),a.find(".js-subtabbar-item").appendTo(d(".js-channel-subtabbar-list")),
d(".js-channel-subtabbar").removeClass("h-hide")))});p(function(a,c,b){a.is(".js-footer-nav-list")&&("dropdown"==b?(k(a,["h-right"],[]),k(c,[],["js-select-on-xsmall"]),c=d("<li></li>").append(c).appendTo(".js-footer-chooser-list"),a.data("vb-remove-li",c)):(a.insertAfter(".js-footer-chooser-list"),a.data("vb-remove-li").remove()))});p(function(a,c,b){"dropdown"==b?(b=a.find(".js-comp-menu--exclude-from-dropdown"),0<b.length&&(c=d("<ul />").addClass(a.get(0).className).removeClass("js-comp-menu-horizontal js-comp-menu--dropdown-on-xsmall js-comp-menu--dropdown-on-small b-comp-menu-dropdown--inactive").insertAfter(c),
Object.assign(c[0].dataset,a[0].dataset),a.data("vb-exclude-item-container",c),b.each(function(e,f){e=d(this);d("<li />").addClass("js-excluded-item-marker h-hide-imp").data("vb-excluded-item",e).insertAfter(e)}),b.appendTo(c))):(c=a.data("vb-exclude-item-container"),b=a.find(".js-excluded-item-marker"),c&&c.length&&0<c.length&&0<b.length&&(b.each(function(e,f){e=d(this);e.data("vb-excluded-item").insertAfter(e)}),b.remove(),a.data("vb-exclude-item-container",!1),c.remove()))});p(function(a,c,b){function e(n){n=
d(this).closest("li");h.removeClass("b-comp-menu-dropdown__content-item--current ui-tabs-active ui-state-active ui-state-hover ui-state-default");n.addClass("b-comp-menu-dropdown__content-item--current")}if(a.is(".js-module-tab-menu")){var f=a.closest(".widget-tabs-nav, .js-widget-tabs-nav"),g=f.find(".module-title, .js-module-title"),h=a.find("li"),l=h.filter(".ui-state-active"),m=a.find("a");f.addClass("js-widget-tabs-nav");g.addClass("js-module-title");"dropdown"==b?((a.is(".js-profile-tabs-nav")||
a.is(".js-subscribe-tabs-nav"))&&d("<div />").addClass("js-profile-menu-wrapper widget-tabs-nav").insertAfter(a).append(c).append(a),k(a,["ui-tabs-nav","ui-helper-reset","ui-helper-clearfix","ui-widget-header","ui-corner-all"],[]),k(c,[],["js-select-when-dropdown"]),k(f,["widget-tabs-nav"],["widget-tabs-nav-background"]),k(g,["module-title"],[]),k(h,"ui-helper-reset ui-helper-clearfix ui-widget-header ui-corner-all ui-corner-bottom ui-corner-top ui-corner-right ui-corner-left ui-corner-br ui-corner-bl ui-corner-tr ui-corner-tl".split(" "),
[]),k(m,["ui-tabs-anchor","h-block"],[]),l.length?l.addClass("b-comp-menu-dropdown__content-item--current"):setTimeout(function(){h.filter(".ui-state-active").addClass("b-comp-menu-dropdown__content-item--current");var n=a.next(".vb-select-el"),z=0;if(n&&n.length){h.each(function(B,C){z=B;if(d(C).is(".ui-state-active"))return!1});var A=n.is(".selectBox");A&&n.selectBox("destroy");n.find(".js-noop-label").remove();n.get(0).selectedIndex=z;A&&n.selectBox()}},0),h.removeClass("ui-state-default ui-tabs-active ui-state-active ui-state-hover"),
m.off("click.vbmoduletabs").on("click.vbmoduletabs",e),c.data("add-classes-to-select-el","h-margin-vert-m h-margin-horiz-xl")):(h.filter(function(){return"true"==d(this).attr("aria-selected")}).removeClass("b-comp-menu-dropdown__content-item--current").addClass("ui-tabs-active ui-state-active"),m.off("click.vbmoduletabs"),q(f),q(g),b=a.parent(),b.is(".js-profile-menu-wrapper")&&(a.insertAfter(b),c.insertAfter(b),b.remove()))}});p(function(a,c,b){if(a.is(".js-tabbed-pane__tabs")){var e=a.find("li"),
f=e.filter(".b-tabbed-pane__tab--selected");a.find("a");"dropdown"==b?(d("<div />").addClass("js-tabbed-pane__tabs-wrapper b-tabbed-pane_tabs b-tabbed-pane__tabs--standard").insertAfter(a).append(c).append(a),k(a.parent(),[],["js-comp-menu-dropdown__content"]),k(c,[],["js-select-when-dropdown"]),k(e,[],["b-comp-menu-dropdown__content-item"]),f.addClass("b-comp-menu-dropdown__content-item--current"),c.data("add-classes-to-select-el","h-margin-horiz-xl h-margin-vert-m")):(e.removeClass("b-comp-menu-dropdown__content-item--current"),
b=a.parent(),b.is(".js-tabbed-pane__tabs-wrapper")&&(a.insertAfter(b),c.insertAfter(b),b.remove()))}});p(function(a,c,b){a.is(".js-groupblog-admin-menu")&&(a.closest(".js-blog-admin-left"),a=a.find("li").filter(".sgAdminActive, .blogAdminActive"),"dropdown"==b&&(k(c,[],["js-select-on-xsmall"]),a.addClass("b-comp-menu-dropdown__content-item--current")))});p(function(a,c,b){if(a.is(".js-sharing-menu")){var e=a.find("li");"dropdown"==b?(b=a.prevAll(".userinfo"),1==b.length&&(c.appendTo(b),a.data("vb-moved-to-userinfo",
"1")),k(a,["b-sharing-menu--horizontal"],[]),k(c,[],["h-align-bottom"]),k(e,[],["b-comp-menu-dropdown__content-item--no-hover","js-comp-menu-dropdown__content-maintain-menu"])):("1"==a.data("vb-moved-to-userinfo")&&(b=c.parent(".userinfo"),a.insertAfter(b).data("vb-moved-to-userinfo","0")),q(e))}});let w=()=>u(d(".js-comp-menu-horizontal, .js-comp-menu-column"));d(document).on("vb-tabinit",a=>{u(d(a.target).find(".js-comp-menu-horizontal, .js-comp-menu-column"))});d(function(){vBulletin.phrase.register(d("[data-dropdown-trigger-phrase]").map(function(a,
c){return d(c).data("dropdown-trigger-phrase")}).get());u(d(".js-comp-menu-horizontal, .js-comp-menu-column").filter(":not(.ui-tabs-nav)"));1>v.init&&(r.registerCallback(w),d(document).on("vb-loadnewposts vb-filterposts",w));v.init++});return{registerMenuChangeFilter:p,checkHorizontalMenuState:w,convertDropdownProgressive:function(a){if(!(1>a.$children.length||1!=a.$parent.length)){a.needsShrink=a.needsShrink||function(){return"need_shrink"==r.checkElementShrinkRequirement(a.$parent)};a.copyChild=
a.copyChild||function(g){var h=g.find("> a");g=d('<a href="#"></a>');g.html(h.html());g.attr("href",h.attr("href"));g.on("click",function(){h.trigger("click");return!1});return g};var c=a.$children.filter(function(){return""!=d(this).text()});if(!(1>c.length)){var b=a.$parent.find(".js-progressive-dropdown-menu");if(1>b.length){b=d('<li class="b-top-menu__item js-shrink-event-child js-progressive-dropdown-menu h-hide-imp"> \t<div class="b-comp-menu-dropdown b-comp-menu-dropdown--sitebuilder js-comp-menu-dropdown">\t\t<div class="b-comp-menu-dropdown__trigger js-comp-menu-dropdown__trigger js-button" tabindex="0"> \t\t\t<span class="b-icon b-icon__ellipsis b-comp-menu-dropdown__trigger-icon">'+
vBulletin.phrase.get("more")+'</span> \t\t</div> \t\t<ul class="b-comp-menu-dropdown__content js-comp-menu-dropdown__content"> \t\t</ul> \t</div> </li>');b.insertAfter(c.last());var e=b.find(".js-comp-menu-dropdown__content");c.each(function(g,h){h=d(this);var l=a.copyChild(h);d('<li class="b-comp-menu-dropdown__content-item h-hide-imp"></li>').append(l).appendTo(e).data("vb-progressive-item-num",g);h.data("vb-progressive-item-num",g)});vBulletin.CompMenuDropdown.init()}var f=b.find(".b-comp-menu-dropdown__content-item");
if(a.removeMenu||!a.needsShrink())c.removeClass("h-hide-imp"),b.addClass("h-hide-imp"),f.addClass("h-hide-imp");!a.removeMenu&&a.needsShrink()&&c.reverse().each(function(){var g=d(this),h=g.data("vb-progressive-item-num"),l=f.filter(function(){return d(this).data("vb-progressive-item-num")==h});l.removeClass("h-hide-imp b-comp-menu-dropdown__content-item--first");g.addClass("h-hide-imp");b.removeClass("h-hide-imp");if(!a.needsShrink())return l.addClass("b-comp-menu-dropdown__content-item--first"),
!1})}}}}}(jQuery,vBulletin.Responsive.Debounce);
;

// ***************************
// js.compressed/css_b_comp_menu_dropdown.js
// ***************************
vBulletin.CompMenuDropdown=function(c){function C(a){c(a.target).closest(".js-comp-menu-dropdown").length||y(c(".js-comp-menu-dropdown"))}function L(){function a(f){e=new Date;h=f.originalEvent.touches[0].pageX;m=f.originalEvent.touches[0].pageY;g=l=0}function b(f){l=h-f.originalEvent.touches[0].pageX;g=m-f.originalEvent.touches[0].pageY}function d(f){400>=new Date-e&&!l&&!g&&C.call(this,f)}var e=!1,h,m,l,g;c(document).off("touchstart",a).on("touchstart",a).off("touchmove",b).on("touchmove",b).off("touchend",
d).on("touchend",d)}function M(a){var b=c(a.target).closest(".js-comp-menu-dropdown");b.is(".b-comp-menu-dropdown--open")?y(b):N(b);a=c(".js-comp-menu-dropdown").filter(function(){return c(this).get(0)!=b.get(0)});y(a);vBulletin.conversation.closeFilterMenus();return!1}function D(a){a=c(a.target).closest(".js-comp-menu-dropdown");a.length&&a.is(".b-comp-menu-dropdown--open")&&y(a)}function E(a){a=c(a.target);a.closest(".js-comp-menu-dropdown").find(".js-comp-menu-dropdown__trigger-text").text(a.text())}
function z(a,b,d){var e=b.find(".b-comp-menu-dropdown__content-item");d=Math.min(d,4);if(1<d){b.addClass("b-comp-menu-dropdown__content--"+d+"-column");b=!a.is(".b-comp-menu-dropdown--open");var h="",m="";e.removeClass("b-comp-menu-dropdown__content-item--column-first b-comp-menu-dropdown__content-item--column-trailing");b&&a.addClass("b-comp-menu-dropdown--open");e.each(function(){var l=c(this).position();l=parseInt(l.top,10);""===h&&(h=l);""===m&&(m=l);h=Math.min(h,l);m=Math.max(m,l)});e.each(function(){var l=
c(this),g=l.position();parseInt(g.top,10)<=h&&l.addClass("b-comp-menu-dropdown__content-item--column-first")});e=e.last();e.position().top<m&&e.addClass("b-comp-menu-dropdown__content-item--column-trailing");b&&a.removeClass("b-comp-menu-dropdown--open")}else{for(a=4;1<a;)b.removeClass("b-comp-menu-dropdown__content--"+a+"-column"),--a;e.removeClass("b-comp-menu-dropdown__content-item--column-first b-comp-menu-dropdown__content-item--column-trailing")}}function F(a,b){if(a.is(".b-comp-menu-dropdown--open")){var d=
b.outerHeight();b=b.outerWidth()}else a.addClass("b-comp-menu-dropdown--open"),d=b.outerHeight(),b=b.outerWidth(),a.removeClass("b-comp-menu-dropdown--open");return{width:b,height:d}}function G(a){var b=c(window),d=b.width(),e=b.height(),h=b.scrollLeft(),m=c(document).height();a.each(function(l,g){var f=c(g),r=f.offset(),u=f.find(".js-comp-menu-dropdown__trigger").outerHeight();l=f.find(".js-comp-menu-dropdown__trigger").outerWidth();g=f.find(".js-comp-menu-dropdown__content");var k=g.find(".b-comp-menu-dropdown__content-item");
g.css("width","auto");z(f,g,1);var n=F(f,g),p=n.height;n=n.width;k=Math.max(Math.min(Math.floor(k.length/15),4),1);p=Math.ceil(p/(e-100));n=Math.floor((d-0)/n);n=Math.max(n,1);k=Math.max(k,p);k=Math.min(k,4);k=Math.min(k,n);z(f,g,k);n=F(f,g);p=n.height;n=n.width;k=g.css("margin-top");var v=parseInt(k,10),q=r.top;k=q>=p;var t=m-q>=u+p+v;r=r.left-h+l;u=d-r+l;p=r>=n;v=u>=n;q=[];k&&!t?(f.addClass("b-comp-menu-dropdown--direction-up"),q.push("Forced up")):t&&!k&&(f.removeClass("b-comp-menu-dropdown--direction-up"),
q.push("Forced down"));k=f="";var w=t=0,x=0;p&&!v?(g.removeClass("b-comp-menu-dropdown__content--left").addClass("b-comp-menu-dropdown__content--right"),f="right",k="left",q.push("Forced right alignment (opens left)")):v&&!p?(g.removeClass("b-comp-menu-dropdown__content--right").addClass("b-comp-menu-dropdown__content--left"),f="left",k="right",q.push("Forced left alignment (opens right)")):v||p||(r>=u?(g.removeClass("b-comp-menu-dropdown__content--left").addClass("b-comp-menu-dropdown__content--right"),
f="right",k="left",w=n-r,x=u-l,t=Math.min(w,x),q.push("Forced right alignment (opens left) (More space on left)")):(g.removeClass("b-comp-menu-dropdown__content--right").addClass("b-comp-menu-dropdown__content--left"),f="left",k="right",w=n-u,x=r-l,t=Math.min(w,x),q.push("Forced left alignment (opens right) (More space on right)")));f&&k&&(0<t?g.css(f,"-"+t+"px"):g.css(f,"0"),g.css(k,"auto"));x<w&&g.css("width",d).find(".b-comp-menu-dropdown__content-item").addClass("ellipsis").find("> a").addClass("ellipsis")})}
function H(){var a=c(".js-comp-menu-dropdown").filter(function(){return c(this).is(".b-comp-menu-dropdown--open")});G(a)}function A(){var a=c(".js-select-on-xsmall, .js-select-on-small, .js-select-when-dropdown"),b=c("body").is(".l-small"),d=c("body").is(".l-xsmall");a.each(function(){var e=c(this),h=0<e.next(".vb-select-el").length,m=e.is(".js-select-when-dropdown")||e.is(".js-select-on-xsmall")&&d||e.is(".js-select-on-small")&&b;m&&!h?(I(e).removeClass("h-hide-imp").selectBox(),e.addClass("h-hide-imp")):
!m&&h&&(I(e).selectBox("destroy").addClass("h-hide-imp"),e.removeClass("h-hide-imp"))})}function I(a){var b=a.next(".vb-select-el");b.length||(b=c('<select class="vb-select-el"></select>'),1!=a.find(".b-comp-menu-dropdown__content-item.b-comp-menu-dropdown__content-item--current").length&&c("<option></option>").addClass("js-noop-label").text(a.find(".js-comp-menu-dropdown__trigger").text()).appendTo(b),a.find(".js-comp-menu-dropdown__content .b-comp-menu-dropdown__content-item").each(function(d,e){var h=
c(this);e=h.is(".b-comp-menu-dropdown__content-item--current");var m=h.find("> a");h=m.html()||h.html();c("<option></option>").html(h).data("vb-option-link",m).appendTo(b);e&&(b.get(0).selectedIndex=d)}),b.addClass("b-comp-menu-dropdown__select").on("change",function(d){d=d.target;idx=d.selectedIndex;opt=d.options[idx];(linkHref=($link=c(opt).data("vb-option-link"))?$link.attr("href"):null)&&"#"!=linkHref.substr(0,1)?window.location.href=linkHref:($link.one("click",function(e){var h=$link.data("href");
h&&(window.location.href=h,e.preventDefault())}),$link.trigger("click"))}).insertAfter(a),(a=a.data("add-classes-to-select-el"))&&b.addClass(a));return b}function J(){c(".js-select-on-xsmall, .js-select-on-small").each(function(){var a=c(this).data("vb-select-el");a&&(a=a.nextAll(".selectBox"),a=a.not(a.first()),a.remove())})}function N(a){a.each(function(b,d){b=c(this).closest(".conversation-toolbar");1==b.length&&b.height(b.height())});a.addClass("b-comp-menu-dropdown--open");G(a);a.find(".js-comp-menu-dropdown__trigger-arrow").removeClass("b-icon--disabled");
c(".js-expanded-indicator",a).removeClass("fa-caret-down").addClass("fa-caret-up")}function y(a){a.removeClass("b-comp-menu-dropdown--open");a.find(".js-comp-menu-dropdown__trigger-arrow").addClass("b-icon--disabled");c(".js-expanded-indicator",a).removeClass("fa-caret-up").addClass("fa-caret-down")}function K(){var a=c(".js-comp-menu-dropdown__trigger").filter((d,e)=>"1"!=c(e).data("comp-menu-dropdown-initialized"));a.offon("click",M).attr("tabindex","0").addClass("js-button").data("comp-menu-dropdown-initialized",
"1");c(document).offon("click.menu",C);L();var b=c();a.each(function(d,e){d=c(e);d.is(".b-comp-menu-dropdown__trigger--arrow")&&1>d.find(".js-comp-menu-dropdown__trigger-arrow").length&&c('<span class="b-icon-fa b-icon-fa--12 fa-solid fa-caret-down b-icon--disabled js-comp-menu-dropdown__trigger-arrow h-align-middle"></span>').appendTo(d);d=d.parents(".js-shrink-event-parent");d.length&&(b=b.add(d))});b.length&&vBulletin.Responsive.Debounce.checkShrinkEvent(b);c(".js-comp-menu-dropdown").removeClass("b-comp-menu-dropdown--open-on-hover");
A();c(document).off("vb-filterposts",J).on("vb-filterposts",J);c(".b-comp-menu-dropdown__content-item:not(.js-comp-menu-dropdown__content-maintain-menu)").filter(function(){return"1"!=c(this).data("comp-menu-dropdown__content-close-menu-initialized")}).off("click",D).on("click",D).attr("data-comp-menu-dropdown__content-close-menu-initialized","1");c(".js-comp-menu-dropdown--display-current").off("click",".b-comp-menu-dropdown__content-item",E).on("click",".b-comp-menu-dropdown__content-item",E);1>
B.init&&(vBulletin.Responsive.Debounce.registerCallback(H),vBulletin.Responsive.Debounce.registerCallback(A));B.init++}var B=vBulletin.ensureObj("jsexec.css_b_comp_menu_dropdown",{exec:0,init:0});B.exec++;c(K);return{init:K,updateMenuFormat:H,updateMenuAsSelectElement:A,setMenuColumnCount:z}}(jQuery);
;

// ***************************
// js.compressed/pmchat.js
// ***************************
vBulletin.precache(["error","pmchat_close_button_label","pmchat_idle_disconnected_message","pmchat_idle_disconnected_title","pmchat_reconnect_button_label"],["pmchat_enabled","pmchat_header_polling_interval","pmchat_chat_polling_idle_timeout","pmchat_chat_polling_min_interval","pmchat_chat_polling_max_interval"]);
(function(b,na,V){function ha(g){g=g.hasOwnProperty("messageid")?"?messageid="+encodeURIComponent(g.messageid):"?aboutNodeid="+encodeURIComponent(g.aboutNodeid)+"&toUserid="+encodeURIComponent(g.toUserid);return""==g?"#":oa+g}function ia(g){var u;g=g.hasOwnProperty("url")?g.url:ha(g);"#"!=g&&((u=window.open(g,"_blank","width=600,height=700,resizable=yes,scrollbars=yes,status=yes"))&&!u.closed&&"undefined"!=typeof u.closed||window.open(g+queryString))}function pa(){function g(l){var f=l[Object.keys(l)[0]];
f=f&&f.orderListForJs||[];var n=f.length,y=!1,F={};if(0<n)L.find(".js-pmchat__submenu__ephemeral").remove();else return!1;for(var z=0;z<n;z++){var v=f[z];if(l.hasOwnProperty(v)){var p=l[v];var r=W.clone(!0);var t=r.find(".js-pmchat__submenu__link"),O="js-pmchat__messagefinder__"+v;r.removeClass("h-hide-imp");t.attr("data-starter",v).prop("title",p.previewtext).attr("href",ha({messageid:v}));r.find(".js-pmchat__submenu__title").html(p.title);0==p.msgread&&r.addClass("b-comp-menu-dropdown__content-item--unread");
r.addClass(O);r.insertBefore(q);(r=0<M&&(!w.hasOwnProperty(v)||w[v].publishdate!=p.publishdate||w[v].userid!=p.userid)&&0==p.msgread&&p.userid!=pageData.userid)&&(y=!0);F[v]={publishdate:p.publishdate,userid:p.userid,title:p.title,previewtext:p.previewtext,findmehelper:O,isNew:r}}}w=F;M=D;y&&u()}function u(){console.log("New Messages found in polling! Notifying user");if(B.find(".js-comp-menu-dropdown").hasClass("b-comp-menu-dropdown--open")){var l=[];for(f in w)w.hasOwnProperty(f)&&w[f].isNew&&l.push("."+
w[f].findmehelper);if(0<l.length){var f=l.join(", ");var n=b(f),y=setInterval(function(){n.toggleClass("b-comp-menu-dropdown__content-item--unread-alert")},100);setTimeout(function(){clearInterval(y);n.removeClass("b-comp-menu-dropdown__content-item--unread-alert")},3E3)}}else B.find(".js-comp-menu-dropdown").addClass("b-comp-menu-dropdown--alert")}function X(){k+=60;k>=x&&G()}function G(){clearTimeout(Y);k>=x?console.log("Header polling stopped due to idle timeout. (idle time: "+k+"s)"):Y=setTimeout(P,
1E3*H)}function P(){G();console.log("Polled for header data!"+Date.now());Z()}function Q(l,f,n){l.length&&(l.text()!=f&&(l.text(f),l.toggleClass("h-hide-imp",0>=f)),n&&l.parents().eq(1).toggleClass("h-hide-imp",0>=f))}function Z(l){K?"function"==typeof l&&I&&I.always(l):(K=!0,N.removeClass("h-hide-imp"),vBulletin.loadingIndicator.suppressNextAjaxIndicator(),I=vBulletin.AJAX({call:"/chat/loadheaderdata",success:function(f){var n=f.headerCounts;Q(aa,n.messages);Q(R,n.totalcount);ba.each(function(){var y=
b(this),F=y.data("folderid")||0;Q(y,n.details&&n.details[F]&&n.details[F].count||0,!0)});b.isEmptyObject(f.messages)||g(f.messages)},api_error:vBulletin.ajaxtools.logApiError,error:vBulletin.ajaxtools.logAjaxError,complete:[function(){K=!1;N.addClass("h-hide-imp");D=Date.now()},l]}))}var B=b(".js-pmchat__dropdown"),aa=B.find(".js-pmchat__messages-count"),R=b(".notifications-count").not(".js-pmchat__messages-count").not("[data-folderid]"),ba=b(".notifications-count[data-folderid]").not(".js-pmchat__messages-count"),
L=B.find(".js-pmchat__dropdown-submenu"),W=L.find(".js-pmchat__dropdown__single-pm-template").removeClass("js-pmchat__dropdown__single-pm-template"),q=L.find(".js-pmchat__insert-marker"),N=b(".js-pmchat__dropdown-submenu").find(".js-pmchat__submenu__loading-icon");B.find(".js-pmchat__header-data");var H=V.get("pmchat_header_polling_interval")||30,k=0,x=vBulletin.options.get("pmchat_chat_polling_idle_timeout")||300,D=0,w={},M=0,K=!1,I=null,ca=b.debounce(100,function(){"function"==typeof vBulletin.CompMenuDropdown.updateMenuFormat&&
vBulletin.CompMenuDropdown.updateMenuFormat()});L.off("click").on("click",".js-pmchat__submenu__link",function(){var l={},f=b(this).attr("href");"#"!=f?l.url=f:l.messageid=b(this).data("starter");ia(l);b(this).parent().removeClass("b-comp-menu-dropdown__content-item--unread");return!1});b(".js-pmchat-reload-header").on("click",function(l){B.find(".js-comp-menu-dropdown").removeClass("b-comp-menu-dropdown--alert");k=0;Date.now()-D<1E3*H?console.log("PM Load aborted: less than "+H+" seconds since last load."):
(G(),Z(ca))});(function(){console.log("Idle detection enabled");setInterval(X,6E4);b(document).on("click keypress scroll",function(l){k=0})})();var Y=setTimeout(P,1E3*H)}function qa(){function g(){var e=b(".js-pmchat__insert-marker").offset().top,a=b(".js-pm-content-entry-container"),d=a.outerHeight();a="fixed"==a.css("position");var c=b(window).outerHeight();(!a||e>c-d)&&vBulletin.animateScrollTop(e)}function u(e){if(n)console.log("Nothing to load, awaiting first message.");else if(E.messagesLoading)console.log("loadNewMessages() rejected: Still awaiting messages from a previous call.");
else{console.log("loadNewMessages() executing.");var a=[];H.find(".js-pmchat__post-wrapper").each(function(d,c){d=parseInt(b(c).data("publishdate")||0,10);var h=parseInt(b(c).data("nodeid")||0,10);d>I&&(I=d,ca=h);0<h&&a.push(h);I>d&&b(c).removeClass("js-pmchat__post-wrapper")});E.messagesLoading=!0;vBulletin.loadingIndicator.suppressNextAjaxIndicator();vBulletin.AJAX({call:"/chat/loadnewmessages",data:{parentid:D,newreplyid:e,lastpublishdate:I,lastnodeid:ca,loadednodes:a},success:function(d){S=(S+
1)%10;d.html&&""!==d.html?(T[S]=1,U=Date.now(),console.log("loadNewMessages(): Inserting new messages."),b(d.html).insertBefore(Y),g()):(T[S]=-1,console.log("loadNewMessages(): No new messages."))},error:function(d){console.log("loadNewMessages(): Error loading new PMs. Ajax result:");console.log(d)},complete:function(d){window.vBulletin.loadingIndicator.hide();E.messagesLoading=!1;E.queued&&(E.queued=!1,window.vBulletin.loadingIndicator.show(),setTimeout(u,0));X(!0)}})}}function X(e){clearTimeout(F);
var a=Date.now(),d=a-U,c=a-y,h=0<T[S],m=T.reduce(function(A,C){return A+C})/10;0<U?h?(t>v&&(t=v),--t,U>z&&(z=U)):t-=1*m:t+=1;t<p?t=p:t>r&&(t=r);y=a;da&&(da=!1,z=a);h=(a-z)/1E3;console.log("Idle time: "+h+"s. (timeout: "+O+"s)");h>=O?(console.log("Polling for messages stopped due to idle timeout. Idle start time: "+z+" time now: "+a),Q(),z=a):(F=setTimeout(G,1E3*t),e?console.log(Date()+" "+`Poll timer was reset from loadNewMssages().  Last poll was ${y}. Next poll is in ${t} seconds. `+"Time since last poll: "+
c/1E3+"s, since last hit: "+d/1E3+"s."):console.log(Date()+" "+`Polling for messages complete. Last poll was ${y}. Next poll is in ${t} seconds. `+"Time since last poll: "+c/1E3+"s, since last hit: "+d/1E3+"s."))}function G(){X();u()}function P(){z=Date.now();t=v;G()}function Q(){f&&f.dialog("instance")||(f=na.dialogtools.openConfirmDialogSimple({title:"pmchat_idle_disconnected_title",message:"pmchat_idle_disconnected_message",width:"50%",yesPhrase:"pmchat_reconnect_button_label",noPhrase:"pmchat_close_button_label",
onClickYes:P,onClickNo:()=>window.close()}))}function Z(e){e?(ra.remove(),ja.remove(),k.attr("data-message-type","pm-reply"),History.replaceState({},K,pageData.baseurl_pmchat+"?messageid="+e),aa(e)):console.log("Missing nodeid for loadParticipants()")}function B(){sa.trigger("event-js-element-resize")}function aa(e,a){vBulletin.AJAX({call:"/chat/loadparticipants",data:{nodeid:e},success:function(d){let c=b(".js-pmchat__participants-insert-marker"),h=b(".js-pmchat__participant");d.participants_html&&
""!=d.participants_html&&c.length&&(h.remove(),c.prepend(d.participants_html),ea.trigger("event-js-content-change"));N.hasClass("h-hide")&&(N.removeClass("h-hide"),ka.trigger("click"),fa.removeClass("h-hide"));d.phrase&&""!=d.phrase&&(b(".js-participants-count-phrase").text(d.phrase),b(".js-participants-count-phrase--title").prop("title",d.phrase));d.title&&""!=d.title&&b(document).find("title").html(d.title);if(a&&a.success&&"function"==typeof a.success)return a.success.apply(this,[d])},complete:function(d,
c,h){if(a&&a.complete&&"function"==typeof a.complete)return a.complete.apply(this,[d,c,h])},error:function(d,c,h){console.log("/ajax/chat/loadparticipants failed!");console.log("----------------");console.log("jqXHR:");console.dir(d);console.log("text status:");console.dir(c);console.log("error thrown:");console.dir(h);console.log("----------------")}})}function R(e){var a=b(this).attr("href");a.startsWith("#")||(e.preventDefault(),(e=window.open(a,"_blank"))&&!e.closed&&"undefined"!=typeof e.closed||
window.open(a))}function ba(e){fa.animate({height:"toggle"},{duration:"fast",start:function(){ea.trigger("event-js-element-resize-start")},progress:function(a,d,c){B()},complete:function(){B()}});e.preventDefault();la.length&&la.toggleClass("fa-caret-down fa-caret-up")}function L(){var e=function(m){var A=0<ea.height();if(m.data&&m.data.command)switch(m.data.command){case "open":J.removeClass("h-hide");break;case "close":J.addClass("h-hide");break;default:A?J.toggleClass("h-hide"):J.removeClass("h-hide")}else J.toggleClass("h-hide");
A?B():ba(m);m.preventDefault()},a={},d=b(".js-participants-add-recipients-input"),c=new vBulletin_Autocomplete(d,{apiClass:"user",afterAdd:function(m,A,C){"undefined"!=typeof C&&"undefined"!=typeof C.id&&C.id&&(a[A]=C.id)},delimiter:" ; "}),h=function(m){c.clearElements();m.data?m.data.command="close":m.data={command:"close"};e(m)};console.log({addRecipientsAutoComplete:c});ma.off("click").on("click",{command:"toggle"},e);J.find(".js-add-recipients-cancel").off("click").on("click",{command:"close"},
h);J.find(".js-add-recipients-submit").off("click").on("click",function(m){var A=c.getInputField(),C=A.val();C&&(A.val(""),c.addElement(C,C));A=c.getValues();vBulletin.AJAX({call:"/ajax/api/content_privatemessage/addPMRecipientsByUsernames",data:{pmid:D,usernames:A,usernamesToIds:a},success:function(ua){aa(D,{success:function(){h(m);E.messagesLoading?E.queued=!0:u()},complete:function(){window.vBulletin.loadingIndicator.hide()}})}})})}function W(e){function a(){if("fixed"==c.css("position")){h.removeClass("h-hide");
var m=c.outerHeight()-30;h.css("height",m+"px")}else h.addClass("h-hide")}var d=e+"-replacement",c=b("."+e),h=b("."+d);0==h.length&&(h=b("<div />").addClass(d).insertAfter(c));b(a);b(document).off("click",a).on("click",a);vBulletin.Responsive.Debounce.registerCallback(a);CKEDITOR.on("instanceReady",function(m){a();m.editor.on("focus",function(){setTimeout(function(){a()},0)})});c.on("event-js-element-resize",a)}var q=b(".js-pmchat__container"),N=b(".js-pmchat__participants"),H=q.find(".js-pmchat__thread-container"),
k=q.find("form"),x=q.find(".js-pmchat__data");q=parseInt(x.data("pmchannelid"),10);var D=parseInt(x.data("parentid"),10),w=parseInt(x.data("pm_messageid"),10),M=parseInt(x.data("to_userid"),10),K=x.data("pm_title"),I=0,ca=0,Y=b(".js-pmchat__insert-marker"),l=H.find(".js-pmchat__thread-placeholder"),f,n=!1;q!=D&&0<w||(n=!0);var y=0,F,z=Date.now(),v,p=V.get("pmchat_chat_polling_min_interval")||1,r=V.get("pmchat_chat_polling_max_interval")||30;r<p&&(q=r,r=p,p=q);var t=v=(10*p+1*r)/11;var O=vBulletin.options.get("pmchat_chat_polling_idle_timeout")||
300,U=0,S=9,T=[];for(q=0;10>q;++q)T[q]=0;var E={messagesLoading:!1,queued:!1},da=!1,sa=b(".js-pmchat__header"),ka=b(".js-participants-collapser-ui"),la=b(".js-participants-toggle-arrow"),fa=b(".js-participants-collapsible"),ea=fa.find(".js-vbscroller-wrapper"),ma=b(".js-participants-show-add-recipients-ui"),J=b(".js-participants-add-recipients-wrapper"),ra=k.find(".js-wrapper-contententry_title"),ja=k.find(".js-wrapper-contententry__msgRecipients");new vBulletin_Autocomplete(b(".privatemessage_author"),
{apiClass:"user",delimiter:" ; "});b(".js-pm-content-entry-container .js-pmchat-submit").off("click").on("click",function(e){function a(c,h,m){b("<input>").attr({type:"hidden",name:h,value:m}).appendTo(c)}var d=b(this);d.prop("disabled",!0);z=Date.now();n?(0==k.find('input[name="msgRecipients"]').length&&M?(console.log({msg:"sentto input added with prefill:",to_userid:M}),a(k,"sentto[]",M)):console.log({msg:'User editable input[name="msgRecipients"] was found. Prefilled sentto skipped.'}),0==k.find('input[name="title"]').length?
(console.log({msg:"title input added with prefill:",pm_title:K}),a(k,"title",K)):console.log({msg:'User editable input[name="title"] was found. Prefilled title skipped.'})):(e=k.find('input[name="respondto"]'),0<e.length?e.val(w):a(k,"respondto",w),0==k.find('input[name="msgtype"]').length&&a(k,"msgtype","message"));n&&l.addClass("h-hide");vBulletin.loadingIndicator.show();vBulletin.AJAX({call:"/create-content/private-message",data:k.serialize(),success:function(c){c.nodeId&&(c=parseInt(c.nodeId,
10),n&&(k.find('input[name="parentid"]').val(c),x.data("parentid",c),x.data("pm_messageid",c),x.attr("data-parentid",c),x.attr("data-pm_messageid",c),D=w=c,n=!1,Z(c)),console.log("==================NEW MESSAGE POSTED, LOADING NEW MESSAGES!"),E.messagesLoading?E.queued=!0:u(c),vBulletin.contentEntryBox.resetForm(k,!1,function(){var h=k.attr("ck-editorid")||b(".js-editor",k).attr("id");h=vBulletin.ckeditor.getEditor(h);vBulletin.hv.reset();h.focus()}))},api_error:vBulletin.hv.resetOnError,complete:function(c){vBulletin.loadingIndicator.hide();
d.prop("disabled",!1)}});return!1});q="a:not('.js-pmchat-ignoreanchor')";var ta=`.js-namecard-html ${q}`;V.get("usenamecard")&&(q+=":not([data-vbnamecard])",b("body").on("click",ta,R));H.on("click",q,R);N.on("click",q,R);b("body").on("click","a.js-pmchat-ignoreanchor",function(e){e.preventDefault()});ka.off("click").on("click",ba);0<ma.length&&0<J.length&&L();b(".js-pm-content-entry-container .js-button").enable();g();G();(function(){b(document).on("click keypress scroll",function(a){da=!0});var e=
k.attr("ck-editorid")||b(".js-editor",k).attr("id");b("#"+e).on("afterInit",function(){var a=vBulletin.ckeditor.getEditor(e);a.on("contentDom",function(){function d(){da=!0}var c=a.editable();null!=c&&(c.attachListener(c,"keypress",d),c.attachListener(c,"click",d),c.attachListener(c,"focus",d))})})})();window.setTimeout(function(){var e=k.attr("ck-editorid")||b(".js-editor",k).attr("id");b("#"+e).on("afterInit",function(){var a=vBulletin.ckeditor.getEditor(e);if(a){console.log("Setting predefined starter PM text: "+
x.data("pm_textprefill"));var d=x.data("pm_textprefill");d&&(d+="&nbsp;");a.setData(d,function(){vBulletin.ckeditor.fixTableFunctionality.call(vBulletin.ckeditor,{},a);var c=ja.find(".autocompleteHelper");0<c.length?c.trigger("focus"):a.focus();d&&(c=a.createRange(),c.moveToPosition(c.root,CKEDITOR.POSITION_BEFORE_END),a.getSelection().selectRanges([c]));g()})}else console.log("Editor not found, cannot set predefined starter PM text")})},0);W("js-pm-content-entry-container");W("js-pmchat__header");
vBulletin.ready("pushnotification").then(e=>{e=new BroadcastChannel("vb_push_privatemessage");b(e).on("message",a=>{a=a.originalEvent;const d=a.data||{};a.origin==location.origin&&w==(d.starter||0)&&(f&&f.dialog("instance")?(P(),f.dialog("close")):G())})});(function(){var e=b("#debug-information");if(1==e.length){function a(){b("body").is(".l-xsmall")?e.appendTo("body"):e.insertBefore(".js-pm-content-entry-container")}a();vBulletin.Responsive.Debounce.registerCallback(a)}})()}var oa=pageData.baseurl_pmchat;
(function(){b(function(){b("body").off("click",".js-pmchat-link").on("click",".js-pmchat-link",function(u){u.preventDefault();u={url:b(this).attr("href")};ia(u);return!1});var g=b(".js-pmchat__dropdown");0<g.length?g.attr("data-initialized")?console.log("PM Dropdown already initialized. Skipping re-init."):(console.log("Initializing PM Dropdown!"),g.attr("data-initialized",!0),pa()):console.log("PM Dropdown not detected, skipping init.");g=b(".js-pmchat__container");0<g.length?g.attr("data-initialized")?
console.log("PM Chat window already initialized. Skipping re-init."):(console.log("Initializing PM Chat window!"),g.attr("data-initialized",!0),qa()):console.log("PM Chat window not detected, skipping init.")})})()})(jQuery,vBulletin,vBulletin.options);
;

// ***************************
// js.compressed/module-search2.js
// ***************************
(function(e){function z(a){var c=a.find(".js-widget-search2-nodelist-item"),b=0,f=a.find(".js-fixed-event-year-header"),n=a.find(".js-year-header");0==f.length&&(f=e("<li />").addClass("js-fixed-event-year-header b-event__listyear b-event__listyear--fixed h-hide").prependTo(a));e.each(n,function(g,d){g=e(d);g.next().hasClass("js-widget-search2-nodelist-item")||g.remove()});e.each(c,function(g,d){g=e(d);d=parseInt(g.data("start-year"),10);var l=g.prev(".js-year-header");d>b&&(l.length||e("<li />").addClass("js-year-header b-event__listyear").text(d).data("start-year",
d).insertBefore(g),b=d)})}function A(a){var c=a.find(".js-widget-search2-nodelist-item"),b=a.data("search-max-page")||!1,f=a.data("loaded-pages")||{};c.removeClass("b-event--lastchild h-hide");z(a);a.find(".js-loading").appendTo(a);a.find(".js-no-more-items").appendTo(a);b&&f.hasOwnProperty(b)&&a.find(".js-no-more-items").removeClass("h-hide");c=a.height();b=a.scrollTop();a.height("auto");f=a.height();a.height(c);a.scrollTop(b);a.data("full-height",f)}function E(a,c){var b=c.$anchorItem&&c.$anchorItem.offset().top||
0;c=c.anchorItemPreviousTop-b;a.scrollTop();a.scrollTop(a.scrollTop()-c)}function F(a){var c=a.find(".js-widget-search2-nodelist-item"),b={},f=a.offset().top,n=f+a.height(),g=!1,d=!1,l,k=Number.POSITIVE_INFINITY,h,p=0;e.each(c,function(m,q){m=e(q);q=m.hasClass("h-hide");var u=m.offset().top,v=u+m.height(),x=m.data("nodeid");b["nodeid"+x]=!0;g=!q&&!(v<=f||n<=u);d=f<=u;"undefined"==typeof l&&g&&d&&(l=m,k=l.data("page"));g&&(h=m,p=h.data("page"))});return{$items:c,haveNodeids:b,$firstVisibleItem:l,firstVisiblePage:k,
$lastVisibleItem:h,lastVisiblePage:p,$anchorItem:h,anchorItemPreviousTop:h&&h.offset().top||0}}function B(a){a=e(a.target);var c=a.scrollTop();a.data("full-height");var b=a.position().top,f=a.height(),n=a.find(".js-widget-search2-nodelist-item");f=n.slice(-5).first().position().top-b<f;var g=n.slice(0,5).last();g=g.position().top-b+g.height()>b;var d=a.find(".js-fixed-event-year-header");if(0<c){var l=0;e.each(n,function(k,h){k=e(h);h=k.position().top-b;var p=k.height();if(0<h+p)return l=k.data("start-year"),
!1});d.css({top:b,width:n.first().width()}).text(l).removeClass("h-hide")}else d.addClass("h-hide");f?C(a,"bottom"):g&&C(a,"top")}function D(){e(".js-widget-search2").each(function(a,c){c=e(c);a=c.find(".js-fixed-event-year-header");c=c.find(".js-widget-search2-nodelist-item").first();a.css("width",c.width())})}function C(a,c){if(!r){r=!0;var b=a.closest(".js-widget-search2"),f=b.data("widget-id"),n=b.data("widget-instance-id"),g=a.data("search-max-page")||Number.POSITIVE_INFINITY,d=a.data("loaded-pages")||
{};e.isEmptyObject(d)&&(b=b.data("current-page"),d={},d[b]=b,a.data("loaded-pages",d));var l=Object.keys(d).sort(function(k,h){return parseInt(k,10)-parseInt(h,10)});if("bottom"==c){if(b=d[l[l.length-1]]+1,g<b){r=!1;return}}else if("top"==c){if(b=d[l[0]]-1,1>b){r=!1;return}}else{r=!1;return}a.find(".js-loading").removeClass("h-hide");vBulletin.AJAX({call:"/ajax/render/widget_search2",data:{widgetinstanceid:n,widgetid:f,currentPage:b},success:function(k){var h=e(k).filter(".js-widget-search2"),p=h.find(".js-widget-search2-nodelist"),
m=p.find(".js-widget-search2-nodelist-item");k=F(a);var q=k.$items,u=q.first(),v=q.length,x=k.haveNodeids;p=p.data("search-has-more");h=h.data("current-page");d[h]=h;a.data("loaded-pages",d);p||a.data("search-max-page",h);e.each(m,function(w,y){w=e(y);y=w.data("nodeid");"undefined"==typeof x["nodeid"+y]&&("bottom"==c?a.append(w):"top"==c&&u.before(w),v++)});if(200<v){var t;m=a.find(".js-widget-search2-nodelist-item");"bottom"==c?t=d[l[0]]:"top"==c&&(t=d[l[l.length-1]]);m=m.filter("[data-page='"+t+
"']");if(t<=k.firstVisiblePage||t>=k.lastVisiblePage)m.remove(),delete d[t],a.data("loaded-pages",d)}A(a);E(a,k)},complete:function(){a.find(".js-loading").addClass("h-hide");r=!1}})}}var r=!1;e(function(){var a=e(".js-widget-search2");a.length&&e.each(a,function(c,b){c=e(b);if("1"!=c.data("vb-continuous-scroll-initialized")){b=c.find(".js-widget-search2-nodelist");if(b.data("search-has-more")||b.find(".js-widget-search2-nodelist-item.h-hide").length){z(b);var f=b.parents(".js-show-on-tabs-create.h-hide");
f.length&&f.removeClass("h-hide");b.css({height:b.height(),overflowY:"scroll"});f.length&&f.addClass("h-hide");A(b)}b.off("scroll",B).on("scroll",B);e(window).off("resize",D).on("resize",D);c.attr("vb-continuous-scroll-initialized","1")}})})})(jQuery);
;

// ***************************
// js.compressed/module-tabbedcontainer.js
// ***************************
(function(b){function f(a){if("1"!=a.data("vb-tabbedcontainer-tabs-initialized")){var d=a.data("default-tab")||0;a.tabs({create:function(c,e){a.find(".js-tabs-loading-placeholder").remove();a.find(".js-show-on-tabs-create").removeClass("h-hide");a.tabs("option","active",d)},activate:function(c,e){e.newPanel.find(".js-parent-tab-render-listener").trigger("parent-tab-render")}});a.trigger("vb-tabinit");a.attr("data-vb-tabbedcontainer-tabs-initialized","1")}}b(function(){var a=b(".js-tabbedcontainer-widget-tab-wrapper");
a.length&&b.each(a,function(d,c){f(b(c))})})})(jQuery);
;

// ***************************
// js.compressed/reactions.js
// ***************************
(function(){function C(n,c){function x(){h.data("nodeid",null);h.toggleClass("vb-pop-open",!1);c(".js-reactions-add-reaction").attr("aria-expanded",!1)}function z(k,p,r=!1){return n.AJAX({call:"/ajax/api/reactions/"+(r?"unvoteNode":"voteNode"),data:{nodeid:k,votetypeid:p},success:function(a){if(a.nodevotes){a=a.nodevotes;var b=c(`.js-reactions-toggle-vote[data-nodeid="${k}"]`);b.attr("data-deleteme",1);for(votetypekey in a)if(a.hasOwnProperty(votetypekey)){var d=a[votetypekey],e=parseInt(d.votetypeid,
10),g=parseInt(d.votes,10);d=d.ivoted;var f=b.filter(`[data-votetypeid="${e}"]`),l=f.length&&f.find(".js-reactions-count");if(e)if(f.length)f.data("ivoted",d),f.attr("data-ivoted",d),l.text(g),f.attr("data-deleteme",0==g?1:0);else if(0<g){f=k;d=d?1:0;e=parseInt(e,10);f=parseInt(f,10);g=parseInt(g,10);l=c(`.js-reactions-dovote[data-votetypeid="${e}"]`);let t=l.html();g=l.length?`<div class="reactions__topic-reaction js-reactions-toggle-vote"
				data-ivoted="${d}"
				data-votetypeid="${e}"
				data-nodeid="${f}"
			>
			${t}<span class="reactions__topic-reaction--count js-reactions-count">${g}</span>
		</div>`:"";""!=g&&c(g).appendTo(c(`.js-topic-reactions-list[data-nodeid="${k}"]`))}}b.filter("[data-deleteme=1]").remove()}},api_error:function(a){return D.hasError(a,"nodevote_dupe_notallowed")?(console.log("TODO: implement flashAlreadyVoted()"),!1):!0},complete:()=>x()})}function u(k,p=!0){k.data("data-vbreaction-lock",p);k.css("cursor",p?"wait":"pointer")}if(!n.reactionsinit){function k(a,b,d){p(A);A=a;E.apply(a,"qtip-whovoted",{position:{viewport:c(window),adjust:{method:"shift flip"}},content:{title:{text:y.get("people_who_liked"),
button:!0},text:function(e,g){n.AJAX({call:"/ajax/api/reactions/fetchWhovoted",data:{nodeid:b,votetypeid:d},success:f=>{let l;if(1>f.length||!f.users)l=y.get("no_one_voted");else{l='<ul class="whovoted-container">';for(const m of f.users){f=pageData.baseurl+m.profileurl;var t=(m.avatar.isfullurl?"":pageData.baseurl_core+"/")+m.avatar.avatarpath;t=c("<img>").attr({src:t,alt:m.username});$userlink=c("<a>").attr("href",f);$avatar=$userlink.clone().addClass("avatar h-inline-block");$rightcolumn=c("<div>").addClass("rightcolumn");
$li=c("<li>").addClass("whovoteditem");$li.append($avatar.append(t));$rightcolumn.append($userlink.clone().addClass("username").html(m.musername));m.doshowdisplayname&&$rightcolumn.append(c("<div>").addClass("usertitle").append($userlink.clone().html(m.username)));$rightcolumn.append(c("<div>").addClass("usertitle").html(m.usertitle));$li.append($rightcolumn);l+=c("<div>").append($li).html()}l+="</ul>"}g.set("content.text",l)}});return y.get("working_ellipsis")}},show:{event:"",ready:!0},hide:{event:"unfocus",
fixed:!0}})}function p(a){var b=a?"object"!==typeof a.data("qtip")?!1:"false"==a.qtip().tooltip.attr("aria-hidden"):!1;b&&a.qtip("hide")}function r(a){a=c(a.currentTarget);return[a,parseInt(a.data("nodeid"),10),parseInt(a.data("votetypeid"),10)]}n.reactionsinit=!0;var h=c(".js-reactions-available-list"),D=n.ajaxtools,B=c(window);c(document).offon("click",".js-reactions-add-reaction",a=>{a=c(a.currentTarget);a.data("vb-reactions-list")||a.siblings(".js-reactions-available-list");if(h)if(h.hasClass("vb-pop-open")&&
h.data("nodeid")==a.data("nodeid"))x();else{var b=parseInt(a.data("nodeid"),10);h.data("nodeid",b);b=h;B.scrollTop();var d=a.offset().top+a.outerHeight(!0);d=Math.max(d-b.outerHeight(!0),B.scrollTop());var e="ltr"==pageData.textdirection,g=a.offset().left+(e?0:a.outerWidth(!0));b.css("top",d);e?b.css("left",g):b.css("right",g);h.toggleClass("vb-pop-open",!0);c(".js-reactions-add-reaction").attr("aria-expanded",!1);a.attr("aria-expanded",!0);h.find(".js-reactions-dovote:first").focus()}return!1});
c(document).on("click.reactions",a=>{x(c(".js-reactions-available-list.vb-pop-open"))});c(document).on("click.reactions",".js-reactions-available-list",()=>!1);c(document).offon("click",".js-reactions-dovote",a=>{const b=c(a.currentTarget);a=parseInt(h.data("nodeid"),10);const d=parseInt(b.data("votetypeid"),10);b.data("data-vbreaction-lock")||(u(b),z(a,d).then(()=>u(b,!1)))});var v=!1,q=!1,w,E=n.qtip,y=n.phrase,A;c(document).offon("click",".js-reactions-toggle-vote",a=>{if(q)return q=!1;const [b,
d,e]=r(a);a=b.hasClass("js-reactions-toggle-vote")&&b.data("ivoted");b.data("data-vbreaction-lock")||(u(b),z(d,e,a).then(()=>u(b,!1)))});c(document).offon("contextmenu ",".js-topic-reactions-whovoted-container .js-reactions-toggle-vote",a=>{if(q)return q=!1;const [b,d,e]=r(a);d&&e&&(a.preventDefault(),v=!1,clearTimeout(w),k(b,d,e))});c(document).offon("mousedown mouseenter touchstart",".js-topic-reactions-whovoted-container .js-reactions-toggle-vote",a=>{const [b,d,e]=r(a);d&&e&&(a.preventDefault(),
"touchstart"!=a.type||"touchstart"==a.originalEvent.type)&&(v=!0,q=!1,clearTimeout(w),w=setTimeout(()=>{v&&(q=!0,k(b,d,e))},750))});c(document).offon("mouseup mouseleave touchend",".js-topic-reactions-whovoted-container .js-reactions-toggle-vote",a=>{v=!1;clearTimeout(w)})}}Promise.all([vBulletin.ready("global")]).then(()=>{C(vBulletin,jQuery)})})();
;

// ***************************
// js.compressed/pushnotification.js
// ***************************
vBulletin.precache(["error_pushmanager_subscribe","error_serviceworker_registration"],["push_publickey"]);
((g,h,w,x)=>{function q(){return navigator.serviceWorker.register("vb_serviceworker.js?c="+pageData.cachebuster).then(a=>{const b=a.installing||a.waiting||a.active;return a.active?a:new Promise((d,c)=>{b.addEventListener("statechange",e=>{"activated"==e.target.state&&d(a)})})}).catch(a=>{console.error("Error during service worker registration: ",a);return Promise.reject("error_serviceworker_registration")})}function k(){return q().then(a=>{console.log("Service worker successfully registered.",a);
return a.pushManager.subscribe(l).then(l).catch(b=>{console.log("Error during pushManager subscribe: ",b);return a.pushManager.getSubscription().then(d=>{d.unsubscribe().then(()=>{a.pushManager.subscribe(l).then(c=>v(d,c).then(c))})})})}).catch(a=>{console.error("Error during pushManager subscribe: ",a);return Promise.reject("error_pushmanager_subscribe")})}function v(a,b){return new Promise((d,c)=>{m({call:"/ajax/api/pushnotification/updateExpiredSubscription",data:{oldSub:f(a),newSub:f(b)},success(e,
r,y){n(b.endpoint);d(e)},api_error(e){console.error("Error during push subscription update on server: ",e);c(e)}})})}function n(a){t.setCookie("vb_push_endpoint",a)}g=h.options.get;const t=h.storagetools,p=a=>btoa(String.fromCharCode.apply(null,new Uint8Array(a))).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,""),f=a=>({endpoint:a.endpoint,keys:{p256dh:p(a.getKey("p256dh")),auth:p(a.getKey("auth"))},expiration:Number.parseInt(a.expirationTime/1E3,10)}),u=g("push_publickey"),l={userVisibleOnly:!0,
applicationServerKey:u},m=h.AJAX;"serviceWorker"in navigator&&"PushManager"in window&&(g={getPushSubscriptionPayload:f,getExistingSubscription:function(){return q().then(a=>{console.log("Service worker successfully registered.",a);return a.pushManager.getSubscription().then(b=>b&&p(b.options&&b.options.applicationServerKey)!==u?(console.log("Old app key does not match the current app key. Unsubscribing from existing subscription."),b.unsubscribe().then(()=>a.pushManager.getSubscription())):b)})},
getPushSubscription:k,subscribeUserToPush:function(){return k().then(a=>new Promise((b,d)=>{m({call:"/ajax/api/pushnotification/subscribeUser",data:f(a),success(c,e,r){n(a.endpoint);b(c)},api_error(c){console.error("Error during push subscription save to server: ",c);d(c)}})}))},unsubscribeUserFromPush:function(){return k().then(a=>new Promise((b,d)=>{m({call:"/ajax/api/pushnotification/unsubscribeUser",data:f(a),success(c,e,r){b(c)},api_error(c){console.error("Error during push subscription delete from server: ",
c);d(c)}})}))},setEndpointToCookie:n,getEndpointFromCookie:function(){t.getCookie("vb_push_endpoint")}},h.ready("pushnotification").resolve(g))})(jQuery,vBulletin,vBulletin.dialogtools,vBulletin.phrase.get);
;

