  



/*! jQuery UI - v1.12.1 - 2016-09-14
* http://jqueryui.com
* Includes: widget.js, position.js, data.js, disable-selection.js, effect.js, effects/effect-blind.js, effects/effect-bounce.js, effects/effect-clip.js, effects/effect-drop.js, effects/effect-explode.js, effects/effect-fade.js, effects/effect-fold.js, effects/effect-highlight.js, effects/effect-puff.js, effects/effect-pulsate.js, effects/effect-scale.js, effects/effect-shake.js, effects/effect-size.js, effects/effect-slide.js, effects/effect-transfer.js, focusable.js, form-reset-mixin.js, jquery-1-7.js, keycode.js, labels.js, scroll-parent.js, tabbable.js, unique-id.js, widgets/accordion.js, widgets/autocomplete.js, widgets/button.js, widgets/checkboxradio.js, widgets/controlgroup.js, widgets/datepicker.js, widgets/dialog.js, widgets/draggable.js, widgets/droppable.js, widgets/menu.js, widgets/mouse.js, widgets/progressbar.js, widgets/resizable.js, widgets/selectable.js, widgets/selectmenu.js, widgets/slider.js, widgets/sortable.js, widgets/spinner.js, widgets/tabs.js, widgets/tooltip.js
* Copyright jQuery Foundation and other contributors; Licensed MIT */

(function( factory ) {
	if ( typeof define === "function" && define.amd ) {

		// AMD. Register as an anonymous module.
		define([ "jquery" ], factory );
	} else {

		// Browser globals
		factory( jQuery );
	}
}(function( $ ) {

$.ui = $.ui || {};

var version = $.ui.version = "1.12.1";


/*!
 * jQuery UI Widget 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Widget
//>>group: Core
//>>description: Provides a factory for creating stateful widgets with a common API.
//>>docs: http://api.jqueryui.com/jQuery.widget/
//>>demos: http://jqueryui.com/widget/



var widgetUuid = 0;
var widgetSlice = Array.prototype.slice;

$.cleanData = ( function( orig ) {
	return function( elems ) {
		var events, elem, i;
		for ( i = 0; ( elem = elems[ i ] ) != null; i++ ) {
			try {

				// Only trigger remove when necessary to save time
				events = $._data( elem, "events" );
				if ( events && events.remove ) {
					$( elem ).triggerHandler( "remove" );
				}

			// Http://bugs.jquery.com/ticket/8235
			} catch ( e ) {}
		}
		orig( elems );
	};
} )( $.cleanData );

$.widget = function( name, base, prototype ) {
	var existingConstructor, constructor, basePrototype;

	// ProxiedPrototype allows the provided prototype to remain unmodified
	// so that it can be used as a mixin for multiple widgets (#8876)
	var proxiedPrototype = {};

	var namespace = name.split( "." )[ 0 ];
	name = name.split( "." )[ 1 ];
	var fullName = namespace + "-" + name;

	if ( !prototype ) {
		prototype = base;
		base = $.Widget;
	}

	if ( $.isArray( prototype ) ) {
		prototype = $.extend.apply( null, [ {} ].concat( prototype ) );
	}

	// Create selector for plugin
	$.expr[ ":" ][ fullName.toLowerCase() ] = function( elem ) {
		return !!$.data( elem, fullName );
	};

	$[ namespace ] = $[ namespace ] || {};
	existingConstructor = $[ namespace ][ name ];
	constructor = $[ namespace ][ name ] = function( options, element ) {

		// Allow instantiation without "new" keyword
		if ( !this._createWidget ) {
			return new constructor( options, element );
		}

		// Allow instantiation without initializing for simple inheritance
		// must use "new" keyword (the code above always passes args)
		if ( arguments.length ) {
			this._createWidget( options, element );
		}
	};

	// Extend with the existing constructor to carry over any static properties
	$.extend( constructor, existingConstructor, {
		version: prototype.version,

		// Copy the object used to create the prototype in case we need to
		// redefine the widget later
		_proto: $.extend( {}, prototype ),

		// Track widgets that inherit from this widget in case this widget is
		// redefined after a widget inherits from it
		_childConstructors: []
	} );

	basePrototype = new base();

	// We need to make the options hash a property directly on the new instance
	// otherwise we'll modify the options hash on the prototype that we're
	// inheriting from
	basePrototype.options = $.widget.extend( {}, basePrototype.options );
	$.each( prototype, function( prop, value ) {
		if ( !$.isFunction( value ) ) {
			proxiedPrototype[ prop ] = value;
			return;
		}
		proxiedPrototype[ prop ] = ( function() {
			function _super() {
				return base.prototype[ prop ].apply( this, arguments );
			}

			function _superApply( args ) {
				return base.prototype[ prop ].apply( this, args );
			}

			return function() {
				var __super = this._super;
				var __superApply = this._superApply;
				var returnValue;

				this._super = _super;
				this._superApply = _superApply;

				returnValue = value.apply( this, arguments );

				this._super = __super;
				this._superApply = __superApply;

				return returnValue;
			};
		} )();
	} );
	constructor.prototype = $.widget.extend( basePrototype, {

		// TODO: remove support for widgetEventPrefix
		// always use the name + a colon as the prefix, e.g., draggable:start
		// don't prefix for widgets that aren't DOM-based
		widgetEventPrefix: existingConstructor ? ( basePrototype.widgetEventPrefix || name ) : name
	}, proxiedPrototype, {
		constructor: constructor,
		namespace: namespace,
		widgetName: name,
		widgetFullName: fullName
	} );

	// If this widget is being redefined then we need to find all widgets that
	// are inheriting from it and redefine all of them so that they inherit from
	// the new version of this widget. We're essentially trying to replace one
	// level in the prototype chain.
	if ( existingConstructor ) {
		$.each( existingConstructor._childConstructors, function( i, child ) {
			var childPrototype = child.prototype;

			// Redefine the child widget using the same prototype that was
			// originally used, but inherit from the new version of the base
			$.widget( childPrototype.namespace + "." + childPrototype.widgetName, constructor,
				child._proto );
		} );

		// Remove the list of existing child constructors from the old constructor
		// so the old child constructors can be garbage collected
		delete existingConstructor._childConstructors;
	} else {
		base._childConstructors.push( constructor );
	}

	$.widget.bridge( name, constructor );

	return constructor;
};

$.widget.extend = function( target ) {
	var input = widgetSlice.call( arguments, 1 );
	var inputIndex = 0;
	var inputLength = input.length;
	var key;
	var value;

	for ( ; inputIndex < inputLength; inputIndex++ ) {
		for ( key in input[ inputIndex ] ) {
			value = input[ inputIndex ][ key ];
			if ( input[ inputIndex ].hasOwnProperty( key ) && value !== undefined ) {

				// Clone objects
				if ( $.isPlainObject( value ) ) {
					target[ key ] = $.isPlainObject( target[ key ] ) ?
						$.widget.extend( {}, target[ key ], value ) :

						// Don't extend strings, arrays, etc. with objects
						$.widget.extend( {}, value );

				// Copy everything else by reference
				} else {
					target[ key ] = value;
				}
			}
		}
	}
	return target;
};

$.widget.bridge = function( name, object ) {
	var fullName = object.prototype.widgetFullName || name;
	$.fn[ name ] = function( options ) {
		var isMethodCall = typeof options === "string";
		var args = widgetSlice.call( arguments, 1 );
		var returnValue = this;

		if ( isMethodCall ) {

			// If this is an empty collection, we need to have the instance method
			// return undefined instead of the jQuery instance
			if ( !this.length && options === "instance" ) {
				returnValue = undefined;
			} else {
				this.each( function() {
					var methodValue;
					var instance = $.data( this, fullName );

					if ( options === "instance" ) {
						returnValue = instance;
						return false;
					}

					if ( !instance ) {
						return $.error( "cannot call methods on " + name +
							" prior to initialization; " +
							"attempted to call method '" + options + "'" );
					}

					if ( !$.isFunction( instance[ options ] ) || options.charAt( 0 ) === "_" ) {
						return $.error( "no such method '" + options + "' for " + name +
							" widget instance" );
					}

					methodValue = instance[ options ].apply( instance, args );

					if ( methodValue !== instance && methodValue !== undefined ) {
						returnValue = methodValue && methodValue.jquery ?
							returnValue.pushStack( methodValue.get() ) :
							methodValue;
						return false;
					}
				} );
			}
		} else {

			// Allow multiple hashes to be passed on init
			if ( args.length ) {
				options = $.widget.extend.apply( null, [ options ].concat( args ) );
			}

			this.each( function() {
				var instance = $.data( this, fullName );
				if ( instance ) {
					instance.option( options || {} );
					if ( instance._init ) {
						instance._init();
					}
				} else {
					$.data( this, fullName, new object( options, this ) );
				}
			} );
		}

		return returnValue;
	};
};

$.Widget = function( /* options, element */ ) {};
$.Widget._childConstructors = [];

$.Widget.prototype = {
	widgetName: "widget",
	widgetEventPrefix: "",
	defaultElement: "<div>",

	options: {
		classes: {},
		disabled: false,

		// Callbacks
		create: null
	},

	_createWidget: function( options, element ) {
		element = $( element || this.defaultElement || this )[ 0 ];
		this.element = $( element );
		this.uuid = widgetUuid++;
		this.eventNamespace = "." + this.widgetName + this.uuid;

		this.bindings = $();
		this.hoverable = $();
		this.focusable = $();
		this.classesElementLookup = {};

		if ( element !== this ) {
			$.data( element, this.widgetFullName, this );
			this._on( true, this.element, {
				remove: function( event ) {
					if ( event.target === element ) {
						this.destroy();
					}
				}
			} );
			this.document = $( element.style ?

				// Element within the document
				element.ownerDocument :

				// Element is window or document
				element.document || element );
			this.window = $( this.document[ 0 ].defaultView || this.document[ 0 ].parentWindow );
		}

		this.options = $.widget.extend( {},
			this.options,
			this._getCreateOptions(),
			options );

		this._create();

		if ( this.options.disabled ) {
			this._setOptionDisabled( this.options.disabled );
		}

		this._trigger( "create", null, this._getCreateEventData() );
		this._init();
	},

	_getCreateOptions: function() {
		return {};
	},

	_getCreateEventData: $.noop,

	_create: $.noop,

	_init: $.noop,

	destroy: function() {
		var that = this;

		this._destroy();
		$.each( this.classesElementLookup, function( key, value ) {
			that._removeClass( value, key );
		} );

		// We can probably remove the unbind calls in 2.0
		// all event bindings should go through this._on()
		this.element
			.off( this.eventNamespace )
			.removeData( this.widgetFullName );
		this.widget()
			.off( this.eventNamespace )
			.removeAttr( "aria-disabled" );

		// Clean up events and states
		this.bindings.off( this.eventNamespace );
	},

	_destroy: $.noop,

	widget: function() {
		return this.element;
	},

	option: function( key, value ) {
		var options = key;
		var parts;
		var curOption;
		var i;

		if ( arguments.length === 0 ) {

			// Don't return a reference to the internal hash
			return $.widget.extend( {}, this.options );
		}

		if ( typeof key === "string" ) {

			// Handle nested keys, e.g., "foo.bar" => { foo: { bar: ___ } }
			options = {};
			parts = key.split( "." );
			key = parts.shift();
			if ( parts.length ) {
				curOption = options[ key ] = $.widget.extend( {}, this.options[ key ] );
				for ( i = 0; i < parts.length - 1; i++ ) {
					curOption[ parts[ i ] ] = curOption[ parts[ i ] ] || {};
					curOption = curOption[ parts[ i ] ];
				}
				key = parts.pop();
				if ( arguments.length === 1 ) {
					return curOption[ key ] === undefined ? null : curOption[ key ];
				}
				curOption[ key ] = value;
			} else {
				if ( arguments.length === 1 ) {
					return this.options[ key ] === undefined ? null : this.options[ key ];
				}
				options[ key ] = value;
			}
		}

		this._setOptions( options );

		return this;
	},

	_setOptions: function( options ) {
		var key;

		for ( key in options ) {
			this._setOption( key, options[ key ] );
		}

		return this;
	},

	_setOption: function( key, value ) {
		if ( key === "classes" ) {
			this._setOptionClasses( value );
		}

		this.options[ key ] = value;

		if ( key === "disabled" ) {
			this._setOptionDisabled( value );
		}

		return this;
	},

	_setOptionClasses: function( value ) {
		var classKey, elements, currentElements;

		for ( classKey in value ) {
			currentElements = this.classesElementLookup[ classKey ];
			if ( value[ classKey ] === this.options.classes[ classKey ] ||
					!currentElements ||
					!currentElements.length ) {
				continue;
			}

			// We are doing this to create a new jQuery object because the _removeClass() call
			// on the next line is going to destroy the reference to the current elements being
			// tracked. We need to save a copy of this collection so that we can add the new classes
			// below.
			elements = $( currentElements.get() );
			this._removeClass( currentElements, classKey );

			// We don't use _addClass() here, because that uses this.options.classes
			// for generating the string of classes. We want to use the value passed in from
			// _setOption(), this is the new value of the classes option which was passed to
			// _setOption(). We pass this value directly to _classes().
			elements.addClass( this._classes( {
				element: elements,
				keys: classKey,
				classes: value,
				add: true
			} ) );
		}
	},

	_setOptionDisabled: function( value ) {
		this._toggleClass( this.widget(), this.widgetFullName + "-disabled", null, !!value );

		// If the widget is becoming disabled, then nothing is interactive
		if ( value ) {
			this._removeClass( this.hoverable, null, "ui-state-hover" );
			this._removeClass( this.focusable, null, "ui-state-focus" );
		}
	},

	enable: function() {
		return this._setOptions( { disabled: false } );
	},

	disable: function() {
		return this._setOptions( { disabled: true } );
	},

	_classes: function( options ) {
		var full = [];
		var that = this;

		options = $.extend( {
			element: this.element,
			classes: this.options.classes || {}
		}, options );

		function processClassString( classes, checkOption ) {
			var current, i;
			for ( i = 0; i < classes.length; i++ ) {
				current = that.classesElementLookup[ classes[ i ] ] || $();
				if ( options.add ) {
					current = $( $.unique( current.get().concat( options.element.get() ) ) );
				} else {
					current = $( current.not( options.element ).get() );
				}
				that.classesElementLookup[ classes[ i ] ] = current;
				full.push( classes[ i ] );
				if ( checkOption && options.classes[ classes[ i ] ] ) {
					full.push( options.classes[ classes[ i ] ] );
				}
			}
		}

		this._on( options.element, {
			"remove": "_untrackClassesElement"
		} );

		if ( options.keys ) {
			processClassString( options.keys.match( /\S+/g ) || [], true );
		}
		if ( options.extra ) {
			processClassString( options.extra.match( /\S+/g ) || [] );
		}

		return full.join( " " );
	},

	_untrackClassesElement: function( event ) {
		var that = this;
		$.each( that.classesElementLookup, function( key, value ) {
			if ( $.inArray( event.target, value ) !== -1 ) {
				that.classesElementLookup[ key ] = $( value.not( event.target ).get() );
			}
		} );
	},

	_removeClass: function( element, keys, extra ) {
		return this._toggleClass( element, keys, extra, false );
	},

	_addClass: function( element, keys, extra ) {
		return this._toggleClass( element, keys, extra, true );
	},

	_toggleClass: function( element, keys, extra, add ) {
		add = ( typeof add === "boolean" ) ? add : extra;
		var shift = ( typeof element === "string" || element === null ),
			options = {
				extra: shift ? keys : extra,
				keys: shift ? element : keys,
				element: shift ? this.element : element,
				add: add
			};
		options.element.toggleClass( this._classes( options ), add );
		return this;
	},

	_on: function( suppressDisabledCheck, element, handlers ) {
		var delegateElement;
		var instance = this;

		// No suppressDisabledCheck flag, shuffle arguments
		if ( typeof suppressDisabledCheck !== "boolean" ) {
			handlers = element;
			element = suppressDisabledCheck;
			suppressDisabledCheck = false;
		}

		// No element argument, shuffle and use this.element
		if ( !handlers ) {
			handlers = element;
			element = this.element;
			delegateElement = this.widget();
		} else {
			element = delegateElement = $( element );
			this.bindings = this.bindings.add( element );
		}

		$.each( handlers, function( event, handler ) {
			function handlerProxy() {

				// Allow widgets to customize the disabled handling
				// - disabled as an array instead of boolean
				// - disabled class as method for disabling individual parts
				if ( !suppressDisabledCheck &&
						( instance.options.disabled === true ||
						$( this ).hasClass( "ui-state-disabled" ) ) ) {
					return;
				}
				return ( typeof handler === "string" ? instance[ handler ] : handler )
					.apply( instance, arguments );
			}

			// Copy the guid so direct unbinding works
			if ( typeof handler !== "string" ) {
				handlerProxy.guid = handler.guid =
					handler.guid || handlerProxy.guid || $.guid++;
			}

			var match = event.match( /^([\w:-]*)\s*(.*)$/ );
			var eventName = match[ 1 ] + instance.eventNamespace;
			var selector = match[ 2 ];

			if ( selector ) {
				delegateElement.on( eventName, selector, handlerProxy );
			} else {
				element.on( eventName, handlerProxy );
			}
		} );
	},

	_off: function( element, eventName ) {
		eventName = ( eventName || "" ).split( " " ).join( this.eventNamespace + " " ) +
			this.eventNamespace;
		element.off( eventName ).off( eventName );

		// Clear the stack to avoid memory leaks (#10056)
		this.bindings = $( this.bindings.not( element ).get() );
		this.focusable = $( this.focusable.not( element ).get() );
		this.hoverable = $( this.hoverable.not( element ).get() );
	},

	_delay: function( handler, delay ) {
		function handlerProxy() {
			return ( typeof handler === "string" ? instance[ handler ] : handler )
				.apply( instance, arguments );
		}
		var instance = this;
		return setTimeout( handlerProxy, delay || 0 );
	},

	_hoverable: function( element ) {
		this.hoverable = this.hoverable.add( element );
		this._on( element, {
			mouseenter: function( event ) {
				this._addClass( $( event.currentTarget ), null, "ui-state-hover" );
			},
			mouseleave: function( event ) {
				this._removeClass( $( event.currentTarget ), null, "ui-state-hover" );
			}
		} );
	},

	_focusable: function( element ) {
		this.focusable = this.focusable.add( element );
		this._on( element, {
			focusin: function( event ) {
				this._addClass( $( event.currentTarget ), null, "ui-state-focus" );
			},
			focusout: function( event ) {
				this._removeClass( $( event.currentTarget ), null, "ui-state-focus" );
			}
		} );
	},

	_trigger: function( type, event, data ) {
		var prop, orig;
		var callback = this.options[ type ];

		data = data || {};
		event = $.Event( event );
		event.type = ( type === this.widgetEventPrefix ?
			type :
			this.widgetEventPrefix + type ).toLowerCase();

		// The original event may come from any element
		// so we need to reset the target on the new event
		event.target = this.element[ 0 ];

		// Copy original event properties over to the new event
		orig = event.originalEvent;
		if ( orig ) {
			for ( prop in orig ) {
				if ( !( prop in event ) ) {
					event[ prop ] = orig[ prop ];
				}
			}
		}

		this.element.trigger( event, data );
		return !( $.isFunction( callback ) &&
			callback.apply( this.element[ 0 ], [ event ].concat( data ) ) === false ||
			event.isDefaultPrevented() );
	}
};

$.each( { show: "fadeIn", hide: "fadeOut" }, function( method, defaultEffect ) {
	$.Widget.prototype[ "_" + method ] = function( element, options, callback ) {
		if ( typeof options === "string" ) {
			options = { effect: options };
		}

		var hasOptions;
		var effectName = !options ?
			method :
			options === true || typeof options === "number" ?
				defaultEffect :
				options.effect || defaultEffect;

		options = options || {};
		if ( typeof options === "number" ) {
			options = { duration: options };
		}

		hasOptions = !$.isEmptyObject( options );
		options.complete = callback;

		if ( options.delay ) {
			element.delay( options.delay );
		}

		if ( hasOptions && $.effects && $.effects.effect[ effectName ] ) {
			element[ method ]( options );
		} else if ( effectName !== method && element[ effectName ] ) {
			element[ effectName ]( options.duration, options.easing, callback );
		} else {
			element.queue( function( next ) {
				$( this )[ method ]();
				if ( callback ) {
					callback.call( element[ 0 ] );
				}
				next();
			} );
		}
	};
} );

var widget = $.widget;


/*!
 * jQuery UI Position 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 *
 * http://api.jqueryui.com/position/
 */

//>>label: Position
//>>group: Core
//>>description: Positions elements relative to other elements.
//>>docs: http://api.jqueryui.com/position/
//>>demos: http://jqueryui.com/position/


( function() {
var cachedScrollbarWidth,
	max = Math.max,
	abs = Math.abs,
	rhorizontal = /left|center|right/,
	rvertical = /top|center|bottom/,
	roffset = /[\+\-]\d+(\.[\d]+)?%?/,
	rposition = /^\w+/,
	rpercent = /%$/,
	_position = $.fn.position;

function getOffsets( offsets, width, height ) {
	return [
		parseFloat( offsets[ 0 ] ) * ( rpercent.test( offsets[ 0 ] ) ? width / 100 : 1 ),
		parseFloat( offsets[ 1 ] ) * ( rpercent.test( offsets[ 1 ] ) ? height / 100 : 1 )
	];
}

function parseCss( element, property ) {
	return parseInt( $.css( element, property ), 10 ) || 0;
}

function getDimensions( elem ) {
	var raw = elem[ 0 ];
	if ( raw.nodeType === 9 ) {
		return {
			width: elem.width(),
			height: elem.height(),
			offset: { top: 0, left: 0 }
		};
	}
	if ( $.isWindow( raw ) ) {
		return {
			width: elem.width(),
			height: elem.height(),
			offset: { top: elem.scrollTop(), left: elem.scrollLeft() }
		};
	}
	if ( raw.preventDefault ) {
		return {
			width: 0,
			height: 0,
			offset: { top: raw.pageY, left: raw.pageX }
		};
	}
	return {
		width: elem.outerWidth(),
		height: elem.outerHeight(),
		offset: elem.offset()
	};
}

$.position = {
	scrollbarWidth: function() {
		if ( cachedScrollbarWidth !== undefined ) {
			return cachedScrollbarWidth;
		}
		var w1, w2,
			div = $( "<div " +
				"style='display:block;position:absolute;width:50px;height:50px;overflow:hidden;'>" +
				"<div style='height:100px;width:auto;'></div></div>" ),
			innerDiv = div.children()[ 0 ];

		$( "body" ).append( div );
		w1 = innerDiv.offsetWidth;
		div.css( "overflow", "scroll" );

		w2 = innerDiv.offsetWidth;

		if ( w1 === w2 ) {
			w2 = div[ 0 ].clientWidth;
		}

		div.remove();

		return ( cachedScrollbarWidth = w1 - w2 );
	},
	getScrollInfo: function( within ) {
		var overflowX = within.isWindow || within.isDocument ? "" :
				within.element.css( "overflow-x" ),
			overflowY = within.isWindow || within.isDocument ? "" :
				within.element.css( "overflow-y" ),
			hasOverflowX = overflowX === "scroll" ||
				( overflowX === "auto" && within.width < within.element[ 0 ].scrollWidth ),
			hasOverflowY = overflowY === "scroll" ||
				( overflowY === "auto" && within.height < within.element[ 0 ].scrollHeight );
		return {
			width: hasOverflowY ? $.position.scrollbarWidth() : 0,
			height: hasOverflowX ? $.position.scrollbarWidth() : 0
		};
	},
	getWithinInfo: function( element ) {
		var withinElement = $( element || window ),
			isWindow = $.isWindow( withinElement[ 0 ] ),
			isDocument = !!withinElement[ 0 ] && withinElement[ 0 ].nodeType === 9,
			hasOffset = !isWindow && !isDocument;
		return {
			element: withinElement,
			isWindow: isWindow,
			isDocument: isDocument,
			offset: hasOffset ? $( element ).offset() : { left: 0, top: 0 },
			scrollLeft: withinElement.scrollLeft(),
			scrollTop: withinElement.scrollTop(),
			width: withinElement.outerWidth(),
			height: withinElement.outerHeight()
		};
	}
};

$.fn.position = function( options ) {
	if ( !options || !options.of ) {
		return _position.apply( this, arguments );
	}

	// Make a copy, we don't want to modify arguments
	options = $.extend( {}, options );

	var atOffset, targetWidth, targetHeight, targetOffset, basePosition, dimensions,
		target = $( options.of ),
		within = $.position.getWithinInfo( options.within ),
		scrollInfo = $.position.getScrollInfo( within ),
		collision = ( options.collision || "flip" ).split( " " ),
		offsets = {};

	dimensions = getDimensions( target );
	if ( target[ 0 ].preventDefault ) {

		// Force left top to allow flipping
		options.at = "left top";
	}
	targetWidth = dimensions.width;
	targetHeight = dimensions.height;
	targetOffset = dimensions.offset;

	// Clone to reuse original targetOffset later
	basePosition = $.extend( {}, targetOffset );

	// Force my and at to have valid horizontal and vertical positions
	// if a value is missing or invalid, it will be converted to center
	$.each( [ "my", "at" ], function() {
		var pos = ( options[ this ] || "" ).split( " " ),
			horizontalOffset,
			verticalOffset;

		if ( pos.length === 1 ) {
			pos = rhorizontal.test( pos[ 0 ] ) ?
				pos.concat( [ "center" ] ) :
				rvertical.test( pos[ 0 ] ) ?
					[ "center" ].concat( pos ) :
					[ "center", "center" ];
		}
		pos[ 0 ] = rhorizontal.test( pos[ 0 ] ) ? pos[ 0 ] : "center";
		pos[ 1 ] = rvertical.test( pos[ 1 ] ) ? pos[ 1 ] : "center";

		// Calculate offsets
		horizontalOffset = roffset.exec( pos[ 0 ] );
		verticalOffset = roffset.exec( pos[ 1 ] );
		offsets[ this ] = [
			horizontalOffset ? horizontalOffset[ 0 ] : 0,
			verticalOffset ? verticalOffset[ 0 ] : 0
		];

		// Reduce to just the positions without the offsets
		options[ this ] = [
			rposition.exec( pos[ 0 ] )[ 0 ],
			rposition.exec( pos[ 1 ] )[ 0 ]
		];
	} );

	// Normalize collision option
	if ( collision.length === 1 ) {
		collision[ 1 ] = collision[ 0 ];
	}

	if ( options.at[ 0 ] === "right" ) {
		basePosition.left += targetWidth;
	} else if ( options.at[ 0 ] === "center" ) {
		basePosition.left += targetWidth / 2;
	}

	if ( options.at[ 1 ] === "bottom" ) {
		basePosition.top += targetHeight;
	} else if ( options.at[ 1 ] === "center" ) {
		basePosition.top += targetHeight / 2;
	}

	atOffset = getOffsets( offsets.at, targetWidth, targetHeight );
	basePosition.left += atOffset[ 0 ];
	basePosition.top += atOffset[ 1 ];

	return this.each( function() {
		var collisionPosition, using,
			elem = $( this ),
			elemWidth = elem.outerWidth(),
			elemHeight = elem.outerHeight(),
			marginLeft = parseCss( this, "marginLeft" ),
			marginTop = parseCss( this, "marginTop" ),
			collisionWidth = elemWidth + marginLeft + parseCss( this, "marginRight" ) +
				scrollInfo.width,
			collisionHeight = elemHeight + marginTop + parseCss( this, "marginBottom" ) +
				scrollInfo.height,
			position = $.extend( {}, basePosition ),
			myOffset = getOffsets( offsets.my, elem.outerWidth(), elem.outerHeight() );

		if ( options.my[ 0 ] === "right" ) {
			position.left -= elemWidth;
		} else if ( options.my[ 0 ] === "center" ) {
			position.left -= elemWidth / 2;
		}

		if ( options.my[ 1 ] === "bottom" ) {
			position.top -= elemHeight;
		} else if ( options.my[ 1 ] === "center" ) {
			position.top -= elemHeight / 2;
		}

		position.left += myOffset[ 0 ];
		position.top += myOffset[ 1 ];

		collisionPosition = {
			marginLeft: marginLeft,
			marginTop: marginTop
		};

		$.each( [ "left", "top" ], function( i, dir ) {
			if ( $.ui.position[ collision[ i ] ] ) {
				$.ui.position[ collision[ i ] ][ dir ]( position, {
					targetWidth: targetWidth,
					targetHeight: targetHeight,
					elemWidth: elemWidth,
					elemHeight: elemHeight,
					collisionPosition: collisionPosition,
					collisionWidth: collisionWidth,
					collisionHeight: collisionHeight,
					offset: [ atOffset[ 0 ] + myOffset[ 0 ], atOffset [ 1 ] + myOffset[ 1 ] ],
					my: options.my,
					at: options.at,
					within: within,
					elem: elem
				} );
			}
		} );

		if ( options.using ) {

			// Adds feedback as second argument to using callback, if present
			using = function( props ) {
				var left = targetOffset.left - position.left,
					right = left + targetWidth - elemWidth,
					top = targetOffset.top - position.top,
					bottom = top + targetHeight - elemHeight,
					feedback = {
						target: {
							element: target,
							left: targetOffset.left,
							top: targetOffset.top,
							width: targetWidth,
							height: targetHeight
						},
						element: {
							element: elem,
							left: position.left,
							top: position.top,
							width: elemWidth,
							height: elemHeight
						},
						horizontal: right < 0 ? "left" : left > 0 ? "right" : "center",
						vertical: bottom < 0 ? "top" : top > 0 ? "bottom" : "middle"
					};
				if ( targetWidth < elemWidth && abs( left + right ) < targetWidth ) {
					feedback.horizontal = "center";
				}
				if ( targetHeight < elemHeight && abs( top + bottom ) < targetHeight ) {
					feedback.vertical = "middle";
				}
				if ( max( abs( left ), abs( right ) ) > max( abs( top ), abs( bottom ) ) ) {
					feedback.important = "horizontal";
				} else {
					feedback.important = "vertical";
				}
				options.using.call( this, props, feedback );
			};
		}

		elem.offset( $.extend( position, { using: using } ) );
	} );
};

$.ui.position = {
	fit: {
		left: function( position, data ) {
			var within = data.within,
				withinOffset = within.isWindow ? within.scrollLeft : within.offset.left,
				outerWidth = within.width,
				collisionPosLeft = position.left - data.collisionPosition.marginLeft,
				overLeft = withinOffset - collisionPosLeft,
				overRight = collisionPosLeft + data.collisionWidth - outerWidth - withinOffset,
				newOverRight;

			// Element is wider than within
			if ( data.collisionWidth > outerWidth ) {

				// Element is initially over the left side of within
				if ( overLeft > 0 && overRight <= 0 ) {
					newOverRight = position.left + overLeft + data.collisionWidth - outerWidth -
						withinOffset;
					position.left += overLeft - newOverRight;

				// Element is initially over right side of within
				} else if ( overRight > 0 && overLeft <= 0 ) {
					position.left = withinOffset;

				// Element is initially over both left and right sides of within
				} else {
					if ( overLeft > overRight ) {
						position.left = withinOffset + outerWidth - data.collisionWidth;
					} else {
						position.left = withinOffset;
					}
				}

			// Too far left -> align with left edge
			} else if ( overLeft > 0 ) {
				position.left += overLeft;

			// Too far right -> align with right edge
			} else if ( overRight > 0 ) {
				position.left -= overRight;

			// Adjust based on position and margin
			} else {
				position.left = max( position.left - collisionPosLeft, position.left );
			}
		},
		top: function( position, data ) {
			var within = data.within,
				withinOffset = within.isWindow ? within.scrollTop : within.offset.top,
				outerHeight = data.within.height,
				collisionPosTop = position.top - data.collisionPosition.marginTop,
				overTop = withinOffset - collisionPosTop,
				overBottom = collisionPosTop + data.collisionHeight - outerHeight - withinOffset,
				newOverBottom;

			// Element is taller than within
			if ( data.collisionHeight > outerHeight ) {

				// Element is initially over the top of within
				if ( overTop > 0 && overBottom <= 0 ) {
					newOverBottom = position.top + overTop + data.collisionHeight - outerHeight -
						withinOffset;
					position.top += overTop - newOverBottom;

				// Element is initially over bottom of within
				} else if ( overBottom > 0 && overTop <= 0 ) {
					position.top = withinOffset;

				// Element is initially over both top and bottom of within
				} else {
					if ( overTop > overBottom ) {
						position.top = withinOffset + outerHeight - data.collisionHeight;
					} else {
						position.top = withinOffset;
					}
				}

			// Too far up -> align with top
			} else if ( overTop > 0 ) {
				position.top += overTop;

			// Too far down -> align with bottom edge
			} else if ( overBottom > 0 ) {
				position.top -= overBottom;

			// Adjust based on position and margin
			} else {
				position.top = max( position.top - collisionPosTop, position.top );
			}
		}
	},
	flip: {
		left: function( position, data ) {
			var within = data.within,
				withinOffset = within.offset.left + within.scrollLeft,
				outerWidth = within.width,
				offsetLeft = within.isWindow ? within.scrollLeft : within.offset.left,
				collisionPosLeft = position.left - data.collisionPosition.marginLeft,
				overLeft = collisionPosLeft - offsetLeft,
				overRight = collisionPosLeft + data.collisionWidth - outerWidth - offsetLeft,
				myOffset = data.my[ 0 ] === "left" ?
					-data.elemWidth :
					data.my[ 0 ] === "right" ?
						data.elemWidth :
						0,
				atOffset = data.at[ 0 ] === "left" ?
					data.targetWidth :
					data.at[ 0 ] === "right" ?
						-data.targetWidth :
						0,
				offset = -2 * data.offset[ 0 ],
				newOverRight,
				newOverLeft;

			if ( overLeft < 0 ) {
				newOverRight = position.left + myOffset + atOffset + offset + data.collisionWidth -
					outerWidth - withinOffset;
				if ( newOverRight < 0 || newOverRight < abs( overLeft ) ) {
					position.left += myOffset + atOffset + offset;
				}
			} else if ( overRight > 0 ) {
				newOverLeft = position.left - data.collisionPosition.marginLeft + myOffset +
					atOffset + offset - offsetLeft;
				if ( newOverLeft > 0 || abs( newOverLeft ) < overRight ) {
					position.left += myOffset + atOffset + offset;
				}
			}
		},
		top: function( position, data ) {
			var within = data.within,
				withinOffset = within.offset.top + within.scrollTop,
				outerHeight = within.height,
				offsetTop = within.isWindow ? within.scrollTop : within.offset.top,
				collisionPosTop = position.top - data.collisionPosition.marginTop,
				overTop = collisionPosTop - offsetTop,
				overBottom = collisionPosTop + data.collisionHeight - outerHeight - offsetTop,
				top = data.my[ 1 ] === "top",
				myOffset = top ?
					-data.elemHeight :
					data.my[ 1 ] === "bottom" ?
						data.elemHeight :
						0,
				atOffset = data.at[ 1 ] === "top" ?
					data.targetHeight :
					data.at[ 1 ] === "bottom" ?
						-data.targetHeight :
						0,
				offset = -2 * data.offset[ 1 ],
				newOverTop,
				newOverBottom;
			if ( overTop < 0 ) {
				newOverBottom = position.top + myOffset + atOffset + offset + data.collisionHeight -
					outerHeight - withinOffset;
				if ( newOverBottom < 0 || newOverBottom < abs( overTop ) ) {
					position.top += myOffset + atOffset + offset;
				}
			} else if ( overBottom > 0 ) {
				newOverTop = position.top - data.collisionPosition.marginTop + myOffset + atOffset +
					offset - offsetTop;
				if ( newOverTop > 0 || abs( newOverTop ) < overBottom ) {
					position.top += myOffset + atOffset + offset;
				}
			}
		}
	},
	flipfit: {
		left: function() {
			$.ui.position.flip.left.apply( this, arguments );
			$.ui.position.fit.left.apply( this, arguments );
		},
		top: function() {
			$.ui.position.flip.top.apply( this, arguments );
			$.ui.position.fit.top.apply( this, arguments );
		}
	}
};

} )();

var position = $.ui.position;


/*!
 * jQuery UI :data 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: :data Selector
//>>group: Core
//>>description: Selects elements which have data stored under the specified key.
//>>docs: http://api.jqueryui.com/data-selector/


var data = $.extend( $.expr[ ":" ], {
	data: $.expr.createPseudo ?
		$.expr.createPseudo( function( dataName ) {
			return function( elem ) {
				return !!$.data( elem, dataName );
			};
		} ) :

		// Support: jQuery <1.8
		function( elem, i, match ) {
			return !!$.data( elem, match[ 3 ] );
		}
} );

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

//>>label: disableSelection
//>>group: Core
//>>description: Disable selection of text content within the set of matched elements.
//>>docs: http://api.jqueryui.com/disableSelection/

// This file is deprecated


var disableSelection = $.fn.extend( {
	disableSelection: ( function() {
		var eventType = "onselectstart" in document.createElement( "div" ) ?
			"selectstart" :
			"mousedown";

		return function() {
			return this.on( eventType + ".ui-disableSelection", function( event ) {
				event.preventDefault();
			} );
		};
	} )(),

	enableSelection: function() {
		return this.off( ".ui-disableSelection" );
	}
} );


/*!
 * jQuery UI Effects 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Effects Core
//>>group: Effects
// jscs:disable maximumLineLength
//>>description: Extends the internal jQuery effects. Includes morphing and easing. Required by all other effects.
// jscs:enable maximumLineLength
//>>docs: http://api.jqueryui.com/category/effects-core/
//>>demos: http://jqueryui.com/effect/



var dataSpace = "ui-effects-",
	dataSpaceStyle = "ui-effects-style",
	dataSpaceAnimated = "ui-effects-animated",

	// Create a local jQuery because jQuery Color relies on it and the
	// global may not exist with AMD and a custom build (#10199)
	jQuery = $;

$.effects = {
	effect: {}
};

/*!
 * jQuery Color Animations v2.1.2
 * https://github.com/jquery/jquery-color
 *
 * Copyright 2014 jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 *
 * Date: Wed Jan 16 08:47:09 2013 -0600
 */
( function( jQuery, undefined ) {

	var stepHooks = "backgroundColor borderBottomColor borderLeftColor borderRightColor " +
		"borderTopColor color columnRuleColor outlineColor textDecorationColor textEmphasisColor",

	// Plusequals test for += 100 -= 100
	rplusequals = /^([\-+])=\s*(\d+\.?\d*)/,

	// A set of RE's that can match strings and generate color tuples.
	stringParsers = [ {
			re: /rgba?\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,
			parse: function( execResult ) {
				return [
					execResult[ 1 ],
					execResult[ 2 ],
					execResult[ 3 ],
					execResult[ 4 ]
				];
			}
		}, {
			re: /rgba?\(\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,
			parse: function( execResult ) {
				return [
					execResult[ 1 ] * 2.55,
					execResult[ 2 ] * 2.55,
					execResult[ 3 ] * 2.55,
					execResult[ 4 ]
				];
			}
		}, {

			// This regex ignores A-F because it's compared against an already lowercased string
			re: /#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})/,
			parse: function( execResult ) {
				return [
					parseInt( execResult[ 1 ], 16 ),
					parseInt( execResult[ 2 ], 16 ),
					parseInt( execResult[ 3 ], 16 )
				];
			}
		}, {

			// This regex ignores A-F because it's compared against an already lowercased string
			re: /#([a-f0-9])([a-f0-9])([a-f0-9])/,
			parse: function( execResult ) {
				return [
					parseInt( execResult[ 1 ] + execResult[ 1 ], 16 ),
					parseInt( execResult[ 2 ] + execResult[ 2 ], 16 ),
					parseInt( execResult[ 3 ] + execResult[ 3 ], 16 )
				];
			}
		}, {
			re: /hsla?\(\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,
			space: "hsla",
			parse: function( execResult ) {
				return [
					execResult[ 1 ],
					execResult[ 2 ] / 100,
					execResult[ 3 ] / 100,
					execResult[ 4 ]
				];
			}
		} ],

	// JQuery.Color( )
	color = jQuery.Color = function( color, green, blue, alpha ) {
		return new jQuery.Color.fn.parse( color, green, blue, alpha );
	},
	spaces = {
		rgba: {
			props: {
				red: {
					idx: 0,
					type: "byte"
				},
				green: {
					idx: 1,
					type: "byte"
				},
				blue: {
					idx: 2,
					type: "byte"
				}
			}
		},

		hsla: {
			props: {
				hue: {
					idx: 0,
					type: "degrees"
				},
				saturation: {
					idx: 1,
					type: "percent"
				},
				lightness: {
					idx: 2,
					type: "percent"
				}
			}
		}
	},
	propTypes = {
		"byte": {
			floor: true,
			max: 255
		},
		"percent": {
			max: 1
		},
		"degrees": {
			mod: 360,
			floor: true
		}
	},
	support = color.support = {},

	// Element for support tests
	supportElem = jQuery( "<p>" )[ 0 ],

	// Colors = jQuery.Color.names
	colors,

	// Local aliases of functions called often
	each = jQuery.each;

// Determine rgba support immediately
supportElem.style.cssText = "background-color:rgba(1,1,1,.5)";
support.rgba = supportElem.style.backgroundColor.indexOf( "rgba" ) > -1;

// Define cache name and alpha properties
// for rgba and hsla spaces
each( spaces, function( spaceName, space ) {
	space.cache = "_" + spaceName;
	space.props.alpha = {
		idx: 3,
		type: "percent",
		def: 1
	};
} );

function clamp( value, prop, allowEmpty ) {
	var type = propTypes[ prop.type ] || {};

	if ( value == null ) {
		return ( allowEmpty || !prop.def ) ? null : prop.def;
	}

	// ~~ is an short way of doing floor for positive numbers
	value = type.floor ? ~~value : parseFloat( value );

	// IE will pass in empty strings as value for alpha,
	// which will hit this case
	if ( isNaN( value ) ) {
		return prop.def;
	}

	if ( type.mod ) {

		// We add mod before modding to make sure that negatives values
		// get converted properly: -10 -> 350
		return ( value + type.mod ) % type.mod;
	}

	// For now all property types without mod have min and max
	return 0 > value ? 0 : type.max < value ? type.max : value;
}

function stringParse( string ) {
	var inst = color(),
		rgba = inst._rgba = [];

	string = string.toLowerCase();

	each( stringParsers, function( i, parser ) {
		var parsed,
			match = parser.re.exec( string ),
			values = match && parser.parse( match ),
			spaceName = parser.space || "rgba";

		if ( values ) {
			parsed = inst[ spaceName ]( values );

			// If this was an rgba parse the assignment might happen twice
			// oh well....
			inst[ spaces[ spaceName ].cache ] = parsed[ spaces[ spaceName ].cache ];
			rgba = inst._rgba = parsed._rgba;

			// Exit each( stringParsers ) here because we matched
			return false;
		}
	} );

	// Found a stringParser that handled it
	if ( rgba.length ) {

		// If this came from a parsed string, force "transparent" when alpha is 0
		// chrome, (and maybe others) return "transparent" as rgba(0,0,0,0)
		if ( rgba.join() === "0,0,0,0" ) {
			jQuery.extend( rgba, colors.transparent );
		}
		return inst;
	}

	// Named colors
	return colors[ string ];
}

color.fn = jQuery.extend( color.prototype, {
	parse: function( red, green, blue, alpha ) {
		if ( red === undefined ) {
			this._rgba = [ null, null, null, null ];
			return this;
		}
		if ( red.jquery || red.nodeType ) {
			red = jQuery( red ).css( green );
			green = undefined;
		}

		var inst = this,
			type = jQuery.type( red ),
			rgba = this._rgba = [];

		// More than 1 argument specified - assume ( red, green, blue, alpha )
		if ( green !== undefined ) {
			red = [ red, green, blue, alpha ];
			type = "array";
		}

		if ( type === "string" ) {
			return this.parse( stringParse( red ) || colors._default );
		}

		if ( type === "array" ) {
			each( spaces.rgba.props, function( key, prop ) {
				rgba[ prop.idx ] = clamp( red[ prop.idx ], prop );
			} );
			return this;
		}

		if ( type === "object" ) {
			if ( red instanceof color ) {
				each( spaces, function( spaceName, space ) {
					if ( red[ space.cache ] ) {
						inst[ space.cache ] = red[ space.cache ].slice();
					}
				} );
			} else {
				each( spaces, function( spaceName, space ) {
					var cache = space.cache;
					each( space.props, function( key, prop ) {

						// If the cache doesn't exist, and we know how to convert
						if ( !inst[ cache ] && space.to ) {

							// If the value was null, we don't need to copy it
							// if the key was alpha, we don't need to copy it either
							if ( key === "alpha" || red[ key ] == null ) {
								return;
							}
							inst[ cache ] = space.to( inst._rgba );
						}

						// This is the only case where we allow nulls for ALL properties.
						// call clamp with alwaysAllowEmpty
						inst[ cache ][ prop.idx ] = clamp( red[ key ], prop, true );
					} );

					// Everything defined but alpha?
					if ( inst[ cache ] &&
							jQuery.inArray( null, inst[ cache ].slice( 0, 3 ) ) < 0 ) {

						// Use the default of 1
						inst[ cache ][ 3 ] = 1;
						if ( space.from ) {
							inst._rgba = space.from( inst[ cache ] );
						}
					}
				} );
			}
			return this;
		}
	},
	is: function( compare ) {
		var is = color( compare ),
			same = true,
			inst = this;

		each( spaces, function( _, space ) {
			var localCache,
				isCache = is[ space.cache ];
			if ( isCache ) {
				localCache = inst[ space.cache ] || space.to && space.to( inst._rgba ) || [];
				each( space.props, function( _, prop ) {
					if ( isCache[ prop.idx ] != null ) {
						same = ( isCache[ prop.idx ] === localCache[ prop.idx ] );
						return same;
					}
				} );
			}
			return same;
		} );
		return same;
	},
	_space: function() {
		var used = [],
			inst = this;
		each( spaces, function( spaceName, space ) {
			if ( inst[ space.cache ] ) {
				used.push( spaceName );
			}
		} );
		return used.pop();
	},
	transition: function( other, distance ) {
		var end = color( other ),
			spaceName = end._space(),
			space = spaces[ spaceName ],
			startColor = this.alpha() === 0 ? color( "transparent" ) : this,
			start = startColor[ space.cache ] || space.to( startColor._rgba ),
			result = start.slice();

		end = end[ space.cache ];
		each( space.props, function( key, prop ) {
			var index = prop.idx,
				startValue = start[ index ],
				endValue = end[ index ],
				type = propTypes[ prop.type ] || {};

			// If null, don't override start value
			if ( endValue === null ) {
				return;
			}

			// If null - use end
			if ( startValue === null ) {
				result[ index ] = endValue;
			} else {
				if ( type.mod ) {
					if ( endValue - startValue > type.mod / 2 ) {
						startValue += type.mod;
					} else if ( startValue - endValue > type.mod / 2 ) {
						startValue -= type.mod;
					}
				}
				result[ index ] = clamp( ( endValue - startValue ) * distance + startValue, prop );
			}
		} );
		return this[ spaceName ]( result );
	},
	blend: function( opaque ) {

		// If we are already opaque - return ourself
		if ( this._rgba[ 3 ] === 1 ) {
			return this;
		}

		var rgb = this._rgba.slice(),
			a = rgb.pop(),
			blend = color( opaque )._rgba;

		return color( jQuery.map( rgb, function( v, i ) {
			return ( 1 - a ) * blend[ i ] + a * v;
		} ) );
	},
	toRgbaString: function() {
		var prefix = "rgba(",
			rgba = jQuery.map( this._rgba, function( v, i ) {
				return v == null ? ( i > 2 ? 1 : 0 ) : v;
			} );

		if ( rgba[ 3 ] === 1 ) {
			rgba.pop();
			prefix = "rgb(";
		}

		return prefix + rgba.join() + ")";
	},
	toHslaString: function() {
		var prefix = "hsla(",
			hsla = jQuery.map( this.hsla(), function( v, i ) {
				if ( v == null ) {
					v = i > 2 ? 1 : 0;
				}

				// Catch 1 and 2
				if ( i && i < 3 ) {
					v = Math.round( v * 100 ) + "%";
				}
				return v;
			} );

		if ( hsla[ 3 ] === 1 ) {
			hsla.pop();
			prefix = "hsl(";
		}
		return prefix + hsla.join() + ")";
	},
	toHexString: function( includeAlpha ) {
		var rgba = this._rgba.slice(),
			alpha = rgba.pop();

		if ( includeAlpha ) {
			rgba.push( ~~( alpha * 255 ) );
		}

		return "#" + jQuery.map( rgba, function( v ) {

			// Default to 0 when nulls exist
			v = ( v || 0 ).toString( 16 );
			return v.length === 1 ? "0" + v : v;
		} ).join( "" );
	},
	toString: function() {
		return this._rgba[ 3 ] === 0 ? "transparent" : this.toRgbaString();
	}
} );
color.fn.parse.prototype = color.fn;

// Hsla conversions adapted from:
// https://code.google.com/p/maashaack/source/browse/packages/graphics/trunk/src/graphics/colors/HUE2RGB.as?r=5021

function hue2rgb( p, q, h ) {
	h = ( h + 1 ) % 1;
	if ( h * 6 < 1 ) {
		return p + ( q - p ) * h * 6;
	}
	if ( h * 2 < 1 ) {
		return q;
	}
	if ( h * 3 < 2 ) {
		return p + ( q - p ) * ( ( 2 / 3 ) - h ) * 6;
	}
	return p;
}

spaces.hsla.to = function( rgba ) {
	if ( rgba[ 0 ] == null || rgba[ 1 ] == null || rgba[ 2 ] == null ) {
		return [ null, null, null, rgba[ 3 ] ];
	}
	var r = rgba[ 0 ] / 255,
		g = rgba[ 1 ] / 255,
		b = rgba[ 2 ] / 255,
		a = rgba[ 3 ],
		max = Math.max( r, g, b ),
		min = Math.min( r, g, b ),
		diff = max - min,
		add = max + min,
		l = add * 0.5,
		h, s;

	if ( min === max ) {
		h = 0;
	} else if ( r === max ) {
		h = ( 60 * ( g - b ) / diff ) + 360;
	} else if ( g === max ) {
		h = ( 60 * ( b - r ) / diff ) + 120;
	} else {
		h = ( 60 * ( r - g ) / diff ) + 240;
	}

	// Chroma (diff) == 0 means greyscale which, by definition, saturation = 0%
	// otherwise, saturation is based on the ratio of chroma (diff) to lightness (add)
	if ( diff === 0 ) {
		s = 0;
	} else if ( l <= 0.5 ) {
		s = diff / add;
	} else {
		s = diff / ( 2 - add );
	}
	return [ Math.round( h ) % 360, s, l, a == null ? 1 : a ];
};

spaces.hsla.from = function( hsla ) {
	if ( hsla[ 0 ] == null || hsla[ 1 ] == null || hsla[ 2 ] == null ) {
		return [ null, null, null, hsla[ 3 ] ];
	}
	var h = hsla[ 0 ] / 360,
		s = hsla[ 1 ],
		l = hsla[ 2 ],
		a = hsla[ 3 ],
		q = l <= 0.5 ? l * ( 1 + s ) : l + s - l * s,
		p = 2 * l - q;

	return [
		Math.round( hue2rgb( p, q, h + ( 1 / 3 ) ) * 255 ),
		Math.round( hue2rgb( p, q, h ) * 255 ),
		Math.round( hue2rgb( p, q, h - ( 1 / 3 ) ) * 255 ),
		a
	];
};

each( spaces, function( spaceName, space ) {
	var props = space.props,
		cache = space.cache,
		to = space.to,
		from = space.from;

	// Makes rgba() and hsla()
	color.fn[ spaceName ] = function( value ) {

		// Generate a cache for this space if it doesn't exist
		if ( to && !this[ cache ] ) {
			this[ cache ] = to( this._rgba );
		}
		if ( value === undefined ) {
			return this[ cache ].slice();
		}

		var ret,
			type = jQuery.type( value ),
			arr = ( type === "array" || type === "object" ) ? value : arguments,
			local = this[ cache ].slice();

		each( props, function( key, prop ) {
			var val = arr[ type === "object" ? key : prop.idx ];
			if ( val == null ) {
				val = local[ prop.idx ];
			}
			local[ prop.idx ] = clamp( val, prop );
		} );

		if ( from ) {
			ret = color( from( local ) );
			ret[ cache ] = local;
			return ret;
		} else {
			return color( local );
		}
	};

	// Makes red() green() blue() alpha() hue() saturation() lightness()
	each( props, function( key, prop ) {

		// Alpha is included in more than one space
		if ( color.fn[ key ] ) {
			return;
		}
		color.fn[ key ] = function( value ) {
			var vtype = jQuery.type( value ),
				fn = ( key === "alpha" ? ( this._hsla ? "hsla" : "rgba" ) : spaceName ),
				local = this[ fn ](),
				cur = local[ prop.idx ],
				match;

			if ( vtype === "undefined" ) {
				return cur;
			}

			if ( vtype === "function" ) {
				value = value.call( this, cur );
				vtype = jQuery.type( value );
			}
			if ( value == null && prop.empty ) {
				return this;
			}
			if ( vtype === "string" ) {
				match = rplusequals.exec( value );
				if ( match ) {
					value = cur + parseFloat( match[ 2 ] ) * ( match[ 1 ] === "+" ? 1 : -1 );
				}
			}
			local[ prop.idx ] = value;
			return this[ fn ]( local );
		};
	} );
} );

// Add cssHook and .fx.step function for each named hook.
// accept a space separated string of properties
color.hook = function( hook ) {
	var hooks = hook.split( " " );
	each( hooks, function( i, hook ) {
		jQuery.cssHooks[ hook ] = {
			set: function( elem, value ) {
				var parsed, curElem,
					backgroundColor = "";

				if ( value !== "transparent" && ( jQuery.type( value ) !== "string" ||
						( parsed = stringParse( value ) ) ) ) {
					value = color( parsed || value );
					if ( !support.rgba && value._rgba[ 3 ] !== 1 ) {
						curElem = hook === "backgroundColor" ? elem.parentNode : elem;
						while (
							( backgroundColor === "" || backgroundColor === "transparent" ) &&
							curElem && curElem.style
						) {
							try {
								backgroundColor = jQuery.css( curElem, "backgroundColor" );
								curElem = curElem.parentNode;
							} catch ( e ) {
							}
						}

						value = value.blend( backgroundColor && backgroundColor !== "transparent" ?
							backgroundColor :
							"_default" );
					}

					value = value.toRgbaString();
				}
				try {
					elem.style[ hook ] = value;
				} catch ( e ) {

					// Wrapped to prevent IE from throwing errors on "invalid" values like
					// 'auto' or 'inherit'
				}
			}
		};
		jQuery.fx.step[ hook ] = function( fx ) {
			if ( !fx.colorInit ) {
				fx.start = color( fx.elem, hook );
				fx.end = color( fx.end );
				fx.colorInit = true;
			}
			jQuery.cssHooks[ hook ].set( fx.elem, fx.start.transition( fx.end, fx.pos ) );
		};
	} );

};

color.hook( stepHooks );

jQuery.cssHooks.borderColor = {
	expand: function( value ) {
		var expanded = {};

		each( [ "Top", "Right", "Bottom", "Left" ], function( i, part ) {
			expanded[ "border" + part + "Color" ] = value;
		} );
		return expanded;
	}
};

// Basic color names only.
// Usage of any of the other color names requires adding yourself or including
// jquery.color.svg-names.js.
colors = jQuery.Color.names = {

	// 4.1. Basic color keywords
	aqua: "#00ffff",
	black: "#000000",
	blue: "#0000ff",
	fuchsia: "#ff00ff",
	gray: "#808080",
	green: "#008000",
	lime: "#00ff00",
	maroon: "#800000",
	navy: "#000080",
	olive: "#808000",
	purple: "#800080",
	red: "#ff0000",
	silver: "#c0c0c0",
	teal: "#008080",
	white: "#ffffff",
	yellow: "#ffff00",

	// 4.2.3. "transparent" color keyword
	transparent: [ null, null, null, 0 ],

	_default: "#ffffff"
};

} )( jQuery );

/******************************************************************************/
/****************************** CLASS ANIMATIONS ******************************/
/******************************************************************************/
( function() {

var classAnimationActions = [ "add", "remove", "toggle" ],
	shorthandStyles = {
		border: 1,
		borderBottom: 1,
		borderColor: 1,
		borderLeft: 1,
		borderRight: 1,
		borderTop: 1,
		borderWidth: 1,
		margin: 1,
		padding: 1
	};

$.each(
	[ "borderLeftStyle", "borderRightStyle", "borderBottomStyle", "borderTopStyle" ],
	function( _, prop ) {
		$.fx.step[ prop ] = function( fx ) {
			if ( fx.end !== "none" && !fx.setAttr || fx.pos === 1 && !fx.setAttr ) {
				jQuery.style( fx.elem, prop, fx.end );
				fx.setAttr = true;
			}
		};
	}
);

function getElementStyles( elem ) {
	var key, len,
		style = elem.ownerDocument.defaultView ?
			elem.ownerDocument.defaultView.getComputedStyle( elem, null ) :
			elem.currentStyle,
		styles = {};

	if ( style && style.length && style[ 0 ] && style[ style[ 0 ] ] ) {
		len = style.length;
		while ( len-- ) {
			key = style[ len ];
			if ( typeof style[ key ] === "string" ) {
				styles[ $.camelCase( key ) ] = style[ key ];
			}
		}

	// Support: Opera, IE <9
	} else {
		for ( key in style ) {
			if ( typeof style[ key ] === "string" ) {
				styles[ key ] = style[ key ];
			}
		}
	}

	return styles;
}

function styleDifference( oldStyle, newStyle ) {
	var diff = {},
		name, value;

	for ( name in newStyle ) {
		value = newStyle[ name ];
		if ( oldStyle[ name ] !== value ) {
			if ( !shorthandStyles[ name ] ) {
				if ( $.fx.step[ name ] || !isNaN( parseFloat( value ) ) ) {
					diff[ name ] = value;
				}
			}
		}
	}

	return diff;
}

// Support: jQuery <1.8
if ( !$.fn.addBack ) {
	$.fn.addBack = function( selector ) {
		return this.add( selector == null ?
			this.prevObject : this.prevObject.filter( selector )
		);
	};
}

$.effects.animateClass = function( value, duration, easing, callback ) {
	var o = $.speed( duration, easing, callback );

	return this.queue( function() {
		var animated = $( this ),
			baseClass = animated.attr( "class" ) || "",
			applyClassChange,
			allAnimations = o.children ? animated.find( "*" ).addBack() : animated;

		// Map the animated objects to store the original styles.
		allAnimations = allAnimations.map( function() {
			var el = $( this );
			return {
				el: el,
				start: getElementStyles( this )
			};
		} );

		// Apply class change
		applyClassChange = function() {
			$.each( classAnimationActions, function( i, action ) {
				if ( value[ action ] ) {
					animated[ action + "Class" ]( value[ action ] );
				}
			} );
		};
		applyClassChange();

		// Map all animated objects again - calculate new styles and diff
		allAnimations = allAnimations.map( function() {
			this.end = getElementStyles( this.el[ 0 ] );
			this.diff = styleDifference( this.start, this.end );
			return this;
		} );

		// Apply original class
		animated.attr( "class", baseClass );

		// Map all animated objects again - this time collecting a promise
		allAnimations = allAnimations.map( function() {
			var styleInfo = this,
				dfd = $.Deferred(),
				opts = $.extend( {}, o, {
					queue: false,
					complete: function() {
						dfd.resolve( styleInfo );
					}
				} );

			this.el.animate( this.diff, opts );
			return dfd.promise();
		} );

		// Once all animations have completed:
		$.when.apply( $, allAnimations.get() ).done( function() {

			// Set the final class
			applyClassChange();

			// For each animated element,
			// clear all css properties that were animated
			$.each( arguments, function() {
				var el = this.el;
				$.each( this.diff, function( key ) {
					el.css( key, "" );
				} );
			} );

			// This is guarnteed to be there if you use jQuery.speed()
			// it also handles dequeuing the next anim...
			o.complete.call( animated[ 0 ] );
		} );
	} );
};

$.fn.extend( {
	addClass: ( function( orig ) {
		return function( classNames, speed, easing, callback ) {
			return speed ?
				$.effects.animateClass.call( this,
					{ add: classNames }, speed, easing, callback ) :
				orig.apply( this, arguments );
		};
	} )( $.fn.addClass ),

	removeClass: ( function( orig ) {
		return function( classNames, speed, easing, callback ) {
			return arguments.length > 1 ?
				$.effects.animateClass.call( this,
					{ remove: classNames }, speed, easing, callback ) :
				orig.apply( this, arguments );
		};
	} )( $.fn.removeClass ),

	toggleClass: ( function( orig ) {
		return function( classNames, force, speed, easing, callback ) {
			if ( typeof force === "boolean" || force === undefined ) {
				if ( !speed ) {

					// Without speed parameter
					return orig.apply( this, arguments );
				} else {
					return $.effects.animateClass.call( this,
						( force ? { add: classNames } : { remove: classNames } ),
						speed, easing, callback );
				}
			} else {

				// Without force parameter
				return $.effects.animateClass.call( this,
					{ toggle: classNames }, force, speed, easing );
			}
		};
	} )( $.fn.toggleClass ),

	switchClass: function( remove, add, speed, easing, callback ) {
		return $.effects.animateClass.call( this, {
			add: add,
			remove: remove
		}, speed, easing, callback );
	}
} );

} )();

/******************************************************************************/
/*********************************** EFFECTS **********************************/
/******************************************************************************/

( function() {

if ( $.expr && $.expr.filters && $.expr.filters.animated ) {
	$.expr.filters.animated = ( function( orig ) {
		return function( elem ) {
			return !!$( elem ).data( dataSpaceAnimated ) || orig( elem );
		};
	} )( $.expr.filters.animated );
}

if ( $.uiBackCompat !== false ) {
	$.extend( $.effects, {

		// Saves a set of properties in a data storage
		save: function( element, set ) {
			var i = 0, length = set.length;
			for ( ; i < length; i++ ) {
				if ( set[ i ] !== null ) {
					element.data( dataSpace + set[ i ], element[ 0 ].style[ set[ i ] ] );
				}
			}
		},

		// Restores a set of previously saved properties from a data storage
		restore: function( element, set ) {
			var val, i = 0, length = set.length;
			for ( ; i < length; i++ ) {
				if ( set[ i ] !== null ) {
					val = element.data( dataSpace + set[ i ] );
					element.css( set[ i ], val );
				}
			}
		},

		setMode: function( el, mode ) {
			if ( mode === "toggle" ) {
				mode = el.is( ":hidden" ) ? "show" : "hide";
			}
			return mode;
		},

		// Wraps the element around a wrapper that copies position properties
		createWrapper: function( element ) {

			// If the element is already wrapped, return it
			if ( element.parent().is( ".ui-effects-wrapper" ) ) {
				return element.parent();
			}

			// Wrap the element
			var props = {
					width: element.outerWidth( true ),
					height: element.outerHeight( true ),
					"float": element.css( "float" )
				},
				wrapper = $( "<div></div>" )
					.addClass( "ui-effects-wrapper" )
					.css( {
						fontSize: "100%",
						background: "transparent",
						border: "none",
						margin: 0,
						padding: 0
					} ),

				// Store the size in case width/height are defined in % - Fixes #5245
				size = {
					width: element.width(),
					height: element.height()
				},
				active = document.activeElement;

			// Support: Firefox
			// Firefox incorrectly exposes anonymous content
			// https://bugzilla.mozilla.org/show_bug.cgi?id=561664
			try {
				active.id;
			} catch ( e ) {
				active = document.body;
			}

			element.wrap( wrapper );

			// Fixes #7595 - Elements lose focus when wrapped.
			if ( element[ 0 ] === active || $.contains( element[ 0 ], active ) ) {
				$( active ).trigger( "focus" );
			}

			// Hotfix for jQuery 1.4 since some change in wrap() seems to actually
			// lose the reference to the wrapped element
			wrapper = element.parent();

			// Transfer positioning properties to the wrapper
			if ( element.css( "position" ) === "static" ) {
				wrapper.css( { position: "relative" } );
				element.css( { position: "relative" } );
			} else {
				$.extend( props, {
					position: element.css( "position" ),
					zIndex: element.css( "z-index" )
				} );
				$.each( [ "top", "left", "bottom", "right" ], function( i, pos ) {
					props[ pos ] = element.css( pos );
					if ( isNaN( parseInt( props[ pos ], 10 ) ) ) {
						props[ pos ] = "auto";
					}
				} );
				element.css( {
					position: "relative",
					top: 0,
					left: 0,
					right: "auto",
					bottom: "auto"
				} );
			}
			element.css( size );

			return wrapper.css( props ).show();
		},

		removeWrapper: function( element ) {
			var active = document.activeElement;

			if ( element.parent().is( ".ui-effects-wrapper" ) ) {
				element.parent().replaceWith( element );

				// Fixes #7595 - Elements lose focus when wrapped.
				if ( element[ 0 ] === active || $.contains( element[ 0 ], active ) ) {
					$( active ).trigger( "focus" );
				}
			}

			return element;
		}
	} );
}

$.extend( $.effects, {
	version: "1.12.1",

	define: function( name, mode, effect ) {
		if ( !effect ) {
			effect = mode;
			mode = "effect";
		}

		$.effects.effect[ name ] = effect;
		$.effects.effect[ name ].mode = mode;

		return effect;
	},

	scaledDimensions: function( element, percent, direction ) {
		if ( percent === 0 ) {
			return {
				height: 0,
				width: 0,
				outerHeight: 0,
				outerWidth: 0
			};
		}

		var x = direction !== "horizontal" ? ( ( percent || 100 ) / 100 ) : 1,
			y = direction !== "vertical" ? ( ( percent || 100 ) / 100 ) : 1;

		return {
			height: element.height() * y,
			width: element.width() * x,
			outerHeight: element.outerHeight() * y,
			outerWidth: element.outerWidth() * x
		};

	},

	clipToBox: function( animation ) {
		return {
			width: animation.clip.right - animation.clip.left,
			height: animation.clip.bottom - animation.clip.top,
			left: animation.clip.left,
			top: animation.clip.top
		};
	},

	// Injects recently queued functions to be first in line (after "inprogress")
	unshift: function( element, queueLength, count ) {
		var queue = element.queue();

		if ( queueLength > 1 ) {
			queue.splice.apply( queue,
				[ 1, 0 ].concat( queue.splice( queueLength, count ) ) );
		}
		element.dequeue();
	},

	saveStyle: function( element ) {
		element.data( dataSpaceStyle, element[ 0 ].style.cssText );
	},

	restoreStyle: function( element ) {
		element[ 0 ].style.cssText = element.data( dataSpaceStyle ) || "";
		element.removeData( dataSpaceStyle );
	},

	mode: function( element, mode ) {
		var hidden = element.is( ":hidden" );

		if ( mode === "toggle" ) {
			mode = hidden ? "show" : "hide";
		}
		if ( hidden ? mode === "hide" : mode === "show" ) {
			mode = "none";
		}
		return mode;
	},

	// Translates a [top,left] array into a baseline value
	getBaseline: function( origin, original ) {
		var y, x;

		switch ( origin[ 0 ] ) {
		case "top":
			y = 0;
			break;
		case "middle":
			y = 0.5;
			break;
		case "bottom":
			y = 1;
			break;
		default:
			y = origin[ 0 ] / original.height;
		}

		switch ( origin[ 1 ] ) {
		case "left":
			x = 0;
			break;
		case "center":
			x = 0.5;
			break;
		case "right":
			x = 1;
			break;
		default:
			x = origin[ 1 ] / original.width;
		}

		return {
			x: x,
			y: y
		};
	},

	// Creates a placeholder element so that the original element can be made absolute
	createPlaceholder: function( element ) {
		var placeholder,
			cssPosition = element.css( "position" ),
			position = element.position();

		// Lock in margins first to account for form elements, which
		// will change margin if you explicitly set height
		// see: http://jsfiddle.net/JZSMt/3/ https://bugs.webkit.org/show_bug.cgi?id=107380
		// Support: Safari
		element.css( {
			marginTop: element.css( "marginTop" ),
			marginBottom: element.css( "marginBottom" ),
			marginLeft: element.css( "marginLeft" ),
			marginRight: element.css( "marginRight" )
		} )
		.outerWidth( element.outerWidth() )
		.outerHeight( element.outerHeight() );

		if ( /^(static|relative)/.test( cssPosition ) ) {
			cssPosition = "absolute";

			placeholder = $( "<" + element[ 0 ].nodeName + ">" ).insertAfter( element ).css( {

				// Convert inline to inline block to account for inline elements
				// that turn to inline block based on content (like img)
				display: /^(inline|ruby)/.test( element.css( "display" ) ) ?
					"inline-block" :
					"block",
				visibility: "hidden",

				// Margins need to be set to account for margin collapse
				marginTop: element.css( "marginTop" ),
				marginBottom: element.css( "marginBottom" ),
				marginLeft: element.css( "marginLeft" ),
				marginRight: element.css( "marginRight" ),
				"float": element.css( "float" )
			} )
			.outerWidth( element.outerWidth() )
			.outerHeight( element.outerHeight() )
			.addClass( "ui-effects-placeholder" );

			element.data( dataSpace + "placeholder", placeholder );
		}

		element.css( {
			position: cssPosition,
			left: position.left,
			top: position.top
		} );

		return placeholder;
	},

	removePlaceholder: function( element ) {
		var dataKey = dataSpace + "placeholder",
				placeholder = element.data( dataKey );

		if ( placeholder ) {
			placeholder.remove();
			element.removeData( dataKey );
		}
	},

	// Removes a placeholder if it exists and restores
	// properties that were modified during placeholder creation
	cleanUp: function( element ) {
		$.effects.restoreStyle( element );
		$.effects.removePlaceholder( element );
	},

	setTransition: function( element, list, factor, value ) {
		value = value || {};
		$.each( list, function( i, x ) {
			var unit = element.cssUnit( x );
			if ( unit[ 0 ] > 0 ) {
				value[ x ] = unit[ 0 ] * factor + unit[ 1 ];
			}
		} );
		return value;
	}
} );

// Return an effect options object for the given parameters:
function _normalizeArguments( effect, options, speed, callback ) {

	// Allow passing all options as the first parameter
	if ( $.isPlainObject( effect ) ) {
		options = effect;
		effect = effect.effect;
	}

	// Convert to an object
	effect = { effect: effect };

	// Catch (effect, null, ...)
	if ( options == null ) {
		options = {};
	}

	// Catch (effect, callback)
	if ( $.isFunction( options ) ) {
		callback = options;
		speed = null;
		options = {};
	}

	// Catch (effect, speed, ?)
	if ( typeof options === "number" || $.fx.speeds[ options ] ) {
		callback = speed;
		speed = options;
		options = {};
	}

	// Catch (effect, options, callback)
	if ( $.isFunction( speed ) ) {
		callback = speed;
		speed = null;
	}

	// Add options to effect
	if ( options ) {
		$.extend( effect, options );
	}

	speed = speed || options.duration;
	effect.duration = $.fx.off ? 0 :
		typeof speed === "number" ? speed :
		speed in $.fx.speeds ? $.fx.speeds[ speed ] :
		$.fx.speeds._default;

	effect.complete = callback || options.complete;

	return effect;
}

function standardAnimationOption( option ) {

	// Valid standard speeds (nothing, number, named speed)
	if ( !option || typeof option === "number" || $.fx.speeds[ option ] ) {
		return true;
	}

	// Invalid strings - treat as "normal" speed
	if ( typeof option === "string" && !$.effects.effect[ option ] ) {
		return true;
	}

	// Complete callback
	if ( $.isFunction( option ) ) {
		return true;
	}

	// Options hash (but not naming an effect)
	if ( typeof option === "object" && !option.effect ) {
		return true;
	}

	// Didn't match any standard API
	return false;
}

$.fn.extend( {
	effect: function( /* effect, options, speed, callback */ ) {
		var args = _normalizeArguments.apply( this, arguments ),
			effectMethod = $.effects.effect[ args.effect ],
			defaultMode = effectMethod.mode,
			queue = args.queue,
			queueName = queue || "fx",
			complete = args.complete,
			mode = args.mode,
			modes = [],
			prefilter = function( next ) {
				var el = $( this ),
					normalizedMode = $.effects.mode( el, mode ) || defaultMode;

				// Sentinel for duck-punching the :animated psuedo-selector
				el.data( dataSpaceAnimated, true );

				// Save effect mode for later use,
				// we can't just call $.effects.mode again later,
				// as the .show() below destroys the initial state
				modes.push( normalizedMode );

				// See $.uiBackCompat inside of run() for removal of defaultMode in 1.13
				if ( defaultMode && ( normalizedMode === "show" ||
						( normalizedMode === defaultMode && normalizedMode === "hide" ) ) ) {
					el.show();
				}

				if ( !defaultMode || normalizedMode !== "none" ) {
					$.effects.saveStyle( el );
				}

				if ( $.isFunction( next ) ) {
					next();
				}
			};

		if ( $.fx.off || !effectMethod ) {

			// Delegate to the original method (e.g., .show()) if possible
			if ( mode ) {
				return this[ mode ]( args.duration, complete );
			} else {
				return this.each( function() {
					if ( complete ) {
						complete.call( this );
					}
				} );
			}
		}

		function run( next ) {
			var elem = $( this );

			function cleanup() {
				elem.removeData( dataSpaceAnimated );

				$.effects.cleanUp( elem );

				if ( args.mode === "hide" ) {
					elem.hide();
				}

				done();
			}

			function done() {
				if ( $.isFunction( complete ) ) {
					complete.call( elem[ 0 ] );
				}

				if ( $.isFunction( next ) ) {
					next();
				}
			}

			// Override mode option on a per element basis,
			// as toggle can be either show or hide depending on element state
			args.mode = modes.shift();

			if ( $.uiBackCompat !== false && !defaultMode ) {
				if ( elem.is( ":hidden" ) ? mode === "hide" : mode === "show" ) {

					// Call the core method to track "olddisplay" properly
					elem[ mode ]();
					done();
				} else {
					effectMethod.call( elem[ 0 ], args, done );
				}
			} else {
				if ( args.mode === "none" ) {

					// Call the core method to track "olddisplay" properly
					elem[ mode ]();
					done();
				} else {
					effectMethod.call( elem[ 0 ], args, cleanup );
				}
			}
		}

		// Run prefilter on all elements first to ensure that
		// any showing or hiding happens before placeholder creation,
		// which ensures that any layout changes are correctly captured.
		return queue === false ?
			this.each( prefilter ).each( run ) :
			this.queue( queueName, prefilter ).queue( queueName, run );
	},

	show: ( function( orig ) {
		return function( option ) {
			if ( standardAnimationOption( option ) ) {
				return orig.apply( this, arguments );
			} else {
				var args = _normalizeArguments.apply( this, arguments );
				args.mode = "show";
				return this.effect.call( this, args );
			}
		};
	} )( $.fn.show ),

	hide: ( function( orig ) {
		return function( option ) {
			if ( standardAnimationOption( option ) ) {
				return orig.apply( this, arguments );
			} else {
				var args = _normalizeArguments.apply( this, arguments );
				args.mode = "hide";
				return this.effect.call( this, args );
			}
		};
	} )( $.fn.hide ),

	toggle: ( function( orig ) {
		return function( option ) {
			if ( standardAnimationOption( option ) || typeof option === "boolean" ) {
				return orig.apply( this, arguments );
			} else {
				var args = _normalizeArguments.apply( this, arguments );
				args.mode = "toggle";
				return this.effect.call( this, args );
			}
		};
	} )( $.fn.toggle ),

	cssUnit: function( key ) {
		var style = this.css( key ),
			val = [];

		$.each( [ "em", "px", "%", "pt" ], function( i, unit ) {
			if ( style.indexOf( unit ) > 0 ) {
				val = [ parseFloat( style ), unit ];
			}
		} );
		return val;
	},

	cssClip: function( clipObj ) {
		if ( clipObj ) {
			return this.css( "clip", "rect(" + clipObj.top + "px " + clipObj.right + "px " +
				clipObj.bottom + "px " + clipObj.left + "px)" );
		}
		return parseClip( this.css( "clip" ), this );
	},

	transfer: function( options, done ) {
		var element = $( this ),
			target = $( options.to ),
			targetFixed = target.css( "position" ) === "fixed",
			body = $( "body" ),
			fixTop = targetFixed ? body.scrollTop() : 0,
			fixLeft = targetFixed ? body.scrollLeft() : 0,
			endPosition = target.offset(),
			animation = {
				top: endPosition.top - fixTop,
				left: endPosition.left - fixLeft,
				height: target.innerHeight(),
				width: target.innerWidth()
			},
			startPosition = element.offset(),
			transfer = $( "<div class='ui-effects-transfer'></div>" )
				.appendTo( "body" )
				.addClass( options.className )
				.css( {
					top: startPosition.top - fixTop,
					left: startPosition.left - fixLeft,
					height: element.innerHeight(),
					width: element.innerWidth(),
					position: targetFixed ? "fixed" : "absolute"
				} )
				.animate( animation, options.duration, options.easing, function() {
					transfer.remove();
					if ( $.isFunction( done ) ) {
						done();
					}
				} );
	}
} );

function parseClip( str, element ) {
		var outerWidth = element.outerWidth(),
			outerHeight = element.outerHeight(),
			clipRegex = /^rect\((-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto)\)$/,
			values = clipRegex.exec( str ) || [ "", 0, outerWidth, outerHeight, 0 ];

		return {
			top: parseFloat( values[ 1 ] ) || 0,
			right: values[ 2 ] === "auto" ? outerWidth : parseFloat( values[ 2 ] ),
			bottom: values[ 3 ] === "auto" ? outerHeight : parseFloat( values[ 3 ] ),
			left: parseFloat( values[ 4 ] ) || 0
		};
}

$.fx.step.clip = function( fx ) {
	if ( !fx.clipInit ) {
		fx.start = $( fx.elem ).cssClip();
		if ( typeof fx.end === "string" ) {
			fx.end = parseClip( fx.end, fx.elem );
		}
		fx.clipInit = true;
	}

	$( fx.elem ).cssClip( {
		top: fx.pos * ( fx.end.top - fx.start.top ) + fx.start.top,
		right: fx.pos * ( fx.end.right - fx.start.right ) + fx.start.right,
		bottom: fx.pos * ( fx.end.bottom - fx.start.bottom ) + fx.start.bottom,
		left: fx.pos * ( fx.end.left - fx.start.left ) + fx.start.left
	} );
};

} )();

/******************************************************************************/
/*********************************** EASING ***********************************/
/******************************************************************************/

( function() {

// Based on easing equations from Robert Penner (http://www.robertpenner.com/easing)

var baseEasings = {};

$.each( [ "Quad", "Cubic", "Quart", "Quint", "Expo" ], function( i, name ) {
	baseEasings[ name ] = function( p ) {
		return Math.pow( p, i + 2 );
	};
} );

$.extend( baseEasings, {
	Sine: function( p ) {
		return 1 - Math.cos( p * Math.PI / 2 );
	},
	Circ: function( p ) {
		return 1 - Math.sqrt( 1 - p * p );
	},
	Elastic: function( p ) {
		return p === 0 || p === 1 ? p :
			-Math.pow( 2, 8 * ( p - 1 ) ) * Math.sin( ( ( p - 1 ) * 80 - 7.5 ) * Math.PI / 15 );
	},
	Back: function( p ) {
		return p * p * ( 3 * p - 2 );
	},
	Bounce: function( p ) {
		var pow2,
			bounce = 4;

		while ( p < ( ( pow2 = Math.pow( 2, --bounce ) ) - 1 ) / 11 ) {}
		return 1 / Math.pow( 4, 3 - bounce ) - 7.5625 * Math.pow( ( pow2 * 3 - 2 ) / 22 - p, 2 );
	}
} );

$.each( baseEasings, function( name, easeIn ) {
	$.easing[ "easeIn" + name ] = easeIn;
	$.easing[ "easeOut" + name ] = function( p ) {
		return 1 - easeIn( 1 - p );
	};
	$.easing[ "easeInOut" + name ] = function( p ) {
		return p < 0.5 ?
			easeIn( p * 2 ) / 2 :
			1 - easeIn( p * -2 + 2 ) / 2;
	};
} );

} )();

var effect = $.effects;


/*!
 * jQuery UI Effects Blind 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Blind Effect
//>>group: Effects
//>>description: Blinds the element.
//>>docs: http://api.jqueryui.com/blind-effect/
//>>demos: http://jqueryui.com/effect/



var effectsEffectBlind = $.effects.define( "blind", "hide", function( options, done ) {
	var map = {
			up: [ "bottom", "top" ],
			vertical: [ "bottom", "top" ],
			down: [ "top", "bottom" ],
			left: [ "right", "left" ],
			horizontal: [ "right", "left" ],
			right: [ "left", "right" ]
		},
		element = $( this ),
		direction = options.direction || "up",
		start = element.cssClip(),
		animate = { clip: $.extend( {}, start ) },
		placeholder = $.effects.createPlaceholder( element );

	animate.clip[ map[ direction ][ 0 ] ] = animate.clip[ map[ direction ][ 1 ] ];

	if ( options.mode === "show" ) {
		element.cssClip( animate.clip );
		if ( placeholder ) {
			placeholder.css( $.effects.clipToBox( animate ) );
		}

		animate.clip = start;
	}

	if ( placeholder ) {
		placeholder.animate( $.effects.clipToBox( animate ), options.duration, options.easing );
	}

	element.animate( animate, {
		queue: false,
		duration: options.duration,
		easing: options.easing,
		complete: done
	} );
} );


/*!
 * jQuery UI Effects Bounce 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Bounce Effect
//>>group: Effects
//>>description: Bounces an element horizontally or vertically n times.
//>>docs: http://api.jqueryui.com/bounce-effect/
//>>demos: http://jqueryui.com/effect/



var effectsEffectBounce = $.effects.define( "bounce", function( options, done ) {
	var upAnim, downAnim, refValue,
		element = $( this ),

		// Defaults:
		mode = options.mode,
		hide = mode === "hide",
		show = mode === "show",
		direction = options.direction || "up",
		distance = options.distance,
		times = options.times || 5,

		// Number of internal animations
		anims = times * 2 + ( show || hide ? 1 : 0 ),
		speed = options.duration / anims,
		easing = options.easing,

		// Utility:
		ref = ( direction === "up" || direction === "down" ) ? "top" : "left",
		motion = ( direction === "up" || direction === "left" ),
		i = 0,

		queuelen = element.queue().length;

	$.effects.createPlaceholder( element );

	refValue = element.css( ref );

	// Default distance for the BIGGEST bounce is the outer Distance / 3
	if ( !distance ) {
		distance = element[ ref === "top" ? "outerHeight" : "outerWidth" ]() / 3;
	}

	if ( show ) {
		downAnim = { opacity: 1 };
		downAnim[ ref ] = refValue;

		// If we are showing, force opacity 0 and set the initial position
		// then do the "first" animation
		element
			.css( "opacity", 0 )
			.css( ref, motion ? -distance * 2 : distance * 2 )
			.animate( downAnim, speed, easing );
	}

	// Start at the smallest distance if we are hiding
	if ( hide ) {
		distance = distance / Math.pow( 2, times - 1 );
	}

	downAnim = {};
	downAnim[ ref ] = refValue;

	// Bounces up/down/left/right then back to 0 -- times * 2 animations happen here
	for ( ; i < times; i++ ) {
		upAnim = {};
		upAnim[ ref ] = ( motion ? "-=" : "+=" ) + distance;

		element
			.animate( upAnim, speed, easing )
			.animate( downAnim, speed, easing );

		distance = hide ? distance * 2 : distance / 2;
	}

	// Last Bounce when Hiding
	if ( hide ) {
		upAnim = { opacity: 0 };
		upAnim[ ref ] = ( motion ? "-=" : "+=" ) + distance;

		element.animate( upAnim, speed, easing );
	}

	element.queue( done );

	$.effects.unshift( element, queuelen, anims + 1 );
} );


/*!
 * jQuery UI Effects Clip 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Clip Effect
//>>group: Effects
//>>description: Clips the element on and off like an old TV.
//>>docs: http://api.jqueryui.com/clip-effect/
//>>demos: http://jqueryui.com/effect/



var effectsEffectClip = $.effects.define( "clip", "hide", function( options, done ) {
	var start,
		animate = {},
		element = $( this ),
		direction = options.direction || "vertical",
		both = direction === "both",
		horizontal = both || direction === "horizontal",
		vertical = both || direction === "vertical";

	start = element.cssClip();
	animate.clip = {
		top: vertical ? ( start.bottom - start.top ) / 2 : start.top,
		right: horizontal ? ( start.right - start.left ) / 2 : start.right,
		bottom: vertical ? ( start.bottom - start.top ) / 2 : start.bottom,
		left: horizontal ? ( start.right - start.left ) / 2 : start.left
	};

	$.effects.createPlaceholder( element );

	if ( options.mode === "show" ) {
		element.cssClip( animate.clip );
		animate.clip = start;
	}

	element.animate( animate, {
		queue: false,
		duration: options.duration,
		easing: options.easing,
		complete: done
	} );

} );


/*!
 * jQuery UI Effects Drop 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Drop Effect
//>>group: Effects
//>>description: Moves an element in one direction and hides it at the same time.
//>>docs: http://api.jqueryui.com/drop-effect/
//>>demos: http://jqueryui.com/effect/



var effectsEffectDrop = $.effects.define( "drop", "hide", function( options, done ) {

	var distance,
		element = $( this ),
		mode = options.mode,
		show = mode === "show",
		direction = options.direction || "left",
		ref = ( direction === "up" || direction === "down" ) ? "top" : "left",
		motion = ( direction === "up" || direction === "left" ) ? "-=" : "+=",
		oppositeMotion = ( motion === "+=" ) ? "-=" : "+=",
		animation = {
			opacity: 0
		};

	$.effects.createPlaceholder( element );

	distance = options.distance ||
		element[ ref === "top" ? "outerHeight" : "outerWidth" ]( true ) / 2;

	animation[ ref ] = motion + distance;

	if ( show ) {
		element.css( animation );

		animation[ ref ] = oppositeMotion + distance;
		animation.opacity = 1;
	}

	// Animate
	element.animate( animation, {
		queue: false,
		duration: options.duration,
		easing: options.easing,
		complete: done
	} );
} );


/*!
 * jQuery UI Effects Explode 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Explode Effect
//>>group: Effects
// jscs:disable maximumLineLength
//>>description: Explodes an element in all directions into n pieces. Implodes an element to its original wholeness.
// jscs:enable maximumLineLength
//>>docs: http://api.jqueryui.com/explode-effect/
//>>demos: http://jqueryui.com/effect/



var effectsEffectExplode = $.effects.define( "explode", "hide", function( options, done ) {

	var i, j, left, top, mx, my,
		rows = options.pieces ? Math.round( Math.sqrt( options.pieces ) ) : 3,
		cells = rows,
		element = $( this ),
		mode = options.mode,
		show = mode === "show",

		// Show and then visibility:hidden the element before calculating offset
		offset = element.show().css( "visibility", "hidden" ).offset(),

		// Width and height of a piece
		width = Math.ceil( element.outerWidth() / cells ),
		height = Math.ceil( element.outerHeight() / rows ),
		pieces = [];

	// Children animate complete:
	function childComplete() {
		pieces.push( this );
		if ( pieces.length === rows * cells ) {
			animComplete();
		}
	}

	// Clone the element for each row and cell.
	for ( i = 0; i < rows; i++ ) { // ===>
		top = offset.top + i * height;
		my = i - ( rows - 1 ) / 2;

		for ( j = 0; j < cells; j++ ) { // |||
			left = offset.left + j * width;
			mx = j - ( cells - 1 ) / 2;

			// Create a clone of the now hidden main element that will be absolute positioned
			// within a wrapper div off the -left and -top equal to size of our pieces
			element
				.clone()
				.appendTo( "body" )
				.wrap( "<div></div>" )
				.css( {
					position: "absolute",
					visibility: "visible",
					left: -j * width,
					top: -i * height
				} )

				// Select the wrapper - make it overflow: hidden and absolute positioned based on
				// where the original was located +left and +top equal to the size of pieces
				.parent()
					.addClass( "ui-effects-explode" )
					.css( {
						position: "absolute",
						overflow: "hidden",
						width: width,
						height: height,
						left: left + ( show ? mx * width : 0 ),
						top: top + ( show ? my * height : 0 ),
						opacity: show ? 0 : 1
					} )
					.animate( {
						left: left + ( show ? 0 : mx * width ),
						top: top + ( show ? 0 : my * height ),
						opacity: show ? 1 : 0
					}, options.duration || 500, options.easing, childComplete );
		}
	}

	function animComplete() {
		element.css( {
			visibility: "visible"
		} );
		$( pieces ).remove();
		done();
	}
} );


/*!
 * jQuery UI Effects Fade 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Fade Effect
//>>group: Effects
//>>description: Fades the element.
//>>docs: http://api.jqueryui.com/fade-effect/
//>>demos: http://jqueryui.com/effect/



var effectsEffectFade = $.effects.define( "fade", "toggle", function( options, done ) {
	var show = options.mode === "show";

	$( this )
		.css( "opacity", show ? 0 : 1 )
		.animate( {
			opacity: show ? 1 : 0
		}, {
			queue: false,
			duration: options.duration,
			easing: options.easing,
			complete: done
		} );
} );


/*!
 * jQuery UI Effects Fold 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Fold Effect
//>>group: Effects
//>>description: Folds an element first horizontally and then vertically.
//>>docs: http://api.jqueryui.com/fold-effect/
//>>demos: http://jqueryui.com/effect/



var effectsEffectFold = $.effects.define( "fold", "hide", function( options, done ) {

	// Create element
	var element = $( this ),
		mode = options.mode,
		show = mode === "show",
		hide = mode === "hide",
		size = options.size || 15,
		percent = /([0-9]+)%/.exec( size ),
		horizFirst = !!options.horizFirst,
		ref = horizFirst ? [ "right", "bottom" ] : [ "bottom", "right" ],
		duration = options.duration / 2,

		placeholder = $.effects.createPlaceholder( element ),

		start = element.cssClip(),
		animation1 = { clip: $.extend( {}, start ) },
		animation2 = { clip: $.extend( {}, start ) },

		distance = [ start[ ref[ 0 ] ], start[ ref[ 1 ] ] ],

		queuelen = element.queue().length;

	if ( percent ) {
		size = parseInt( percent[ 1 ], 10 ) / 100 * distance[ hide ? 0 : 1 ];
	}
	animation1.clip[ ref[ 0 ] ] = size;
	animation2.clip[ ref[ 0 ] ] = size;
	animation2.clip[ ref[ 1 ] ] = 0;

	if ( show ) {
		element.cssClip( animation2.clip );
		if ( placeholder ) {
			placeholder.css( $.effects.clipToBox( animation2 ) );
		}

		animation2.clip = start;
	}

	// Animate
	element
		.queue( function( next ) {
			if ( placeholder ) {
				placeholder
					.animate( $.effects.clipToBox( animation1 ), duration, options.easing )
					.animate( $.effects.clipToBox( animation2 ), duration, options.easing );
			}

			next();
		} )
		.animate( animation1, duration, options.easing )
		.animate( animation2, duration, options.easing )
		.queue( done );

	$.effects.unshift( element, queuelen, 4 );
} );


/*!
 * jQuery UI Effects Highlight 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Highlight Effect
//>>group: Effects
//>>description: Highlights the background of an element in a defined color for a custom duration.
//>>docs: http://api.jqueryui.com/highlight-effect/
//>>demos: http://jqueryui.com/effect/



var effectsEffectHighlight = $.effects.define( "highlight", "show", function( options, done ) {
	var element = $( this ),
		animation = {
			backgroundColor: element.css( "backgroundColor" )
		};

	if ( options.mode === "hide" ) {
		animation.opacity = 0;
	}

	$.effects.saveStyle( element );

	element
		.css( {
			backgroundImage: "none",
			backgroundColor: options.color || "#ffff99"
		} )
		.animate( animation, {
			queue: false,
			duration: options.duration,
			easing: options.easing,
			complete: done
		} );
} );


/*!
 * jQuery UI Effects Size 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Size Effect
//>>group: Effects
//>>description: Resize an element to a specified width and height.
//>>docs: http://api.jqueryui.com/size-effect/
//>>demos: http://jqueryui.com/effect/



var effectsEffectSize = $.effects.define( "size", function( options, done ) {

	// Create element
	var baseline, factor, temp,
		element = $( this ),

		// Copy for children
		cProps = [ "fontSize" ],
		vProps = [ "borderTopWidth", "borderBottomWidth", "paddingTop", "paddingBottom" ],
		hProps = [ "borderLeftWidth", "borderRightWidth", "paddingLeft", "paddingRight" ],

		// Set options
		mode = options.mode,
		restore = mode !== "effect",
		scale = options.scale || "both",
		origin = options.origin || [ "middle", "center" ],
		position = element.css( "position" ),
		pos = element.position(),
		original = $.effects.scaledDimensions( element ),
		from = options.from || original,
		to = options.to || $.effects.scaledDimensions( element, 0 );

	$.effects.createPlaceholder( element );

	if ( mode === "show" ) {
		temp = from;
		from = to;
		to = temp;
	}

	// Set scaling factor
	factor = {
		from: {
			y: from.height / original.height,
			x: from.width / original.width
		},
		to: {
			y: to.height / original.height,
			x: to.width / original.width
		}
	};

	// Scale the css box
	if ( scale === "box" || scale === "both" ) {

		// Vertical props scaling
		if ( factor.from.y !== factor.to.y ) {
			from = $.effects.setTransition( element, vProps, factor.from.y, from );
			to = $.effects.setTransition( element, vProps, factor.to.y, to );
		}

		// Horizontal props scaling
		if ( factor.from.x !== factor.to.x ) {
			from = $.effects.setTransition( element, hProps, factor.from.x, from );
			to = $.effects.setTransition( element, hProps, factor.to.x, to );
		}
	}

	// Scale the content
	if ( scale === "content" || scale === "both" ) {

		// Vertical props scaling
		if ( factor.from.y !== factor.to.y ) {
			from = $.effects.setTransition( element, cProps, factor.from.y, from );
			to = $.effects.setTransition( element, cProps, factor.to.y, to );
		}
	}

	// Adjust the position properties based on the provided origin points
	if ( origin ) {
		baseline = $.effects.getBaseline( origin, original );
		from.top = ( original.outerHeight - from.outerHeight ) * baseline.y + pos.top;
		from.left = ( original.outerWidth - from.outerWidth ) * baseline.x + pos.left;
		to.top = ( original.outerHeight - to.outerHeight ) * baseline.y + pos.top;
		to.left = ( original.outerWidth - to.outerWidth ) * baseline.x + pos.left;
	}
	element.css( from );

	// Animate the children if desired
	if ( scale === "content" || scale === "both" ) {

		vProps = vProps.concat( [ "marginTop", "marginBottom" ] ).concat( cProps );
		hProps = hProps.concat( [ "marginLeft", "marginRight" ] );

		// Only animate children with width attributes specified
		// TODO: is this right? should we include anything with css width specified as well
		element.find( "*[width]" ).each( function() {
			var child = $( this ),
				childOriginal = $.effects.scaledDimensions( child ),
				childFrom = {
					height: childOriginal.height * factor.from.y,
					width: childOriginal.width * factor.from.x,
					outerHeight: childOriginal.outerHeight * factor.from.y,
					outerWidth: childOriginal.outerWidth * factor.from.x
				},
				childTo = {
					height: childOriginal.height * factor.to.y,
					width: childOriginal.width * factor.to.x,
					outerHeight: childOriginal.height * factor.to.y,
					outerWidth: childOriginal.width * factor.to.x
				};

			// Vertical props scaling
			if ( factor.from.y !== factor.to.y ) {
				childFrom = $.effects.setTransition( child, vProps, factor.from.y, childFrom );
				childTo = $.effects.setTransition( child, vProps, factor.to.y, childTo );
			}

			// Horizontal props scaling
			if ( factor.from.x !== factor.to.x ) {
				childFrom = $.effects.setTransition( child, hProps, factor.from.x, childFrom );
				childTo = $.effects.setTransition( child, hProps, factor.to.x, childTo );
			}

			if ( restore ) {
				$.effects.saveStyle( child );
			}

			// Animate children
			child.css( childFrom );
			child.animate( childTo, options.duration, options.easing, function() {

				// Restore children
				if ( restore ) {
					$.effects.restoreStyle( child );
				}
			} );
		} );
	}

	// Animate
	element.animate( to, {
		queue: false,
		duration: options.duration,
		easing: options.easing,
		complete: function() {

			var offset = element.offset();

			if ( to.opacity === 0 ) {
				element.css( "opacity", from.opacity );
			}

			if ( !restore ) {
				element
					.css( "position", position === "static" ? "relative" : position )
					.offset( offset );

				// Need to save style here so that automatic style restoration
				// doesn't restore to the original styles from before the animation.
				$.effects.saveStyle( element );
			}

			done();
		}
	} );

} );


/*!
 * jQuery UI Effects Scale 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Scale Effect
//>>group: Effects
//>>description: Grows or shrinks an element and its content.
//>>docs: http://api.jqueryui.com/scale-effect/
//>>demos: http://jqueryui.com/effect/



var effectsEffectScale = $.effects.define( "scale", function( options, done ) {

	// Create element
	var el = $( this ),
		mode = options.mode,
		percent = parseInt( options.percent, 10 ) ||
			( parseInt( options.percent, 10 ) === 0 ? 0 : ( mode !== "effect" ? 0 : 100 ) ),

		newOptions = $.extend( true, {
			from: $.effects.scaledDimensions( el ),
			to: $.effects.scaledDimensions( el, percent, options.direction || "both" ),
			origin: options.origin || [ "middle", "center" ]
		}, options );

	// Fade option to support puff
	if ( options.fade ) {
		newOptions.from.opacity = 1;
		newOptions.to.opacity = 0;
	}

	$.effects.effect.size.call( this, newOptions, done );
} );


/*!
 * jQuery UI Effects Puff 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Puff Effect
//>>group: Effects
//>>description: Creates a puff effect by scaling the element up and hiding it at the same time.
//>>docs: http://api.jqueryui.com/puff-effect/
//>>demos: http://jqueryui.com/effect/



var effectsEffectPuff = $.effects.define( "puff", "hide", function( options, done ) {
	var newOptions = $.extend( true, {}, options, {
		fade: true,
		percent: parseInt( options.percent, 10 ) || 150
	} );

	$.effects.effect.scale.call( this, newOptions, done );
} );


/*!
 * jQuery UI Effects Pulsate 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Pulsate Effect
//>>group: Effects
//>>description: Pulsates an element n times by changing the opacity to zero and back.
//>>docs: http://api.jqueryui.com/pulsate-effect/
//>>demos: http://jqueryui.com/effect/



var effectsEffectPulsate = $.effects.define( "pulsate", "show", function( options, done ) {
	var element = $( this ),
		mode = options.mode,
		show = mode === "show",
		hide = mode === "hide",
		showhide = show || hide,

		// Showing or hiding leaves off the "last" animation
		anims = ( ( options.times || 5 ) * 2 ) + ( showhide ? 1 : 0 ),
		duration = options.duration / anims,
		animateTo = 0,
		i = 1,
		queuelen = element.queue().length;

	if ( show || !element.is( ":visible" ) ) {
		element.css( "opacity", 0 ).show();
		animateTo = 1;
	}

	// Anims - 1 opacity "toggles"
	for ( ; i < anims; i++ ) {
		element.animate( { opacity: animateTo }, duration, options.easing );
		animateTo = 1 - animateTo;
	}

	element.animate( { opacity: animateTo }, duration, options.easing );

	element.queue( done );

	$.effects.unshift( element, queuelen, anims + 1 );
} );


/*!
 * jQuery UI Effects Shake 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Shake Effect
//>>group: Effects
//>>description: Shakes an element horizontally or vertically n times.
//>>docs: http://api.jqueryui.com/shake-effect/
//>>demos: http://jqueryui.com/effect/



var effectsEffectShake = $.effects.define( "shake", function( options, done ) {

	var i = 1,
		element = $( this ),
		direction = options.direction || "left",
		distance = options.distance || 20,
		times = options.times || 3,
		anims = times * 2 + 1,
		speed = Math.round( options.duration / anims ),
		ref = ( direction === "up" || direction === "down" ) ? "top" : "left",
		positiveMotion = ( direction === "up" || direction === "left" ),
		animation = {},
		animation1 = {},
		animation2 = {},

		queuelen = element.queue().length;

	$.effects.createPlaceholder( element );

	// Animation
	animation[ ref ] = ( positiveMotion ? "-=" : "+=" ) + distance;
	animation1[ ref ] = ( positiveMotion ? "+=" : "-=" ) + distance * 2;
	animation2[ ref ] = ( positiveMotion ? "-=" : "+=" ) + distance * 2;

	// Animate
	element.animate( animation, speed, options.easing );

	// Shakes
	for ( ; i < times; i++ ) {
		element
			.animate( animation1, speed, options.easing )
			.animate( animation2, speed, options.easing );
	}

	element
		.animate( animation1, speed, options.easing )
		.animate( animation, speed / 2, options.easing )
		.queue( done );

	$.effects.unshift( element, queuelen, anims + 1 );
} );


/*!
 * jQuery UI Effects Slide 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Slide Effect
//>>group: Effects
//>>description: Slides an element in and out of the viewport.
//>>docs: http://api.jqueryui.com/slide-effect/
//>>demos: http://jqueryui.com/effect/



var effectsEffectSlide = $.effects.define( "slide", "show", function( options, done ) {
	var startClip, startRef,
		element = $( this ),
		map = {
			up: [ "bottom", "top" ],
			down: [ "top", "bottom" ],
			left: [ "right", "left" ],
			right: [ "left", "right" ]
		},
		mode = options.mode,
		direction = options.direction || "left",
		ref = ( direction === "up" || direction === "down" ) ? "top" : "left",
		positiveMotion = ( direction === "up" || direction === "left" ),
		distance = options.distance ||
			element[ ref === "top" ? "outerHeight" : "outerWidth" ]( true ),
		animation = {};

	$.effects.createPlaceholder( element );

	startClip = element.cssClip();
	startRef = element.position()[ ref ];

	// Define hide animation
	animation[ ref ] = ( positiveMotion ? -1 : 1 ) * distance + startRef;
	animation.clip = element.cssClip();
	animation.clip[ map[ direction ][ 1 ] ] = animation.clip[ map[ direction ][ 0 ] ];

	// Reverse the animation if we're showing
	if ( mode === "show" ) {
		element.cssClip( animation.clip );
		element.css( ref, animation[ ref ] );
		animation.clip = startClip;
		animation[ ref ] = startRef;
	}

	// Actually animate
	element.animate( animation, {
		queue: false,
		duration: options.duration,
		easing: options.easing,
		complete: done
	} );
} );


/*!
 * jQuery UI Effects Transfer 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Transfer Effect
//>>group: Effects
//>>description: Displays a transfer effect from one element to another.
//>>docs: http://api.jqueryui.com/transfer-effect/
//>>demos: http://jqueryui.com/effect/



var effect;
if ( $.uiBackCompat !== false ) {
	effect = $.effects.define( "transfer", function( options, done ) {
		$( this ).transfer( options, done );
	} );
}
var effectsEffectTransfer = effect;


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

//>>label: :focusable Selector
//>>group: Core
//>>description: Selects elements which can be focused.
//>>docs: http://api.jqueryui.com/focusable-selector/



// Selectors
$.ui.focusable = function( element, hasTabindex ) {
	var map, mapName, img, focusableIfVisible, fieldset,
		nodeName = element.nodeName.toLowerCase();

	if ( "area" === nodeName ) {
		map = element.parentNode;
		mapName = map.name;
		if ( !element.href || !mapName || map.nodeName.toLowerCase() !== "map" ) {
			return false;
		}
		img = $( "img[usemap='#" + mapName + "']" );
		return img.length > 0 && img.is( ":visible" );
	}

	if ( /^(input|select|textarea|button|object)$/.test( nodeName ) ) {
		focusableIfVisible = !element.disabled;

		if ( focusableIfVisible ) {

			// Form controls within a disabled fieldset are disabled.
			// However, controls within the fieldset's legend do not get disabled.
			// Since controls generally aren't placed inside legends, we skip
			// this portion of the check.
			fieldset = $( element ).closest( "fieldset" )[ 0 ];
			if ( fieldset ) {
				focusableIfVisible = !fieldset.disabled;
			}
		}
	} else if ( "a" === nodeName ) {
		focusableIfVisible = element.href || hasTabindex;
	} else {
		focusableIfVisible = hasTabindex;
	}

	return focusableIfVisible && $( element ).is( ":visible" ) && visible( $( element ) );
};

// Support: IE 8 only
// IE 8 doesn't resolve inherit to visible/hidden for computed values
function visible( element ) {
	var visibility = element.css( "visibility" );
	while ( visibility === "inherit" ) {
		element = element.parent();
		visibility = element.css( "visibility" );
	}
	return visibility !== "hidden";
}

$.extend( $.expr[ ":" ], {
	focusable: function( element ) {
		return $.ui.focusable( element, $.attr( element, "tabindex" ) != null );
	}
} );

var focusable = $.ui.focusable;




// Support: IE8 Only
// IE8 does not support the form attribute and when it is supplied. It overwrites the form prop
// with a string, so we need to find the proper form.
var form = $.fn.form = function() {
	return typeof this[ 0 ].form === "string" ? this.closest( "form" ) : $( this[ 0 ].form );
};


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

//>>label: Form Reset Mixin
//>>group: Core
//>>description: Refresh input widgets when their form is reset
//>>docs: http://api.jqueryui.com/form-reset-mixin/



var formResetMixin = $.ui.formResetMixin = {
	_formResetHandler: function() {
		var form = $( this );

		// Wait for the form reset to actually happen before refreshing
		setTimeout( function() {
			var instances = form.data( "ui-form-reset-instances" );
			$.each( instances, function() {
				this.refresh();
			} );
		} );
	},

	_bindFormResetHandler: function() {
		this.form = this.element.form();
		if ( !this.form.length ) {
			return;
		}

		var instances = this.form.data( "ui-form-reset-instances" ) || [];
		if ( !instances.length ) {

			// We don't use _on() here because we use a single event handler per form
			this.form.on( "reset.ui-form-reset", this._formResetHandler );
		}
		instances.push( this );
		this.form.data( "ui-form-reset-instances", instances );
	},

	_unbindFormResetHandler: function() {
		if ( !this.form.length ) {
			return;
		}

		var instances = this.form.data( "ui-form-reset-instances" );
		instances.splice( $.inArray( this, instances ), 1 );
		if ( instances.length ) {
			this.form.data( "ui-form-reset-instances", instances );
		} else {
			this.form
				.removeData( "ui-form-reset-instances" )
				.off( "reset.ui-form-reset" );
		}
	}
};


/*!
 * jQuery UI Support for jQuery core 1.7.x 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 *
 */

//>>label: jQuery 1.7 Support
//>>group: Core
//>>description: Support version 1.7.x of jQuery core



// Support: jQuery 1.7 only
// Not a great way to check versions, but since we only support 1.7+ and only
// need to detect <1.8, this is a simple check that should suffice. Checking
// for "1.7." would be a bit safer, but the version string is 1.7, not 1.7.0
// and we'll never reach 1.70.0 (if we do, we certainly won't be supporting
// 1.7 anymore). See #11197 for why we're not using feature detection.
if ( $.fn.jquery.substring( 0, 3 ) === "1.7" ) {

	// Setters for .innerWidth(), .innerHeight(), .outerWidth(), .outerHeight()
	// Unlike jQuery Core 1.8+, these only support numeric values to set the
	// dimensions in pixels
	$.each( [ "Width", "Height" ], function( i, name ) {
		var side = name === "Width" ? [ "Left", "Right" ] : [ "Top", "Bottom" ],
			type = name.toLowerCase(),
			orig = {
				innerWidth: $.fn.innerWidth,
				innerHeight: $.fn.innerHeight,
				outerWidth: $.fn.outerWidth,
				outerHeight: $.fn.outerHeight
			};

		function reduce( elem, size, border, margin ) {
			$.each( side, function() {
				size -= parseFloat( $.css( elem, "padding" + this ) ) || 0;
				if ( border ) {
					size -= parseFloat( $.css( elem, "border" + this + "Width" ) ) || 0;
				}
				if ( margin ) {
					size -= parseFloat( $.css( elem, "margin" + this ) ) || 0;
				}
			} );
			return size;
		}

		$.fn[ "inner" + name ] = function( size ) {
			if ( size === undefined ) {
				return orig[ "inner" + name ].call( this );
			}

			return this.each( function() {
				$( this ).css( type, reduce( this, size ) + "px" );
			} );
		};

		$.fn[ "outer" + name ] = function( size, margin ) {
			if ( typeof size !== "number" ) {
				return orig[ "outer" + name ].call( this, size );
			}

			return this.each( function() {
				$( this ).css( type, reduce( this, size, true, margin ) + "px" );
			} );
		};
	} );

	$.fn.addBack = function( selector ) {
		return this.add( selector == null ?
			this.prevObject : this.prevObject.filter( selector )
		);
	};
}

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

//>>label: Keycode
//>>group: Core
//>>description: Provide keycodes as keynames
//>>docs: http://api.jqueryui.com/jQuery.ui.keyCode/


var keycode = $.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
};




// Internal use only
var escapeSelector = $.ui.escapeSelector = ( function() {
	var selectorEscape = /([!"#$%&'()*+,./:;<=>?@[\]^`{|}~])/g;
	return function( selector ) {
		return selector.replace( selectorEscape, "\\$1" );
	};
} )();


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

//>>label: labels
//>>group: Core
//>>description: Find all the labels associated with a given input
//>>docs: http://api.jqueryui.com/labels/



var labels = $.fn.labels = function() {
	var ancestor, selector, id, labels, ancestors;

	// Check control.labels first
	if ( this[ 0 ].labels && this[ 0 ].labels.length ) {
		return this.pushStack( this[ 0 ].labels );
	}

	// Support: IE <= 11, FF <= 37, Android <= 2.3 only
	// Above browsers do not support control.labels. Everything below is to support them
	// as well as document fragments. control.labels does not work on document fragments
	labels = this.eq( 0 ).parents( "label" );

	// Look for the label based on the id
	id = this.attr( "id" );
	if ( id ) {

		// We don't search against the document in case the element
		// is disconnected from the DOM
		ancestor = this.eq( 0 ).parents().last();

		// Get a full set of top level ancestors
		ancestors = ancestor.add( ancestor.length ? ancestor.siblings() : this.siblings() );

		// Create a selector for the label based on the id
		selector = "label[for='" + $.ui.escapeSelector( id ) + "']";

		labels = labels.add( ancestors.find( selector ).addBack( selector ) );

	}

	// Return whatever we have found for labels
	return this.pushStack( labels );
};


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

//>>label: scrollParent
//>>group: Core
//>>description: Get the closest ancestor element that is scrollable.
//>>docs: http://api.jqueryui.com/scrollParent/



var scrollParent = $.fn.scrollParent = function( includeHidden ) {
	var position = this.css( "position" ),
		excludeStaticParent = position === "absolute",
		overflowRegex = includeHidden ? /(auto|scroll|hidden)/ : /(auto|scroll)/,
		scrollParent = this.parents().filter( function() {
			var parent = $( this );
			if ( excludeStaticParent && parent.css( "position" ) === "static" ) {
				return false;
			}
			return overflowRegex.test( parent.css( "overflow" ) + parent.css( "overflow-y" ) +
				parent.css( "overflow-x" ) );
		} ).eq( 0 );

	return position === "fixed" || !scrollParent.length ?
		$( this[ 0 ].ownerDocument || document ) :
		scrollParent;
};


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

//>>label: :tabbable Selector
//>>group: Core
//>>description: Selects elements which can be tabbed to.
//>>docs: http://api.jqueryui.com/tabbable-selector/



var tabbable = $.extend( $.expr[ ":" ], {
	tabbable: function( element ) {
		var tabIndex = $.attr( element, "tabindex" ),
			hasTabindex = tabIndex != null;
		return ( !hasTabindex || tabIndex >= 0 ) && $.ui.focusable( element, hasTabindex );
	}
} );


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

//>>label: uniqueId
//>>group: Core
//>>description: Functions to generate and remove uniqueId's
//>>docs: http://api.jqueryui.com/uniqueId/



var uniqueId = $.fn.extend( {
	uniqueId: ( function() {
		var uuid = 0;

		return function() {
			return this.each( function() {
				if ( !this.id ) {
					this.id = "ui-id-" + ( ++uuid );
				}
			} );
		};
	} )(),

	removeUniqueId: function() {
		return this.each( function() {
			if ( /^ui-id-\d+$/.test( this.id ) ) {
				$( this ).removeAttr( "id" );
			}
		} );
	}
} );


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

//>>label: Accordion
//>>group: Widgets
// jscs:disable maximumLineLength
//>>description: Displays collapsible content panels for presenting information in a limited amount of space.
// jscs:enable maximumLineLength
//>>docs: http://api.jqueryui.com/accordion/
//>>demos: http://jqueryui.com/accordion/
//>>css.structure: ../../themes/base/core.css
//>>css.structure: ../../themes/base/accordion.css
//>>css.theme: ../../themes/base/theme.css



var widgetsAccordion = $.widget( "ui.accordion", {
	version: "1.12.1",
	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: false,
		event: "click",
		header: "> li > :first-child, > :not(li):even",
		heightStyle: "auto",
		icons: {
			activeHeader: "ui-icon-triangle-1-s",
			header: "ui-icon-triangle-1-e"
		},

		// Callbacks
		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 options = this.options;

		this.prevShow = this.prevHide = $();
		this._addClass( "ui-accordion", "ui-widget ui-helper-reset" );
		this.element.attr( "role", "tablist" );

		// Don't allow collapsible: false and active: false / null
		if ( !options.collapsible && ( options.active === false || options.active == null ) ) {
			options.active = 0;
		}

		this._processPanels();

		// handle negative values
		if ( options.active < 0 ) {
			options.active += this.headers.length;
		}
		this._refresh();
	},

	_getCreateEventData: function() {
		return {
			header: this.active,
			panel: !this.active.length ? $() : this.active.next()
		};
	},

	_createIcons: function() {
		var icon, children,
			icons = this.options.icons;

		if ( icons ) {
			icon = $( "<span>" );
			this._addClass( icon, "ui-accordion-header-icon", "ui-icon " + icons.header );
			icon.prependTo( this.headers );
			children = this.active.children( ".ui-accordion-header-icon" );
			this._removeClass( children, icons.header )
				._addClass( children, null, icons.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() {
		var contents;

		// Clean up main element
		this.element.removeAttr( "role" );

		// Clean up headers
		this.headers
			.removeAttr( "role aria-expanded aria-selected aria-controls tabIndex" )
			.removeUniqueId();

		this._destroyIcons();

		// Clean up content panels
		contents = this.headers.next()
			.css( "display", "" )
			.removeAttr( "role aria-hidden aria-labelledby" )
			.removeUniqueId();

		if ( this.options.heightStyle !== "content" ) {
			contents.css( "height", "" );
		}
	},

	_setOption: function( key, value ) {
		if ( key === "active" ) {

			// _activate() will handle invalid values and update this.options
			this._activate( value );
			return;
		}

		if ( key === "event" ) {
			if ( this.options.event ) {
				this._off( this.headers, this.options.event );
			}
			this._setupEvents( value );
		}

		this._super( key, value );

		// Setting collapsible: false while collapsed; open first panel
		if ( key === "collapsible" && !value && this.options.active === false ) {
			this._activate( 0 );
		}

		if ( key === "icons" ) {
			this._destroyIcons();
			if ( value ) {
				this._createIcons();
			}
		}
	},

	_setOptionDisabled: function( value ) {
		this._super( value );

		this.element.attr( "aria-disabled", value );

		// Support: IE8 Only
		// #5332 / #6059 - opacity doesn't cascade to positioned elements in IE
		// so we need to add the disabled class to the headers and panels
		this._toggleClass( null, "ui-state-disabled", !!value );
		this._toggleClass( this.headers.add( this.headers.next() ), null, "ui-state-disabled",
			!!value );
	},

	_keydown: function( event ) {
		if ( event.altKey || event.ctrlKey ) {
			return;
		}

		var keyCode = $.ui.keyCode,
			length = this.headers.length,
			currentIndex = this.headers.index( event.target ),
			toFocus = false;

		switch ( event.keyCode ) {
		case keyCode.RIGHT:
		case keyCode.DOWN:
			toFocus = this.headers[ ( currentIndex + 1 ) % length ];
			break;
		case keyCode.LEFT:
		case keyCode.UP:
			toFocus = this.headers[ ( currentIndex - 1 + length ) % length ];
			break;
		case keyCode.SPACE:
		case keyCode.ENTER:
			this._eventHandler( event );
			break;
		case keyCode.HOME:
			toFocus = this.headers[ 0 ];
			break;
		case keyCode.END:
			toFocus = this.headers[ length - 1 ];
			break;
		}

		if ( toFocus ) {
			$( event.target ).attr( "tabIndex", -1 );
			$( toFocus ).attr( "tabIndex", 0 );
			$( toFocus ).trigger( "focus" );
			event.preventDefault();
		}
	},

	_panelKeyDown: function( event ) {
		if ( event.keyCode === $.ui.keyCode.UP && event.ctrlKey ) {
			$( event.currentTarget ).prev().trigger( "focus" );
		}
	},

	refresh: function() {
		var options = this.options;
		this._processPanels();

		// Was collapsed or no panel
		if ( ( options.active === false && options.collapsible === true ) ||
				!this.headers.length ) {
			options.active = false;
			this.active = $();

		// active false only when collapsible is true
		} else if ( options.active === false ) {
			this._activate( 0 );

		// was active, but active panel is gone
		} else if ( this.active.length && !$.contains( this.element[ 0 ], this.active[ 0 ] ) ) {

			// all remaining panel are disabled
			if ( this.headers.length === this.headers.find( ".ui-state-disabled" ).length ) {
				options.active = false;
				this.active = $();

			// activate previous panel
			} else {
				this._activate( Math.max( 0, options.active - 1 ) );
			}

		// was active, active panel still exists
		} else {

			// make sure active index is correct
			options.active = this.headers.index( this.active );
		}

		this._destroyIcons();

		this._refresh();
	},

	_processPanels: function() {
		var prevHeaders = this.headers,
			prevPanels = this.panels;

		this.headers = 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" );

		// Avoid memory leaks (#10056)
		if ( prevPanels ) {
			this._off( prevHeaders.not( this.headers ) );
			this._off( prevPanels.not( this.panels ) );
		}
	},

	_refresh: function() {
		var maxHeight,
			options = this.options,
			heightStyle = options.heightStyle,
			parent = this.element.parent();

		this.active = this._findActive( options.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 header = $( this ),
					headerId = header.uniqueId().attr( "id" ),
					panel = header.next(),
					panelId = panel.uniqueId().attr( "id" );
				header.attr( "aria-controls", panelId );
				panel.attr( "aria-labelledby", headerId );
			} )
			.next()
				.attr( "role", "tabpanel" );

		this.headers
			.not( this.active )
				.attr( {
					"aria-selected": "false",
					"aria-expanded": "false",
					tabIndex: -1
				} )
				.next()
					.attr( {
						"aria-hidden": "true"
					} )
					.hide();

		// Make sure at least one header is in the tab order
		if ( !this.active.length ) {
			this.headers.eq( 0 ).attr( "tabIndex", 0 );
		} else {
			this.active.attr( {
				"aria-selected": "true",
				"aria-expanded": "true",
				tabIndex: 0
			} )
				.next()
					.attr( {
						"aria-hidden": "false"
					} );
		}

		this._createIcons();

		this._setupEvents( options.event );

		if ( heightStyle === "fill" ) {
			maxHeight = parent.height();
			this.element.siblings( ":visible" ).each( function() {
				var elem = $( this ),
					position = elem.css( "position" );

				if ( position === "absolute" || position === "fixed" ) {
					return;
				}
				maxHeight -= elem.outerHeight( true );
			} );

			this.headers.each( function() {
				maxHeight -= $( this ).outerHeight( true );
			} );

			this.headers.next()
				.each( function() {
					$( this ).height( Math.max( 0, maxHeight -
						$( this ).innerHeight() + $( this ).height() ) );
				} )
				.css( "overflow", "auto" );
		} else if ( heightStyle === "auto" ) {
			maxHeight = 0;
			this.headers.next()
				.each( function() {
					var isVisible = $( this ).is( ":visible" );
					if ( !isVisible ) {
						$( this ).show();
					}
					maxHeight = Math.max( maxHeight, $( this ).css( "height", "" ).height() );
					if ( !isVisible ) {
						$( this ).hide();
					}
				} )
				.height( maxHeight );
		}
	},

	_activate: function( index ) {
		var active = this._findActive( index )[ 0 ];

		// Trying to activate the already active panel
		if ( active === this.active[ 0 ] ) {
			return;
		}

		// Trying to collapse, simulate a click on the currently active header
		active = active || this.active[ 0 ];

		this._eventHandler( {
			target: active,
			currentTarget: active,
			preventDefault: $.noop
		} );
	},

	_findActive: function( selector ) {
		return typeof selector === "number" ? this.headers.eq( selector ) : $();
	},

	_setupEvents: function( event ) {
		var events = {
			keydown: "_keydown"
		};
		if ( event ) {
			$.each( event.split( " " ), function( index, eventName ) {
				events[ eventName ] = "_eventHandler";
			} );
		}

		this._off( this.headers.add( this.headers.next() ) );
		this._on( this.headers, events );
		this._on( this.headers.next(), { keydown: "_panelKeyDown" } );
		this._hoverable( this.headers );
		this._focusable( this.headers );
	},

	_eventHandler: function( event ) {
		var activeChildren, clickedChildren,
			options = this.options,
			active = this.active,
			clicked = $( event.currentTarget ),
			clickedIsActive = clicked[ 0 ] === active[ 0 ],
			collapsing = clickedIsActive && options.collapsible,
			toShow = collapsing ? $() : clicked.next(),
			toHide = active.next(),
			eventData = {
				oldHeader: active,
				oldPanel: toHide,
				newHeader: collapsing ? $() : clicked,
				newPanel: toShow
			};

		event.preventDefault();

		if (

				// click on active header, but not collapsible
				( clickedIsActive && !options.collapsible ) ||

				// allow canceling activation
				( this._trigger( "beforeActivate", event, eventData ) === false ) ) {
			return;
		}

		options.active = collapsing ? false : this.headers.index( clicked );

		// When the call to ._toggle() comes after the class changes
		// it causes a very odd bug in IE 8 (see #6720)
		this.active = clickedIsActive ? $() : clicked;
		this._toggle( eventData );

		// Switch classes
		// corner classes on the previously active header stay after the animation
		this._removeClass( active, "ui-accordion-header-active", "ui-state-active" );
		if ( options.icons ) {
			activeChildren = active.children( ".ui-accordion-header-icon" );
			this._removeClass( activeChildren, null, options.icons.activeHeader )
				._addClass( activeChildren, null, options.icons.header );
		}

		if ( !clickedIsActive ) {
			this._removeClass( clicked, "ui-accordion-header-collapsed" )
				._addClass( clicked, "ui-accordion-header-active", "ui-state-active" );
			if ( options.icons ) {
				clickedChildren = clicked.children( ".ui-accordion-header-icon" );
				this._removeClass( clickedChildren, null, options.icons.header )
					._addClass( clickedChildren, null, options.icons.activeHeader );
			}

			this._addClass( clicked.next(), "ui-accordion-content-active" );
		}
	},

	_toggle: function( data ) {
		var toShow = data.newPanel,
			toHide = this.prevShow.length ? this.prevShow : data.oldPanel;

		// Handle activating a panel during the animation for another activation
		this.prevShow.add( this.prevHide ).stop( true, true );
		this.prevShow = toShow;
		this.prevHide = toHide;

		if ( this.options.animate ) {
			this._animate( toShow, toHide, data );
		} else {
			toHide.hide();
			toShow.show();
			this._toggleComplete( data );
		}

		toHide.attr( {
			"aria-hidden": "true"
		} );
		toHide.prev().attr( {
			"aria-selected": "false",
			"aria-expanded": "false"
		} );

		// if we're switching panels, remove the old header from the tab order
		// if we're opening from collapsed state, remove the previous header from the tab order
		// if we're collapsing, then keep the collapsing header in the tab order
		if ( toShow.length && toHide.length ) {
			toHide.prev().attr( {
				"tabIndex": -1,
				"aria-expanded": "false"
			} );
		} else if ( toShow.length ) {
			this.headers.filter( function() {
				return parseInt( $( this ).attr( "tabIndex" ), 10 ) === 0;
			} )
				.attr( "tabIndex", -1 );
		}

		toShow
			.attr( "aria-hidden", "false" )
			.prev()
				.attr( {
					"aria-selected": "true",
					"aria-expanded": "true",
					tabIndex: 0
				} );
	},

	_animate: function( toShow, toHide, data ) {
		var total, easing, duration,
			that = this,
			adjust = 0,
			boxSizing = toShow.css( "box-sizing" ),
			down = toShow.length &&
				( !toHide.length || ( toShow.index() < toHide.index() ) ),
			animate = this.options.animate || {},
			options = down && animate.down || animate,
			complete = function() {
				that._toggleComplete( data );
			};

		if ( typeof options === "number" ) {
			duration = options;
		}
		if ( typeof options === "string" ) {
			easing = options;
		}

		// fall back from options to animation in case of partial down settings
		easing = easing || options.easing || animate.easing;
		duration = duration || options.duration || animate.duration;

		if ( !toHide.length ) {
			return toShow.animate( this.showProps, duration, easing, complete );
		}
		if ( !toShow.length ) {
			return toHide.animate( this.hideProps, duration, easing, complete );
		}

		total = toShow.show().outerHeight();
		toHide.animate( this.hideProps, {
			duration: duration,
			easing: easing,
			step: function( now, fx ) {
				fx.now = Math.round( now );
			}
		} );
		toShow
			.hide()
			.animate( this.showProps, {
				duration: duration,
				easing: easing,
				complete: complete,
				step: function( now, fx ) {
					fx.now = Math.round( now );
					if ( fx.prop !== "height" ) {
						if ( boxSizing === "content-box" ) {
							adjust += fx.now;
						}
					} else if ( that.options.heightStyle !== "content" ) {
						fx.now = Math.round( total - toHide.outerHeight() - adjust );
						adjust = 0;
					}
				}
			} );
	},

	_toggleComplete: function( data ) {
		var toHide = data.oldPanel,
			prev = toHide.prev();

		this._removeClass( toHide, "ui-accordion-content-active" );
		this._removeClass( prev, "ui-accordion-header-active" )
			._addClass( prev, "ui-accordion-header-collapsed" );

		// Work around for rendering bug in IE (#5421)
		if ( toHide.length ) {
			toHide.parent()[ 0 ].className = toHide.parent()[ 0 ].className;
		}
		this._trigger( "activate", null, data );
	}
} );



var safeActiveElement = $.ui.safeActiveElement = function( document ) {
	var activeElement;

	// Support: IE 9 only
	// IE9 throws an "Unspecified error" accessing document.activeElement from an <iframe>
	try {
		activeElement = document.activeElement;
	} catch ( error ) {
		activeElement = document.body;
	}

	// Support: IE 9 - 11 only
	// IE may return null instead of an element
	// Interestingly, this only seems to occur when NOT in an iframe
	if ( !activeElement ) {
		activeElement = document.body;
	}

	// Support: IE 11 only
	// IE11 returns a seemingly empty object in some cases when accessing
	// document.activeElement from an <iframe>
	if ( !activeElement.nodeName ) {
		activeElement = document.body;
	}

	return activeElement;
};


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

//>>label: Menu
//>>group: Widgets
//>>description: Creates nestable menus.
//>>docs: http://api.jqueryui.com/menu/
//>>demos: http://jqueryui.com/menu/
//>>css.structure: ../../themes/base/core.css
//>>css.structure: ../../themes/base/menu.css
//>>css.theme: ../../themes/base/theme.css



var widgetsMenu = $.widget( "ui.menu", {
	version: "1.12.1",
	defaultElement: "<ul>",
	delay: 300,
	options: {
		icons: {
			submenu: "ui-icon-caret-1-e"
		},
		items: "> *",
		menus: "ul",
		position: {
			my: "left top",
			at: "right top"
		},
		role: "menu",

		// Callbacks
		blur: null,
		focus: null,
		select: null
	},

	_create: function() {
		this.activeMenu = this.element;

		// Flag used to prevent firing of the click handler
		// as the event bubbles up through nested menus
		this.mouseHandled = false;
		this.element
			.uniqueId()
			.attr( {
				role: this.options.role,
				tabIndex: 0
			} );

		this._addClass( "ui-menu", "ui-widget ui-widget-content" );
		this._on( {

			// Prevent focus from sticking to links inside menu after clicking
			// them (focus should always stay on UL during navigation).
			"mousedown .ui-menu-item": function( event ) {
				event.preventDefault();
			},
			"click .ui-menu-item": function( event ) {
				var target = $( event.target );
				var active = $( $.ui.safeActiveElement( this.document[ 0 ] ) );
				if ( !this.mouseHandled && target.not( ".ui-state-disabled" ).length ) {
					this.select( event );

					// Only set the mouseHandled flag if the event will bubble, see #9469.
					if ( !event.isPropagationStopped() ) {
						this.mouseHandled = true;
					}

					// Open submenu on click
					if ( target.has( ".ui-menu" ).length ) {
						this.expand( event );
					} else if ( !this.element.is( ":focus" ) &&
							active.closest( ".ui-menu" ).length ) {

						// Redirect focus to the menu
						this.element.trigger( "focus", [ true ] );

						// If the active item is on the top level, let it stay active.
						// Otherwise, blur the active item since it is no longer visible.
						if ( this.active && this.active.parents( ".ui-menu" ).length === 1 ) {
							clearTimeout( this.timer );
						}
					}
				}
			},
			"mouseenter .ui-menu-item": function( event ) {

				// Ignore mouse events while typeahead is active, see #10458.
				// Prevents focusing the wrong item when typeahead causes a scroll while the mouse
				// is over an item in the menu
				if ( this.previousFilter ) {
					return;
				}

				var actualTarget = $( event.target ).closest( ".ui-menu-item" ),
					target = $( event.currentTarget );

				// Ignore bubbled events on parent items, see #11641
				if ( actualTarget[ 0 ] !== target[ 0 ] ) {
					return;
				}

				// Remove ui-state-active class from siblings of the newly focused menu item
				// to avoid a jump caused by adjacent elements both having a class with a border
				this._removeClass( target.siblings().children( ".ui-state-active" ),
					null, "ui-state-active" );
				this.focus( event, target );
			},
			mouseleave: "collapseAll",
			"mouseleave .ui-menu": "collapseAll",
			focus: function( event, keepActiveItem ) {

				// If there's already an active item, keep it active
				// If not, activate the first item
				var item = this.active || this.element.find( this.options.items ).eq( 0 );

				if ( !keepActiveItem ) {
					this.focus( event, item );
				}
			},
			blur: function( event ) {
				this._delay( function() {
					var notContained = !$.contains(
						this.element[ 0 ],
						$.ui.safeActiveElement( this.document[ 0 ] )
					);
					if ( notContained ) {
						this.collapseAll( event );
					}
				} );
			},
			keydown: "_keydown"
		} );

		this.refresh();

		// Clicks outside of a menu collapse any open menus
		this._on( this.document, {
			click: function( event ) {
				if ( this._closeOnDocumentClick( event ) ) {
					this.collapseAll( event );
				}

				// Reset the mouseHandled flag
				this.mouseHandled = false;
			}
		} );
	},

	_destroy: function() {
		var items = this.element.find( ".ui-menu-item" )
				.removeAttr( "role aria-disabled" ),
			submenus = items.children( ".ui-menu-item-wrapper" )
				.removeUniqueId()
				.removeAttr( "tabIndex role aria-haspopup" );

		// Destroy (sub)menus
		this.element
			.removeAttr( "aria-activedescendant" )
			.find( ".ui-menu" ).addBack()
				.removeAttr( "role aria-labelledby aria-expanded aria-hidden aria-disabled " +
					"tabIndex" )
				.removeUniqueId()
				.show();

		submenus.children().each( function() {
			var elem = $( this );
			if ( elem.data( "ui-menu-submenu-caret" ) ) {
				elem.remove();
			}
		} );
	},

	_keydown: function( event ) {
		var match, prev, character, skip,
			preventDefault = true;

		switch ( event.keyCode ) {
		case $.ui.keyCode.PAGE_UP:
			this.previousPage( event );
			break;
		case $.ui.keyCode.PAGE_DOWN:
			this.nextPage( event );
			break;
		case $.ui.keyCode.HOME:
			this._move( "first", "first", event );
			break;
		case $.ui.keyCode.END:
			this._move( "last", "last", event );
			break;
		case $.ui.keyCode.UP:
			this.previous( event );
			break;
		case $.ui.keyCode.DOWN:
			this.next( event );
			break;
		case $.ui.keyCode.LEFT:
			this.collapse( event );
			break;
		case $.ui.keyCode.RIGHT:
			if ( this.active && !this.active.is( ".ui-state-disabled" ) ) {
				this.expand( event );
			}
			break;
		case $.ui.keyCode.ENTER:
		case $.ui.keyCode.SPACE:
			this._activate( event );
			break;
		case $.ui.keyCode.ESCAPE:
			this.collapse( event );
			break;
		default:
			preventDefault = false;
			prev = this.previousFilter || "";
			skip = false;

			// Support number pad values
			character = event.keyCode >= 96 && event.keyCode <= 105 ?
				( event.keyCode - 96 ).toString() : String.fromCharCode( event.keyCode );

			clearTimeout( this.filterTimer );

			if ( character === prev ) {
				skip = true;
			} else {
				character = prev + character;
			}

			match = this._filterMenuItems( character );
			match = skip && match.index( this.active.next() ) !== -1 ?
				this.active.nextAll( ".ui-menu-item" ) :
				match;

			// If no matches on the current filter, reset to the last character pressed
			// to move down the menu to the first item that starts with that character
			if ( !match.length ) {
				character = String.fromCharCode( event.keyCode );
				match = this._filterMenuItems( character );
			}

			if ( match.length ) {
				this.focus( event, match );
				this.previousFilter = character;
				this.filterTimer = this._delay( function() {
					delete this.previousFilter;
				}, 1000 );
			} else {
				delete this.previousFilter;
			}
		}

		if ( preventDefault ) {
			event.preventDefault();
		}
	},

	_activate: function( event ) {
		if ( this.active && !this.active.is( ".ui-state-disabled" ) ) {
			if ( this.active.children( "[aria-haspopup='true']" ).length ) {
				this.expand( event );
			} else {
				this.select( event );
			}
		}
	},

	refresh: function() {
		var menus, items, newSubmenus, newItems, newWrappers,
			that = this,
			icon = this.options.icons.submenu,
			submenus = this.element.find( this.options.menus );

		this._toggleClass( "ui-menu-icons", null, !!this.element.find( ".ui-icon" ).length );

		// Initialize nested menus
		newSubmenus = submenus.filter( ":not(.ui-menu)" )
			.hide()
			.attr( {
				role: this.options.role,
				"aria-hidden": "true",
				"aria-expanded": "false"
			} )
			.each( function() {
				var menu = $( this ),
					item = menu.prev(),
					submenuCaret = $( "<span>" ).data( "ui-menu-submenu-caret", true );

				that._addClass( submenuCaret, "ui-menu-icon", "ui-icon " + icon );
				item
					.attr( "aria-haspopup", "true" )
					.prepend( submenuCaret );
				menu.attr( "aria-labelledby", item.attr( "id" ) );
			} );

		this._addClass( newSubmenus, "ui-menu", "ui-widget ui-widget-content ui-front" );

		menus = submenus.add( this.element );
		items = menus.find( this.options.items );

		// Initialize menu-items containing spaces and/or dashes only as dividers
		items.not( ".ui-menu-item" ).each( function() {
			var item = $( this );
			if ( that._isDivider( item ) ) {
				that._addClass( item, "ui-menu-divider", "ui-widget-content" );
			}
		} );

		// Don't refresh list items that are already adapted
		newItems = items.not( ".ui-menu-item, .ui-menu-divider" );
		newWrappers = newItems.children()
			.not( ".ui-menu" )
				.uniqueId()
				.attr( {
					tabIndex: -1,
					role: this._itemRole()
				} );
		this._addClass( newItems, "ui-menu-item" )
			._addClass( newWrappers, "ui-menu-item-wrapper" );

		// Add aria-disabled attribute to any disabled menu item
		items.filter( ".ui-state-disabled" ).attr( "aria-disabled", "true" );

		// If the active item has been removed, blur the menu
		if ( this.active && !$.contains( this.element[ 0 ], this.active[ 0 ] ) ) {
			this.blur();
		}
	},

	_itemRole: function() {
		return {
			menu: "menuitem",
			listbox: "option"
		}[ this.options.role ];
	},

	_setOption: function( key, value ) {
		if ( key === "icons" ) {
			var icons = this.element.find( ".ui-menu-icon" );
			this._removeClass( icons, null, this.options.icons.submenu )
				._addClass( icons, null, value.submenu );
		}
		this._super( key, value );
	},

	_setOptionDisabled: function( value ) {
		this._super( value );

		this.element.attr( "aria-disabled", String( value ) );
		this._toggleClass( null, "ui-state-disabled", !!value );
	},

	focus: function( event, item ) {
		var nested, focused, activeParent;
		this.blur( event, event && event.type === "focus" );

		this._scrollIntoView( item );

		this.active = item.first();

		focused = this.active.children( ".ui-menu-item-wrapper" );
		this._addClass( focused, null, "ui-state-active" );

		// Only update aria-activedescendant if there's a role
		// otherwise we assume focus is managed elsewhere
		if ( this.options.role ) {
			this.element.attr( "aria-activedescendant", focused.attr( "id" ) );
		}

		// Highlight active parent menu item, if any
		activeParent = this.active
			.parent()
				.closest( ".ui-menu-item" )
					.children( ".ui-menu-item-wrapper" );
		this._addClass( activeParent, null, "ui-state-active" );

		if ( event && event.type === "keydown" ) {
			this._close();
		} else {
			this.timer = this._delay( function() {
				this._close();
			}, this.delay );
		}

		nested = item.children( ".ui-menu" );
		if ( nested.length && event && ( /^mouse/.test( event.type ) ) ) {
			this._startOpening( nested );
		}
		this.activeMenu = item.parent();

		this._trigger( "focus", event, { item: item } );
	},

	_scrollIntoView: function( item ) {
		var borderTop, paddingTop, offset, scroll, elementHeight, itemHeight;
		if ( this._hasScroll() ) {
			borderTop = parseFloat( $.css( this.activeMenu[ 0 ], "borderTopWidth" ) ) || 0;
			paddingTop = parseFloat( $.css( this.activeMenu[ 0 ], "paddingTop" ) ) || 0;
			offset = item.offset().top - this.activeMenu.offset().top - borderTop - paddingTop;
			scroll = this.activeMenu.scrollTop();
			elementHeight = this.activeMenu.height();
			itemHeight = item.outerHeight();

			if ( offset < 0 ) {
				this.activeMenu.scrollTop( scroll + offset );
			} else if ( offset + itemHeight > elementHeight ) {
				this.activeMenu.scrollTop( scroll + offset - elementHeight + itemHeight );
			}
		}
	},

	blur: function( event, fromFocus ) {
		if ( !fromFocus ) {
			clearTimeout( this.timer );
		}

		if ( !this.active ) {
			return;
		}

		this._removeClass( this.active.children( ".ui-menu-item-wrapper" ),
			null, "ui-state-active" );

		this._trigger( "blur", event, { item: this.active } );
		this.active = null;
	},

	_startOpening: function( submenu ) {
		clearTimeout( this.timer );

		// Don't open if already open fixes a Firefox bug that caused a .5 pixel
		// shift in the submenu position when mousing over the caret icon
		if ( submenu.attr( "aria-hidden" ) !== "true" ) {
			return;
		}

		this.timer = this._delay( function() {
			this._close();
			this._open( submenu );
		}, this.delay );
	},

	_open: function( submenu ) {
		var position = $.extend( {
			of: this.active
		}, this.options.position );

		clearTimeout( this.timer );
		this.element.find( ".ui-menu" ).not( submenu.parents( ".ui-menu" ) )
			.hide()
			.attr( "aria-hidden", "true" );

		submenu
			.show()
			.removeAttr( "aria-hidden" )
			.attr( "aria-expanded", "true" )
			.position( position );
	},

	collapseAll: function( event, all ) {
		clearTimeout( this.timer );
		this.timer = this._delay( function() {

			// If we were passed an event, look for the submenu that contains the event
			var currentMenu = all ? this.element :
				$( event && event.target ).closest( this.element.find( ".ui-menu" ) );

			// If we found no valid submenu ancestor, use the main menu to close all
			// sub menus anyway
			if ( !currentMenu.length ) {
				currentMenu = this.element;
			}

			this._close( currentMenu );

			this.blur( event );

			// Work around active item staying active after menu is blurred
			this._removeClass( currentMenu.find( ".ui-state-active" ), null, "ui-state-active" );

			this.activeMenu = currentMenu;
		}, this.delay );
	},

	// With no arguments, closes the currently active menu - if nothing is active
	// it closes all menus.  If passed an argument, it will search for menus BELOW
	_close: function( startMenu ) {
		if ( !startMenu ) {
			startMenu = this.active ? this.active.parent() : this.element;
		}

		startMenu.find( ".ui-menu" )
			.hide()
			.attr( "aria-hidden", "true" )
			.attr( "aria-expanded", "false" );
	},

	_closeOnDocumentClick: function( event ) {
		return !$( event.target ).closest( ".ui-menu" ).length;
	},

	_isDivider: function( item ) {

		// Match hyphen, em dash, en dash
		return !/[^\-\u2014\u2013\s]/.test( item.text() );
	},

	collapse: function( event ) {
		var newItem = this.active &&
			this.active.parent().closest( ".ui-menu-item", this.element );
		if ( newItem && newItem.length ) {
			this._close();
			this.focus( event, newItem );
		}
	},

	expand: function( event ) {
		var newItem = this.active &&
			this.active
				.children( ".ui-menu " )
					.find( this.options.items )
						.first();

		if ( newItem && newItem.length ) {
			this._open( newItem.parent() );

			// Delay so Firefox will not hide activedescendant change in expanding submenu from AT
			this._delay( function() {
				this.focus( event, newItem );
			} );
		}
	},

	next: function( event ) {
		this._move( "next", "first", event );
	},

	previous: function( event ) {
		this._move( "prev", "last", event );
	},

	isFirstItem: function() {
		return this.active && !this.active.prevAll( ".ui-menu-item" ).length;
	},

	isLastItem: function() {
		return this.active && !this.active.nextAll( ".ui-menu-item" ).length;
	},

	_move: function( direction, filter, event ) {
		var next;
		if ( this.active ) {
			if ( direction === "first" || direction === "last" ) {
				next = this.active
					[ direction === "first" ? "prevAll" : "nextAll" ]( ".ui-menu-item" )
					.eq( -1 );
			} else {
				next = this.active
					[ direction + "All" ]( ".ui-menu-item" )
					.eq( 0 );
			}
		}
		if ( !next || !next.length || !this.active ) {
			next = this.activeMenu.find( this.options.items )[ filter ]();
		}

		this.focus( event, next );
	},

	nextPage: function( event ) {
		var item, base, height;

		if ( !this.active ) {
			this.next( event );
			return;
		}
		if ( this.isLastItem() ) {
			return;
		}
		if ( this._hasScroll() ) {
			base = this.active.offset().top;
			height = this.element.height();
			this.active.nextAll( ".ui-menu-item" ).each( function() {
				item = $( this );
				return item.offset().top - base - height < 0;
			} );

			this.focus( event, item );
		} else {
			this.focus( event, this.activeMenu.find( this.options.items )
				[ !this.active ? "first" : "last" ]() );
		}
	},

	previousPage: function( event ) {
		var item, base, height;
		if ( !this.active ) {
			this.next( event );
			return;
		}
		if ( this.isFirstItem() ) {
			return;
		}
		if ( this._hasScroll() ) {
			base = this.active.offset().top;
			height = this.element.height();
			this.active.prevAll( ".ui-menu-item" ).each( function() {
				item = $( this );
				return item.offset().top - base + height > 0;
			} );

			this.focus( event, item );
		} else {
			this.focus( event, this.activeMenu.find( this.options.items ).first() );
		}
	},

	_hasScroll: function() {
		return this.element.outerHeight() < this.element.prop( "scrollHeight" );
	},

	select: function( event ) {

		// TODO: It should never be possible to not have an active item at this
		// point, but the tests don't trigger mouseenter before click.
		this.active = this.active || $( event.target ).closest( ".ui-menu-item" );
		var ui = { item: this.active };
		if ( !this.active.has( ".ui-menu" ).length ) {
			this.collapseAll( event, true );
		}
		this._trigger( "select", event, ui );
	},

	_filterMenuItems: function( character ) {
		var escapedCharacter = character.replace( /[\-\[\]{}()*+?.,\\\^$|#\s]/g, "\\$&" ),
			regex = new RegExp( "^" + escapedCharacter, "i" );

		return this.activeMenu
			.find( this.options.items )

				// Only match on items, not dividers or other content (#10571)
				.filter( ".ui-menu-item" )
					.filter( function() {
						return regex.test(
							$.trim( $( this ).children( ".ui-menu-item-wrapper" ).text() ) );
					} );
	}
} );


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

//>>label: Autocomplete
//>>group: Widgets
//>>description: Lists suggested words as the user is typing.
//>>docs: http://api.jqueryui.com/autocomplete/
//>>demos: http://jqueryui.com/autocomplete/
//>>css.structure: ../../themes/base/core.css
//>>css.structure: ../../themes/base/autocomplete.css
//>>css.theme: ../../themes/base/theme.css



$.widget( "ui.autocomplete", {
	version: "1.12.1",
	defaultElement: "<input>",
	options: {
		appendTo: null,
		autoFocus: false,
		delay: 300,
		minLength: 1,
		position: {
			my: "left top",
			at: "left bottom",
			collision: "none"
		},
		source: null,

		// Callbacks
		change: null,
		close: null,
		focus: null,
		open: null,
		response: null,
		search: null,
		select: null
	},

	requestIndex: 0,
	pending: 0,

	_create: function() {

		// Some browsers only repeat keydown events, not keypress events,
		// so we use the suppressKeyPress flag to determine if we've already
		// handled the keydown event. #7269
		// Unfortunately the code for & in keypress is the same as the up arrow,
		// so we use the suppressKeyPressRepeat flag to avoid handling keypress
		// events when we know the keydown event was used to modify the
		// search term. #7799
		var suppressKeyPress, suppressKeyPressRepeat, suppressInput,
			nodeName = this.element[ 0 ].nodeName.toLowerCase(),
			isTextarea = nodeName === "textarea",
			isInput = nodeName === "input";

		// Textareas are always multi-line
		// Inputs are always single-line, even if inside a contentEditable element
		// IE also treats inputs as contentEditable
		// All other element types are determined by whether or not they're contentEditable
		this.isMultiLine = isTextarea || !isInput && this._isContentEditable( this.element );

		this.valueMethod = this.element[ isTextarea || isInput ? "val" : "text" ];
		this.isNewMenu = true;

		this._addClass( "ui-autocomplete-input" );
		this.element.attr( "autocomplete", "off" );

		this._on( this.element, {
			keydown: function( event ) {
				if ( this.element.prop( "readOnly" ) ) {
					suppressKeyPress = true;
					suppressInput = true;
					suppressKeyPressRepeat = true;
					return;
				}

				suppressKeyPress = false;
				suppressInput = false;
				suppressKeyPressRepeat = false;
				var keyCode = $.ui.keyCode;
				switch ( event.keyCode ) {
				case keyCode.PAGE_UP:
					suppressKeyPress = true;
					this._move( "previousPage", event );
					break;
				case keyCode.PAGE_DOWN:
					suppressKeyPress = true;
					this._move( "nextPage", event );
					break;
				case keyCode.UP:
					suppressKeyPress = true;
					this._keyEvent( "previous", event );
					break;
				case keyCode.DOWN:
					suppressKeyPress = true;
					this._keyEvent( "next", event );
					break;
				case keyCode.ENTER:

					// when menu is open and has focus
					if ( this.menu.active ) {

						// #6055 - Opera still allows the keypress to occur
						// which causes forms to submit
						suppressKeyPress = true;
						event.preventDefault();
						this.menu.select( event );
					}
					break;
				case keyCode.TAB:
					if ( this.menu.active ) {
						this.menu.select( event );
					}
					break;
				case keyCode.ESCAPE:
					if ( this.menu.element.is( ":visible" ) ) {
						if ( !this.isMultiLine ) {
							this._value( this.term );
						}
						this.close( event );

						// Different browsers have different default behavior for escape
						// Single press can mean undo or clear
						// Double press in IE means clear the whole form
						event.preventDefault();
					}
					break;
				default:
					suppressKeyPressRepeat = true;

					// search timeout should be triggered before the input value is changed
					this._searchTimeout( event );
					break;
				}
			},
			keypress: function( event ) {
				if ( suppressKeyPress ) {
					suppressKeyPress = false;
					if ( !this.isMultiLine || this.menu.element.is( ":visible" ) ) {
						event.preventDefault();
					}
					return;
				}
				if ( suppressKeyPressRepeat ) {
					return;
				}

				// Replicate some key handlers to allow them to repeat in Firefox and Opera
				var keyCode = $.ui.keyCode;
				switch ( event.keyCode ) {
				case keyCode.PAGE_UP:
					this._move( "previousPage", event );
					break;
				case keyCode.PAGE_DOWN:
					this._move( "nextPage", event );
					break;
				case keyCode.UP:
					this._keyEvent( "previous", event );
					break;
				case keyCode.DOWN:
					this._keyEvent( "next", event );
					break;
				}
			},
			input: function( event ) {
				if ( suppressInput ) {
					suppressInput = false;
					event.preventDefault();
					return;
				}
				this._searchTimeout( event );
			},
			focus: function() {
				this.selectedItem = null;
				this.previous = this._value();
			},
			blur: function( event ) {
				if ( this.cancelBlur ) {
					delete this.cancelBlur;
					return;
				}

				clearTimeout( this.searching );
				this.close( event );
				this._change( event );
			}
		} );

		this._initSource();
		this.menu = $( "<ul>" )
			.appendTo( this._appendTo() )
			.menu( {

				// disable ARIA support, the live region takes care of that
				role: null
			} )
			.hide()
			.menu( "instance" );

		this._addClass( this.menu.element, "ui-autocomplete", "ui-front" );
		this._on( this.menu.element, {
			mousedown: function( event ) {

				// prevent moving focus out of the text field
				event.preventDefault();

				// IE doesn't prevent moving focus even with event.preventDefault()
				// so we set a flag to know when we should ignore the blur event
				this.cancelBlur = true;
				this._delay( function() {
					delete this.cancelBlur;

					// Support: IE 8 only
					// Right clicking a menu item or selecting text from the menu items will
					// result in focus moving out of the input. However, we've already received
					// and ignored the blur event because of the cancelBlur flag set above. So
					// we restore focus to ensure that the menu closes properly based on the user's
					// next actions.
					if ( this.element[ 0 ] !== $.ui.safeActiveElement( this.document[ 0 ] ) ) {
						this.element.trigger( "focus" );
					}
				} );
			},
			menufocus: function( event, ui ) {
				var label, item;

				// support: Firefox
				// Prevent accidental activation of menu items in Firefox (#7024 #9118)
				if ( this.isNewMenu ) {
					this.isNewMenu = false;
					if ( event.originalEvent && /^mouse/.test( event.originalEvent.type ) ) {
						this.menu.blur();

						this.document.one( "mousemove", function() {
							$( event.target ).trigger( event.originalEvent );
						} );

						return;
					}
				}

				item = ui.item.data( "ui-autocomplete-item" );
				if ( false !== this._trigger( "focus", event, { item: item } ) ) {

					// use value to match what will end up in the input, if it was a key event
					if ( event.originalEvent && /^key/.test( event.originalEvent.type ) ) {
						this._value( item.value );
					}
				}

				// Announce the value in the liveRegion
				label = ui.item.attr( "aria-label" ) || item.value;
				if ( label && $.trim( label ).length ) {
					this.liveRegion.children().hide();
					$( "<div>" ).text( label ).appendTo( this.liveRegion );
				}
			},
			menuselect: function( event, ui ) {
				var item = ui.item.data( "ui-autocomplete-item" ),
					previous = this.previous;

				// Only trigger when focus was lost (click on menu)
				if ( this.element[ 0 ] !== $.ui.safeActiveElement( this.document[ 0 ] ) ) {
					this.element.trigger( "focus" );
					this.previous = previous;

					// #6109 - IE triggers two focus events and the second
					// is asynchronous, so we need to reset the previous
					// term synchronously and asynchronously :-(
					this._delay( function() {
						this.previous = previous;
						this.selectedItem = item;
					} );
				}

				if ( false !== this._trigger( "select", event, { item: item } ) ) {
					this._value( item.value );
				}

				// reset the term after the select event
				// this allows custom select handling to work properly
				this.term = this._value();

				this.close( event );
				this.selectedItem = item;
			}
		} );

		this.liveRegion = $( "<div>", {
			role: "status",
			"aria-live": "assertive",
			"aria-relevant": "additions"
		} )
			.appendTo( this.document[ 0 ].body );

		this._addClass( this.liveRegion, null, "ui-helper-hidden-accessible" );

		// Turning off autocomplete prevents the browser from remembering the
		// value when navigating through history, so we re-enable autocomplete
		// if the page is unloaded before the widget is destroyed. #7790
		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( key, value ) {
		this._super( key, value );
		if ( key === "source" ) {
			this._initSource();
		}
		if ( key === "appendTo" ) {
			this.menu.element.appendTo( this._appendTo() );
		}
		if ( key === "disabled" && value && this.xhr ) {
			this.xhr.abort();
		}
	},

	_isEventTargetInWidget: function( event ) {
		var menuElement = this.menu.element[ 0 ];

		return event.target === this.element[ 0 ] ||
			event.target === menuElement ||
			$.contains( menuElement, event.target );
	},

	_closeOnClickOutside: function( event ) {
		if ( !this._isEventTargetInWidget( event ) ) {
			this.close();
		}
	},

	_appendTo: function() {
		var element = this.options.appendTo;

		if ( element ) {
			element = element.jquery || element.nodeType ?
				$( element ) :
				this.document.find( element ).eq( 0 );
		}

		if ( !element || !element[ 0 ] ) {
			element = this.element.closest( ".ui-front, dialog" );
		}

		if ( !element.length ) {
			element = this.document[ 0 ].body;
		}

		return element;
	},

	_initSource: function() {
		var array, url,
			that = this;
		if ( $.isArray( this.options.source ) ) {
			array = this.options.source;
			this.source = function( request, response ) {
				response( $.ui.autocomplete.filter( array, request.term ) );
			};
		} else if ( typeof this.options.source === "string" ) {
			url = this.options.source;
			this.source = function( request, response ) {
				if ( that.xhr ) {
					that.xhr.abort();
				}
				that.xhr = $.ajax( {
					url: url,
					data: request,
					dataType: "json",
					success: function( data ) {
						response( data );
					},
					error: function() {
						response( [] );
					}
				} );
			};
		} else {
			this.source = this.options.source;
		}
	},

	_searchTimeout: function( event ) {
		clearTimeout( this.searching );
		this.searching = this._delay( function() {

			// Search if the value has changed, or if the user retypes the same value (see #7434)
			var equalValues = this.term === this._value(),
				menuVisible = this.menu.element.is( ":visible" ),
				modifierKey = event.altKey || event.ctrlKey || event.metaKey || event.shiftKey;

			if ( !equalValues || ( equalValues && !menuVisible && !modifierKey ) ) {
				this.selectedItem = null;
				this.search( null, event );
			}
		}, this.options.delay );
	},

	search: function( value, event ) {
		value = value != null ? value : this._value();

		// Always save the actual value, not the one passed as an argument
		this.term = this._value();

		if ( value.length < this.options.minLength ) {
			return this.close( event );
		}

		if ( this._trigger( "search", event ) === false ) {
			return;
		}

		return this._search( value );
	},

	_search: function( value ) {
		this.pending++;
		this._addClass( "ui-autocomplete-loading" );
		this.cancelSearch = false;

		this.source( { term: value }, this._response() );
	},

	_response: function() {
		var index = ++this.requestIndex;

		return $.proxy( function( content ) {
			if ( index === this.requestIndex ) {
				this.__response( content );
			}

			this.pending--;
			if ( !this.pending ) {
				this._removeClass( "ui-autocomplete-loading" );
			}
		}, this );
	},

	__response: function( content ) {
		if ( content ) {
			content = this._normalize( content );
		}
		this._trigger( "response", null, { content: content } );
		if ( !this.options.disabled && content && content.length && !this.cancelSearch ) {
			this._suggest( content );
			this._trigger( "open" );
		} else {

			// use ._close() instead of .close() so we don't cancel future searches
			this._close();
		}
	},

	close: function( event ) {
		this.cancelSearch = true;
		this._close( event );
	},

	_close: function( event ) {

		// Remove the handler that closes the menu on outside clicks
		this._off( this.document, "mousedown" );

		if ( this.menu.element.is( ":visible" ) ) {
			this.menu.element.hide();
			this.menu.blur();
			this.isNewMenu = true;
			this._trigger( "close", event );
		}
	},

	_change: function( event ) {
		if ( this.previous !== this._value() ) {
			this._trigger( "change", event, { item: this.selectedItem } );
		}
	},

	_normalize: function( items ) {

		// assume all items have the right format when the first item is complete
		if ( items.length && items[ 0 ].label && items[ 0 ].value ) {
			return items;
		}
		return $.map( items, function( item ) {
			if ( typeof item === "string" ) {
				return {
					label: item,
					value: item
				};
			}
			return $.extend( {}, item, {
				label: item.label || item.value,
				value: item.value || item.label
			} );
		} );
	},

	_suggest: function( items ) {
		var ul = this.menu.element.empty();
		this._renderMenu( ul, items );
		this.isNewMenu = true;
		this.menu.refresh();

		// Size and position menu
		ul.show();
		this._resizeMenu();
		ul.position( $.extend( {
			of: this.element
		}, this.options.position ) );

		if ( this.options.autoFocus ) {
			this.menu.next();
		}

		// Listen for interactions outside of the widget (#6642)
		this._on( this.document, {
			mousedown: "_closeOnClickOutside"
		} );
	},

	_resizeMenu: function() {
		var ul = this.menu.element;
		ul.outerWidth( Math.max(

			// Firefox wraps long text (possibly a rounding bug)
			// so we add 1px to avoid the wrapping (#7513)
			ul.width( "" ).outerWidth() + 1,
			this.element.outerWidth()
		) );
	},

	_renderMenu: function( ul, items ) {
		var that = this;
		$.each( items, function( index, item ) {
			that._renderItemData( ul, item );
		} );
	},

	_renderItemData: function( ul, item ) {
		return this._renderItem( ul, item ).data( "ui-autocomplete-item", item );
	},

	_renderItem: function( ul, item ) {
		return $( "<li>" )
			.append( $( "<div>" ).text( item.label ) )
			.appendTo( ul );
	},

	_move: function( direction, event ) {
		if ( !this.menu.element.is( ":visible" ) ) {
			this.search( null, event );
			return;
		}
		if ( this.menu.isFirstItem() && /^previous/.test( direction ) ||
				this.menu.isLastItem() && /^next/.test( direction ) ) {

			if ( !this.isMultiLine ) {
				this._value( this.term );
			}

			this.menu.blur();
			return;
		}
		this.menu[ direction ]( event );
	},

	widget: function() {
		return this.menu.element;
	},

	_value: function() {
		return this.valueMethod.apply( this.element, arguments );
	},

	_keyEvent: function( keyEvent, event ) {
		if ( !this.isMultiLine || this.menu.element.is( ":visible" ) ) {
			this._move( keyEvent, event );

			// Prevents moving cursor to beginning/end of the text field in some browsers
			event.preventDefault();
		}
	},

	// Support: Chrome <=50
	// We should be able to just use this.element.prop( "isContentEditable" )
	// but hidden elements always report false in Chrome.
	// https://code.google.com/p/chromium/issues/detail?id=313082
	_isContentEditable: function( element ) {
		if ( !element.length ) {
			return false;
		}

		var editable = element.prop( "contentEditable" );

		if ( editable === "inherit" ) {
		  return this._isContentEditable( element.parent() );
		}

		return editable === "true";
	}
} );

$.extend( $.ui.autocomplete, {
	escapeRegex: function( value ) {
		return value.replace( /[\-\[\]{}()*+?.,\\\^$|#\s]/g, "\\$&" );
	},
	filter: function( array, term ) {
		var matcher = new RegExp( $.ui.autocomplete.escapeRegex( term ), "i" );
		return $.grep( array, function( value ) {
			return matcher.test( value.label || value.value || value );
		} );
	}
} );

// Live region extension, adding a `messages` option
// NOTE: This is an experimental API. We are still investigating
// a full solution for string manipulation and internationalization.
$.widget( "ui.autocomplete", $.ui.autocomplete, {
	options: {
		messages: {
			noResults: "No search results.",
			results: function( amount ) {
				return amount + ( amount > 1 ? " results are" : " result is" ) +
					" available, use up and down arrow keys to navigate.";
			}
		}
	},

	__response: function( content ) {
		var message;
		this._superApply( arguments );
		if ( this.options.disabled || this.cancelSearch ) {
			return;
		}
		if ( content && content.length ) {
			message = this.options.messages.results( content.length );
		} else {
			message = this.options.messages.noResults;
		}
		this.liveRegion.children().hide();
		$( "<div>" ).text( message ).appendTo( this.liveRegion );
	}
} );

var widgetsAutocomplete = $.ui.autocomplete;


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

//>>label: Controlgroup
//>>group: Widgets
//>>description: Visually groups form control widgets
//>>docs: http://api.jqueryui.com/controlgroup/
//>>demos: http://jqueryui.com/controlgroup/
//>>css.structure: ../../themes/base/core.css
//>>css.structure: ../../themes/base/controlgroup.css
//>>css.theme: ../../themes/base/theme.css


var controlgroupCornerRegex = /ui-corner-([a-z]){2,6}/g;

var widgetsControlgroup = $.widget( "ui.controlgroup", {
	version: "1.12.1",
	defaultElement: "<div>",
	options: {
		direction: "horizontal",
		disabled: null,
		onlyVisible: true,
		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();
	},

	// To support the enhanced option in jQuery Mobile, we isolate DOM manipulation
	_enhance: function() {
		this.element.attr( "role", "toolbar" );
		this.refresh();
	},

	_destroy: function() {
		this._callChildMethod( "destroy" );
		this.childWidgets.removeData( "ui-controlgroup-data" );
		this.element.removeAttr( "role" );
		if ( this.options.items.controlgroupLabel ) {
			this.element
				.find( this.options.items.controlgroupLabel )
				.find( ".ui-controlgroup-label-contents" )
				.contents().unwrap();
		}
	},

	_initWidgets: function() {
		var that = this,
			childWidgets = [];

		// First we iterate over each of the items options
		$.each( this.options.items, function( widget, selector ) {
			var labels;
			var options = {};

			// Make sure the widget has a selector set
			if ( !selector ) {
				return;
			}

			if ( widget === "controlgroupLabel" ) {
				labels = that.element.find( selector );
				labels.each( function() {
					var element = $( this );

					if ( element.children( ".ui-controlgroup-label-contents" ).length ) {
						return;
					}
					element.contents()
						.wrapAll( "<span class='ui-controlgroup-label-contents'></span>" );
				} );
				that._addClass( labels, null, "ui-widget ui-widget-content ui-state-default" );
				childWidgets = childWidgets.concat( labels.get() );
				return;
			}

			// Make sure the widget actually exists
			if ( !$.fn[ widget ] ) {
				return;
			}

			// We assume everything is in the middle to start because we can't determine
			// first / last elements until all enhancments are done.
			if ( that[ "_" + widget + "Options" ] ) {
				options = that[ "_" + widget + "Options" ]( "middle" );
			} else {
				options = { classes: {} };
			}

			// Find instances of this widget inside controlgroup and init them
			that.element
				.find( selector )
				.each( function() {
					var element = $( this );
					var instance = element[ widget ]( "instance" );

					// We need to clone the default options for this type of widget to avoid
					// polluting the variable options which has a wider scope than a single widget.
					var instanceOptions = $.widget.extend( {}, options );

					// If the button is the child of a spinner ignore it
					// TODO: Find a more generic solution
					if ( widget === "button" && element.parent( ".ui-spinner" ).length ) {
						return;
					}

					// Create the widget if it doesn't exist
					if ( !instance ) {
						instance = element[ widget ]()[ widget ]( "instance" );
					}
					if ( instance ) {
						instanceOptions.classes =
							that._resolveClassesValues( instanceOptions.classes, instance );
					}
					element[ widget ]( instanceOptions );

					// Store an instance of the controlgroup to be able to reference
					// from the outermost element for changing options and refresh
					var widgetElement = element[ widget ]( "widget" );
					$.data( widgetElement[ 0 ], "ui-controlgroup-data",
						instance ? instance : element[ widget ]( "instance" ) );

					childWidgets.push( widgetElement[ 0 ] );
				} );
		} );

		this.childWidgets = $( $.unique( childWidgets ) );
		this._addClass( this.childWidgets, "ui-controlgroup-item" );
	},

	_callChildMethod: function( method ) {
		this.childWidgets.each( function() {
			var element = $( this ),
				data = element.data( "ui-controlgroup-data" );
			if ( data && data[ method ] ) {
				data[ method ]();
			}
		} );
	},

	_updateCornerClass: function( element, position ) {
		var remove = "ui-corner-top ui-corner-bottom ui-corner-left ui-corner-right ui-corner-all";
		var add = this._buildSimpleOptions( position, "label" ).classes.label;

		this._removeClass( element, null, remove );
		this._addClass( element, null, add );
	},

	_buildSimpleOptions: function( position, key ) {
		var direction = this.options.direction === "vertical";
		var result = {
			classes: {}
		};
		result.classes[ key ] = {
			"middle": "",
			"first": "ui-corner-" + ( direction ? "top" : "left" ),
			"last": "ui-corner-" + ( direction ? "bottom" : "right" ),
			"only": "ui-corner-all"
		}[ position ];

		return result;
	},

	_spinnerOptions: function( position ) {
		var options = this._buildSimpleOptions( position, "ui-spinner" );

		options.classes[ "ui-spinner-up" ] = "";
		options.classes[ "ui-spinner-down" ] = "";

		return options;
	},

	_buttonOptions: function( position ) {
		return this._buildSimpleOptions( position, "ui-button" );
	},

	_checkboxradioOptions: function( position ) {
		return this._buildSimpleOptions( position, "ui-checkboxradio-label" );
	},

	_selectmenuOptions: function( position ) {
		var direction = this.options.direction === "vertical";
		return {
			width: direction ? "auto" : false,
			classes: {
				middle: {
					"ui-selectmenu-button-open": "",
					"ui-selectmenu-button-closed": ""
				},
				first: {
					"ui-selectmenu-button-open": "ui-corner-" + ( direction ? "top" : "tl" ),
					"ui-selectmenu-button-closed": "ui-corner-" + ( direction ? "top" : "left" )
				},
				last: {
					"ui-selectmenu-button-open": direction ? "" : "ui-corner-tr",
					"ui-selectmenu-button-closed": "ui-corner-" + ( direction ? "bottom" : "right" )
				},
				only: {
					"ui-selectmenu-button-open": "ui-corner-top",
					"ui-selectmenu-button-closed": "ui-corner-all"
				}

			}[ position ]
		};
	},

	_resolveClassesValues: function( classes, instance ) {
		var result = {};
		$.each( classes, function( key ) {
			var current = instance.options.classes[ key ] || "";
			current = $.trim( current.replace( controlgroupCornerRegex, "" ) );
			result[ key ] = ( current + " " + classes[ key ] ).replace( /\s+/g, " " );
		} );
		return result;
	},

	_setOption: function( key, value ) {
		if ( key === "direction" ) {
			this._removeClass( "ui-controlgroup-" + this.options.direction );
		}

		this._super( key, value );
		if ( key === "disabled" ) {
			this._callChildMethod( value ? "disable" : "enable" );
			return;
		}

		this.refresh();
	},

	refresh: function() {
		var children,
			that = this;

		this._addClass( "ui-controlgroup ui-controlgroup-" + this.options.direction );

		if ( this.options.direction === "horizontal" ) {
			this._addClass( null, "ui-helper-clearfix" );
		}
		this._initWidgets();

		children = this.childWidgets;

		// We filter here because we need to track all childWidgets not just the visible ones
		if ( this.options.onlyVisible ) {
			children = children.filter( ":visible" );
		}

		if ( children.length ) {

			// We do this last because we need to make sure all enhancment is done
			// before determining first and last
			$.each( [ "first", "last" ], function( index, value ) {
				var instance = children[ value ]().data( "ui-controlgroup-data" );

				if ( instance && that[ "_" + instance.widgetName + "Options" ] ) {
					var options = that[ "_" + instance.widgetName + "Options" ](
						children.length === 1 ? "only" : value
					);
					options.classes = that._resolveClassesValues( options.classes, instance );
					instance.element[ instance.widgetName ]( options );
				} else {
					that._updateCornerClass( children[ value ](), value );
				}
			} );

			// Finally call the refresh method on each of the child widgets.
			this._callChildMethod( "refresh" );
		}
	}
} );

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

//>>label: Checkboxradio
//>>group: Widgets
//>>description: Enhances a form with multiple themeable checkboxes or radio buttons.
//>>docs: http://api.jqueryui.com/checkboxradio/
//>>demos: http://jqueryui.com/checkboxradio/
//>>css.structure: ../../themes/base/core.css
//>>css.structure: ../../themes/base/button.css
//>>css.structure: ../../themes/base/checkboxradio.css
//>>css.theme: ../../themes/base/theme.css



$.widget( "ui.checkboxradio", [ $.ui.formResetMixin, {
	version: "1.12.1",
	options: {
		disabled: null,
		label: null,
		icon: true,
		classes: {
			"ui-checkboxradio-label": "ui-corner-all",
			"ui-checkboxradio-icon": "ui-corner-all"
		}
	},

	_getCreateOptions: function() {
		var disabled, labels;
		var that = this;
		var options = this._super() || {};

		// We read the type here, because it makes more sense to throw a element type error first,
		// rather then the error for lack of a label. Often if its the wrong type, it
		// won't have a label (e.g. calling on a div, btn, etc)
		this._readType();

		labels = this.element.labels();

		// If there are multiple labels, use the last one
		this.label = $( labels[ labels.length - 1 ] );
		if ( !this.label.length ) {
			$.error( "No label found for checkboxradio widget" );
		}

		this.originalLabel = "";

		// We need to get the label text but this may also need to make sure it does not contain the
		// input itself.
		this.label.contents().not( this.element[ 0 ] ).each( function() {

			// The label contents could be text, html, or a mix. We concat each element to get a
			// string representation of the label, without the input as part of it.
			that.originalLabel += this.nodeType === 3 ? $( this ).text() : this.outerHTML;
		} );

		// Set the label option if we found label text
		if ( this.originalLabel ) {
			options.label = this.originalLabel;
		}

		disabled = this.element[ 0 ].disabled;
		if ( disabled != null ) {
			options.disabled = disabled;
		}
		return options;
	},

	_create: function() {
		var checked = this.element[ 0 ].checked;

		this._bindFormResetHandler();

		if ( this.options.disabled == null ) {
			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" );

		if ( this.type === "radio" ) {
			this._addClass( this.label, "ui-checkboxradio-radio-label" );
		}

		if ( this.options.label && this.options.label !== this.originalLabel ) {
			this._updateLabel();
		} else if ( this.originalLabel ) {
			this.options.label = this.originalLabel;
		}

		this._enhance();

		if ( checked ) {
			this._addClass( this.label, "ui-checkboxradio-checked", "ui-state-active" );
			if ( this.icon ) {
				this._addClass( this.icon, null, "ui-state-hover" );
			}
		}

		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 nodeName = this.element[ 0 ].nodeName.toLowerCase();
		this.type = this.element[ 0 ].type;
		if ( nodeName !== "input" || !/radio|checkbox/.test( this.type ) ) {
			$.error( "Can't create checkboxradio on element.nodeName=" + nodeName +
				" and element.type=" + this.type );
		}
	},

	// Support jQuery Mobile enhanced option
	_enhance: function() {
		this._updateIcon( this.element[ 0 ].checked );
	},

	widget: function() {
		return this.label;
	},

	_getRadioGroup: function() {
		var group;
		var name = this.element[ 0 ].name;
		var nameSelector = "input[name='" + $.ui.escapeSelector( name ) + "']";

		if ( !name ) {
			return $( [] );
		}

		if ( this.form.length ) {
			group = $( this.form[ 0 ].elements ).filter( nameSelector );
		} else {

			// Not inside a form, check all inputs that also are not inside a form
			group = $( nameSelector ).filter( function() {
				return $( this ).form().length === 0;
			} );
		}

		return group.not( this.element );
	},

	_toggleClasses: function() {
		var checked = this.element[ 0 ].checked;
		this._toggleClass( this.label, "ui-checkboxradio-checked", "ui-state-active", checked );

		if ( this.options.icon && this.type === "checkbox" ) {
			this._toggleClass( this.icon, null, "ui-icon-check ui-state-checked", checked )
				._toggleClass( this.icon, null, "ui-icon-blank", !checked );
		}

		if ( this.type === "radio" ) {
			this._getRadioGroup()
				.each( function() {
					var instance = $( this ).checkboxradio( "instance" );

					if ( instance ) {
						instance._removeClass( instance.label,
							"ui-checkboxradio-checked", "ui-state-active" );
					}
				} );
		}
	},

	_destroy: function() {
		this._unbindFormResetHandler();

		if ( this.icon ) {
			this.icon.remove();
			this.iconSpace.remove();
		}
	},

	_setOption: function( key, value ) {

		// We don't allow the value to be set to nothing
		if ( key === "label" && !value ) {
			return;
		}

		this._super( key, value );

		if ( key === "disabled" ) {
			this._toggleClass( this.label, null, "ui-state-disabled", value );
			this.element[ 0 ].disabled = value;

			// Don't refresh when setting disabled
			return;
		}
		this.refresh();
	},

	_updateIcon: function( checked ) {
		var toAdd = "ui-icon ui-icon-background ";

		if ( this.options.icon ) {
			if ( !this.icon ) {
				this.icon = $( "<span>" );
				this.iconSpace = $( "<span> </span>" );
				this._addClass( this.iconSpace, "ui-checkboxradio-icon-space" );
			}

			if ( this.type === "checkbox" ) {
				toAdd += checked ? "ui-icon-check ui-state-checked" : "ui-icon-blank";
				this._removeClass( this.icon, null, checked ? "ui-icon-blank" : "ui-icon-check" );
			} else {
				toAdd += "ui-icon-blank";
			}
			this._addClass( this.icon, "ui-checkboxradio-icon", toAdd );
			if ( !checked ) {
				this._removeClass( this.icon, null, "ui-icon-check ui-state-checked" );
			}
			this.icon.prependTo( this.label ).after( this.iconSpace );
		} else if ( this.icon !== undefined ) {
			this.icon.remove();
			this.iconSpace.remove();
			delete this.icon;
		}
	},

	_updateLabel: function() {

		// Remove the contents of the label ( minus the icon, icon space, and input )
		var contents = this.label.contents().not( this.element[ 0 ] );
		if ( this.icon ) {
			contents = contents.not( this.icon[ 0 ] );
		}
		if ( this.iconSpace ) {
			contents = contents.not( this.iconSpace[ 0 ] );
		}
		contents.remove();

		this.label.append( this.options.label );
	},

	refresh: function() {
		var checked = this.element[ 0 ].checked,
			isDisabled = this.element[ 0 ].disabled;

		this._updateIcon( checked );
		this._toggleClass( this.label, "ui-checkboxradio-checked", "ui-state-active", checked );
		if ( this.options.label !== null ) {
			this._updateLabel();
		}

		if ( isDisabled !== this.options.disabled ) {
			this._setOptions( { "disabled": isDisabled } );
		}
	}

} ] );

var widgetsCheckboxradio = $.ui.checkboxradio;


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

//>>label: Button
//>>group: Widgets
//>>description: Enhances a form with themeable buttons.
//>>docs: http://api.jqueryui.com/button/
//>>demos: http://jqueryui.com/button/
//>>css.structure: ../../themes/base/core.css
//>>css.structure: ../../themes/base/button.css
//>>css.theme: ../../themes/base/theme.css



$.widget( "ui.button", {
	version: "1.12.1",
	defaultElement: "<button>",
	options: {
		classes: {
			"ui-button": "ui-corner-all"
		},
		disabled: null,
		icon: null,
		iconPosition: "beginning",
		label: null,
		showLabel: true
	},

	_getCreateOptions: function() {
		var disabled,

			// This is to support cases like in jQuery Mobile where the base widget does have
			// an implementation of _getCreateOptions
			options = this._super() || {};

		this.isInput = this.element.is( "input" );

		disabled = this.element[ 0 ].disabled;
		if ( disabled != null ) {
			options.disabled = disabled;
		}

		this.originalLabel = this.isInput ? this.element.val() : this.element.html();
		if ( this.originalLabel ) {
			options.label = this.originalLabel;
		}

		return options;
	},

	_create: function() {
		if ( !this.option.showLabel & !this.options.icon ) {
			this.options.showLabel = true;
		}

		// We have to check the option again here even though we did in _getCreateOptions,
		// because null may have been passed on init which would override what was set in
		// _getCreateOptions
		if ( this.options.disabled == null ) {
			this.options.disabled = this.element[ 0 ].disabled || false;
		}

		this.hasTitle = !!this.element.attr( "title" );

		// Check to see if the label needs to be set or if its already correct
		if ( this.options.label && this.options.label !== this.originalLabel ) {
			if ( this.isInput ) {
				this.element.val( this.options.label );
			} else {
				this.element.html( this.options.label );
			}
		}
		this._addClass( "ui-button", "ui-widget" );
		this._setOption( "disabled", this.options.disabled );
		this._enhance();

		if ( this.element.is( "a" ) ) {
			this._on( {
				"keyup": function( event ) {
					if ( event.keyCode === $.ui.keyCode.SPACE ) {
						event.preventDefault();

						// Support: PhantomJS <= 1.9, IE 8 Only
						// If a native click is available use it so we actually cause navigation
						// otherwise just trigger a click event
						if ( this.element[ 0 ].click ) {
							this.element[ 0 ].click();
						} else {
							this.element.trigger( "click" );
						}
					}
				}
			} );
		}
	},

	_enhance: function() {
		if ( !this.element.is( "button" ) ) {
			this.element.attr( "role", "button" );
		}

		if ( this.options.icon ) {
			this._updateIcon( "icon", this.options.icon );
			this._updateTooltip();
		}
	},

	_updateTooltip: function() {
		this.title = this.element.attr( "title" );

		if ( !this.options.showLabel && !this.title ) {
			this.element.attr( "title", this.options.label );
		}
	},

	_updateIcon: function( option, value ) {
		var icon = option !== "iconPosition",
			position = icon ? this.options.iconPosition : value,
			displayBlock = position === "top" || position === "bottom";

		// Create icon
		if ( !this.icon ) {
			this.icon = $( "<span>" );

			this._addClass( this.icon, "ui-button-icon", "ui-icon" );

			if ( !this.options.showLabel ) {
				this._addClass( "ui-button-icon-only" );
			}
		} else if ( icon ) {

			// If we are updating the icon remove the old icon class
			this._removeClass( this.icon, null, this.options.icon );
		}

		// If we are updating the icon add the new icon class
		if ( icon ) {
			this._addClass( this.icon, null, value );
		}

		this._attachIcon( position );

		// If the icon is on top or bottom we need to add the ui-widget-icon-block class and remove
		// the iconSpace if there is one.
		if ( displayBlock ) {
			this._addClass( this.icon, null, "ui-widget-icon-block" );
			if ( this.iconSpace ) {
				this.iconSpace.remove();
			}
		} else {

			// Position is beginning or end so remove the ui-widget-icon-block class and add the
			// space if it does not exist
			if ( !this.iconSpace ) {
				this.iconSpace = $( "<span> </span>" );
				this._addClass( this.iconSpace, "ui-button-icon-space" );
			}
			this._removeClass( this.icon, null, "ui-wiget-icon-block" );
			this._attachIconSpace( position );
		}
	},

	_destroy: function() {
		this.element.removeAttr( "role" );

		if ( this.icon ) {
			this.icon.remove();
		}
		if ( this.iconSpace ) {
			this.iconSpace.remove();
		}
		if ( !this.hasTitle ) {
			this.element.removeAttr( "title" );
		}
	},

	_attachIconSpace: function( iconPosition ) {
		this.icon[ /^(?:end|bottom)/.test( iconPosition ) ? "before" : "after" ]( this.iconSpace );
	},

	_attachIcon: function( iconPosition ) {
		this.element[ /^(?:end|bottom)/.test( iconPosition ) ? "append" : "prepend" ]( this.icon );
	},

	_setOptions: function( options ) {
		var newShowLabel = options.showLabel === undefined ?
				this.options.showLabel :
				options.showLabel,
			newIcon = options.icon === undefined ? this.options.icon : options.icon;

		if ( !newShowLabel && !newIcon ) {
			options.showLabel = true;
		}
		this._super( options );
	},

	_setOption: function( key, value ) {
		if ( key === "icon" ) {
			if ( value ) {
				this._updateIcon( key, value );
			} else if ( this.icon ) {
				this.icon.remove();
				if ( this.iconSpace ) {
					this.iconSpace.remove();
				}
			}
		}

		if ( key === "iconPosition" ) {
			this._updateIcon( key, value );
		}

		// Make sure we can't end up with a button that has neither text nor icon
		if ( key === "showLabel" ) {
				this._toggleClass( "ui-button-icon-only", null, !value );
				this._updateTooltip();
		}

		if ( key === "label" ) {
			if ( this.isInput ) {
				this.element.val( value );
			} else {

				// If there is an icon, append it, else nothing then append the value
				// this avoids removal of the icon when setting label text
				this.element.html( value );
				if ( this.icon ) {
					this._attachIcon( this.options.iconPosition );
					this._attachIconSpace( this.options.iconPosition );
				}
			}
		}

		this._super( key, value );

		if ( key === "disabled" ) {
			this._toggleClass( null, "ui-state-disabled", value );
			this.element[ 0 ].disabled = value;
			if ( value ) {
				this.element.blur();
			}
		}
	},

	refresh: function() {

		// Make sure to only check disabled if its an element that supports this otherwise
		// check for the disabled class to determine state
		var isDisabled = this.element.is( "input, button" ) ?
			this.element[ 0 ].disabled : this.element.hasClass( "ui-button-disabled" );

		if ( isDisabled !== this.options.disabled ) {
			this._setOptions( { disabled: isDisabled } );
		}

		this._updateTooltip();
	}
} );

// DEPRECATED
if ( $.uiBackCompat !== false ) {

	// Text and Icons options
	$.widget( "ui.button", $.ui.button, {
		options: {
			text: true,
			icons: {
				primary: null,
				secondary: null
			}
		},

		_create: function() {
			if ( this.options.showLabel && !this.options.text ) {
				this.options.showLabel = this.options.text;
			}
			if ( !this.options.showLabel && this.options.text ) {
				this.options.text = this.options.showLabel;
			}
			if ( !this.options.icon && ( this.options.icons.primary ||
					this.options.icons.secondary ) ) {
				if ( this.options.icons.primary ) {
					this.options.icon = this.options.icons.primary;
				} else {
					this.options.icon = this.options.icons.secondary;
					this.options.iconPosition = "end";
				}
			} else if ( this.options.icon ) {
				this.options.icons.primary = this.options.icon;
			}
			this._super();
		},

		_setOption: function( key, value ) {
			if ( key === "text" ) {
				this._super( "showLabel", value );
				return;
			}
			if ( key === "showLabel" ) {
				this.options.text = value;
			}
			if ( key === "icon" ) {
				this.options.icons.primary = value;
			}
			if ( key === "icons" ) {
				if ( value.primary ) {
					this._super( "icon", value.primary );
					this._super( "iconPosition", "beginning" );
				} else if ( value.secondary ) {
					this._super( "icon", value.secondary );
					this._super( "iconPosition", "end" );
				}
			}
			this._superApply( arguments );
		}
	} );

	$.fn.button = ( function( orig ) {
		return function() {
			if ( !this.length || ( this.length && this[ 0 ].tagName !== "INPUT" ) ||
					( this.length && this[ 0 ].tagName === "INPUT" && (
						this.attr( "type" ) !== "checkbox" && this.attr( "type" ) !== "radio"
					) ) ) {
				return orig.apply( this, arguments );
			}
			if ( !$.ui.checkboxradio ) {
				$.error( "Checkboxradio widget missing" );
			}
			if ( arguments.length === 0 ) {
				return this.checkboxradio( {
					"icon": false
				} );
			}
			return this.checkboxradio.apply( this, arguments );
		};
	} )( $.fn.button );

	$.fn.buttonset = function() {
		if ( !$.ui.controlgroup ) {
			$.error( "Controlgroup widget missing" );
		}
		if ( arguments[ 0 ] === "option" && arguments[ 1 ] === "items" && arguments[ 2 ] ) {
			return this.controlgroup.apply( this,
				[ arguments[ 0 ], "items.button", arguments[ 2 ] ] );
		}
		if ( arguments[ 0 ] === "option" && arguments[ 1 ] === "items" ) {
			return this.controlgroup.apply( this, [ arguments[ 0 ], "items.button" ] );
		}
		if ( typeof arguments[ 0 ] === "object" && arguments[ 0 ].items ) {
			arguments[ 0 ].items = {
				button: arguments[ 0 ].items
			};
		}
		return this.controlgroup.apply( this, arguments );
	};
}

var widgetsButton = $.ui.button;


// jscs:disable maximumLineLength
/* jscs:disable requireCamelCaseOrUpperCaseIdentifiers */
/*!
 * jQuery UI Datepicker 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Datepicker
//>>group: Widgets
//>>description: Displays a calendar from an input or inline for selecting dates.
//>>docs: http://api.jqueryui.com/datepicker/
//>>demos: http://jqueryui.com/datepicker/
//>>css.structure: ../../themes/base/core.css
//>>css.structure: ../../themes/base/datepicker.css
//>>css.theme: ../../themes/base/theme.css



$.extend( $.ui, { datepicker: { version: "1.12.1" } } );

var datepicker_instActive;

function datepicker_getZindex( elem ) {
	var position, value;
	while ( elem.length && elem[ 0 ] !== document ) {

		// Ignore z-index if position is set to a value where z-index is ignored by the browser
		// This makes behavior of this function consistent across browsers
		// WebKit always returns auto if the element is positioned
		position = elem.css( "position" );
		if ( position === "absolute" || position === "relative" || position === "fixed" ) {

			// IE returns 0 when zIndex is not specified
			// other browsers return a string
			// we ignore the case of nested elements with an explicit value of 0
			// <div style="z-index: -10;"><div style="z-index: 0;"></div></div>
			value = parseInt( elem.css( "zIndex" ), 10 );
			if ( !isNaN( value ) && value !== 0 ) {
				return value;
			}
		}
		elem = elem.parent();
	}

	return 0;
}
/* Date picker manager.
   Use the singleton instance of this class, $.datepicker, to interact with the date picker.
   Settings for (groups of) date pickers are maintained in an instance object,
   allowing multiple different settings on the same page. */

function Datepicker() {
	this._curInst = null; // The current instance in use
	this._keyEvent = false; // If the last event was a key event
	this._disabledInputs = []; // List of date picker inputs that have been disabled
	this._datepickerShowing = false; // True if the popup picker is showing , false if not
	this._inDialog = false; // True if showing within a "dialog", false if not
	this._mainDivId = "ui-datepicker-div"; // The ID of the main datepicker division
	this._inlineClass = "ui-datepicker-inline"; // The name of the inline marker class
	this._appendClass = "ui-datepicker-append"; // The name of the append marker class
	this._triggerClass = "ui-datepicker-trigger"; // The name of the trigger marker class
	this._dialogClass = "ui-datepicker-dialog"; // The name of the dialog marker class
	this._disableClass = "ui-datepicker-disabled"; // The name of the disabled covering marker class
	this._unselectableClass = "ui-datepicker-unselectable"; // The name of the unselectable cell marker class
	this._currentClass = "ui-datepicker-current-day"; // The name of the current day marker class
	this._dayOverClass = "ui-datepicker-days-cell-over"; // The name of the day hover marker class
	this.regional = []; // Available regional settings, indexed by language code
	this.regional[ "" ] = { // Default regional settings
		closeText: "Done", // Display text for close link
		prevText: "Prev", // Display text for previous month link
		nextText: "Next", // Display text for next month link
		currentText: "Today", // Display text for current month link
		monthNames: [ "January","February","March","April","May","June",
			"July","August","September","October","November","December" ], // Names of months for drop-down and formatting
		monthNamesShort: [ "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" ], // For formatting
		dayNames: [ "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday" ], // For formatting
		dayNamesShort: [ "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" ], // For formatting
		dayNamesMin: [ "Su","Mo","Tu","We","Th","Fr","Sa" ], // Column headings for days starting at Sunday
		weekHeader: "Wk", // Column header for week of the year
		dateFormat: "mm/dd/yy", // See format options on parseDate
		firstDay: 0, // The first day of the week, Sun = 0, Mon = 1, ...
		isRTL: false, // True if right-to-left language, false if left-to-right
		showMonthAfterYear: false, // True if the year select precedes month, false for month then year
		yearSuffix: "" // Additional text to append to the year in the month headers
	};
	this._defaults = { // Global defaults for all the date picker instances
		showOn: "focus", // "focus" for popup on focus,
			// "button" for trigger button, or "both" for either
		showAnim: "fadeIn", // Name of jQuery animation for popup
		showOptions: {}, // Options for enhanced animations
		defaultDate: null, // Used when field is blank: actual date,
			// +/-number for offset from today, null for today
		appendText: "", // Display text following the input box, e.g. showing the format
		buttonText: "...", // Text for trigger button
		buttonImage: "", // URL for trigger button image
		buttonImageOnly: false, // True if the image appears alone, false if it appears on a button
		hideIfNoPrevNext: false, // True to hide next/previous month links
			// if not applicable, false to just disable them
		navigationAsDateFormat: false, // True if date formatting applied to prev/today/next links
		gotoCurrent: false, // True if today link goes back to current selection instead
		changeMonth: false, // True if month can be selected directly, false if only prev/next
		changeYear: false, // True if year can be selected directly, false if only prev/next
		yearRange: "c-10:c+10", // Range of years to display in drop-down,
			// either relative to today's year (-nn:+nn), relative to currently displayed year
			// (c-nn:c+nn), absolute (nnnn:nnnn), or a combination of the above (nnnn:-n)
		showOtherMonths: false, // True to show dates in other months, false to leave blank
		selectOtherMonths: false, // True to allow selection of dates in other months, false for unselectable
		showWeek: false, // True to show week of the year, false to not show it
		calculateWeek: this.iso8601Week, // How to calculate the week of the year,
			// takes a Date and returns the number of the week for it
		shortYearCutoff: "+10", // Short year values < this are in the current century,
			// > this are in the previous century,
			// string value starting with "+" for current year + value
		minDate: null, // The earliest selectable date, or null for no limit
		maxDate: null, // The latest selectable date, or null for no limit
		duration: "fast", // Duration of display/closure
		beforeShowDay: null, // Function that takes a date and returns an array with
			// [0] = true if selectable, false if not, [1] = custom CSS class name(s) or "",
			// [2] = cell title (optional), e.g. $.datepicker.noWeekends
		beforeShow: null, // Function that takes an input field and
			// returns a set of custom settings for the date picker
		onSelect: null, // Define a callback function when a date is selected
		onChangeMonthYear: null, // Define a callback function when the month or year is changed
		onClose: null, // Define a callback function when the datepicker is closed
		numberOfMonths: 1, // Number of months to show at a time
		showCurrentAtPos: 0, // The position in multipe months at which to show the current month (starting at 0)
		stepMonths: 1, // Number of months to step back/forward
		stepBigMonths: 12, // Number of months to step back/forward for the big links
		altField: "", // Selector for an alternate field to store selected dates into
		altFormat: "", // The date format to use for the alternate field
		constrainInput: true, // The input is constrained by the current date format
		showButtonPanel: false, // True to show button panel, false to not show it
		autoSize: false, // True to size the input for the date format, false to leave as is
		disabled: false // The initial disabled state
	};
	$.extend( this._defaults, this.regional[ "" ] );
	this.regional.en = $.extend( true, {}, this.regional[ "" ] );
	this.regional[ "en-US" ] = $.extend( true, {}, this.regional.en );
	this.dpDiv = datepicker_bindHover( $( "<div id='" + this._mainDivId + "' class='ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'></div>" ) );
}

$.extend( Datepicker.prototype, {
	/* Class name added to elements to indicate already configured with a date picker. */
	markerClassName: "hasDatepicker",

	//Keep track of the maximum number of rows displayed (see #7043)
	maxRows: 4,

	// TODO rename to "widget" when switching to widget factory
	_widgetDatepicker: function() {
		return this.dpDiv;
	},

	/* Override the default settings for all instances of the date picker.
	 * @param  settings  object - the new settings to use as defaults (anonymous object)
	 * @return the manager object
	 */
	setDefaults: function( settings ) {
		datepicker_extendRemove( this._defaults, settings || {} );
		return this;
	},

	/* Attach the date picker to a jQuery selection.
	 * @param  target	element - the target input field or division or span
	 * @param  settings  object - the new settings to use for this date picker instance (anonymous)
	 */
	_attachDatepicker: function( target, settings ) {
		var nodeName, inline, inst;
		nodeName = target.nodeName.toLowerCase();
		inline = ( nodeName === "div" || nodeName === "span" );
		if ( !target.id ) {
			this.uuid += 1;
			target.id = "dp" + this.uuid;
		}
		inst = this._newInst( $( target ), inline );
		inst.settings = $.extend( {}, settings || {} );
		if ( nodeName === "input" ) {
			this._connectDatepicker( target, inst );
		} else if ( inline ) {
			this._inlineDatepicker( target, inst );
		}
	},

	/* Create a new instance object. */
	_newInst: function( target, inline ) {
		var id = target[ 0 ].id.replace( /([^A-Za-z0-9_\-])/g, "\\\\$1" ); // escape jQuery meta chars
		return { id: id, input: target, // associated target
			selectedDay: 0, selectedMonth: 0, selectedYear: 0, // current selection
			drawMonth: 0, drawYear: 0, // month being drawn
			inline: inline, // is datepicker inline or not
			dpDiv: ( !inline ? this.dpDiv : // presentation div
			datepicker_bindHover( $( "<div class='" + this._inlineClass + " ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'></div>" ) ) ) };
	},

	/* Attach the date picker to an input field. */
	_connectDatepicker: function( target, inst ) {
		var input = $( target );
		inst.append = $( [] );
		inst.trigger = $( [] );
		if ( input.hasClass( this.markerClassName ) ) {
			return;
		}
		this._attachments( input, inst );
		input.addClass( this.markerClassName ).on( "keydown", this._doKeyDown ).
			on( "keypress", this._doKeyPress ).on( "keyup", this._doKeyUp );
		this._autoSize( inst );
		$.data( target, "datepicker", inst );

		//If disabled option is true, disable the datepicker once it has been attached to the input (see ticket #5665)
		if ( inst.settings.disabled ) {
			this._disableDatepicker( target );
		}
	},

	/* Make attachments based on settings. */
	_attachments: function( input, inst ) {
		var showOn, buttonText, buttonImage,
			appendText = this._get( inst, "appendText" ),
			isRTL = this._get( inst, "isRTL" );

		if ( inst.append ) {
			inst.append.remove();
		}
		if ( appendText ) {
			inst.append = $( "<span class='" + this._appendClass + "'>" + appendText + "</span>" );
			input[ isRTL ? "before" : "after" ]( inst.append );
		}

		input.off( "focus", this._showDatepicker );

		if ( inst.trigger ) {
			inst.trigger.remove();
		}

		showOn = this._get( inst, "showOn" );
		if ( showOn === "focus" || showOn === "both" ) { // pop-up date picker when in the marked field
			input.on( "focus", this._showDatepicker );
		}
		if ( showOn === "button" || showOn === "both" ) { // pop-up date picker when button clicked
			buttonText = this._get( inst, "buttonText" );
			buttonImage = this._get( inst, "buttonImage" );
			inst.trigger = $( this._get( inst, "buttonImageOnly" ) ?
				$( "<img/>" ).addClass( this._triggerClass ).
					attr( { src: buttonImage, alt: buttonText, title: buttonText } ) :
				$( "<button type='button'></button>" ).addClass( this._triggerClass ).
					html( !buttonImage ? buttonText : $( "<img/>" ).attr(
					{ src:buttonImage, alt:buttonText, title:buttonText } ) ) );
			input[ isRTL ? "before" : "after" ]( inst.trigger );
			inst.trigger.on( "click", function() {
				if ( $.datepicker._datepickerShowing && $.datepicker._lastInput === input[ 0 ] ) {
					$.datepicker._hideDatepicker();
				} else if ( $.datepicker._datepickerShowing && $.datepicker._lastInput !== input[ 0 ] ) {
					$.datepicker._hideDatepicker();
					$.datepicker._showDatepicker( input[ 0 ] );
				} else {
					$.datepicker._showDatepicker( input[ 0 ] );
				}
				return false;
			} );
		}
	},

	/* Apply the maximum length for the date format. */
	_autoSize: function( inst ) {
		if ( this._get( inst, "autoSize" ) && !inst.inline ) {
			var findMax, max, maxI, i,
				date = new Date( 2009, 12 - 1, 20 ), // Ensure double digits
				dateFormat = this._get( inst, "dateFormat" );

			if ( dateFormat.match( /[DM]/ ) ) {
				findMax = function( names ) {
					max = 0;
					maxI = 0;
					for ( i = 0; i < names.length; i++ ) {
						if ( names[ i ].length > max ) {
							max = names[ i ].length;
							maxI = i;
						}
					}
					return maxI;
				};
				date.setMonth( findMax( this._get( inst, ( dateFormat.match( /MM/ ) ?
					"monthNames" : "monthNamesShort" ) ) ) );
				date.setDate( findMax( this._get( inst, ( dateFormat.match( /DD/ ) ?
					"dayNames" : "dayNamesShort" ) ) ) + 20 - date.getDay() );
			}
			inst.input.attr( "size", this._formatDate( inst, date ).length );
		}
	},

	/* Attach an inline date picker to a div. */
	_inlineDatepicker: function( target, inst ) {
		var divSpan = $( target );
		if ( divSpan.hasClass( this.markerClassName ) ) {
			return;
		}
		divSpan.addClass( this.markerClassName ).append( inst.dpDiv );
		$.data( target, "datepicker", inst );
		this._setDate( inst, this._getDefaultDate( inst ), true );
		this._updateDatepicker( inst );
		this._updateAlternate( inst );

		//If disabled option is true, disable the datepicker before showing it (see ticket #5665)
		if ( inst.settings.disabled ) {
			this._disableDatepicker( target );
		}

		// Set display:block in place of inst.dpDiv.show() which won't work on disconnected elements
		// http://bugs.jqueryui.com/ticket/7552 - A Datepicker created on a detached div has zero height
		inst.dpDiv.css( "display", "block" );
	},

	/* Pop-up the date picker in a "dialog" box.
	 * @param  input element - ignored
	 * @param  date	string or Date - the initial date to display
	 * @param  onSelect  function - the function to call when a date is selected
	 * @param  settings  object - update the dialog date picker instance's settings (anonymous object)
	 * @param  pos int[2] - coordinates for the dialog's position within the screen or
	 *					event - with x/y coordinates or
	 *					leave empty for default (screen centre)
	 * @return the manager object
	 */
	_dialogDatepicker: function( input, date, onSelect, settings, pos ) {
		var id, browserWidth, browserHeight, scrollX, scrollY,
			inst = this._dialogInst; // internal instance

		if ( !inst ) {
			this.uuid += 1;
			id = "dp" + this.uuid;
			this._dialogInput = $( "<input type='text' id='" + id +
				"' style='position: absolute; top: -100px; width: 0px;'/>" );
			this._dialogInput.on( "keydown", this._doKeyDown );
			$( "body" ).append( this._dialogInput );
			inst = this._dialogInst = this._newInst( this._dialogInput, false );
			inst.settings = {};
			$.data( this._dialogInput[ 0 ], "datepicker", inst );
		}
		datepicker_extendRemove( inst.settings, settings || {} );
		date = ( date && date.constructor === Date ? this._formatDate( inst, date ) : date );
		this._dialogInput.val( date );

		this._pos = ( pos ? ( pos.length ? pos : [ pos.pageX, pos.pageY ] ) : null );
		if ( !this._pos ) {
			browserWidth = document.documentElement.clientWidth;
			browserHeight = document.documentElement.clientHeight;
			scrollX = document.documentElement.scrollLeft || document.body.scrollLeft;
			scrollY = document.documentElement.scrollTop || document.body.scrollTop;
			this._pos = // should use actual width/height below
				[ ( browserWidth / 2 ) - 100 + scrollX, ( browserHeight / 2 ) - 150 + scrollY ];
		}

		// Move input on screen for focus, but hidden behind dialog
		this._dialogInput.css( "left", ( this._pos[ 0 ] + 20 ) + "px" ).css( "top", this._pos[ 1 ] + "px" );
		inst.settings.onSelect = onSelect;
		this._inDialog = true;
		this.dpDiv.addClass( this._dialogClass );
		this._showDatepicker( this._dialogInput[ 0 ] );
		if ( $.blockUI ) {
			$.blockUI( this.dpDiv );
		}
		$.data( this._dialogInput[ 0 ], "datepicker", inst );
		return this;
	},

	/* Detach a datepicker from its control.
	 * @param  target	element - the target input field or division or span
	 */
	_destroyDatepicker: function( target ) {
		var nodeName,
			$target = $( target ),
			inst = $.data( target, "datepicker" );

		if ( !$target.hasClass( this.markerClassName ) ) {
			return;
		}

		nodeName = target.nodeName.toLowerCase();
		$.removeData( target, "datepicker" );
		if ( nodeName === "input" ) {
			inst.append.remove();
			inst.trigger.remove();
			$target.removeClass( this.markerClassName ).
				off( "focus", this._showDatepicker ).
				off( "keydown", this._doKeyDown ).
				off( "keypress", this._doKeyPress ).
				off( "keyup", this._doKeyUp );
		} else if ( nodeName === "div" || nodeName === "span" ) {
			$target.removeClass( this.markerClassName ).empty();
		}

		if ( datepicker_instActive === inst ) {
			datepicker_instActive = null;
		}
	},

	/* Enable the date picker to a jQuery selection.
	 * @param  target	element - the target input field or division or span
	 */
	_enableDatepicker: function( target ) {
		var nodeName, inline,
			$target = $( target ),
			inst = $.data( target, "datepicker" );

		if ( !$target.hasClass( this.markerClassName ) ) {
			return;
		}

		nodeName = target.nodeName.toLowerCase();
		if ( nodeName === "input" ) {
			target.disabled = false;
			inst.trigger.filter( "button" ).
				each( function() { this.disabled = false; } ).end().
				filter( "img" ).css( { opacity: "1.0", cursor: "" } );
		} else if ( nodeName === "div" || nodeName === "span" ) {
			inline = $target.children( "." + this._inlineClass );
			inline.children().removeClass( "ui-state-disabled" );
			inline.find( "select.ui-datepicker-month, select.ui-datepicker-year" ).
				prop( "disabled", false );
		}
		this._disabledInputs = $.map( this._disabledInputs,
			function( value ) { return ( value === target ? null : value ); } ); // delete entry
	},

	/* Disable the date picker to a jQuery selection.
	 * @param  target	element - the target input field or division or span
	 */
	_disableDatepicker: function( target ) {
		var nodeName, inline,
			$target = $( target ),
			inst = $.data( target, "datepicker" );

		if ( !$target.hasClass( this.markerClassName ) ) {
			return;
		}

		nodeName = target.nodeName.toLowerCase();
		if ( nodeName === "input" ) {
			target.disabled = true;
			inst.trigger.filter( "button" ).
				each( function() { this.disabled = true; } ).end().
				filter( "img" ).css( { opacity: "0.5", cursor: "default" } );
		} else if ( nodeName === "div" || nodeName === "span" ) {
			inline = $target.children( "." + this._inlineClass );
			inline.children().addClass( "ui-state-disabled" );
			inline.find( "select.ui-datepicker-month, select.ui-datepicker-year" ).
				prop( "disabled", true );
		}
		this._disabledInputs = $.map( this._disabledInputs,
			function( value ) { return ( value === target ? null : value ); } ); // delete entry
		this._disabledInputs[ this._disabledInputs.length ] = target;
	},

	/* Is the first field in a jQuery collection disabled as a datepicker?
	 * @param  target	element - the target input field or division or span
	 * @return boolean - true if disabled, false if enabled
	 */
	_isDisabledDatepicker: function( target ) {
		if ( !target ) {
			return false;
		}
		for ( var i = 0; i < this._disabledInputs.length; i++ ) {
			if ( this._disabledInputs[ i ] === target ) {
				return true;
			}
		}
		return false;
	},

	/* Retrieve the instance data for the target control.
	 * @param  target  element - the target input field or division or span
	 * @return  object - the associated instance data
	 * @throws  error if a jQuery problem getting data
	 */
	_getInst: function( target ) {
		try {
			return $.data( target, "datepicker" );
		}
		catch ( err ) {
			throw "Missing instance data for this datepicker";
		}
	},

	/* Update or retrieve the settings for a date picker attached to an input field or division.
	 * @param  target  element - the target input field or division or span
	 * @param  name	object - the new settings to update or
	 *				string - the name of the setting to change or retrieve,
	 *				when retrieving also "all" for all instance settings or
	 *				"defaults" for all global defaults
	 * @param  value   any - the new value for the setting
	 *				(omit if above is an object or to retrieve a value)
	 */
	_optionDatepicker: function( target, name, value ) {
		var settings, date, minDate, maxDate,
			inst = this._getInst( target );

		if ( arguments.length === 2 && typeof name === "string" ) {
			return ( name === "defaults" ? $.extend( {}, $.datepicker._defaults ) :
				( inst ? ( name === "all" ? $.extend( {}, inst.settings ) :
				this._get( inst, name ) ) : null ) );
		}

		settings = name || {};
		if ( typeof name === "string" ) {
			settings = {};
			settings[ name ] = value;
		}

		if ( inst ) {
			if ( this._curInst === inst ) {
				this._hideDatepicker();
			}

			date = this._getDateDatepicker( target, true );
			minDate = this._getMinMaxDate( inst, "min" );
			maxDate = this._getMinMaxDate( inst, "max" );
			datepicker_extendRemove( inst.settings, settings );

			// reformat the old minDate/maxDate values if dateFormat changes and a new minDate/maxDate isn't provided
			if ( minDate !== null && settings.dateFormat !== undefined && settings.minDate === undefined ) {
				inst.settings.minDate = this._formatDate( inst, minDate );
			}
			if ( maxDate !== null && settings.dateFormat !== undefined && settings.maxDate === undefined ) {
				inst.settings.maxDate = this._formatDate( inst, maxDate );
			}
			if ( "disabled" in settings ) {
				if ( settings.disabled ) {
					this._disableDatepicker( target );
				} else {
					this._enableDatepicker( target );
				}
			}
			this._attachments( $( target ), inst );
			this._autoSize( inst );
			this._setDate( inst, date );
			this._updateAlternate( inst );
			this._updateDatepicker( inst );
		}
	},

	// Change method deprecated
	_changeDatepicker: function( target, name, value ) {
		this._optionDatepicker( target, name, value );
	},

	/* Redraw the date picker attached to an input field or division.
	 * @param  target  element - the target input field or division or span
	 */
	_refreshDatepicker: function( target ) {
		var inst = this._getInst( target );
		if ( inst ) {
			this._updateDatepicker( inst );
		}
	},

	/* Set the dates for a jQuery selection.
	 * @param  target element - the target input field or division or span
	 * @param  date	Date - the new date
	 */
	_setDateDatepicker: function( target, date ) {
		var inst = this._getInst( target );
		if ( inst ) {
			this._setDate( inst, date );
			this._updateDatepicker( inst );
			this._updateAlternate( inst );
		}
	},

	/* Get the date(s) for the first entry in a jQuery selection.
	 * @param  target element - the target input field or division or span
	 * @param  noDefault boolean - true if no default date is to be used
	 * @return Date - the current date
	 */
	_getDateDatepicker: function( target, noDefault ) {
		var inst = this._getInst( target );
		if ( inst && !inst.inline ) {
			this._setDateFromField( inst, noDefault );
		}
		return ( inst ? this._getDate( inst ) : null );
	},

	/* Handle keystrokes. */
	_doKeyDown: function( event ) {
		var onSelect, dateStr, sel,
			inst = $.datepicker._getInst( event.target ),
			handled = true,
			isRTL = inst.dpDiv.is( ".ui-datepicker-rtl" );

		inst._keyEvent = true;
		if ( $.datepicker._datepickerShowing ) {
			switch ( event.keyCode ) {
				case 9: $.datepicker._hideDatepicker();
						handled = false;
						break; // hide on tab out
				case 13: sel = $( "td." + $.datepicker._dayOverClass + ":not(." +
									$.datepicker._currentClass + ")", inst.dpDiv );
						if ( sel[ 0 ] ) {
							$.datepicker._selectDay( event.target, inst.selectedMonth, inst.selectedYear, sel[ 0 ] );
						}

						onSelect = $.datepicker._get( inst, "onSelect" );
						if ( onSelect ) {
							dateStr = $.datepicker._formatDate( inst );

							// Trigger custom callback
							onSelect.apply( ( inst.input ? inst.input[ 0 ] : null ), [ dateStr, inst ] );
						} else {
							$.datepicker._hideDatepicker();
						}

						return false; // don't submit the form
				case 27: $.datepicker._hideDatepicker();
						break; // hide on escape
				case 33: $.datepicker._adjustDate( event.target, ( event.ctrlKey ?
							-$.datepicker._get( inst, "stepBigMonths" ) :
							-$.datepicker._get( inst, "stepMonths" ) ), "M" );
						break; // previous month/year on page up/+ ctrl
				case 34: $.datepicker._adjustDate( event.target, ( event.ctrlKey ?
							+$.datepicker._get( inst, "stepBigMonths" ) :
							+$.datepicker._get( inst, "stepMonths" ) ), "M" );
						break; // next month/year on page down/+ ctrl
				case 35: if ( event.ctrlKey || event.metaKey ) {
							$.datepicker._clearDate( event.target );
						}
						handled = event.ctrlKey || event.metaKey;
						break; // clear on ctrl or command +end
				case 36: if ( event.ctrlKey || event.metaKey ) {
							$.datepicker._gotoToday( event.target );
						}
						handled = event.ctrlKey || event.metaKey;
						break; // current on ctrl or command +home
				case 37: if ( event.ctrlKey || event.metaKey ) {
							$.datepicker._adjustDate( event.target, ( isRTL ? +1 : -1 ), "D" );
						}
						handled = event.ctrlKey || event.metaKey;

						// -1 day on ctrl or command +left
						if ( event.originalEvent.altKey ) {
							$.datepicker._adjustDate( event.target, ( event.ctrlKey ?
								-$.datepicker._get( inst, "stepBigMonths" ) :
								-$.datepicker._get( inst, "stepMonths" ) ), "M" );
						}

						// next month/year on alt +left on Mac
						break;
				case 38: if ( event.ctrlKey || event.metaKey ) {
							$.datepicker._adjustDate( event.target, -7, "D" );
						}
						handled = event.ctrlKey || event.metaKey;
						break; // -1 week on ctrl or command +up
				case 39: if ( event.ctrlKey || event.metaKey ) {
							$.datepicker._adjustDate( event.target, ( isRTL ? -1 : +1 ), "D" );
						}
						handled = event.ctrlKey || event.metaKey;

						// +1 day on ctrl or command +right
						if ( event.originalEvent.altKey ) {
							$.datepicker._adjustDate( event.target, ( event.ctrlKey ?
								+$.datepicker._get( inst, "stepBigMonths" ) :
								+$.datepicker._get( inst, "stepMonths" ) ), "M" );
						}

						// next month/year on alt +right
						break;
				case 40: if ( event.ctrlKey || event.metaKey ) {
							$.datepicker._adjustDate( event.target, +7, "D" );
						}
						handled = event.ctrlKey || event.metaKey;
						break; // +1 week on ctrl or command +down
				default: handled = false;
			}
		} else if ( event.keyCode === 36 && event.ctrlKey ) { // display the date picker on ctrl+home
			$.datepicker._showDatepicker( this );
		} else {
			handled = false;
		}

		if ( handled ) {
			event.preventDefault();
			event.stopPropagation();
		}
	},

	/* Filter entered characters - based on date format. */
	_doKeyPress: function( event ) {
		var chars, chr,
			inst = $.datepicker._getInst( event.target );

		if ( $.datepicker._get( inst, "constrainInput" ) ) {
			chars = $.datepicker._possibleChars( $.datepicker._get( inst, "dateFormat" ) );
			chr = String.fromCharCode( event.charCode == null ? event.keyCode : event.charCode );
			return event.ctrlKey || event.metaKey || ( chr < " " || !chars || chars.indexOf( chr ) > -1 );
		}
	},

	/* Synchronise manual entry and field/alternate field. */
	_doKeyUp: function( event ) {
		var date,
			inst = $.datepicker._getInst( event.target );

		if ( inst.input.val() !== inst.lastVal ) {
			try {
				date = $.datepicker.parseDate( $.datepicker._get( inst, "dateFormat" ),
					( inst.input ? inst.input.val() : null ),
					$.datepicker._getFormatConfig( inst ) );

				if ( date ) { // only if valid
					$.datepicker._setDateFromField( inst );
					$.datepicker._updateAlternate( inst );
					$.datepicker._updateDatepicker( inst );
				}
			}
			catch ( err ) {
			}
		}
		return true;
	},

	/* Pop-up the date picker for a given input field.
	 * If false returned from beforeShow event handler do not show.
	 * @param  input  element - the input field attached to the date picker or
	 *					event - if triggered by focus
	 */
	_showDatepicker: function( input ) {
		input = input.target || input;
		if ( input.nodeName.toLowerCase() !== "input" ) { // find from button/image trigger
			input = $( "input", input.parentNode )[ 0 ];
		}

		if ( $.datepicker._isDisabledDatepicker( input ) || $.datepicker._lastInput === input ) { // already here
			return;
		}

		var inst, beforeShow, beforeShowSettings, isFixed,
			offset, showAnim, duration;

		inst = $.datepicker._getInst( input );
		if ( $.datepicker._curInst && $.datepicker._curInst !== inst ) {
			$.datepicker._curInst.dpDiv.stop( true, true );
			if ( inst && $.datepicker._datepickerShowing ) {
				$.datepicker._hideDatepicker( $.datepicker._curInst.input[ 0 ] );
			}
		}

		beforeShow = $.datepicker._get( inst, "beforeShow" );
		beforeShowSettings = beforeShow ? beforeShow.apply( input, [ input, inst ] ) : {};
		if ( beforeShowSettings === false ) {
			return;
		}
		datepicker_extendRemove( inst.settings, beforeShowSettings );

		inst.lastVal = null;
		$.datepicker._lastInput = input;
		$.datepicker._setDateFromField( inst );

		if ( $.datepicker._inDialog ) { // hide cursor
			input.value = "";
		}
		if ( !$.datepicker._pos ) { // position below input
			$.datepicker._pos = $.datepicker._findPos( input );
			$.datepicker._pos[ 1 ] += input.offsetHeight; // add the height
		}

		isFixed = false;
		$( input ).parents().each( function() {
			isFixed |= $( this ).css( "position" ) === "fixed";
			return !isFixed;
		} );

		offset = { left: $.datepicker._pos[ 0 ], top: $.datepicker._pos[ 1 ] };
		$.datepicker._pos = null;

		//to avoid flashes on Firefox
		inst.dpDiv.empty();

		// determine sizing offscreen
		inst.dpDiv.css( { position: "absolute", display: "block", top: "-1000px" } );
		$.datepicker._updateDatepicker( inst );

		// fix width for dynamic number of date pickers
		// and adjust position before showing
		offset = $.datepicker._checkOffset( inst, offset, isFixed );
		inst.dpDiv.css( { position: ( $.datepicker._inDialog && $.blockUI ?
			"static" : ( isFixed ? "fixed" : "absolute" ) ), display: "none",
			left: offset.left + "px", top: offset.top + "px" } );

		if ( !inst.inline ) {
			showAnim = $.datepicker._get( inst, "showAnim" );
			duration = $.datepicker._get( inst, "duration" );
			inst.dpDiv.css( "z-index", datepicker_getZindex( $( input ) ) + 1 );
			$.datepicker._datepickerShowing = true;

			if ( $.effects && $.effects.effect[ showAnim ] ) {
				inst.dpDiv.show( showAnim, $.datepicker._get( inst, "showOptions" ), duration );
			} else {
				inst.dpDiv[ showAnim || "show" ]( showAnim ? duration : null );
			}

			if ( $.datepicker._shouldFocusInput( inst ) ) {
				inst.input.trigger( "focus" );
			}

			$.datepicker._curInst = inst;
		}
	},

	/* Generate the date picker content. */
	_updateDatepicker: function( inst ) {
		this.maxRows = 4; //Reset the max number of rows being displayed (see #7043)
		datepicker_instActive = inst; // for delegate hover events
		inst.dpDiv.empty().append( this._generateHTML( inst ) );
		this._attachHandlers( inst );

		var origyearshtml,
			numMonths = this._getNumberOfMonths( inst ),
			cols = numMonths[ 1 ],
			width = 17,
			activeCell = inst.dpDiv.find( "." + this._dayOverClass + " a" );

		if ( activeCell.length > 0 ) {
			datepicker_handleMouseover.apply( activeCell.get( 0 ) );
		}

		inst.dpDiv.removeClass( "ui-datepicker-multi-2 ui-datepicker-multi-3 ui-datepicker-multi-4" ).width( "" );
		if ( cols > 1 ) {
			inst.dpDiv.addClass( "ui-datepicker-multi-" + cols ).css( "width", ( width * cols ) + "em" );
		}
		inst.dpDiv[ ( numMonths[ 0 ] !== 1 || numMonths[ 1 ] !== 1 ? "add" : "remove" ) +
			"Class" ]( "ui-datepicker-multi" );
		inst.dpDiv[ ( this._get( inst, "isRTL" ) ? "add" : "remove" ) +
			"Class" ]( "ui-datepicker-rtl" );

		if ( inst === $.datepicker._curInst && $.datepicker._datepickerShowing && $.datepicker._shouldFocusInput( inst ) ) {
			inst.input.trigger( "focus" );
		}

		// Deffered render of the years select (to avoid flashes on Firefox)
		if ( inst.yearshtml ) {
			origyearshtml = inst.yearshtml;
			setTimeout( function() {

				//assure that inst.yearshtml didn't change.
				if ( origyearshtml === inst.yearshtml && inst.yearshtml ) {
					inst.dpDiv.find( "select.ui-datepicker-year:first" ).replaceWith( inst.yearshtml );
				}
				origyearshtml = inst.yearshtml = null;
			}, 0 );
		}
	},

	// #6694 - don't focus the input if it's already focused
	// this breaks the change event in IE
	// Support: IE and jQuery <1.9
	_shouldFocusInput: function( inst ) {
		return inst.input && inst.input.is( ":visible" ) && !inst.input.is( ":disabled" ) && !inst.input.is( ":focus" );
	},

	/* Check positioning to remain on screen. */
	_checkOffset: function( inst, offset, isFixed ) {
		var dpWidth = inst.dpDiv.outerWidth(),
			dpHeight = inst.dpDiv.outerHeight(),
			inputWidth = inst.input ? inst.input.outerWidth() : 0,
			inputHeight = inst.input ? inst.input.outerHeight() : 0,
			viewWidth = document.documentElement.clientWidth + ( isFixed ? 0 : $( document ).scrollLeft() ),
			viewHeight = document.documentElement.clientHeight + ( isFixed ? 0 : $( document ).scrollTop() );

		offset.left -= ( this._get( inst, "isRTL" ) ? ( dpWidth - inputWidth ) : 0 );
		offset.left -= ( isFixed && offset.left === inst.input.offset().left ) ? $( document ).scrollLeft() : 0;
		offset.top -= ( isFixed && offset.top === ( inst.input.offset().top + inputHeight ) ) ? $( document ).scrollTop() : 0;

		// Now check if datepicker is showing outside window viewport - move to a better place if so.
		offset.left -= Math.min( offset.left, ( offset.left + dpWidth > viewWidth && viewWidth > dpWidth ) ?
			Math.abs( offset.left + dpWidth - viewWidth ) : 0 );
		offset.top -= Math.min( offset.top, ( offset.top + dpHeight > viewHeight && viewHeight > dpHeight ) ?
			Math.abs( dpHeight + inputHeight ) : 0 );

		return offset;
	},

	/* Find an object's position on the screen. */
	_findPos: function( obj ) {
		var position,
			inst = this._getInst( obj ),
			isRTL = this._get( inst, "isRTL" );

		while ( obj && ( obj.type === "hidden" || obj.nodeType !== 1 || $.expr.filters.hidden( obj ) ) ) {
			obj = obj[ isRTL ? "previousSibling" : "nextSibling" ];
		}

		position = $( obj ).offset();
		return [ position.left, position.top ];
	},

	/* Hide the date picker from view.
	 * @param  input  element - the input field attached to the date picker
	 */
	_hideDatepicker: function( input ) {
		var showAnim, duration, postProcess, onClose,
			inst = this._curInst;

		if ( !inst || ( input && inst !== $.data( input, "datepicker" ) ) ) {
			return;
		}

		if ( this._datepickerShowing ) {
			showAnim = this._get( inst, "showAnim" );
			duration = this._get( inst, "duration" );
			postProcess = function() {
				$.datepicker._tidyDialog( inst );
			};

			// DEPRECATED: after BC for 1.8.x $.effects[ showAnim ] is not needed
			if ( $.effects && ( $.effects.effect[ showAnim ] || $.effects[ showAnim ] ) ) {
				inst.dpDiv.hide( showAnim, $.datepicker._get( inst, "showOptions" ), duration, postProcess );
			} else {
				inst.dpDiv[ ( showAnim === "slideDown" ? "slideUp" :
					( showAnim === "fadeIn" ? "fadeOut" : "hide" ) ) ]( ( showAnim ? duration : null ), postProcess );
			}

			if ( !showAnim ) {
				postProcess();
			}
			this._datepickerShowing = false;

			onClose = this._get( inst, "onClose" );
			if ( onClose ) {
				onClose.apply( ( inst.input ? inst.input[ 0 ] : null ), [ ( inst.input ? inst.input.val() : "" ), inst ] );
			}

			this._lastInput = null;
			if ( this._inDialog ) {
				this._dialogInput.css( { position: "absolute", left: "0", top: "-100px" } );
				if ( $.blockUI ) {
					$.unblockUI();
					$( "body" ).append( this.dpDiv );
				}
			}
			this._inDialog = false;
		}
	},

	/* Tidy up after a dialog display. */
	_tidyDialog: function( inst ) {
		inst.dpDiv.removeClass( this._dialogClass ).off( ".ui-datepicker-calendar" );
	},

	/* Close date picker if clicked elsewhere. */
	_checkExternalClick: function( event ) {
		if ( !$.datepicker._curInst ) {
			return;
		}

		var $target = $( event.target ),
			inst = $.datepicker._getInst( $target[ 0 ] );

		if ( ( ( $target[ 0 ].id !== $.datepicker._mainDivId &&
				$target.parents( "#" + $.datepicker._mainDivId ).length === 0 &&
				!$target.hasClass( $.datepicker.markerClassName ) &&
				!$target.closest( "." + $.datepicker._triggerClass ).length &&
				$.datepicker._datepickerShowing && !( $.datepicker._inDialog && $.blockUI ) ) ) ||
			( $target.hasClass( $.datepicker.markerClassName ) && $.datepicker._curInst !== inst ) ) {
				$.datepicker._hideDatepicker();
		}
	},

	/* Adjust one of the date sub-fields. */
	_adjustDate: function( id, offset, period ) {
		var target = $( id ),
			inst = this._getInst( target[ 0 ] );

		if ( this._isDisabledDatepicker( target[ 0 ] ) ) {
			return;
		}
		this._adjustInstDate( inst, offset +
			( period === "M" ? this._get( inst, "showCurrentAtPos" ) : 0 ), // undo positioning
			period );
		this._updateDatepicker( inst );
	},

	/* Action for current link. */
	_gotoToday: function( id ) {
		var date,
			target = $( id ),
			inst = this._getInst( target[ 0 ] );

		if ( this._get( inst, "gotoCurrent" ) && inst.currentDay ) {
			inst.selectedDay = inst.currentDay;
			inst.drawMonth = inst.selectedMonth = inst.currentMonth;
			inst.drawYear = inst.selectedYear = inst.currentYear;
		} else {
			date = new Date();
			inst.selectedDay = date.getDate();
			inst.drawMonth = inst.selectedMonth = date.getMonth();
			inst.drawYear = inst.selectedYear = date.getFullYear();
		}
		this._notifyChange( inst );
		this._adjustDate( target );
	},

	/* Action for selecting a new month/year. */
	_selectMonthYear: function( id, select, period ) {
		var target = $( id ),
			inst = this._getInst( target[ 0 ] );

		inst[ "selected" + ( period === "M" ? "Month" : "Year" ) ] =
		inst[ "draw" + ( period === "M" ? "Month" : "Year" ) ] =
			parseInt( select.options[ select.selectedIndex ].value, 10 );

		this._notifyChange( inst );
		this._adjustDate( target );
	},

	/* Action for selecting a day. */
	_selectDay: function( id, month, year, td ) {
		var inst,
			target = $( id );

		if ( $( td ).hasClass( this._unselectableClass ) || this._isDisabledDatepicker( target[ 0 ] ) ) {
			return;
		}

		inst = this._getInst( target[ 0 ] );
		inst.selectedDay = inst.currentDay = $( "a", td ).html();
		inst.selectedMonth = inst.currentMonth = month;
		inst.selectedYear = inst.currentYear = year;
		this._selectDate( id, this._formatDate( inst,
			inst.currentDay, inst.currentMonth, inst.currentYear ) );
	},

	/* Erase the input field and hide the date picker. */
	_clearDate: function( id ) {
		var target = $( id );
		this._selectDate( target, "" );
	},

	/* Update the input field with the selected date. */
	_selectDate: function( id, dateStr ) {
		var onSelect,
			target = $( id ),
			inst = this._getInst( target[ 0 ] );

		dateStr = ( dateStr != null ? dateStr : this._formatDate( inst ) );
		if ( inst.input ) {
			inst.input.val( dateStr );
		}
		this._updateAlternate( inst );

		onSelect = this._get( inst, "onSelect" );
		if ( onSelect ) {
			onSelect.apply( ( inst.input ? inst.input[ 0 ] : null ), [ dateStr, inst ] );  // trigger custom callback
		} else if ( inst.input ) {
			inst.input.trigger( "change" ); // fire the change event
		}

		if ( inst.inline ) {
			this._updateDatepicker( inst );
		} else {
			this._hideDatepicker();
			this._lastInput = inst.input[ 0 ];
			if ( typeof( inst.input[ 0 ] ) !== "object" ) {
				inst.input.trigger( "focus" ); // restore focus
			}
			this._lastInput = null;
		}
	},

	/* Update any alternate field to synchronise with the main field. */
	_updateAlternate: function( inst ) {
		var altFormat, date, dateStr,
			altField = this._get( inst, "altField" );

		if ( altField ) { // update alternate field too
			altFormat = this._get( inst, "altFormat" ) || this._get( inst, "dateFormat" );
			date = this._getDate( inst );
			dateStr = this.formatDate( altFormat, date, this._getFormatConfig( inst ) );
			$( altField ).val( dateStr );
		}
	},

	/* Set as beforeShowDay function to prevent selection of weekends.
	 * @param  date  Date - the date to customise
	 * @return [boolean, string] - is this date selectable?, what is its CSS class?
	 */
	noWeekends: function( date ) {
		var day = date.getDay();
		return [ ( day > 0 && day < 6 ), "" ];
	},

	/* Set as calculateWeek to determine the week of the year based on the ISO 8601 definition.
	 * @param  date  Date - the date to get the week for
	 * @return  number - the number of the week within the year that contains this date
	 */
	iso8601Week: function( date ) {
		var time,
			checkDate = new Date( date.getTime() );

		// Find Thursday of this week starting on Monday
		checkDate.setDate( checkDate.getDate() + 4 - ( checkDate.getDay() || 7 ) );

		time = checkDate.getTime();
		checkDate.setMonth( 0 ); // Compare with Jan 1
		checkDate.setDate( 1 );
		return Math.floor( Math.round( ( time - checkDate ) / 86400000 ) / 7 ) + 1;
	},

	/* Parse a string value into a date object.
	 * See formatDate below for the possible formats.
	 *
	 * @param  format string - the expected format of the date
	 * @param  value string - the date in the above format
	 * @param  settings Object - attributes include:
	 *					shortYearCutoff  number - the cutoff year for determining the century (optional)
	 *					dayNamesShort	string[7] - abbreviated names of the days from Sunday (optional)
	 *					dayNames		string[7] - names of the days from Sunday (optional)
	 *					monthNamesShort string[12] - abbreviated names of the months (optional)
	 *					monthNames		string[12] - names of the months (optional)
	 * @return  Date - the extracted date value or null if value is blank
	 */
	parseDate: function( format, value, settings ) {
		if ( format == null || value == null ) {
			throw "Invalid arguments";
		}

		value = ( typeof value === "object" ? value.toString() : value + "" );
		if ( value === "" ) {
			return null;
		}

		var iFormat, dim, extra,
			iValue = 0,
			shortYearCutoffTemp = ( settings ? settings.shortYearCutoff : null ) || this._defaults.shortYearCutoff,
			shortYearCutoff = ( typeof shortYearCutoffTemp !== "string" ? shortYearCutoffTemp :
				new Date().getFullYear() % 100 + parseInt( shortYearCutoffTemp, 10 ) ),
			dayNamesShort = ( settings ? settings.dayNamesShort : null ) || this._defaults.dayNamesShort,
			dayNames = ( settings ? settings.dayNames : null ) || this._defaults.dayNames,
			monthNamesShort = ( settings ? settings.monthNamesShort : null ) || this._defaults.monthNamesShort,
			monthNames = ( settings ? settings.monthNames : null ) || this._defaults.monthNames,
			year = -1,
			month = -1,
			day = -1,
			doy = -1,
			literal = false,
			date,

			// Check whether a format character is doubled
			lookAhead = function( match ) {
				var matches = ( iFormat + 1 < format.length && format.charAt( iFormat + 1 ) === match );
				if ( matches ) {
					iFormat++;
				}
				return matches;
			},

			// Extract a number from the string value
			getNumber = function( match ) {
				var isDoubled = lookAhead( match ),
					size = ( match === "@" ? 14 : ( match === "!" ? 20 :
					( match === "y" && isDoubled ? 4 : ( match === "o" ? 3 : 2 ) ) ) ),
					minSize = ( match === "y" ? size : 1 ),
					digits = new RegExp( "^\\d{" + minSize + "," + size + "}" ),
					num = value.substring( iValue ).match( digits );
				if ( !num ) {
					throw "Missing number at position " + iValue;
				}
				iValue += num[ 0 ].length;
				return parseInt( num[ 0 ], 10 );
			},

			// Extract a name from the string value and convert to an index
			getName = function( match, shortNames, longNames ) {
				var index = -1,
					names = $.map( lookAhead( match ) ? longNames : shortNames, function( v, k ) {
						return [ [ k, v ] ];
					} ).sort( function( a, b ) {
						return -( a[ 1 ].length - b[ 1 ].length );
					} );

				$.each( names, function( i, pair ) {
					var name = pair[ 1 ];
					if ( value.substr( iValue, name.length ).toLowerCase() === name.toLowerCase() ) {
						index = pair[ 0 ];
						iValue += name.length;
						return false;
					}
				} );
				if ( index !== -1 ) {
					return index + 1;
				} else {
					throw "Unknown name at position " + iValue;
				}
			},

			// Confirm that a literal character matches the string value
			checkLiteral = function() {
				if ( value.charAt( iValue ) !== format.charAt( iFormat ) ) {
					throw "Unexpected literal at position " + iValue;
				}
				iValue++;
			};

		for ( iFormat = 0; iFormat < format.length; iFormat++ ) {
			if ( literal ) {
				if ( format.charAt( iFormat ) === "'" && !lookAhead( "'" ) ) {
					literal = false;
				} else {
					checkLiteral();
				}
			} else {
				switch ( format.charAt( iFormat ) ) {
					case "d":
						day = getNumber( "d" );
						break;
					case "D":
						getName( "D", dayNamesShort, dayNames );
						break;
					case "o":
						doy = getNumber( "o" );
						break;
					case "m":
						month = getNumber( "m" );
						break;
					case "M":
						month = getName( "M", monthNamesShort, monthNames );
						break;
					case "y":
						year = getNumber( "y" );
						break;
					case "@":
						date = new Date( getNumber( "@" ) );
						year = date.getFullYear();
						month = date.getMonth() + 1;
						day = date.getDate();
						break;
					case "!":
						date = new Date( ( getNumber( "!" ) - this._ticksTo1970 ) / 10000 );
						year = date.getFullYear();
						month = date.getMonth() + 1;
						day = date.getDate();
						break;
					case "'":
						if ( lookAhead( "'" ) ) {
							checkLiteral();
						} else {
							literal = true;
						}
						break;
					default:
						checkLiteral();
				}
			}
		}

		if ( iValue < value.length ) {
			extra = value.substr( iValue );
			if ( !/^\s+/.test( extra ) ) {
				throw "Extra/unparsed characters found in date: " + extra;
			}
		}

		if ( year === -1 ) {
			year = new Date().getFullYear();
		} else if ( year < 100 ) {
			year += new Date().getFullYear() - new Date().getFullYear() % 100 +
				( year <= shortYearCutoff ? 0 : -100 );
		}

		if ( doy > -1 ) {
			month = 1;
			day = doy;
			do {
				dim = this._getDaysInMonth( year, month - 1 );
				if ( day <= dim ) {
					break;
				}
				month++;
				day -= dim;
			} while ( true );
		}

		date = this._daylightSavingAdjust( new Date( year, month - 1, day ) );
		if ( date.getFullYear() !== year || date.getMonth() + 1 !== month || date.getDate() !== day ) {
			throw "Invalid date"; // E.g. 31/02/00
		}
		return date;
	},

	/* Standard date formats. */
	ATOM: "yy-mm-dd", // RFC 3339 (ISO 8601)
	COOKIE: "D, dd M yy",
	ISO_8601: "yy-mm-dd",
	RFC_822: "D, d M y",
	RFC_850: "DD, dd-M-y",
	RFC_1036: "D, d M y",
	RFC_1123: "D, d M yy",
	RFC_2822: "D, d M yy",
	RSS: "D, d M y", // RFC 822
	TICKS: "!",
	TIMESTAMP: "@",
	W3C: "yy-mm-dd", // ISO 8601

	_ticksTo1970: ( ( ( 1970 - 1 ) * 365 + Math.floor( 1970 / 4 ) - Math.floor( 1970 / 100 ) +
		Math.floor( 1970 / 400 ) ) * 24 * 60 * 60 * 10000000 ),

	/* Format a date object into a string value.
	 * The format can be combinations of the following:
	 * d  - day of month (no leading zero)
	 * dd - day of month (two digit)
	 * o  - day of year (no leading zeros)
	 * oo - day of year (three digit)
	 * D  - day name short
	 * DD - day name long
	 * m  - month of year (no leading zero)
	 * mm - month of year (two digit)
	 * M  - month name short
	 * MM - month name long
	 * y  - year (two digit)
	 * yy - year (four digit)
	 * @ - Unix timestamp (ms since 01/01/1970)
	 * ! - Windows ticks (100ns since 01/01/0001)
	 * "..." - literal text
	 * '' - single quote
	 *
	 * @param  format string - the desired format of the date
	 * @param  date Date - the date value to format
	 * @param  settings Object - attributes include:
	 *					dayNamesShort	string[7] - abbreviated names of the days from Sunday (optional)
	 *					dayNames		string[7] - names of the days from Sunday (optional)
	 *					monthNamesShort string[12] - abbreviated names of the months (optional)
	 *					monthNames		string[12] - names of the months (optional)
	 * @return  string - the date in the above format
	 */
	formatDate: function( format, date, settings ) {
		if ( !date ) {
			return "";
		}

		var iFormat,
			dayNamesShort = ( settings ? settings.dayNamesShort : null ) || this._defaults.dayNamesShort,
			dayNames = ( settings ? settings.dayNames : null ) || this._defaults.dayNames,
			monthNamesShort = ( settings ? settings.monthNamesShort : null ) || this._defaults.monthNamesShort,
			monthNames = ( settings ? settings.monthNames : null ) || this._defaults.monthNames,

			// Check whether a format character is doubled
			lookAhead = function( match ) {
				var matches = ( iFormat + 1 < format.length && format.charAt( iFormat + 1 ) === match );
				if ( matches ) {
					iFormat++;
				}
				return matches;
			},

			// Format a number, with leading zero if necessary
			formatNumber = function( match, value, len ) {
				var num = "" + value;
				if ( lookAhead( match ) ) {
					while ( num.length < len ) {
						num = "0" + num;
					}
				}
				return num;
			},

			// Format a name, short or long as requested
			formatName = function( match, value, shortNames, longNames ) {
				return ( lookAhead( match ) ? longNames[ value ] : shortNames[ value ] );
			},
			output = "",
			literal = false;

		if ( date ) {
			for ( iFormat = 0; iFormat < format.length; iFormat++ ) {
				if ( literal ) {
					if ( format.charAt( iFormat ) === "'" && !lookAhead( "'" ) ) {
						literal = false;
					} else {
						output += format.charAt( iFormat );
					}
				} else {
					switch ( format.charAt( iFormat ) ) {
						case "d":
							output += formatNumber( "d", date.getDate(), 2 );
							break;
						case "D":
							output += formatName( "D", date.getDay(), dayNamesShort, dayNames );
							break;
						case "o":
							output += formatNumber( "o",
								Math.round( ( new Date( date.getFullYear(), date.getMonth(), date.getDate() ).getTime() - new Date( date.getFullYear(), 0, 0 ).getTime() ) / 86400000 ), 3 );
							break;
						case "m":
							output += formatNumber( "m", date.getMonth() + 1, 2 );
							break;
						case "M":
							output += formatName( "M", date.getMonth(), monthNamesShort, monthNames );
							break;
						case "y":
							output += ( lookAhead( "y" ) ? date.getFullYear() :
								( date.getFullYear() % 100 < 10 ? "0" : "" ) + date.getFullYear() % 100 );
							break;
						case "@":
							output += date.getTime();
							break;
						case "!":
							output += date.getTime() * 10000 + this._ticksTo1970;
							break;
						case "'":
							if ( lookAhead( "'" ) ) {
								output += "'";
							} else {
								literal = true;
							}
							break;
						default:
							output += format.charAt( iFormat );
					}
				}
			}
		}
		return output;
	},

	/* Extract all possible characters from the date format. */
	_possibleChars: function( format ) {
		var iFormat,
			chars = "",
			literal = false,

			// Check whether a format character is doubled
			lookAhead = function( match ) {
				var matches = ( iFormat + 1 < format.length && format.charAt( iFormat + 1 ) === match );
				if ( matches ) {
					iFormat++;
				}
				return matches;
			};

		for ( iFormat = 0; iFormat < format.length; iFormat++ ) {
			if ( literal ) {
				if ( format.charAt( iFormat ) === "'" && !lookAhead( "'" ) ) {
					literal = false;
				} else {
					chars += format.charAt( iFormat );
				}
			} else {
				switch ( format.charAt( iFormat ) ) {
					case "d": case "m": case "y": case "@":
						chars += "0123456789";
						break;
					case "D": case "M":
						return null; // Accept anything
					case "'":
						if ( lookAhead( "'" ) ) {
							chars += "'";
						} else {
							literal = true;
						}
						break;
					default:
						chars += format.charAt( iFormat );
				}
			}
		}
		return chars;
	},

	/* Get a setting value, defaulting if necessary. */
	_get: function( inst, name ) {
		return inst.settings[ name ] !== undefined ?
			inst.settings[ name ] : this._defaults[ name ];
	},

	/* Parse existing date and initialise date picker. */
	_setDateFromField: function( inst, noDefault ) {
		if ( inst.input.val() === inst.lastVal ) {
			return;
		}

		var dateFormat = this._get( inst, "dateFormat" ),
			dates = inst.lastVal = inst.input ? inst.input.val() : null,
			defaultDate = this._getDefaultDate( inst ),
			date = defaultDate,
			settings = this._getFormatConfig( inst );

		try {
			date = this.parseDate( dateFormat, dates, settings ) || defaultDate;
		} catch ( event ) {
			dates = ( noDefault ? "" : dates );
		}
		inst.selectedDay = date.getDate();
		inst.drawMonth = inst.selectedMonth = date.getMonth();
		inst.drawYear = inst.selectedYear = date.getFullYear();
		inst.currentDay = ( dates ? date.getDate() : 0 );
		inst.currentMonth = ( dates ? date.getMonth() : 0 );
		inst.currentYear = ( dates ? date.getFullYear() : 0 );
		this._adjustInstDate( inst );
	},

	/* Retrieve the default date shown on opening. */
	_getDefaultDate: function( inst ) {
		return this._restrictMinMax( inst,
			this._determineDate( inst, this._get( inst, "defaultDate" ), new Date() ) );
	},

	/* A date may be specified as an exact value or a relative one. */
	_determineDate: function( inst, date, defaultDate ) {
		var offsetNumeric = function( offset ) {
				var date = new Date();
				date.setDate( date.getDate() + offset );
				return date;
			},
			offsetString = function( offset ) {
				try {
					return $.datepicker.parseDate( $.datepicker._get( inst, "dateFormat" ),
						offset, $.datepicker._getFormatConfig( inst ) );
				}
				catch ( e ) {

					// Ignore
				}

				var date = ( offset.toLowerCase().match( /^c/ ) ?
					$.datepicker._getDate( inst ) : null ) || new Date(),
					year = date.getFullYear(),
					month = date.getMonth(),
					day = date.getDate(),
					pattern = /([+\-]?[0-9]+)\s*(d|D|w|W|m|M|y|Y)?/g,
					matches = pattern.exec( offset );

				while ( matches ) {
					switch ( matches[ 2 ] || "d" ) {
						case "d" : case "D" :
							day += parseInt( matches[ 1 ], 10 ); break;
						case "w" : case "W" :
							day += parseInt( matches[ 1 ], 10 ) * 7; break;
						case "m" : case "M" :
							month += parseInt( matches[ 1 ], 10 );
							day = Math.min( day, $.datepicker._getDaysInMonth( year, month ) );
							break;
						case "y": case "Y" :
							year += parseInt( matches[ 1 ], 10 );
							day = Math.min( day, $.datepicker._getDaysInMonth( year, month ) );
							break;
					}
					matches = pattern.exec( offset );
				}
				return new Date( year, month, day );
			},
			newDate = ( date == null || date === "" ? defaultDate : ( typeof date === "string" ? offsetString( date ) :
				( typeof date === "number" ? ( isNaN( date ) ? defaultDate : offsetNumeric( date ) ) : new Date( date.getTime() ) ) ) );

		newDate = ( newDate && newDate.toString() === "Invalid Date" ? defaultDate : newDate );
		if ( newDate ) {
			newDate.setHours( 0 );
			newDate.setMinutes( 0 );
			newDate.setSeconds( 0 );
			newDate.setMilliseconds( 0 );
		}
		return this._daylightSavingAdjust( newDate );
	},

	/* Handle switch to/from daylight saving.
	 * Hours may be non-zero on daylight saving cut-over:
	 * > 12 when midnight changeover, but then cannot generate
	 * midnight datetime, so jump to 1AM, otherwise reset.
	 * @param  date  (Date) the date to check
	 * @return  (Date) the corrected date
	 */
	_daylightSavingAdjust: function( date ) {
		if ( !date ) {
			return null;
		}
		date.setHours( date.getHours() > 12 ? date.getHours() + 2 : 0 );
		return date;
	},

	/* Set the date(s) directly. */
	_setDate: function( inst, date, noChange ) {
		var clear = !date,
			origMonth = inst.selectedMonth,
			origYear = inst.selectedYear,
			newDate = this._restrictMinMax( inst, this._determineDate( inst, date, new Date() ) );

		inst.selectedDay = inst.currentDay = newDate.getDate();
		inst.drawMonth = inst.selectedMonth = inst.currentMonth = newDate.getMonth();
		inst.drawYear = inst.selectedYear = inst.currentYear = newDate.getFullYear();
		if ( ( origMonth !== inst.selectedMonth || origYear !== inst.selectedYear ) && !noChange ) {
			this._notifyChange( inst );
		}
		this._adjustInstDate( inst );
		if ( inst.input ) {
			inst.input.val( clear ? "" : this._formatDate( inst ) );
		}
	},

	/* Retrieve the date(s) directly. */
	_getDate: function( inst ) {
		var startDate = ( !inst.currentYear || ( inst.input && inst.input.val() === "" ) ? null :
			this._daylightSavingAdjust( new Date(
			inst.currentYear, inst.currentMonth, inst.currentDay ) ) );
			return startDate;
	},

	/* Attach the onxxx handlers.  These are declared statically so
	 * they work with static code transformers like Caja.
	 */
	_attachHandlers: function( inst ) {
		var stepMonths = this._get( inst, "stepMonths" ),
			id = "#" + inst.id.replace( /\\\\/g, "\\" );
		inst.dpDiv.find( "[data-handler]" ).map( function() {
			var handler = {
				prev: function() {
					$.datepicker._adjustDate( id, -stepMonths, "M" );
				},
				next: function() {
					$.datepicker._adjustDate( id, +stepMonths, "M" );
				},
				hide: function() {
					$.datepicker._hideDatepicker();
				},
				today: function() {
					$.datepicker._gotoToday( id );
				},
				selectDay: function() {
					$.datepicker._selectDay( id, +this.getAttribute( "data-month" ), +this.getAttribute( "data-year" ), this );
					return false;
				},
				selectMonth: function() {
					$.datepicker._selectMonthYear( id, this, "M" );
					return false;
				},
				selectYear: function() {
					$.datepicker._selectMonthYear( id, this, "Y" );
					return false;
				}
			};
			$( this ).on( this.getAttribute( "data-event" ), handler[ this.getAttribute( "data-handler" ) ] );
		} );
	},

	/* Generate the HTML for the current state of the date picker. */
	_generateHTML: function( inst ) {
		var maxDraw, prevText, prev, nextText, next, currentText, gotoDate,
			controls, buttonPanel, firstDay, showWeek, dayNames, dayNamesMin,
			monthNames, monthNamesShort, beforeShowDay, showOtherMonths,
			selectOtherMonths, defaultDate, html, dow, row, group, col, selectedDate,
			cornerClass, calender, thead, day, daysInMonth, leadDays, curRows, numRows,
			printDate, dRow, tbody, daySettings, otherMonth, unselectable,
			tempDate = new Date(),
			today = this._daylightSavingAdjust(
				new Date( tempDate.getFullYear(), tempDate.getMonth(), tempDate.getDate() ) ), // clear time
			isRTL = this._get( inst, "isRTL" ),
			showButtonPanel = this._get( inst, "showButtonPanel" ),
			hideIfNoPrevNext = this._get( inst, "hideIfNoPrevNext" ),
			navigationAsDateFormat = this._get( inst, "navigationAsDateFormat" ),
			numMonths = this._getNumberOfMonths( inst ),
			showCurrentAtPos = this._get( inst, "showCurrentAtPos" ),
			stepMonths = this._get( inst, "stepMonths" ),
			isMultiMonth = ( numMonths[ 0 ] !== 1 || numMonths[ 1 ] !== 1 ),
			currentDate = this._daylightSavingAdjust( ( !inst.currentDay ? new Date( 9999, 9, 9 ) :
				new Date( inst.currentYear, inst.currentMonth, inst.currentDay ) ) ),
			minDate = this._getMinMaxDate( inst, "min" ),
			maxDate = this._getMinMaxDate( inst, "max" ),
			drawMonth = inst.drawMonth - showCurrentAtPos,
			drawYear = inst.drawYear;

		if ( drawMonth < 0 ) {
			drawMonth += 12;
			drawYear--;
		}
		if ( maxDate ) {
			maxDraw = this._daylightSavingAdjust( new Date( maxDate.getFullYear(),
				maxDate.getMonth() - ( numMonths[ 0 ] * numMonths[ 1 ] ) + 1, maxDate.getDate() ) );
			maxDraw = ( minDate && maxDraw < minDate ? minDate : maxDraw );
			while ( this._daylightSavingAdjust( new Date( drawYear, drawMonth, 1 ) ) > maxDraw ) {
				drawMonth--;
				if ( drawMonth < 0 ) {
					drawMonth = 11;
					drawYear--;
				}
			}
		}
		inst.drawMonth = drawMonth;
		inst.drawYear = drawYear;

		prevText = this._get( inst, "prevText" );
		prevText = ( !navigationAsDateFormat ? prevText : this.formatDate( prevText,
			this._daylightSavingAdjust( new Date( drawYear, drawMonth - stepMonths, 1 ) ),
			this._getFormatConfig( inst ) ) );

		prev = ( this._canAdjustMonth( inst, -1, drawYear, drawMonth ) ?
			"<a class='ui-datepicker-prev ui-corner-all' data-handler='prev' data-event='click'" +
			" title='" + prevText + "'><span class='ui-icon ui-icon-circle-triangle-" + ( isRTL ? "e" : "w" ) + "'>" + prevText + "</span></a>" :
			( hideIfNoPrevNext ? "" : "<a class='ui-datepicker-prev ui-corner-all ui-state-disabled' title='" + prevText + "'><span class='ui-icon ui-icon-circle-triangle-" + ( isRTL ? "e" : "w" ) + "'>" + prevText + "</span></a>" ) );

		nextText = this._get( inst, "nextText" );
		nextText = ( !navigationAsDateFormat ? nextText : this.formatDate( nextText,
			this._daylightSavingAdjust( new Date( drawYear, drawMonth + stepMonths, 1 ) ),
			this._getFormatConfig( inst ) ) );

		next = ( this._canAdjustMonth( inst, +1, drawYear, drawMonth ) ?
			"<a class='ui-datepicker-next ui-corner-all' data-handler='next' data-event='click'" +
			" title='" + nextText + "'><span class='ui-icon ui-icon-circle-triangle-" + ( isRTL ? "w" : "e" ) + "'>" + nextText + "</span></a>" :
			( hideIfNoPrevNext ? "" : "<a class='ui-datepicker-next ui-corner-all ui-state-disabled' title='" + nextText + "'><span class='ui-icon ui-icon-circle-triangle-" + ( isRTL ? "w" : "e" ) + "'>" + nextText + "</span></a>" ) );

		currentText = this._get( inst, "currentText" );
		gotoDate = ( this._get( inst, "gotoCurrent" ) && inst.currentDay ? currentDate : today );
		currentText = ( !navigationAsDateFormat ? currentText :
			this.formatDate( currentText, gotoDate, this._getFormatConfig( inst ) ) );

		controls = ( !inst.inline ? "<button type='button' class='ui-datepicker-close ui-state-default ui-priority-primary ui-corner-all' data-handler='hide' data-event='click'>" +
			this._get( inst, "closeText" ) + "</button>" : "" );

		buttonPanel = ( showButtonPanel ) ? "<div class='ui-datepicker-buttonpane ui-widget-content'>" + ( isRTL ? controls : "" ) +
			( this._isInRange( inst, gotoDate ) ? "<button type='button' class='ui-datepicker-current ui-state-default ui-priority-secondary ui-corner-all' data-handler='today' data-event='click'" +
			">" + currentText + "</button>" : "" ) + ( isRTL ? "" : controls ) + "</div>" : "";

		firstDay = parseInt( this._get( inst, "firstDay" ), 10 );
		firstDay = ( isNaN( firstDay ) ? 0 : firstDay );

		showWeek = this._get( inst, "showWeek" );
		dayNames = this._get( inst, "dayNames" );
		dayNamesMin = this._get( inst, "dayNamesMin" );
		monthNames = this._get( inst, "monthNames" );
		monthNamesShort = this._get( inst, "monthNamesShort" );
		beforeShowDay = this._get( inst, "beforeShowDay" );
		showOtherMonths = this._get( inst, "showOtherMonths" );
		selectOtherMonths = this._get( inst, "selectOtherMonths" );
		defaultDate = this._getDefaultDate( inst );
		html = "";

		for ( row = 0; row < numMonths[ 0 ]; row++ ) {
			group = "";
			this.maxRows = 4;
			for ( col = 0; col < numMonths[ 1 ]; col++ ) {
				selectedDate = this._daylightSavingAdjust( new Date( drawYear, drawMonth, inst.selectedDay ) );
				cornerClass = " ui-corner-all";
				calender = "";
				if ( isMultiMonth ) {
					calender += "<div class='ui-datepicker-group";
					if ( numMonths[ 1 ] > 1 ) {
						switch ( col ) {
							case 0: calender += " ui-datepicker-group-first";
								cornerClass = " ui-corner-" + ( isRTL ? "right" : "left" ); break;
							case numMonths[ 1 ] - 1: calender += " ui-datepicker-group-last";
								cornerClass = " ui-corner-" + ( isRTL ? "left" : "right" ); break;
							default: calender += " ui-datepicker-group-middle"; cornerClass = ""; break;
						}
					}
					calender += "'>";
				}
				calender += "<div class='ui-datepicker-header ui-widget-header ui-helper-clearfix" + cornerClass + "'>" +
					( /all|left/.test( cornerClass ) && row === 0 ? ( isRTL ? next : prev ) : "" ) +
					( /all|right/.test( cornerClass ) && row === 0 ? ( isRTL ? prev : next ) : "" ) +
					this._generateMonthYearHeader( inst, drawMonth, drawYear, minDate, maxDate,
					row > 0 || col > 0, monthNames, monthNamesShort ) + // draw month headers
					"</div><table class='ui-datepicker-calendar'><thead>" +
					"<tr>";
				thead = ( showWeek ? "<th class='ui-datepicker-week-col'>" + this._get( inst, "weekHeader" ) + "</th>" : "" );
				for ( dow = 0; dow < 7; dow++ ) { // days of the week
					day = ( dow + firstDay ) % 7;
					thead += "<th scope='col'" + ( ( dow + firstDay + 6 ) % 7 >= 5 ? " class='ui-datepicker-week-end'" : "" ) + ">" +
						"<span title='" + dayNames[ day ] + "'>" + dayNamesMin[ day ] + "</span></th>";
				}
				calender += thead + "</tr></thead><tbody>";
				daysInMonth = this._getDaysInMonth( drawYear, drawMonth );
				if ( drawYear === inst.selectedYear && drawMonth === inst.selectedMonth ) {
					inst.selectedDay = Math.min( inst.selectedDay, daysInMonth );
				}
				leadDays = ( this._getFirstDayOfMonth( drawYear, drawMonth ) - firstDay + 7 ) % 7;
				curRows = Math.ceil( ( leadDays + daysInMonth ) / 7 ); // calculate the number of rows to generate
				numRows = ( isMultiMonth ? this.maxRows > curRows ? this.maxRows : curRows : curRows ); //If multiple months, use the higher number of rows (see #7043)
				this.maxRows = numRows;
				printDate = this._daylightSavingAdjust( new Date( drawYear, drawMonth, 1 - leadDays ) );
				for ( dRow = 0; dRow < numRows; dRow++ ) { // create date picker rows
					calender += "<tr>";
					tbody = ( !showWeek ? "" : "<td class='ui-datepicker-week-col'>" +
						this._get( inst, "calculateWeek" )( printDate ) + "</td>" );
					for ( dow = 0; dow < 7; dow++ ) { // create date picker days
						daySettings = ( beforeShowDay ?
							beforeShowDay.apply( ( inst.input ? inst.input[ 0 ] : null ), [ printDate ] ) : [ true, "" ] );
						otherMonth = ( printDate.getMonth() !== drawMonth );
						unselectable = ( otherMonth && !selectOtherMonths ) || !daySettings[ 0 ] ||
							( minDate && printDate < minDate ) || ( maxDate && printDate > maxDate );
						tbody += "<td class='" +
							( ( dow + firstDay + 6 ) % 7 >= 5 ? " ui-datepicker-week-end" : "" ) + // highlight weekends
							( otherMonth ? " ui-datepicker-other-month" : "" ) + // highlight days from other months
							( ( printDate.getTime() === selectedDate.getTime() && drawMonth === inst.selectedMonth && inst._keyEvent ) || // user pressed key
							( defaultDate.getTime() === printDate.getTime() && defaultDate.getTime() === selectedDate.getTime() ) ?

							// or defaultDate is current printedDate and defaultDate is selectedDate
							" " + this._dayOverClass : "" ) + // highlight selected day
							( unselectable ? " " + this._unselectableClass + " ui-state-disabled" : "" ) +  // highlight unselectable days
							( otherMonth && !showOtherMonths ? "" : " " + daySettings[ 1 ] + // highlight custom dates
							( printDate.getTime() === currentDate.getTime() ? " " + this._currentClass : "" ) + // highlight selected day
							( printDate.getTime() === today.getTime() ? " ui-datepicker-today" : "" ) ) + "'" + // highlight today (if different)
							( ( !otherMonth || showOtherMonths ) && daySettings[ 2 ] ? " title='" + daySettings[ 2 ].replace( /'/g, "&#39;" ) + "'" : "" ) + // cell title
							( unselectable ? "" : " data-handler='selectDay' data-event='click' data-month='" + printDate.getMonth() + "' data-year='" + printDate.getFullYear() + "'" ) + ">" + // actions
							( otherMonth && !showOtherMonths ? "&#xa0;" : // display for other months
							( unselectable ? "<span class='ui-state-default'>" + printDate.getDate() + "</span>" : "<a class='ui-state-default" +
							( printDate.getTime() === today.getTime() ? " ui-state-highlight" : "" ) +
							( printDate.getTime() === currentDate.getTime() ? " ui-state-active" : "" ) + // highlight selected day
							( otherMonth ? " ui-priority-secondary" : "" ) + // distinguish dates from other months
							"' href='#'>" + printDate.getDate() + "</a>" ) ) + "</td>"; // display selectable date
						printDate.setDate( printDate.getDate() + 1 );
						printDate = this._daylightSavingAdjust( printDate );
					}
					calender += tbody + "</tr>";
				}
				drawMonth++;
				if ( drawMonth > 11 ) {
					drawMonth = 0;
					drawYear++;
				}
				calender += "</tbody></table>" + ( isMultiMonth ? "</div>" +
							( ( numMonths[ 0 ] > 0 && col === numMonths[ 1 ] - 1 ) ? "<div class='ui-datepicker-row-break'></div>" : "" ) : "" );
				group += calender;
			}
			html += group;
		}
		html += buttonPanel;
		inst._keyEvent = false;
		return html;
	},

	/* Generate the month and year header. */
	_generateMonthYearHeader: function( inst, drawMonth, drawYear, minDate, maxDate,
			secondary, monthNames, monthNamesShort ) {

		var inMinYear, inMaxYear, month, years, thisYear, determineYear, year, endYear,
			changeMonth = this._get( inst, "changeMonth" ),
			changeYear = this._get( inst, "changeYear" ),
			showMonthAfterYear = this._get( inst, "showMonthAfterYear" ),
			html = "<div class='ui-datepicker-title'>",
			monthHtml = "";

		// Month selection
		if ( secondary || !changeMonth ) {
			monthHtml += "<span class='ui-datepicker-month'>" + monthNames[ drawMonth ] + "</span>";
		} else {
			inMinYear = ( minDate && minDate.getFullYear() === drawYear );
			inMaxYear = ( maxDate && maxDate.getFullYear() === drawYear );
			monthHtml += "<select class='ui-datepicker-month' data-handler='selectMonth' data-event='change'>";
			for ( month = 0; month < 12; month++ ) {
				if ( ( !inMinYear || month >= minDate.getMonth() ) && ( !inMaxYear || month <= maxDate.getMonth() ) ) {
					monthHtml += "<option value='" + month + "'" +
						( month === drawMonth ? " selected='selected'" : "" ) +
						">" + monthNamesShort[ month ] + "</option>";
				}
			}
			monthHtml += "</select>";
		}

		if ( !showMonthAfterYear ) {
			html += monthHtml + ( secondary || !( changeMonth && changeYear ) ? "&#xa0;" : "" );
		}

		// Year selection
		if ( !inst.yearshtml ) {
			inst.yearshtml = "";
			if ( secondary || !changeYear ) {
				html += "<span class='ui-datepicker-year'>" + drawYear + "</span>";
			} else {

				// determine range of years to display
				years = this._get( inst, "yearRange" ).split( ":" );
				thisYear = new Date().getFullYear();
				determineYear = function( value ) {
					var year = ( value.match( /c[+\-].*/ ) ? drawYear + parseInt( value.substring( 1 ), 10 ) :
						( value.match( /[+\-].*/ ) ? thisYear + parseInt( value, 10 ) :
						parseInt( value, 10 ) ) );
					return ( isNaN( year ) ? thisYear : year );
				};
				year = determineYear( years[ 0 ] );
				endYear = Math.max( year, determineYear( years[ 1 ] || "" ) );
				year = ( minDate ? Math.max( year, minDate.getFullYear() ) : year );
				endYear = ( maxDate ? Math.min( endYear, maxDate.getFullYear() ) : endYear );
				inst.yearshtml += "<select class='ui-datepicker-year' data-handler='selectYear' data-event='change'>";
				for ( ; year <= endYear; year++ ) {
					inst.yearshtml += "<option value='" + year + "'" +
						( year === drawYear ? " selected='selected'" : "" ) +
						">" + year + "</option>";
				}
				inst.yearshtml += "</select>";

				html += inst.yearshtml;
				inst.yearshtml = null;
			}
		}

		html += this._get( inst, "yearSuffix" );
		if ( showMonthAfterYear ) {
			html += ( secondary || !( changeMonth && changeYear ) ? "&#xa0;" : "" ) + monthHtml;
		}
		html += "</div>"; // Close datepicker_header
		return html;
	},

	/* Adjust one of the date sub-fields. */
	_adjustInstDate: function( inst, offset, period ) {
		var year = inst.selectedYear + ( period === "Y" ? offset : 0 ),
			month = inst.selectedMonth + ( period === "M" ? offset : 0 ),
			day = Math.min( inst.selectedDay, this._getDaysInMonth( year, month ) ) + ( period === "D" ? offset : 0 ),
			date = this._restrictMinMax( inst, this._daylightSavingAdjust( new Date( year, month, day ) ) );

		inst.selectedDay = date.getDate();
		inst.drawMonth = inst.selectedMonth = date.getMonth();
		inst.drawYear = inst.selectedYear = date.getFullYear();
		if ( period === "M" || period === "Y" ) {
			this._notifyChange( inst );
		}
	},

	/* Ensure a date is within any min/max bounds. */
	_restrictMinMax: function( inst, date ) {
		var minDate = this._getMinMaxDate( inst, "min" ),
			maxDate = this._getMinMaxDate( inst, "max" ),
			newDate = ( minDate && date < minDate ? minDate : date );
		return ( maxDate && newDate > maxDate ? maxDate : newDate );
	},

	/* Notify change of month/year. */
	_notifyChange: function( inst ) {
		var onChange = this._get( inst, "onChangeMonthYear" );
		if ( onChange ) {
			onChange.apply( ( inst.input ? inst.input[ 0 ] : null ),
				[ inst.selectedYear, inst.selectedMonth + 1, inst ] );
		}
	},

	/* Determine the number of months to show. */
	_getNumberOfMonths: function( inst ) {
		var numMonths = this._get( inst, "numberOfMonths" );
		return ( numMonths == null ? [ 1, 1 ] : ( typeof numMonths === "number" ? [ 1, numMonths ] : numMonths ) );
	},

	/* Determine the current maximum date - ensure no time components are set. */
	_getMinMaxDate: function( inst, minMax ) {
		return this._determineDate( inst, this._get( inst, minMax + "Date" ), null );
	},

	/* Find the number of days in a given month. */
	_getDaysInMonth: function( year, month ) {
		return 32 - this._daylightSavingAdjust( new Date( year, month, 32 ) ).getDate();
	},

	/* Find the day of the week of the first of a month. */
	_getFirstDayOfMonth: function( year, month ) {
		return new Date( year, month, 1 ).getDay();
	},

	/* Determines if we should allow a "next/prev" month display change. */
	_canAdjustMonth: function( inst, offset, curYear, curMonth ) {
		var numMonths = this._getNumberOfMonths( inst ),
			date = this._daylightSavingAdjust( new Date( curYear,
			curMonth + ( offset < 0 ? offset : numMonths[ 0 ] * numMonths[ 1 ] ), 1 ) );

		if ( offset < 0 ) {
			date.setDate( this._getDaysInMonth( date.getFullYear(), date.getMonth() ) );
		}
		return this._isInRange( inst, date );
	},

	/* Is the given date in the accepted range? */
	_isInRange: function( inst, date ) {
		var yearSplit, currentYear,
			minDate = this._getMinMaxDate( inst, "min" ),
			maxDate = this._getMinMaxDate( inst, "max" ),
			minYear = null,
			maxYear = null,
			years = this._get( inst, "yearRange" );
			if ( years ) {
				yearSplit = years.split( ":" );
				currentYear = new Date().getFullYear();
				minYear = parseInt( yearSplit[ 0 ], 10 );
				maxYear = parseInt( yearSplit[ 1 ], 10 );
				if ( yearSplit[ 0 ].match( /[+\-].*/ ) ) {
					minYear += currentYear;
				}
				if ( yearSplit[ 1 ].match( /[+\-].*/ ) ) {
					maxYear += currentYear;
				}
			}

		return ( ( !minDate || date.getTime() >= minDate.getTime() ) &&
			( !maxDate || date.getTime() <= maxDate.getTime() ) &&
			( !minYear || date.getFullYear() >= minYear ) &&
			( !maxYear || date.getFullYear() <= maxYear ) );
	},

	/* Provide the configuration settings for formatting/parsing. */
	_getFormatConfig: function( inst ) {
		var shortYearCutoff = this._get( inst, "shortYearCutoff" );
		shortYearCutoff = ( typeof shortYearCutoff !== "string" ? shortYearCutoff :
			new Date().getFullYear() % 100 + parseInt( shortYearCutoff, 10 ) );
		return { shortYearCutoff: shortYearCutoff,
			dayNamesShort: this._get( inst, "dayNamesShort" ), dayNames: this._get( inst, "dayNames" ),
			monthNamesShort: this._get( inst, "monthNamesShort" ), monthNames: this._get( inst, "monthNames" ) };
	},

	/* Format the given date for display. */
	_formatDate: function( inst, day, month, year ) {
		if ( !day ) {
			inst.currentDay = inst.selectedDay;
			inst.currentMonth = inst.selectedMonth;
			inst.currentYear = inst.selectedYear;
		}
		var date = ( day ? ( typeof day === "object" ? day :
			this._daylightSavingAdjust( new Date( year, month, day ) ) ) :
			this._daylightSavingAdjust( new Date( inst.currentYear, inst.currentMonth, inst.currentDay ) ) );
		return this.formatDate( this._get( inst, "dateFormat" ), date, this._getFormatConfig( inst ) );
	}
} );

/*
 * Bind hover events for datepicker elements.
 * Done via delegate so the binding only occurs once in the lifetime of the parent div.
 * Global datepicker_instActive, set by _updateDatepicker allows the handlers to find their way back to the active picker.
 */
function datepicker_bindHover( dpDiv ) {
	var selector = "button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a";
	return dpDiv.on( "mouseout", selector, function() {
			$( this ).removeClass( "ui-state-hover" );
			if ( this.className.indexOf( "ui-datepicker-prev" ) !== -1 ) {
				$( this ).removeClass( "ui-datepicker-prev-hover" );
			}
			if ( this.className.indexOf( "ui-datepicker-next" ) !== -1 ) {
				$( this ).removeClass( "ui-datepicker-next-hover" );
			}
		} )
		.on( "mouseover", selector, datepicker_handleMouseover );
}

function datepicker_handleMouseover() {
	if ( !$.datepicker._isDisabledDatepicker( datepicker_instActive.inline ? datepicker_instActive.dpDiv.parent()[ 0 ] : datepicker_instActive.input[ 0 ] ) ) {
		$( this ).parents( ".ui-datepicker-calendar" ).find( "a" ).removeClass( "ui-state-hover" );
		$( this ).addClass( "ui-state-hover" );
		if ( this.className.indexOf( "ui-datepicker-prev" ) !== -1 ) {
			$( this ).addClass( "ui-datepicker-prev-hover" );
		}
		if ( this.className.indexOf( "ui-datepicker-next" ) !== -1 ) {
			$( this ).addClass( "ui-datepicker-next-hover" );
		}
	}
}

/* jQuery extend now ignores nulls! */
function datepicker_extendRemove( target, props ) {
	$.extend( target, props );
	for ( var name in props ) {
		if ( props[ name ] == null ) {
			target[ name ] = props[ name ];
		}
	}
	return target;
}

/* Invoke the datepicker functionality.
   @param  options  string - a command, optionally followed by additional parameters or
					Object - settings for attaching new datepicker functionality
   @return  jQuery object */
$.fn.datepicker = function( options ) {

	/* Verify an empty collection wasn't passed - Fixes #6976 */
	if ( !this.length ) {
		return this;
	}

	/* Initialise the date picker. */
	if ( !$.datepicker.initialized ) {
		$( document ).on( "mousedown", $.datepicker._checkExternalClick );
		$.datepicker.initialized = true;
	}

	/* Append datepicker main container to body if not exist. */
	if ( $( "#" + $.datepicker._mainDivId ).length === 0 ) {
		$( "body" ).append( $.datepicker.dpDiv );
	}

	var otherArgs = Array.prototype.slice.call( arguments, 1 );
	if ( typeof options === "string" && ( options === "isDisabled" || options === "getDate" || options === "widget" ) ) {
		return $.datepicker[ "_" + options + "Datepicker" ].
			apply( $.datepicker, [ this[ 0 ] ].concat( otherArgs ) );
	}
	if ( options === "option" && arguments.length === 2 && typeof arguments[ 1 ] === "string" ) {
		return $.datepicker[ "_" + options + "Datepicker" ].
			apply( $.datepicker, [ this[ 0 ] ].concat( otherArgs ) );
	}
	return this.each( function() {
		typeof options === "string" ?
			$.datepicker[ "_" + options + "Datepicker" ].
				apply( $.datepicker, [ this ].concat( otherArgs ) ) :
			$.datepicker._attachDatepicker( this, options );
	} );
};

$.datepicker = new Datepicker(); // singleton instance
$.datepicker.initialized = false;
$.datepicker.uuid = new Date().getTime();
$.datepicker.version = "1.12.1";

var widgetsDatepicker = $.datepicker;




// This file is deprecated
var ie = $.ui.ie = !!/msie [\w.]+/.exec( navigator.userAgent.toLowerCase() );

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

//>>label: Mouse
//>>group: Widgets
//>>description: Abstracts mouse-based interactions to assist in creating certain widgets.
//>>docs: http://api.jqueryui.com/mouse/



var mouseHandled = false;
$( document ).on( "mouseup", function() {
	mouseHandled = false;
} );

var widgetsMouse = $.widget( "ui.mouse", {
	version: "1.12.1",
	options: {
		cancel: "input, textarea, button, select, option",
		distance: 1,
		delay: 0
	},
	_mouseInit: function() {
		var that = this;

		this.element
			.on( "mousedown." + this.widgetName, function( event ) {
				return that._mouseDown( event );
			} )
			.on( "click." + this.widgetName, function( event ) {
				if ( true === $.data( event.target, that.widgetName + ".preventClickEvent" ) ) {
					$.removeData( event.target, that.widgetName + ".preventClickEvent" );
					event.stopImmediatePropagation();
					return false;
				}
			} );

		this.started = false;
	},

	// TODO: make sure destroying one instance of mouse doesn't mess with
	// other instances of mouse
	_mouseDestroy: function() {
		this.element.off( "." + this.widgetName );
		if ( this._mouseMoveDelegate ) {
			this.document
				.off( "mousemove." + this.widgetName, this._mouseMoveDelegate )
				.off( "mouseup." + this.widgetName, this._mouseUpDelegate );
		}
	},

	_mouseDown: function( event ) {

		// don't let more than one widget handle mouseStart
		if ( mouseHandled ) {
			return;
		}

		this._mouseMoved = false;

		// We may have missed mouseup (out of window)
		( this._mouseStarted && this._mouseUp( event ) );

		this._mouseDownEvent = event;

		var that = this,
			btnIsLeft = ( event.which === 1 ),

			// event.target.nodeName works around a bug in IE 8 with
			// disabled inputs (#7620)
			elIsCancel = ( typeof this.options.cancel === "string" && event.target.nodeName ?
				$( event.target ).closest( this.options.cancel ).length : false );
		if ( !btnIsLeft || elIsCancel || !this._mouseCapture( event ) ) {
			return true;
		}

		this.mouseDelayMet = !this.options.delay;
		if ( !this.mouseDelayMet ) {
			this._mouseDelayTimer = setTimeout( function() {
				that.mouseDelayMet = true;
			}, this.options.delay );
		}

		if ( this._mouseDistanceMet( event ) && this._mouseDelayMet( event ) ) {
			this._mouseStarted = ( this._mouseStart( event ) !== false );
			if ( !this._mouseStarted ) {
				event.preventDefault();
				return true;
			}
		}

		// Click event may never have fired (Gecko & Opera)
		if ( true === $.data( event.target, this.widgetName + ".preventClickEvent" ) ) {
			$.removeData( event.target, this.widgetName + ".preventClickEvent" );
		}

		// These delegates are required to keep context
		this._mouseMoveDelegate = function( event ) {
			return that._mouseMove( event );
		};
		this._mouseUpDelegate = function( event ) {
			return that._mouseUp( event );
		};

		this.document
			.on( "mousemove." + this.widgetName, this._mouseMoveDelegate )
			.on( "mouseup." + this.widgetName, this._mouseUpDelegate );

		event.preventDefault();

		mouseHandled = true;
		return true;
	},

	_mouseMove: function( event ) {

		// Only check for mouseups outside the document if you've moved inside the document
		// at least once. This prevents the firing of mouseup in the case of IE<9, which will
		// fire a mousemove event if content is placed under the cursor. See #7778
		// Support: IE <9
		if ( this._mouseMoved ) {

			// IE mouseup check - mouseup happened when mouse was out of window
			if ( $.ui.ie && ( !document.documentMode || document.documentMode < 9 ) &&
					!event.button ) {
				return this._mouseUp( event );

			// Iframe mouseup check - mouseup occurred in another document
			} else if ( !event.which ) {

				// Support: Safari <=8 - 9
				// Safari sets which to 0 if you press any of the following keys
				// during a drag (#14461)
				if ( event.originalEvent.altKey || event.originalEvent.ctrlKey ||
						event.originalEvent.metaKey || event.originalEvent.shiftKey ) {
					this.ignoreMissingWhich = true;
				} else if ( !this.ignoreMissingWhich ) {
					return this._mouseUp( event );
				}
			}
		}

		if ( event.which || event.button ) {
			this._mouseMoved = true;
		}

		if ( this._mouseStarted ) {
			this._mouseDrag( event );
			return event.preventDefault();
		}

		if ( this._mouseDistanceMet( event ) && this._mouseDelayMet( event ) ) {
			this._mouseStarted =
				( this._mouseStart( this._mouseDownEvent, event ) !== false );
			( this._mouseStarted ? this._mouseDrag( event ) : this._mouseUp( event ) );
		}

		return !this._mouseStarted;
	},

	_mouseUp: function( event ) {
		this.document
			.off( "mousemove." + this.widgetName, this._mouseMoveDelegate )
			.off( "mouseup." + this.widgetName, this._mouseUpDelegate );

		if ( this._mouseStarted ) {
			this._mouseStarted = false;

			if ( event.target === this._mouseDownEvent.target ) {
				$.data( event.target, this.widgetName + ".preventClickEvent", true );
			}

			this._mouseStop( event );
		}

		if ( this._mouseDelayTimer ) {
			clearTimeout( this._mouseDelayTimer );
			delete this._mouseDelayTimer;
		}

		this.ignoreMissingWhich = false;
		mouseHandled = false;
		event.preventDefault();
	},

	_mouseDistanceMet: function( event ) {
		return ( Math.max(
				Math.abs( this._mouseDownEvent.pageX - event.pageX ),
				Math.abs( this._mouseDownEvent.pageY - event.pageY )
			) >= this.options.distance
		);
	},

	_mouseDelayMet: function( /* event */ ) {
		return this.mouseDelayMet;
	},

	// These are placeholder methods, to be overriden by extending plugin
	_mouseStart: function( /* event */ ) {},
	_mouseDrag: function( /* event */ ) {},
	_mouseStop: function( /* event */ ) {},
	_mouseCapture: function( /* event */ ) { return true; }
} );




// $.ui.plugin is deprecated. Use $.widget() extensions instead.
var plugin = $.ui.plugin = {
	add: function( module, option, set ) {
		var i,
			proto = $.ui[ module ].prototype;
		for ( i in set ) {
			proto.plugins[ i ] = proto.plugins[ i ] || [];
			proto.plugins[ i ].push( [ option, set[ i ] ] );
		}
	},
	call: function( instance, name, args, allowDisconnected ) {
		var i,
			set = instance.plugins[ name ];

		if ( !set ) {
			return;
		}

		if ( !allowDisconnected && ( !instance.element[ 0 ].parentNode ||
				instance.element[ 0 ].parentNode.nodeType === 11 ) ) {
			return;
		}

		for ( i = 0; i < set.length; i++ ) {
			if ( instance.options[ set[ i ][ 0 ] ] ) {
				set[ i ][ 1 ].apply( instance.element, args );
			}
		}
	}
};



var safeBlur = $.ui.safeBlur = function( element ) {

	// Support: IE9 - 10 only
	// If the <body> is blurred, IE will switch windows, see #9420
	if ( element && element.nodeName.toLowerCase() !== "body" ) {
		$( element ).trigger( "blur" );
	}
};


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

//>>label: Draggable
//>>group: Interactions
//>>description: Enables dragging functionality for any element.
//>>docs: http://api.jqueryui.com/draggable/
//>>demos: http://jqueryui.com/draggable/
//>>css.structure: ../../themes/base/draggable.css



$.widget( "ui.draggable", $.ui.mouse, {
	version: "1.12.1",
	widgetEventPrefix: "drag",
	options: {
		addClasses: true,
		appendTo: "parent",
		axis: false,
		connectToSortable: false,
		containment: false,
		cursor: "auto",
		cursorAt: false,
		grid: false,
		handle: false,
		helper: "original",
		iframeFix: false,
		opacity: false,
		refreshPositions: false,
		revert: false,
		revertDuration: 500,
		scope: "default",
		scroll: true,
		scrollSensitivity: 20,
		scrollSpeed: 20,
		snap: false,
		snapMode: "both",
		snapTolerance: 20,
		stack: false,
		zIndex: false,

		// Callbacks
		drag: null,
		start: null,
		stop: null
	},
	_create: function() {

		if ( this.options.helper === "original" ) {
			this._setPositionRelative();
		}
		if ( this.options.addClasses ) {
			this._addClass( "ui-draggable" );
		}
		this._setHandleClassName();

		this._mouseInit();
	},

	_setOption: function( key, value ) {
		this._super( key, value );
		if ( key === "handle" ) {
			this._removeHandleClassName();
			this._setHandleClassName();
		}
	},

	_destroy: function() {
		if ( ( this.helper || this.element ).is( ".ui-draggable-dragging" ) ) {
			this.destroyOnClear = true;
			return;
		}
		this._removeHandleClassName();
		this._mouseDestroy();
	},

	_mouseCapture: function( event ) {
		var o = this.options;

		// Among others, prevent a drag on a resizable-handle
		if ( this.helper || o.disabled ||
				$( event.target ).closest( ".ui-resizable-handle" ).length > 0 ) {
			return false;
		}

		//Quit if we're not on a valid handle
		this.handle = this._getHandle( event );
		if ( !this.handle ) {
			return false;
		}

		this._blurActiveElement( event );

		this._blockFrames( o.iframeFix === true ? "iframe" : o.iframeFix );

		return true;

	},

	_blockFrames: function( selector ) {
		this.iframeBlocks = this.document.find( selector ).map( function() {
			var iframe = $( this );

			return $( "<div>" )
				.css( "position", "absolute" )
				.appendTo( iframe.parent() )
				.outerWidth( iframe.outerWidth() )
				.outerHeight( iframe.outerHeight() )
				.offset( iframe.offset() )[ 0 ];
		} );
	},

	_unblockFrames: function() {
		if ( this.iframeBlocks ) {
			this.iframeBlocks.remove();
			delete this.iframeBlocks;
		}
	},

	_blurActiveElement: function( event ) {
		var activeElement = $.ui.safeActiveElement( this.document[ 0 ] ),
			target = $( event.target );

		// Don't blur if the event occurred on an element that is within
		// the currently focused element
		// See #10527, #12472
		if ( target.closest( activeElement ).length ) {
			return;
		}

		// Blur any element that currently has focus, see #4261
		$.ui.safeBlur( activeElement );
	},

	_mouseStart: function( event ) {

		var o = this.options;

		//Create and append the visible helper
		this.helper = this._createHelper( event );

		this._addClass( this.helper, "ui-draggable-dragging" );

		//Cache the helper size
		this._cacheHelperProportions();

		//If ddmanager is used for droppables, set the global draggable
		if ( $.ui.ddmanager ) {
			$.ui.ddmanager.current = this;
		}

		/*
		 * - Position generation -
		 * This block generates everything position related - it's the core of draggables.
		 */

		//Cache the margins of the original element
		this._cacheMargins();

		//Store the helper's css position
		this.cssPosition = this.helper.css( "position" );
		this.scrollParent = this.helper.scrollParent( true );
		this.offsetParent = this.helper.offsetParent();
		this.hasFixedAncestor = this.helper.parents().filter( function() {
				return $( this ).css( "position" ) === "fixed";
			} ).length > 0;

		//The element's absolute position on the page minus margins
		this.positionAbs = this.element.offset();
		this._refreshOffsets( event );

		//Generate the original position
		this.originalPosition = this.position = this._generatePosition( event, false );
		this.originalPageX = event.pageX;
		this.originalPageY = event.pageY;

		//Adjust the mouse offset relative to the helper if "cursorAt" is supplied
		( o.cursorAt && this._adjustOffsetFromHelper( o.cursorAt ) );

		//Set a containment if given in the options
		this._setContainment();

		//Trigger event + callbacks
		if ( this._trigger( "start", event ) === false ) {
			this._clear();
			return false;
		}

		//Recache the helper size
		this._cacheHelperProportions();

		//Prepare the droppable offsets
		if ( $.ui.ddmanager && !o.dropBehaviour ) {
			$.ui.ddmanager.prepareOffsets( this, event );
		}

		// Execute the drag once - this causes the helper not to be visible before getting its
		// correct position
		this._mouseDrag( event, true );

		// If the ddmanager is used for droppables, inform the manager that dragging has started
		// (see #5003)
		if ( $.ui.ddmanager ) {
			$.ui.ddmanager.dragStart( this, event );
		}

		return true;
	},

	_refreshOffsets: function( event ) {
		this.offset = {
			top: this.positionAbs.top - this.margins.top,
			left: this.positionAbs.left - this.margins.left,
			scroll: false,
			parent: this._getParentOffset(),
			relative: this._getRelativeOffset()
		};

		this.offset.click = {
			left: event.pageX - this.offset.left,
			top: event.pageY - this.offset.top
		};
	},

	_mouseDrag: function( event, noPropagation ) {

		// reset any necessary cached properties (see #5009)
		if ( this.hasFixedAncestor ) {
			this.offset.parent = this._getParentOffset();
		}

		//Compute the helpers position
		this.position = this._generatePosition( event, true );
		this.positionAbs = this._convertPositionTo( "absolute" );

		//Call plugins and callbacks and use the resulting position if something is returned
		if ( !noPropagation ) {
			var ui = this._uiHash();
			if ( this._trigger( "drag", event, ui ) === false ) {
				this._mouseUp( new $.Event( "mouseup", event ) );
				return false;
			}
			this.position = ui.position;
		}

		this.helper[ 0 ].style.left = this.position.left + "px";
		this.helper[ 0 ].style.top = this.position.top + "px";

		if ( $.ui.ddmanager ) {
			$.ui.ddmanager.drag( this, event );
		}

		return false;
	},

	_mouseStop: function( event ) {

		//If we are using droppables, inform the manager about the drop
		var that = this,
			dropped = false;
		if ( $.ui.ddmanager && !this.options.dropBehaviour ) {
			dropped = $.ui.ddmanager.drop( this, event );
		}

		//if a drop comes from outside (a sortable)
		if ( this.dropped ) {
			dropped = this.dropped;
			this.dropped = false;
		}

		if ( ( this.options.revert === "invalid" && !dropped ) ||
				( this.options.revert === "valid" && dropped ) ||
				this.options.revert === true || ( $.isFunction( this.options.revert ) &&
				this.options.revert.call( this.element, dropped ) )
		) {
			$( this.helper ).animate(
				this.originalPosition,
				parseInt( this.options.revertDuration, 10 ),
				function() {
					if ( that._trigger( "stop", event ) !== false ) {
						that._clear();
					}
				}
			);
		} else {
			if ( this._trigger( "stop", event ) !== false ) {
				this._clear();
			}
		}

		return false;
	},

	_mouseUp: function( event ) {
		this._unblockFrames();

		// If the ddmanager is used for droppables, inform the manager that dragging has stopped
		// (see #5003)
		if ( $.ui.ddmanager ) {
			$.ui.ddmanager.dragStop( this, event );
		}

		// Only need to focus if the event occurred on the draggable itself, see #10527
		if ( this.handleElement.is( event.target ) ) {

			// The interaction is over; whether or not the click resulted in a drag,
			// focus the element
			this.element.trigger( "focus" );
		}

		return $.ui.mouse.prototype._mouseUp.call( this, event );
	},

	cancel: function() {

		if ( this.helper.is( ".ui-draggable-dragging" ) ) {
			this._mouseUp( new $.Event( "mouseup", { target: this.element[ 0 ] } ) );
		} else {
			this._clear();
		}

		return this;

	},

	_getHandle: function( event ) {
		return this.options.handle ?
			!!$( event.target ).closest( this.element.find( this.options.handle ) ).length :
			true;
	},

	_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( event ) {

		var o = this.options,
			helperIsFunction = $.isFunction( o.helper ),
			helper = helperIsFunction ?
				$( o.helper.apply( this.element[ 0 ], [ event ] ) ) :
				( o.helper === "clone" ?
					this.element.clone().removeAttr( "id" ) :
					this.element );

		if ( !helper.parents( "body" ).length ) {
			helper.appendTo( ( o.appendTo === "parent" ?
				this.element[ 0 ].parentNode :
				o.appendTo ) );
		}

		// Http://bugs.jqueryui.com/ticket/9446
		// a helper function can return the original element
		// which wouldn't have been set to relative in _create
		if ( helperIsFunction && helper[ 0 ] === this.element[ 0 ] ) {
			this._setPositionRelative();
		}

		if ( helper[ 0 ] !== this.element[ 0 ] &&
				!( /(fixed|absolute)/ ).test( helper.css( "position" ) ) ) {
			helper.css( "position", "absolute" );
		}

		return helper;

	},

	_setPositionRelative: function() {
		if ( !( /^(?:r|a|f)/ ).test( this.element.css( "position" ) ) ) {
			this.element[ 0 ].style.position = "relative";
		}
	},

	_adjustOffsetFromHelper: function( obj ) {
		if ( typeof obj === "string" ) {
			obj = obj.split( " " );
		}
		if ( $.isArray( obj ) ) {
			obj = { left: +obj[ 0 ], top: +obj[ 1 ] || 0 };
		}
		if ( "left" in obj ) {
			this.offset.click.left = obj.left + this.margins.left;
		}
		if ( "right" in obj ) {
			this.offset.click.left = this.helperProportions.width - obj.right + this.margins.left;
		}
		if ( "top" in obj ) {
			this.offset.click.top = obj.top + this.margins.top;
		}
		if ( "bottom" in obj ) {
			this.offset.click.top = this.helperProportions.height - obj.bottom + this.margins.top;
		}
	},

	_isRootNode: function( element ) {
		return ( /(html|body)/i ).test( element.tagName ) || element === this.document[ 0 ];
	},

	_getParentOffset: function() {

		//Get the offsetParent and cache its position
		var po = this.offsetParent.offset(),
			document = this.document[ 0 ];

		// This is a special case where we need to modify a offset calculated on start, since the
		// following happened:
		// 1. The position of the helper is absolute, so it's position is calculated based on the
		// next positioned parent
		// 2. The actual offset parent is a child of the scroll parent, and the scroll parent isn't
		// the document, which means that the scroll is included in the initial calculation of the
		// offset of the parent, and never recalculated upon drag
		if ( this.cssPosition === "absolute" && this.scrollParent[ 0 ] !== document &&
				$.contains( this.scrollParent[ 0 ], this.offsetParent[ 0 ] ) ) {
			po.left += this.scrollParent.scrollLeft();
			po.top += this.scrollParent.scrollTop();
		}

		if ( this._isRootNode( this.offsetParent[ 0 ] ) ) {
			po = { top: 0, left: 0 };
		}

		return {
			top: po.top + ( parseInt( this.offsetParent.css( "borderTopWidth" ), 10 ) || 0 ),
			left: po.left + ( parseInt( this.offsetParent.css( "borderLeftWidth" ), 10 ) || 0 )
		};

	},

	_getRelativeOffset: function() {
		if ( this.cssPosition !== "relative" ) {
			return { top: 0, left: 0 };
		}

		var p = this.element.position(),
			scrollIsRootNode = this._isRootNode( this.scrollParent[ 0 ] );

		return {
			top: p.top - ( parseInt( this.helper.css( "top" ), 10 ) || 0 ) +
				( !scrollIsRootNode ? this.scrollParent.scrollTop() : 0 ),
			left: p.left - ( parseInt( this.helper.css( "left" ), 10 ) || 0 ) +
				( !scrollIsRootNode ? this.scrollParent.scrollLeft() : 0 )
		};

	},

	_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 isUserScrollable, c, ce,
			o = this.options,
			document = this.document[ 0 ];

		this.relativeContainer = null;

		if ( !o.containment ) {
			this.containment = null;
			return;
		}

		if ( o.containment === "window" ) {
			this.containment = [
				$( window ).scrollLeft() - this.offset.relative.left - this.offset.parent.left,
				$( window ).scrollTop() - this.offset.relative.top - this.offset.parent.top,
				$( window ).scrollLeft() + $( window ).width() -
					this.helperProportions.width - this.margins.left,
				$( window ).scrollTop() +
					( $( window ).height() || document.body.parentNode.scrollHeight ) -
					this.helperProportions.height - this.margins.top
			];
			return;
		}

		if ( o.containment === "document" ) {
			this.containment = [
				0,
				0,
				$( document ).width() - this.helperProportions.width - this.margins.left,
				( $( document ).height() || document.body.parentNode.scrollHeight ) -
					this.helperProportions.height - this.margins.top
			];
			return;
		}

		if ( o.containment.constructor === Array ) {
			this.containment = o.containment;
			return;
		}

		if ( o.containment === "parent" ) {
			o.containment = this.helper[ 0 ].parentNode;
		}

		c = $( o.containment );
		ce = c[ 0 ];

		if ( !ce ) {
			return;
		}

		isUserScrollable = /(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 ),
			( isUserScrollable ? Math.max( ce.scrollWidth, ce.offsetWidth ) : ce.offsetWidth ) -
				( parseInt( c.css( "borderRightWidth" ), 10 ) || 0 ) -
				( parseInt( c.css( "paddingRight" ), 10 ) || 0 ) -
				this.helperProportions.width -
				this.margins.left -
				this.margins.right,
			( isUserScrollable ? Math.max( ce.scrollHeight, ce.offsetHeight ) : ce.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;
	},

	_convertPositionTo: function( d, pos ) {

		if ( !pos ) {
			pos = this.position;
		}

		var mod = d === "absolute" ? 1 : -1,
			scrollIsRootNode = this._isRootNode( this.scrollParent[ 0 ] );

		return {
			top: (

				// The absolute mouse position
				pos.top	+

				// Only for relative positioned nodes: Relative offset from element to offset parent
				this.offset.relative.top * mod +

				// The offsetParent's offset without borders (offset + border)
				this.offset.parent.top * mod -
				( ( this.cssPosition === "fixed" ?
					-this.offset.scroll.top :
					( scrollIsRootNode ? 0 : this.offset.scroll.top ) ) * mod )
			),
			left: (

				// The absolute mouse position
				pos.left +

				// Only for relative positioned nodes: Relative offset from element to offset parent
				this.offset.relative.left * mod +

				// The offsetParent's offset without borders (offset + border)
				this.offset.parent.left * mod	-
				( ( this.cssPosition === "fixed" ?
					-this.offset.scroll.left :
					( scrollIsRootNode ? 0 : this.offset.scroll.left ) ) * mod )
			)
		};

	},

	_generatePosition: function( event, constrainPosition ) {

		var containment, co, top, left,
			o = this.options,
			scrollIsRootNode = this._isRootNode( this.scrollParent[ 0 ] ),
			pageX = event.pageX,
			pageY = event.pageY;

		// Cache the scroll
		if ( !scrollIsRootNode || !this.offset.scroll ) {
			this.offset.scroll = {
				top: this.scrollParent.scrollTop(),
				left: this.scrollParent.scrollLeft()
			};
		}

		/*
		 * - Position constraining -
		 * Constrain the position to a mix of grid, containment.
		 */

		// If we are not dragging yet, we won't check for options
		if ( constrainPosition ) {
			if ( this.containment ) {
				if ( this.relativeContainer ) {
					co = this.relativeContainer.offset();
					containment = [
						this.containment[ 0 ] + co.left,
						this.containment[ 1 ] + co.top,
						this.containment[ 2 ] + co.left,
						this.containment[ 3 ] + co.top
					];
				} else {
					containment = this.containment;
				}

				if ( event.pageX - this.offset.click.left < containment[ 0 ] ) {
					pageX = containment[ 0 ] + this.offset.click.left;
				}
				if ( event.pageY - this.offset.click.top < containment[ 1 ] ) {
					pageY = containment[ 1 ] + this.offset.click.top;
				}
				if ( event.pageX - this.offset.click.left > containment[ 2 ] ) {
					pageX = containment[ 2 ] + this.offset.click.left;
				}
				if ( event.pageY - this.offset.click.top > containment[ 3 ] ) {
					pageY = containment[ 3 ] + this.offset.click.top;
				}
			}

			if ( o.grid ) {

				//Check for grid elements set to 0 to prevent divide by 0 error causing invalid
				// argument errors in IE (see ticket #6950)
				top = o.grid[ 1 ] ? this.originalPageY + Math.round( ( pageY -
					this.originalPageY ) / o.grid[ 1 ] ) * o.grid[ 1 ] : this.originalPageY;
				pageY = containment ? ( ( top - this.offset.click.top >= containment[ 1 ] ||
					top - this.offset.click.top > containment[ 3 ] ) ?
						top :
						( ( top - this.offset.click.top >= containment[ 1 ] ) ?
							top - o.grid[ 1 ] : top + o.grid[ 1 ] ) ) : top;

				left = o.grid[ 0 ] ? this.originalPageX +
					Math.round( ( pageX - this.originalPageX ) / o.grid[ 0 ] ) * o.grid[ 0 ] :
					this.originalPageX;
				pageX = containment ? ( ( left - this.offset.click.left >= containment[ 0 ] ||
					left - this.offset.click.left > containment[ 2 ] ) ?
						left :
						( ( left - this.offset.click.left >= containment[ 0 ] ) ?
							left - o.grid[ 0 ] : left + o.grid[ 0 ] ) ) : left;
			}

			if ( o.axis === "y" ) {
				pageX = this.originalPageX;
			}

			if ( o.axis === "x" ) {
				pageY = this.originalPageY;
			}
		}

		return {
			top: (

				// The absolute mouse position
				pageY -

				// Click offset (relative to the element)
				this.offset.click.top -

				// Only for relative positioned nodes: Relative offset from element to offset parent
				this.offset.relative.top -

				// The offsetParent's offset without borders (offset + border)
				this.offset.parent.top +
				( this.cssPosition === "fixed" ?
					-this.offset.scroll.top :
					( scrollIsRootNode ? 0 : this.offset.scroll.top ) )
			),
			left: (

				// The absolute mouse position
				pageX -

				// Click offset (relative to the element)
				this.offset.click.left -

				// Only for relative positioned nodes: Relative offset from element to offset parent
				this.offset.relative.left -

				// The offsetParent's offset without borders (offset + border)
				this.offset.parent.left +
				( this.cssPosition === "fixed" ?
					-this.offset.scroll.left :
					( scrollIsRootNode ? 0 : this.offset.scroll.left ) )
			)
		};

	},

	_clear: function() {
		this._removeClass( this.helper, "ui-draggable-dragging" );
		if ( this.helper[ 0 ] !== this.element[ 0 ] && !this.cancelHelperRemoval ) {
			this.helper.remove();
		}
		this.helper = null;
		this.cancelHelperRemoval = false;
		if ( this.destroyOnClear ) {
			this.destroy();
		}
	},

	// From now on bulk stuff - mainly helpers

	_trigger: function( type, event, ui ) {
		ui = ui || this._uiHash();
		$.ui.plugin.call( this, type, [ event, ui, this ], true );

		// Absolute position and offset (see #6884 ) have to be recalculated after plugins
		if ( /^(drag|start|stop)/.test( type ) ) {
			this.positionAbs = this._convertPositionTo( "absolute" );
			ui.offset = this.positionAbs;
		}
		return $.Widget.prototype._trigger.call( this, type, event, ui );
	},

	plugins: {},

	_uiHash: function() {
		return {
			helper: this.helper,
			position: this.position,
			originalPosition: this.originalPosition,
			offset: this.positionAbs
		};
	}

} );

$.ui.plugin.add( "draggable", "connectToSortable", {
	start: function( event, ui, draggable ) {
		var uiSortable = $.extend( {}, ui, {
			item: draggable.element
		} );

		draggable.sortables = [];
		$( draggable.options.connectToSortable ).each( function() {
			var sortable = $( this ).sortable( "instance" );

			if ( sortable && !sortable.options.disabled ) {
				draggable.sortables.push( sortable );

				// RefreshPositions is called at drag start to refresh the containerCache
				// which is used in drag. This ensures it's initialized and synchronized
				// with any changes that might have happened on the page since initialization.
				sortable.refreshPositions();
				sortable._trigger( "activate", event, uiSortable );
			}
		} );
	},
	stop: function( event, ui, draggable ) {
		var uiSortable = $.extend( {}, ui, {
			item: draggable.element
		} );

		draggable.cancelHelperRemoval = false;

		$.each( draggable.sortables, function() {
			var sortable = this;

			if ( sortable.isOver ) {
				sortable.isOver = 0;

				// Allow this sortable to handle removing the helper
				draggable.cancelHelperRemoval = true;
				sortable.cancelHelperRemoval = false;

				// Use _storedCSS To restore properties in the sortable,
				// as this also handles revert (#9675) since the draggable
				// may have modified them in unexpected ways (#8809)
				sortable._storedCSS = {
					position: sortable.placeholder.css( "position" ),
					top: sortable.placeholder.css( "top" ),
					left: sortable.placeholder.css( "left" )
				};

				sortable._mouseStop( event );

				// Once drag has ended, the sortable should return to using
				// its original helper, not the shared helper from draggable
				sortable.options.helper = sortable.options._helper;
			} else {

				// Prevent this Sortable from removing the helper.
				// However, don't set the draggable to remove the helper
				// either as another connected Sortable may yet handle the removal.
				sortable.cancelHelperRemoval = true;

				sortable._trigger( "deactivate", event, uiSortable );
			}
		} );
	},
	drag: function( event, ui, draggable ) {
		$.each( draggable.sortables, function() {
			var innermostIntersecting = false,
				sortable = this;

			// Copy over variables that sortable's _intersectsWith uses
			sortable.positionAbs = draggable.positionAbs;
			sortable.helperProportions = draggable.helperProportions;
			sortable.offset.click = draggable.offset.click;

			if ( sortable._intersectsWith( sortable.containerCache ) ) {
				innermostIntersecting = true;

				$.each( draggable.sortables, function() {

					// Copy over variables that sortable's _intersectsWith uses
					this.positionAbs = draggable.positionAbs;
					this.helperProportions = draggable.helperProportions;
					this.offset.click = draggable.offset.click;

					if ( this !== sortable &&
							this._intersectsWith( this.containerCache ) &&
							$.contains( sortable.element[ 0 ], this.element[ 0 ] ) ) {
						innermostIntersecting = false;
					}

					return innermostIntersecting;
				} );
			}

			if ( innermostIntersecting ) {

				// If it intersects, we use a little isOver variable and set it once,
				// so that the move-in stuff gets fired only once.
				if ( !sortable.isOver ) {
					sortable.isOver = 1;

					// Store draggable's parent in case we need to reappend to it later.
					draggable._parent = ui.helper.parent();

					sortable.currentItem = ui.helper
						.appendTo( sortable.element )
						.data( "ui-sortable-item", true );

					// Store helper option to later restore it
					sortable.options._helper = sortable.options.helper;

					sortable.options.helper = function() {
						return ui.helper[ 0 ];
					};

					// Fire the start events of the sortable with our passed browser event,
					// and our own helper (so it doesn't create a new one)
					event.target = sortable.currentItem[ 0 ];
					sortable._mouseCapture( event, true );
					sortable._mouseStart( event, true, true );

					// Because the browser event is way off the new appended portlet,
					// modify necessary variables to reflect the changes
					sortable.offset.click.top = draggable.offset.click.top;
					sortable.offset.click.left = draggable.offset.click.left;
					sortable.offset.parent.left -= draggable.offset.parent.left -
						sortable.offset.parent.left;
					sortable.offset.parent.top -= draggable.offset.parent.top -
						sortable.offset.parent.top;

					draggable._trigger( "toSortable", event );

					// Inform draggable that the helper is in a valid drop zone,
					// used solely in the revert option to handle "valid/invalid".
					draggable.dropped = sortable.element;

					// Need to refreshPositions of all sortables in the case that
					// adding to one sortable changes the location of the other sortables (#9675)
					$.each( draggable.sortables, function() {
						this.refreshPositions();
					} );

					// Hack so receive/update callbacks work (mostly)
					draggable.currentItem = draggable.element;
					sortable.fromOutside = draggable;
				}

				if ( sortable.currentItem ) {
					sortable._mouseDrag( event );

					// Copy the sortable's position because the draggable's can potentially reflect
					// a relative position, while sortable is always absolute, which the dragged
					// element has now become. (#8809)
					ui.position = sortable.position;
				}
			} else {

				// If it doesn't intersect with the sortable, and it intersected before,
				// we fake the drag stop of the sortable, but make sure it doesn't remove
				// the helper by using cancelHelperRemoval.
				if ( sortable.isOver ) {

					sortable.isOver = 0;
					sortable.cancelHelperRemoval = true;

					// Calling sortable's mouseStop would trigger a revert,
					// so revert must be temporarily false until after mouseStop is called.
					sortable.options._revert = sortable.options.revert;
					sortable.options.revert = false;

					sortable._trigger( "out", event, sortable._uiHash( sortable ) );
					sortable._mouseStop( event, true );

					// Restore sortable behaviors that were modfied
					// when the draggable entered the sortable area (#9481)
					sortable.options.revert = sortable.options._revert;
					sortable.options.helper = sortable.options._helper;

					if ( sortable.placeholder ) {
						sortable.placeholder.remove();
					}

					// Restore and recalculate the draggable's offset considering the sortable
					// may have modified them in unexpected ways. (#8809, #10669)
					ui.helper.appendTo( draggable._parent );
					draggable._refreshOffsets( event );
					ui.position = draggable._generatePosition( event, true );

					draggable._trigger( "fromSortable", event );

					// Inform draggable that the helper is no longer in a valid drop zone
					draggable.dropped = false;

					// Need to refreshPositions of all sortables just in case removing
					// from one sortable changes the location of other sortables (#9675)
					$.each( draggable.sortables, function() {
						this.refreshPositions();
					} );
				}
			}
		} );
	}
} );

$.ui.plugin.add( "draggable", "cursor", {
	start: function( event, ui, instance ) {
		var t = $( "body" ),
			o = instance.options;

		if ( t.css( "cursor" ) ) {
			o._cursor = t.css( "cursor" );
		}
		t.css( "cursor", o.cursor );
	},
	stop: function( event, ui, instance ) {
		var o = instance.options;
		if ( o._cursor ) {
			$( "body" ).css( "cursor", o._cursor );
		}
	}
} );

$.ui.plugin.add( "draggable", "opacity", {
	start: function( event, ui, instance ) {
		var t = $( ui.helper ),
			o = instance.options;
		if ( t.css( "opacity" ) ) {
			o._opacity = t.css( "opacity" );
		}
		t.css( "opacity", o.opacity );
	},
	stop: function( event, ui, instance ) {
		var o = instance.options;
		if ( o._opacity ) {
			$( ui.helper ).css( "opacity", o._opacity );
		}
	}
} );

$.ui.plugin.add( "draggable", "scroll", {
	start: function( event, ui, i ) {
		if ( !i.scrollParentNotHidden ) {
			i.scrollParentNotHidden = i.helper.scrollParent( false );
		}

		if ( i.scrollParentNotHidden[ 0 ] !== i.document[ 0 ] &&
				i.scrollParentNotHidden[ 0 ].tagName !== "HTML" ) {
			i.overflowOffset = i.scrollParentNotHidden.offset();
		}
	},
	drag: function( event, ui, i  ) {

		var o = i.options,
			scrolled = false,
			scrollParent = i.scrollParentNotHidden[ 0 ],
			document = i.document[ 0 ];

		if ( scrollParent !== document && scrollParent.tagName !== "HTML" ) {
			if ( !o.axis || o.axis !== "x" ) {
				if ( ( i.overflowOffset.top + scrollParent.offsetHeight ) - event.pageY <
						o.scrollSensitivity ) {
					scrollParent.scrollTop = scrolled = scrollParent.scrollTop + o.scrollSpeed;
				} else if ( event.pageY - i.overflowOffset.top < o.scrollSensitivity ) {
					scrollParent.scrollTop = scrolled = scrollParent.scrollTop - o.scrollSpeed;
				}
			}

			if ( !o.axis || o.axis !== "y" ) {
				if ( ( i.overflowOffset.left + scrollParent.offsetWidth ) - event.pageX <
						o.scrollSensitivity ) {
					scrollParent.scrollLeft = scrolled = scrollParent.scrollLeft + o.scrollSpeed;
				} else if ( event.pageX - i.overflowOffset.left < o.scrollSensitivity ) {
					scrollParent.scrollLeft = scrolled = scrollParent.scrollLeft - o.scrollSpeed;
				}
			}

		} else {

			if ( !o.axis || o.axis !== "x" ) {
				if ( event.pageY - $( document ).scrollTop() < o.scrollSensitivity ) {
					scrolled = $( document ).scrollTop( $( document ).scrollTop() - o.scrollSpeed );
				} else if ( $( window ).height() - ( event.pageY - $( document ).scrollTop() ) <
						o.scrollSensitivity ) {
					scrolled = $( document ).scrollTop( $( document ).scrollTop() + o.scrollSpeed );
				}
			}

			if ( !o.axis || o.axis !== "y" ) {
				if ( event.pageX - $( document ).scrollLeft() < o.scrollSensitivity ) {
					scrolled = $( document ).scrollLeft(
						$( document ).scrollLeft() - o.scrollSpeed
					);
				} else if ( $( window ).width() - ( event.pageX - $( document ).scrollLeft() ) <
						o.scrollSensitivity ) {
					scrolled = $( document ).scrollLeft(
						$( document ).scrollLeft() + o.scrollSpeed
					);
				}
			}

		}

		if ( scrolled !== false && $.ui.ddmanager && !o.dropBehaviour ) {
			$.ui.ddmanager.prepareOffsets( i, event );
		}

	}
} );

$.ui.plugin.add( "draggable", "snap", {
	start: function( event, ui, i ) {

		var o = i.options;

		i.snapElements = [];

		$( o.snap.constructor !== String ? ( o.snap.items || ":data(ui-draggable)" ) : o.snap )
			.each( function() {
				var $t = $( this ),
					$o = $t.offset();
				if ( this !== i.element[ 0 ] ) {
					i.snapElements.push( {
						item: this,
						width: $t.outerWidth(), height: $t.outerHeight(),
						top: $o.top, left: $o.left
					} );
				}
			} );

	},
	drag: function( event, ui, inst ) {

		var ts, bs, ls, rs, l, r, t, b, i, first,
			o = inst.options,
			d = o.snapTolerance,
			x1 = ui.offset.left, x2 = x1 + inst.helperProportions.width,
			y1 = ui.offset.top, y2 = y1 + inst.helperProportions.height;

		for ( i = inst.snapElements.length - 1; i >= 0; i-- ) {

			l = inst.snapElements[ i ].left - inst.margins.left;
			r = l + inst.snapElements[ i ].width;
			t = inst.snapElements[ i ].top - inst.margins.top;
			b = t + inst.snapElements[ i ].height;

			if ( x2 < l - d || x1 > r + d || y2 < t - d || y1 > b + d ||
					!$.contains( inst.snapElements[ i ].item.ownerDocument,
					inst.snapElements[ i ].item ) ) {
				if ( inst.snapElements[ i ].snapping ) {
					( inst.options.snap.release &&
						inst.options.snap.release.call(
							inst.element,
							event,
							$.extend( inst._uiHash(), { snapItem: inst.snapElements[ i ].item } )
						) );
				}
				inst.snapElements[ i ].snapping = false;
				continue;
			}

			if ( o.snapMode !== "inner" ) {
				ts = Math.abs( t - y2 ) <= d;
				bs = Math.abs( b - y1 ) <= d;
				ls = Math.abs( l - x2 ) <= d;
				rs = Math.abs( r - x1 ) <= d;
				if ( ts ) {
					ui.position.top = inst._convertPositionTo( "relative", {
						top: t - inst.helperProportions.height,
						left: 0
					} ).top;
				}
				if ( bs ) {
					ui.position.top = inst._convertPositionTo( "relative", {
						top: b,
						left: 0
					} ).top;
				}
				if ( ls ) {
					ui.position.left = inst._convertPositionTo( "relative", {
						top: 0,
						left: l - inst.helperProportions.width
					} ).left;
				}
				if ( rs ) {
					ui.position.left = inst._convertPositionTo( "relative", {
						top: 0,
						left: r
					} ).left;
				}
			}

			first = ( ts || bs || ls || rs );

			if ( o.snapMode !== "outer" ) {
				ts = Math.abs( t - y1 ) <= d;
				bs = Math.abs( b - y2 ) <= d;
				ls = Math.abs( l - x1 ) <= d;
				rs = Math.abs( r - x2 ) <= d;
				if ( ts ) {
					ui.position.top = inst._convertPositionTo( "relative", {
						top: t,
						left: 0
					} ).top;
				}
				if ( bs ) {
					ui.position.top = inst._convertPositionTo( "relative", {
						top: b - inst.helperProportions.height,
						left: 0
					} ).top;
				}
				if ( ls ) {
					ui.position.left = inst._convertPositionTo( "relative", {
						top: 0,
						left: l
					} ).left;
				}
				if ( rs ) {
					ui.position.left = inst._convertPositionTo( "relative", {
						top: 0,
						left: r - inst.helperProportions.width
					} ).left;
				}
			}

			if ( !inst.snapElements[ i ].snapping && ( ts || bs || ls || rs || first ) ) {
				( inst.options.snap.snap &&
					inst.options.snap.snap.call(
						inst.element,
						event,
						$.extend( inst._uiHash(), {
							snapItem: inst.snapElements[ i ].item
						} ) ) );
			}
			inst.snapElements[ i ].snapping = ( ts || bs || ls || rs || first );

		}

	}
} );

$.ui.plugin.add( "draggable", "stack", {
	start: function( event, ui, instance ) {
		var min,
			o = instance.options,
			group = $.makeArray( $( o.stack ) ).sort( function( a, b ) {
				return ( parseInt( $( a ).css( "zIndex" ), 10 ) || 0 ) -
					( parseInt( $( b ).css( "zIndex" ), 10 ) || 0 );
			} );

		if ( !group.length ) { return; }

		min = parseInt( $( group[ 0 ] ).css( "zIndex" ), 10 ) || 0;
		$( group ).each( function( i ) {
			$( this ).css( "zIndex", min + i );
		} );
		this.css( "zIndex", ( min + group.length ) );
	}
} );

$.ui.plugin.add( "draggable", "zIndex", {
	start: function( event, ui, instance ) {
		var t = $( ui.helper ),
			o = instance.options;

		if ( t.css( "zIndex" ) ) {
			o._zIndex = t.css( "zIndex" );
		}
		t.css( "zIndex", o.zIndex );
	},
	stop: function( event, ui, instance ) {
		var o = instance.options;

		if ( o._zIndex ) {
			$( ui.helper ).css( "zIndex", o._zIndex );
		}
	}
} );

var widgetsDraggable = $.ui.draggable;


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

//>>label: Resizable
//>>group: Interactions
//>>description: Enables resize functionality for any element.
//>>docs: http://api.jqueryui.com/resizable/
//>>demos: http://jqueryui.com/resizable/
//>>css.structure: ../../themes/base/core.css
//>>css.structure: ../../themes/base/resizable.css
//>>css.theme: ../../themes/base/theme.css



$.widget( "ui.resizable", $.ui.mouse, {
	version: "1.12.1",
	widgetEventPrefix: "resize",
	options: {
		alsoResize: false,
		animate: false,
		animateDuration: "slow",
		animateEasing: "swing",
		aspectRatio: false,
		autoHide: false,
		classes: {
			"ui-resizable-se": "ui-icon ui-icon-gripsmall-diagonal-se"
		},
		containment: false,
		ghost: false,
		grid: false,
		handles: "e,s,se",
		helper: false,
		maxHeight: null,
		maxWidth: null,
		minHeight: 10,
		minWidth: 10,

		// See #7960
		zIndex: 90,

		// Callbacks
		resize: null,
		start: null,
		stop: null
	},

	_num: function( value ) {
		return parseFloat( value ) || 0;
	},

	_isNumber: function( value ) {
		return !isNaN( parseFloat( value ) );
	},

	_hasScroll: function( el, a ) {

		if ( $( el ).css( "overflow" ) === "hidden" ) {
			return false;
		}

		var scroll = ( a && a === "left" ) ? "scrollLeft" : "scrollTop",
			has = false;

		if ( el[ scroll ] > 0 ) {
			return true;
		}

		// TODO: determine which cases actually cause this to happen
		// if the element doesn't have the scroll set, see if it's possible to
		// set the scroll
		el[ scroll ] = 1;
		has = ( el[ scroll ] > 0 );
		el[ scroll ] = 0;
		return has;
	},

	_create: function() {

		var margins,
			o = this.options,
			that = this;
		this._addClass( "ui-resizable" );

		$.extend( this, {
			_aspectRatio: !!( o.aspectRatio ),
			aspectRatio: o.aspectRatio,
			originalElement: this.element,
			_proportionallyResizeElements: [],
			_helper: o.helper || o.ghost || o.animate ? o.helper || "ui-resizable-helper" : null
		} );

		// Wrap the element if it cannot hold child nodes
		if ( this.element[ 0 ].nodeName.match( /^(canvas|textarea|input|select|button|img)$/i ) ) {

			this.element.wrap(
				$( "<div class='ui-wrapper' style='overflow: hidden;'></div>" ).css( {
					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 = true;

			margins = {
				marginTop: this.originalElement.css( "marginTop" ),
				marginRight: this.originalElement.css( "marginRight" ),
				marginBottom: this.originalElement.css( "marginBottom" ),
				marginLeft: this.originalElement.css( "marginLeft" )
			};

			this.element.css( margins );
			this.originalElement.css( "margin", 0 );

			// support: Safari
			// Prevent Safari textarea resize
			this.originalResizeStyle = this.originalElement.css( "resize" );
			this.originalElement.css( "resize", "none" );

			this._proportionallyResizeElements.push( this.originalElement.css( {
				position: "static",
				zoom: 1,
				display: "block"
			} ) );

			// Support: IE9
			// avoid IE jump (hard set the margin)
			this.originalElement.css( margins );

			this._proportionallyResize();
		}

		this._setupHandles();

		if ( o.autoHide ) {
			$( this.element )
				.on( "mouseenter", function() {
					if ( o.disabled ) {
						return;
					}
					that._removeClass( "ui-resizable-autohide" );
					that._handles.show();
				} )
				.on( "mouseleave", function() {
					if ( o.disabled ) {
						return;
					}
					if ( !that.resizing ) {
						that._addClass( "ui-resizable-autohide" );
						that._handles.hide();
					}
				} );
		}

		this._mouseInit();
	},

	_destroy: function() {

		this._mouseDestroy();

		var wrapper,
			_destroy = function( exp ) {
				$( exp )
					.removeData( "resizable" )
					.removeData( "ui-resizable" )
					.off( ".resizable" )
					.find( ".ui-resizable-handle" )
						.remove();
			};

		// TODO: Unwrap at same DOM position
		if ( this.elementIsWrapper ) {
			_destroy( this.element );
			wrapper = this.element;
			this.originalElement.css( {
				position: wrapper.css( "position" ),
				width: wrapper.outerWidth(),
				height: wrapper.outerHeight(),
				top: wrapper.css( "top" ),
				left: wrapper.css( "left" )
			} ).insertAfter( wrapper );
			wrapper.remove();
		}

		this.originalElement.css( "resize", this.originalResizeStyle );
		_destroy( this.originalElement );

		return this;
	},

	_setOption: function( key, value ) {
		this._super( key, value );

		switch ( key ) {
		case "handles":
			this._removeHandles();
			this._setupHandles();
			break;
		default:
			break;
		}
	},

	_setupHandles: function() {
		var o = this.options, handle, i, n, hname, axis, that = this;
		this.handles = o.handles ||
			( !$( ".ui-resizable-handle", this.element ).length ?
				"e,s,se" : {
					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"
				} );

		this._handles = $();
		if ( this.handles.constructor === String ) {

			if ( this.handles === "all" ) {
				this.handles = "n,e,s,w,se,sw,ne,nw";
			}

			n = this.handles.split( "," );
			this.handles = {};

			for ( i = 0; i < n.length; i++ ) {

				handle = $.trim( n[ i ] );
				hname = "ui-resizable-" + handle;
				axis = $( "<div>" );
				this._addClass( axis, "ui-resizable-handle " + hname );

				axis.css( { zIndex: o.zIndex } );

				this.handles[ handle ] = ".ui-resizable-" + handle;
				this.element.append( axis );
			}

		}

		this._renderAxis = function( target ) {

			var i, axis, padPos, padWrapper;

			target = target || this.element;

			for ( i in this.handles ) {

				if ( this.handles[ i ].constructor === String ) {
					this.handles[ i ] = this.element.children( this.handles[ i ] ).first().show();
				} else if ( this.handles[ i ].jquery || this.handles[ i ].nodeType ) {
					this.handles[ i ] = $( this.handles[ i ] );
					this._on( this.handles[ i ], { "mousedown": that._mouseDown } );
				}

				if ( this.elementIsWrapper &&
						this.originalElement[ 0 ]
							.nodeName
							.match( /^(textarea|input|select|button)$/i ) ) {
					axis = $( this.handles[ i ], this.element );

					padWrapper = /sw|ne|nw|se|n|s/.test( i ) ?
						axis.outerHeight() :
						axis.outerWidth();

					padPos = [ "padding",
						/ne|nw|n/.test( i ) ? "Top" :
						/se|sw|s/.test( i ) ? "Bottom" :
						/^e$/.test( i ) ? "Right" : "Left" ].join( "" );

					target.css( padPos, padWrapper );

					this._proportionallyResize();
				}

				this._handles = this._handles.add( this.handles[ i ] );
			}
		};

		// TODO: make renderAxis a prototype function
		this._renderAxis( this.element );

		this._handles = this._handles.add( this.element.find( ".ui-resizable-handle" ) );
		this._handles.disableSelection();

		this._handles.on( "mouseover", function() {
			if ( !that.resizing ) {
				if ( this.className ) {
					axis = this.className.match( /ui-resizable-(se|sw|ne|nw|n|e|s|w)/i );
				}
				that.axis = axis && axis[ 1 ] ? axis[ 1 ] : "se";
			}
		} );

		if ( o.autoHide ) {
			this._handles.hide();
			this._addClass( "ui-resizable-autohide" );
		}
	},

	_removeHandles: function() {
		this._handles.remove();
	},

	_mouseCapture: function( event ) {
		var i, handle,
			capture = false;

		for ( i in this.handles ) {
			handle = $( this.handles[ i ] )[ 0 ];
			if ( handle === event.target || $.contains( handle, event.target ) ) {
				capture = true;
			}
		}

		return !this.options.disabled && capture;
	},

	_mouseStart: function( event ) {

		var curleft, curtop, cursor,
			o = this.options,
			el = this.element;

		this.resizing = true;

		this._renderProxy();

		curleft = this._num( this.helper.css( "left" ) );
		curtop = this._num( this.helper.css( "top" ) );

		if ( o.containment ) {
			curleft += $( o.containment ).scrollLeft() || 0;
			curtop += $( o.containment ).scrollTop() || 0;
		}

		this.offset = this.helper.offset();
		this.position = { left: curleft, top: curtop };

		this.size = this._helper ? {
				width: this.helper.width(),
				height: this.helper.height()
			} : {
				width: el.width(),
				height: el.height()
			};

		this.originalSize = this._helper ? {
				width: el.outerWidth(),
				height: el.outerHeight()
			} : {
				width: el.width(),
				height: el.height()
			};

		this.sizeDiff = {
			width: el.outerWidth() - el.width(),
			height: el.outerHeight() - el.height()
		};

		this.originalPosition = { left: curleft, top: curtop };
		this.originalMousePosition = { left: event.pageX, top: event.pageY };

		this.aspectRatio = ( typeof o.aspectRatio === "number" ) ?
			o.aspectRatio :
			( ( this.originalSize.width / this.originalSize.height ) || 1 );

		cursor = $( ".ui-resizable-" + this.axis ).css( "cursor" );
		$( "body" ).css( "cursor", cursor === "auto" ? this.axis + "-resize" : cursor );

		this._addClass( "ui-resizable-resizing" );
		this._propagate( "start", event );
		return true;
	},

	_mouseDrag: function( event ) {

		var data, props,
			smp = this.originalMousePosition,
			a = this.axis,
			dx = ( event.pageX - smp.left ) || 0,
			dy = ( event.pageY - smp.top ) || 0,
			trigger = this._change[ a ];

		this._updatePrevProperties();

		if ( !trigger ) {
			return false;
		}

		data = trigger.apply( this, [ event, dx, dy ] );

		this._updateVirtualBoundaries( event.shiftKey );
		if ( this._aspectRatio || event.shiftKey ) {
			data = this._updateRatio( data, event );
		}

		data = this._respectSize( data, event );

		this._updateCache( data );

		this._propagate( "resize", event );

		props = this._applyChanges();

		if ( !this._helper && this._proportionallyResizeElements.length ) {
			this._proportionallyResize();
		}

		if ( !$.isEmptyObject( props ) ) {
			this._updatePrevProperties();
			this._trigger( "resize", event, this.ui() );
			this._applyChanges();
		}

		return false;
	},

	_mouseStop: function( event ) {

		this.resizing = false;
		var pr, ista, soffseth, soffsetw, s, left, top,
			o = this.options, that = this;

		if ( this._helper ) {

			pr = this._proportionallyResizeElements;
			ista = pr.length && ( /textarea/i ).test( pr[ 0 ].nodeName );
			soffseth = ista && this._hasScroll( pr[ 0 ], "left" ) ? 0 : that.sizeDiff.height;
			soffsetw = ista ? 0 : that.sizeDiff.width;

			s = {
				width: ( that.helper.width()  - soffsetw ),
				height: ( that.helper.height() - soffseth )
			};
			left = ( parseFloat( that.element.css( "left" ) ) +
				( that.position.left - that.originalPosition.left ) ) || null;
			top = ( parseFloat( that.element.css( "top" ) ) +
				( that.position.top - that.originalPosition.top ) ) || null;

			if ( !o.animate ) {
				this.element.css( $.extend( s, { top: top, left: left } ) );
			}

			that.helper.height( that.size.height );
			that.helper.width( that.size.width );

			if ( this._helper && !o.animate ) {
				this._proportionallyResize();
			}
		}

		$( "body" ).css( "cursor", "auto" );

		this._removeClass( "ui-resizable-resizing" );

		this._propagate( "stop", event );

		if ( this._helper ) {
			this.helper.remove();
		}

		return false;

	},

	_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 props = {};

		if ( this.position.top !== this.prevPosition.top ) {
			props.top = this.position.top + "px";
		}
		if ( this.position.left !== this.prevPosition.left ) {
			props.left = this.position.left + "px";
		}
		if ( this.size.width !== this.prevSize.width ) {
			props.width = this.size.width + "px";
		}
		if ( this.size.height !== this.prevSize.height ) {
			props.height = this.size.height + "px";
		}

		this.helper.css( props );

		return props;
	},

	_updateVirtualBoundaries: function( forceAspectRatio ) {
		var pMinWidth, pMaxWidth, pMinHeight, pMaxHeight, b,
			o = this.options;

		b = {
			minWidth: this._isNumber( o.minWidth ) ? o.minWidth : 0,
			maxWidth: this._isNumber( o.maxWidth ) ? o.maxWidth : Infinity,
			minHeight: this._isNumber( o.minHeight ) ? o.minHeight : 0,
			maxHeight: this._isNumber( o.maxHeight ) ? o.maxHeight : Infinity
		};

		if ( this._aspectRatio || forceAspectRatio ) {
			pMinWidth = b.minHeight * this.aspectRatio;
			pMinHeight = b.minWidth / this.aspectRatio;
			pMaxWidth = b.maxHeight * this.aspectRatio;
			pMaxHeight = b.maxWidth / this.aspectRatio;

			if ( pMinWidth > b.minWidth ) {
				b.minWidth = pMinWidth;
			}
			if ( pMinHeight > b.minHeight ) {
				b.minHeight = pMinHeight;
			}
			if ( pMaxWidth < b.maxWidth ) {
				b.maxWidth = pMaxWidth;
			}
			if ( pMaxHeight < b.maxHeight ) {
				b.maxHeight = pMaxHeight;
			}
		}
		this._vBoundaries = b;
	},

	_updateCache: function( data ) {
		this.offset = this.helper.offset();
		if ( this._isNumber( data.left ) ) {
			this.position.left = data.left;
		}
		if ( this._isNumber( data.top ) ) {
			this.position.top = data.top;
		}
		if ( this._isNumber( data.height ) ) {
			this.size.height = data.height;
		}
		if ( this._isNumber( data.width ) ) {
			this.size.width = data.width;
		}
	},

	_updateRatio: function( data ) {

		var cpos = this.position,
			csize = this.size,
			a = this.axis;

		if ( this._isNumber( data.height ) ) {
			data.width = ( data.height * this.aspectRatio );
		} else if ( this._isNumber( data.width ) ) {
			data.height = ( data.width / this.aspectRatio );
		}

		if ( a === "sw" ) {
			data.left = cpos.left + ( csize.width - data.width );
			data.top = null;
		}
		if ( a === "nw" ) {
			data.top = cpos.top + ( csize.height - data.height );
			data.left = cpos.left + ( csize.width - data.width );
		}

		return data;
	},

	_respectSize: function( data ) {

		var o = this._vBoundaries,
			a = this.axis,
			ismaxw = this._isNumber( data.width ) && o.maxWidth && ( o.maxWidth < data.width ),
			ismaxh = this._isNumber( data.height ) && o.maxHeight && ( o.maxHeight < data.height ),
			isminw = this._isNumber( data.width ) && o.minWidth && ( o.minWidth > data.width ),
			isminh = this._isNumber( data.height ) && o.minHeight && ( o.minHeight > data.height ),
			dw = this.originalPosition.left + this.originalSize.width,
			dh = this.originalPosition.top + this.originalSize.height,
			cw = /sw|nw|w/.test( a ), ch = /nw|ne|n/.test( a );
		if ( isminw ) {
			data.width = o.minWidth;
		}
		if ( isminh ) {
			data.height = o.minHeight;
		}
		if ( ismaxw ) {
			data.width = o.maxWidth;
		}
		if ( ismaxh ) {
			data.height = o.maxHeight;
		}

		if ( isminw && cw ) {
			data.left = dw - o.minWidth;
		}
		if ( ismaxw && cw ) {
			data.left = dw - o.maxWidth;
		}
		if ( isminh && ch ) {
			data.top = dh - o.minHeight;
		}
		if ( ismaxh && ch ) {
			data.top = dh - o.maxHeight;
		}

		// Fixing jump error on top/left - bug #2330
		if ( !data.width && !data.height && !data.left && data.top ) {
			data.top = null;
		} else if ( !data.width && !data.height && !data.top && data.left ) {
			data.left = null;
		}

		return data;
	},

	_getPaddingPlusBorderDimensions: function( element ) {
		var i = 0,
			widths = [],
			borders = [
				element.css( "borderTopWidth" ),
				element.css( "borderRightWidth" ),
				element.css( "borderBottomWidth" ),
				element.css( "borderLeftWidth" )
			],
			paddings = [
				element.css( "paddingTop" ),
				element.css( "paddingRight" ),
				element.css( "paddingBottom" ),
				element.css( "paddingLeft" )
			];

		for ( ; i < 4; i++ ) {
			widths[ i ] = ( parseFloat( borders[ i ] ) || 0 );
			widths[ i ] += ( parseFloat( paddings[ i ] ) || 0 );
		}

		return {
			height: widths[ 0 ] + widths[ 2 ],
			width: widths[ 1 ] + widths[ 3 ]
		};
	},

	_proportionallyResize: function() {

		if ( !this._proportionallyResizeElements.length ) {
			return;
		}

		var prel,
			i = 0,
			element = this.helper || this.element;

		for ( ; i < this._proportionallyResizeElements.length; i++ ) {

			prel = this._proportionallyResizeElements[ i ];

			// TODO: Seems like a bug to cache this.outerDimensions
			// considering that we are in a loop.
			if ( !this.outerDimensions ) {
				this.outerDimensions = this._getPaddingPlusBorderDimensions( prel );
			}

			prel.css( {
				height: ( element.height() - this.outerDimensions.height ) || 0,
				width: ( element.width() - this.outerDimensions.width ) || 0
			} );

		}

	},

	_renderProxy: function() {

		var el = this.element, o = this.options;
		this.elementOffset = el.offset();

		if ( this._helper ) {

			this.helper = this.helper || $( "<div style='overflow:hidden;'></div>" );

			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: ++o.zIndex //TODO: Don't modify option
			} );

			this.helper
				.appendTo( "body" )
				.disableSelection();

		} else {
			this.helper = this.element;
		}

	},

	_change: {
		e: function( event, dx ) {
			return { width: this.originalSize.width + dx };
		},
		w: function( event, dx ) {
			var cs = this.originalSize, sp = this.originalPosition;
			return { left: sp.left + dx, width: cs.width - dx };
		},
		n: function( event, dx, dy ) {
			var cs = this.originalSize, sp = this.originalPosition;
			return { top: sp.top + dy, height: cs.height - dy };
		},
		s: function( event, dx, dy ) {
			return { height: this.originalSize.height + dy };
		},
		se: function( event, dx, dy ) {
			return $.extend( this._change.s.apply( this, arguments ),
				this._change.e.apply( this, [ event, dx, dy ] ) );
		},
		sw: function( event, dx, dy ) {
			return $.extend( this._change.s.apply( this, arguments ),
				this._change.w.apply( this, [ event, dx, dy ] ) );
		},
		ne: function( event, dx, dy ) {
			return $.extend( this._change.n.apply( this, arguments ),
				this._change.e.apply( this, [ event, dx, dy ] ) );
		},
		nw: function( event, dx, dy ) {
			return $.extend( this._change.n.apply( this, arguments ),
				this._change.w.apply( this, [ event, dx, dy ] ) );
		}
	},

	_propagate: function( n, event ) {
		$.ui.plugin.call( this, n, [ event, this.ui() ] );
		( n !== "resize" && this._trigger( n, event, 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
		};
	}

} );

/*
 * Resizable Extensions
 */

$.ui.plugin.add( "resizable", "animate", {

	stop: function( event ) {
		var that = $( this ).resizable( "instance" ),
			o = that.options,
			pr = that._proportionallyResizeElements,
			ista = pr.length && ( /textarea/i ).test( pr[ 0 ].nodeName ),
			soffseth = ista && that._hasScroll( pr[ 0 ], "left" ) ? 0 : that.sizeDiff.height,
			soffsetw = ista ? 0 : that.sizeDiff.width,
			style = {
				width: ( that.size.width - soffsetw ),
				height: ( that.size.height - soffseth )
			},
			left = ( parseFloat( that.element.css( "left" ) ) +
				( that.position.left - that.originalPosition.left ) ) || null,
			top = ( parseFloat( that.element.css( "top" ) ) +
				( that.position.top - that.originalPosition.top ) ) || null;

		that.element.animate(
			$.extend( style, top && left ? { top: top, left: left } : {} ), {
				duration: o.animateDuration,
				easing: o.animateEasing,
				step: function() {

					var data = {
						width: parseFloat( that.element.css( "width" ) ),
						height: parseFloat( that.element.css( "height" ) ),
						top: parseFloat( that.element.css( "top" ) ),
						left: parseFloat( that.element.css( "left" ) )
					};

					if ( pr && pr.length ) {
						$( pr[ 0 ] ).css( { width: data.width, height: data.height } );
					}

					// Propagating resize, and updating values for each animation step
					that._updateCache( data );
					that._propagate( "resize", event );

				}
			}
		);
	}

} );

$.ui.plugin.add( "resizable", "containment", {

	start: function() {
		var element, p, co, ch, cw, width, height,
			that = $( this ).resizable( "instance" ),
			o = that.options,
			el = that.element,
			oc = o.containment,
			ce = ( oc instanceof $ ) ?
				oc.get( 0 ) :
				( /parent/.test( oc ) ) ? el.parent().get( 0 ) : oc;

		if ( !ce ) {
			return;
		}

		that.containerElement = $( ce );

		if ( /document/.test( oc ) || oc === document ) {
			that.containerOffset = {
				left: 0,
				top: 0
			};
			that.containerPosition = {
				left: 0,
				top: 0
			};

			that.parentData = {
				element: $( document ),
				left: 0,
				top: 0,
				width: $( document ).width(),
				height: $( document ).height() || document.body.parentNode.scrollHeight
			};
		} else {
			element = $( ce );
			p = [];
			$( [ "Top", "Right", "Left", "Bottom" ] ).each( function( i, name ) {
				p[ i ] = that._num( element.css( "padding" + name ) );
			} );

			that.containerOffset = element.offset();
			that.containerPosition = element.position();
			that.containerSize = {
				height: ( element.innerHeight() - p[ 3 ] ),
				width: ( element.innerWidth() - p[ 1 ] )
			};

			co = that.containerOffset;
			ch = that.containerSize.height;
			cw = that.containerSize.width;
			width = ( that._hasScroll ( ce, "left" ) ? ce.scrollWidth : cw );
			height = ( that._hasScroll ( ce ) ? ce.scrollHeight : ch ) ;

			that.parentData = {
				element: ce,
				left: co.left,
				top: co.top,
				width: width,
				height: height
			};
		}
	},

	resize: function( event ) {
		var woset, hoset, isParent, isOffsetRelative,
			that = $( this ).resizable( "instance" ),
			o = that.options,
			co = that.containerOffset,
			cp = that.position,
			pRatio = that._aspectRatio || event.shiftKey,
			cop = {
				top: 0,
				left: 0
			},
			ce = that.containerElement,
			continueResize = true;

		if ( ce[ 0 ] !== document && ( /static/ ).test( ce.css( "position" ) ) ) {
			cop = co;
		}

		if ( cp.left < ( that._helper ? co.left : 0 ) ) {
			that.size.width = that.size.width +
				( that._helper ?
					( that.position.left - co.left ) :
					( that.position.left - cop.left ) );

			if ( pRatio ) {
				that.size.height = that.size.width / that.aspectRatio;
				continueResize = false;
			}
			that.position.left = o.helper ? co.left : 0;
		}

		if ( cp.top < ( that._helper ? co.top : 0 ) ) {
			that.size.height = that.size.height +
				( that._helper ?
					( that.position.top - co.top ) :
					that.position.top );

			if ( pRatio ) {
				that.size.width = that.size.height * that.aspectRatio;
				continueResize = false;
			}
			that.position.top = that._helper ? co.top : 0;
		}

		isParent = that.containerElement.get( 0 ) === that.element.parent().get( 0 );
		isOffsetRelative = /relative|absolute/.test( that.containerElement.css( "position" ) );

		if ( isParent && isOffsetRelative ) {
			that.offset.left = that.parentData.left + that.position.left;
			that.offset.top = that.parentData.top + that.position.top;
		} else {
			that.offset.left = that.element.offset().left;
			that.offset.top = that.element.offset().top;
		}

		woset = Math.abs( that.sizeDiff.width +
			( that._helper ?
				that.offset.left - cop.left :
				( that.offset.left - co.left ) ) );

		hoset = Math.abs( that.sizeDiff.height +
			( that._helper ?
				that.offset.top - cop.top :
				( that.offset.top - co.top ) ) );

		if ( woset + that.size.width >= that.parentData.width ) {
			that.size.width = that.parentData.width - woset;
			if ( pRatio ) {
				that.size.height = that.size.width / that.aspectRatio;
				continueResize = false;
			}
		}

		if ( hoset + that.size.height >= that.parentData.height ) {
			that.size.height = that.parentData.height - hoset;
			if ( pRatio ) {
				that.size.width = that.size.height * that.aspectRatio;
				continueResize = false;
			}
		}

		if ( !continueResize ) {
			that.position.left = that.prevPosition.left;
			that.position.top = that.prevPosition.top;
			that.size.width = that.prevSize.width;
			that.size.height = that.prevSize.height;
		}
	},

	stop: function() {
		var that = $( this ).resizable( "instance" ),
			o = that.options,
			co = that.containerOffset,
			cop = that.containerPosition,
			ce = that.containerElement,
			helper = $( that.helper ),
			ho = helper.offset(),
			w = helper.outerWidth() - that.sizeDiff.width,
			h = helper.outerHeight() - that.sizeDiff.height;

		if ( that._helper && !o.animate && ( /relative/ ).test( ce.css( "position" ) ) ) {
			$( this ).css( {
				left: ho.left - cop.left - co.left,
				width: w,
				height: h
			} );
		}

		if ( that._helper && !o.animate && ( /static/ ).test( ce.css( "position" ) ) ) {
			$( this ).css( {
				left: ho.left - cop.left - co.left,
				width: w,
				height: h
			} );
		}
	}
} );

$.ui.plugin.add( "resizable", "alsoResize", {

	start: function() {
		var that = $( this ).resizable( "instance" ),
			o = that.options;

		$( o.alsoResize ).each( function() {
			var el = $( this );
			el.data( "ui-resizable-alsoresize", {
				width: parseFloat( el.width() ), height: parseFloat( el.height() ),
				left: parseFloat( el.css( "left" ) ), top: parseFloat( el.css( "top" ) )
			} );
		} );
	},

	resize: function( event, ui ) {
		var that = $( this ).resizable( "instance" ),
			o = that.options,
			os = that.originalSize,
			op = that.originalPosition,
			delta = {
				height: ( that.size.height - os.height ) || 0,
				width: ( that.size.width - os.width ) || 0,
				top: ( that.position.top - op.top ) || 0,
				left: ( that.position.left - op.left ) || 0
			};

			$( o.alsoResize ).each( function() {
				var el = $( this ), start = $( this ).data( "ui-resizable-alsoresize" ), style = {},
					css = el.parents( ui.originalElement[ 0 ] ).length ?
							[ "width", "height" ] :
							[ "width", "height", "top", "left" ];

				$.each( css, function( i, prop ) {
					var sum = ( start[ prop ] || 0 ) + ( delta[ prop ] || 0 );
					if ( sum && sum >= 0 ) {
						style[ prop ] = sum || null;
					}
				} );

				el.css( style );
			} );
	},

	stop: function() {
		$( this ).removeData( "ui-resizable-alsoresize" );
	}
} );

$.ui.plugin.add( "resizable", "ghost", {

	start: function() {

		var that = $( this ).resizable( "instance" ), cs = that.size;

		that.ghost = that.originalElement.clone();
		that.ghost.css( {
			opacity: 0.25,
			display: "block",
			position: "relative",
			height: cs.height,
			width: cs.width,
			margin: 0,
			left: 0,
			top: 0
		} );

		that._addClass( that.ghost, "ui-resizable-ghost" );

		// DEPRECATED
		// TODO: remove after 1.12
		if ( $.uiBackCompat !== false && typeof that.options.ghost === "string" ) {

			// Ghost option
			that.ghost.addClass( this.options.ghost );
		}

		that.ghost.appendTo( that.helper );

	},

	resize: function() {
		var that = $( this ).resizable( "instance" );
		if ( that.ghost ) {
			that.ghost.css( {
				position: "relative",
				height: that.size.height,
				width: that.size.width
			} );
		}
	},

	stop: function() {
		var that = $( this ).resizable( "instance" );
		if ( that.ghost && that.helper ) {
			that.helper.get( 0 ).removeChild( that.ghost.get( 0 ) );
		}
	}

} );

$.ui.plugin.add( "resizable", "grid", {

	resize: function() {
		var outerDimensions,
			that = $( this ).resizable( "instance" ),
			o = that.options,
			cs = that.size,
			os = that.originalSize,
			op = that.originalPosition,
			a = that.axis,
			grid = typeof o.grid === "number" ? [ o.grid, o.grid ] : o.grid,
			gridX = ( grid[ 0 ] || 1 ),
			gridY = ( grid[ 1 ] || 1 ),
			ox = Math.round( ( cs.width - os.width ) / gridX ) * gridX,
			oy = Math.round( ( cs.height - os.height ) / gridY ) * gridY,
			newWidth = os.width + ox,
			newHeight = os.height + oy,
			isMaxWidth = o.maxWidth && ( o.maxWidth < newWidth ),
			isMaxHeight = o.maxHeight && ( o.maxHeight < newHeight ),
			isMinWidth = o.minWidth && ( o.minWidth > newWidth ),
			isMinHeight = o.minHeight && ( o.minHeight > newHeight );

		o.grid = grid;

		if ( isMinWidth ) {
			newWidth += gridX;
		}
		if ( isMinHeight ) {
			newHeight += gridY;
		}
		if ( isMaxWidth ) {
			newWidth -= gridX;
		}
		if ( isMaxHeight ) {
			newHeight -= gridY;
		}

		if ( /^(se|s|e)$/.test( a ) ) {
			that.size.width = newWidth;
			that.size.height = newHeight;
		} else if ( /^(ne)$/.test( a ) ) {
			that.size.width = newWidth;
			that.size.height = newHeight;
			that.position.top = op.top - oy;
		} else if ( /^(sw)$/.test( a ) ) {
			that.size.width = newWidth;
			that.size.height = newHeight;
			that.position.left = op.left - ox;
		} else {
			if ( newHeight - gridY <= 0 || newWidth - gridX <= 0 ) {
				outerDimensions = that._getPaddingPlusBorderDimensions( this );
			}

			if ( newHeight - gridY > 0 ) {
				that.size.height = newHeight;
				that.position.top = op.top - oy;
			} else {
				newHeight = gridY - outerDimensions.height;
				that.size.height = newHeight;
				that.position.top = op.top + os.height - newHeight;
			}
			if ( newWidth - gridX > 0 ) {
				that.size.width = newWidth;
				that.position.left = op.left - ox;
			} else {
				newWidth = gridX - outerDimensions.width;
				that.size.width = newWidth;
				that.position.left = op.left + os.width - newWidth;
			}
		}
	}

} );

var widgetsResizable = $.ui.resizable;


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

//>>label: Dialog
//>>group: Widgets
//>>description: Displays customizable dialog windows.
//>>docs: http://api.jqueryui.com/dialog/
//>>demos: http://jqueryui.com/dialog/
//>>css.structure: ../../themes/base/core.css
//>>css.structure: ../../themes/base/dialog.css
//>>css.theme: ../../themes/base/theme.css



$.widget( "ui.dialog", {
	version: "1.12.1",
	options: {
		appendTo: "body",
		autoOpen: true,
		buttons: [],
		classes: {
			"ui-dialog": "ui-corner-all",
			"ui-dialog-titlebar": "ui-corner-all"
		},
		closeOnEscape: true,
		closeText: "Close",
		draggable: true,
		hide: null,
		height: "auto",
		maxHeight: null,
		maxWidth: null,
		minHeight: 150,
		minWidth: 150,
		modal: false,
		position: {
			my: "center",
			at: "center",
			of: window,
			collision: "fit",

			// Ensure the titlebar is always visible
			using: function( pos ) {
				var topOffset = $( this ).css( pos ).offset().top;
				if ( topOffset < 0 ) {
					$( this ).css( "top", pos.top - topOffset );
				}
			}
		},
		resizable: true,
		show: null,
		title: null,
		width: 300,

		// Callbacks
		beforeClose: null,
		close: null,
		drag: null,
		dragStart: null,
		dragStop: null,
		focus: null,
		open: null,
		resize: null,
		resizeStart: null,
		resizeStop: null
	},

	sizeRelatedOptions: {
		buttons: true,
		height: true,
		maxHeight: true,
		maxWidth: true,
		minHeight: true,
		minWidth: true,
		width: true
	},

	resizableRelatedOptions: {
		maxHeight: true,
		maxWidth: true,
		minHeight: true,
		minWidth: true
	},

	_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" );
		if ( this.options.title == null && this.originalTitle != null ) {
			this.options.title = this.originalTitle;
		}

		// Dialogs can't be disabled
		if ( this.options.disabled ) {
			this.options.disabled = false;
		}

		this._createWrapper();

		this.element
			.show()
			.removeAttr( "title" )
			.appendTo( this.uiDialog );

		this._addClass( "ui-dialog-content", "ui-widget-content" );

		this._createTitlebar();
		this._createButtonPane();

		if ( this.options.draggable && $.fn.draggable ) {
			this._makeDraggable();
		}
		if ( this.options.resizable && $.fn.resizable ) {
			this._makeResizable();
		}

		this._isOpen = false;

		this._trackFocus();
	},

	_init: function() {
		if ( this.options.autoOpen ) {
			this.open();
		}
	},

	_appendTo: function() {
		var element = this.options.appendTo;
		if ( element && ( element.jquery || element.nodeType ) ) {
			return $( element );
		}
		return this.document.find( element || "body" ).eq( 0 );
	},

	_destroy: function() {
		var next,
			originalPosition = this.originalPosition;

		this._untrackInstance();
		this._destroyOverlay();

		this.element
			.removeUniqueId()
			.css( this.originalCss )

			// Without detaching first, the following becomes really slow
			.detach();

		this.uiDialog.remove();

		if ( this.originalTitle ) {
			this.element.attr( "title", this.originalTitle );
		}

		next = originalPosition.parent.children().eq( originalPosition.index );

		// Don't try to place the dialog next to itself (#8613)
		if ( next.length && next[ 0 ] !== this.element[ 0 ] ) {
			next.before( this.element );
		} else {
			originalPosition.parent.append( this.element );
		}
	},

	widget: function() {
		return this.uiDialog;
	},

	disable: $.noop,
	enable: $.noop,

	close: function( event ) {
		var that = this;

		if ( !this._isOpen || this._trigger( "beforeClose", event ) === false ) {
			return;
		}

		this._isOpen = false;
		this._focusedElement = null;
		this._destroyOverlay();
		this._untrackInstance();

		if ( !this.opener.filter( ":focusable" ).trigger( "focus" ).length ) {

			// Hiding a focused element doesn't trigger blur in WebKit
			// so in case we have nothing to focus on, explicitly blur the active element
			// https://bugs.webkit.org/show_bug.cgi?id=47182
			$.ui.safeBlur( $.ui.safeActiveElement( this.document[ 0 ] ) );
		}

		this._hide( this.uiDialog, this.options.hide, function() {
			that._trigger( "close", event );
		} );
	},

	isOpen: function() {
		return this._isOpen;
	},

	moveToTop: function() {
		this._moveToTop();
	},

	_moveToTop: function( event, silent ) {
		var moved = false,
			zIndices = this.uiDialog.siblings( ".ui-front:visible" ).map( function() {
				return +$( this ).css( "z-index" );
			} ).get(),
			zIndexMax = Math.max.apply( null, zIndices );

		if ( zIndexMax >= +this.uiDialog.css( "z-index" ) ) {
			this.uiDialog.css( "z-index", zIndexMax + 1 );
			moved = true;
		}

		if ( moved && !silent ) {
			this._trigger( "focus", event );
		}
		return moved;
	},

	open: function() {
		var that = this;
		if ( this._isOpen ) {
			if ( this._moveToTop() ) {
				this._focusTabbable();
			}
			return;
		}

		this._isOpen = true;
		this.opener = $( $.ui.safeActiveElement( this.document[ 0 ] ) );

		this._size();
		this._position();
		this._createOverlay();
		this._moveToTop( null, true );

		// Ensure the overlay is moved to the top with the dialog, but only when
		// opening. The overlay shouldn't move after the dialog is open so that
		// modeless dialogs opened after the modal dialog stack properly.
		if ( this.overlay ) {
			this.overlay.css( "z-index", this.uiDialog.css( "z-index" ) - 1 );
		}

		this._show( this.uiDialog, this.options.show, function() {
			that._focusTabbable();
			that._trigger( "focus" );
		} );

		// Track the dialog immediately upon openening in case a focus event
		// somehow occurs outside of the dialog before an element inside the
		// dialog is focused (#10152)
		this._makeFocusTarget();

		this._trigger( "open" );
	},

	_focusTabbable: function() {

		// Set focus to the first match:
		// 1. An element that was focused previously
		// 2. First element inside the dialog matching [autofocus]
		// 3. Tabbable element inside the content element
		// 4. Tabbable element inside the buttonpane
		// 5. The close button
		// 6. The dialog itself
		var hasFocus = this._focusedElement;
		if ( !hasFocus ) {
			hasFocus = this.element.find( "[autofocus]" );
		}
		if ( !hasFocus.length ) {
			hasFocus = this.element.find( ":tabbable" );
		}
		if ( !hasFocus.length ) {
			hasFocus = this.uiDialogButtonPane.find( ":tabbable" );
		}
		if ( !hasFocus.length ) {
			hasFocus = this.uiDialogTitlebarClose.filter( ":tabbable" );
		}
		if ( !hasFocus.length ) {
			hasFocus = this.uiDialog;
		}
		hasFocus.eq( 0 ).trigger( "focus" );
	},

	_keepFocus: function( event ) {
		function checkFocus() {
			var activeElement = $.ui.safeActiveElement( this.document[ 0 ] ),
				isActive = this.uiDialog[ 0 ] === activeElement ||
					$.contains( this.uiDialog[ 0 ], activeElement );
			if ( !isActive ) {
				this._focusTabbable();
			}
		}
		event.preventDefault();
		checkFocus.call( this );

		// support: IE
		// IE <= 8 doesn't prevent moving focus even with event.preventDefault()
		// so we check again later
		this._delay( checkFocus );
	},

	_createWrapper: function() {
		this.uiDialog = $( "<div>" )
			.hide()
			.attr( {

				// Setting tabIndex makes the div focusable
				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( event ) {
				if ( this.options.closeOnEscape && !event.isDefaultPrevented() && event.keyCode &&
						event.keyCode === $.ui.keyCode.ESCAPE ) {
					event.preventDefault();
					this.close( event );
					return;
				}

				// Prevent tabbing out of dialogs
				if ( event.keyCode !== $.ui.keyCode.TAB || event.isDefaultPrevented() ) {
					return;
				}
				var tabbables = this.uiDialog.find( ":tabbable" ),
					first = tabbables.filter( ":first" ),
					last = tabbables.filter( ":last" );

				if ( ( event.target === last[ 0 ] || event.target === this.uiDialog[ 0 ] ) &&
						!event.shiftKey ) {
					this._delay( function() {
						first.trigger( "focus" );
					} );
					event.preventDefault();
				} else if ( ( event.target === first[ 0 ] ||
						event.target === this.uiDialog[ 0 ] ) && event.shiftKey ) {
					this._delay( function() {
						last.trigger( "focus" );
					} );
					event.preventDefault();
				}
			},
			mousedown: function( event ) {
				if ( this._moveToTop( event ) ) {
					this._focusTabbable();
				}
			}
		} );

		// We assume that any existing aria-describedby attribute means
		// that the dialog content is marked up properly
		// otherwise we brute force the content as the description
		if ( !this.element.find( "[aria-describedby]" ).length ) {
			this.uiDialog.attr( {
				"aria-describedby": this.element.uniqueId().attr( "id" )
			} );
		}
	},

	_createTitlebar: function() {
		var uiDialogTitle;

		this.uiDialogTitlebar = $( "<div>" );
		this._addClass( this.uiDialogTitlebar,
			"ui-dialog-titlebar", "ui-widget-header ui-helper-clearfix" );
		this._on( this.uiDialogTitlebar, {
			mousedown: function( event ) {

				// Don't prevent click on close button (#8838)
				// Focusing a dialog that is partially scrolled out of view
				// causes the browser to scroll it into view, preventing the click event
				if ( !$( event.target ).closest( ".ui-dialog-titlebar-close" ) ) {

					// Dialog isn't getting focus when dragging (#8063)
					this.uiDialog.trigger( "focus" );
				}
			}
		} );

		// Support: IE
		// Use type="button" to prevent enter keypresses in textboxes from closing the
		// dialog in IE (#9312)
		this.uiDialogTitlebarClose = $( "<button type='button'></button>" )
			.button( {
				label: $( "<a>" ).text( this.options.closeText ).html(),
				icon: "ui-icon-closethick",
				showLabel: false
			} )
			.appendTo( this.uiDialogTitlebar );

		this._addClass( this.uiDialogTitlebarClose, "ui-dialog-titlebar-close" );
		this._on( this.uiDialogTitlebarClose, {
			click: function( event ) {
				event.preventDefault();
				this.close( event );
			}
		} );

		uiDialogTitle = $( "<span>" ).uniqueId().prependTo( this.uiDialogTitlebar );
		this._addClass( uiDialogTitle, "ui-dialog-title" );
		this._title( uiDialogTitle );

		this.uiDialogTitlebar.prependTo( this.uiDialog );

		this.uiDialog.attr( {
			"aria-labelledby": uiDialogTitle.attr( "id" )
		} );
	},

	_title: function( title ) {
		if ( this.options.title ) {
			title.text( this.options.title );
		} else {
			title.html( "&#160;" );
		}
	},

	_createButtonPane: function() {
		this.uiDialogButtonPane = $( "<div>" );
		this._addClass( this.uiDialogButtonPane, "ui-dialog-buttonpane",
			"ui-widget-content ui-helper-clearfix" );

		this.uiButtonSet = $( "<div>" )
			.appendTo( this.uiDialogButtonPane );
		this._addClass( this.uiButtonSet, "ui-dialog-buttonset" );

		this._createButtons();
	},

	_createButtons: function() {
		var that = this,
			buttons = this.options.buttons;

		// If we already have a button pane, remove it
		this.uiDialogButtonPane.remove();
		this.uiButtonSet.empty();

		if ( $.isEmptyObject( buttons ) || ( $.isArray( buttons ) && !buttons.length ) ) {
			this._removeClass( this.uiDialog, "ui-dialog-buttons" );
			return;
		}

		$.each( buttons, function( name, props ) {
			var click, buttonOptions;
			props = $.isFunction( props ) ?
				{ click: props, text: name } :
				props;

			// Default to a non-submitting button
			props = $.extend( { type: "button" }, props );

			// Change the context for the click callback to be the main element
			click = props.click;
			buttonOptions = {
				icon: props.icon,
				iconPosition: props.iconPosition,
				showLabel: props.showLabel,

				// Deprecated options
				icons: props.icons,
				text: props.text
			};

			delete props.click;
			delete props.icon;
			delete props.iconPosition;
			delete props.showLabel;

			// Deprecated options
			delete props.icons;
			if ( typeof props.text === "boolean" ) {
				delete props.text;
			}

			$( "<button></button>", props )
				.button( buttonOptions )
				.appendTo( that.uiButtonSet )
				.on( "click", function() {
					click.apply( that.element[ 0 ], arguments );
				} );
		} );
		this._addClass( this.uiDialog, "ui-dialog-buttons" );
		this.uiDialogButtonPane.appendTo( this.uiDialog );
	},

	_makeDraggable: function() {
		var that = this,
			options = this.options;

		function filteredUi( ui ) {
			return {
				position: ui.position,
				offset: ui.offset
			};
		}

		this.uiDialog.draggable( {
			cancel: ".ui-dialog-content, .ui-dialog-titlebar-close",
			handle: ".ui-dialog-titlebar",
			containment: "document",
			start: function( event, ui ) {
				that._addClass( $( this ), "ui-dialog-dragging" );
				that._blockFrames();
				that._trigger( "dragStart", event, filteredUi( ui ) );
			},
			drag: function( event, ui ) {
				that._trigger( "drag", event, filteredUi( ui ) );
			},
			stop: function( event, ui ) {
				var left = ui.offset.left - that.document.scrollLeft(),
					top = ui.offset.top - that.document.scrollTop();

				options.position = {
					my: "left top",
					at: "left" + ( left >= 0 ? "+" : "" ) + left + " " +
						"top" + ( top >= 0 ? "+" : "" ) + top,
					of: that.window
				};
				that._removeClass( $( this ), "ui-dialog-dragging" );
				that._unblockFrames();
				that._trigger( "dragStop", event, filteredUi( ui ) );
			}
		} );
	},

	_makeResizable: function() {
		var that = this,
			options = this.options,
			handles = options.resizable,

			// .ui-resizable has position: relative defined in the stylesheet
			// but dialogs have to use absolute or fixed positioning
			position = this.uiDialog.css( "position" ),
			resizeHandles = typeof handles === "string" ?
				handles :
				"n,e,s,w,se,sw,ne,nw";

		function filteredUi( ui ) {
			return {
				originalPosition: ui.originalPosition,
				originalSize: ui.originalSize,
				position: ui.position,
				size: ui.size
			};
		}

		this.uiDialog.resizable( {
			cancel: ".ui-dialog-content",
			containment: "document",
			alsoResize: this.element,
			maxWidth: options.maxWidth,
			maxHeight: options.maxHeight,
			minWidth: options.minWidth,
			minHeight: this._minHeight(),
			handles: resizeHandles,
			start: function( event, ui ) {
				that._addClass( $( this ), "ui-dialog-resizing" );
				that._blockFrames();
				that._trigger( "resizeStart", event, filteredUi( ui ) );
			},
			resize: function( event, ui ) {
				that._trigger( "resize", event, filteredUi( ui ) );
			},
			stop: function( event, ui ) {
				var offset = that.uiDialog.offset(),
					left = offset.left - that.document.scrollLeft(),
					top = offset.top - that.document.scrollTop();

				options.height = that.uiDialog.height();
				options.width = that.uiDialog.width();
				options.position = {
					my: "left top",
					at: "left" + ( left >= 0 ? "+" : "" ) + left + " " +
						"top" + ( top >= 0 ? "+" : "" ) + top,
					of: that.window
				};
				that._removeClass( $( this ), "ui-dialog-resizing" );
				that._unblockFrames();
				that._trigger( "resizeStop", event, filteredUi( ui ) );
			}
		} )
			.css( "position", position );
	},

	_trackFocus: function() {
		this._on( this.widget(), {
			focusin: function( event ) {
				this._makeFocusTarget();
				this._focusedElement = $( event.target );
			}
		} );
	},

	_makeFocusTarget: function() {
		this._untrackInstance();
		this._trackingInstances().unshift( this );
	},

	_untrackInstance: function() {
		var instances = this._trackingInstances(),
			exists = $.inArray( this, instances );
		if ( exists !== -1 ) {
			instances.splice( exists, 1 );
		}
	},

	_trackingInstances: function() {
		var instances = this.document.data( "ui-dialog-instances" );
		if ( !instances ) {
			instances = [];
			this.document.data( "ui-dialog-instances", instances );
		}
		return instances;
	},

	_minHeight: function() {
		var options = this.options;

		return options.height === "auto" ?
			options.minHeight :
			Math.min( options.minHeight, options.height );
	},

	_position: function() {

		// Need to show the dialog to get the actual offset in the position plugin
		var isVisible = this.uiDialog.is( ":visible" );
		if ( !isVisible ) {
			this.uiDialog.show();
		}
		this.uiDialog.position( this.options.position );
		if ( !isVisible ) {
			this.uiDialog.hide();
		}
	},

	_setOptions: function( options ) {
		var that = this,
			resize = false,
			resizableOptions = {};

		$.each( options, function( key, value ) {
			that._setOption( key, value );

			if ( key in that.sizeRelatedOptions ) {
				resize = true;
			}
			if ( key in that.resizableRelatedOptions ) {
				resizableOptions[ key ] = value;
			}
		} );

		if ( resize ) {
			this._size();
			this._position();
		}
		if ( this.uiDialog.is( ":data(ui-resizable)" ) ) {
			this.uiDialog.resizable( "option", resizableOptions );
		}
	},

	_setOption: function( key, value ) {
		var isDraggable, isResizable,
			uiDialog = this.uiDialog;

		if ( key === "disabled" ) {
			return;
		}

		this._super( key, value );

		if ( key === "appendTo" ) {
			this.uiDialog.appendTo( this._appendTo() );
		}

		if ( key === "buttons" ) {
			this._createButtons();
		}

		if ( key === "closeText" ) {
			this.uiDialogTitlebarClose.button( {

				// Ensure that we always pass a string
				label: $( "<a>" ).text( "" + this.options.closeText ).html()
			} );
		}

		if ( key === "draggable" ) {
			isDraggable = uiDialog.is( ":data(ui-draggable)" );
			if ( isDraggable && !value ) {
				uiDialog.draggable( "destroy" );
			}

			if ( !isDraggable && value ) {
				this._makeDraggable();
			}
		}

		if ( key === "position" ) {
			this._position();
		}

		if ( key === "resizable" ) {

			// currently resizable, becoming non-resizable
			isResizable = uiDialog.is( ":data(ui-resizable)" );
			if ( isResizable && !value ) {
				uiDialog.resizable( "destroy" );
			}

			// Currently resizable, changing handles
			if ( isResizable && typeof value === "string" ) {
				uiDialog.resizable( "option", "handles", value );
			}

			// Currently non-resizable, becoming resizable
			if ( !isResizable && value !== false ) {
				this._makeResizable();
			}
		}

		if ( key === "title" ) {
			this._title( this.uiDialogTitlebar.find( ".ui-dialog-title" ) );
		}
	},

	_size: function() {

		// If the user has resized the dialog, the .ui-dialog and .ui-dialog-content
		// divs will both have width and height set, so we need to reset them
		var nonContentHeight, minContentHeight, maxContentHeight,
			options = this.options;

		// Reset content sizing
		this.element.show().css( {
			width: "auto",
			minHeight: 0,
			maxHeight: "none",
			height: 0
		} );

		if ( options.minWidth > options.width ) {
			options.width = options.minWidth;
		}

		// Reset wrapper sizing
		// determine the height of all the non-content elements
		nonContentHeight = this.uiDialog.css( {
			height: "auto",
			width: options.width
		} )
			.outerHeight();
		minContentHeight = Math.max( 0, options.minHeight - nonContentHeight );
		maxContentHeight = typeof options.maxHeight === "number" ?
			Math.max( 0, options.maxHeight - nonContentHeight ) :
			"none";

		if ( options.height === "auto" ) {
			this.element.css( {
				minHeight: minContentHeight,
				maxHeight: maxContentHeight,
				height: "auto"
			} );
		} else {
			this.element.height( Math.max( 0, options.height - nonContentHeight ) );
		}

		if ( this.uiDialog.is( ":data(ui-resizable)" ) ) {
			this.uiDialog.resizable( "option", "minHeight", this._minHeight() );
		}
	},

	_blockFrames: function() {
		this.iframeBlocks = this.document.find( "iframe" ).map( function() {
			var iframe = $( this );

			return $( "<div>" )
				.css( {
					position: "absolute",
					width: iframe.outerWidth(),
					height: iframe.outerHeight()
				} )
				.appendTo( iframe.parent() )
				.offset( iframe.offset() )[ 0 ];
		} );
	},

	_unblockFrames: function() {
		if ( this.iframeBlocks ) {
			this.iframeBlocks.remove();
			delete this.iframeBlocks;
		}
	},

	_allowInteraction: function( event ) {
		if ( $( event.target ).closest( ".ui-dialog" ).length ) {
			return true;
		}

		// TODO: Remove hack when datepicker implements
		// the .ui-front logic (#8989)
		return !!$( event.target ).closest( ".ui-datepicker" ).length;
	},

	_createOverlay: function() {
		if ( !this.options.modal ) {
			return;
		}

		// We use a delay in case the overlay is created from an
		// event that we're going to be cancelling (#2804)
		var isOpening = true;
		this._delay( function() {
			isOpening = false;
		} );

		if ( !this.document.data( "ui-dialog-overlays" ) ) {

			// Prevent use of anchors and inputs
			// Using _on() for an event handler shared across many instances is
			// safe because the dialogs stack and must be closed in reverse order
			this._on( this.document, {
				focusin: function( event ) {
					if ( isOpening ) {
						return;
					}

					if ( !this._allowInteraction( event ) ) {
						event.preventDefault();
						this._trackingInstances()[ 0 ]._focusTabbable();
					}
				}
			} );
		}

		this.overlay = $( "<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 ) {
			return;
		}

		if ( this.overlay ) {
			var overlays = this.document.data( "ui-dialog-overlays" ) - 1;

			if ( !overlays ) {
				this._off( this.document, "focusin" );
				this.document.removeData( "ui-dialog-overlays" );
			} else {
				this.document.data( "ui-dialog-overlays", overlays );
			}

			this.overlay.remove();
			this.overlay = null;
		}
	}
} );

// DEPRECATED
// TODO: switch return back to widget declaration at top of file when this is removed
if ( $.uiBackCompat !== false ) {

	// Backcompat for dialogClass option
	$.widget( "ui.dialog", $.ui.dialog, {
		options: {
			dialogClass: ""
		},
		_createWrapper: function() {
			this._super();
			this.uiDialog.addClass( this.options.dialogClass );
		},
		_setOption: function( key, value ) {
			if ( key === "dialogClass" ) {
				this.uiDialog
					.removeClass( this.options.dialogClass )
					.addClass( value );
			}
			this._superApply( arguments );
		}
	} );
}

var widgetsDialog = $.ui.dialog;


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

//>>label: Droppable
//>>group: Interactions
//>>description: Enables drop targets for draggable elements.
//>>docs: http://api.jqueryui.com/droppable/
//>>demos: http://jqueryui.com/droppable/



$.widget( "ui.droppable", {
	version: "1.12.1",
	widgetEventPrefix: "drop",
	options: {
		accept: "*",
		addClasses: true,
		greedy: false,
		scope: "default",
		tolerance: "intersect",

		// Callbacks
		activate: null,
		deactivate: null,
		drop: null,
		out: null,
		over: null
	},
	_create: function() {

		var proportions,
			o = this.options,
			accept = o.accept;

		this.isover = false;
		this.isout = true;

		this.accept = $.isFunction( accept ) ? accept : function( d ) {
			return d.is( accept );
		};

		this.proportions = function( /* valueToWrite */ ) {
			if ( arguments.length ) {

				// Store the droppable's proportions
				proportions = arguments[ 0 ];
			} else {

				// Retrieve or derive the droppable's proportions
				return proportions ?
					proportions :
					proportions = {
						width: this.element[ 0 ].offsetWidth,
						height: this.element[ 0 ].offsetHeight
					};
			}
		};

		this._addToManager( o.scope );

		o.addClasses && this._addClass( "ui-droppable" );

	},

	_addToManager: function( scope ) {

		// Add the reference and positions to the manager
		$.ui.ddmanager.droppables[ scope ] = $.ui.ddmanager.droppables[ scope ] || [];
		$.ui.ddmanager.droppables[ scope ].push( this );
	},

	_splice: function( drop ) {
		var i = 0;
		for ( ; i < drop.length; i++ ) {
			if ( drop[ i ] === this ) {
				drop.splice( i, 1 );
			}
		}
	},

	_destroy: function() {
		var drop = $.ui.ddmanager.droppables[ this.options.scope ];

		this._splice( drop );
	},

	_setOption: function( key, value ) {

		if ( key === "accept" ) {
			this.accept = $.isFunction( value ) ? value : function( d ) {
				return d.is( value );
			};
		} else if ( key === "scope" ) {
			var drop = $.ui.ddmanager.droppables[ this.options.scope ];

			this._splice( drop );
			this._addToManager( value );
		}

		this._super( key, value );
	},

	_activate: function( event ) {
		var draggable = $.ui.ddmanager.current;

		this._addActiveClass();
		if ( draggable ) {
			this._trigger( "activate", event, this.ui( draggable ) );
		}
	},

	_deactivate: function( event ) {
		var draggable = $.ui.ddmanager.current;

		this._removeActiveClass();
		if ( draggable ) {
			this._trigger( "deactivate", event, this.ui( draggable ) );
		}
	},

	_over: function( event ) {

		var draggable = $.ui.ddmanager.current;

		// Bail if draggable and droppable are same element
		if ( !draggable || ( draggable.currentItem ||
				draggable.element )[ 0 ] === this.element[ 0 ] ) {
			return;
		}

		if ( this.accept.call( this.element[ 0 ], ( draggable.currentItem ||
				draggable.element ) ) ) {
			this._addHoverClass();
			this._trigger( "over", event, this.ui( draggable ) );
		}

	},

	_out: function( event ) {

		var draggable = $.ui.ddmanager.current;

		// Bail if draggable and droppable are same element
		if ( !draggable || ( draggable.currentItem ||
				draggable.element )[ 0 ] === this.element[ 0 ] ) {
			return;
		}

		if ( this.accept.call( this.element[ 0 ], ( draggable.currentItem ||
				draggable.element ) ) ) {
			this._removeHoverClass();
			this._trigger( "out", event, this.ui( draggable ) );
		}

	},

	_drop: function( event, custom ) {

		var draggable = custom || $.ui.ddmanager.current,
			childrenIntersection = false;

		// Bail if draggable and droppable are same element
		if ( !draggable || ( draggable.currentItem ||
				draggable.element )[ 0 ] === this.element[ 0 ] ) {
			return false;
		}

		this.element
			.find( ":data(ui-droppable)" )
			.not( ".ui-draggable-dragging" )
			.each( function() {
				var inst = $( this ).droppable( "instance" );
				if (
					inst.options.greedy &&
					!inst.options.disabled &&
					inst.options.scope === draggable.options.scope &&
					inst.accept.call(
						inst.element[ 0 ], ( draggable.currentItem || draggable.element )
					) &&
					intersect(
						draggable,
						$.extend( inst, { offset: inst.element.offset() } ),
						inst.options.tolerance, event
					)
				) {
					childrenIntersection = true;
					return false; }
			} );
		if ( childrenIntersection ) {
			return false;
		}

		if ( this.accept.call( this.element[ 0 ],
				( draggable.currentItem || draggable.element ) ) ) {
			this._removeActiveClass();
			this._removeHoverClass();

			this._trigger( "drop", event, this.ui( draggable ) );
			return this.element;
		}

		return false;

	},

	ui: function( c ) {
		return {
			draggable: ( c.currentItem || c.element ),
			helper: c.helper,
			position: c.position,
			offset: c.positionAbs
		};
	},

	// Extension points just to make backcompat sane and avoid duplicating logic
	// TODO: Remove in 1.13 along with call to it below
	_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" );
	}
} );

var intersect = $.ui.intersect = ( function() {
	function isOverAxis( x, reference, size ) {
		return ( x >= reference ) && ( x < ( reference + size ) );
	}

	return function( draggable, droppable, toleranceMode, event ) {

		if ( !droppable.offset ) {
			return false;
		}

		var x1 = ( draggable.positionAbs ||
				draggable.position.absolute ).left + draggable.margins.left,
			y1 = ( draggable.positionAbs ||
				draggable.position.absolute ).top + draggable.margins.top,
			x2 = x1 + draggable.helperProportions.width,
			y2 = y1 + draggable.helperProportions.height,
			l = droppable.offset.left,
			t = droppable.offset.top,
			r = l + droppable.proportions().width,
			b = t + droppable.proportions().height;

		switch ( toleranceMode ) {
		case "fit":
			return ( l <= x1 && x2 <= r && t <= y1 && y2 <= b );
		case "intersect":
			return ( l < x1 + ( draggable.helperProportions.width / 2 ) && // Right Half
				x2 - ( draggable.helperProportions.width / 2 ) < r && // Left Half
				t < y1 + ( draggable.helperProportions.height / 2 ) && // Bottom Half
				y2 - ( draggable.helperProportions.height / 2 ) < b ); // Top Half
		case "pointer":
			return isOverAxis( event.pageY, t, droppable.proportions().height ) &&
				isOverAxis( event.pageX, l, droppable.proportions().width );
		case "touch":
			return (
				( y1 >= t && y1 <= b ) || // Top edge touching
				( y2 >= t && y2 <= b ) || // Bottom edge touching
				( y1 < t && y2 > b ) // Surrounded vertically
			) && (
				( x1 >= l && x1 <= r ) || // Left edge touching
				( x2 >= l && x2 <= r ) || // Right edge touching
				( x1 < l && x2 > r ) // Surrounded horizontally
			);
		default:
			return false;
		}
	};
} )();

/*
	This manager tracks offsets of draggables and droppables
*/
$.ui.ddmanager = {
	current: null,
	droppables: { "default": [] },
	prepareOffsets: function( t, event ) {

		var i, j,
			m = $.ui.ddmanager.droppables[ t.options.scope ] || [],
			type = event ? event.type : null, // workaround for #2317
			list = ( t.currentItem || t.element ).find( ":data(ui-droppable)" ).addBack();

		droppablesLoop: for ( i = 0; i < m.length; i++ ) {

			// No disabled and non-accepted
			if ( m[ i ].options.disabled || ( t && !m[ i ].accept.call( m[ i ].element[ 0 ],
					( t.currentItem || t.element ) ) ) ) {
				continue;
			}

			// Filter out elements in the current dragged item
			for ( j = 0; j < list.length; j++ ) {
				if ( list[ j ] === m[ i ].element[ 0 ] ) {
					m[ i ].proportions().height = 0;
					continue droppablesLoop;
				}
			}

			m[ i ].visible = m[ i ].element.css( "display" ) !== "none";
			if ( !m[ i ].visible ) {
				continue;
			}

			// Activate the droppable if used directly from draggables
			if ( type === "mousedown" ) {
				m[ i ]._activate.call( m[ i ], event );
			}

			m[ i ].offset = m[ i ].element.offset();
			m[ i ].proportions( {
				width: m[ i ].element[ 0 ].offsetWidth,
				height: m[ i ].element[ 0 ].offsetHeight
			} );

		}

	},
	drop: function( draggable, event ) {

		var dropped = false;

		// Create a copy of the droppables in case the list changes during the drop (#9116)
		$.each( ( $.ui.ddmanager.droppables[ draggable.options.scope ] || [] ).slice(), function() {

			if ( !this.options ) {
				return;
			}
			if ( !this.options.disabled && this.visible &&
					intersect( draggable, this, this.options.tolerance, event ) ) {
				dropped = this._drop.call( this, event ) || dropped;
			}

			if ( !this.options.disabled && this.visible && this.accept.call( this.element[ 0 ],
					( draggable.currentItem || draggable.element ) ) ) {
				this.isout = true;
				this.isover = false;
				this._deactivate.call( this, event );
			}

		} );
		return dropped;

	},
	dragStart: function( draggable, event ) {

		// Listen for scrolling so that if the dragging causes scrolling the position of the
		// droppables can be recalculated (see #5003)
		draggable.element.parentsUntil( "body" ).on( "scroll.droppable", function() {
			if ( !draggable.options.refreshPositions ) {
				$.ui.ddmanager.prepareOffsets( draggable, event );
			}
		} );
	},
	drag: function( draggable, event ) {

		// If you have a highly dynamic page, you might try this option. It renders positions
		// every time you move the mouse.
		if ( draggable.options.refreshPositions ) {
			$.ui.ddmanager.prepareOffsets( draggable, event );
		}

		// Run through all droppables and check their positions based on specific tolerance options
		$.each( $.ui.ddmanager.droppables[ draggable.options.scope ] || [], function() {

			if ( this.options.disabled || this.greedyChild || !this.visible ) {
				return;
			}

			var parentInstance, scope, parent,
				intersects = intersect( draggable, this, this.options.tolerance, event ),
				c = !intersects && this.isover ?
					"isout" :
					( intersects && !this.isover ? "isover" : null );
			if ( !c ) {
				return;
			}

			if ( this.options.greedy ) {

				// find droppable parents with same scope
				scope = this.options.scope;
				parent = this.element.parents( ":data(ui-droppable)" ).filter( function() {
					return $( this ).droppable( "instance" ).options.scope === scope;
				} );

				if ( parent.length ) {
					parentInstance = $( parent[ 0 ] ).droppable( "instance" );
					parentInstance.greedyChild = ( c === "isover" );
				}
			}

			// We just moved into a greedy child
			if ( parentInstance && c === "isover" ) {
				parentInstance.isover = false;
				parentInstance.isout = true;
				parentInstance._out.call( parentInstance, event );
			}

			this[ c ] = true;
			this[ c === "isout" ? "isover" : "isout" ] = false;
			this[ c === "isover" ? "_over" : "_out" ].call( this, event );

			// We just moved out of a greedy child
			if ( parentInstance && c === "isout" ) {
				parentInstance.isout = false;
				parentInstance.isover = true;
				parentInstance._over.call( parentInstance, event );
			}
		} );

	},
	dragStop: function( draggable, event ) {
		draggable.element.parentsUntil( "body" ).off( "scroll.droppable" );

		// Call prepareOffsets one final time since IE does not fire return scroll events when
		// overflow was caused by drag (see #5003)
		if ( !draggable.options.refreshPositions ) {
			$.ui.ddmanager.prepareOffsets( draggable, event );
		}
	}
};

// DEPRECATED
// TODO: switch return back to widget declaration at top of file when this is removed
if ( $.uiBackCompat !== false ) {

	// Backcompat for activeClass and hoverClass options
	$.widget( "ui.droppable", $.ui.droppable, {
		options: {
			hoverClass: false,
			activeClass: false
		},
		_addActiveClass: function() {
			this._super();
			if ( this.options.activeClass ) {
				this.element.addClass( this.options.activeClass );
			}
		},
		_removeActiveClass: function() {
			this._super();
			if ( this.options.activeClass ) {
				this.element.removeClass( this.options.activeClass );
			}
		},
		_addHoverClass: function() {
			this._super();
			if ( this.options.hoverClass ) {
				this.element.addClass( this.options.hoverClass );
			}
		},
		_removeHoverClass: function() {
			this._super();
			if ( this.options.hoverClass ) {
				this.element.removeClass( this.options.hoverClass );
			}
		}
	} );
}

var widgetsDroppable = $.ui.droppable;


/*!
 * jQuery UI Progressbar 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Progressbar
//>>group: Widgets
// jscs:disable maximumLineLength
//>>description: Displays a status indicator for loading state, standard percentage, and other progress indicators.
// jscs:enable maximumLineLength
//>>docs: http://api.jqueryui.com/progressbar/
//>>demos: http://jqueryui.com/progressbar/
//>>css.structure: ../../themes/base/core.css
//>>css.structure: ../../themes/base/progressbar.css
//>>css.theme: ../../themes/base/theme.css



var widgetsProgressbar = $.widget( "ui.progressbar", {
	version: "1.12.1",
	options: {
		classes: {
			"ui-progressbar": "ui-corner-all",
			"ui-progressbar-value": "ui-corner-left",
			"ui-progressbar-complete": "ui-corner-right"
		},
		max: 100,
		value: 0,

		change: null,
		complete: null
	},

	min: 0,

	_create: function() {

		// Constrain initial value
		this.oldValue = this.options.value = this._constrainedValue();

		this.element.attr( {

			// Only set static values; aria-valuenow and aria-valuemax are
			// set inside _refreshValue()
			role: "progressbar",
			"aria-valuemin": this.min
		} );
		this._addClass( "ui-progressbar", "ui-widget ui-widget-content" );

		this.valueDiv = $( "<div>" ).appendTo( this.element );
		this._addClass( this.valueDiv, "ui-progressbar-value", "ui-widget-header" );
		this._refreshValue();
	},

	_destroy: function() {
		this.element.removeAttr( "role aria-valuemin aria-valuemax aria-valuenow" );

		this.valueDiv.remove();
	},

	value: function( newValue ) {
		if ( newValue === undefined ) {
			return this.options.value;
		}

		this.options.value = this._constrainedValue( newValue );
		this._refreshValue();
	},

	_constrainedValue: function( newValue ) {
		if ( newValue === undefined ) {
			newValue = this.options.value;
		}

		this.indeterminate = newValue === false;

		// Sanitize value
		if ( typeof newValue !== "number" ) {
			newValue = 0;
		}

		return this.indeterminate ? false :
			Math.min( this.options.max, Math.max( this.min, newValue ) );
	},

	_setOptions: function( options ) {

		// Ensure "value" option is set after other values (like max)
		var value = options.value;
		delete options.value;

		this._super( options );

		this.options.value = this._constrainedValue( value );
		this._refreshValue();
	},

	_setOption: function( key, value ) {
		if ( key === "max" ) {

			// Don't allow a max less than min
			value = Math.max( this.min, value );
		}
		this._super( key, value );
	},

	_setOptionDisabled: function( value ) {
		this._super( value );

		this.element.attr( "aria-disabled", value );
		this._toggleClass( null, "ui-state-disabled", !!value );
	},

	_percentage: function() {
		return this.indeterminate ?
			100 :
			100 * ( this.options.value - this.min ) / ( this.options.max - this.min );
	},

	_refreshValue: function() {
		var value = this.options.value,
			percentage = this._percentage();

		this.valueDiv
			.toggle( this.indeterminate || value > this.min )
			.width( percentage.toFixed( 0 ) + "%" );

		this
			._toggleClass( this.valueDiv, "ui-progressbar-complete", null,
				value === this.options.max )
			._toggleClass( "ui-progressbar-indeterminate", null, this.indeterminate );

		if ( this.indeterminate ) {
			this.element.removeAttr( "aria-valuenow" );
			if ( !this.overlayDiv ) {
				this.overlayDiv = $( "<div>" ).appendTo( this.valueDiv );
				this._addClass( this.overlayDiv, "ui-progressbar-overlay" );
			}
		} else {
			this.element.attr( {
				"aria-valuemax": this.options.max,
				"aria-valuenow": value
			} );
			if ( this.overlayDiv ) {
				this.overlayDiv.remove();
				this.overlayDiv = null;
			}
		}

		if ( this.oldValue !== value ) {
			this.oldValue = value;
			this._trigger( "change" );
		}
		if ( value === this.options.max ) {
			this._trigger( "complete" );
		}
	}
} );


/*!
 * jQuery UI Selectable 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Selectable
//>>group: Interactions
//>>description: Allows groups of elements to be selected with the mouse.
//>>docs: http://api.jqueryui.com/selectable/
//>>demos: http://jqueryui.com/selectable/
//>>css.structure: ../../themes/base/selectable.css



var widgetsSelectable = $.widget( "ui.selectable", $.ui.mouse, {
	version: "1.12.1",
	options: {
		appendTo: "body",
		autoRefresh: true,
		distance: 0,
		filter: "*",
		tolerance: "touch",

		// Callbacks
		selected: null,
		selecting: null,
		start: null,
		stop: null,
		unselected: null,
		unselecting: null
	},
	_create: function() {
		var that = this;

		this._addClass( "ui-selectable" );

		this.dragged = false;

		// Cache selectee children based on filter
		this.refresh = function() {
			that.elementPos = $( that.element[ 0 ] ).offset();
			that.selectees = $( that.options.filter, that.element[ 0 ] );
			that._addClass( that.selectees, "ui-selectee" );
			that.selectees.each( function() {
				var $this = $( this ),
					selecteeOffset = $this.offset(),
					pos = {
						left: selecteeOffset.left - that.elementPos.left,
						top: selecteeOffset.top - that.elementPos.top
					};
				$.data( this, "selectable-item", {
					element: this,
					$element: $this,
					left: pos.left,
					top: pos.top,
					right: pos.left + $this.outerWidth(),
					bottom: pos.top + $this.outerHeight(),
					startselected: false,
					selected: $this.hasClass( "ui-selected" ),
					selecting: $this.hasClass( "ui-selecting" ),
					unselecting: $this.hasClass( "ui-unselecting" )
				} );
			} );
		};
		this.refresh();

		this._mouseInit();

		this.helper = $( "<div>" );
		this._addClass( this.helper, "ui-selectable-helper" );
	},

	_destroy: function() {
		this.selectees.removeData( "selectable-item" );
		this._mouseDestroy();
	},

	_mouseStart: function( event ) {
		var that = this,
			options = this.options;

		this.opos = [ event.pageX, event.pageY ];
		this.elementPos = $( this.element[ 0 ] ).offset();

		if ( this.options.disabled ) {
			return;
		}

		this.selectees = $( options.filter, this.element[ 0 ] );

		this._trigger( "start", event );

		$( options.appendTo ).append( this.helper );

		// position helper (lasso)
		this.helper.css( {
			"left": event.pageX,
			"top": event.pageY,
			"width": 0,
			"height": 0
		} );

		if ( options.autoRefresh ) {
			this.refresh();
		}

		this.selectees.filter( ".ui-selected" ).each( function() {
			var selectee = $.data( this, "selectable-item" );
			selectee.startselected = true;
			if ( !event.metaKey && !event.ctrlKey ) {
				that._removeClass( selectee.$element, "ui-selected" );
				selectee.selected = false;
				that._addClass( selectee.$element, "ui-unselecting" );
				selectee.unselecting = true;

				// selectable UNSELECTING callback
				that._trigger( "unselecting", event, {
					unselecting: selectee.element
				} );
			}
		} );

		$( event.target ).parents().addBack().each( function() {
			var doSelect,
				selectee = $.data( this, "selectable-item" );
			if ( selectee ) {
				doSelect = ( !event.metaKey && !event.ctrlKey ) ||
					!selectee.$element.hasClass( "ui-selected" );
				that._removeClass( selectee.$element, doSelect ? "ui-unselecting" : "ui-selected" )
					._addClass( selectee.$element, doSelect ? "ui-selecting" : "ui-unselecting" );
				selectee.unselecting = !doSelect;
				selectee.selecting = doSelect;
				selectee.selected = doSelect;

				// selectable (UN)SELECTING callback
				if ( doSelect ) {
					that._trigger( "selecting", event, {
						selecting: selectee.element
					} );
				} else {
					that._trigger( "unselecting", event, {
						unselecting: selectee.element
					} );
				}
				return false;
			}
		} );

	},

	_mouseDrag: function( event ) {

		this.dragged = true;

		if ( this.options.disabled ) {
			return;
		}

		var tmp,
			that = this,
			options = this.options,
			x1 = this.opos[ 0 ],
			y1 = this.opos[ 1 ],
			x2 = event.pageX,
			y2 = event.pageY;

		if ( x1 > x2 ) { tmp = x2; x2 = x1; x1 = tmp; }
		if ( y1 > y2 ) { tmp = y2; y2 = y1; y1 = tmp; }
		this.helper.css( { left: x1, top: y1, width: x2 - x1, height: y2 - y1 } );

		this.selectees.each( function() {
			var selectee = $.data( this, "selectable-item" ),
				hit = false,
				offset = {};

			//prevent helper from being selected if appendTo: selectable
			if ( !selectee || selectee.element === that.element[ 0 ] ) {
				return;
			}

			offset.left   = selectee.left   + that.elementPos.left;
			offset.right  = selectee.right  + that.elementPos.left;
			offset.top    = selectee.top    + that.elementPos.top;
			offset.bottom = selectee.bottom + that.elementPos.top;

			if ( options.tolerance === "touch" ) {
				hit = ( !( offset.left > x2 || offset.right < x1 || offset.top > y2 ||
                    offset.bottom < y1 ) );
			} else if ( options.tolerance === "fit" ) {
				hit = ( offset.left > x1 && offset.right < x2 && offset.top > y1 &&
                    offset.bottom < y2 );
			}

			if ( hit ) {

				// SELECT
				if ( selectee.selected ) {
					that._removeClass( selectee.$element, "ui-selected" );
					selectee.selected = false;
				}
				if ( selectee.unselecting ) {
					that._removeClass( selectee.$element, "ui-unselecting" );
					selectee.unselecting = false;
				}
				if ( !selectee.selecting ) {
					that._addClass( selectee.$element, "ui-selecting" );
					selectee.selecting = true;

					// selectable SELECTING callback
					that._trigger( "selecting", event, {
						selecting: selectee.element
					} );
				}
			} else {

				// UNSELECT
				if ( selectee.selecting ) {
					if ( ( event.metaKey || event.ctrlKey ) && selectee.startselected ) {
						that._removeClass( selectee.$element, "ui-selecting" );
						selectee.selecting = false;
						that._addClass( selectee.$element, "ui-selected" );
						selectee.selected = true;
					} else {
						that._removeClass( selectee.$element, "ui-selecting" );
						selectee.selecting = false;
						if ( selectee.startselected ) {
							that._addClass( selectee.$element, "ui-unselecting" );
							selectee.unselecting = true;
						}

						// selectable UNSELECTING callback
						that._trigger( "unselecting", event, {
							unselecting: selectee.element
						} );
					}
				}
				if ( selectee.selected ) {
					if ( !event.metaKey && !event.ctrlKey && !selectee.startselected ) {
						that._removeClass( selectee.$element, "ui-selected" );
						selectee.selected = false;

						that._addClass( selectee.$element, "ui-unselecting" );
						selectee.unselecting = true;

						// selectable UNSELECTING callback
						that._trigger( "unselecting", event, {
							unselecting: selectee.element
						} );
					}
				}
			}
		} );

		return false;
	},

	_mouseStop: function( event ) {
		var that = this;

		this.dragged = false;

		$( ".ui-unselecting", this.element[ 0 ] ).each( function() {
			var selectee = $.data( this, "selectable-item" );
			that._removeClass( selectee.$element, "ui-unselecting" );
			selectee.unselecting = false;
			selectee.startselected = false;
			that._trigger( "unselected", event, {
				unselected: selectee.element
			} );
		} );
		$( ".ui-selecting", this.element[ 0 ] ).each( function() {
			var selectee = $.data( this, "selectable-item" );
			that._removeClass( selectee.$element, "ui-selecting" )
				._addClass( selectee.$element, "ui-selected" );
			selectee.selecting = false;
			selectee.selected = true;
			selectee.startselected = true;
			that._trigger( "selected", event, {
				selected: selectee.element
			} );
		} );
		this._trigger( "stop", event );

		this.helper.remove();

		return false;
	}

} );


/*!
 * jQuery UI Selectmenu 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Selectmenu
//>>group: Widgets
// jscs:disable maximumLineLength
//>>description: Duplicates and extends the functionality of a native HTML select element, allowing it to be customizable in behavior and appearance far beyond the limitations of a native select.
// jscs:enable maximumLineLength
//>>docs: http://api.jqueryui.com/selectmenu/
//>>demos: http://jqueryui.com/selectmenu/
//>>css.structure: ../../themes/base/core.css
//>>css.structure: ../../themes/base/selectmenu.css, ../../themes/base/button.css
//>>css.theme: ../../themes/base/theme.css



var widgetsSelectmenu = $.widget( "ui.selectmenu", [ $.ui.formResetMixin, {
	version: "1.12.1",
	defaultElement: "<select>",
	options: {
		appendTo: null,
		classes: {
			"ui-selectmenu-button-open": "ui-corner-top",
			"ui-selectmenu-button-closed": "ui-corner-all"
		},
		disabled: null,
		icons: {
			button: "ui-icon-triangle-1-s"
		},
		position: {
			my: "left top",
			at: "left bottom",
			collision: "none"
		},
		width: false,

		// Callbacks
		change: null,
		close: null,
		focus: null,
		open: null,
		select: null
	},

	_create: function() {
		var selectmenuId = this.element.uniqueId().attr( "id" );
		this.ids = {
			element: selectmenuId,
			button: selectmenuId + "-button",
			menu: selectmenuId + "-menu"
		};

		this._drawButton();
		this._drawMenu();
		this._bindFormResetHandler();

		this._rendered = false;
		this.menuItems = $();
	},

	_drawButton: function() {
		var icon,
			that = this,
			item = this._parseOption(
				this.element.find( "option:selected" ),
				this.element[ 0 ].selectedIndex
			);

		// Associate existing label with the new button
		this.labels = this.element.labels().attr( "for", this.ids.button );
		this._on( this.labels, {
			click: function( event ) {
				this.button.focus();
				event.preventDefault();
			}
		} );

		// Hide original select element
		this.element.hide();

		// Create button
		this.button = $( "<span>", {
			tabindex: this.options.disabled ? -1 : 0,
			id: this.ids.button,
			role: "combobox",
			"aria-expanded": "false",
			"aria-autocomplete": "list",
			"aria-owns": this.ids.menu,
			"aria-haspopup": "true",
			title: this.element.attr( "title" )
		} )
			.insertAfter( this.element );

		this._addClass( this.button, "ui-selectmenu-button ui-selectmenu-button-closed",
			"ui-button ui-widget" );

		icon = $( "<span>" ).appendTo( this.button );
		this._addClass( icon, "ui-selectmenu-icon", "ui-icon " + this.options.icons.button );
		this.buttonItem = this._renderButtonItem( item )
			.appendTo( this.button );

		if ( this.options.width !== false ) {
			this._resizeButton();
		}

		this._on( this.button, this._buttonEvents );
		this.button.one( "focusin", function() {

			// Delay rendering the menu items until the button receives focus.
			// The menu may have already been rendered via a programmatic open.
			if ( !that._rendered ) {
				that._refreshMenu();
			}
		} );
	},

	_drawMenu: function() {
		var that = this;

		// Create menu
		this.menu = $( "<ul>", {
			"aria-hidden": "true",
			"aria-labelledby": this.ids.button,
			id: this.ids.menu
		} );

		// Wrap menu
		this.menuWrap = $( "<div>" ).append( this.menu );
		this._addClass( this.menuWrap, "ui-selectmenu-menu", "ui-front" );
		this.menuWrap.appendTo( this._appendTo() );

		// Initialize menu widget
		this.menuInstance = this.menu
			.menu( {
				classes: {
					"ui-menu": "ui-corner-bottom"
				},
				role: "listbox",
				select: function( event, ui ) {
					event.preventDefault();

					// Support: IE8
					// If the item was selected via a click, the text selection
					// will be destroyed in IE
					that._setSelection();

					that._select( ui.item.data( "ui-selectmenu-item" ), event );
				},
				focus: function( event, ui ) {
					var item = ui.item.data( "ui-selectmenu-item" );

					// Prevent inital focus from firing and check if its a newly focused item
					if ( that.focusIndex != null && item.index !== that.focusIndex ) {
						that._trigger( "focus", event, { item: item } );
						if ( !that.isOpen ) {
							that._select( item, event );
						}
					}
					that.focusIndex = item.index;

					that.button.attr( "aria-activedescendant",
						that.menuItems.eq( item.index ).attr( "id" ) );
				}
			} )
			.menu( "instance" );

		// Don't close the menu on mouseleave
		this.menuInstance._off( this.menu, "mouseleave" );

		// Cancel the menu's collapseAll on document click
		this.menuInstance._closeOnDocumentClick = function() {
			return false;
		};

		// Selects often contain empty items, but never contain dividers
		this.menuInstance._isDivider = function() {
			return false;
		};
	},

	refresh: function() {
		this._refreshMenu();
		this.buttonItem.replaceWith(
			this.buttonItem = this._renderButtonItem(

				// Fall back to an empty object in case there are no options
				this._getSelectedItem().data( "ui-selectmenu-item" ) || {}
			)
		);
		if ( this.options.width === null ) {
			this._resizeButton();
		}
	},

	_refreshMenu: function() {
		var item,
			options = this.element.find( "option" );

		this.menu.empty();

		this._parseOptions( options );
		this._renderMenu( this.menu, this.items );

		this.menuInstance.refresh();
		this.menuItems = this.menu.find( "li" )
			.not( ".ui-selectmenu-optgroup" )
				.find( ".ui-menu-item-wrapper" );

		this._rendered = true;

		if ( !options.length ) {
			return;
		}

		item = this._getSelectedItem();

		// Update the menu to have the correct item focused
		this.menuInstance.focus( null, item );
		this._setAria( item.data( "ui-selectmenu-item" ) );

		// Set disabled state
		this._setOption( "disabled", this.element.prop( "disabled" ) );
	},

	open: function( event ) {
		if ( this.options.disabled ) {
			return;
		}

		// If this is the first time the menu is being opened, render the items
		if ( !this._rendered ) {
			this._refreshMenu();
		} else {

			// Menu clears focus on close, reset focus to selected item
			this._removeClass( this.menu.find( ".ui-state-active" ), null, "ui-state-active" );
			this.menuInstance.focus( null, this._getSelectedItem() );
		}

		// If there are no options, don't open the menu
		if ( !this.menuItems.length ) {
			return;
		}

		this.isOpen = true;
		this._toggleAttr();
		this._resizeMenu();
		this._position();

		this._on( this.document, this._documentClick );

		this._trigger( "open", event );
	},

	_position: function() {
		this.menuWrap.position( $.extend( { of: this.button }, this.options.position ) );
	},

	close: function( event ) {
		if ( !this.isOpen ) {
			return;
		}

		this.isOpen = false;
		this._toggleAttr();

		this.range = null;
		this._off( this.document );

		this._trigger( "close", event );
	},

	widget: function() {
		return this.button;
	},

	menuWidget: function() {
		return this.menu;
	},

	_renderButtonItem: function( item ) {
		var buttonItem = $( "<span>" );

		this._setText( buttonItem, item.label );
		this._addClass( buttonItem, "ui-selectmenu-text" );

		return buttonItem;
	},

	_renderMenu: function( ul, items ) {
		var that = this,
			currentOptgroup = "";

		$.each( items, function( index, item ) {
			var li;

			if ( item.optgroup !== currentOptgroup ) {
				li = $( "<li>", {
					text: item.optgroup
				} );
				that._addClass( li, "ui-selectmenu-optgroup", "ui-menu-divider" +
					( item.element.parent( "optgroup" ).prop( "disabled" ) ?
						" ui-state-disabled" :
						"" ) );

				li.appendTo( ul );

				currentOptgroup = item.optgroup;
			}

			that._renderItemData( ul, item );
		} );
	},

	_renderItemData: function( ul, item ) {
		return this._renderItem( ul, item ).data( "ui-selectmenu-item", item );
	},

	_renderItem: function( ul, item ) {
		var li = $( "<li>" ),
			wrapper = $( "<div>", {
				title: item.element.attr( "title" )
			} );

		if ( item.disabled ) {
			this._addClass( li, null, "ui-state-disabled" );
		}
		this._setText( wrapper, item.label );

		return li.append( wrapper ).appendTo( ul );
	},

	_setText: function( element, value ) {
		if ( value ) {
			element.text( value );
		} else {
			element.html( "&#160;" );
		}
	},

	_move: function( direction, event ) {
		var item, next,
			filter = ".ui-menu-item";

		if ( this.isOpen ) {
			item = this.menuItems.eq( this.focusIndex ).parent( "li" );
		} else {
			item = this.menuItems.eq( this.element[ 0 ].selectedIndex ).parent( "li" );
			filter += ":not(.ui-state-disabled)";
		}

		if ( direction === "first" || direction === "last" ) {
			next = item[ direction === "first" ? "prevAll" : "nextAll" ]( filter ).eq( -1 );
		} else {
			next = item[ direction + "All" ]( filter ).eq( 0 );
		}

		if ( next.length ) {
			this.menuInstance.focus( event, next );
		}
	},

	_getSelectedItem: function() {
		return this.menuItems.eq( this.element[ 0 ].selectedIndex ).parent( "li" );
	},

	_toggle: function( event ) {
		this[ this.isOpen ? "close" : "open" ]( event );
	},

	_setSelection: function() {
		var selection;

		if ( !this.range ) {
			return;
		}

		if ( window.getSelection ) {
			selection = window.getSelection();
			selection.removeAllRanges();
			selection.addRange( this.range );

		// Support: IE8
		} else {
			this.range.select();
		}

		// Support: IE
		// Setting the text selection kills the button focus in IE, but
		// restoring the focus doesn't kill the selection.
		this.button.focus();
	},

	_documentClick: {
		mousedown: function( event ) {
			if ( !this.isOpen ) {
				return;
			}

			if ( !$( event.target ).closest( ".ui-selectmenu-menu, #" +
					$.ui.escapeSelector( this.ids.button ) ).length ) {
				this.close( event );
			}
		}
	},

	_buttonEvents: {

		// Prevent text selection from being reset when interacting with the selectmenu (#10144)
		mousedown: function() {
			var selection;

			if ( window.getSelection ) {
				selection = window.getSelection();
				if ( selection.rangeCount ) {
					this.range = selection.getRangeAt( 0 );
				}

			// Support: IE8
			} else {
				this.range = document.selection.createRange();
			}
		},

		click: function( event ) {
			this._setSelection();
			this._toggle( event );
		},

		keydown: function( event ) {
			var preventDefault = true;
			switch ( event.keyCode ) {
			case $.ui.keyCode.TAB:
			case $.ui.keyCode.ESCAPE:
				this.close( event );
				preventDefault = false;
				break;
			case $.ui.keyCode.ENTER:
				if ( this.isOpen ) {
					this._selectFocusedItem( event );
				}
				break;
			case $.ui.keyCode.UP:
				if ( event.altKey ) {
					this._toggle( event );
				} else {
					this._move( "prev", event );
				}
				break;
			case $.ui.keyCode.DOWN:
				if ( event.altKey ) {
					this._toggle( event );
				} else {
					this._move( "next", event );
				}
				break;
			case $.ui.keyCode.SPACE:
				if ( this.isOpen ) {
					this._selectFocusedItem( event );
				} else {
					this._toggle( event );
				}
				break;
			case $.ui.keyCode.LEFT:
				this._move( "prev", event );
				break;
			case $.ui.keyCode.RIGHT:
				this._move( "next", event );
				break;
			case $.ui.keyCode.HOME:
			case $.ui.keyCode.PAGE_UP:
				this._move( "first", event );
				break;
			case $.ui.keyCode.END:
			case $.ui.keyCode.PAGE_DOWN:
				this._move( "last", event );
				break;
			default:
				this.menu.trigger( event );
				preventDefault = false;
			}

			if ( preventDefault ) {
				event.preventDefault();
			}
		}
	},

	_selectFocusedItem: function( event ) {
		var item = this.menuItems.eq( this.focusIndex ).parent( "li" );
		if ( !item.hasClass( "ui-state-disabled" ) ) {
			this._select( item.data( "ui-selectmenu-item" ), event );
		}
	},

	_select: function( item, event ) {
		var oldIndex = this.element[ 0 ].selectedIndex;

		// Change native select element
		this.element[ 0 ].selectedIndex = item.index;
		this.buttonItem.replaceWith( this.buttonItem = this._renderButtonItem( item ) );
		this._setAria( item );
		this._trigger( "select", event, { item: item } );

		if ( item.index !== oldIndex ) {
			this._trigger( "change", event, { item: item } );
		}

		this.close( event );
	},

	_setAria: function( item ) {
		var id = this.menuItems.eq( item.index ).attr( "id" );

		this.button.attr( {
			"aria-labelledby": id,
			"aria-activedescendant": id
		} );
		this.menu.attr( "aria-activedescendant", id );
	},

	_setOption: function( key, value ) {
		if ( key === "icons" ) {
			var icon = this.button.find( "span.ui-icon" );
			this._removeClass( icon, null, this.options.icons.button )
				._addClass( icon, null, value.button );
		}

		this._super( key, value );

		if ( key === "appendTo" ) {
			this.menuWrap.appendTo( this._appendTo() );
		}

		if ( key === "width" ) {
			this._resizeButton();
		}
	},

	_setOptionDisabled: function( value ) {
		this._super( value );

		this.menuInstance.option( "disabled", value );
		this.button.attr( "aria-disabled", value );
		this._toggleClass( this.button, null, "ui-state-disabled", value );

		this.element.prop( "disabled", value );
		if ( value ) {
			this.button.attr( "tabindex", -1 );
			this.close();
		} else {
			this.button.attr( "tabindex", 0 );
		}
	},

	_appendTo: function() {
		var element = this.options.appendTo;

		if ( element ) {
			element = element.jquery || element.nodeType ?
				$( element ) :
				this.document.find( element ).eq( 0 );
		}

		if ( !element || !element[ 0 ] ) {
			element = this.element.closest( ".ui-front, dialog" );
		}

		if ( !element.length ) {
			element = this.document[ 0 ].body;
		}

		return element;
	},

	_toggleAttr: function() {
		this.button.attr( "aria-expanded", this.isOpen );

		// We can't use two _toggleClass() calls here, because we need to make sure
		// we always remove classes first and add them second, otherwise if both classes have the
		// same theme class, it will be removed after we add it.
		this._removeClass( this.button, "ui-selectmenu-button-" +
			( this.isOpen ? "closed" : "open" ) )
			._addClass( this.button, "ui-selectmenu-button-" +
				( this.isOpen ? "open" : "closed" ) )
			._toggleClass( this.menuWrap, "ui-selectmenu-open", null, this.isOpen );

		this.menu.attr( "aria-hidden", !this.isOpen );
	},

	_resizeButton: function() {
		var width = this.options.width;

		// For `width: false`, just remove inline style and stop
		if ( width === false ) {
			this.button.css( "width", "" );
			return;
		}

		// For `width: null`, match the width of the original element
		if ( width === null ) {
			width = this.element.show().outerWidth();
			this.element.hide();
		}

		this.button.outerWidth( width );
	},

	_resizeMenu: function() {
		this.menu.outerWidth( Math.max(
			this.button.outerWidth(),

			// Support: IE10
			// IE10 wraps long text (possibly a rounding bug)
			// so we add 1px to avoid the wrapping
			this.menu.width( "" ).outerWidth() + 1
		) );
	},

	_getCreateOptions: function() {
		var options = this._super();

		options.disabled = this.element.prop( "disabled" );

		return options;
	},

	_parseOptions: function( options ) {
		var that = this,
			data = [];
		options.each( function( index, item ) {
			data.push( that._parseOption( $( item ), index ) );
		} );
		this.items = data;
	},

	_parseOption: function( option, index ) {
		var optgroup = option.parent( "optgroup" );

		return {
			element: option,
			index: index,
			value: option.val(),
			label: option.text(),
			optgroup: optgroup.attr( "label" ) || "",
			disabled: optgroup.prop( "disabled" ) || option.prop( "disabled" )
		};
	},

	_destroy: function() {
		this._unbindFormResetHandler();
		this.menuWrap.remove();
		this.button.remove();
		this.element.show();
		this.element.removeUniqueId();
		this.labels.attr( "for", this.ids.element );
	}
} ] );


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

//>>label: Slider
//>>group: Widgets
//>>description: Displays a flexible slider with ranges and accessibility via keyboard.
//>>docs: http://api.jqueryui.com/slider/
//>>demos: http://jqueryui.com/slider/
//>>css.structure: ../../themes/base/core.css
//>>css.structure: ../../themes/base/slider.css
//>>css.theme: ../../themes/base/theme.css



var widgetsSlider = $.widget( "ui.slider", $.ui.mouse, {
	version: "1.12.1",
	widgetEventPrefix: "slide",

	options: {
		animate: false,
		classes: {
			"ui-slider": "ui-corner-all",
			"ui-slider-handle": "ui-corner-all",

			// Note: ui-widget-header isn't the most fittingly semantic framework class for this
			// element, but worked best visually with a variety of themes
			"ui-slider-range": "ui-corner-all ui-widget-header"
		},
		distance: 0,
		max: 100,
		min: 0,
		orientation: "horizontal",
		range: false,
		step: 1,
		value: 0,
		values: null,

		// Callbacks
		change: null,
		slide: null,
		start: null,
		stop: null
	},

	// Number of pages in a slider
	// (how many times can you page up/down to go through the whole range)
	numPages: 5,

	_create: function() {
		this._keySliding = false;
		this._mouseSliding = false;
		this._animateOff = true;
		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 = false;
	},

	_refresh: function() {
		this._createRange();
		this._createHandles();
		this._setupEvents();
		this._refreshValue();
	},

	_createHandles: function() {
		var i, handleCount,
			options = this.options,
			existingHandles = this.element.find( ".ui-slider-handle" ),
			handle = "<span tabindex='0'></span>",
			handles = [];

		handleCount = ( options.values && options.values.length ) || 1;

		if ( existingHandles.length > handleCount ) {
			existingHandles.slice( handleCount ).remove();
			existingHandles = existingHandles.slice( 0, handleCount );
		}

		for ( i = existingHandles.length; i < handleCount; i++ ) {
			handles.push( handle );
		}

		this.handles = existingHandles.add( $( handles.join( "" ) ).appendTo( this.element ) );

		this._addClass( this.handles, "ui-slider-handle", "ui-state-default" );

		this.handle = this.handles.eq( 0 );

		this.handles.each( function( i ) {
			$( this )
				.data( "ui-slider-handle-index", i )
				.attr( "tabIndex", 0 );
		} );
	},

	_createRange: function() {
		var options = this.options;

		if ( options.range ) {
			if ( options.range === true ) {
				if ( !options.values ) {
					options.values = [ this._valueMin(), this._valueMin() ];
				} else if ( options.values.length && options.values.length !== 2 ) {
					options.values = [ options.values[ 0 ], options.values[ 0 ] ];
				} else if ( $.isArray( options.values ) ) {
					options.values = options.values.slice( 0 );
				}
			}

			if ( !this.range || !this.range.length ) {
				this.range = $( "<div>" )
					.appendTo( this.element );

				this._addClass( this.range, "ui-slider-range" );
			} else {
				this._removeClass( this.range, "ui-slider-range-min ui-slider-range-max" );

				// Handle range switching from true to min/max
				this.range.css( {
					"left": "",
					"bottom": ""
				} );
			}
			if ( options.range === "min" || options.range === "max" ) {
				this._addClass( this.range, "ui-slider-range-" + options.range );
			}
		} else {
			if ( 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();
		if ( this.range ) {
			this.range.remove();
		}

		this._mouseDestroy();
	},

	_mouseCapture: function( event ) {
		var position, normValue, distance, closestHandle, index, allowed, offset, mouseOverHandle,
			that = this,
			o = this.options;

		if ( o.disabled ) {
			return false;
		}

		this.elementSize = {
			width: this.element.outerWidth(),
			height: this.element.outerHeight()
		};
		this.elementOffset = this.element.offset();

		position = { x: event.pageX, y: event.pageY };
		normValue = this._normValueFromMouse( position );
		distance = this._valueMax() - this._valueMin() + 1;
		this.handles.each( function( i ) {
			var thisDistance = Math.abs( normValue - that.values( i ) );
			if ( ( distance > thisDistance ) ||
				( distance === thisDistance &&
					( i === that._lastChangedValue || that.values( i ) === o.min ) ) ) {
				distance = thisDistance;
				closestHandle = $( this );
				index = i;
			}
		} );

		allowed = this._start( event, index );
		if ( allowed === false ) {
			return false;
		}
		this._mouseSliding = true;

		this._handleIndex = index;

		this._addClass( closestHandle, null, "ui-state-active" );
		closestHandle.trigger( "focus" );

		offset = closestHandle.offset();
		mouseOverHandle = !$( event.target ).parents().addBack().is( ".ui-slider-handle" );
		this._clickOffset = mouseOverHandle ? { left: 0, top: 0 } : {
			left: event.pageX - offset.left - ( closestHandle.width() / 2 ),
			top: event.pageY - offset.top -
				( closestHandle.height() / 2 ) -
				( parseInt( closestHandle.css( "borderTopWidth" ), 10 ) || 0 ) -
				( parseInt( closestHandle.css( "borderBottomWidth" ), 10 ) || 0 ) +
				( parseInt( closestHandle.css( "marginTop" ), 10 ) || 0 )
		};

		if ( !this.handles.hasClass( "ui-state-hover" ) ) {
			this._slide( event, index, normValue );
		}
		this._animateOff = true;
		return true;
	},

	_mouseStart: function() {
		return true;
	},

	_mouseDrag: function( event ) {
		var position = { x: event.pageX, y: event.pageY },
			normValue = this._normValueFromMouse( position );

		this._slide( event, this._handleIndex, normValue );

		return false;
	},

	_mouseStop: function( event ) {
		this._removeClass( this.handles, null, "ui-state-active" );
		this._mouseSliding = false;

		this._stop( event, this._handleIndex );
		this._change( event, this._handleIndex );

		this._handleIndex = null;
		this._clickOffset = null;
		this._animateOff = false;

		return false;
	},

	_detectOrientation: function() {
		this.orientation = ( this.options.orientation === "vertical" ) ? "vertical" : "horizontal";
	},

	_normValueFromMouse: function( position ) {
		var pixelTotal,
			pixelMouse,
			percentMouse,
			valueTotal,
			valueMouse;

		if ( this.orientation === "horizontal" ) {
			pixelTotal = this.elementSize.width;
			pixelMouse = position.x - this.elementOffset.left -
				( this._clickOffset ? this._clickOffset.left : 0 );
		} else {
			pixelTotal = this.elementSize.height;
			pixelMouse = position.y - this.elementOffset.top -
				( this._clickOffset ? this._clickOffset.top : 0 );
		}

		percentMouse = ( pixelMouse / pixelTotal );
		if ( percentMouse > 1 ) {
			percentMouse = 1;
		}
		if ( percentMouse < 0 ) {
			percentMouse = 0;
		}
		if ( this.orientation === "vertical" ) {
			percentMouse = 1 - percentMouse;
		}

		valueTotal = this._valueMax() - this._valueMin();
		valueMouse = this._valueMin() + percentMouse * valueTotal;

		return this._trimAlignValue( valueMouse );
	},

	_uiHash: function( index, value, values ) {
		var uiHash = {
			handle: this.handles[ index ],
			handleIndex: index,
			value: value !== undefined ? value : this.value()
		};

		if ( this._hasMultipleValues() ) {
			uiHash.value = value !== undefined ? value : this.values( index );
			uiHash.values = values || this.values();
		}

		return uiHash;
	},

	_hasMultipleValues: function() {
		return this.options.values && this.options.values.length;
	},

	_start: function( event, index ) {
		return this._trigger( "start", event, this._uiHash( index ) );
	},

	_slide: function( event, index, newVal ) {
		var allowed, otherVal,
			currentValue = this.value(),
			newValues = this.values();

		if ( this._hasMultipleValues() ) {
			otherVal = this.values( index ? 0 : 1 );
			currentValue = this.values( index );

			if ( this.options.values.length === 2 && this.options.range === true ) {
				newVal =  index === 0 ? Math.min( otherVal, newVal ) : Math.max( otherVal, newVal );
			}

			newValues[ index ] = newVal;
		}

		if ( newVal === currentValue ) {
			return;
		}

		allowed = this._trigger( "slide", event, this._uiHash( index, newVal, newValues ) );

		// A slide can be canceled by returning false from the slide callback
		if ( allowed === false ) {
			return;
		}

		if ( this._hasMultipleValues() ) {
			this.values( index, newVal );
		} else {
			this.value( newVal );
		}
	},

	_stop: function( event, index ) {
		this._trigger( "stop", event, this._uiHash( index ) );
	},

	_change: function( event, index ) {
		if ( !this._keySliding && !this._mouseSliding ) {

			//store the last changed value index for reference when handles overlap
			this._lastChangedValue = index;
			this._trigger( "change", event, this._uiHash( index ) );
		}
	},

	value: function( newValue ) {
		if ( arguments.length ) {
			this.options.value = this._trimAlignValue( newValue );
			this._refreshValue();
			this._change( null, 0 );
			return;
		}

		return this._value();
	},

	values: function( index, newValue ) {
		var vals,
			newValues,
			i;

		if ( arguments.length > 1 ) {
			this.options.values[ index ] = this._trimAlignValue( newValue );
			this._refreshValue();
			this._change( null, index );
			return;
		}

		if ( arguments.length ) {
			if ( $.isArray( arguments[ 0 ] ) ) {
				vals = this.options.values;
				newValues = arguments[ 0 ];
				for ( i = 0; i < vals.length; i += 1 ) {
					vals[ i ] = this._trimAlignValue( newValues[ i ] );
					this._change( null, i );
				}
				this._refreshValue();
			} else {
				if ( this._hasMultipleValues() ) {
					return this._values( index );
				} else {
					return this.value();
				}
			}
		} else {
			return this._values();
		}
	},

	_setOption: function( key, value ) {
		var i,
			valsLength = 0;

		if ( key === "range" && this.options.range === true ) {
			if ( value === "min" ) {
				this.options.value = this._values( 0 );
				this.options.values = null;
			} else if ( value === "max" ) {
				this.options.value = this._values( this.options.values.length - 1 );
				this.options.values = null;
			}
		}

		if ( $.isArray( this.options.values ) ) {
			valsLength = this.options.values.length;
		}

		this._super( key, value );

		switch ( key ) {
			case "orientation":
				this._detectOrientation();
				this._removeClass( "ui-slider-horizontal ui-slider-vertical" )
					._addClass( "ui-slider-" + this.orientation );
				this._refreshValue();
				if ( this.options.range ) {
					this._refreshRange( value );
				}

				// Reset positioning from previous orientation
				this.handles.css( value === "horizontal" ? "bottom" : "left", "" );
				break;
			case "value":
				this._animateOff = true;
				this._refreshValue();
				this._change( null, 0 );
				this._animateOff = false;
				break;
			case "values":
				this._animateOff = true;
				this._refreshValue();

				// Start from the last handle to prevent unreachable handles (#9046)
				for ( i = valsLength - 1; i >= 0; i-- ) {
					this._change( null, i );
				}
				this._animateOff = false;
				break;
			case "step":
			case "min":
			case "max":
				this._animateOff = true;
				this._calculateNewMax();
				this._refreshValue();
				this._animateOff = false;
				break;
			case "range":
				this._animateOff = true;
				this._refresh();
				this._animateOff = false;
				break;
		}
	},

	_setOptionDisabled: function( value ) {
		this._super( value );

		this._toggleClass( null, "ui-state-disabled", !!value );
	},

	//internal value getter
	// _value() returns value trimmed by min and max, aligned by step
	_value: function() {
		var val = this.options.value;
		val = this._trimAlignValue( val );

		return val;
	},

	//internal values getter
	// _values() returns array of values trimmed by min and max, aligned by step
	// _values( index ) returns single value trimmed by min and max, aligned by step
	_values: function( index ) {
		var val,
			vals,
			i;

		if ( arguments.length ) {
			val = this.options.values[ index ];
			val = this._trimAlignValue( val );

			return val;
		} else if ( this._hasMultipleValues() ) {

			// .slice() creates a copy of the array
			// this copy gets trimmed by min and max and then returned
			vals = this.options.values.slice();
			for ( i = 0; i < vals.length; i += 1 ) {
				vals[ i ] = this._trimAlignValue( vals[ i ] );
			}

			return vals;
		} else {
			return [];
		}
	},

	// Returns the step-aligned value that val is closest to, between (inclusive) min and max
	_trimAlignValue: function( val ) {
		if ( val <= this._valueMin() ) {
			return this._valueMin();
		}
		if ( val >= this._valueMax() ) {
			return this._valueMax();
		}
		var step = ( this.options.step > 0 ) ? this.options.step : 1,
			valModStep = ( val - this._valueMin() ) % step,
			alignValue = val - valModStep;

		if ( Math.abs( valModStep ) * 2 >= step ) {
			alignValue += ( valModStep > 0 ) ? step : ( -step );
		}

		// Since JavaScript has problems with large floats, round
		// the final value to 5 digits after the decimal point (see #4124)
		return parseFloat( alignValue.toFixed( 5 ) );
	},

	_calculateNewMax: function() {
		var max = this.options.max,
			min = this._valueMin(),
			step = this.options.step,
			aboveMin = Math.round( ( max - min ) / step ) * step;
		max = aboveMin + min;
		if ( max > this.options.max ) {

			//If max is not divisible by step, rounding off may increase its value
			max -= step;
		}
		this.max = parseFloat( max.toFixed( this._precision() ) );
	},

	_precision: function() {
		var precision = this._precisionOf( this.options.step );
		if ( this.options.min !== null ) {
			precision = Math.max( precision, this._precisionOf( this.options.min ) );
		}
		return precision;
	},

	_precisionOf: function( num ) {
		var str = num.toString(),
			decimal = str.indexOf( "." );
		return decimal === -1 ? 0 : str.length - decimal - 1;
	},

	_valueMin: function() {
		return this.options.min;
	},

	_valueMax: function() {
		return this.max;
	},

	_refreshRange: function( orientation ) {
		if ( orientation === "vertical" ) {
			this.range.css( { "width": "", "left": "" } );
		}
		if ( orientation === "horizontal" ) {
			this.range.css( { "height": "", "bottom": "" } );
		}
	},

	_refreshValue: function() {
		var lastValPercent, valPercent, value, valueMin, valueMax,
			oRange = this.options.range,
			o = this.options,
			that = this,
			animate = ( !this._animateOff ) ? o.animate : false,
			_set = {};

		if ( this._hasMultipleValues() ) {
			this.handles.each( function( i ) {
				valPercent = ( that.values( i ) - that._valueMin() ) / ( that._valueMax() -
					that._valueMin() ) * 100;
				_set[ that.orientation === "horizontal" ? "left" : "bottom" ] = valPercent + "%";
				$( this ).stop( 1, 1 )[ animate ? "animate" : "css" ]( _set, o.animate );
				if ( that.options.range === true ) {
					if ( that.orientation === "horizontal" ) {
						if ( i === 0 ) {
							that.range.stop( 1, 1 )[ animate ? "animate" : "css" ]( {
								left: valPercent + "%"
							}, o.animate );
						}
						if ( i === 1 ) {
							that.range[ animate ? "animate" : "css" ]( {
								width: ( valPercent - lastValPercent ) + "%"
							}, {
								queue: false,
								duration: o.animate
							} );
						}
					} else {
						if ( i === 0 ) {
							that.range.stop( 1, 1 )[ animate ? "animate" : "css" ]( {
								bottom: ( valPercent ) + "%"
							}, o.animate );
						}
						if ( i === 1 ) {
							that.range[ animate ? "animate" : "css" ]( {
								height: ( valPercent - lastValPercent ) + "%"
							}, {
								queue: false,
								duration: o.animate
							} );
						}
					}
				}
				lastValPercent = valPercent;
			} );
		} else {
			value = this.value();
			valueMin = this._valueMin();
			valueMax = this._valueMax();
			valPercent = ( valueMax !== valueMin ) ?
					( value - valueMin ) / ( valueMax - valueMin ) * 100 :
					0;
			_set[ this.orientation === "horizontal" ? "left" : "bottom" ] = valPercent + "%";
			this.handle.stop( 1, 1 )[ animate ? "animate" : "css" ]( _set, o.animate );

			if ( oRange === "min" && this.orientation === "horizontal" ) {
				this.range.stop( 1, 1 )[ animate ? "animate" : "css" ]( {
					width: valPercent + "%"
				}, o.animate );
			}
			if ( oRange === "max" && this.orientation === "horizontal" ) {
				this.range.stop( 1, 1 )[ animate ? "animate" : "css" ]( {
					width: ( 100 - valPercent ) + "%"
				}, o.animate );
			}
			if ( oRange === "min" && this.orientation === "vertical" ) {
				this.range.stop( 1, 1 )[ animate ? "animate" : "css" ]( {
					height: valPercent + "%"
				}, o.animate );
			}
			if ( oRange === "max" && this.orientation === "vertical" ) {
				this.range.stop( 1, 1 )[ animate ? "animate" : "css" ]( {
					height: ( 100 - valPercent ) + "%"
				}, o.animate );
			}
		}
	},

	_handleEvents: {
		keydown: function( event ) {
			var allowed, curVal, newVal, step,
				index = $( event.target ).data( "ui-slider-handle-index" );

			switch ( event.keyCode ) {
				case $.ui.keyCode.HOME:
				case $.ui.keyCode.END:
				case $.ui.keyCode.PAGE_UP:
				case $.ui.keyCode.PAGE_DOWN:
				case $.ui.keyCode.UP:
				case $.ui.keyCode.RIGHT:
				case $.ui.keyCode.DOWN:
				case $.ui.keyCode.LEFT:
					event.preventDefault();
					if ( !this._keySliding ) {
						this._keySliding = true;
						this._addClass( $( event.target ), null, "ui-state-active" );
						allowed = this._start( event, index );
						if ( allowed === false ) {
							return;
						}
					}
					break;
			}

			step = this.options.step;
			if ( this._hasMultipleValues() ) {
				curVal = newVal = this.values( index );
			} else {
				curVal = newVal = this.value();
			}

			switch ( event.keyCode ) {
				case $.ui.keyCode.HOME:
					newVal = this._valueMin();
					break;
				case $.ui.keyCode.END:
					newVal = this._valueMax();
					break;
				case $.ui.keyCode.PAGE_UP:
					newVal = this._trimAlignValue(
						curVal + ( ( this._valueMax() - this._valueMin() ) / this.numPages )
					);
					break;
				case $.ui.keyCode.PAGE_DOWN:
					newVal = this._trimAlignValue(
						curVal - ( ( this._valueMax() - this._valueMin() ) / this.numPages ) );
					break;
				case $.ui.keyCode.UP:
				case $.ui.keyCode.RIGHT:
					if ( curVal === this._valueMax() ) {
						return;
					}
					newVal = this._trimAlignValue( curVal + step );
					break;
				case $.ui.keyCode.DOWN:
				case $.ui.keyCode.LEFT:
					if ( curVal === this._valueMin() ) {
						return;
					}
					newVal = this._trimAlignValue( curVal - step );
					break;
			}

			this._slide( event, index, newVal );
		},
		keyup: function( event ) {
			var index = $( event.target ).data( "ui-slider-handle-index" );

			if ( this._keySliding ) {
				this._keySliding = false;
				this._stop( event, index );
				this._change( event, index );
				this._removeClass( $( event.target ), null, "ui-state-active" );
			}
		}
	}
} );


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

//>>label: Sortable
//>>group: Interactions
//>>description: Enables items in a list to be sorted using the mouse.
//>>docs: http://api.jqueryui.com/sortable/
//>>demos: http://jqueryui.com/sortable/
//>>css.structure: ../../themes/base/sortable.css



var widgetsSortable = $.widget( "ui.sortable", $.ui.mouse, {
	version: "1.12.1",
	widgetEventPrefix: "sort",
	ready: false,
	options: {
		appendTo: "parent",
		axis: false,
		connectWith: false,
		containment: false,
		cursor: "auto",
		cursorAt: false,
		dropOnEmpty: true,
		forcePlaceholderSize: false,
		forceHelperSize: false,
		grid: false,
		handle: false,
		helper: "original",
		items: "> *",
		opacity: false,
		placeholder: false,
		revert: false,
		scroll: true,
		scrollSensitivity: 20,
		scrollSpeed: 20,
		scope: "default",
		tolerance: "intersect",
		zIndex: 1000,

		// Callbacks
		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( x, reference, size ) {
		return ( x >= reference ) && ( x < ( reference + size ) );
	},

	_isFloating: function( item ) {
		return ( /left|right/ ).test( item.css( "float" ) ) ||
			( /inline|table-cell/ ).test( item.css( "display" ) );
	},

	_create: function() {
		this.containerCache = {};
		this._addClass( "ui-sortable" );

		//Get the items
		this.refresh();

		//Let's determine the parent's offset
		this.offset = this.element.offset();

		//Initialize mouse events for interaction
		this._mouseInit();

		this._setHandleClassName();

		//We're ready to go
		this.ready = true;

	},

	_setOption: function( key, value ) {
		this._super( key, value );

		if ( key === "handle" ) {
			this._setHandleClassName();
		}
	},

	_setHandleClassName: function() {
		var that = this;
		this._removeClass( this.element.find( ".ui-sortable-handle" ), "ui-sortable-handle" );
		$.each( this.items, function() {
			that._addClass(
				this.instance.options.handle ?
					this.item.find( this.instance.options.handle ) :
					this.item,
				"ui-sortable-handle"
			);
		} );
	},

	_destroy: function() {
		this._mouseDestroy();

		for ( var i = this.items.length - 1; i >= 0; i-- ) {
			this.items[ i ].item.removeData( this.widgetName + "-item" );
		}

		return this;
	},

	_mouseCapture: function( event, overrideHandle ) {
		var currentItem = null,
			validHandle = false,
			that = this;

		if ( this.reverting ) {
			return false;
		}

		if ( this.options.disabled || this.options.type === "static" ) {
			return false;
		}

		//We have to refresh the items data once first
		this._refreshItems( event );

		//Find out if the clicked node (or one of its parents) is a actual item in this.items
		$( event.target ).parents().each( function() {
			if ( $.data( this, that.widgetName + "-item" ) === that ) {
				currentItem = $( this );
				return false;
			}
		} );
		if ( $.data( event.target, that.widgetName + "-item" ) === that ) {
			currentItem = $( event.target );
		}

		if ( !currentItem ) {
			return false;
		}
		if ( this.options.handle && !overrideHandle ) {
			$( this.options.handle, currentItem ).find( "*" ).addBack().each( function() {
				if ( this === event.target ) {
					validHandle = true;
				}
			} );
			if ( !validHandle ) {
				return false;
			}
		}

		this.currentItem = currentItem;
		this._removeCurrentsFromItems();
		return true;

	},

	_mouseStart: function( event, overrideHandle, noActivation ) {

		var i, body,
			o = this.options;

		this.currentContainer = this;

		//We only need to call refreshPositions, because the refreshItems call has been moved to
		// mouseCapture
		this.refreshPositions();

		//Create and append the visible helper
		this.helper = this._createHelper( event );

		//Cache the helper size
		this._cacheHelperProportions();

		/*
		 * - Position generation -
		 * This block generates everything position related - it's the core of draggables.
		 */

		//Cache the margins of the original element
		this._cacheMargins();

		//Get the next scrolling parent
		this.scrollParent = this.helper.scrollParent();

		//The element's absolute position on the page minus margins
		this.offset = this.currentItem.offset();
		this.offset = {
			top: this.offset.top - this.margins.top,
			left: this.offset.left - this.margins.left
		};

		$.extend( this.offset, {
			click: { //Where the click happened, relative to the element
				left: event.pageX - this.offset.left,
				top: event.pageY - this.offset.top
			},
			parent: this._getParentOffset(),

			// This is a relative to absolute position minus the actual position calculation -
			// only used for relative positioned helper
			relative: this._getRelativeOffset()
		} );

		// Only after we got the offset, we can change the helper's position to absolute
		// TODO: Still need to figure out a way to make relative sorting possible
		this.helper.css( "position", "absolute" );
		this.cssPosition = this.helper.css( "position" );

		//Generate the original position
		this.originalPosition = this._generatePosition( event );
		this.originalPageX = event.pageX;
		this.originalPageY = event.pageY;

		//Adjust the mouse offset relative to the helper if "cursorAt" is supplied
		( o.cursorAt && this._adjustOffsetFromHelper( o.cursorAt ) );

		//Cache the former DOM position
		this.domPosition = {
			prev: this.currentItem.prev()[ 0 ],
			parent: this.currentItem.parent()[ 0 ]
		};

		// If the helper is not the original, hide the original so it's not playing any role during
		// the drag, won't cause anything bad this way
		if ( this.helper[ 0 ] !== this.currentItem[ 0 ] ) {
			this.currentItem.hide();
		}

		//Create the placeholder
		this._createPlaceholder();

		//Set a containment if given in the options
		if ( o.containment ) {
			this._setContainment();
		}

		if ( o.cursor && o.cursor !== "auto" ) { // cursor option
			body = this.document.find( "body" );

			// Support: IE
			this.storedCursor = body.css( "cursor" );
			body.css( "cursor", o.cursor );

			this.storedStylesheet =
				$( "<style>*{ cursor: " + o.cursor + " !important; }</style>" ).appendTo( body );
		}

		if ( o.opacity ) { // opacity option
			if ( this.helper.css( "opacity" ) ) {
				this._storedOpacity = this.helper.css( "opacity" );
			}
			this.helper.css( "opacity", o.opacity );
		}

		if ( o.zIndex ) { // zIndex option
			if ( this.helper.css( "zIndex" ) ) {
				this._storedZIndex = this.helper.css( "zIndex" );
			}
			this.helper.css( "zIndex", o.zIndex );
		}

		//Prepare scrolling
		if ( this.scrollParent[ 0 ] !== this.document[ 0 ] &&
				this.scrollParent[ 0 ].tagName !== "HTML" ) {
			this.overflowOffset = this.scrollParent.offset();
		}

		//Call callbacks
		this._trigger( "start", event, this._uiHash() );

		//Recache the helper size
		if ( !this._preserveHelperProportions ) {
			this._cacheHelperProportions();
		}

		//Post "activate" events to possible containers
		if ( !noActivation ) {
			for ( i = this.containers.length - 1; i >= 0; i-- ) {
				this.containers[ i ]._trigger( "activate", event, this._uiHash( this ) );
			}
		}

		//Prepare possible droppables
		if ( $.ui.ddmanager ) {
			$.ui.ddmanager.current = this;
		}

		if ( $.ui.ddmanager && !o.dropBehaviour ) {
			$.ui.ddmanager.prepareOffsets( this, event );
		}

		this.dragging = true;

		this._addClass( this.helper, "ui-sortable-helper" );

		// Execute the drag once - this causes the helper not to be visiblebefore getting its
		// correct position
		this._mouseDrag( event );
		return true;

	},

	_mouseDrag: function( event ) {
		var i, item, itemElement, intersection,
			o = this.options,
			scrolled = false;

		//Compute the helpers position
		this.position = this._generatePosition( event );
		this.positionAbs = this._convertPositionTo( "absolute" );

		if ( !this.lastPositionAbs ) {
			this.lastPositionAbs = this.positionAbs;
		}

		//Do scrolling
		if ( this.options.scroll ) {
			if ( this.scrollParent[ 0 ] !== this.document[ 0 ] &&
					this.scrollParent[ 0 ].tagName !== "HTML" ) {

				if ( ( this.overflowOffset.top + this.scrollParent[ 0 ].offsetHeight ) -
						event.pageY < o.scrollSensitivity ) {
					this.scrollParent[ 0 ].scrollTop =
						scrolled = this.scrollParent[ 0 ].scrollTop + o.scrollSpeed;
				} else if ( event.pageY - this.overflowOffset.top < o.scrollSensitivity ) {
					this.scrollParent[ 0 ].scrollTop =
						scrolled = this.scrollParent[ 0 ].scrollTop - o.scrollSpeed;
				}

				if ( ( this.overflowOffset.left + this.scrollParent[ 0 ].offsetWidth ) -
						event.pageX < o.scrollSensitivity ) {
					this.scrollParent[ 0 ].scrollLeft = scrolled =
						this.scrollParent[ 0 ].scrollLeft + o.scrollSpeed;
				} else if ( event.pageX - this.overflowOffset.left < o.scrollSensitivity ) {
					this.scrollParent[ 0 ].scrollLeft = scrolled =
						this.scrollParent[ 0 ].scrollLeft - o.scrollSpeed;
				}

			} else {

				if ( event.pageY - this.document.scrollTop() < o.scrollSensitivity ) {
					scrolled = this.document.scrollTop( this.document.scrollTop() - o.scrollSpeed );
				} else if ( this.window.height() - ( event.pageY - this.document.scrollTop() ) <
						o.scrollSensitivity ) {
					scrolled = this.document.scrollTop( this.document.scrollTop() + o.scrollSpeed );
				}

				if ( event.pageX - this.document.scrollLeft() < o.scrollSensitivity ) {
					scrolled = this.document.scrollLeft(
						this.document.scrollLeft() - o.scrollSpeed
					);
				} else if ( this.window.width() - ( event.pageX - this.document.scrollLeft() ) <
						o.scrollSensitivity ) {
					scrolled = this.document.scrollLeft(
						this.document.scrollLeft() + o.scrollSpeed
					);
				}

			}

			if ( scrolled !== false && $.ui.ddmanager && !o.dropBehaviour ) {
				$.ui.ddmanager.prepareOffsets( this, event );
			}
		}

		//Regenerate the absolute position used for position checks
		this.positionAbs = this._convertPositionTo( "absolute" );

		//Set the helper position
		if ( !this.options.axis || this.options.axis !== "y" ) {
			this.helper[ 0 ].style.left = this.position.left + "px";
		}
		if ( !this.options.axis || this.options.axis !== "x" ) {
			this.helper[ 0 ].style.top = this.position.top + "px";
		}

		//Rearrange
		for ( i = this.items.length - 1; i >= 0; i-- ) {

			//Cache variables and intersection, continue if no intersection
			item = this.items[ i ];
			itemElement = item.item[ 0 ];
			intersection = this._intersectsWithPointer( item );
			if ( !intersection ) {
				continue;
			}

			// Only put the placeholder inside the current Container, skip all
			// items from other containers. This works because when moving
			// an item from one container to another the
			// currentContainer is switched before the placeholder is moved.
			//
			// Without this, moving items in "sub-sortables" can cause
			// the placeholder to jitter between the outer and inner container.
			if ( item.instance !== this.currentContainer ) {
				continue;
			}

			// Cannot intersect with itself
			// no useless actions that have been done before
			// no action if the item moved is the parent of the item checked
			if ( itemElement !== this.currentItem[ 0 ] &&
				this.placeholder[ intersection === 1 ? "next" : "prev" ]()[ 0 ] !== itemElement &&
				!$.contains( this.placeholder[ 0 ], itemElement ) &&
				( this.options.type === "semi-dynamic" ?
					!$.contains( this.element[ 0 ], itemElement ) :
					true
				)
			) {

				this.direction = intersection === 1 ? "down" : "up";

				if ( this.options.tolerance === "pointer" || this._intersectsWithSides( item ) ) {
					this._rearrange( event, item );
				} else {
					break;
				}

				this._trigger( "change", event, this._uiHash() );
				break;
			}
		}

		//Post events to containers
		this._contactContainers( event );

		//Interconnect with droppables
		if ( $.ui.ddmanager ) {
			$.ui.ddmanager.drag( this, event );
		}

		//Call callbacks
		this._trigger( "sort", event, this._uiHash() );

		this.lastPositionAbs = this.positionAbs;
		return false;

	},

	_mouseStop: function( event, noPropagation ) {

		if ( !event ) {
			return;
		}

		//If we are using droppables, inform the manager about the drop
		if ( $.ui.ddmanager && !this.options.dropBehaviour ) {
			$.ui.ddmanager.drop( this, event );
		}

		if ( this.options.revert ) {
			var that = this,
				cur = this.placeholder.offset(),
				axis = this.options.axis,
				animation = {};

			if ( !axis || axis === "x" ) {
				animation.left = cur.left - this.offset.parent.left - this.margins.left +
					( this.offsetParent[ 0 ] === this.document[ 0 ].body ?
						0 :
						this.offsetParent[ 0 ].scrollLeft
					);
			}
			if ( !axis || axis === "y" ) {
				animation.top = cur.top - this.offset.parent.top - this.margins.top +
					( this.offsetParent[ 0 ] === this.document[ 0 ].body ?
						0 :
						this.offsetParent[ 0 ].scrollTop
					);
			}
			this.reverting = true;
			$( this.helper ).animate(
				animation,
				parseInt( this.options.revert, 10 ) || 500,
				function() {
					that._clear( event );
				}
			);
		} else {
			this._clear( event, noPropagation );
		}

		return false;

	},

	cancel: function() {

		if ( this.dragging ) {

			this._mouseUp( new $.Event( "mouseup", { target: null } ) );

			if ( this.options.helper === "original" ) {
				this.currentItem.css( this._storedCSS );
				this._removeClass( this.currentItem, "ui-sortable-helper" );
			} else {
				this.currentItem.show();
			}

			//Post deactivating events to containers
			for ( var i = this.containers.length - 1; i >= 0; i-- ) {
				this.containers[ i ]._trigger( "deactivate", null, this._uiHash( this ) );
				if ( this.containers[ i ].containerCache.over ) {
					this.containers[ i ]._trigger( "out", null, this._uiHash( this ) );
					this.containers[ i ].containerCache.over = 0;
				}
			}

		}

		if ( this.placeholder ) {

			//$(this.placeholder[0]).remove(); would have been the jQuery way - unfortunately,
			// it unbinds ALL events from the original node!
			if ( this.placeholder[ 0 ].parentNode ) {
				this.placeholder[ 0 ].parentNode.removeChild( this.placeholder[ 0 ] );
			}
			if ( this.options.helper !== "original" && this.helper &&
					this.helper[ 0 ].parentNode ) {
				this.helper.remove();
			}

			$.extend( this, {
				helper: null,
				dragging: false,
				reverting: false,
				_noFinalSort: null
			} );

			if ( this.domPosition.prev ) {
				$( this.domPosition.prev ).after( this.currentItem );
			} else {
				$( this.domPosition.parent ).prepend( this.currentItem );
			}
		}

		return this;

	},

	serialize: function( o ) {

		var items = this._getItemsAsjQuery( o && o.connected ),
			str = [];
		o = o || {};

		$( items ).each( function() {
			var res = ( $( o.item || this ).attr( o.attribute || "id" ) || "" )
				.match( o.expression || ( /(.+)[\-=_](.+)/ ) );
			if ( res ) {
				str.push(
					( o.key || res[ 1 ] + "[]" ) +
					"=" + ( o.key && o.expression ? res[ 1 ] : res[ 2 ] ) );
			}
		} );

		if ( !str.length && o.key ) {
			str.push( o.key + "=" );
		}

		return str.join( "&" );

	},

	toArray: function( o ) {

		var items = this._getItemsAsjQuery( o && o.connected ),
			ret = [];

		o = o || {};

		items.each( function() {
			ret.push( $( o.item || this ).attr( o.attribute || "id" ) || "" );
		} );
		return ret;

	},

	/* Be careful with the following core functions */
	_intersectsWith: function( item ) {

		var x1 = this.positionAbs.left,
			x2 = x1 + this.helperProportions.width,
			y1 = this.positionAbs.top,
			y2 = y1 + this.helperProportions.height,
			l = item.left,
			r = l + item.width,
			t = item.top,
			b = t + item.height,
			dyClick = this.offset.click.top,
			dxClick = this.offset.click.left,
			isOverElementHeight = ( this.options.axis === "x" ) || ( ( y1 + dyClick ) > t &&
				( y1 + dyClick ) < b ),
			isOverElementWidth = ( this.options.axis === "y" ) || ( ( x1 + dxClick ) > l &&
				( x1 + dxClick ) < r ),
			isOverElement = isOverElementHeight && isOverElementWidth;

		if ( this.options.tolerance === "pointer" ||
			this.options.forcePointerForContainers ||
			( this.options.tolerance !== "pointer" &&
				this.helperProportions[ this.floating ? "width" : "height" ] >
				item[ this.floating ? "width" : "height" ] )
		) {
			return isOverElement;
		} else {

			return ( l < x1 + ( this.helperProportions.width / 2 ) && // Right Half
				x2 - ( this.helperProportions.width / 2 ) < r && // Left Half
				t < y1 + ( this.helperProportions.height / 2 ) && // Bottom Half
				y2 - ( this.helperProportions.height / 2 ) < b ); // Top Half

		}
	},

	_intersectsWithPointer: function( item ) {
		var verticalDirection, horizontalDirection,
			isOverElementHeight = ( this.options.axis === "x" ) ||
				this._isOverAxis(
					this.positionAbs.top + this.offset.click.top, item.top, item.height ),
			isOverElementWidth = ( this.options.axis === "y" ) ||
				this._isOverAxis(
					this.positionAbs.left + this.offset.click.left, item.left, item.width ),
			isOverElement = isOverElementHeight && isOverElementWidth;

		if ( !isOverElement ) {
			return false;
		}

		verticalDirection = this._getDragVerticalDirection();
		horizontalDirection = this._getDragHorizontalDirection();

		return this.floating ?
			( ( horizontalDirection === "right" || verticalDirection === "down" ) ? 2 : 1 )
			: ( verticalDirection && ( verticalDirection === "down" ? 2 : 1 ) );

	},

	_intersectsWithSides: function( item ) {

		var isOverBottomHalf = this._isOverAxis( this.positionAbs.top +
				this.offset.click.top, item.top + ( item.height / 2 ), item.height ),
			isOverRightHalf = this._isOverAxis( this.positionAbs.left +
				this.offset.click.left, item.left + ( item.width / 2 ), item.width ),
			verticalDirection = this._getDragVerticalDirection(),
			horizontalDirection = this._getDragHorizontalDirection();

		if ( this.floating && horizontalDirection ) {
			return ( ( horizontalDirection === "right" && isOverRightHalf ) ||
				( horizontalDirection === "left" && !isOverRightHalf ) );
		} else {
			return verticalDirection && ( ( verticalDirection === "down" && isOverBottomHalf ) ||
				( verticalDirection === "up" && !isOverBottomHalf ) );
		}

	},

	_getDragVerticalDirection: function() {
		var delta = this.positionAbs.top - this.lastPositionAbs.top;
		return delta !== 0 && ( delta > 0 ? "down" : "up" );
	},

	_getDragHorizontalDirection: function() {
		var delta = this.positionAbs.left - this.lastPositionAbs.left;
		return delta !== 0 && ( delta > 0 ? "right" : "left" );
	},

	refresh: function( event ) {
		this._refreshItems( event );
		this._setHandleClassName();
		this.refreshPositions();
		return this;
	},

	_connectWith: function() {
		var options = this.options;
		return options.connectWith.constructor === String ?
			[ options.connectWith ] :
			options.connectWith;
	},

	_getItemsAsjQuery: function( connected ) {

		var i, j, cur, inst,
			items = [],
			queries = [],
			connectWith = this._connectWith();

		if ( connectWith && connected ) {
			for ( i = connectWith.length - 1; i >= 0; i-- ) {
				cur = $( connectWith[ i ], this.document[ 0 ] );
				for ( j = cur.length - 1; j >= 0; j-- ) {
					inst = $.data( cur[ j ], this.widgetFullName );
					if ( inst && inst !== this && !inst.options.disabled ) {
						queries.push( [ $.isFunction( inst.options.items ) ?
							inst.options.items.call( inst.element ) :
							$( inst.options.items, inst.element )
								.not( ".ui-sortable-helper" )
								.not( ".ui-sortable-placeholder" ), inst ] );
					}
				}
			}
		}

		queries.push( [ $.isFunction( this.options.items ) ?
			this.options.items
				.call( this.element, null, { options: this.options, item: this.currentItem } ) :
			$( this.options.items, this.element )
				.not( ".ui-sortable-helper" )
				.not( ".ui-sortable-placeholder" ), this ] );

		function addItems() {
			items.push( this );
		}
		for ( i = queries.length - 1; i >= 0; i-- ) {
			queries[ i ][ 0 ].each( addItems );
		}

		return $( items );

	},

	_removeCurrentsFromItems: function() {

		var list = this.currentItem.find( ":data(" + this.widgetName + "-item)" );

		this.items = $.grep( this.items, function( item ) {
			for ( var j = 0; j < list.length; j++ ) {
				if ( list[ j ] === item.item[ 0 ] ) {
					return false;
				}
			}
			return true;
		} );

	},

	_refreshItems: function( event ) {

		this.items = [];
		this.containers = [ this ];

		var i, j, cur, inst, targetData, _queries, item, queriesLength,
			items = this.items,
			queries = [ [ $.isFunction( this.options.items ) ?
				this.options.items.call( this.element[ 0 ], event, { item: this.currentItem } ) :
				$( this.options.items, this.element ), this ] ],
			connectWith = this._connectWith();

		//Shouldn't be run the first time through due to massive slow-down
		if ( connectWith && this.ready ) {
			for ( i = connectWith.length - 1; i >= 0; i-- ) {
				cur = $( connectWith[ i ], this.document[ 0 ] );
				for ( j = cur.length - 1; j >= 0; j-- ) {
					inst = $.data( cur[ j ], this.widgetFullName );
					if ( inst && inst !== this && !inst.options.disabled ) {
						queries.push( [ $.isFunction( inst.options.items ) ?
							inst.options.items
								.call( inst.element[ 0 ], event, { item: this.currentItem } ) :
							$( inst.options.items, inst.element ), inst ] );
						this.containers.push( inst );
					}
				}
			}
		}

		for ( i = queries.length - 1; i >= 0; i-- ) {
			targetData = queries[ i ][ 1 ];
			_queries = queries[ i ][ 0 ];

			for ( j = 0, queriesLength = _queries.length; j < queriesLength; j++ ) {
				item = $( _queries[ j ] );

				// Data for target checking (mouse manager)
				item.data( this.widgetName + "-item", targetData );

				items.push( {
					item: item,
					instance: targetData,
					width: 0, height: 0,
					left: 0, top: 0
				} );
			}
		}

	},

	refreshPositions: function( fast ) {

		// Determine whether items are being displayed horizontally
		this.floating = this.items.length ?
			this.options.axis === "x" || this._isFloating( this.items[ 0 ].item ) :
			false;

		//This has to be redone because due to the item being moved out/into the offsetParent,
		// the offsetParent's position will change
		if ( this.offsetParent && this.helper ) {
			this.offset.parent = this._getParentOffset();
		}

		var i, item, t, p;

		for ( i = this.items.length - 1; i >= 0; i-- ) {
			item = this.items[ i ];

			//We ignore calculating positions of all connected containers when we're not over them
			if ( item.instance !== this.currentContainer && this.currentContainer &&
					item.item[ 0 ] !== this.currentItem[ 0 ] ) {
				continue;
			}

			t = this.options.toleranceElement ?
				$( this.options.toleranceElement, item.item ) :
				item.item;

			if ( !fast ) {
				item.width = t.outerWidth();
				item.height = t.outerHeight();
			}

			p = t.offset();
			item.left = p.left;
			item.top = p.top;
		}

		if ( this.options.custom && this.options.custom.refreshContainers ) {
			this.options.custom.refreshContainers.call( this );
		} else {
			for ( i = this.containers.length - 1; i >= 0; i-- ) {
				p = this.containers[ i ].element.offset();
				this.containers[ i ].containerCache.left = p.left;
				this.containers[ i ].containerCache.top = p.top;
				this.containers[ i ].containerCache.width =
					this.containers[ i ].element.outerWidth();
				this.containers[ i ].containerCache.height =
					this.containers[ i ].element.outerHeight();
			}
		}

		return this;
	},

	_createPlaceholder: function( that ) {
		that = that || this;
		var className,
			o = that.options;

		if ( !o.placeholder || o.placeholder.constructor === String ) {
			className = o.placeholder;
			o.placeholder = {
				element: function() {

					var nodeName = that.currentItem[ 0 ].nodeName.toLowerCase(),
						element = $( "<" + nodeName + ">", that.document[ 0 ] );

						that._addClass( element, "ui-sortable-placeholder",
								className || that.currentItem[ 0 ].className )
							._removeClass( element, "ui-sortable-helper" );

					if ( nodeName === "tbody" ) {
						that._createTrPlaceholder(
							that.currentItem.find( "tr" ).eq( 0 ),
							$( "<tr>", that.document[ 0 ] ).appendTo( element )
						);
					} else if ( nodeName === "tr" ) {
						that._createTrPlaceholder( that.currentItem, element );
					} else if ( nodeName === "img" ) {
						element.attr( "src", that.currentItem.attr( "src" ) );
					}

					if ( !className ) {
						element.css( "visibility", "hidden" );
					}

					return element;
				},
				update: function( container, p ) {

					// 1. If a className is set as 'placeholder option, we don't force sizes -
					// the class is responsible for that
					// 2. The option 'forcePlaceholderSize can be enabled to force it even if a
					// class name is specified
					if ( className && !o.forcePlaceholderSize ) {
						return;
					}

					//If the element doesn't have a actual height by itself (without styles coming
					// from a stylesheet), it receives the inline height from the dragged item
					if ( !p.height() ) {
						p.height(
							that.currentItem.innerHeight() -
							parseInt( that.currentItem.css( "paddingTop" ) || 0, 10 ) -
							parseInt( that.currentItem.css( "paddingBottom" ) || 0, 10 ) );
					}
					if ( !p.width() ) {
						p.width(
							that.currentItem.innerWidth() -
							parseInt( that.currentItem.css( "paddingLeft" ) || 0, 10 ) -
							parseInt( that.currentItem.css( "paddingRight" ) || 0, 10 ) );
					}
				}
			};
		}

		//Create the placeholder
		that.placeholder = $( o.placeholder.element.call( that.element, that.currentItem ) );

		//Append it after the actual current item
		that.currentItem.after( that.placeholder );

		//Update the size of the placeholder (TODO: Logic to fuzzy, see line 316/317)
		o.placeholder.update( that, that.placeholder );

	},

	_createTrPlaceholder: function( sourceTr, targetTr ) {
		var that = this;

		sourceTr.children().each( function() {
			$( "<td>&#160;</td>", that.document[ 0 ] )
				.attr( "colspan", $( this ).attr( "colspan" ) || 1 )
				.appendTo( targetTr );
		} );
	},

	_contactContainers: function( event ) {
		var i, j, dist, itemWithLeastDistance, posProperty, sizeProperty, cur, nearBottom,
			floating, axis,
			innermostContainer = null,
			innermostIndex = null;

		// Get innermost container that intersects with item
		for ( i = this.containers.length - 1; i >= 0; i-- ) {

			// Never consider a container that's located within the item itself
			if ( $.contains( this.currentItem[ 0 ], this.containers[ i ].element[ 0 ] ) ) {
				continue;
			}

			if ( this._intersectsWith( this.containers[ i ].containerCache ) ) {

				// If we've already found a container and it's more "inner" than this, then continue
				if ( innermostContainer &&
						$.contains(
							this.containers[ i ].element[ 0 ],
							innermostContainer.element[ 0 ] ) ) {
					continue;
				}

				innermostContainer = this.containers[ i ];
				innermostIndex = i;

			} else {

				// container doesn't intersect. trigger "out" event if necessary
				if ( this.containers[ i ].containerCache.over ) {
					this.containers[ i ]._trigger( "out", event, this._uiHash( this ) );
					this.containers[ i ].containerCache.over = 0;
				}
			}

		}

		// If no intersecting containers found, return
		if ( !innermostContainer ) {
			return;
		}

		// Move the item into the container if it's not there already
		if ( this.containers.length === 1 ) {
			if ( !this.containers[ innermostIndex ].containerCache.over ) {
				this.containers[ innermostIndex ]._trigger( "over", event, this._uiHash( this ) );
				this.containers[ innermostIndex ].containerCache.over = 1;
			}
		} else {

			// When entering a new container, we will find the item with the least distance and
			// append our item near it
			dist = 10000;
			itemWithLeastDistance = null;
			floating = innermostContainer.floating || this._isFloating( this.currentItem );
			posProperty = floating ? "left" : "top";
			sizeProperty = floating ? "width" : "height";
			axis = floating ? "pageX" : "pageY";

			for ( j = this.items.length - 1; j >= 0; j-- ) {
				if ( !$.contains(
						this.containers[ innermostIndex ].element[ 0 ], this.items[ j ].item[ 0 ] )
				) {
					continue;
				}
				if ( this.items[ j ].item[ 0 ] === this.currentItem[ 0 ] ) {
					continue;
				}

				cur = this.items[ j ].item.offset()[ posProperty ];
				nearBottom = false;
				if ( event[ axis ] - cur > this.items[ j ][ sizeProperty ] / 2 ) {
					nearBottom = true;
				}

				if ( Math.abs( event[ axis ] - cur ) < dist ) {
					dist = Math.abs( event[ axis ] - cur );
					itemWithLeastDistance = this.items[ j ];
					this.direction = nearBottom ? "up" : "down";
				}
			}

			//Check if dropOnEmpty is enabled
			if ( !itemWithLeastDistance && !this.options.dropOnEmpty ) {
				return;
			}

			if ( this.currentContainer === this.containers[ innermostIndex ] ) {
				if ( !this.currentContainer.containerCache.over ) {
					this.containers[ innermostIndex ]._trigger( "over", event, this._uiHash() );
					this.currentContainer.containerCache.over = 1;
				}
				return;
			}

			itemWithLeastDistance ?
				this._rearrange( event, itemWithLeastDistance, null, true ) :
				this._rearrange( event, null, this.containers[ innermostIndex ].element, true );
			this._trigger( "change", event, this._uiHash() );
			this.containers[ innermostIndex ]._trigger( "change", event, this._uiHash( this ) );
			this.currentContainer = this.containers[ innermostIndex ];

			//Update the placeholder
			this.options.placeholder.update( this.currentContainer, this.placeholder );

			this.containers[ innermostIndex ]._trigger( "over", event, this._uiHash( this ) );
			this.containers[ innermostIndex ].containerCache.over = 1;
		}

	},

	_createHelper: function( event ) {

		var o = this.options,
			helper = $.isFunction( o.helper ) ?
				$( o.helper.apply( this.element[ 0 ], [ event, this.currentItem ] ) ) :
				( o.helper === "clone" ? this.currentItem.clone() : this.currentItem );

		//Add the helper to the DOM if that didn't happen already
		if ( !helper.parents( "body" ).length ) {
			$( o.appendTo !== "parent" ?
				o.appendTo :
				this.currentItem[ 0 ].parentNode )[ 0 ].appendChild( helper[ 0 ] );
		}

		if ( helper[ 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" )
			};
		}

		if ( !helper[ 0 ].style.width || o.forceHelperSize ) {
			helper.width( this.currentItem.width() );
		}
		if ( !helper[ 0 ].style.height || o.forceHelperSize ) {
			helper.height( this.currentItem.height() );
		}

		return helper;

	},

	_adjustOffsetFromHelper: function( obj ) {
		if ( typeof obj === "string" ) {
			obj = obj.split( " " );
		}
		if ( $.isArray( obj ) ) {
			obj = { left: +obj[ 0 ], top: +obj[ 1 ] || 0 };
		}
		if ( "left" in obj ) {
			this.offset.click.left = obj.left + this.margins.left;
		}
		if ( "right" in obj ) {
			this.offset.click.left = this.helperProportions.width - obj.right + this.margins.left;
		}
		if ( "top" in obj ) {
			this.offset.click.top = obj.top + this.margins.top;
		}
		if ( "bottom" in obj ) {
			this.offset.click.top = this.helperProportions.height - obj.bottom + this.margins.top;
		}
	},

	_getParentOffset: function() {

		//Get the offsetParent and cache its position
		this.offsetParent = this.helper.offsetParent();
		var po = this.offsetParent.offset();

		// This is a special case where we need to modify a offset calculated on start, since the
		// following happened:
		// 1. The position of the helper is absolute, so it's position is calculated based on the
		// next positioned parent
		// 2. The actual offset parent is a child of the scroll parent, and the scroll parent isn't
		// the document, which means that the scroll is included in the initial calculation of the
		// offset of the parent, and never recalculated upon drag
		if ( this.cssPosition === "absolute" && this.scrollParent[ 0 ] !== this.document[ 0 ] &&
				$.contains( this.scrollParent[ 0 ], this.offsetParent[ 0 ] ) ) {
			po.left += this.scrollParent.scrollLeft();
			po.top += this.scrollParent.scrollTop();
		}

		// This needs to be actually done for all browsers, since pageX/pageY includes this
		// information with an ugly IE fix
		if ( this.offsetParent[ 0 ] === this.document[ 0 ].body ||
				( this.offsetParent[ 0 ].tagName &&
				this.offsetParent[ 0 ].tagName.toLowerCase() === "html" && $.ui.ie ) ) {
			po = { top: 0, left: 0 };
		}

		return {
			top: po.top + ( parseInt( this.offsetParent.css( "borderTopWidth" ), 10 ) || 0 ),
			left: po.left + ( parseInt( this.offsetParent.css( "borderLeftWidth" ), 10 ) || 0 )
		};

	},

	_getRelativeOffset: function() {

		if ( this.cssPosition === "relative" ) {
			var p = this.currentItem.position();
			return {
				top: p.top - ( parseInt( this.helper.css( "top" ), 10 ) || 0 ) +
					this.scrollParent.scrollTop(),
				left: p.left - ( parseInt( this.helper.css( "left" ), 10 ) || 0 ) +
					this.scrollParent.scrollLeft()
			};
		} else {
			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 ce, co, over,
			o = this.options;
		if ( o.containment === "parent" ) {
			o.containment = this.helper[ 0 ].parentNode;
		}
		if ( o.containment === "document" || o.containment === "window" ) {
			this.containment = [
				0 - this.offset.relative.left - this.offset.parent.left,
				0 - this.offset.relative.top - this.offset.parent.top,
				o.containment === "document" ?
					this.document.width() :
					this.window.width() - this.helperProportions.width - this.margins.left,
				( o.containment === "document" ?
					( 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( o.containment ) ) {
			ce = $( o.containment )[ 0 ];
			co = $( o.containment ).offset();
			over = ( $( ce ).css( "overflow" ) !== "hidden" );

			this.containment = [
				co.left + ( parseInt( $( ce ).css( "borderLeftWidth" ), 10 ) || 0 ) +
					( parseInt( $( ce ).css( "paddingLeft" ), 10 ) || 0 ) - this.margins.left,
				co.top + ( parseInt( $( ce ).css( "borderTopWidth" ), 10 ) || 0 ) +
					( parseInt( $( ce ).css( "paddingTop" ), 10 ) || 0 ) - this.margins.top,
				co.left + ( over ? Math.max( ce.scrollWidth, ce.offsetWidth ) : ce.offsetWidth ) -
					( parseInt( $( ce ).css( "borderLeftWidth" ), 10 ) || 0 ) -
					( parseInt( $( ce ).css( "paddingRight" ), 10 ) || 0 ) -
					this.helperProportions.width - this.margins.left,
				co.top + ( over ? Math.max( ce.scrollHeight, ce.offsetHeight ) : ce.offsetHeight ) -
					( parseInt( $( ce ).css( "borderTopWidth" ), 10 ) || 0 ) -
					( parseInt( $( ce ).css( "paddingBottom" ), 10 ) || 0 ) -
					this.helperProportions.height - this.margins.top
			];
		}

	},

	_convertPositionTo: function( d, pos ) {

		if ( !pos ) {
			pos = this.position;
		}
		var mod = d === "absolute" ? 1 : -1,
			scroll = this.cssPosition === "absolute" &&
				!( this.scrollParent[ 0 ] !== this.document[ 0 ] &&
				$.contains( this.scrollParent[ 0 ], this.offsetParent[ 0 ] ) ) ?
					this.offsetParent :
					this.scrollParent,
			scrollIsRootNode = ( /(html|body)/i ).test( scroll[ 0 ].tagName );

		return {
			top: (

				// The absolute mouse position
				pos.top	+

				// Only for relative positioned nodes: Relative offset from element to offset parent
				this.offset.relative.top * mod +

				// The offsetParent's offset without borders (offset + border)
				this.offset.parent.top * mod -
				( ( this.cssPosition === "fixed" ?
					-this.scrollParent.scrollTop() :
					( scrollIsRootNode ? 0 : scroll.scrollTop() ) ) * mod )
			),
			left: (

				// The absolute mouse position
				pos.left +

				// Only for relative positioned nodes: Relative offset from element to offset parent
				this.offset.relative.left * mod +

				// The offsetParent's offset without borders (offset + border)
				this.offset.parent.left * mod	-
				( ( this.cssPosition === "fixed" ?
					-this.scrollParent.scrollLeft() : scrollIsRootNode ? 0 :
					scroll.scrollLeft() ) * mod )
			)
		};

	},

	_generatePosition: function( event ) {

		var top, left,
			o = this.options,
			pageX = event.pageX,
			pageY = event.pageY,
			scroll = this.cssPosition === "absolute" &&
				!( this.scrollParent[ 0 ] !== this.document[ 0 ] &&
				$.contains( this.scrollParent[ 0 ], this.offsetParent[ 0 ] ) ) ?
					this.offsetParent :
					this.scrollParent,
				scrollIsRootNode = ( /(html|body)/i ).test( scroll[ 0 ].tagName );

		// This is another very weird special case that only happens for relative elements:
		// 1. If the css position is relative
		// 2. and the scroll parent is the document or similar to the offset parent
		// we have to refresh the relative offset during the scroll so there are no jumps
		if ( this.cssPosition === "relative" && !( this.scrollParent[ 0 ] !== this.document[ 0 ] &&
				this.scrollParent[ 0 ] !== this.offsetParent[ 0 ] ) ) {
			this.offset.relative = this._getRelativeOffset();
		}

		/*
		 * - Position constraining -
		 * Constrain the position to a mix of grid, containment.
		 */

		if ( this.originalPosition ) { //If we are not dragging yet, we won't check for options

			if ( this.containment ) {
				if ( event.pageX - this.offset.click.left < this.containment[ 0 ] ) {
					pageX = this.containment[ 0 ] + this.offset.click.left;
				}
				if ( event.pageY - this.offset.click.top < this.containment[ 1 ] ) {
					pageY = this.containment[ 1 ] + this.offset.click.top;
				}
				if ( event.pageX - this.offset.click.left > this.containment[ 2 ] ) {
					pageX = this.containment[ 2 ] + this.offset.click.left;
				}
				if ( event.pageY - this.offset.click.top > this.containment[ 3 ] ) {
					pageY = this.containment[ 3 ] + this.offset.click.top;
				}
			}

			if ( o.grid ) {
				top = this.originalPageY + Math.round( ( pageY - this.originalPageY ) /
					o.grid[ 1 ] ) * o.grid[ 1 ];
				pageY = this.containment ?
					( ( top - this.offset.click.top >= this.containment[ 1 ] &&
						top - this.offset.click.top <= this.containment[ 3 ] ) ?
							top :
							( ( top - this.offset.click.top >= this.containment[ 1 ] ) ?
								top - o.grid[ 1 ] : top + o.grid[ 1 ] ) ) :
								top;

				left = this.originalPageX + Math.round( ( pageX - this.originalPageX ) /
					o.grid[ 0 ] ) * o.grid[ 0 ];
				pageX = this.containment ?
					( ( left - this.offset.click.left >= this.containment[ 0 ] &&
						left - this.offset.click.left <= this.containment[ 2 ] ) ?
							left :
							( ( left - this.offset.click.left >= this.containment[ 0 ] ) ?
								left - o.grid[ 0 ] : left + o.grid[ 0 ] ) ) :
								left;
			}

		}

		return {
			top: (

				// The absolute mouse position
				pageY -

				// Click offset (relative to the element)
				this.offset.click.top -

				// Only for relative positioned nodes: Relative offset from element to offset parent
				this.offset.relative.top -

				// The offsetParent's offset without borders (offset + border)
				this.offset.parent.top +
				( ( this.cssPosition === "fixed" ?
					-this.scrollParent.scrollTop() :
					( scrollIsRootNode ? 0 : scroll.scrollTop() ) ) )
			),
			left: (

				// The absolute mouse position
				pageX -

				// Click offset (relative to the element)
				this.offset.click.left -

				// Only for relative positioned nodes: Relative offset from element to offset parent
				this.offset.relative.left -

				// The offsetParent's offset without borders (offset + border)
				this.offset.parent.left +
				( ( this.cssPosition === "fixed" ?
					-this.scrollParent.scrollLeft() :
					scrollIsRootNode ? 0 : scroll.scrollLeft() ) )
			)
		};

	},

	_rearrange: function( event, i, a, hardRefresh ) {

		a ? a[ 0 ].appendChild( this.placeholder[ 0 ] ) :
			i.item[ 0 ].parentNode.insertBefore( this.placeholder[ 0 ],
				( this.direction === "down" ? i.item[ 0 ] : i.item[ 0 ].nextSibling ) );

		//Various things done here to improve the performance:
		// 1. we create a setTimeout, that calls refreshPositions
		// 2. on the instance, we have a counter variable, that get's higher after every append
		// 3. on the local scope, we copy the counter variable, and check in the timeout,
		// if it's still the same
		// 4. this lets only the last addition to the timeout stack through
		this.counter = this.counter ? ++this.counter : 1;
		var counter = this.counter;

		this._delay( function() {
			if ( counter === this.counter ) {

				//Precompute after each DOM insertion, NOT on mousemove
				this.refreshPositions( !hardRefresh );
			}
		} );

	},

	_clear: function( event, noPropagation ) {

		this.reverting = false;

		// We delay all events that have to be triggered to after the point where the placeholder
		// has been removed and everything else normalized again
		var i,
			delayedTriggers = [];

		// We first have to update the dom position of the actual currentItem
		// Note: don't do it if the current item is already removed (by a user), or it gets
		// reappended (see #4088)
		if ( !this._noFinalSort && this.currentItem.parent().length ) {
			this.placeholder.before( this.currentItem );
		}
		this._noFinalSort = null;

		if ( this.helper[ 0 ] === this.currentItem[ 0 ] ) {
			for ( i in this._storedCSS ) {
				if ( this._storedCSS[ i ] === "auto" || this._storedCSS[ i ] === "static" ) {
					this._storedCSS[ i ] = "";
				}
			}
			this.currentItem.css( this._storedCSS );
			this._removeClass( this.currentItem, "ui-sortable-helper" );
		} else {
			this.currentItem.show();
		}

		if ( this.fromOutside && !noPropagation ) {
			delayedTriggers.push( function( event ) {
				this._trigger( "receive", event, this._uiHash( this.fromOutside ) );
			} );
		}
		if ( ( this.fromOutside ||
				this.domPosition.prev !==
				this.currentItem.prev().not( ".ui-sortable-helper" )[ 0 ] ||
				this.domPosition.parent !== this.currentItem.parent()[ 0 ] ) && !noPropagation ) {

			// Trigger update callback if the DOM position has changed
			delayedTriggers.push( function( event ) {
				this._trigger( "update", event, this._uiHash() );
			} );
		}

		// Check if the items Container has Changed and trigger appropriate
		// events.
		if ( this !== this.currentContainer ) {
			if ( !noPropagation ) {
				delayedTriggers.push( function( event ) {
					this._trigger( "remove", event, this._uiHash() );
				} );
				delayedTriggers.push( ( function( c ) {
					return function( event ) {
						c._trigger( "receive", event, this._uiHash( this ) );
					};
				} ).call( this, this.currentContainer ) );
				delayedTriggers.push( ( function( c ) {
					return function( event ) {
						c._trigger( "update", event, this._uiHash( this ) );
					};
				} ).call( this, this.currentContainer ) );
			}
		}

		//Post events to containers
		function delayEvent( type, instance, container ) {
			return function( event ) {
				container._trigger( type, event, instance._uiHash( instance ) );
			};
		}
		for ( i = this.containers.length - 1; i >= 0; i-- ) {
			if ( !noPropagation ) {
				delayedTriggers.push( delayEvent( "deactivate", this, this.containers[ i ] ) );
			}
			if ( this.containers[ i ].containerCache.over ) {
				delayedTriggers.push( delayEvent( "out", this, this.containers[ i ] ) );
				this.containers[ i ].containerCache.over = 0;
			}
		}

		//Do what was originally in plugins
		if ( this.storedCursor ) {
			this.document.find( "body" ).css( "cursor", this.storedCursor );
			this.storedStylesheet.remove();
		}
		if ( this._storedOpacity ) {
			this.helper.css( "opacity", this._storedOpacity );
		}
		if ( this._storedZIndex ) {
			this.helper.css( "zIndex", this._storedZIndex === "auto" ? "" : this._storedZIndex );
		}

		this.dragging = false;

		if ( !noPropagation ) {
			this._trigger( "beforeStop", event, this._uiHash() );
		}

		//$(this.placeholder[0]).remove(); would have been the jQuery way - unfortunately,
		// it unbinds ALL events from the original node!
		this.placeholder[ 0 ].parentNode.removeChild( this.placeholder[ 0 ] );

		if ( !this.cancelHelperRemoval ) {
			if ( this.helper[ 0 ] !== this.currentItem[ 0 ] ) {
				this.helper.remove();
			}
			this.helper = null;
		}

		if ( !noPropagation ) {
			for ( i = 0; i < delayedTriggers.length; i++ ) {

				// Trigger all delayed events
				delayedTriggers[ i ].call( this, event );
			}
			this._trigger( "stop", event, this._uiHash() );
		}

		this.fromOutside = false;
		return !this.cancelHelperRemoval;

	},

	_trigger: function() {
		if ( $.Widget.prototype._trigger.apply( this, arguments ) === false ) {
			this.cancel();
		}
	},

	_uiHash: function( _inst ) {
		var inst = _inst || this;
		return {
			helper: inst.helper,
			placeholder: inst.placeholder || $( [] ),
			position: inst.position,
			originalPosition: inst.originalPosition,
			offset: inst.positionAbs,
			item: inst.currentItem,
			sender: _inst ? _inst.element : null
		};
	}

} );


/*!
 * jQuery UI Spinner 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Spinner
//>>group: Widgets
//>>description: Displays buttons to easily input numbers via the keyboard or mouse.
//>>docs: http://api.jqueryui.com/spinner/
//>>demos: http://jqueryui.com/spinner/
//>>css.structure: ../../themes/base/core.css
//>>css.structure: ../../themes/base/spinner.css
//>>css.theme: ../../themes/base/theme.css



function spinnerModifer( fn ) {
	return function() {
		var previous = this.element.val();
		fn.apply( this, arguments );
		this._refresh();
		if ( previous !== this.element.val() ) {
			this._trigger( "change" );
		}
	};
}

$.widget( "ui.spinner", {
	version: "1.12.1",
	defaultElement: "<input>",
	widgetEventPrefix: "spin",
	options: {
		classes: {
			"ui-spinner": "ui-corner-all",
			"ui-spinner-down": "ui-corner-br",
			"ui-spinner-up": "ui-corner-tr"
		},
		culture: null,
		icons: {
			down: "ui-icon-triangle-1-s",
			up: "ui-icon-triangle-1-n"
		},
		incremental: true,
		max: null,
		min: null,
		numberFormat: null,
		page: 10,
		step: 1,

		change: null,
		spin: null,
		start: null,
		stop: null
	},

	_create: function() {

		// handle string values that need to be parsed
		this._setOption( "max", this.options.max );
		this._setOption( "min", this.options.min );
		this._setOption( "step", this.options.step );

		// Only format if there is a value, prevents the field from being marked
		// as invalid in Firefox, see #9573.
		if ( this.value() !== "" ) {

			// Format the value, but don't constrain.
			this._value( this.element.val(), true );
		}

		this._draw();
		this._on( this._events );
		this._refresh();

		// Turning off autocomplete prevents the browser from remembering the
		// value when navigating through history, so we re-enable autocomplete
		// if the page is unloaded before the widget is destroyed. #7790
		this._on( this.window, {
			beforeunload: function() {
				this.element.removeAttr( "autocomplete" );
			}
		} );
	},

	_getCreateOptions: function() {
		var options = this._super();
		var element = this.element;

		$.each( [ "min", "max", "step" ], function( i, option ) {
			var value = element.attr( option );
			if ( value != null && value.length ) {
				options[ option ] = value;
			}
		} );

		return options;
	},

	_events: {
		keydown: function( event ) {
			if ( this._start( event ) && this._keydown( event ) ) {
				event.preventDefault();
			}
		},
		keyup: "_stop",
		focus: function() {
			this.previous = this.element.val();
		},
		blur: function( event ) {
			if ( this.cancelBlur ) {
				delete this.cancelBlur;
				return;
			}

			this._stop();
			this._refresh();
			if ( this.previous !== this.element.val() ) {
				this._trigger( "change", event );
			}
		},
		mousewheel: function( event, delta ) {
			if ( !delta ) {
				return;
			}
			if ( !this.spinning && !this._start( event ) ) {
				return false;
			}

			this._spin( ( delta > 0 ? 1 : -1 ) * this.options.step, event );
			clearTimeout( this.mousewheelTimer );
			this.mousewheelTimer = this._delay( function() {
				if ( this.spinning ) {
					this._stop( event );
				}
			}, 100 );
			event.preventDefault();
		},
		"mousedown .ui-spinner-button": function( event ) {
			var previous;

			// We never want the buttons to have focus; whenever the user is
			// interacting with the spinner, the focus should be on the input.
			// If the input is focused then this.previous is properly set from
			// when the input first received focus. If the input is not focused
			// then we need to set this.previous based on the value before spinning.
			previous = this.element[ 0 ] === $.ui.safeActiveElement( this.document[ 0 ] ) ?
				this.previous : this.element.val();
			function checkFocus() {
				var isActive = this.element[ 0 ] === $.ui.safeActiveElement( this.document[ 0 ] );
				if ( !isActive ) {
					this.element.trigger( "focus" );
					this.previous = previous;

					// support: IE
					// IE sets focus asynchronously, so we need to check if focus
					// moved off of the input because the user clicked on the button.
					this._delay( function() {
						this.previous = previous;
					} );
				}
			}

			// Ensure focus is on (or stays on) the text field
			event.preventDefault();
			checkFocus.call( this );

			// Support: IE
			// IE doesn't prevent moving focus even with event.preventDefault()
			// so we set a flag to know when we should ignore the blur event
			// and check (again) if focus moved off of the input.
			this.cancelBlur = true;
			this._delay( function() {
				delete this.cancelBlur;
				checkFocus.call( this );
			} );

			if ( this._start( event ) === false ) {
				return;
			}

			this._repeat( null, $( event.currentTarget )
				.hasClass( "ui-spinner-up" ) ? 1 : -1, event );
		},
		"mouseup .ui-spinner-button": "_stop",
		"mouseenter .ui-spinner-button": function( event ) {

			// button will add ui-state-active if mouse was down while mouseleave and kept down
			if ( !$( event.currentTarget ).hasClass( "ui-state-active" ) ) {
				return;
			}

			if ( this._start( event ) === false ) {
				return false;
			}
			this._repeat( null, $( event.currentTarget )
				.hasClass( "ui-spinner-up" ) ? 1 : -1, event );
		},

		// TODO: do we really want to consider this a stop?
		// shouldn't we just stop the repeater and wait until mouseup before
		// we trigger the stop event?
		"mouseleave .ui-spinner-button": "_stop"
	},

	// Support mobile enhanced option and make backcompat more sane
	_enhance: function() {
		this.uiSpinner = this.element
			.attr( "autocomplete", "off" )
			.wrap( "<span>" )
			.parent()

				// Add buttons
				.append(
					"<a></a><a></a>"
				);
	},

	_draw: function() {
		this._enhance();

		this._addClass( this.uiSpinner, "ui-spinner", "ui-widget ui-widget-content" );
		this._addClass( "ui-spinner-input" );

		this.element.attr( "role", "spinbutton" );

		// Button bindings
		this.buttons = this.uiSpinner.children( "a" )
			.attr( "tabIndex", -1 )
			.attr( "aria-hidden", true )
			.button( {
				classes: {
					"ui-button": ""
				}
			} );

		// TODO: Right now button does not support classes this is already updated in button PR
		this._removeClass( this.buttons, "ui-corner-all" );

		this._addClass( this.buttons.first(), "ui-spinner-button ui-spinner-up" );
		this._addClass( this.buttons.last(), "ui-spinner-button ui-spinner-down" );
		this.buttons.first().button( {
			"icon": this.options.icons.up,
			"showLabel": false
		} );
		this.buttons.last().button( {
			"icon": this.options.icons.down,
			"showLabel": false
		} );

		// IE 6 doesn't understand height: 50% for the buttons
		// unless the wrapper has an explicit height
		if ( this.buttons.height() > Math.ceil( this.uiSpinner.height() * 0.5 ) &&
				this.uiSpinner.height() > 0 ) {
			this.uiSpinner.height( this.uiSpinner.height() );
		}
	},

	_keydown: function( event ) {
		var options = this.options,
			keyCode = $.ui.keyCode;

		switch ( event.keyCode ) {
		case keyCode.UP:
			this._repeat( null, 1, event );
			return true;
		case keyCode.DOWN:
			this._repeat( null, -1, event );
			return true;
		case keyCode.PAGE_UP:
			this._repeat( null, options.page, event );
			return true;
		case keyCode.PAGE_DOWN:
			this._repeat( null, -options.page, event );
			return true;
		}

		return false;
	},

	_start: function( event ) {
		if ( !this.spinning && this._trigger( "start", event ) === false ) {
			return false;
		}

		if ( !this.counter ) {
			this.counter = 1;
		}
		this.spinning = true;
		return true;
	},

	_repeat: function( i, steps, event ) {
		i = i || 500;

		clearTimeout( this.timer );
		this.timer = this._delay( function() {
			this._repeat( 40, steps, event );
		}, i );

		this._spin( steps * this.options.step, event );
	},

	_spin: function( step, event ) {
		var value = this.value() || 0;

		if ( !this.counter ) {
			this.counter = 1;
		}

		value = this._adjustValue( value + step * this._increment( this.counter ) );

		if ( !this.spinning || this._trigger( "spin", event, { value: value } ) !== false ) {
			this._value( value );
			this.counter++;
		}
	},

	_increment: function( i ) {
		var incremental = this.options.incremental;

		if ( incremental ) {
			return $.isFunction( incremental ) ?
				incremental( i ) :
				Math.floor( i * i * i / 50000 - i * i / 500 + 17 * i / 200 + 1 );
		}

		return 1;
	},

	_precision: function() {
		var precision = this._precisionOf( this.options.step );
		if ( this.options.min !== null ) {
			precision = Math.max( precision, this._precisionOf( this.options.min ) );
		}
		return precision;
	},

	_precisionOf: function( num ) {
		var str = num.toString(),
			decimal = str.indexOf( "." );
		return decimal === -1 ? 0 : str.length - decimal - 1;
	},

	_adjustValue: function( value ) {
		var base, aboveMin,
			options = this.options;

		// Make sure we're at a valid step
		// - find out where we are relative to the base (min or 0)
		base = options.min !== null ? options.min : 0;
		aboveMin = value - base;

		// - round to the nearest step
		aboveMin = Math.round( aboveMin / options.step ) * options.step;

		// - rounding is based on 0, so adjust back to our base
		value = base + aboveMin;

		// Fix precision from bad JS floating point math
		value = parseFloat( value.toFixed( this._precision() ) );

		// Clamp the value
		if ( options.max !== null && value > options.max ) {
			return options.max;
		}
		if ( options.min !== null && value < options.min ) {
			return options.min;
		}

		return value;
	},

	_stop: function( event ) {
		if ( !this.spinning ) {
			return;
		}

		clearTimeout( this.timer );
		clearTimeout( this.mousewheelTimer );
		this.counter = 0;
		this.spinning = false;
		this._trigger( "stop", event );
	},

	_setOption: function( key, value ) {
		var prevValue, first, last;

		if ( key === "culture" || key === "numberFormat" ) {
			prevValue = this._parse( this.element.val() );
			this.options[ key ] = value;
			this.element.val( this._format( prevValue ) );
			return;
		}

		if ( key === "max" || key === "min" || key === "step" ) {
			if ( typeof value === "string" ) {
				value = this._parse( value );
			}
		}
		if ( key === "icons" ) {
			first = this.buttons.first().find( ".ui-icon" );
			this._removeClass( first, null, this.options.icons.up );
			this._addClass( first, null, value.up );
			last = this.buttons.last().find( ".ui-icon" );
			this._removeClass( last, null, this.options.icons.down );
			this._addClass( last, null, value.down );
		}

		this._super( key, value );
	},

	_setOptionDisabled: function( value ) {
		this._super( value );

		this._toggleClass( this.uiSpinner, null, "ui-state-disabled", !!value );
		this.element.prop( "disabled", !!value );
		this.buttons.button( value ? "disable" : "enable" );
	},

	_setOptions: spinnerModifer( function( options ) {
		this._super( options );
	} ),

	_parse: function( val ) {
		if ( typeof val === "string" && val !== "" ) {
			val = window.Globalize && this.options.numberFormat ?
				Globalize.parseFloat( val, 10, this.options.culture ) : +val;
		}
		return val === "" || isNaN( val ) ? null : val;
	},

	_format: function( value ) {
		if ( value === "" ) {
			return "";
		}
		return window.Globalize && this.options.numberFormat ?
			Globalize.format( value, this.options.numberFormat, this.options.culture ) :
			value;
	},

	_refresh: function() {
		this.element.attr( {
			"aria-valuemin": this.options.min,
			"aria-valuemax": this.options.max,

			// TODO: what should we do with values that can't be parsed?
			"aria-valuenow": this._parse( this.element.val() )
		} );
	},

	isValid: function() {
		var value = this.value();

		// Null is invalid
		if ( value === null ) {
			return false;
		}

		// If value gets adjusted, it's invalid
		return value === this._adjustValue( value );
	},

	// Update the value without triggering change
	_value: function( value, allowAny ) {
		var parsed;
		if ( value !== "" ) {
			parsed = this._parse( value );
			if ( parsed !== null ) {
				if ( !allowAny ) {
					parsed = this._adjustValue( parsed );
				}
				value = this._format( parsed );
			}
		}
		this.element.val( value );
		this._refresh();
	},

	_destroy: function() {
		this.element
			.prop( "disabled", false )
			.removeAttr( "autocomplete role aria-valuemin aria-valuemax aria-valuenow" );

		this.uiSpinner.replaceWith( this.element );
	},

	stepUp: spinnerModifer( function( steps ) {
		this._stepUp( steps );
	} ),
	_stepUp: function( steps ) {
		if ( this._start() ) {
			this._spin( ( steps || 1 ) * this.options.step );
			this._stop();
		}
	},

	stepDown: spinnerModifer( function( steps ) {
		this._stepDown( steps );
	} ),
	_stepDown: function( steps ) {
		if ( this._start() ) {
			this._spin( ( steps || 1 ) * -this.options.step );
			this._stop();
		}
	},

	pageUp: spinnerModifer( function( pages ) {
		this._stepUp( ( pages || 1 ) * this.options.page );
	} ),

	pageDown: spinnerModifer( function( pages ) {
		this._stepDown( ( pages || 1 ) * this.options.page );
	} ),

	value: function( newVal ) {
		if ( !arguments.length ) {
			return this._parse( this.element.val() );
		}
		spinnerModifer( this._value ).call( this, newVal );
	},

	widget: function() {
		return this.uiSpinner;
	}
} );

// DEPRECATED
// TODO: switch return back to widget declaration at top of file when this is removed
if ( $.uiBackCompat !== false ) {

	// Backcompat for spinner html extension points
	$.widget( "ui.spinner", $.ui.spinner, {
		_enhance: function() {
			this.uiSpinner = this.element
				.attr( "autocomplete", "off" )
				.wrap( this._uiSpinnerHtml() )
				.parent()

					// Add buttons
					.append( this._buttonHtml() );
		},
		_uiSpinnerHtml: function() {
			return "<span>";
		},

		_buttonHtml: function() {
			return "<a></a><a></a>";
		}
	} );
}

var widgetsSpinner = $.ui.spinner;


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

//>>label: Tabs
//>>group: Widgets
//>>description: Transforms a set of container elements into a tab structure.
//>>docs: http://api.jqueryui.com/tabs/
//>>demos: http://jqueryui.com/tabs/
//>>css.structure: ../../themes/base/core.css
//>>css.structure: ../../themes/base/tabs.css
//>>css.theme: ../../themes/base/theme.css



$.widget( "ui.tabs", {
	version: "1.12.1",
	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: false,
		event: "click",
		heightStyle: "content",
		hide: null,
		show: null,

		// Callbacks
		activate: null,
		beforeActivate: null,
		beforeLoad: null,
		load: null
	},

	_isLocal: ( function() {
		var rhash = /#.*$/;

		return function( anchor ) {
			var anchorUrl, locationUrl;

			anchorUrl = anchor.href.replace( rhash, "" );
			locationUrl = location.href.replace( rhash, "" );

			// Decoding may throw an error if the URL isn't UTF-8 (#9518)
			try {
				anchorUrl = decodeURIComponent( anchorUrl );
			} catch ( error ) {}
			try {
				locationUrl = decodeURIComponent( locationUrl );
			} catch ( error ) {}

			return anchor.hash.length > 1 && anchorUrl === locationUrl;
		};
	} )(),

	_create: function() {
		var that = this,
			options = this.options;

		this.running = false;

		this._addClass( "ui-tabs", "ui-widget ui-widget-content" );
		this._toggleClass( "ui-tabs-collapsible", null, options.collapsible );

		this._processTabs();
		options.active = this._initialActive();

		// Take disabling tabs via class attribute from HTML
		// into account and update option properly.
		if ( $.isArray( options.disabled ) ) {
			options.disabled = $.unique( options.disabled.concat(
				$.map( this.tabs.filter( ".ui-state-disabled" ), function( li ) {
					return that.tabs.index( li );
				} )
			) ).sort();
		}

		// Check for length avoids error when initializing empty list
		if ( this.options.active !== false && this.anchors.length ) {
			this.active = this._findActive( options.active );
		} else {
			this.active = $();
		}

		this._refresh();

		if ( this.active.length ) {
			this.load( options.active );
		}
	},

	_initialActive: function() {
		var active = this.options.active,
			collapsible = this.options.collapsible,
			locationHash = location.hash.substring( 1 );

		if ( active === null ) {

			// check the fragment identifier in the URL
			if ( locationHash ) {
				this.tabs.each( function( i, tab ) {
					if ( $( tab ).attr( "aria-controls" ) === locationHash ) {
						active = i;
						return false;
					}
				} );
			}

			// Check for a tab marked active via a class
			if ( active === null ) {
				active = this.tabs.index( this.tabs.filter( ".ui-tabs-active" ) );
			}

			// No active tab, set to false
			if ( active === null || active === -1 ) {
				active = this.tabs.length ? 0 : false;
			}
		}

		// Handle numbers: negative, out of range
		if ( active !== false ) {
			active = this.tabs.index( this.tabs.eq( active ) );
			if ( active === -1 ) {
				active = collapsible ? false : 0;
			}
		}

		// Don't allow collapsible: false and active: false
		if ( !collapsible && active === false && this.anchors.length ) {
			active = 0;
		}

		return active;
	},

	_getCreateEventData: function() {
		return {
			tab: this.active,
			panel: !this.active.length ? $() : this._getPanelForTab( this.active )
		};
	},

	_tabKeydown: function( event ) {
		var focusedTab = $( $.ui.safeActiveElement( this.document[ 0 ] ) ).closest( "li" ),
			selectedIndex = this.tabs.index( focusedTab ),
			goingForward = true;

		if ( this._handlePageNav( event ) ) {
			return;
		}

		switch ( event.keyCode ) {
		case $.ui.keyCode.RIGHT:
		case $.ui.keyCode.DOWN:
			selectedIndex++;
			break;
		case $.ui.keyCode.UP:
		case $.ui.keyCode.LEFT:
			goingForward = false;
			selectedIndex--;
			break;
		case $.ui.keyCode.END:
			selectedIndex = this.anchors.length - 1;
			break;
		case $.ui.keyCode.HOME:
			selectedIndex = 0;
			break;
		case $.ui.keyCode.SPACE:

			// Activate only, no collapsing
			event.preventDefault();
			clearTimeout( this.activating );
			this._activate( selectedIndex );
			return;
		case $.ui.keyCode.ENTER:

			// Toggle (cancel delayed activation, allow collapsing)
			event.preventDefault();
			clearTimeout( this.activating );

			// Determine if we should collapse or activate
			this._activate( selectedIndex === this.options.active ? false : selectedIndex );
			return;
		default:
			return;
		}

		// Focus the appropriate tab, based on which key was pressed
		event.preventDefault();
		clearTimeout( this.activating );
		selectedIndex = this._focusNextTab( selectedIndex, goingForward );

		// Navigating with control/command key will prevent automatic activation
		if ( !event.ctrlKey && !event.metaKey ) {

			// Update aria-selected immediately so that AT think the tab is already selected.
			// Otherwise AT may confuse the user by stating that they need to activate the tab,
			// but the tab will already be activated by the time the announcement finishes.
			focusedTab.attr( "aria-selected", "false" );
			this.tabs.eq( selectedIndex ).attr( "aria-selected", "true" );

			this.activating = this._delay( function() {
				this.option( "active", selectedIndex );
			}, this.delay );
		}
	},

	_panelKeydown: function( event ) {
		if ( this._handlePageNav( event ) ) {
			return;
		}

		// Ctrl+up moves focus to the current tab
		if ( event.ctrlKey && event.keyCode === $.ui.keyCode.UP ) {
			event.preventDefault();
			this.active.trigger( "focus" );
		}
	},

	// Alt+page up/down moves focus to the previous/next tab (and activates)
	_handlePageNav: function( event ) {
		if ( event.altKey && event.keyCode === $.ui.keyCode.PAGE_UP ) {
			this._activate( this._focusNextTab( this.options.active - 1, false ) );
			return true;
		}
		if ( event.altKey && event.keyCode === $.ui.keyCode.PAGE_DOWN ) {
			this._activate( this._focusNextTab( this.options.active + 1, true ) );
			return true;
		}
	},

	_findNextTab: function( index, goingForward ) {
		var lastTabIndex = this.tabs.length - 1;

		function constrain() {
			if ( index > lastTabIndex ) {
				index = 0;
			}
			if ( index < 0 ) {
				index = lastTabIndex;
			}
			return index;
		}

		while ( $.inArray( constrain(), this.options.disabled ) !== -1 ) {
			index = goingForward ? index + 1 : index - 1;
		}

		return index;
	},

	_focusNextTab: function( index, goingForward ) {
		index = this._findNextTab( index, goingForward );
		this.tabs.eq( index ).trigger( "focus" );
		return index;
	},

	_setOption: function( key, value ) {
		if ( key === "active" ) {

			// _activate() will handle invalid values and update this.options
			this._activate( value );
			return;
		}

		this._super( key, value );

		if ( key === "collapsible" ) {
			this._toggleClass( "ui-tabs-collapsible", null, value );

			// Setting collapsible: false while collapsed; open first panel
			if ( !value && this.options.active === false ) {
				this._activate( 0 );
			}
		}

		if ( key === "event" ) {
			this._setupEvents( value );
		}

		if ( key === "heightStyle" ) {
			this._setupHeightStyle( value );
		}
	},

	_sanitizeSelector: function( hash ) {
		return hash ? hash.replace( /[!"$%&'()*+,.\/:;<=>?@\[\]\^`{|}~]/g, "\\$&" ) : "";
	},

	refresh: function() {
		var options = this.options,
			lis = this.tablist.children( ":has(a[href])" );

		// Get disabled tabs from class attribute from HTML
		// this will get converted to a boolean if needed in _refresh()
		options.disabled = $.map( lis.filter( ".ui-state-disabled" ), function( tab ) {
			return lis.index( tab );
		} );

		this._processTabs();

		// Was collapsed or no tabs
		if ( options.active === false || !this.anchors.length ) {
			options.active = false;
			this.active = $();

		// was active, but active tab is gone
		} else if ( this.active.length && !$.contains( this.tablist[ 0 ], this.active[ 0 ] ) ) {

			// all remaining tabs are disabled
			if ( this.tabs.length === options.disabled.length ) {
				options.active = false;
				this.active = $();

			// activate previous tab
			} else {
				this._activate( this._findNextTab( Math.max( 0, options.active - 1 ), false ) );
			}

		// was active, active tab still exists
		} else {

			// make sure active index is correct
			options.active = this.tabs.index( this.active );
		}

		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"
			} );

		// Make sure one tab is in the tab order
		if ( !this.active.length ) {
			this.tabs.eq( 0 ).attr( "tabIndex", 0 );
		} else {
			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"
				} );
		}
	},

	_processTabs: function() {
		var that = this,
			prevTabs = this.tabs,
			prevAnchors = this.anchors,
			prevPanels = 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" );

		// Prevent users from focusing disabled tabs via click
		this.tablist
			.on( "mousedown" + this.eventNamespace, "> li", function( event ) {
				if ( $( this ).is( ".ui-state-disabled" ) ) {
					event.preventDefault();
				}
			} )

			// Support: IE <9
			// Preventing the default action in mousedown doesn't prevent IE
			// from focusing the element, so if the anchor gets focused, blur.
			// We don't have to worry about focusing the previously focused
			// element since clicking on a non-focusable element should focus
			// the body anyway.
			.on( "focus" + this.eventNamespace, ".ui-tabs-anchor", function() {
				if ( $( 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 $( "a", this )[ 0 ];
		} )
			.attr( {
				role: "presentation",
				tabIndex: -1
			} );
		this._addClass( this.anchors, "ui-tabs-anchor" );

		this.panels = $();

		this.anchors.each( function( i, anchor ) {
			var selector, panel, panelId,
				anchorId = $( anchor ).uniqueId().attr( "id" ),
				tab = $( anchor ).closest( "li" ),
				originalAriaControls = tab.attr( "aria-controls" );

			// Inline tab
			if ( that._isLocal( anchor ) ) {
				selector = anchor.hash;
				panelId = selector.substring( 1 );
				panel = that.element.find( that._sanitizeSelector( selector ) );

			// remote tab
			} else {

				// If the tab doesn't already have aria-controls,
				// generate an id by using a throw-away element
				panelId = tab.attr( "aria-controls" ) || $( {} ).uniqueId()[ 0 ].id;
				selector = "#" + panelId;
				panel = that.element.find( selector );
				if ( !panel.length ) {
					panel = that._createPanel( panelId );
					panel.insertAfter( that.panels[ i - 1 ] || that.tablist );
				}
				panel.attr( "aria-live", "polite" );
			}

			if ( panel.length ) {
				that.panels = that.panels.add( panel );
			}
			if ( originalAriaControls ) {
				tab.data( "ui-tabs-aria-controls", originalAriaControls );
			}
			tab.attr( {
				"aria-controls": panelId,
				"aria-labelledby": anchorId
			} );
			panel.attr( "aria-labelledby", anchorId );
		} );

		this.panels.attr( "role", "tabpanel" );
		this._addClass( this.panels, "ui-tabs-panel", "ui-widget-content" );

		// Avoid memory leaks (#10056)
		if ( prevTabs ) {
			this._off( prevTabs.not( this.tabs ) );
			this._off( prevAnchors.not( this.anchors ) );
			this._off( prevPanels.not( this.panels ) );
		}
	},

	// Allow overriding how to find the list for rare usage scenarios (#7715)
	_getList: function() {
		return this.tablist || this.element.find( "ol, ul" ).eq( 0 );
	},

	_createPanel: function( id ) {
		return $( "<div>" )
			.attr( "id", id )
			.data( "ui-tabs-destroy", true );
	},

	_setOptionDisabled: function( disabled ) {
		var currentItem, li, i;

		if ( $.isArray( disabled ) ) {
			if ( !disabled.length ) {
				disabled = false;
			} else if ( disabled.length === this.anchors.length ) {
				disabled = true;
			}
		}

		// Disable tabs
		for ( i = 0; ( li = this.tabs[ i ] ); i++ ) {
			currentItem = $( li );
			if ( disabled === true || $.inArray( i, disabled ) !== -1 ) {
				currentItem.attr( "aria-disabled", "true" );
				this._addClass( currentItem, null, "ui-state-disabled" );
			} else {
				currentItem.removeAttr( "aria-disabled" );
				this._removeClass( currentItem, null, "ui-state-disabled" );
			}
		}

		this.options.disabled = disabled;

		this._toggleClass( this.widget(), this.widgetFullName + "-disabled", null,
			disabled === true );
	},

	_setupEvents: function( event ) {
		var events = {};
		if ( event ) {
			$.each( event.split( " " ), function( index, eventName ) {
				events[ eventName ] = "_eventHandler";
			} );
		}

		this._off( this.anchors.add( this.tabs ).add( this.panels ) );

		// Always prevent the default action, even when disabled
		this._on( true, this.anchors, {
			click: function( event ) {
				event.preventDefault();
			}
		} );
		this._on( this.anchors, events );
		this._on( this.tabs, { keydown: "_tabKeydown" } );
		this._on( this.panels, { keydown: "_panelKeydown" } );

		this._focusable( this.tabs );
		this._hoverable( this.tabs );
	},

	_setupHeightStyle: function( heightStyle ) {
		var maxHeight,
			parent = this.element.parent();

		if ( heightStyle === "fill" ) {
			maxHeight = parent.height();
			maxHeight -= this.element.outerHeight() - this.element.height();

			this.element.siblings( ":visible" ).each( function() {
				var elem = $( this ),
					position = elem.css( "position" );

				if ( position === "absolute" || position === "fixed" ) {
					return;
				}
				maxHeight -= elem.outerHeight( true );
			} );

			this.element.children().not( this.panels ).each( function() {
				maxHeight -= $( this ).outerHeight( true );
			} );

			this.panels.each( function() {
				$( this ).height( Math.max( 0, maxHeight -
					$( this ).innerHeight() + $( this ).height() ) );
			} )
				.css( "overflow", "auto" );
		} else if ( heightStyle === "auto" ) {
			maxHeight = 0;
			this.panels.each( function() {
				maxHeight = Math.max( maxHeight, $( this ).height( "" ).height() );
			} ).height( maxHeight );
		}
	},

	_eventHandler: function( event ) {
		var options = this.options,
			active = this.active,
			anchor = $( event.currentTarget ),
			tab = anchor.closest( "li" ),
			clickedIsActive = tab[ 0 ] === active[ 0 ],
			collapsing = clickedIsActive && options.collapsible,
			toShow = collapsing ? $() : this._getPanelForTab( tab ),
			toHide = !active.length ? $() : this._getPanelForTab( active ),
			eventData = {
				oldTab: active,
				oldPanel: toHide,
				newTab: collapsing ? $() : tab,
				newPanel: toShow
			};

		event.preventDefault();

		if ( tab.hasClass( "ui-state-disabled" ) ||

				// tab is already loading
				tab.hasClass( "ui-tabs-loading" ) ||

				// can't switch durning an animation
				this.running ||

				// click on active header, but not collapsible
				( clickedIsActive && !options.collapsible ) ||

				// allow canceling activation
				( this._trigger( "beforeActivate", event, eventData ) === false ) ) {
			return;
		}

		options.active = collapsing ? false : this.tabs.index( tab );

		this.active = clickedIsActive ? $() : tab;
		if ( this.xhr ) {
			this.xhr.abort();
		}

		if ( !toHide.length && !toShow.length ) {
			$.error( "jQuery UI Tabs: Mismatching fragment identifier." );
		}

		if ( toShow.length ) {
			this.load( this.tabs.index( tab ), event );
		}
		this._toggle( event, eventData );
	},

	// Handles show/hide for selecting tabs
	_toggle: function( event, eventData ) {
		var that = this,
			toShow = eventData.newPanel,
			toHide = eventData.oldPanel;

		this.running = true;

		function complete() {
			that.running = false;
			that._trigger( "activate", event, eventData );
		}

		function show() {
			that._addClass( eventData.newTab.closest( "li" ), "ui-tabs-active", "ui-state-active" );

			if ( toShow.length && that.options.show ) {
				that._show( toShow, that.options.show, complete );
			} else {
				toShow.show();
				complete();
			}
		}

		// Start out by hiding, then showing, then completing
		if ( toHide.length && this.options.hide ) {
			this._hide( toHide, this.options.hide, function() {
				that._removeClass( eventData.oldTab.closest( "li" ),
					"ui-tabs-active", "ui-state-active" );
				show();
			} );
		} else {
			this._removeClass( eventData.oldTab.closest( "li" ),
				"ui-tabs-active", "ui-state-active" );
			toHide.hide();
			show();
		}

		toHide.attr( "aria-hidden", "true" );
		eventData.oldTab.attr( {
			"aria-selected": "false",
			"aria-expanded": "false"
		} );

		// If we're switching tabs, remove the old tab from the tab order.
		// If we're opening from collapsed state, remove the previous tab from the tab order.
		// If we're collapsing, then keep the collapsing tab in the tab order.
		if ( toShow.length && toHide.length ) {
			eventData.oldTab.attr( "tabIndex", -1 );
		} else if ( toShow.length ) {
			this.tabs.filter( function() {
				return $( this ).attr( "tabIndex" ) === 0;
			} )
				.attr( "tabIndex", -1 );
		}

		toShow.attr( "aria-hidden", "false" );
		eventData.newTab.attr( {
			"aria-selected": "true",
			"aria-expanded": "true",
			tabIndex: 0
		} );
	},

	_activate: function( index ) {
		var anchor,
			active = this._findActive( index );

		// Trying to activate the already active panel
		if ( active[ 0 ] === this.active[ 0 ] ) {
			return;
		}

		// Trying to collapse, simulate a click on the current active header
		if ( !active.length ) {
			active = this.active;
		}

		anchor = active.find( ".ui-tabs-anchor" )[ 0 ];
		this._eventHandler( {
			target: anchor,
			currentTarget: anchor,
			preventDefault: $.noop
		} );
	},

	_findActive: function( index ) {
		return index === false ? $() : this.tabs.eq( index );
	},

	_getIndex: function( index ) {

		// meta-function to give users option to provide a href string instead of a numerical index.
		if ( typeof index === "string" ) {
			index = this.anchors.index( this.anchors.filter( "[href$='" +
				$.ui.escapeSelector( index ) + "']" ) );
		}

		return index;
	},

	_destroy: function() {
		if ( 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() {
			if ( $.data( this, "ui-tabs-destroy" ) ) {
				$( this ).remove();
			} else {
				$( this ).removeAttr( "role tabIndex " +
					"aria-live aria-busy aria-selected aria-labelledby aria-hidden aria-expanded" );
			}
		} );

		this.tabs.each( function() {
			var li = $( this ),
				prev = li.data( "ui-tabs-aria-controls" );
			if ( prev ) {
				li
					.attr( "aria-controls", prev )
					.removeData( "ui-tabs-aria-controls" );
			} else {
				li.removeAttr( "aria-controls" );
			}
		} );

		this.panels.show();

		if ( this.options.heightStyle !== "content" ) {
			this.panels.css( "height", "" );
		}
	},

	enable: function( index ) {
		var disabled = this.options.disabled;
		if ( disabled === false ) {
			return;
		}

		if ( index === undefined ) {
			disabled = false;
		} else {
			index = this._getIndex( index );
			if ( $.isArray( disabled ) ) {
				disabled = $.map( disabled, function( num ) {
					return num !== index ? num : null;
				} );
			} else {
				disabled = $.map( this.tabs, function( li, num ) {
					return num !== index ? num : null;
				} );
			}
		}
		this._setOptionDisabled( disabled );
	},

	disable: function( index ) {
		var disabled = this.options.disabled;
		if ( disabled === true ) {
			return;
		}

		if ( index === undefined ) {
			disabled = true;
		} else {
			index = this._getIndex( index );
			if ( $.inArray( index, disabled ) !== -1 ) {
				return;
			}
			if ( $.isArray( disabled ) ) {
				disabled = $.merge( [ index ], disabled ).sort();
			} else {
				disabled = [ index ];
			}
		}
		this._setOptionDisabled( disabled );
	},

	load: function( index, event ) {
		index = this._getIndex( index );
		var that = this,
			tab = this.tabs.eq( index ),
			anchor = tab.find( ".ui-tabs-anchor" ),
			panel = this._getPanelForTab( tab ),
			eventData = {
				tab: tab,
				panel: panel
			},
			complete = function( jqXHR, status ) {
				if ( status === "abort" ) {
					that.panels.stop( false, true );
				}

				that._removeClass( tab, "ui-tabs-loading" );
				panel.removeAttr( "aria-busy" );

				if ( jqXHR === that.xhr ) {
					delete that.xhr;
				}
			};

		// Not remote
		if ( this._isLocal( anchor[ 0 ] ) ) {
			return;
		}

		this.xhr = $.ajax( this._ajaxSettings( anchor, event, eventData ) );

		// Support: jQuery <1.8
		// jQuery <1.8 returns false if the request is canceled in beforeSend,
		// but as of 1.8, $.ajax() always returns a jqXHR object.
		if ( this.xhr && this.xhr.statusText !== "canceled" ) {
			this._addClass( tab, "ui-tabs-loading" );
			panel.attr( "aria-busy", "true" );

			this.xhr
				.done( function( response, status, jqXHR ) {

					// support: jQuery <1.8
					// http://bugs.jquery.com/ticket/11778
					setTimeout( function() {
						panel.html( response );
						that._trigger( "load", event, eventData );

						complete( jqXHR, status );
					}, 1 );
				} )
				.fail( function( jqXHR, status ) {

					// support: jQuery <1.8
					// http://bugs.jquery.com/ticket/11778
					setTimeout( function() {
						complete( jqXHR, status );
					}, 1 );
				} );
		}
	},

	_ajaxSettings: function( anchor, event, eventData ) {
		var that = this;
		return {

			// Support: IE <11 only
			// Strip any hash that exists to prevent errors with the Ajax request
			url: anchor.attr( "href" ).replace( /#.*$/, "" ),
			beforeSend: function( jqXHR, settings ) {
				return that._trigger( "beforeLoad", event,
					$.extend( { jqXHR: jqXHR, ajaxSettings: settings }, eventData ) );
			}
		};
	},

	_getPanelForTab: function( tab ) {
		var id = $( tab ).attr( "aria-controls" );
		return this.element.find( this._sanitizeSelector( "#" + id ) );
	}
} );

// DEPRECATED
// TODO: Switch return back to widget declaration at top of file when this is removed
if ( $.uiBackCompat !== false ) {

	// Backcompat for ui-tab class (now ui-tabs-tab)
	$.widget( "ui.tabs", $.ui.tabs, {
		_processTabs: function() {
			this._superApply( arguments );
			this._addClass( this.tabs, "ui-tab" );
		}
	} );
}

var widgetsTabs = $.ui.tabs;


/*!
 * jQuery UI Tooltip 1.12.1
 * http://jqueryui.com
 *
 * Copyright jQuery Foundation and other contributors
 * Released under the MIT license.
 * http://jquery.org/license
 */

//>>label: Tooltip
//>>group: Widgets
//>>description: Shows additional information for any element on hover or focus.
//>>docs: http://api.jqueryui.com/tooltip/
//>>demos: http://jqueryui.com/tooltip/
//>>css.structure: ../../themes/base/core.css
//>>css.structure: ../../themes/base/tooltip.css
//>>css.theme: ../../themes/base/theme.css



$.widget( "ui.tooltip", {
	version: "1.12.1",
	options: {
		classes: {
			"ui-tooltip": "ui-corner-all ui-widget-shadow"
		},
		content: function() {

			// support: IE<9, Opera in jQuery <1.7
			// .text() can't accept undefined, so coerce to a string
			var title = $( this ).attr( "title" ) || "";

			// Escape title, since we're going from an attribute to raw HTML
			return $( "<a>" ).text( title ).html();
		},
		hide: true,

		// Disabled elements have inconsistent behavior across browsers (#8661)
		items: "[title]:not([disabled])",
		position: {
			my: "left top+15",
			at: "left bottom",
			collision: "flipfit flip"
		},
		show: true,
		track: false,

		// Callbacks
		close: null,
		open: null
	},

	_addDescribedBy: function( elem, id ) {
		var describedby = ( elem.attr( "aria-describedby" ) || "" ).split( /\s+/ );
		describedby.push( id );
		elem
			.data( "ui-tooltip-id", id )
			.attr( "aria-describedby", $.trim( describedby.join( " " ) ) );
	},

	_removeDescribedBy: function( elem ) {
		var id = elem.data( "ui-tooltip-id" ),
			describedby = ( elem.attr( "aria-describedby" ) || "" ).split( /\s+/ ),
			index = $.inArray( id, describedby );

		if ( index !== -1 ) {
			describedby.splice( index, 1 );
		}

		elem.removeData( "ui-tooltip-id" );
		describedby = $.trim( describedby.join( " " ) );
		if ( describedby ) {
			elem.attr( "aria-describedby", describedby );
		} else {
			elem.removeAttr( "aria-describedby" );
		}
	},

	_create: function() {
		this._on( {
			mouseover: "open",
			focusin: "open"
		} );

		// IDs of generated tooltips, needed for destroy
		this.tooltips = {};

		// IDs of parent tooltips where we removed the title attribute
		this.parents = {};

		// Append the aria-live region so tooltips announce correctly
		this.liveRegion = $( "<div>" )
			.attr( {
				role: "log",
				"aria-live": "assertive",
				"aria-relevant": "additions"
			} )
			.appendTo( this.document[ 0 ].body );
		this._addClass( this.liveRegion, null, "ui-helper-hidden-accessible" );

		this.disabledTitles = $( [] );
	},

	_setOption: function( key, value ) {
		var that = this;

		this._super( key, value );

		if ( key === "content" ) {
			$.each( this.tooltips, function( id, tooltipData ) {
				that._updateContent( tooltipData.element );
			} );
		}
	},

	_setOptionDisabled: function( value ) {
		this[ value ? "_disable" : "_enable" ]();
	},

	_disable: function() {
		var that = this;

		// Close open tooltips
		$.each( this.tooltips, function( id, tooltipData ) {
			var event = $.Event( "blur" );
			event.target = event.currentTarget = tooltipData.element[ 0 ];
			that.close( event, true );
		} );

		// Remove title attributes to prevent native tooltips
		this.disabledTitles = this.disabledTitles.add(
			this.element.find( this.options.items ).addBack()
				.filter( function() {
					var element = $( this );
					if ( element.is( "[title]" ) ) {
						return element
							.data( "ui-tooltip-title", element.attr( "title" ) )
							.removeAttr( "title" );
					}
				} )
		);
	},

	_enable: function() {

		// restore title attributes
		this.disabledTitles.each( function() {
			var element = $( this );
			if ( element.data( "ui-tooltip-title" ) ) {
				element.attr( "title", element.data( "ui-tooltip-title" ) );
			}
		} );
		this.disabledTitles = $( [] );
	},

	open: function( event ) {
		var that = this,
			target = $( event ? event.target : this.element )

				// we need closest here due to mouseover bubbling,
				// but always pointing at the same event target
				.closest( this.options.items );

		// No element to show a tooltip for or the tooltip is already open
		if ( !target.length || target.data( "ui-tooltip-id" ) ) {
			return;
		}

		if ( target.attr( "title" ) ) {
			target.data( "ui-tooltip-title", target.attr( "title" ) );
		}

		target.data( "ui-tooltip-open", true );

		// Kill parent tooltips, custom or native, for hover
		if ( event && event.type === "mouseover" ) {
			target.parents().each( function() {
				var parent = $( this ),
					blurEvent;
				if ( parent.data( "ui-tooltip-open" ) ) {
					blurEvent = $.Event( "blur" );
					blurEvent.target = blurEvent.currentTarget = this;
					that.close( blurEvent, true );
				}
				if ( parent.attr( "title" ) ) {
					parent.uniqueId();
					that.parents[ this.id ] = {
						element: this,
						title: parent.attr( "title" )
					};
					parent.attr( "title", "" );
				}
			} );
		}

		this._registerCloseHandlers( event, target );
		this._updateContent( target, event );
	},

	_updateContent: function( target, event ) {
		var content,
			contentOption = this.options.content,
			that = this,
			eventType = event ? event.type : null;

		if ( typeof contentOption === "string" || contentOption.nodeType ||
				contentOption.jquery ) {
			return this._open( event, target, contentOption );
		}

		content = contentOption.call( target[ 0 ], function( response ) {

			// IE may instantly serve a cached response for ajax requests
			// delay this call to _open so the other call to _open runs first
			that._delay( function() {

				// Ignore async response if tooltip was closed already
				if ( !target.data( "ui-tooltip-open" ) ) {
					return;
				}

				// JQuery creates a special event for focusin when it doesn't
				// exist natively. To improve performance, the native event
				// object is reused and the type is changed. Therefore, we can't
				// rely on the type being correct after the event finished
				// bubbling, so we set it back to the previous value. (#8740)
				if ( event ) {
					event.type = eventType;
				}
				this._open( event, target, response );
			} );
		} );
		if ( content ) {
			this._open( event, target, content );
		}
	},

	_open: function( event, target, content ) {
		var tooltipData, tooltip, delayedShow, a11yContent,
			positionOption = $.extend( {}, this.options.position );

		if ( !content ) {
			return;
		}

		// Content can be updated multiple times. If the tooltip already
		// exists, then just update the content and bail.
		tooltipData = this._find( target );
		if ( tooltipData ) {
			tooltipData.tooltip.find( ".ui-tooltip-content" ).html( content );
			return;
		}

		// If we have a title, clear it to prevent the native tooltip
		// we have to check first to avoid defining a title if none exists
		// (we don't want to cause an element to start matching [title])
		//
		// We use removeAttr only for key events, to allow IE to export the correct
		// accessible attributes. For mouse events, set to empty string to avoid
		// native tooltip showing up (happens only when removing inside mouseover).
		if ( target.is( "[title]" ) ) {
			if ( event && event.type === "mouseover" ) {
				target.attr( "title", "" );
			} else {
				target.removeAttr( "title" );
			}
		}

		tooltipData = this._tooltip( target );
		tooltip = tooltipData.tooltip;
		this._addDescribedBy( target, tooltip.attr( "id" ) );
		tooltip.find( ".ui-tooltip-content" ).html( content );

		// Support: Voiceover on OS X, JAWS on IE <= 9
		// JAWS announces deletions even when aria-relevant="additions"
		// Voiceover will sometimes re-read the entire log region's contents from the beginning
		this.liveRegion.children().hide();
		a11yContent = $( "<div>" ).html( tooltip.find( ".ui-tooltip-content" ).html() );
		a11yContent.removeAttr( "name" ).find( "[name]" ).removeAttr( "name" );
		a11yContent.removeAttr( "id" ).find( "[id]" ).removeAttr( "id" );
		a11yContent.appendTo( this.liveRegion );

		function position( event ) {
			positionOption.of = event;
			if ( tooltip.is( ":hidden" ) ) {
				return;
			}
			tooltip.position( positionOption );
		}
		if ( this.options.track && event && /^mouse/.test( event.type ) ) {
			this._on( this.document, {
				mousemove: position
			} );

			// trigger once to override element-relative positioning
			position( event );
		} else {
			tooltip.position( $.extend( {
				of: target
			}, this.options.position ) );
		}

		tooltip.hide();

		this._show( tooltip, this.options.show );

		// Handle tracking tooltips that are shown with a delay (#8644). As soon
		// as the tooltip is visible, position the tooltip using the most recent
		// event.
		// Adds the check to add the timers only when both delay and track options are set (#14682)
		if ( this.options.track && this.options.show && this.options.show.delay ) {
			delayedShow = this.delayedShow = setInterval( function() {
				if ( tooltip.is( ":visible" ) ) {
					position( positionOption.of );
					clearInterval( delayedShow );
				}
			}, $.fx.interval );
		}

		this._trigger( "open", event, { tooltip: tooltip } );
	},

	_registerCloseHandlers: function( event, target ) {
		var events = {
			keyup: function( event ) {
				if ( event.keyCode === $.ui.keyCode.ESCAPE ) {
					var fakeEvent = $.Event( event );
					fakeEvent.currentTarget = target[ 0 ];
					this.close( fakeEvent, true );
				}
			}
		};

		// Only bind remove handler for delegated targets. Non-delegated
		// tooltips will handle this in destroy.
		if ( target[ 0 ] !== this.element[ 0 ] ) {
			events.remove = function() {
				this._removeTooltip( this._find( target ).tooltip );
			};
		}

		if ( !event || event.type === "mouseover" ) {
			events.mouseleave = "close";
		}
		if ( !event || event.type === "focusin" ) {
			events.focusout = "close";
		}
		this._on( true, target, events );
	},

	close: function( event ) {
		var tooltip,
			that = this,
			target = $( event ? event.currentTarget : this.element ),
			tooltipData = this._find( target );

		// The tooltip may already be closed
		if ( !tooltipData ) {

			// We set ui-tooltip-open immediately upon open (in open()), but only set the
			// additional data once there's actually content to show (in _open()). So even if the
			// tooltip doesn't have full data, we always remove ui-tooltip-open in case we're in
			// the period between open() and _open().
			target.removeData( "ui-tooltip-open" );
			return;
		}

		tooltip = tooltipData.tooltip;

		// Disabling closes the tooltip, so we need to track when we're closing
		// to avoid an infinite loop in case the tooltip becomes disabled on close
		if ( tooltipData.closing ) {
			return;
		}

		// Clear the interval for delayed tracking tooltips
		clearInterval( this.delayedShow );

		// Only set title if we had one before (see comment in _open())
		// If the title attribute has changed since open(), don't restore
		if ( target.data( "ui-tooltip-title" ) && !target.attr( "title" ) ) {
			target.attr( "title", target.data( "ui-tooltip-title" ) );
		}

		this._removeDescribedBy( target );

		tooltipData.hiding = true;
		tooltip.stop( true );
		this._hide( tooltip, this.options.hide, function() {
			that._removeTooltip( $( this ) );
		} );

		target.removeData( "ui-tooltip-open" );
		this._off( target, "mouseleave focusout keyup" );

		// Remove 'remove' binding only on delegated targets
		if ( target[ 0 ] !== this.element[ 0 ] ) {
			this._off( target, "remove" );
		}
		this._off( this.document, "mousemove" );

		if ( event && event.type === "mouseleave" ) {
			$.each( this.parents, function( id, parent ) {
				$( parent.element ).attr( "title", parent.title );
				delete that.parents[ id ];
			} );
		}

		tooltipData.closing = true;
		this._trigger( "close", event, { tooltip: tooltip } );
		if ( !tooltipData.hiding ) {
			tooltipData.closing = false;
		}
	},

	_tooltip: function( element ) {
		var tooltip = $( "<div>" ).attr( "role", "tooltip" ),
			content = $( "<div>" ).appendTo( tooltip ),
			id = tooltip.uniqueId().attr( "id" );

		this._addClass( content, "ui-tooltip-content" );
		this._addClass( tooltip, "ui-tooltip", "ui-widget ui-widget-content" );

		tooltip.appendTo( this._appendTo( element ) );

		return this.tooltips[ id ] = {
			element: element,
			tooltip: tooltip
		};
	},

	_find: function( target ) {
		var id = target.data( "ui-tooltip-id" );
		return id ? this.tooltips[ id ] : null;
	},

	_removeTooltip: function( tooltip ) {
		tooltip.remove();
		delete this.tooltips[ tooltip.attr( "id" ) ];
	},

	_appendTo: function( target ) {
		var element = target.closest( ".ui-front, dialog" );

		if ( !element.length ) {
			element = this.document[ 0 ].body;
		}

		return element;
	},

	_destroy: function() {
		var that = this;

		// Close open tooltips
		$.each( this.tooltips, function( id, tooltipData ) {

			// Delegate to close method to handle common cleanup
			var event = $.Event( "blur" ),
				element = tooltipData.element;
			event.target = event.currentTarget = element[ 0 ];
			that.close( event, true );

			// Remove immediately; destroying an open tooltip doesn't use the
			// hide animation
			$( "#" + id ).remove();

			// Restore the title
			if ( element.data( "ui-tooltip-title" ) ) {

				// If the title attribute has changed since open(), don't restore
				if ( !element.attr( "title" ) ) {
					element.attr( "title", element.data( "ui-tooltip-title" ) );
				}
				element.removeData( "ui-tooltip-title" );
			}
		} );
		this.liveRegion.remove();
	}
} );

// DEPRECATED
// TODO: Switch return back to widget declaration at top of file when this is removed
if ( $.uiBackCompat !== false ) {

	// Backcompat for tooltipClass option
	$.widget( "ui.tooltip", $.ui.tooltip, {
		options: {
			tooltipClass: null
		},
		_tooltip: function() {
			var tooltipData = this._superApply( arguments );
			if ( this.options.tooltipClass ) {
				tooltipData.tooltip.addClass( this.options.tooltipClass );
			}
			return tooltipData;
		}
	} );
}

var widgetsTooltip = $.ui.tooltip;




}));
/*!
 * jQuery Mousewheel 3.1.13
 * Copyright OpenJS Foundation and other contributors
 */
!function(e){"function"==typeof define&&define.amd?define(["jquery"],e):"object"==typeof exports?module.exports=e:e(jQuery)}(function(a){var u,r,e=["wheel","mousewheel","DOMMouseScroll","MozMousePixelScroll"],t="onwheel"in window.document||9<=window.document.documentMode?["wheel"]:["mousewheel","DomMouseScroll","MozMousePixelScroll"],f=Array.prototype.slice;if(a.event.fixHooks)for(var n=e.length;n;)a.event.fixHooks[e[--n]]=a.event.mouseHooks;var d=a.event.special.mousewheel={version:"3.1.12",setup:function(){if(this.addEventListener)for(var e=t.length;e;)this.addEventListener(t[--e],i,!1);else this.onmousewheel=i;a.data(this,"mousewheel-line-height",d.getLineHeight(this)),a.data(this,"mousewheel-page-height",d.getPageHeight(this))},teardown:function(){if(this.removeEventListener)for(var e=t.length;e;)this.removeEventListener(t[--e],i,!1);else this.onmousewheel=null;a.removeData(this,"mousewheel-line-height"),a.removeData(this,"mousewheel-page-height")},getLineHeight:function(e){var t=a(e),e=t["offsetParent"in a.fn?"offsetParent":"parent"]();return e.length||(e=a("body")),parseInt(e.css("fontSize"),10)||parseInt(t.css("fontSize"),10)||16},getPageHeight:function(e){return a(e).height()},settings:{adjustOldDeltas:!0,normalizeOffset:!0}};function i(e){var t,n=e||window.event,i=f.call(arguments,1),o=0,l=0,s=0,h=0;if((e=a.event.fix(n)).type="mousewheel","detail"in n&&(s=-1*n.detail),"wheelDelta"in n&&(s=n.wheelDelta),"wheelDeltaY"in n&&(s=n.wheelDeltaY),"wheelDeltaX"in n&&(l=-1*n.wheelDeltaX),"axis"in n&&n.axis===n.HORIZONTAL_AXIS&&(l=-1*s,s=0),o=0===s?l:s,"deltaY"in n&&(o=s=-1*n.deltaY),"deltaX"in n&&(l=n.deltaX,0===s&&(o=-1*l)),0!==s||0!==l)return 1===n.deltaMode?(o*=t=a.data(this,"mousewheel-line-height"),s*=t,l*=t):2===n.deltaMode&&(o*=t=a.data(this,"mousewheel-page-height"),s*=t,l*=t),h=Math.max(Math.abs(s),Math.abs(l)),(!r||h<r)&&c(n,r=h)&&(r/=40),c(n,h)&&(o/=40,l/=40,s/=40),o=Math[1<=o?"floor":"ceil"](o/r),l=Math[1<=l?"floor":"ceil"](l/r),s=Math[1<=s?"floor":"ceil"](s/r),d.settings.normalizeOffset&&this.getBoundingClientRect&&(h=this.getBoundingClientRect(),e.offsetX=e.clientX-h.left,e.offsetY=e.clientY-h.top),e.deltaX=l,e.deltaY=s,e.deltaFactor=r,e.deltaMode=0,i.unshift(e,o,l,s),u&&window.clearTimeout(u),u=window.setTimeout(w,200),(a.event.dispatch||a.event.handle).apply(this,i)}function w(){r=null}function c(e,t){return d.settings.adjustOldDeltas&&"mousewheel"===e.type&&t%120==0}a.fn.extend({mousewheel:function(e){return e?this.on("mousewheel",e):this.trigger("mousewheel")},unmousewheel:function(e){return this.off("mousewheel",e)}})});
/*! jQuery-ui-Slider-Pips - v1.11.4 - 2016-09-04
* Copyright (c) 2016 Simon Goellner <simey.me@gmail.com>; Licensed MIT */

!function(e){"use strict";var i={pips:function(i){function l(i){var l,s,t,a,n,r=[],o=0;if(u.values()&&u.values().length){for(t=u.values(),a=e.map(t,function(e){return Math.abs(e-i)}),n=Math.min.apply(Math,a),l=0;l<a.length;l++)a[l]===n&&r.push(l);for(o=r[0],s=0;s<r.length;s++)u._lastChangedValue===r[s]&&(o=r[s]);u.options.range&&2===r.length&&(i>t[1]?o=r[1]:i<t[0]&&(o=r[0]))}return o}function s(){u.element.off(".selectPip").on("mousedown.slider",u.element.data("mousedown-original")).removeClass("ui-slider-pips").find(".ui-slider-pip").remove()}function t(i,s){if(!u.option("disabled")){var t=e(i).data("value"),a=l(t);u.values()&&u.values().length?u.options.values[a]=u._trimAlignValue(t):u.options.value=u._trimAlignValue(t),u._refreshValue(),u._change(s,a)}}function a(i){var l,s,t,a,r,o=i,p="ui-slider-pip",d="",f=u.value(),v=u.values();if("first"===i?o=0:"last"===i&&(o=h),t=c+u.options.step*o,a=t.toString().replace(".","-"),r=o+c-c,l="array"===e.type(g.labels)?g.labels[r]||"":"object"===e.type(g.labels)?"first"===i?g.labels.first||"":"last"===i?g.labels.last||"":"array"===e.type(g.labels.rest)?g.labels.rest[r-1]||"":t:t,"first"===i?(s="0%",p+=" ui-slider-pip-first",p+="label"===g.first?" ui-slider-pip-label":"",p+=g.first===!1?" ui-slider-pip-hide":""):"last"===i?(s="100%",p+=" ui-slider-pip-last",p+="label"===g.last?" ui-slider-pip-label":"",p+=g.last===!1?" ui-slider-pip-hide":""):(s=(100/h*i).toFixed(4)+"%",p+="label"===g.rest?" ui-slider-pip-label":"",p+=g.rest===!1?" ui-slider-pip-hide":""),p+=" ui-slider-pip-"+a,v&&v.length){for(n=0;n<v.length;n++)t===v[n]&&(p+=" ui-slider-pip-initial-"+(n+1),p+=" ui-slider-pip-selected-"+(n+1));u.options.range&&t>v[0]&&t<v[1]&&(p+=" ui-slider-pip-inrange")}else t===f&&(p+=" ui-slider-pip-initial",p+=" ui-slider-pip-selected"),u.options.range&&("min"===u.options.range&&f>t||"max"===u.options.range&&t>f)&&(p+=" ui-slider-pip-inrange");return d="horizontal"===u.options.orientation?"left: "+s:"bottom: "+s,'<span class="'+p+'" style="'+d+'"><span class="ui-slider-line"></span><span class="ui-slider-label" data-value="'+t+'">'+g.formatLabel(l)+"</span></span>"}var n,r,o,p,d,u=this,f="",c=u._valueMin(),v=u._valueMax(),h=(v-c)/u.options.step,m=u.element.find(".ui-slider-handle"),g={first:"label",last:"label",rest:"pip",labels:!1,prefix:"",suffix:"",step:h>100?Math.floor(.05*h):1,formatLabel:function(e){return this.prefix+e+this.suffix}};if("object"!==e.type(i)&&"undefined"!==e.type(i))return void("destroy"===i?s():"refresh"===i&&u.element.slider("pips",u.element.data("pips-options")));e.extend(g,i),u.element.data("pips-options",g),u.options.pipStep=Math.abs(Math.round(g.step))||1,u.element.off(".selectPip").addClass("ui-slider-pips").find(".ui-slider-pip").remove();var b={single:function(i){this.resetClasses(),d.filter(".ui-slider-pip-"+this.classLabel(i)).addClass("ui-slider-pip-selected"),u.options.range&&d.each(function(l,s){var t=e(s).children(".ui-slider-label").data("value");("min"===u.options.range&&i>t||"max"===u.options.range&&t>i)&&e(s).addClass("ui-slider-pip-inrange")})},range:function(i){for(this.resetClasses(),n=0;n<i.length;n++)d.filter(".ui-slider-pip-"+this.classLabel(i[n])).addClass("ui-slider-pip-selected-"+(n+1));u.options.range&&d.each(function(l,s){var t=e(s).children(".ui-slider-label").data("value");t>i[0]&&t<i[1]&&e(s).addClass("ui-slider-pip-inrange")})},classLabel:function(e){return e.toString().replace(".","-")},resetClasses:function(){var e=/(^|\s*)(ui-slider-pip-selected|ui-slider-pip-inrange)(-{1,2}\d+|\s|$)/gi;d.removeClass(function(i,l){return(l.match(e)||[]).join(" ")})}};for(f+=a("first"),o=u.options.pipStep;h>o;o+=u.options.pipStep)f+=a(o);for(f+=a("last"),u.element.append(f),d=u.element.find(".ui-slider-pip"),p=e._data(u.element.get(0),"events").mousedown&&e._data(u.element.get(0),"events").mousedown.length?e._data(u.element.get(0),"events").mousedown:u.element.data("mousedown-handlers"),u.element.data("mousedown-handlers",p.slice()),r=0;r<p.length;r++)"slider"===p[r].namespace&&u.element.data("mousedown-original",p[r].handler);u.element.off("mousedown.slider").on("mousedown.selectPip",function(i){var s=e(i.target),a=l(s.data("value")),n=m.eq(a);if(n.addClass("ui-state-active"),s.is(".ui-slider-label"))t(s,i),u.element.one("mouseup.selectPip",function(){n.removeClass("ui-state-active").focus()});else{var r=u.element.data("mousedown-original");r(i)}}),u.element.on("slide.selectPip slidechange.selectPip",function(i,l){var s=e(this),t=s.slider("value"),a=s.slider("values");l&&(t=l.value,a=l.values),u.values()&&u.values().length?b.range(a):b.single(t)})},"float":function(i){function l(){a.element.off(".sliderFloat").removeClass("ui-slider-float").find(".ui-slider-tip, .ui-slider-tip-label").remove()}function s(i){var l=[],s=e.map(i,function(e){return Math.ceil((e-n)/a.options.step)});if("array"===e.type(f.labels))for(t=0;t<i.length;t++)l[t]=f.labels[s[t]]||i[t];else if("object"===e.type(f.labels))for(t=0;t<i.length;t++)i[t]===n?l[t]=f.labels.first||n:i[t]===r?l[t]=f.labels.last||r:"array"===e.type(f.labels.rest)?l[t]=f.labels.rest[s[t]-1]||i[t]:l[t]=i[t];else for(t=0;t<i.length;t++)l[t]=i[t];return l}var t,a=this,n=a._valueMin(),r=a._valueMax(),o=a._value(),p=a._values(),d=[],u=a.element.find(".ui-slider-handle"),f={handle:!0,pips:!1,labels:!1,prefix:"",suffix:"",event:"slidechange slide",formatLabel:function(e){return this.prefix+e+this.suffix}};if("object"!==e.type(i)&&"undefined"!==e.type(i))return void("destroy"===i?l():"refresh"===i&&a.element.slider("float",a.element.data("float-options")));if(e.extend(f,i),a.element.data("float-options",f),n>o&&(o=n),o>r&&(o=r),p&&p.length)for(t=0;t<p.length;t++)p[t]<n&&(p[t]=n),p[t]>r&&(p[t]=r);if(a.element.addClass("ui-slider-float").find(".ui-slider-tip, .ui-slider-tip-label").remove(),f.handle)for(d=s(a.values()&&a.values().length?p:[o]),t=0;t<d.length;t++)u.eq(t).append(e('<span class="ui-slider-tip">'+f.formatLabel(d[t])+"</span>"));f.pips&&a.element.find(".ui-slider-label").each(function(i,l){var t,a,n=e(l),r=[n.data("value")];t=f.formatLabel(s(r)[0]),a=e('<span class="ui-slider-tip-label">'+t+"</span>").insertAfter(n)}),"slide"!==f.event&&"slidechange"!==f.event&&"slide slidechange"!==f.event&&"slidechange slide"!==f.event&&(f.event="slidechange slide"),a.element.off(".sliderFloat").on(f.event+".sliderFloat",function(i,l){var t="array"===e.type(l.value)?l.value:[l.value],a=f.formatLabel(s(t)[0]);e(l.handle).find(".ui-slider-tip").html(a)})}};e.extend(!0,e.ui.slider.prototype,i)}(jQuery);
/*!
 * 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(a){function f(a,b){if(!(a.originalEvent.touches.length>1)){a.preventDefault();var c=a.originalEvent.changedTouches[0],d=document.createEvent("MouseEvents");d.initMouseEvent(b,!0,!0,window,1,c.screenX,c.screenY,c.clientX,c.clientY,!1,!1,!1,!1,0,null),a.target.dispatchEvent(d)}}if(a.support.touch="ontouchend"in document,a.support.touch){var e,b=a.ui.mouse.prototype,c=b._mouseInit,d=b._mouseDestroy;b._touchStart=function(a){var b=this;!e&&b._mouseCapture(a.originalEvent.changedTouches[0])&&(e=!0,b._touchMoved=!1,f(a,"mouseover"),f(a,"mousemove"),f(a,"mousedown"))},b._touchMove=function(a){e&&(this._touchMoved=!0,f(a,"mousemove"))},b._touchEnd=function(a){e&&(f(a,"mouseup"),f(a,"mouseout"),this._touchMoved||f(a,"click"),e=!1)},b._mouseInit=function(){var b=this;b.element.bind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),c.call(b)},b._mouseDestroy=function(){var b=this;b.element.unbind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),d.call(b)}}}(jQuery);
      var leftNavParentItemHref = null;
      function setLeftNavParent(parentItemHref) {
      }
$(document).ready(function(){
    // bootsrtap tab control setup
    $('.nav-tabs a').click(function (e) {
      e.preventDefault();
      $(this).tab('show');
    });
    // Manage HISTORY (back button behavior) for tabs
    // add a hash to the URL when the user clicks on a tab
    // relies on https://github.com/devote/HTML5-History-API/ to support pushState()
    $('a[data-toggle="tab"]').on('click', function(e) {
      history.pushState(null, null, $(this).attr('href'));
    });
    // // navigate to a tab when the history changes
    showTabFromUrl = function(e) {
      if (location.hash.substr(0,3)=="#/#") {
        hashToUse = location.hash.substr(2);
      } else {
        hashToUse = location.hash;
      }
      var activeTab = $('[href="' + hashToUse + '"]');
      if (activeTab.length) {
        activeTab.tab('show');
      } else {
        $('.nav-tabs a:first').tab('show');
      }
    }
    // cross-browser call to bind showTab
    if (!window.addEventListener) {
      window.attachEvent("popstate", showTabFromUrl);
    } else {
      window.addEventListener("popstate", showTabFromUrl, false);
    }

    showTabFromUrl();

  });// doc ready

/**
 * @summary Transforms all clicks on mailto <A> links into email form popups. NOTE: this is Removed temporarily
 *
 * Long. Transforms all clicks on mailto <A> links into email form popups. Whenever there is a click on a <a> tag that begins with "mailto", run the main function. The function builds a URL to the view that will show the form for the user, opens Colorbox to the view with some options for Colorbox that run scripts after the form is submitted. The Colorbox options are onComplete and onLoad. The onLoad function removes the default Colorbox close button. The onComplete function sets up a click handler when the user submits the form. This handler runs the AJAX connection to the URL in the form's action attribute. The AJAX connection uses the form's data in a serialized format. The success attribute of the AJAX connection displays a message to the user, as does the error function. These messages display inside the Colorbox window. 
 *
 */
/*! jQuery-ui-Slider-Pips - v1.5.5 - 2014-05-14
* Copyright (c) 2014 Simon Goellner <simey.me@gmail.com>; Licensed  */
!function(a){"use strict";var b={pips:function(b){function c(b){var c=a(b).data("value"),d=a(e.element);if(e.options.range){var f=d.slider("values");f[0]===f[1]?c<f[0]?d.slider("values",[c,f[1]]):d.slider("values",[f[0],c]):Math.abs(f[0]-c)===Math.abs(f[1]-c)?d.slider("values",[c,c]):Math.abs(f[0]-c)<Math.abs(f[1]-c)?d.slider("values",[c,f[1]]):d.slider("values",[f[0],c])}else d.slider("value",c)}function d(a){var b,c,d=a,i="ui-slider-pip",j="";"first"===a?d=0:"last"===a&&(d=g);var k=e.options.min+e.options.step*d,l=k.toString().replace(".","-");b=h.labels?h.labels[d]:k,"undefined"==typeof b&&(b=""),"first"===a?(c="0%",i+=" ui-slider-pip-first",i+="label"===h.first?" ui-slider-pip-label":"",i+=!1===h.first?" ui-slider-pip-hide":""):"last"===a?(c="100%",i+=" ui-slider-pip-last",i+="label"===h.last?" ui-slider-pip-label":"",i+=!1===h.last?" ui-slider-pip-hide":""):(c=(100/g*a).toFixed(4)+"%",i+="label"===h.rest?" ui-slider-pip-label":"",i+=!1===h.rest?" ui-slider-pip-hide":""),i+=" ui-slider-pip-"+l,j="horizontal"===e.options.orientation?"left: "+c:"bottom: "+c,f+='<span class="'+i+'" style="'+j+'"><span class="ui-slider-line"></span><span class="ui-slider-label" data-value="'+k+'">'+h.formatLabel(b)+"</span></span>"}var e=this,f="",g=(e.options.max-e.options.min)/e.options.step,h={first:"label",last:"label",rest:"pip",labels:!1,prefix:"",suffix:"",step:g>100?Math.floor(.05*g):1,formatLabel:function(a){return this.prefix+a+this.suffix}};a.extend(h,b),e.element.addClass("ui-slider-pips").find(".ui-slider-pip").remove(),h.step=Math.round(h.step),d("first");for(var i=1;g>i;i++)0===i%h.step&&d(i);d("last"),e.element.append(f),e.element.on("mousedown",".ui-slider-label",function(a){a.stopPropagation(),c(this)})}};a.extend(!0,a.ui.slider.prototype,b)}(jQuery),function(a){"use strict";var b={"float":function(b){var c,d,e=this,f=[],g={handle:!0,pips:!1,labels:!1,prefix:"",suffix:"",event:"slidechange slide",formatLabel:function(a){return this.prefix+a+this.suffix}};a.extend(g,b),e.options.value<e.options.min&&(e.options.value=e.options.min),e.options.value>e.options.max&&(e.options.value=e.options.max),e.options.values&&(e.options.values[0]<e.options.min&&(e.options.values[0]=e.options.min),e.options.values[1]<e.options.min&&(e.options.values[1]=e.options.min),e.options.values[0]>e.options.max&&(e.options.values[0]=e.options.max),e.options.values[1]>e.options.max&&(e.options.values[1]=e.options.max)),e.element.addClass("ui-slider-float").find(".ui-slider-tip, .ui-slider-tip-label").remove(),g.handle&&(e.options.values?(g.labels?(f[0]=g.labels[e.options.values[0]-e.options.min],f[1]=g.labels[e.options.values[1]-e.options.min],"undefined"==typeof f[0]&&(f[0]=e.options.values[0]),"undefined"==typeof f[1]&&(f[1]=e.options.values[1])):(f[0]=e.options.values[0],f[1]=e.options.values[1]),c=[a('<span class="ui-slider-tip">'+g.formatLabel(f[0])+"</span>"),a('<span class="ui-slider-tip">'+g.formatLabel(f[1])+"</span>")]):(g.labels?(d=g.labels[e.options.value-e.options.min],"undefined"==typeof d&&(d=e.options.value)):d=e.options.value,c=a('<span class="ui-slider-tip">'+g.formatLabel(d)+"</span>")),e.element.find(".ui-slider-handle").each(function(b,d){a(d).append(c[b])})),g.pips&&e.element.find(".ui-slider-label").each(function(b,c){var d=a(c).clone().removeClass("ui-slider-label").addClass("ui-slider-tip-label");d.insertAfter(a(c))}),"slide"!==g.event&&"slidechange"!==g.event&&"slide slidechange"!==g.event&&"slidechange slide"!==g.event&&(g.event="slidechange slide"),e.element.on(g.event,function(b,c){var d;g.labels?(d=g.labels[c.value-e.options.min],"undefined"==typeof d&&(d=c.value)):d=c.value,a(c.handle).find(".ui-slider-tip").html(g.formatLabel(d))})}};a.extend(!0,a.ui.slider.prototype,b)}(jQuery);
/*
 Highcharts JS v9.2.2 (2021-08-24)

 (c) 2009-2021 Torstein Honsi

 License: www.highcharts.com/license
*/
'use strict';(function(aa,M){"object"===typeof module&&module.exports?(M["default"]=M,module.exports=aa.document?M(aa):M):"function"===typeof define&&define.amd?define("highcharts/highcharts",function(){return M(aa)}):(aa.Highcharts&&aa.Highcharts.error(16,!0),aa.Highcharts=M(aa))})("undefined"!==typeof window?window:this,function(aa){function M(r,a,C,E){r.hasOwnProperty(a)||(r[a]=E.apply(null,C))}var a={};M(a,"Core/Globals.js",[],function(){var r="undefined"!==typeof aa?aa:"undefined"!==typeof window?
window:{},a;(function(a){a.SVG_NS="http://www.w3.org/2000/svg";a.product="Highcharts";a.version="9.2.2";a.win=r;a.doc=a.win.document;a.svg=a.doc&&a.doc.createElementNS&&!!a.doc.createElementNS(a.SVG_NS,"svg").createSVGRect;a.userAgent=a.win.navigator&&a.win.navigator.userAgent||"";a.isChrome=-1!==a.userAgent.indexOf("Chrome");a.isFirefox=-1!==a.userAgent.indexOf("Firefox");a.isMS=/(edge|msie|trident)/i.test(a.userAgent)&&!a.win.opera;a.isSafari=!a.isChrome&&-1!==a.userAgent.indexOf("Safari");a.isTouchDevice=
/(Mobile|Android|Windows Phone)/.test(a.userAgent);a.isWebKit=-1!==a.userAgent.indexOf("AppleWebKit");a.deg2rad=2*Math.PI/360;a.hasBidiBug=a.isFirefox&&4>parseInt(a.userAgent.split("Firefox/")[1],10);a.hasTouch=!!a.win.TouchEvent;a.marginNames=["plotTop","marginRight","marginBottom","plotLeft"];a.noop=function(){};a.supportsPassiveEvents=function(){var r=!1;if(!a.isMS){var w=Object.defineProperty({},"passive",{get:function(){r=!0}});a.win.addEventListener&&a.win.removeEventListener&&(a.win.addEventListener("testPassive",
a.noop,w),a.win.removeEventListener("testPassive",a.noop,w))}return r}();a.charts=[];a.dateFormats={};a.seriesTypes={};a.symbolSizes={};a.chartCount=0})(a||(a={}));"";return a});M(a,"Core/Utilities.js",[a["Core/Globals.js"]],function(a){function r(b,d,e,p){var y=d?"Highcharts error":"Highcharts warning";32===b&&(b=y+": Deprecated member");var F=m(b),c=F?y+" #"+b+": www.highcharts.com/errors/"+b+"/":b.toString();if("undefined"!==typeof p){var k="";F&&(c+="?");I(p,function(b,K){k+="\n - "+K+": "+b;
F&&(c+=encodeURI(K)+"="+encodeURI(b))});c+=k}B(a,"displayError",{chart:e,code:b,message:c,params:p},function(){if(d)throw Error(c);h.console&&-1===r.messages.indexOf(c)&&console.warn(c)});r.messages.push(c)}function C(b,d){var y={};I(b,function(h,c){if(J(b[c],!0)&&!b.nodeType&&d[c])h=C(b[c],d[c]),Object.keys(h).length&&(y[c]=h);else if(J(b[c])||b[c]!==d[c])y[c]=b[c]});return y}function E(b,d){return parseInt(b,d||10)}function z(b){return"string"===typeof b}function x(b){b=Object.prototype.toString.call(b);
return"[object Array]"===b||"[object Array Iterator]"===b}function J(b,d){return!!b&&"object"===typeof b&&(!d||!x(b))}function u(b){return J(b)&&"number"===typeof b.nodeType}function n(b){var d=b&&b.constructor;return!(!J(b,!0)||u(b)||!d||!d.name||"Object"===d.name)}function m(b){return"number"===typeof b&&!isNaN(b)&&Infinity>b&&-Infinity<b}function g(b){return"undefined"!==typeof b&&null!==b}function c(b,d,h){var y;z(d)?g(h)?b.setAttribute(d,h):b&&b.getAttribute&&((y=b.getAttribute(d))||"class"!==
d||(y=b.getAttribute(d+"Name"))):I(d,function(d,y){b.setAttribute(y,d)});return y}function e(b,d){var y;b||(b={});for(y in d)b[y]=d[y];return b}function l(){for(var b=arguments,d=b.length,h=0;h<d;h++){var c=b[h];if("undefined"!==typeof c&&null!==c)return c}}function f(b,d){a.isMS&&!a.svg&&d&&"undefined"!==typeof d.opacity&&(d.filter="alpha(opacity="+100*d.opacity+")");e(b.style,d)}function v(b,d,h,c,p){b=t.createElement(b);d&&e(b,d);p&&f(b,{padding:"0",border:"none",margin:"0"});h&&f(b,h);c&&c.appendChild(b);
return b}function q(b,d){return parseFloat(b.toPrecision(d||14))}function k(b,d,c){var y=a.getStyle||k;if("width"===d)return d=Math.min(b.offsetWidth,b.scrollWidth),c=b.getBoundingClientRect&&b.getBoundingClientRect().width,c<d&&c>=d-1&&(d=Math.floor(c)),Math.max(0,d-(y(b,"padding-left",!0)||0)-(y(b,"padding-right",!0)||0));if("height"===d)return Math.max(0,Math.min(b.offsetHeight,b.scrollHeight)-(y(b,"padding-top",!0)||0)-(y(b,"padding-bottom",!0)||0));h.getComputedStyle||r(27,!0);if(b=h.getComputedStyle(b,
void 0)){var e=b.getPropertyValue(d);l(c,"opacity"!==d)&&(e=E(e))}return e}function I(b,d,h){for(var y in b)Object.hasOwnProperty.call(b,y)&&d.call(h||b[y],b[y],y,b)}function D(b,d,h){function y(d,H){var K=b.removeEventListener||a.removeEventListenerPolyfill;K&&K.call(b,d,H,!1)}function c(h){var H;if(b.nodeName){if(d){var K={};K[d]=!0}else K=h;I(K,function(b,d){if(h[d])for(H=h[d].length;H--;)y(d,h[d][H].fn)})}}var e="function"===typeof b&&b.prototype||b;if(Object.hasOwnProperty.call(e,"hcEvents")){var p=
e.hcEvents;d?(e=p[d]||[],h?(p[d]=e.filter(function(b){return h!==b.fn}),y(d,h)):(c(p),p[d]=[])):(c(p),delete e.hcEvents)}}function B(b,d,h,c){h=h||{};if(t.createEvent&&(b.dispatchEvent||b.fireEvent&&b!==a)){var y=t.createEvent("Events");y.initEvent(d,!0,!0);h=e(y,h);b.dispatchEvent?b.dispatchEvent(h):b.fireEvent(d,h)}else if(b.hcEvents){h.target||e(h,{preventDefault:function(){h.defaultPrevented=!0},target:b,type:d});y=[];for(var p=b,k=!1;p.hcEvents;)Object.hasOwnProperty.call(p,"hcEvents")&&p.hcEvents[d]&&
(y.length&&(k=!0),y.unshift.apply(y,p.hcEvents[d])),p=Object.getPrototypeOf(p);k&&y.sort(function(b,d){return b.order-d.order});y.forEach(function(d){!1===d.fn.call(b,h)&&h.preventDefault()})}c&&!h.defaultPrevented&&c.call(b,h)}var O=a.charts,t=a.doc,h=a.win;(r||(r={})).messages=[];var d;Math.easeInOutSine=function(b){return-.5*(Math.cos(Math.PI*b)-1)};var b=Array.prototype.find?function(b,d){return b.find(d)}:function(b,d){var h,y=b.length;for(h=0;h<y;h++)if(d(b[h],h))return b[h]};I({map:"map",each:"forEach",
grep:"filter",reduce:"reduce",some:"some"},function(b,d){a[d]=function(h){var y;r(32,!1,void 0,(y={},y["Highcharts."+d]="use Array."+b,y));return Array.prototype[b].apply(h,[].slice.call(arguments,1))}});var p,G=function(){var b=Math.random().toString(36).substring(2,9)+"-",d=0;return function(){return"highcharts-"+(p?"":b)+d++}}();h.jQuery&&(h.jQuery.fn.highcharts=function(){var b=[].slice.call(arguments);if(this[0])return b[0]?(new (a[z(b[0])?b.shift():"Chart"])(this[0],b[0],b[1]),this):O[c(this[0],
"data-highcharts-chart")]});b={addEvent:function(b,d,h,c){void 0===c&&(c={});var y="function"===typeof b&&b.prototype||b;Object.hasOwnProperty.call(y,"hcEvents")||(y.hcEvents={});y=y.hcEvents;a.Point&&b instanceof a.Point&&b.series&&b.series.chart&&(b.series.chart.runTrackerClick=!0);var p=b.addEventListener||a.addEventListenerPolyfill;p&&p.call(b,d,h,a.supportsPassiveEvents?{passive:void 0===c.passive?-1!==d.indexOf("touch"):c.passive,capture:!1}:!1);y[d]||(y[d]=[]);y[d].push({fn:h,order:"number"===
typeof c.order?c.order:Infinity});y[d].sort(function(b,d){return b.order-d.order});return function(){D(b,d,h)}},arrayMax:function(b){for(var d=b.length,h=b[0];d--;)b[d]>h&&(h=b[d]);return h},arrayMin:function(b){for(var d=b.length,h=b[0];d--;)b[d]<h&&(h=b[d]);return h},attr:c,clamp:function(b,d,h){return b>d?b<h?b:h:d},cleanRecursively:C,clearTimeout:function(b){g(b)&&clearTimeout(b)},correctFloat:q,createElement:v,css:f,defined:g,destroyObjectProperties:function(b,d){I(b,function(h,c){h&&h!==d&&
h.destroy&&h.destroy();delete b[c]})},discardElement:function(b){d||(d=v("div"));b&&d.appendChild(b);d.innerHTML=""},erase:function(b,d){for(var h=b.length;h--;)if(b[h]===d){b.splice(h,1);break}},error:r,extend:e,extendClass:function(b,d){var h=function(){};h.prototype=new b;e(h.prototype,d);return h},find:b,fireEvent:B,getMagnitude:function(b){return Math.pow(10,Math.floor(Math.log(b)/Math.LN10))},getNestedProperty:function(b,d){for(b=b.split(".");b.length&&g(d);){var c=b.shift();if("undefined"===
typeof c||"__proto__"===c)return;d=d[c];if(!g(d)||"function"===typeof d||"number"===typeof d.nodeType||d===h)return}return d},getStyle:k,inArray:function(b,d,h){r(32,!1,void 0,{"Highcharts.inArray":"use Array.indexOf"});return d.indexOf(b,h)},isArray:x,isClass:n,isDOMElement:u,isFunction:function(b){return"function"===typeof b},isNumber:m,isObject:J,isString:z,keys:function(b){r(32,!1,void 0,{"Highcharts.keys":"use Object.keys"});return Object.keys(b)},merge:function(){var b,d=arguments,h={},c=function(b,
d){"object"!==typeof b&&(b={});I(d,function(h,H){"__proto__"!==H&&"constructor"!==H&&(!J(h,!0)||n(h)||u(h)?b[H]=d[H]:b[H]=c(b[H]||{},h))});return b};!0===d[0]&&(h=d[1],d=Array.prototype.slice.call(d,2));var p=d.length;for(b=0;b<p;b++)h=c(h,d[b]);return h},normalizeTickInterval:function(b,d,h,c,p){var e=b;h=l(h,1);var k=b/h;d||(d=p?[1,1.2,1.5,2,2.5,3,4,5,6,8,10]:[1,2,2.5,5,10],!1===c&&(1===h?d=d.filter(function(b){return 0===b%1}):.1>=h&&(d=[1/h])));for(c=0;c<d.length&&!(e=d[c],p&&e*h>=b||!p&&k<=(d[c]+
(d[c+1]||d[c]))/2);c++);return e=q(e*h,-Math.round(Math.log(.001)/Math.LN10))},objectEach:I,offset:function(b){var d=t.documentElement;b=b.parentElement||b.parentNode?b.getBoundingClientRect():{top:0,left:0,width:0,height:0};return{top:b.top+(h.pageYOffset||d.scrollTop)-(d.clientTop||0),left:b.left+(h.pageXOffset||d.scrollLeft)-(d.clientLeft||0),width:b.width,height:b.height}},pad:function(b,d,h){return Array((d||2)+1-String(b).replace("-","").length).join(h||"0")+b},pick:l,pInt:E,relativeLength:function(b,
d,h){return/%$/.test(b)?d*parseFloat(b)/100+(h||0):parseFloat(b)},removeEvent:D,splat:function(b){return x(b)?b:[b]},stableSort:function(b,d){var h=b.length,c,p;for(p=0;p<h;p++)b[p].safeI=p;b.sort(function(b,h){c=d(b,h);return 0===c?b.safeI-h.safeI:c});for(p=0;p<h;p++)delete b[p].safeI},syncTimeout:function(b,d,h){if(0<d)return setTimeout(b,d,h);b.call(0,h);return-1},timeUnits:{millisecond:1,second:1E3,minute:6E4,hour:36E5,day:864E5,week:6048E5,month:24192E5,year:314496E5},uniqueKey:G,useSerialIds:function(b){return p=
l(b,p)},wrap:function(b,d,h){var c=b[d];b[d]=function(){var b=Array.prototype.slice.call(arguments),d=arguments,p=this;p.proceed=function(){c.apply(p,arguments.length?arguments:d)};b.unshift(c);b=h.apply(this,b);p.proceed=null;return b}}};"";return b});M(a,"Core/Color/Palette.js",[],function(){return{colors:"#7cb5ec #434348 #90ed7d #f7a35c #8085e9 #f15c80 #e4d354 #2b908f #f45b5b #91e8e1".split(" "),backgroundColor:"#ffffff",neutralColor100:"#000000",neutralColor80:"#333333",neutralColor60:"#666666",
neutralColor40:"#999999",neutralColor20:"#cccccc",neutralColor10:"#e6e6e6",neutralColor5:"#f2f2f2",neutralColor3:"#f7f7f7",highlightColor100:"#003399",highlightColor80:"#335cad",highlightColor60:"#6685c2",highlightColor20:"#ccd6eb",highlightColor10:"#e6ebf5",positiveColor:"#06b535",negativeColor:"#f21313"}});M(a,"Core/Chart/ChartDefaults.js",[a["Core/Color/Palette.js"]],function(a){return{panning:{enabled:!1,type:"x"},styledMode:!1,borderRadius:0,colorCount:10,defaultSeriesType:"line",ignoreHiddenSeries:!0,
spacing:[10,10,15,10],resetZoomButton:{theme:{zIndex:6},position:{align:"right",x:-10,y:10}},zoomBySingleTouch:!1,width:null,height:null,borderColor:a.highlightColor80,backgroundColor:a.backgroundColor,plotBorderColor:a.neutralColor20}});M(a,"Core/Color/Color.js",[a["Core/Globals.js"],a["Core/Utilities.js"]],function(a,w){var r=w.isNumber,E=w.merge,z=w.pInt;w=function(){function x(r){this.rgba=[NaN,NaN,NaN,NaN];this.input=r;var u=a.Color;if(u&&u!==x)return new u(r);if(!(this instanceof x))return new x(r);
this.init(r)}x.parse=function(a){return a?new x(a):x.None};x.prototype.init=function(a){var u;if("object"===typeof a&&"undefined"!==typeof a.stops)this.stops=a.stops.map(function(c){return new x(c[1])});else if("string"===typeof a){this.input=a=x.names[a.toLowerCase()]||a;if("#"===a.charAt(0)){var n=a.length;var m=parseInt(a.substr(1),16);7===n?u=[(m&16711680)>>16,(m&65280)>>8,m&255,1]:4===n&&(u=[(m&3840)>>4|(m&3840)>>8,(m&240)>>4|m&240,(m&15)<<4|m&15,1])}if(!u)for(m=x.parsers.length;m--&&!u;){var g=
x.parsers[m];(n=g.regex.exec(a))&&(u=g.parse(n))}}u&&(this.rgba=u)};x.prototype.get=function(a){var u=this.input,n=this.rgba;if("object"===typeof u&&"undefined"!==typeof this.stops){var m=E(u);m.stops=[].slice.call(m.stops);this.stops.forEach(function(g,c){m.stops[c]=[m.stops[c][0],g.get(a)]});return m}return n&&r(n[0])?"rgb"===a||!a&&1===n[3]?"rgb("+n[0]+","+n[1]+","+n[2]+")":"a"===a?""+n[3]:"rgba("+n.join(",")+")":u};x.prototype.brighten=function(a){var u=this.rgba;if(this.stops)this.stops.forEach(function(m){m.brighten(a)});
else if(r(a)&&0!==a)for(var n=0;3>n;n++)u[n]+=z(255*a),0>u[n]&&(u[n]=0),255<u[n]&&(u[n]=255);return this};x.prototype.setOpacity=function(a){this.rgba[3]=a;return this};x.prototype.tweenTo=function(a,u){var n=this.rgba,m=a.rgba;if(!r(n[0])||!r(m[0]))return a.input||"none";a=1!==m[3]||1!==n[3];return(a?"rgba(":"rgb(")+Math.round(m[0]+(n[0]-m[0])*(1-u))+","+Math.round(m[1]+(n[1]-m[1])*(1-u))+","+Math.round(m[2]+(n[2]-m[2])*(1-u))+(a?","+(m[3]+(n[3]-m[3])*(1-u)):"")+")"};x.names={white:"#ffffff",black:"#000000"};
x.parsers=[{regex:/rgba\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]?(?:\.[0-9]+)?)\s*\)/,parse:function(a){return[z(a[1]),z(a[2]),z(a[3]),parseFloat(a[4],10)]}},{regex:/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/,parse:function(a){return[z(a[1]),z(a[2]),z(a[3]),1]}}];x.None=new x("");return x}();"";return w});M(a,"Core/Time.js",[a["Core/Globals.js"],a["Core/Utilities.js"]],function(a,w){var r=a.win,E=w.defined,z=w.error,x=w.extend,J=w.isObject,u=w.merge,
n=w.objectEach,m=w.pad,g=w.pick,c=w.splat,e=w.timeUnits,l=a.isSafari&&r.Intl&&r.Intl.DateTimeFormat.prototype.formatRange,f=a.isSafari&&r.Intl&&!r.Intl.DateTimeFormat.prototype.formatRange;w=function(){function v(c){this.options={};this.variableTimezone=this.useUTC=!1;this.Date=r.Date;this.getTimezoneOffset=this.timezoneOffsetFunction();this.update(c)}v.prototype.get=function(c,e){if(this.variableTimezone||this.timezoneOffset){var k=e.getTime(),f=k-this.getTimezoneOffset(e);e.setTime(f);c=e["getUTC"+
c]();e.setTime(k);return c}return this.useUTC?e["getUTC"+c]():e["get"+c]()};v.prototype.set=function(c,e,f){if(this.variableTimezone||this.timezoneOffset){if("Milliseconds"===c||"Seconds"===c||"Minutes"===c&&0===this.getTimezoneOffset(e)%36E5)return e["setUTC"+c](f);var k=this.getTimezoneOffset(e);k=e.getTime()-k;e.setTime(k);e["setUTC"+c](f);c=this.getTimezoneOffset(e);k=e.getTime()+c;return e.setTime(k)}return this.useUTC||l&&"FullYear"===c?e["setUTC"+c](f):e["set"+c](f)};v.prototype.update=function(c){var e=
g(c&&c.useUTC,!0);this.options=c=u(!0,this.options||{},c);this.Date=c.Date||r.Date||Date;this.timezoneOffset=(this.useUTC=e)&&c.timezoneOffset;this.getTimezoneOffset=this.timezoneOffsetFunction();this.variableTimezone=e&&!(!c.getTimezoneOffset&&!c.timezone)};v.prototype.makeTime=function(c,e,l,v,B,a){if(this.useUTC){var k=this.Date.UTC.apply(0,arguments);var h=this.getTimezoneOffset(k);k+=h;var d=this.getTimezoneOffset(k);h!==d?k+=d-h:h-36E5!==this.getTimezoneOffset(k-36E5)||f||(k-=36E5)}else k=(new this.Date(c,
e,g(l,1),g(v,0),g(B,0),g(a,0))).getTime();return k};v.prototype.timezoneOffsetFunction=function(){var c=this,e=this.options,f=e.moment||r.moment;if(!this.useUTC)return function(c){return 6E4*(new Date(c.toString())).getTimezoneOffset()};if(e.timezone){if(f)return function(c){return 6E4*-f.tz(c,e.timezone).utcOffset()};z(25)}return this.useUTC&&e.getTimezoneOffset?function(c){return 6E4*e.getTimezoneOffset(c.valueOf())}:function(){return 6E4*(c.timezoneOffset||0)}};v.prototype.dateFormat=function(c,
e,f){if(!E(e)||isNaN(e))return a.defaultOptions.lang&&a.defaultOptions.lang.invalidDate||"";c=g(c,"%Y-%m-%d %H:%M:%S");var k=this,l=new this.Date(e),q=this.get("Hours",l),t=this.get("Day",l),h=this.get("Date",l),d=this.get("Month",l),b=this.get("FullYear",l),p=a.defaultOptions.lang,G=p&&p.weekdays,y=p&&p.shortWeekdays;l=x({a:y?y[t]:G[t].substr(0,3),A:G[t],d:m(h),e:m(h,2," "),w:t,b:p.shortMonths[d],B:p.months[d],m:m(d+1),o:d+1,y:b.toString().substr(2,2),Y:b,H:m(q),k:q,I:m(q%12||12),l:q%12||12,M:m(this.get("Minutes",
l)),p:12>q?"AM":"PM",P:12>q?"am":"pm",S:m(l.getSeconds()),L:m(Math.floor(e%1E3),3)},a.dateFormats);n(l,function(b,d){for(;-1!==c.indexOf("%"+d);)c=c.replace("%"+d,"function"===typeof b?b.call(k,e):b)});return f?c.substr(0,1).toUpperCase()+c.substr(1):c};v.prototype.resolveDTLFormat=function(e){return J(e,!0)?e:(e=c(e),{main:e[0],from:e[1],to:e[2]})};v.prototype.getTimeTicks=function(c,k,f,l){var q=this,v=[],t={},h=new q.Date(k),d=c.unitRange,b=c.count||1,p;l=g(l,1);if(E(k)){q.set("Milliseconds",h,
d>=e.second?0:b*Math.floor(q.get("Milliseconds",h)/b));d>=e.second&&q.set("Seconds",h,d>=e.minute?0:b*Math.floor(q.get("Seconds",h)/b));d>=e.minute&&q.set("Minutes",h,d>=e.hour?0:b*Math.floor(q.get("Minutes",h)/b));d>=e.hour&&q.set("Hours",h,d>=e.day?0:b*Math.floor(q.get("Hours",h)/b));d>=e.day&&q.set("Date",h,d>=e.month?1:Math.max(1,b*Math.floor(q.get("Date",h)/b)));if(d>=e.month){q.set("Month",h,d>=e.year?0:b*Math.floor(q.get("Month",h)/b));var G=q.get("FullYear",h)}d>=e.year&&q.set("FullYear",
h,G-G%b);d===e.week&&(G=q.get("Day",h),q.set("Date",h,q.get("Date",h)-G+l+(G<l?-7:0)));G=q.get("FullYear",h);l=q.get("Month",h);var y=q.get("Date",h),a=q.get("Hours",h);k=h.getTime();!q.variableTimezone&&q.useUTC||!E(f)||(p=f-k>4*e.month||q.getTimezoneOffset(k)!==q.getTimezoneOffset(f));k=h.getTime();for(h=1;k<f;)v.push(k),k=d===e.year?q.makeTime(G+h*b,0):d===e.month?q.makeTime(G,l+h*b):!p||d!==e.day&&d!==e.week?p&&d===e.hour&&1<b?q.makeTime(G,l,y,a+h*b):k+d*b:q.makeTime(G,l,y+h*b*(d===e.day?1:7)),
h++;v.push(k);d<=e.hour&&1E4>v.length&&v.forEach(function(b){0===b%18E5&&"000000000"===q.dateFormat("%H%M%S%L",b)&&(t[b]="day")})}v.info=x(c,{higherRanks:t,totalRange:d*b});return v};v.prototype.getDateFormat=function(c,k,f,g){var l=this.dateFormat("%m-%d %H:%M:%S.%L",k),q={millisecond:15,second:12,minute:9,hour:6,day:3},t="millisecond";for(h in e){if(c===e.week&&+this.dateFormat("%w",k)===f&&"00:00:00.000"===l.substr(6)){var h="week";break}if(e[h]>c){h=t;break}if(q[h]&&l.substr(q[h])!=="01-01 00:00:00.000".substr(q[h]))break;
"week"!==h&&(t=h)}if(h)var d=this.resolveDTLFormat(g[h]).main;return d};return v}();"";return w});M(a,"Core/DefaultOptions.js",[a["Core/Chart/ChartDefaults.js"],a["Core/Color/Color.js"],a["Core/Globals.js"],a["Core/Color/Palette.js"],a["Core/Time.js"],a["Core/Utilities.js"]],function(a,w,C,E,z,x){w=w.parse;var r=x.merge,u={colors:E.colors,symbols:["circle","diamond","square","triangle","triangle-down"],lang:{loading:"Loading...",months:"January February March April May June July August September October November December".split(" "),
shortMonths:"Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec".split(" "),weekdays:"Sunday Monday Tuesday Wednesday Thursday Friday Saturday".split(" "),decimalPoint:".",numericSymbols:"kMGTPE".split(""),resetZoom:"Reset zoom",resetZoomTitle:"Reset zoom level 1:1",thousandsSep:" "},global:{},time:{Date:void 0,getTimezoneOffset:void 0,timezone:void 0,timezoneOffset:0,useUTC:!0},chart:a,title:{text:"Chart title",align:"center",margin:15,widthAdjust:-44},subtitle:{text:"",align:"center",widthAdjust:-44},
caption:{margin:15,text:"",align:"left",verticalAlign:"bottom"},plotOptions:{},labels:{style:{position:"absolute",color:E.neutralColor80}},legend:{enabled:!0,align:"center",alignColumns:!0,className:"highcharts-no-tooltip",layout:"horizontal",labelFormatter:function(){return this.name},borderColor:E.neutralColor40,borderRadius:0,navigation:{activeColor:E.highlightColor100,inactiveColor:E.neutralColor20},itemStyle:{color:E.neutralColor80,cursor:"pointer",fontSize:"12px",fontWeight:"bold",textOverflow:"ellipsis"},
itemHoverStyle:{color:E.neutralColor100},itemHiddenStyle:{color:E.neutralColor20},shadow:!1,itemCheckboxStyle:{position:"absolute",width:"13px",height:"13px"},squareSymbol:!0,symbolPadding:5,verticalAlign:"bottom",x:0,y:0,title:{style:{fontWeight:"bold"}}},loading:{labelStyle:{fontWeight:"bold",position:"relative",top:"45%"},style:{position:"absolute",backgroundColor:E.backgroundColor,opacity:.5,textAlign:"center"}},tooltip:{enabled:!0,animation:C.svg,borderRadius:3,dateTimeLabelFormats:{millisecond:"%A, %b %e, %H:%M:%S.%L",
second:"%A, %b %e, %H:%M:%S",minute:"%A, %b %e, %H:%M",hour:"%A, %b %e, %H:%M",day:"%A, %b %e, %Y",week:"Week from %A, %b %e, %Y",month:"%B %Y",year:"%Y"},footerFormat:"",headerShape:"callout",hideDelay:500,padding:8,shape:"callout",shared:!1,snap:C.isTouchDevice?25:10,headerFormat:'<span style="font-size: 10px">{point.key}</span><br/>',pointFormat:'<span style="color:{point.color}">\u25cf</span> {series.name}: <b>{point.y}</b><br/>',backgroundColor:w(E.neutralColor3).setOpacity(.85).get(),borderWidth:1,
shadow:!0,stickOnContact:!1,style:{color:E.neutralColor80,cursor:"default",fontSize:"12px",whiteSpace:"nowrap"},useHTML:!1},credits:{enabled:!0,href:"https://www.highcharts.com?credits",position:{align:"right",x:-10,verticalAlign:"bottom",y:-5},style:{cursor:"pointer",color:E.neutralColor40,fontSize:"9px"},text:"Highcharts.com"}};u.chart.styledMode=!1;"";var n=new z(r(u.global,u.time));a={defaultOptions:u,defaultTime:n,getOptions:function(){return u},setOptions:function(a){r(!0,u,a);if(a.time||a.global)C.time?
C.time.update(r(u.global,u.time,a.global,a.time)):C.time=n;return u}};"";return a});M(a,"Core/Animation/Fx.js",[a["Core/Color/Color.js"],a["Core/Globals.js"],a["Core/Utilities.js"]],function(a,w,C){var r=a.parse,z=w.win,x=C.isNumber,J=C.objectEach;return function(){function a(a,m,g){this.pos=NaN;this.options=m;this.elem=a;this.prop=g}a.prototype.dSetter=function(){var a=this.paths,m=a&&a[0];a=a&&a[1];var g=this.now||0,c=[];if(1!==g&&m&&a)if(m.length===a.length&&1>g)for(var e=0;e<a.length;e++){for(var l=
m[e],f=a[e],v=[],q=0;q<f.length;q++){var k=l[q],I=f[q];x(k)&&x(I)&&("A"!==f[0]||4!==q&&5!==q)?v[q]=k+g*(I-k):v[q]=I}c.push(v)}else c=a;else c=this.toD||[];this.elem.attr("d",c,void 0,!0)};a.prototype.update=function(){var a=this.elem,m=this.prop,g=this.now,c=this.options.step;if(this[m+"Setter"])this[m+"Setter"]();else a.attr?a.element&&a.attr(m,g,null,!0):a.style[m]=g+this.unit;c&&c.call(a,g,this)};a.prototype.run=function(n,m,g){var c=this,e=c.options,l=function(e){return l.stopped?!1:c.step(e)},
f=z.requestAnimationFrame||function(c){setTimeout(c,13)},v=function(){for(var c=0;c<a.timers.length;c++)a.timers[c]()||a.timers.splice(c--,1);a.timers.length&&f(v)};n!==m||this.elem["forceAnimate:"+this.prop]?(this.startTime=+new Date,this.start=n,this.end=m,this.unit=g,this.now=this.start,this.pos=0,l.elem=this.elem,l.prop=this.prop,l()&&1===a.timers.push(l)&&f(v)):(delete e.curAnim[this.prop],e.complete&&0===Object.keys(e.curAnim).length&&e.complete.call(this.elem))};a.prototype.step=function(a){var m=
+new Date,g=this.options,c=this.elem,e=g.complete,l=g.duration,f=g.curAnim;if(c.attr&&!c.element)a=!1;else if(a||m>=l+this.startTime){this.now=this.end;this.pos=1;this.update();var v=f[this.prop]=!0;J(f,function(c){!0!==c&&(v=!1)});v&&e&&e.call(c);a=!1}else this.pos=g.easing((m-this.startTime)/l),this.now=this.start+(this.end-this.start)*this.pos,this.update(),a=!0;return a};a.prototype.initPath=function(a,m,g){function c(c,e){for(;c.length<D;){var f=c[0],h=e[D-c.length];h&&"M"===f[0]&&(c[0]="C"===
h[0]?["C",f[1],f[2],f[1],f[2],f[1],f[2]]:["L",f[1],f[2]]);c.unshift(f);v&&(f=c.pop(),c.push(c[c.length-1],f))}}function e(c,e){for(;c.length<D;)if(e=c[Math.floor(c.length/q)-1].slice(),"C"===e[0]&&(e[1]=e[5],e[2]=e[6]),v){var f=c[Math.floor(c.length/q)].slice();c.splice(c.length/2,0,e,f)}else c.push(e)}var l=a.startX,f=a.endX;g=g.slice();var v=a.isArea,q=v?2:1;m=m&&m.slice();if(!m)return[g,g];if(l&&f&&f.length){for(a=0;a<l.length;a++)if(l[a]===f[0]){var k=a;break}else if(l[0]===f[f.length-l.length+
a]){k=a;var I=!0;break}else if(l[l.length-1]===f[f.length-l.length+a]){k=l.length-a;break}"undefined"===typeof k&&(m=[])}if(m.length&&x(k)){var D=g.length+k*q;I?(c(m,g),e(g,m)):(c(g,m),e(m,g))}return[m,g]};a.prototype.fillSetter=function(){a.prototype.strokeSetter.apply(this,arguments)};a.prototype.strokeSetter=function(){this.elem.attr(this.prop,r(this.start).tweenTo(r(this.end),this.pos),null,!0)};a.timers=[];return a}()});M(a,"Core/Animation/AnimationUtilities.js",[a["Core/Animation/Fx.js"],a["Core/Utilities.js"]],
function(a,w){function r(c){return n(c)?m({duration:500,defer:0},c):{duration:c?500:0,defer:0}}function E(c,g){for(var e=a.timers.length;e--;)a.timers[e].elem!==c||g&&g!==a.timers[e].prop||(a.timers[e].stopped=!0)}var z=w.defined,x=w.getStyle,J=w.isArray,u=w.isNumber,n=w.isObject,m=w.merge,g=w.objectEach,c=w.pick;return{animate:function(c,l,f){var e,q="",k,I;if(!n(f)){var D=arguments;f={duration:D[2],easing:D[3],complete:D[4]}}u(f.duration)||(f.duration=400);f.easing="function"===typeof f.easing?
f.easing:Math[f.easing]||Math.easeInOutSine;f.curAnim=m(l);g(l,function(g,v){E(c,v);I=new a(c,f,v);k=void 0;"d"===v&&J(l.d)?(I.paths=I.initPath(c,c.pathArray,l.d),I.toD=l.d,e=0,k=1):c.attr?e=c.attr(v):(e=parseFloat(x(c,v))||0,"opacity"!==v&&(q="px"));k||(k=g);"string"===typeof k&&k.match("px")&&(k=k.replace(/px/g,""));I.run(e,k,q)})},animObject:r,getDeferredAnimation:function(c,g,f){var e=r(g),a=0,k=0;(f?[f]:c.series).forEach(function(c){c=r(c.options.animation);a=g&&z(g.defer)?e.defer:Math.max(a,
c.duration+c.defer);k=Math.min(e.duration,c.duration)});c.renderer.forExport&&(a=0);return{defer:Math.max(0,a-k),duration:Math.min(a,k)}},setAnimation:function(e,g){g.renderer.globalAnimation=c(e,g.options.chart.animation,!0)},stop:E}});M(a,"Core/Renderer/HTML/AST.js",[a["Core/Globals.js"],a["Core/Utilities.js"]],function(a,w){var r=a.SVG_NS,E=w.attr,z=w.createElement,x=w.discardElement,J=w.error,u=w.isString,n=w.objectEach,m=w.splat;try{var g=!!(new DOMParser).parseFromString("","text/html")}catch(c){g=
!1}w=function(){function c(c){this.nodes="string"===typeof c?this.parseMarkup(c):c}c.filterUserAttributes=function(e){n(e,function(g,f){var a=!0;-1===c.allowedAttributes.indexOf(f)&&(a=!1);-1!==["background","dynsrc","href","lowsrc","src"].indexOf(f)&&(a=u(g)&&c.allowedReferences.some(function(c){return 0===g.indexOf(c)}));a||(J("Highcharts warning: Invalid attribute '"+f+"' in config"),delete e[f])});return e};c.setElementHTML=function(e,g){e.innerHTML="";g&&(new c(g)).addToDOM(e)};c.prototype.addToDOM=
function(e){function g(e,l){var f;m(e).forEach(function(e){var k=e.tagName,q=e.textContent?a.doc.createTextNode(e.textContent):void 0;if(k)if("#text"===k)var v=q;else if(-1!==c.allowedTags.indexOf(k)){k=a.doc.createElementNS("svg"===k?r:l.namespaceURI||r,k);var m=e.attributes||{};n(e,function(c,h){"tagName"!==h&&"attributes"!==h&&"children"!==h&&"textContent"!==h&&(m[h]=c)});E(k,c.filterUserAttributes(m));q&&k.appendChild(q);g(e.children||[],k);v=k}else J("Highcharts warning: Invalid tagName '"+k+
"' in config");v&&l.appendChild(v);f=v});return f}return g(this.nodes,e)};c.prototype.parseMarkup=function(c){var e=[];c=c.trim();if(g)c=(new DOMParser).parseFromString(c,"text/html");else{var f=z("div");f.innerHTML=c;c={body:f}}var a=function(c,e){var f=c.nodeName.toLowerCase(),k={tagName:f};"#text"===f&&(k.textContent=c.textContent||"");if(f=c.attributes){var g={};[].forEach.call(f,function(c){g[c.name]=c.value});k.attributes=g}if(c.childNodes.length){var l=[];[].forEach.call(c.childNodes,function(c){a(c,
l)});l.length&&(k.children=l)}e.push(k)};[].forEach.call(c.body.childNodes,function(c){return a(c,e)});f&&x(f);return e};c.allowedAttributes="aria-controls aria-describedby aria-expanded aria-haspopup aria-hidden aria-label aria-labelledby aria-live aria-pressed aria-readonly aria-roledescription aria-selected class clip-path color colspan cx cy d dx dy disabled fill height href id in markerHeight markerWidth offset opacity orient padding paddingLeft paddingRight patternUnits r refX refY role scope slope src startOffset stdDeviation stroke stroke-linecap stroke-width style tableValues result rowspan summary target tabindex text-align textAnchor textLength type valign width x x1 x2 y y1 y2 zIndex".split(" ");
c.allowedReferences="https:// http:// mailto: / ../ ./ #".split(" ");c.allowedTags="a b br button caption circle clipPath code dd defs div dl dt em feComponentTransfer feFuncA feFuncB feFuncG feFuncR feGaussianBlur feOffset feMerge feMergeNode filter h1 h2 h3 h4 h5 h6 hr i img li linearGradient marker ol p path pattern pre rect small span stop strong style sub sup svg table text thead tbody tspan td th tr u ul #text".split(" ");return c}();"";return w});M(a,"Core/FormatUtilities.js",[a["Core/DefaultOptions.js"],
a["Core/Utilities.js"]],function(a,w){function r(a,g,c,e){a=+a||0;g=+g;var l=E.lang,f=(a.toString().split(".")[1]||"").split("e")[0].length,v=a.toString().split("e"),q=g;if(-1===g)g=Math.min(f,20);else if(!J(g))g=2;else if(g&&v[1]&&0>v[1]){var k=g+ +v[1];0<=k?(v[0]=(+v[0]).toExponential(k).split("e")[0],g=k):(v[0]=v[0].split(".")[0]||0,a=20>g?(v[0]*Math.pow(10,v[1])).toFixed(g):0,v[1]=0)}k=(Math.abs(v[1]?v[0]:a)+Math.pow(10,-Math.max(g,f)-1)).toFixed(g);f=String(n(k));var m=3<f.length?f.length%3:
0;c=u(c,l.decimalPoint);e=u(e,l.thousandsSep);a=(0>a?"-":"")+(m?f.substr(0,m)+e:"");a=0>+v[1]&&!q?"0":a+f.substr(m).replace(/(\d{3})(?=\d)/g,"$1"+e);g&&(a+=c+k.slice(-g));v[1]&&0!==+a&&(a+="e"+v[1]);return a}var E=a.defaultOptions,z=a.defaultTime,x=w.getNestedProperty,J=w.isNumber,u=w.pick,n=w.pInt;return{dateFormat:function(a,g,c){return z.dateFormat(a,g,c)},format:function(a,g,c){var e="{",l=!1,f=/f$/,v=/\.([0-9])/,q=E.lang,k=c&&c.time||z;c=c&&c.numberFormatter||r;for(var m=[];a;){var D=a.indexOf(e);
if(-1===D)break;var B=a.slice(0,D);if(l){B=B.split(":");e=x(B.shift()||"",g);if(B.length&&"number"===typeof e)if(B=B.join(":"),f.test(B)){var u=parseInt((B.match(v)||["","-1"])[1],10);null!==e&&(e=c(e,u,q.decimalPoint,-1<B.indexOf(",")?q.thousandsSep:""))}else e=k.dateFormat(B,e);m.push(e)}else m.push(B);a=a.slice(D+1);e=(l=!l)?"}":"{"}m.push(a);return m.join("")},numberFormat:r}});M(a,"Core/Renderer/RendererUtilities.js",[a["Core/Utilities.js"]],function(a){var r=a.clamp,C=a.pick,E=a.stableSort,
z;(function(a){function x(a,n,m){var g=a,c=g.reducedLen||n,e=function(c,e){return(e.rank||0)-(c.rank||0)},l=function(c,e){return c.target-e.target},f,v=!0,q=[],k=0;for(f=a.length;f--;)k+=a[f].size;if(k>c){E(a,e);for(k=f=0;k<=c;)k+=a[f].size,f++;q=a.splice(f-1,a.length)}E(a,l);for(a=a.map(function(c){return{size:c.size,targets:[c.target],align:C(c.align,.5)}});v;){for(f=a.length;f--;)c=a[f],e=(Math.min.apply(0,c.targets)+Math.max.apply(0,c.targets))/2,c.pos=r(e-c.size*c.align,0,n-c.size);f=a.length;
for(v=!1;f--;)0<f&&a[f-1].pos+a[f-1].size>a[f].pos&&(a[f-1].size+=a[f].size,a[f-1].targets=a[f-1].targets.concat(a[f].targets),a[f-1].align=.5,a[f-1].pos+a[f-1].size>n&&(a[f-1].pos=n-a[f-1].size),a.splice(f,1),v=!0)}g.push.apply(g,q);f=0;a.some(function(c){var e=0;return(c.targets||[]).some(function(){g[f].pos=c.pos+e;if("undefined"!==typeof m&&Math.abs(g[f].pos-g[f].target)>m)return g.slice(0,f+1).forEach(function(c){return delete c.pos}),g.reducedLen=(g.reducedLen||n)-.1*n,g.reducedLen>.1*n&&x(g,
n,m),!0;e+=g[f].size;f++;return!1})});E(g,l);return g}a.distribute=x})(z||(z={}));return z});M(a,"Core/Renderer/SVG/SVGElement.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Renderer/HTML/AST.js"],a["Core/Color/Color.js"],a["Core/Globals.js"],a["Core/Color/Palette.js"],a["Core/Utilities.js"]],function(a,w,C,E,z,x){var r=a.animate,u=a.animObject,n=a.stop,m=E.deg2rad,g=E.doc,c=E.noop,e=E.svg,l=E.SVG_NS,f=E.win,v=x.addEvent,q=x.attr,k=x.createElement,I=x.css,D=x.defined,B=x.erase,O=x.extend,
t=x.fireEvent,h=x.isArray,d=x.isFunction,b=x.isNumber,p=x.isString,G=x.merge,y=x.objectEach,L=x.pick,F=x.pInt,P=x.syncTimeout,S=x.uniqueKey;a=function(){function a(){this.element=void 0;this.onEvents={};this.opacity=1;this.renderer=void 0;this.SVG_NS=l;this.symbolCustomAttribs="x y width height r start end innerR anchorX anchorY rounded".split(" ")}a.prototype._defaultGetter=function(b){b=L(this[b+"Value"],this[b],this.element?this.element.getAttribute(b):null,0);/^[\-0-9\.]+$/.test(b)&&(b=parseFloat(b));
return b};a.prototype._defaultSetter=function(b,d,c){c.setAttribute(d,b)};a.prototype.add=function(b){var d=this.renderer,c=this.element;b&&(this.parentGroup=b);this.parentInverted=b&&b.inverted;"undefined"!==typeof this.textStr&&"text"===this.element.nodeName&&d.buildText(this);this.added=!0;if(!b||b.handleZ||this.zIndex)var K=this.zIndexSetter();K||(b?b.element:d.box).appendChild(c);if(this.onAdd)this.onAdd();return this};a.prototype.addClass=function(b,d){var c=d?"":this.attr("class")||"";b=(b||
"").split(/ /g).reduce(function(b,d){-1===c.indexOf(d)&&b.push(d);return b},c?[c]:[]).join(" ");b!==c&&this.attr("class",b);return this};a.prototype.afterSetters=function(){this.doTransform&&(this.updateTransform(),this.doTransform=!1)};a.prototype.align=function(b,d,c){var K={},h=this.renderer,H=h.alignedObjects,a,e,A;if(b){if(this.alignOptions=b,this.alignByTranslate=d,!c||p(c))this.alignTo=a=c||"renderer",B(H,this),H.push(this),c=void 0}else b=this.alignOptions,d=this.alignByTranslate,a=this.alignTo;
c=L(c,h[a],"scrollablePlotBox"===a?h.plotBox:void 0,h);a=b.align;var f=b.verticalAlign;h=(c.x||0)+(b.x||0);H=(c.y||0)+(b.y||0);"right"===a?e=1:"center"===a&&(e=2);e&&(h+=(c.width-(b.width||0))/e);K[d?"translateX":"x"]=Math.round(h);"bottom"===f?A=1:"middle"===f&&(A=2);A&&(H+=(c.height-(b.height||0))/A);K[d?"translateY":"y"]=Math.round(H);this[this.placed?"animate":"attr"](K);this.placed=!0;this.alignAttr=K;return this};a.prototype.alignSetter=function(b){var d={left:"start",center:"middle",right:"end"};
d[b]&&(this.alignValue=b,this.element.setAttribute("text-anchor",d[b]))};a.prototype.animate=function(b,d,c){var h=this,H=u(L(d,this.renderer.globalAnimation,!0));d=H.defer;L(g.hidden,g.msHidden,g.webkitHidden,!1)&&(H.duration=0);0!==H.duration?(c&&(H.complete=c),P(function(){h.element&&r(h,b,H)},d)):(this.attr(b,void 0,c),y(b,function(b,d){H.step&&H.step.call(this,b,{prop:d,pos:1,elem:this})},this));return this};a.prototype.applyTextOutline=function(b){var d=this.element;-1!==b.indexOf("contrast")&&
(b=b.replace(/contrast/g,this.renderer.getContrast(d.style.fill)));var c=b.split(" ");b=c[c.length-1];if((c=c[0])&&"none"!==c&&E.svg){this.fakeTS=!0;this.ySetter=this.xSetter;c=c.replace(/(^[\d\.]+)(.*?)$/g,function(b,d,c){return 2*Number(d)+c});this.removeTextOutline();var h=g.createElementNS(l,"tspan");q(h,{"class":"highcharts-text-outline",fill:b,stroke:b,"stroke-width":c,"stroke-linejoin":"round"});[].forEach.call(d.childNodes,function(b){var d=b.cloneNode(!0);d.removeAttribute&&["fill","stroke",
"stroke-width","stroke"].forEach(function(b){return d.removeAttribute(b)});h.appendChild(d)});var a=g.createElementNS(l,"tspan");a.textContent="\u200b";["x","y"].forEach(function(b){var c=d.getAttribute(b);c&&a.setAttribute(b,c)});h.appendChild(a);d.insertBefore(h,d.firstChild)}};a.prototype.attr=function(b,d,c,h){var K=this.element,H=this.symbolCustomAttribs,a,e=this,A,p;if("string"===typeof b&&"undefined"!==typeof d){var f=b;b={};b[f]=d}"string"===typeof b?e=(this[b+"Getter"]||this._defaultGetter).call(this,
b,K):(y(b,function(d,c){A=!1;h||n(this,c);this.symbolName&&-1!==H.indexOf(c)&&(a||(this.symbolAttr(b),a=!0),A=!0);!this.rotation||"x"!==c&&"y"!==c||(this.doTransform=!0);A||(p=this[c+"Setter"]||this._defaultSetter,p.call(this,d,c,K),!this.styledMode&&this.shadows&&/^(width|height|visibility|x|y|d|transform|cx|cy|r)$/.test(c)&&this.updateShadows(c,d,p))},this),this.afterSetters());c&&c.call(this);return e};a.prototype.clip=function(b){return this.attr("clip-path",b?"url("+this.renderer.url+"#"+b.id+
")":"none")};a.prototype.crisp=function(b,d){d=d||b.strokeWidth||0;var c=Math.round(d)%2/2;b.x=Math.floor(b.x||this.x||0)+c;b.y=Math.floor(b.y||this.y||0)+c;b.width=Math.floor((b.width||this.width||0)-2*c);b.height=Math.floor((b.height||this.height||0)-2*c);D(b.strokeWidth)&&(b.strokeWidth=d);return b};a.prototype.complexColor=function(b,d,c){var K=this.renderer,a,H,e,p,A,f,k,g,l,q,v=[],F;t(this.renderer,"complexColor",{args:arguments},function(){b.radialGradient?H="radialGradient":b.linearGradient&&
(H="linearGradient");if(H){e=b[H];A=K.gradients;f=b.stops;l=c.radialReference;h(e)&&(b[H]=e={x1:e[0],y1:e[1],x2:e[2],y2:e[3],gradientUnits:"userSpaceOnUse"});"radialGradient"===H&&l&&!D(e.gradientUnits)&&(p=e,e=G(e,K.getRadialAttr(l,p),{gradientUnits:"userSpaceOnUse"}));y(e,function(b,d){"id"!==d&&v.push(d,b)});y(f,function(b){v.push(b)});v=v.join(",");if(A[v])q=A[v].attr("id");else{e.id=q=S();var N=A[v]=K.createElement(H).attr(e).add(K.defs);N.radAttr=p;N.stops=[];f.forEach(function(b){0===b[1].indexOf("rgba")?
(a=C.parse(b[1]),k=a.get("rgb"),g=a.get("a")):(k=b[1],g=1);b=K.createElement("stop").attr({offset:b[0],"stop-color":k,"stop-opacity":g}).add(N);N.stops.push(b)})}F="url("+K.url+"#"+q+")";c.setAttribute(d,F);c.gradient=v;b.toString=function(){return F}}})};a.prototype.css=function(b){var d=this.styles,c={},h=this.element,a=["textOutline","textOverflow","width"],p="",f=!d;b&&b.color&&(b.fill=b.color);d&&y(b,function(b,h){d&&d[h]!==b&&(c[h]=b,f=!0)});if(f){d&&(b=O(d,c));if(b)if(null===b.width||"auto"===
b.width)delete this.textWidth;else if("text"===h.nodeName.toLowerCase()&&b.width)var k=this.textWidth=F(b.width);this.styles=b;k&&!e&&this.renderer.forExport&&delete b.width;if(h.namespaceURI===this.SVG_NS){var A=function(b,d){return"-"+d.toLowerCase()};y(b,function(b,d){-1===a.indexOf(d)&&(p+=d.replace(/([A-Z])/g,A)+":"+b+";")});p&&q(h,"style",p)}else I(h,b);this.added&&("text"===this.element.nodeName&&this.renderer.buildText(this),b&&b.textOutline&&this.applyTextOutline(b.textOutline))}return this};
a.prototype.dashstyleSetter=function(b){var d=this["stroke-width"];"inherit"===d&&(d=1);if(b=b&&b.toLowerCase()){var c=b.replace("shortdashdotdot","3,1,1,1,1,1,").replace("shortdashdot","3,1,1,1").replace("shortdot","1,1,").replace("shortdash","3,1,").replace("longdash","8,3,").replace(/dot/g,"1,3,").replace("dash","4,3,").replace(/,$/,"").split(",");for(b=c.length;b--;)c[b]=""+F(c[b])*L(d,NaN);b=c.join(",").replace(/NaN/g,"none");this.element.setAttribute("stroke-dasharray",b)}};a.prototype.destroy=
function(){var b=this,d=b.element||{},c=b.renderer,h=d.ownerSVGElement,a=c.isSVG&&"SPAN"===d.nodeName&&b.parentGroup||void 0;d.onclick=d.onmouseout=d.onmouseover=d.onmousemove=d.point=null;n(b);if(b.clipPath&&h){var e=b.clipPath;[].forEach.call(h.querySelectorAll("[clip-path],[CLIP-PATH]"),function(b){-1<b.getAttribute("clip-path").indexOf(e.element.id)&&b.removeAttribute("clip-path")});b.clipPath=e.destroy()}if(b.stops){for(h=0;h<b.stops.length;h++)b.stops[h].destroy();b.stops.length=0;b.stops=void 0}b.safeRemoveChild(d);
for(c.styledMode||b.destroyShadows();a&&a.div&&0===a.div.childNodes.length;)d=a.parentGroup,b.safeRemoveChild(a.div),delete a.div,a=d;b.alignTo&&B(c.alignedObjects,b);y(b,function(d,c){b[c]&&b[c].parentGroup===b&&b[c].destroy&&b[c].destroy();delete b[c]})};a.prototype.destroyShadows=function(){(this.shadows||[]).forEach(function(b){this.safeRemoveChild(b)},this);this.shadows=void 0};a.prototype.destroyTextPath=function(b,d){var c=b.getElementsByTagName("text")[0];if(c){if(c.removeAttribute("dx"),
c.removeAttribute("dy"),d.element.setAttribute("id",""),this.textPathWrapper&&c.getElementsByTagName("textPath").length){for(b=this.textPathWrapper.element.childNodes;b.length;)c.appendChild(b[0]);c.removeChild(this.textPathWrapper.element)}}else if(b.getAttribute("dx")||b.getAttribute("dy"))b.removeAttribute("dx"),b.removeAttribute("dy");this.textPathWrapper&&(this.textPathWrapper=this.textPathWrapper.destroy())};a.prototype.dSetter=function(b,d,c){h(b)&&("string"===typeof b[0]&&(b=this.renderer.pathToSegments(b)),
this.pathArray=b,b=b.reduce(function(b,d,c){return d&&d.join?(c?b+" ":"")+d.join(" "):(d||"").toString()},""));/(NaN| {2}|^$)/.test(b)&&(b="M 0 0");this[d]!==b&&(c.setAttribute(d,b),this[d]=b)};a.prototype.fadeOut=function(b){var d=this;d.animate({opacity:0},{duration:L(b,150),complete:function(){d.attr({y:-9999}).hide()}})};a.prototype.fillSetter=function(b,d,c){"string"===typeof b?c.setAttribute(d,b):b&&this.complexColor(b,d,c)};a.prototype.getBBox=function(b,c){var h=this.renderer,K=this.element,
e=this.styles,p=this.textStr,f=h.cache,k=h.cacheKeys,A=K.namespaceURI===this.SVG_NS;c=L(c,this.rotation,0);var g=h.styledMode?K&&a.prototype.getStyle.call(K,"font-size"):e&&e.fontSize,y;if(D(p)){var G=p.toString();-1===G.indexOf("<")&&(G=G.replace(/[0-9]/g,"0"));G+=["",c,g,this.textWidth,e&&e.textOverflow,e&&e.fontWeight].join()}G&&!b&&(y=f[G]);if(!y){if(A||h.forExport){try{var l=this.fakeTS&&function(b){var d=K.querySelector(".highcharts-text-outline");d&&I(d,{display:b})};d(l)&&l("none");y=K.getBBox?
O({},K.getBBox()):{width:K.offsetWidth,height:K.offsetHeight};d(l)&&l("")}catch(Y){""}if(!y||0>y.width)y={width:0,height:0}}else y=this.htmlGetBBox();h.isSVG&&(b=y.width,h=y.height,A&&(y.height=h={"11px,17":14,"13px,20":16}[e&&e.fontSize+","+Math.round(h)]||h),c&&(e=c*m,y.width=Math.abs(h*Math.sin(e))+Math.abs(b*Math.cos(e)),y.height=Math.abs(h*Math.cos(e))+Math.abs(b*Math.sin(e))));if(G&&(""===p||0<y.height)){for(;250<k.length;)delete f[k.shift()];f[G]||k.push(G);f[G]=y}}return y};a.prototype.getStyle=
function(b){return f.getComputedStyle(this.element||this,"").getPropertyValue(b)};a.prototype.hasClass=function(b){return-1!==(""+this.attr("class")).split(" ").indexOf(b)};a.prototype.hide=function(b){b?this.attr({y:-9999}):this.attr({visibility:"hidden"});return this};a.prototype.htmlGetBBox=function(){return{height:0,width:0,x:0,y:0}};a.prototype.init=function(b,d){this.element="span"===d?k(d):g.createElementNS(this.SVG_NS,d);this.renderer=b;t(this,"afterInit")};a.prototype.invert=function(b){this.inverted=
b;this.updateTransform();return this};a.prototype.on=function(b,d){var c=this.onEvents;if(c[b])c[b]();c[b]=v(this.element,b,d);return this};a.prototype.opacitySetter=function(b,d,c){this.opacity=b=Number(Number(b).toFixed(3));c.setAttribute(d,b)};a.prototype.removeClass=function(b){return this.attr("class",(""+this.attr("class")).replace(p(b)?new RegExp("(^| )"+b+"( |$)"):b," ").replace(/ +/g," ").trim())};a.prototype.removeTextOutline=function(){var b=this.element.querySelector("tspan.highcharts-text-outline");
b&&this.safeRemoveChild(b)};a.prototype.safeRemoveChild=function(b){var d=b.parentNode;d&&d.removeChild(b)};a.prototype.setRadialReference=function(b){var d=this.element.gradient&&this.renderer.gradients[this.element.gradient];this.element.radialReference=b;d&&d.radAttr&&d.animate(this.renderer.getRadialAttr(b,d.radAttr));return this};a.prototype.setTextPath=function(d,h){var a=this.element,K=this.text?this.text.element:a,e={textAnchor:"text-anchor"},p=!1,f=this.textPathWrapper,k=!f;h=G(!0,{enabled:!0,
attributes:{dy:-5,startOffset:"50%",textAnchor:"middle"}},h);var A=w.filterUserAttributes(h.attributes);if(d&&h&&h.enabled){f&&null===f.element.parentNode?(k=!0,f=f.destroy()):f&&this.removeTextOutline.call(f.parentGroup);this.options&&this.options.padding&&(A.dx=-this.options.padding);f||(this.textPathWrapper=f=this.renderer.createElement("textPath"),p=!0);var g=f.element;(h=d.element.getAttribute("id"))||d.element.setAttribute("id",h=S());if(k)for(K.setAttribute("y",0),b(A.dx)&&K.setAttribute("x",
-A.dx),d=[].slice.call(K.childNodes),k=0;k<d.length;k++){var l=d[k];l.nodeType!==Node.TEXT_NODE&&"tspan"!==l.nodeName||g.appendChild(l)}p&&f&&f.add({element:K});g.setAttributeNS("http://www.w3.org/1999/xlink","href",this.renderer.url+"#"+h);D(A.dy)&&(g.parentNode.setAttribute("dy",A.dy),delete A.dy);D(A.dx)&&(g.parentNode.setAttribute("dx",A.dx),delete A.dx);y(A,function(b,d){g.setAttribute(e[d]||d,b)});a.removeAttribute("transform");this.removeTextOutline.call(f);this.text&&!this.renderer.styledMode&&
this.attr({fill:"none","stroke-width":0});this.applyTextOutline=this.updateTransform=c}else f&&(delete this.updateTransform,delete this.applyTextOutline,this.destroyTextPath(a,d),this.updateTransform(),this.options&&this.options.rotation&&this.applyTextOutline(this.options.style.textOutline));return this};a.prototype.shadow=function(b,d,c){var h=[],a=this.element,e=this.oldShadowOptions,H={color:z.neutralColor100,offsetX:this.parentInverted?-1:1,offsetY:this.parentInverted?-1:1,opacity:.15,width:3},
p=!1,A;!0===b?A=H:"object"===typeof b&&(A=O(H,b));A&&(A&&e&&y(A,function(b,d){b!==e[d]&&(p=!0)}),p&&this.destroyShadows(),this.oldShadowOptions=A);if(!A)this.destroyShadows();else if(!this.shadows){var f=A.opacity/A.width;var k=this.parentInverted?"translate("+A.offsetY+", "+A.offsetX+")":"translate("+A.offsetX+", "+A.offsetY+")";for(H=1;H<=A.width;H++){var g=a.cloneNode(!1);var G=2*A.width+1-2*H;q(g,{stroke:b.color||z.neutralColor100,"stroke-opacity":f*H,"stroke-width":G,transform:k,fill:"none"});
g.setAttribute("class",(g.getAttribute("class")||"")+" highcharts-shadow");c&&(q(g,"height",Math.max(q(g,"height")-G,0)),g.cutHeight=G);d?d.element.appendChild(g):a.parentNode&&a.parentNode.insertBefore(g,a);h.push(g)}this.shadows=h}return this};a.prototype.show=function(b){return this.attr({visibility:b?"inherit":"visible"})};a.prototype.strokeSetter=function(b,d,c){this[d]=b;this.stroke&&this["stroke-width"]?(a.prototype.fillSetter.call(this,this.stroke,"stroke",c),c.setAttribute("stroke-width",
this["stroke-width"]),this.hasStroke=!0):"stroke-width"===d&&0===b&&this.hasStroke?(c.removeAttribute("stroke"),this.hasStroke=!1):this.renderer.styledMode&&this["stroke-width"]&&(c.setAttribute("stroke-width",this["stroke-width"]),this.hasStroke=!0)};a.prototype.strokeWidth=function(){if(!this.renderer.styledMode)return this["stroke-width"]||0;var b=this.getStyle("stroke-width"),d=0;if(b.indexOf("px")===b.length-2)d=F(b);else if(""!==b){var c=g.createElementNS(l,"rect");q(c,{width:b,"stroke-width":0});
this.element.parentNode.appendChild(c);d=c.getBBox().width;c.parentNode.removeChild(c)}return d};a.prototype.symbolAttr=function(b){var d=this;"x y r start end width height innerR anchorX anchorY clockwise".split(" ").forEach(function(c){d[c]=L(b[c],d[c])});d.attr({d:d.renderer.symbols[d.symbolName](d.x,d.y,d.width,d.height,d)})};a.prototype.textSetter=function(b){b!==this.textStr&&(delete this.textPxLength,this.textStr=b,this.added&&this.renderer.buildText(this))};a.prototype.titleSetter=function(b){var d=
this.element,c=d.getElementsByTagName("title")[0]||g.createElementNS(this.SVG_NS,"title");d.insertBefore?d.insertBefore(c,d.firstChild):d.appendChild(c);c.textContent=String(L(b,"")).replace(/<[^>]*>/g,"").replace(/&lt;/g,"<").replace(/&gt;/g,">")};a.prototype.toFront=function(){var b=this.element;b.parentNode.appendChild(b);return this};a.prototype.translate=function(b,d){return this.attr({translateX:b,translateY:d})};a.prototype.updateShadows=function(b,d,c){var h=this.shadows;if(h)for(var a=h.length;a--;)c.call(h[a],
"height"===b?Math.max(d-(h[a].cutHeight||0),0):"d"===b?this.d:d,b,h[a])};a.prototype.updateTransform=function(){var b=this.scaleX,d=this.scaleY,c=this.inverted,h=this.rotation,a=this.matrix,e=this.element,p=this.translateX||0,f=this.translateY||0;c&&(p+=this.width,f+=this.height);p=["translate("+p+","+f+")"];D(a)&&p.push("matrix("+a.join(",")+")");c?p.push("rotate(90) scale(-1,1)"):h&&p.push("rotate("+h+" "+L(this.rotationOriginX,e.getAttribute("x"),0)+" "+L(this.rotationOriginY,e.getAttribute("y")||
0)+")");(D(b)||D(d))&&p.push("scale("+L(b,1)+" "+L(d,1)+")");p.length&&e.setAttribute("transform",p.join(" "))};a.prototype.visibilitySetter=function(b,d,c){"inherit"===b?c.removeAttribute(d):this[d]!==b&&c.setAttribute(d,b);this[d]=b};a.prototype.xGetter=function(b){"circle"===this.element.nodeName&&("x"===b?b="cx":"y"===b&&(b="cy"));return this._defaultGetter(b)};a.prototype.zIndexSetter=function(b,d){var c=this.renderer,h=this.parentGroup,a=(h||c).element||c.box,e=this.element;c=a===c.box;var p=
!1;var f=this.added;var A;D(b)?(e.setAttribute("data-z-index",b),b=+b,this[d]===b&&(f=!1)):D(this[d])&&e.removeAttribute("data-z-index");this[d]=b;if(f){(b=this.zIndex)&&h&&(h.handleZ=!0);d=a.childNodes;for(A=d.length-1;0<=A&&!p;A--){h=d[A];f=h.getAttribute("data-z-index");var k=!D(f);if(h!==e)if(0>b&&k&&!c&&!A)a.insertBefore(e,d[A]),p=!0;else if(F(f)<=b||k&&(!D(b)||0<=b))a.insertBefore(e,d[A+1]||null),p=!0}p||(a.insertBefore(e,d[c?3:0]||null),p=!0)}return p};return a}();a.prototype["stroke-widthSetter"]=
a.prototype.strokeSetter;a.prototype.yGetter=a.prototype.xGetter;a.prototype.matrixSetter=a.prototype.rotationOriginXSetter=a.prototype.rotationOriginYSetter=a.prototype.rotationSetter=a.prototype.scaleXSetter=a.prototype.scaleYSetter=a.prototype.translateXSetter=a.prototype.translateYSetter=a.prototype.verticalAlignSetter=function(b,d){this[d]=b;this.doTransform=!0};"";return a});M(a,"Core/Renderer/RendererRegistry.js",[a["Core/Globals.js"]],function(a){var r;(function(r){r.rendererTypes={};var w;
r.getRendererType=function(a){void 0===a&&(a=w);return r.rendererTypes[a]||r.rendererTypes[w]};r.registerRendererType=function(C,x,E){r.rendererTypes[C]=x;if(!w||E)w=C,a.Renderer=x}})(r||(r={}));return r});M(a,"Core/Renderer/SVG/SVGLabel.js",[a["Core/Renderer/SVG/SVGElement.js"],a["Core/Utilities.js"]],function(a,w){var r=this&&this.__extends||function(){var a=function(g,c){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,a){c.__proto__=a}||function(c,a){for(var e in a)a.hasOwnProperty(e)&&
(c[e]=a[e])};return a(g,c)};return function(g,c){function e(){this.constructor=g}a(g,c);g.prototype=null===c?Object.create(c):(e.prototype=c.prototype,new e)}}(),E=w.defined,z=w.extend,x=w.isNumber,J=w.merge,u=w.pick,n=w.removeEvent;return function(m){function g(c,a,l,f,v,q,k,I,D,B){var e=m.call(this)||this;e.paddingLeftSetter=e.paddingSetter;e.paddingRightSetter=e.paddingSetter;e.init(c,"g");e.textStr=a;e.x=l;e.y=f;e.anchorX=q;e.anchorY=k;e.baseline=D;e.className=B;e.addClass("button"===B?"highcharts-no-tooltip":
"highcharts-label");B&&e.addClass("highcharts-"+B);e.text=c.text(void 0,0,0,I).attr({zIndex:1});var t;"string"===typeof v&&((t=/^url\((.*?)\)$/.test(v))||e.renderer.symbols[v])&&(e.symbolKey=v);e.bBox=g.emptyBBox;e.padding=3;e.baselineOffset=0;e.needsBox=c.styledMode||t;e.deferredAttr={};e.alignFactor=0;return e}r(g,m);g.prototype.alignSetter=function(c){c={left:0,center:.5,right:1}[c];c!==this.alignFactor&&(this.alignFactor=c,this.bBox&&x(this.xSetting)&&this.attr({x:this.xSetting}))};g.prototype.anchorXSetter=
function(c,a){this.anchorX=c;this.boxAttr(a,Math.round(c)-this.getCrispAdjust()-this.xSetting)};g.prototype.anchorYSetter=function(c,a){this.anchorY=c;this.boxAttr(a,c-this.ySetting)};g.prototype.boxAttr=function(c,a){this.box?this.box.attr(c,a):this.deferredAttr[c]=a};g.prototype.css=function(c){if(c){var e={};c=J(c);g.textProps.forEach(function(a){"undefined"!==typeof c[a]&&(e[a]=c[a],delete c[a])});this.text.css(e);var l="width"in e;"fontSize"in e||"fontWeight"in e?this.updateTextPadding():l&&
this.updateBoxSize()}return a.prototype.css.call(this,c)};g.prototype.destroy=function(){n(this.element,"mouseenter");n(this.element,"mouseleave");this.text&&this.text.destroy();this.box&&(this.box=this.box.destroy());a.prototype.destroy.call(this)};g.prototype.fillSetter=function(c,a){c&&(this.needsBox=!0);this.fill=c;this.boxAttr(a,c)};g.prototype.getBBox=function(){this.textStr&&0===this.bBox.width&&0===this.bBox.height&&this.updateBoxSize();var c=this.padding,a=u(this.paddingLeft,c);return{width:this.width,
height:this.height,x:this.bBox.x-a,y:this.bBox.y-c}};g.prototype.getCrispAdjust=function(){return this.renderer.styledMode&&this.box?this.box.strokeWidth()%2/2:(this["stroke-width"]?parseInt(this["stroke-width"],10):0)%2/2};g.prototype.heightSetter=function(c){this.heightSetting=c};g.prototype.onAdd=function(){var c=this.textStr;this.text.add(this);this.attr({text:E(c)?c:"",x:this.x,y:this.y});this.box&&E(this.anchorX)&&this.attr({anchorX:this.anchorX,anchorY:this.anchorY})};g.prototype.paddingSetter=
function(c,a){x(c)?c!==this[a]&&(this[a]=c,this.updateTextPadding()):this[a]=void 0};g.prototype.rSetter=function(c,a){this.boxAttr(a,c)};g.prototype.shadow=function(c){c&&!this.renderer.styledMode&&(this.updateBoxSize(),this.box&&this.box.shadow(c));return this};g.prototype.strokeSetter=function(c,a){this.stroke=c;this.boxAttr(a,c)};g.prototype["stroke-widthSetter"]=function(c,a){c&&(this.needsBox=!0);this["stroke-width"]=c;this.boxAttr(a,c)};g.prototype["text-alignSetter"]=function(c){this.textAlign=
c};g.prototype.textSetter=function(c){"undefined"!==typeof c&&this.text.attr({text:c});this.updateTextPadding()};g.prototype.updateBoxSize=function(){var c=this.text.element.style,a={},l=this.padding,f=this.bBox=x(this.widthSetting)&&x(this.heightSetting)&&!this.textAlign||!E(this.text.textStr)?g.emptyBBox:this.text.getBBox();this.width=this.getPaddedWidth();this.height=(this.heightSetting||f.height||0)+2*l;c=this.renderer.fontMetrics(c&&c.fontSize,this.text);this.baselineOffset=l+Math.min((this.text.firstLineMetrics||
c).b,f.height||Infinity);this.heightSetting&&(this.baselineOffset+=(this.heightSetting-c.h)/2);this.needsBox&&(this.box||(l=this.box=this.symbolKey?this.renderer.symbol(this.symbolKey):this.renderer.rect(),l.addClass(("button"===this.className?"":"highcharts-label-box")+(this.className?" highcharts-"+this.className+"-box":"")),l.add(this)),l=this.getCrispAdjust(),a.x=l,a.y=(this.baseline?-this.baselineOffset:0)+l,a.width=Math.round(this.width),a.height=Math.round(this.height),this.box.attr(z(a,this.deferredAttr)),
this.deferredAttr={})};g.prototype.updateTextPadding=function(){var c=this.text;this.updateBoxSize();var a=this.baseline?0:this.baselineOffset,g=u(this.paddingLeft,this.padding);E(this.widthSetting)&&this.bBox&&("center"===this.textAlign||"right"===this.textAlign)&&(g+={center:.5,right:1}[this.textAlign]*(this.widthSetting-this.bBox.width));if(g!==c.x||a!==c.y)c.attr("x",g),c.hasBoxWidthChanged&&(this.bBox=c.getBBox(!0)),"undefined"!==typeof a&&c.attr("y",a);c.x=g;c.y=a};g.prototype.widthSetter=function(c){this.widthSetting=
x(c)?c:void 0};g.prototype.getPaddedWidth=function(){var c=this.padding,a=u(this.paddingLeft,c);c=u(this.paddingRight,c);return(this.widthSetting||this.bBox.width||0)+a+c};g.prototype.xSetter=function(c){this.x=c;this.alignFactor&&(c-=this.alignFactor*this.getPaddedWidth(),this["forceAnimate:x"]=!0);this.xSetting=Math.round(c);this.attr("translateX",this.xSetting)};g.prototype.ySetter=function(c){this.ySetting=this.y=Math.round(c);this.attr("translateY",this.ySetting)};g.emptyBBox={width:0,height:0,
x:0,y:0};g.textProps="color direction fontFamily fontSize fontStyle fontWeight lineHeight textAlign textDecoration textOutline textOverflow width".split(" ");return g}(a)});M(a,"Core/Renderer/SVG/Symbols.js",[a["Core/Utilities.js"]],function(a){function r(a,n,m,g,c){var e=[];if(c){var l=c.start||0,f=J(c.r,m);m=J(c.r,g||m);var v=(c.end||0)-.001;g=c.innerR;var q=J(c.open,.001>Math.abs((c.end||0)-l-2*Math.PI)),k=Math.cos(l),I=Math.sin(l),D=Math.cos(v),B=Math.sin(v);l=J(c.longArc,.001>v-l-Math.PI?0:1);
e.push(["M",a+f*k,n+m*I],["A",f,m,0,l,J(c.clockwise,1),a+f*D,n+m*B]);z(g)&&e.push(q?["M",a+g*D,n+g*B]:["L",a+g*D,n+g*B],["A",g,g,0,l,z(c.clockwise)?1-c.clockwise:0,a+g*k,n+g*I]);q||e.push(["Z"])}return e}function C(a,n,m,g,c){return c&&c.r?E(a,n,m,g,c):[["M",a,n],["L",a+m,n],["L",a+m,n+g],["L",a,n+g],["Z"]]}function E(a,n,m,g,c){c=c&&c.r||0;return[["M",a+c,n],["L",a+m-c,n],["C",a+m,n,a+m,n,a+m,n+c],["L",a+m,n+g-c],["C",a+m,n+g,a+m,n+g,a+m-c,n+g],["L",a+c,n+g],["C",a,n+g,a,n+g,a,n+g-c],["L",a,n+c],
["C",a,n,a,n,a+c,n]]}var z=a.defined,x=a.isNumber,J=a.pick;return{arc:r,callout:function(a,n,m,g,c){var e=Math.min(c&&c.r||0,m,g),l=e+6,f=c&&c.anchorX;c=c&&c.anchorY||0;var v=E(a,n,m,g,{r:e});if(!x(f))return v;a+f>=m?c>n+l&&c<n+g-l?v.splice(3,1,["L",a+m,c-6],["L",a+m+6,c],["L",a+m,c+6],["L",a+m,n+g-e]):v.splice(3,1,["L",a+m,g/2],["L",f,c],["L",a+m,g/2],["L",a+m,n+g-e]):0>=a+f?c>n+l&&c<n+g-l?v.splice(7,1,["L",a,c+6],["L",a-6,c],["L",a,c-6],["L",a,n+e]):v.splice(7,1,["L",a,g/2],["L",f,c],["L",a,g/2],
["L",a,n+e]):c&&c>g&&f>a+l&&f<a+m-l?v.splice(5,1,["L",f+6,n+g],["L",f,n+g+6],["L",f-6,n+g],["L",a+e,n+g]):c&&0>c&&f>a+l&&f<a+m-l&&v.splice(1,1,["L",f-6,n],["L",f,n-6],["L",f+6,n],["L",m-e,n]);return v},circle:function(a,n,m,g){return r(a+m/2,n+g/2,m/2,g/2,{start:.5*Math.PI,end:2.5*Math.PI,open:!1})},diamond:function(a,n,m,g){return[["M",a+m/2,n],["L",a+m,n+g/2],["L",a+m/2,n+g],["L",a,n+g/2],["Z"]]},rect:C,roundedRect:E,square:C,triangle:function(a,n,m,g){return[["M",a+m/2,n],["L",a+m,n+g],["L",a,
n+g],["Z"]]},"triangle-down":function(a,n,m,g){return[["M",a,n],["L",a+m,n],["L",a+m/2,n+g],["Z"]]}}});M(a,"Core/Renderer/SVG/TextBuilder.js",[a["Core/Renderer/HTML/AST.js"],a["Core/Globals.js"],a["Core/Utilities.js"]],function(a,w,C){var r=w.doc,z=w.SVG_NS,x=C.attr,J=C.isString,u=C.objectEach,n=C.pick;return function(){function m(a){var c=a.styles;this.renderer=a.renderer;this.svgElement=a;this.width=a.textWidth;this.textLineHeight=c&&c.lineHeight;this.textOutline=c&&c.textOutline;this.ellipsis=
!(!c||"ellipsis"!==c.textOverflow);this.noWrap=!(!c||"nowrap"!==c.whiteSpace);this.fontSize=c&&c.fontSize}m.prototype.buildSVG=function(){var g=this.svgElement,c=g.element,e=g.renderer,l=n(g.textStr,"").toString(),f=-1!==l.indexOf("<"),v=c.childNodes;e=this.width&&!g.added&&e.box;var q=/<br.*?>/g,k=[l,this.ellipsis,this.noWrap,this.textLineHeight,this.textOutline,this.fontSize,this.width].join();if(k!==g.textCache){g.textCache=k;delete g.actualWidth;for(k=v.length;k--;)c.removeChild(v[k]);f||this.ellipsis||
this.width||-1!==l.indexOf(" ")&&(!this.noWrap||q.test(l))?""!==l&&(e&&e.appendChild(c),l=new a(l),this.modifyTree(l.nodes),l.addToDOM(g.element),this.modifyDOM(),this.ellipsis&&-1!==(c.textContent||"").indexOf("\u2026")&&g.attr("title",this.unescapeEntities(g.textStr||"",["&lt;","&gt;"])),e&&e.removeChild(c)):c.appendChild(r.createTextNode(this.unescapeEntities(l)));J(this.textOutline)&&g.applyTextOutline&&g.applyTextOutline(this.textOutline)}};m.prototype.modifyDOM=function(){var a=this,c=this.svgElement,
e=x(c.element,"x");c.firstLineMetrics=void 0;for(var l;l=c.element.firstChild;)if(/^[\s\u200B]*$/.test(l.textContent||" "))c.element.removeChild(l);else break;[].forEach.call(c.element.querySelectorAll("tspan.highcharts-br"),function(f,g){f.nextSibling&&f.previousSibling&&(0===g&&1===f.previousSibling.nodeType&&(c.firstLineMetrics=c.renderer.fontMetrics(void 0,f.previousSibling)),x(f,{dy:a.getLineHeight(f.nextSibling),x:e}))});var f=this.width||0;if(f){var v=function(k,g){var l=k.textContent||"",
q=l.replace(/([^\^])-/g,"$1- ").split(" "),v=!a.noWrap&&(1<q.length||1<c.element.childNodes.length),t=a.getLineHeight(g),h=0,d=c.actualWidth;if(a.ellipsis)l&&a.truncate(k,l,void 0,0,Math.max(0,f-parseInt(a.fontSize||12,10)),function(b,d){return b.substring(0,d)+"\u2026"});else if(v){l=[];for(v=[];g.firstChild&&g.firstChild!==k;)v.push(g.firstChild),g.removeChild(g.firstChild);for(;q.length;)q.length&&!a.noWrap&&0<h&&(l.push(k.textContent||""),k.textContent=q.join(" ").replace(/- /g,"-")),a.truncate(k,
void 0,q,0===h?d||0:0,f,function(b,d){return q.slice(0,d).join(" ").replace(/- /g,"-")}),d=c.actualWidth,h++;v.forEach(function(b){g.insertBefore(b,k)});l.forEach(function(b){g.insertBefore(r.createTextNode(b),k);b=r.createElementNS(z,"tspan");b.textContent="\u200b";x(b,{dy:t,x:e});g.insertBefore(b,k)})}},q=function(a){[].slice.call(a.childNodes).forEach(function(e){e.nodeType===Node.TEXT_NODE?v(e,a):(-1!==e.className.baseVal.indexOf("highcharts-br")&&(c.actualWidth=0),q(e))})};q(c.element)}};m.prototype.getLineHeight=
function(a){var c;a=a.nodeType===Node.TEXT_NODE?a.parentElement:a;this.renderer.styledMode||(c=a&&/(px|em)$/.test(a.style.fontSize)?a.style.fontSize:this.fontSize||this.renderer.style.fontSize||12);return this.textLineHeight?parseInt(this.textLineHeight.toString(),10):this.renderer.fontMetrics(c,a||this.svgElement.element).h};m.prototype.modifyTree=function(a){var c=this,e=function(g,f){var l=g.tagName,q=c.renderer.styledMode,k=g.attributes||{};if("b"===l||"strong"===l)q?k["class"]="highcharts-strong":
k.style="font-weight:bold;"+(k.style||"");else if("i"===l||"em"===l)q?k["class"]="highcharts-emphasized":k.style="font-style:italic;"+(k.style||"");J(k.style)&&(k.style=k.style.replace(/(;| |^)color([ :])/,"$1fill$2"));"br"===l&&(k["class"]="highcharts-br",g.textContent="\u200b",(f=a[f+1])&&f.textContent&&(f.textContent=f.textContent.replace(/^ +/gm,"")));"#text"!==l&&"a"!==l&&(g.tagName="tspan");g.attributes=k;g.children&&g.children.filter(function(c){return"#text"!==c.tagName}).forEach(e)};a.forEach(e)};
m.prototype.truncate=function(a,c,e,l,f,v){var g=this.svgElement,k=g.renderer,m=g.rotation,D=[],B=e?1:0,n=(c||e||"").length,t=n,h,d=function(b,d){d=d||b;var h=a.parentNode;if(h&&"undefined"===typeof D[d])if(h.getSubStringLength)try{D[d]=l+h.getSubStringLength(0,e?d+1:d)}catch(L){""}else k.getSpanWidth&&(a.textContent=v(c||e,b),D[d]=l+k.getSpanWidth(g,a));return D[d]};g.rotation=0;var b=d(a.textContent.length);if(l+b>f){for(;B<=n;)t=Math.ceil((B+n)/2),e&&(h=v(e,t)),b=d(t,h&&h.length-1),B===n?B=n+1:
b>f?n=t-1:B=t;0===n?a.textContent="":c&&n===c.length-1||(a.textContent=h||v(c||e,t))}e&&e.splice(0,t);g.actualWidth=b;g.rotation=m};m.prototype.unescapeEntities=function(a,c){u(this.renderer.escapes,function(e,g){c&&-1!==c.indexOf(e)||(a=a.toString().replace(new RegExp(e,"g"),g))});return a};return m}()});M(a,"Core/Renderer/SVG/SVGRenderer.js",[a["Core/Renderer/HTML/AST.js"],a["Core/Color/Color.js"],a["Core/Globals.js"],a["Core/Color/Palette.js"],a["Core/Renderer/RendererRegistry.js"],a["Core/Renderer/SVG/SVGElement.js"],
a["Core/Renderer/SVG/SVGLabel.js"],a["Core/Renderer/SVG/Symbols.js"],a["Core/Renderer/SVG/TextBuilder.js"],a["Core/Utilities.js"]],function(a,w,C,E,z,x,J,u,n,m){var g=C.charts,c=C.deg2rad,e=C.doc,l=C.isFirefox,f=C.isMS,v=C.isWebKit,q=C.noop,k=C.SVG_NS,I=C.symbolSizes,D=C.win,B=m.addEvent,r=m.attr,t=m.createElement,h=m.css,d=m.defined,b=m.destroyObjectProperties,p=m.extend,G=m.isArray,y=m.isNumber,L=m.isObject,F=m.isString,P=m.merge,S=m.pick,Q=m.pInt,V=m.uniqueKey,fa;C=function(){function H(b,d,c,
a,h,e,p){this.width=this.url=this.style=this.isSVG=this.imgCount=this.height=this.gradients=this.globalAnimation=this.defs=this.chartIndex=this.cacheKeys=this.cache=this.boxWrapper=this.box=this.alignedObjects=void 0;this.init(b,d,c,a,h,e,p)}H.prototype.init=function(b,d,c,a,p,A,H){var K=this.createElement("svg").attr({version:"1.1","class":"highcharts-root"}),f=K.element;H||K.css(this.getStyle(a));b.appendChild(f);r(b,"dir","ltr");-1===b.innerHTML.indexOf("xmlns")&&r(f,"xmlns",this.SVG_NS);this.isSVG=
!0;this.box=f;this.boxWrapper=K;this.alignedObjects=[];this.url=this.getReferenceURL();this.createElement("desc").add().element.appendChild(e.createTextNode("Created with Highcharts 9.2.2"));this.defs=this.createElement("defs").add();this.allowHTML=A;this.forExport=p;this.styledMode=H;this.gradients={};this.cache={};this.cacheKeys=[];this.imgCount=0;this.setSize(d,c,!1);var k;l&&b.getBoundingClientRect&&(d=function(){h(b,{left:0,top:0});k=b.getBoundingClientRect();h(b,{left:Math.ceil(k.left)-k.left+
"px",top:Math.ceil(k.top)-k.top+"px"})},d(),this.unSubPixelFix=B(D,"resize",d))};H.prototype.definition=function(b){return(new a([b])).addToDOM(this.defs.element)};H.prototype.getReferenceURL=function(){if((l||v)&&e.getElementsByTagName("base").length){if(!d(fa)){var b=V();b=(new a([{tagName:"svg",attributes:{width:8,height:8},children:[{tagName:"defs",children:[{tagName:"clipPath",attributes:{id:b},children:[{tagName:"rect",attributes:{width:4,height:4}}]}]},{tagName:"rect",attributes:{id:"hitme",
width:8,height:8,"clip-path":"url(#"+b+")",fill:"rgba(0,0,0,0.001)"}}]}])).addToDOM(e.body);h(b,{position:"fixed",top:0,left:0,zIndex:9E5});var c=e.elementFromPoint(6,6);fa="hitme"===(c&&c.id);e.body.removeChild(b)}if(fa)return D.location.href.split("#")[0].replace(/<[^>]*>/g,"").replace(/([\('\)])/g,"\\$1").replace(/ /g,"%20")}return""};H.prototype.getStyle=function(b){return this.style=p({fontFamily:'"Lucida Grande", "Lucida Sans Unicode", Arial, Helvetica, sans-serif',fontSize:"12px"},b)};H.prototype.setStyle=
function(b){this.boxWrapper.css(this.getStyle(b))};H.prototype.isHidden=function(){return!this.boxWrapper.getBBox().width};H.prototype.destroy=function(){var d=this.defs;this.box=null;this.boxWrapper=this.boxWrapper.destroy();b(this.gradients||{});this.gradients=null;d&&(this.defs=d.destroy());this.unSubPixelFix&&this.unSubPixelFix();return this.alignedObjects=null};H.prototype.createElement=function(b){var d=new this.Element;d.init(this,b);return d};H.prototype.getRadialAttr=function(b,d){return{cx:b[0]-
b[2]/2+(d.cx||0)*b[2],cy:b[1]-b[2]/2+(d.cy||0)*b[2],r:(d.r||0)*b[2]}};H.prototype.buildText=function(b){(new n(b)).buildSVG()};H.prototype.getContrast=function(b){b=w.parse(b).rgba;b[0]*=1;b[1]*=1.2;b[2]*=.5;return 459<b[0]+b[1]+b[2]?"#000000":"#FFFFFF"};H.prototype.button=function(b,d,c,h,e,A,H,k,g,y){var K=this.label(b,d,c,g,void 0,void 0,y,void 0,"button"),G=this.styledMode,l=0,t=e?P(e):{};b=t&&t.style||{};t=a.filterUserAttributes(t);K.attr(P({padding:8,r:2},t));if(!G){t=P({fill:E.neutralColor3,
stroke:E.neutralColor20,"stroke-width":1,style:{color:E.neutralColor80,cursor:"pointer",fontWeight:"normal"}},{style:b},t);var N=t.style;delete t.style;A=P(t,{fill:E.neutralColor10},a.filterUserAttributes(A||{}));var q=A.style;delete A.style;H=P(t,{fill:E.highlightColor10,style:{color:E.neutralColor100,fontWeight:"bold"}},a.filterUserAttributes(H||{}));var v=H.style;delete H.style;k=P(t,{style:{color:E.neutralColor20}},a.filterUserAttributes(k||{}));var F=k.style;delete k.style}B(K.element,f?"mouseover":
"mouseenter",function(){3!==l&&K.setState(1)});B(K.element,f?"mouseout":"mouseleave",function(){3!==l&&K.setState(l)});K.setState=function(b){1!==b&&(K.state=l=b);K.removeClass(/highcharts-button-(normal|hover|pressed|disabled)/).addClass("highcharts-button-"+["normal","hover","pressed","disabled"][b||0]);G||K.attr([t,A,H,k][b||0]).css([N,q,v,F][b||0])};G||K.attr(t).css(p({cursor:"default"},N));return K.on("touchstart",function(b){return b.stopPropagation()}).on("click",function(b){3!==l&&h.call(K,
b)})};H.prototype.crispLine=function(b,c,a){void 0===a&&(a="round");var h=b[0],e=b[1];d(h[1])&&h[1]===e[1]&&(h[1]=e[1]=Math[a](h[1])-c%2/2);d(h[2])&&h[2]===e[2]&&(h[2]=e[2]=Math[a](h[2])+c%2/2);return b};H.prototype.path=function(b){var d=this.styledMode?{}:{fill:"none"};G(b)?d.d=b:L(b)&&p(d,b);return this.createElement("path").attr(d)};H.prototype.circle=function(b,d,c){b=L(b)?b:"undefined"===typeof b?{}:{x:b,y:d,r:c};d=this.createElement("circle");d.xSetter=d.ySetter=function(b,d,c){c.setAttribute("c"+
d,b)};return d.attr(b)};H.prototype.arc=function(b,d,c,a,h,e){L(b)?(a=b,d=a.y,c=a.r,b=a.x):a={innerR:a,start:h,end:e};b=this.symbol("arc",b,d,c,c,a);b.r=c;return b};H.prototype.rect=function(b,d,c,a,h,e){h=L(b)?b.r:h;var p=this.createElement("rect");b=L(b)?b:"undefined"===typeof b?{}:{x:b,y:d,width:Math.max(c,0),height:Math.max(a,0)};this.styledMode||("undefined"!==typeof e&&(b["stroke-width"]=e,b=p.crisp(b)),b.fill="none");h&&(b.r=h);p.rSetter=function(b,d,c){p.r=b;r(c,{rx:b,ry:b})};p.rGetter=function(){return p.r||
0};return p.attr(b)};H.prototype.setSize=function(b,d,c){this.width=b;this.height=d;this.boxWrapper.animate({width:b,height:d},{step:function(){this.attr({viewBox:"0 0 "+this.attr("width")+" "+this.attr("height")})},duration:S(c,!0)?void 0:0});this.alignElements()};H.prototype.g=function(b){var d=this.createElement("g");return b?d.attr({"class":"highcharts-"+b}):d};H.prototype.image=function(b,d,c,a,h,e){var A={preserveAspectRatio:"none"},H=function(b,d){b.setAttributeNS?b.setAttributeNS("http://www.w3.org/1999/xlink",
"href",d):b.setAttribute("hc-svg-href",d)};1<arguments.length&&p(A,{x:d,y:c,width:a,height:h});var f=this.createElement("image").attr(A);A=function(d){H(f.element,b);e.call(f,d)};if(e){H(f.element,"data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==");var K=new D.Image;B(K,"load",A);K.src=b;K.complete&&A({})}else H(f.element,b);return f};H.prototype.symbol=function(b,c,a,H,f,A){var K=this,k=/^url\((.*?)\)$/,y=k.test(b),G=!y&&(this.symbols[b]?b:"circle"),l=G&&this.symbols[G],
q;if(l){"number"===typeof c&&(q=l.call(this.symbols,Math.round(c||0),Math.round(a||0),H||0,f||0,A));var v=this.path(q);K.styledMode||v.attr("fill","none");p(v,{symbolName:G||void 0,x:c,y:a,width:H,height:f});A&&p(v,A)}else if(y){var F=b.match(k)[1];var m=v=this.image(F);m.imgwidth=S(I[F]&&I[F].width,A&&A.width);m.imgheight=S(I[F]&&I[F].height,A&&A.height);var L=function(b){return b.attr({width:b.width,height:b.height})};["width","height"].forEach(function(b){m[b+"Setter"]=function(b,c){var a=this["img"+
c];this[c]=b;d(a)&&(A&&"within"===A.backgroundSize&&this.width&&this.height&&(a=Math.round(a*Math.min(this.width/this.imgwidth,this.height/this.imgheight))),this.element&&this.element.setAttribute(c,a),this.alignByTranslate||(b=((this[c]||0)-a)/2,this.attr("width"===c?{translateX:b}:{translateY:b})))}});d(c)&&m.attr({x:c,y:a});m.isImg=!0;d(m.imgwidth)&&d(m.imgheight)?L(m):(m.attr({width:0,height:0}),t("img",{onload:function(){var b=g[K.chartIndex];0===this.width&&(h(this,{position:"absolute",top:"-999em"}),
e.body.appendChild(this));I[F]={width:this.width,height:this.height};m.imgwidth=this.width;m.imgheight=this.height;m.element&&L(m);this.parentNode&&this.parentNode.removeChild(this);K.imgCount--;if(!K.imgCount&&b&&!b.hasLoaded)b.onload()},src:F}),this.imgCount++)}return v};H.prototype.clipRect=function(b,d,c,a){var h=V()+"-",e=this.createElement("clipPath").attr({id:h}).add(this.defs);b=this.rect(b,d,c,a,0).add(e);b.id=h;b.clipPath=e;b.count=0;return b};H.prototype.text=function(b,c,a,h){var e={};
if(h&&(this.allowHTML||!this.forExport))return this.html(b,c,a);e.x=Math.round(c||0);a&&(e.y=Math.round(a));d(b)&&(e.text=b);b=this.createElement("text").attr(e);if(!h||this.forExport&&!this.allowHTML)b.xSetter=function(b,d,c){for(var a=c.getElementsByTagName("tspan"),h=c.getAttribute(d),e=0,p;e<a.length;e++)p=a[e],p.getAttribute(d)===h&&p.setAttribute(d,b);c.setAttribute(d,b)};return b};H.prototype.fontMetrics=function(b,d){b=!this.styledMode&&/px/.test(b)||!D.getComputedStyle?b||d&&d.style&&d.style.fontSize||
this.style&&this.style.fontSize:d&&x.prototype.getStyle.call(d,"font-size");b=/px/.test(b)?Q(b):12;d=24>b?b+3:Math.round(1.2*b);return{h:d,b:Math.round(.8*d),f:b}};H.prototype.rotCorr=function(b,d,a){var h=b;d&&a&&(h=Math.max(h*Math.cos(d*c),4));return{x:-b/3*Math.sin(d*c),y:h}};H.prototype.pathToSegments=function(b){for(var d=[],c=[],a={A:8,C:7,H:2,L:3,M:3,Q:5,S:5,T:3,V:2},h=0;h<b.length;h++)F(c[0])&&y(b[h])&&c.length===a[c[0].toUpperCase()]&&b.splice(h,0,c[0].replace("M","L").replace("m","l")),
"string"===typeof b[h]&&(c.length&&d.push(c.slice(0)),c.length=0),c.push(b[h]);d.push(c.slice(0));return d};H.prototype.label=function(b,d,c,a,h,e,p,H,f){return new J(this,b,d,c,a,h,e,p,H,f)};H.prototype.alignElements=function(){this.alignedObjects.forEach(function(b){return b.align()})};return H}();p(C.prototype,{Element:x,SVG_NS:k,escapes:{"&":"&amp;","<":"&lt;",">":"&gt;","'":"&#39;",'"':"&quot;"},symbols:u,draw:q});z.registerRendererType("svg",C,!0);"";return C});M(a,"Core/Renderer/HTML/HTMLElement.js",
[a["Core/Globals.js"],a["Core/Renderer/SVG/SVGElement.js"],a["Core/Utilities.js"]],function(a,w,C){var r=this&&this.__extends||function(){var c=function(a,e){c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,a){c.__proto__=a}||function(c,a){for(var e in a)a.hasOwnProperty(e)&&(c[e]=a[e])};return c(a,e)};return function(a,e){function f(){this.constructor=a}c(a,e);a.prototype=null===e?Object.create(e):(f.prototype=e.prototype,new f)}}(),z=a.isFirefox,x=a.isMS,J=a.isWebKit,u=a.win,
n=C.css,m=C.defined,g=C.extend,c=C.pick,e=C.pInt;return function(a){function f(){return null!==a&&a.apply(this,arguments)||this}r(f,a);f.compose=function(c){if(-1===f.composedClasses.indexOf(c)){f.composedClasses.push(c);var a=f.prototype,e=c.prototype;e.getSpanCorrection=a.getSpanCorrection;e.htmlCss=a.htmlCss;e.htmlGetBBox=a.htmlGetBBox;e.htmlUpdateTransform=a.htmlUpdateTransform;e.setSpanRotation=a.setSpanRotation}return c};f.prototype.getSpanCorrection=function(c,a,e){this.xCorr=-c*e;this.yCorr=
-a};f.prototype.htmlCss=function(a){var e="SPAN"===this.element.tagName&&a&&"width"in a,f=c(e&&a.width,void 0);if(e){delete a.width;this.textWidth=f;var l=!0}a&&"ellipsis"===a.textOverflow&&(a.whiteSpace="nowrap",a.overflow="hidden");this.styles=g(this.styles,a);n(this.element,a);l&&this.htmlUpdateTransform();return this};f.prototype.htmlGetBBox=function(){var c=this.element;return{x:c.offsetLeft,y:c.offsetTop,width:c.offsetWidth,height:c.offsetHeight}};f.prototype.htmlUpdateTransform=function(){if(this.added){var c=
this.renderer,a=this.element,f=this.translateX||0,g=this.translateY||0,l=this.x||0,B=this.y||0,r=this.textAlign||"left",t={left:0,center:.5,right:1}[r],h=this.styles;h=h&&h.whiteSpace;n(a,{marginLeft:f,marginTop:g});!c.styledMode&&this.shadows&&this.shadows.forEach(function(b){n(b,{marginLeft:f+1,marginTop:g+1})});this.inverted&&[].forEach.call(a.childNodes,function(b){c.invertChild(b,a)});if("SPAN"===a.tagName){var d=this.rotation,b=this.textWidth&&e(this.textWidth),p=[d,r,a.innerHTML,this.textWidth,
this.textAlign].join(),G=void 0;(G=b!==this.oldTextWidth)&&!(G=b>this.oldTextWidth)&&((G=this.textPxLength)||(n(a,{width:"",whiteSpace:h||"nowrap"}),G=a.offsetWidth),G=G>b);G&&(/[ \-]/.test(a.textContent||a.innerText)||"ellipsis"===a.style.textOverflow)?(n(a,{width:b+"px",display:"block",whiteSpace:h||"normal"}),this.oldTextWidth=b,this.hasBoxWidthChanged=!0):this.hasBoxWidthChanged=!1;p!==this.cTT&&(G=c.fontMetrics(a.style.fontSize,a).b,!m(d)||d===(this.oldRotation||0)&&r===this.oldAlign||this.setSpanRotation(d,
t,G),this.getSpanCorrection(!m(d)&&this.textPxLength||a.offsetWidth,G,t,d,r));n(a,{left:l+(this.xCorr||0)+"px",top:B+(this.yCorr||0)+"px"});this.cTT=p;this.oldRotation=d;this.oldAlign=r}}else this.alignOnAdd=!0};f.prototype.setSpanRotation=function(c,a,e){var f={},g=x&&!/Edge/.test(u.navigator.userAgent)?"-ms-transform":J?"-webkit-transform":z?"MozTransform":u.opera?"-o-transform":void 0;g&&(f[g]=f.transform="rotate("+c+"deg)",f[g+(z?"Origin":"-origin")]=f.transformOrigin=100*a+"% "+e+"px",n(this.element,
f))};f.composedClasses=[];return f}(w)});M(a,"Core/Renderer/HTML/HTMLRenderer.js",[a["Core/Renderer/HTML/AST.js"],a["Core/Renderer/SVG/SVGElement.js"],a["Core/Renderer/SVG/SVGRenderer.js"],a["Core/Utilities.js"]],function(a,w,C,E){var r=this&&this.__extends||function(){var a=function(g,c){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,c){a.__proto__=c}||function(a,c){for(var e in c)c.hasOwnProperty(e)&&(a[e]=c[e])};return a(g,c)};return function(g,c){function e(){this.constructor=
g}a(g,c);g.prototype=null===c?Object.create(c):(e.prototype=c.prototype,new e)}}(),x=E.attr,J=E.createElement,u=E.extend,n=E.pick;return function(m){function g(){return null!==m&&m.apply(this,arguments)||this}r(g,m);g.compose=function(c){-1===g.composedClasses.indexOf(c)&&(g.composedClasses.push(c),c.prototype.html=g.prototype.html);return c};g.prototype.html=function(c,e,g){var f=this.createElement("span"),l=f.element,q=f.renderer,k=q.isSVG,m=function(c,a){["opacity","visibility"].forEach(function(e){c[e+
"Setter"]=function(f,h,d){var b=c.div?c.div.style:a;w.prototype[e+"Setter"].call(this,f,h,d);b&&(b[h]=f)}});c.addedSetters=!0};f.textSetter=function(c){c!==this.textStr&&(delete this.bBox,delete this.oldTextWidth,a.setElementHTML(this.element,n(c,"")),this.textStr=c,f.doTransform=!0)};k&&m(f,f.element.style);f.xSetter=f.ySetter=f.alignSetter=f.rotationSetter=function(c,a){"align"===a?f.alignValue=f.textAlign=c:f[a]=c;f.doTransform=!0};f.afterSetters=function(){this.doTransform&&(this.htmlUpdateTransform(),
this.doTransform=!1)};f.attr({text:c,x:Math.round(e),y:Math.round(g)}).css({position:"absolute"});q.styledMode||f.css({fontFamily:this.style.fontFamily,fontSize:this.style.fontSize});l.style.whiteSpace="nowrap";f.css=f.htmlCss;k&&(f.add=function(c){var a=q.box.parentNode,e=[];if(this.parentGroup=c){var g=c.div;if(!g){for(;c;)e.push(c),c=c.parentGroup;e.reverse().forEach(function(c){function d(b,d){c[d]=b;"translateX"===d?k.left=b+"px":k.top=b+"px";c.doTransform=!0}var b=x(c.element,"class"),h=c.styles||
{};g=c.div=c.div||J("div",b?{className:b}:void 0,{position:"absolute",left:(c.translateX||0)+"px",top:(c.translateY||0)+"px",display:c.display,opacity:c.opacity,cursor:h.cursor,pointerEvents:h.pointerEvents,visibility:c.visibility},g||a);var k=g.style;u(c,{classSetter:function(b){return function(d){this.element.setAttribute("class",d);b.className=d}}(g),on:function(){e[0].div&&f.on.apply({element:e[0].div,onEvents:c.onEvents},arguments);return c},translateXSetter:d,translateYSetter:d});c.addedSetters||
m(c)})}}else g=a;g.appendChild(l);f.added=!0;f.alignOnAdd&&f.htmlUpdateTransform();return f});return f};g.composedClasses=[];return g}(C)});M(a,"Core/Axis/AxisDefaults.js",[a["Core/Color/Palette.js"]],function(a){var r;(function(r){r.defaultXAxisOptions={alignTicks:!0,allowDecimals:void 0,panningEnabled:!0,zIndex:2,zoomEnabled:!0,dateTimeLabelFormats:{millisecond:{main:"%H:%M:%S.%L",range:!1},second:{main:"%H:%M:%S",range:!1},minute:{main:"%H:%M",range:!1},hour:{main:"%H:%M",range:!1},day:{main:"%e. %b"},
week:{main:"%e. %b"},month:{main:"%b '%y"},year:{main:"%Y"}},endOnTick:!1,gridLineDashStyle:"Solid",gridZIndex:1,labels:{autoRotation:void 0,autoRotationLimit:80,distance:void 0,enabled:!0,indentation:10,overflow:"justify",padding:5,reserveSpace:void 0,rotation:void 0,staggerLines:0,step:0,useHTML:!1,x:0,zIndex:7,style:{color:a.neutralColor60,cursor:"default",fontSize:"11px"}},maxPadding:.01,minorGridLineDashStyle:"Solid",minorTickLength:2,minorTickPosition:"outside",minPadding:.01,offset:void 0,
opposite:!1,reversed:void 0,reversedStacks:!1,showEmpty:!0,showFirstLabel:!0,showLastLabel:!0,startOfWeek:1,startOnTick:!1,tickLength:10,tickPixelInterval:100,tickmarkPlacement:"between",tickPosition:"outside",title:{align:"middle",rotation:0,useHTML:!1,x:0,y:0,style:{color:a.neutralColor60}},type:"linear",uniqueNames:!0,visible:!0,minorGridLineColor:a.neutralColor5,minorGridLineWidth:1,minorTickColor:a.neutralColor40,lineColor:a.highlightColor20,lineWidth:1,gridLineColor:a.neutralColor10,gridLineWidth:void 0,
tickColor:a.highlightColor20};r.defaultYAxisOptions={reversedStacks:!0,endOnTick:!0,maxPadding:.05,minPadding:.05,tickPixelInterval:72,showLastLabel:!0,labels:{x:-8},startOnTick:!0,title:{rotation:270,text:"Values"},stackLabels:{animation:{},allowOverlap:!1,enabled:!1,crop:!0,overflow:"justify",formatter:function(){var a=this.axis.chart.numberFormatter;return a(this.total,-1)},style:{color:a.neutralColor100,fontSize:"11px",fontWeight:"bold",textOutline:"1px contrast"}},gridLineWidth:1,lineWidth:0};
r.defaultLeftAxisOptions={labels:{x:-15},title:{rotation:270}};r.defaultRightAxisOptions={labels:{x:15},title:{rotation:90}};r.defaultBottomAxisOptions={labels:{autoRotation:[-45],x:0},margin:15,title:{rotation:0}};r.defaultTopAxisOptions={labels:{autoRotation:[-45],x:0},margin:15,title:{rotation:0}}})(r||(r={}));return r});M(a,"Core/Foundation.js",[a["Core/Utilities.js"]],function(a){var r=a.addEvent,C=a.isFunction,E=a.objectEach,z=a.removeEvent;return{registerEventOptions:function(a,w){a.eventOptions=
a.eventOptions||{};E(w.events,function(u,n){a.eventOptions[n]!==u&&(a.eventOptions[n]&&(z(a,n,a.eventOptions[n]),delete a.eventOptions[n]),C(u)&&(a.eventOptions[n]=u,r(a,n,u)))})}}});M(a,"Core/Axis/Tick.js",[a["Core/FormatUtilities.js"],a["Core/Globals.js"],a["Core/Utilities.js"]],function(a,w,C){var r=w.deg2rad,z=C.clamp,x=C.correctFloat,J=C.defined,u=C.destroyObjectProperties,n=C.extend,m=C.fireEvent,g=C.isNumber,c=C.merge,e=C.objectEach,l=C.pick;w=function(){function f(c,a,e,f,g){this.isNewLabel=
this.isNew=!0;this.axis=c;this.pos=a;this.type=e||"";this.parameters=g||{};this.tickmarkOffset=this.parameters.tickmarkOffset;this.options=this.parameters.options;m(this,"init");e||f||this.addLabel()}f.prototype.addLabel=function(){var c=this,e=c.axis,f=e.options,I=e.chart,D=e.categories,B=e.logarithmic,r=e.names,t=c.pos,h=l(c.options&&c.options.labels,f.labels),d=e.tickPositions,b=t===d[0],p=t===d[d.length-1],G=(!h.step||1===h.step)&&1===e.tickInterval;d=d.info;var y=c.label,L;D=this.parameters.category||
(D?l(D[t],r[t],t):t);B&&g(D)&&(D=x(B.lin2log(D)));if(e.dateTime)if(d){var F=I.time.resolveDTLFormat(f.dateTimeLabelFormats[!f.grid&&d.higherRanks[t]||d.unitName]);var P=F.main}else g(D)&&(P=e.dateTime.getXDateFormat(D,f.dateTimeLabelFormats||{}));c.isFirst=b;c.isLast=p;var S={axis:e,chart:I,dateTimeLabelFormat:P,isFirst:b,isLast:p,pos:t,tick:c,tickPositionInfo:d,value:D};m(this,"labelFormat",S);var Q=function(b){return h.formatter?h.formatter.call(b,b):h.format?(b.text=e.defaultLabelFormatter.call(b),
a.format(h.format,b,I)):e.defaultLabelFormatter.call(b,b)};f=Q.call(S,S);var u=F&&F.list;c.shortenLabel=u?function(){for(L=0;L<u.length;L++)if(n(S,{dateTimeLabelFormat:u[L]}),y.attr({text:Q.call(S,S)}),y.getBBox().width<e.getSlotWidth(c)-2*h.padding)return;y.attr({text:""})}:void 0;G&&e._addedPlotLB&&c.moveLabel(f,h);J(y)||c.movedLabel?y&&y.textStr!==f&&!G&&(!y.textWidth||h.style.width||y.styles.width||y.css({width:null}),y.attr({text:f}),y.textPxLength=y.getBBox().width):(c.label=y=c.createLabel({x:0,
y:0},f,h),c.rotation=0)};f.prototype.createLabel=function(a,e,f){var g=this.axis,k=g.chart;if(a=J(e)&&f.enabled?k.renderer.text(e,a.x,a.y,f.useHTML).add(g.labelGroup):null)k.styledMode||a.css(c(f.style)),a.textPxLength=a.getBBox().width;return a};f.prototype.destroy=function(){u(this,this.axis)};f.prototype.getPosition=function(c,a,e,f){var g=this.axis,k=g.chart,l=f&&k.oldChartHeight||k.chartHeight;c={x:c?x(g.translate(a+e,null,null,f)+g.transB):g.left+g.offset+(g.opposite?(f&&k.oldChartWidth||k.chartWidth)-
g.right-g.left:0),y:c?l-g.bottom+g.offset-(g.opposite?g.height:0):x(l-g.translate(a+e,null,null,f)-g.transB)};c.y=z(c.y,-1E5,1E5);m(this,"afterGetPosition",{pos:c});return c};f.prototype.getLabelPosition=function(c,a,e,f,g,l,n,t){var h=this.axis,d=h.transA,b=h.isLinked&&h.linkedParent?h.linkedParent.reversed:h.reversed,p=h.staggerLines,k=h.tickRotCorr||{x:0,y:0},y=f||h.reserveSpaceDefault?0:-h.labelOffset*("center"===h.labelAlign?.5:1),q={},F=g.y;J(F)||(F=0===h.side?e.rotation?-8:-e.getBBox().height:
2===h.side?k.y+8:Math.cos(e.rotation*r)*(k.y-e.getBBox(!1,0).height/2));c=c+g.x+y+k.x-(l&&f?l*d*(b?-1:1):0);a=a+F-(l&&!f?l*d*(b?1:-1):0);p&&(e=n/(t||1)%p,h.opposite&&(e=p-e-1),a+=h.labelOffset/p*e);q.x=c;q.y=Math.round(a);m(this,"afterGetLabelPosition",{pos:q,tickmarkOffset:l,index:n});return q};f.prototype.getLabelSize=function(){return this.label?this.label.getBBox()[this.axis.horiz?"height":"width"]:0};f.prototype.getMarkPath=function(c,a,e,f,g,l){return l.crispLine([["M",c,a],["L",c+(g?0:-e),
a+(g?e:0)]],f)};f.prototype.handleOverflow=function(c){var a=this.axis,e=a.options.labels,f=c.x,g=a.chart.chartWidth,m=a.chart.spacing,v=l(a.labelLeft,Math.min(a.pos,m[3]));m=l(a.labelRight,Math.max(a.isRadial?0:a.pos+a.len,g-m[1]));var t=this.label,h=this.rotation,d={left:0,center:.5,right:1}[a.labelAlign||t.attr("align")],b=t.getBBox().width,p=a.getSlotWidth(this),G={},y=p,L=1,F;if(h||"justify"!==e.overflow)0>h&&f-d*b<v?F=Math.round(f/Math.cos(h*r)-v):0<h&&f+d*b>m&&(F=Math.round((g-f)/Math.cos(h*
r)));else if(g=f+(1-d)*b,f-d*b<v?y=c.x+y*(1-d)-v:g>m&&(y=m-c.x+y*d,L=-1),y=Math.min(p,y),y<p&&"center"===a.labelAlign&&(c.x+=L*(p-y-d*(p-Math.min(b,y)))),b>y||a.autoRotation&&(t.styles||{}).width)F=y;F&&(this.shortenLabel?this.shortenLabel():(G.width=Math.floor(F)+"px",(e.style||{}).textOverflow||(G.textOverflow="ellipsis"),t.css(G)))};f.prototype.moveLabel=function(c,a){var f=this,g=f.label,l=f.axis,m=l.reversed,q=!1;g&&g.textStr===c?(f.movedLabel=g,q=!0,delete f.label):e(l.ticks,function(a){q||
a.isNew||a===f||!a.label||a.label.textStr!==c||(f.movedLabel=a.label,q=!0,a.labelPos=f.movedLabel.xy,delete a.label)});if(!q&&(f.labelPos||g)){var t=f.labelPos||g.xy;g=l.horiz?m?0:l.width+l.left:t.x;l=l.horiz?t.y:m?l.width+l.left:0;f.movedLabel=f.createLabel({x:g,y:l},c,a);f.movedLabel&&f.movedLabel.attr({opacity:0})}};f.prototype.render=function(a,c,e){var f=this.axis,g=f.horiz,k=this.pos,q=l(this.tickmarkOffset,f.tickmarkOffset);k=this.getPosition(g,k,q,c);q=k.x;var t=k.y;f=g&&q===f.pos+f.len||
!g&&t===f.pos?-1:1;g=l(e,this.label&&this.label.newOpacity,1);e=l(e,1);this.isActive=!0;this.renderGridLine(c,e,f);this.renderMark(k,e,f);this.renderLabel(k,c,g,a);this.isNew=!1;m(this,"afterRender")};f.prototype.renderGridLine=function(c,a,e){var f=this.axis,g=f.options,k={},m=this.pos,t=this.type,h=l(this.tickmarkOffset,f.tickmarkOffset),d=f.chart.renderer,b=this.gridLine,p=g.gridLineWidth,G=g.gridLineColor,y=g.gridLineDashStyle;"minor"===this.type&&(p=g.minorGridLineWidth,G=g.minorGridLineColor,
y=g.minorGridLineDashStyle);b||(f.chart.styledMode||(k.stroke=G,k["stroke-width"]=p||0,k.dashstyle=y),t||(k.zIndex=1),c&&(a=0),this.gridLine=b=d.path().attr(k).addClass("highcharts-"+(t?t+"-":"")+"grid-line").add(f.gridGroup));if(b&&(e=f.getPlotLinePath({value:m+h,lineWidth:b.strokeWidth()*e,force:"pass",old:c})))b[c||this.isNew?"attr":"animate"]({d:e,opacity:a})};f.prototype.renderMark=function(c,a,e){var f=this.axis,g=f.options,k=f.chart.renderer,m=this.type,t=f.tickSize(m?m+"Tick":"tick"),h=c.x;
c=c.y;var d=l(g["minor"!==m?"tickWidth":"minorTickWidth"],!m&&f.isXAxis?1:0);g=g["minor"!==m?"tickColor":"minorTickColor"];var b=this.mark,p=!b;t&&(f.opposite&&(t[0]=-t[0]),b||(this.mark=b=k.path().addClass("highcharts-"+(m?m+"-":"")+"tick").add(f.axisGroup),f.chart.styledMode||b.attr({stroke:g,"stroke-width":d})),b[p?"attr":"animate"]({d:this.getMarkPath(h,c,t[0],b.strokeWidth()*e,f.horiz,k),opacity:a}))};f.prototype.renderLabel=function(c,a,e,f){var k=this.axis,m=k.horiz,q=k.options,t=this.label,
h=q.labels,d=h.step;k=l(this.tickmarkOffset,k.tickmarkOffset);var b=c.x;c=c.y;var p=!0;t&&g(b)&&(t.xy=c=this.getLabelPosition(b,c,t,m,h,k,f,d),this.isFirst&&!this.isLast&&!q.showFirstLabel||this.isLast&&!this.isFirst&&!q.showLastLabel?p=!1:!m||h.step||h.rotation||a||0===e||this.handleOverflow(c),d&&f%d&&(p=!1),p&&g(c.y)?(c.opacity=e,t[this.isNewLabel?"attr":"animate"](c),this.isNewLabel=!1):(t.attr("y",-9999),this.isNewLabel=!0))};f.prototype.replaceMovedLabel=function(){var c=this.label,a=this.axis,
e=a.reversed;if(c&&!this.isNew){var f=a.horiz?e?a.left:a.width+a.left:c.xy.x;e=a.horiz?c.xy.y:e?a.width+a.top:a.top;c.animate({x:f,y:e,opacity:0},void 0,c.destroy);delete this.label}a.isDirty=!0;this.label=this.movedLabel;delete this.movedLabel};return f}();"";return w});M(a,"Core/Axis/Axis.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Axis/AxisDefaults.js"],a["Core/Color/Color.js"],a["Core/Color/Palette.js"],a["Core/DefaultOptions.js"],a["Core/Foundation.js"],a["Core/Globals.js"],a["Core/Axis/Tick.js"],
a["Core/Utilities.js"]],function(a,w,C,E,z,x,J,u,n){var m=a.animObject,g=z.defaultOptions,c=x.registerEventOptions,e=J.deg2rad,l=n.arrayMax,f=n.arrayMin,v=n.clamp,q=n.correctFloat,k=n.defined,r=n.destroyObjectProperties,D=n.erase,B=n.error,O=n.extend,t=n.fireEvent,h=n.getMagnitude,d=n.isArray,b=n.isNumber,p=n.isString,G=n.merge,y=n.normalizeTickInterval,L=n.objectEach,F=n.pick,P=n.relativeLength,S=n.removeEvent,Q=n.splat,V=n.syncTimeout;a=function(){function a(b,a){this.zoomEnabled=this.width=this.visible=
this.userOptions=this.translationSlope=this.transB=this.transA=this.top=this.ticks=this.tickRotCorr=this.tickPositions=this.tickmarkOffset=this.tickInterval=this.tickAmount=this.side=this.series=this.right=this.positiveValuesOnly=this.pos=this.pointRangePadding=this.pointRange=this.plotLinesAndBandsGroups=this.plotLinesAndBands=this.paddedTicks=this.overlap=this.options=this.offset=this.names=this.minPixelPadding=this.minorTicks=this.minorTickInterval=this.min=this.maxLabelLength=this.max=this.len=
this.left=this.labelFormatter=this.labelEdge=this.isLinked=this.height=this.hasVisibleSeries=this.hasNames=this.eventOptions=this.coll=this.closestPointRange=this.chart=this.categories=this.bottom=this.alternateBands=void 0;this.init(b,a)}a.prototype.init=function(a,d){var h=d.isX;this.chart=a;this.horiz=a.inverted&&!this.isZAxis?!h:h;this.isXAxis=h;this.coll=this.coll||(h?"xAxis":"yAxis");t(this,"init",{userOptions:d});this.opposite=F(d.opposite,this.opposite);this.side=F(d.side,this.side,this.horiz?
this.opposite?0:2:this.opposite?1:3);this.setOptions(d);var e=this.options,f=e.labels,p=e.type;this.userOptions=d;this.minPixelPadding=0;this.reversed=F(e.reversed,this.reversed);this.visible=e.visible;this.zoomEnabled=e.zoomEnabled;this.hasNames="category"===p||!0===e.categories;this.categories=e.categories||this.hasNames;this.names||(this.names=[],this.names.keys={});this.plotLinesAndBandsGroups={};this.positiveValuesOnly=!!this.logarithmic;this.isLinked=k(e.linkedTo);this.ticks={};this.labelEdge=
[];this.minorTicks={};this.plotLinesAndBands=[];this.alternateBands={};this.len=0;this.minRange=this.userMinRange=e.minRange||e.maxZoom;this.range=e.range;this.offset=e.offset||0;this.min=this.max=null;d=F(e.crosshair,Q(a.options.tooltip.crosshairs)[h?0:1]);this.crosshair=!0===d?{}:d;-1===a.axes.indexOf(this)&&(h?a.axes.splice(a.xAxis.length,0,this):a.axes.push(this),a[this.coll].push(this));this.series=this.series||[];a.inverted&&!this.isZAxis&&h&&"undefined"===typeof this.reversed&&(this.reversed=
!0);this.labelRotation=b(f.rotation)?f.rotation:void 0;c(this,e);t(this,"afterInit")};a.prototype.setOptions=function(b){this.options=G(w.defaultXAxisOptions,"yAxis"===this.coll&&w.defaultYAxisOptions,[w.defaultTopAxisOptions,w.defaultRightAxisOptions,w.defaultBottomAxisOptions,w.defaultLeftAxisOptions][this.side],G(g[this.coll],b));t(this,"afterSetOptions",{userOptions:b})};a.prototype.defaultLabelFormatter=function(a){var d=this.axis;a=this.chart.numberFormatter;var c=b(this.value)?this.value:NaN,
e=d.chart.time,h=this.dateTimeLabelFormat,f=g.lang,p=f.numericSymbols;f=f.numericSymbolMagnitude||1E3;var H=d.logarithmic?Math.abs(c):d.tickInterval,y=p&&p.length;if(d.categories)var k=""+this.value;else if(h)k=e.dateFormat(h,c);else if(y&&1E3<=H)for(;y--&&"undefined"===typeof k;)d=Math.pow(f,y+1),H>=d&&0===10*c%d&&null!==p[y]&&0!==c&&(k=a(c/d,-1)+p[y]);"undefined"===typeof k&&(k=1E4<=Math.abs(c)?a(c,-1):a(c,-1,void 0,""));return k};a.prototype.getSeriesExtremes=function(){var a=this,d=a.chart,c;
t(this,"getSeriesExtremes",null,function(){a.hasVisibleSeries=!1;a.dataMin=a.dataMax=a.threshold=null;a.softThreshold=!a.isXAxis;a.stacking&&a.stacking.buildStacks();a.series.forEach(function(e){if(e.visible||!d.options.chart.ignoreHiddenSeries){var h=e.options,f=h.threshold;a.hasVisibleSeries=!0;a.positiveValuesOnly&&0>=f&&(f=null);if(a.isXAxis){if(h=e.xData,h.length){h=a.logarithmic?h.filter(a.validatePositiveValue):h;c=e.getXExtremes(h);var p=c.min;var g=c.max;b(p)||p instanceof Date||(h=h.filter(b),
c=e.getXExtremes(h),p=c.min,g=c.max);h.length&&(a.dataMin=Math.min(F(a.dataMin,p),p),a.dataMax=Math.max(F(a.dataMax,g),g))}}else if(e=e.applyExtremes(),b(e.dataMin)&&(p=e.dataMin,a.dataMin=Math.min(F(a.dataMin,p),p)),b(e.dataMax)&&(g=e.dataMax,a.dataMax=Math.max(F(a.dataMax,g),g)),k(f)&&(a.threshold=f),!h.softThreshold||a.positiveValuesOnly)a.softThreshold=!1}})});t(this,"afterGetSeriesExtremes")};a.prototype.translate=function(a,d,c,e,h,f){var p=this.linkedParent||this,g=e&&p.old?p.old.min:p.min,
H=p.minPixelPadding;h=(p.isOrdinal||p.brokenAxis&&p.brokenAxis.hasBreaks||p.logarithmic&&h)&&p.lin2val;var K=1,y=0;e=e&&p.old?p.old.transA:p.transA;e||(e=p.transA);c&&(K*=-1,y=p.len);p.reversed&&(K*=-1,y-=K*(p.sector||p.len));d?(a=(a*K+y-H)/e+g,h&&(a=p.lin2val(a))):(h&&(a=p.val2lin(a)),a=b(g)?K*(a-g)*e+y+K*H+(b(f)?e*f:0):void 0);return a};a.prototype.toPixels=function(b,a){return this.translate(b,!1,!this.horiz,null,!0)+(a?0:this.pos)};a.prototype.toValue=function(b,a){return this.translate(b-(a?
0:this.pos),!0,!this.horiz,null,!0)};a.prototype.getPlotLinePath=function(a){function d(b,a,d){if("pass"!==m&&b<a||b>d)m?b=v(b,a,d):r=!0;return b}var c=this,e=c.chart,h=c.left,f=c.top,p=a.old,g=a.value,H=a.lineWidth,y=p&&e.oldChartHeight||e.chartHeight,k=p&&e.oldChartWidth||e.chartWidth,G=c.transB,l=a.translatedValue,m=a.force,L,q,n,B,r;a={value:g,lineWidth:H,old:p,force:m,acrossPanes:a.acrossPanes,translatedValue:l};t(this,"getPlotLinePath",a,function(a){l=F(l,c.translate(g,null,null,p));l=v(l,-1E5,
1E5);L=n=Math.round(l+G);q=B=Math.round(y-l-G);b(l)?c.horiz?(q=f,B=y-c.bottom,L=n=d(L,h,h+c.width)):(L=h,n=k-c.right,q=B=d(q,f,f+c.height)):(r=!0,m=!1);a.path=r&&!m?null:e.renderer.crispLine([["M",L,q],["L",n,B]],H||1)});return a.path};a.prototype.getLinearTickPositions=function(b,a,d){var c=q(Math.floor(a/b)*b);d=q(Math.ceil(d/b)*b);var e=[],h;q(c+b)===c&&(h=20);if(this.single)return[a];for(a=c;a<=d;){e.push(a);a=q(a+b,h);if(a===f)break;var f=a}return e};a.prototype.getMinorTickInterval=function(){var b=
this.options;return!0===b.minorTicks?F(b.minorTickInterval,"auto"):!1===b.minorTicks?null:b.minorTickInterval};a.prototype.getMinorTickPositions=function(){var b=this.options,a=this.tickPositions,d=this.minorTickInterval,c=this.pointRangePadding||0,e=this.min-c;c=this.max+c;var h=c-e,f=[];if(h&&h/d<this.len/3){var p=this.logarithmic;if(p)this.paddedTicks.forEach(function(b,a,c){a&&f.push.apply(f,p.getLogTickPositions(d,c[a-1],c[a],!0))});else if(this.dateTime&&"auto"===this.getMinorTickInterval())f=
f.concat(this.getTimeTicks(this.dateTime.normalizeTimeTickInterval(d),e,c,b.startOfWeek));else for(b=e+(a[0]-e)%d;b<=c&&b!==f[0];b+=d)f.push(b)}0!==f.length&&this.trimTicks(f);return f};a.prototype.adjustForMinRange=function(){var b=this.options,a=this.logarithmic,d=this.min,c=this.max,e=0,h,p,g,y;this.isXAxis&&"undefined"===typeof this.minRange&&!a&&(k(b.min)||k(b.max)?this.minRange=null:(this.series.forEach(function(b){g=b.xData;y=b.xIncrement?1:g.length-1;if(1<g.length)for(h=y;0<h;h--)if(p=g[h]-
g[h-1],!e||p<e)e=p}),this.minRange=Math.min(5*e,this.dataMax-this.dataMin)));if(c-d<this.minRange){var G=this.dataMax-this.dataMin>=this.minRange;var t=this.minRange;var m=(t-c+d)/2;m=[d-m,F(b.min,d-m)];G&&(m[2]=this.logarithmic?this.logarithmic.log2lin(this.dataMin):this.dataMin);d=l(m);c=[d+t,F(b.max,d+t)];G&&(c[2]=a?a.log2lin(this.dataMax):this.dataMax);c=f(c);c-d<t&&(m[0]=c-t,m[1]=F(b.min,c-t),d=l(m))}this.min=d;this.max=c};a.prototype.getClosest=function(){var b;this.categories?b=1:this.series.forEach(function(a){var d=
a.closestPointRange,c=a.visible||!a.chart.options.chart.ignoreHiddenSeries;!a.noSharedTooltip&&k(d)&&c&&(b=k(b)?Math.min(b,d):d)});return b};a.prototype.nameToX=function(b){var a=d(this.categories),c=a?this.categories:this.names,e=b.options.x;b.series.requireSorting=!1;k(e)||(e=this.options.uniqueNames?a?c.indexOf(b.name):F(c.keys[b.name],-1):b.series.autoIncrement());if(-1===e){if(!a)var h=c.length}else h=e;"undefined"!==typeof h&&(this.names[h]=b.name,this.names.keys[b.name]=h);return h};a.prototype.updateNames=
function(){var b=this,a=this.names;0<a.length&&(Object.keys(a.keys).forEach(function(b){delete a.keys[b]}),a.length=0,this.minRange=this.userMinRange,(this.series||[]).forEach(function(a){a.xIncrement=null;if(!a.points||a.isDirtyData)b.max=Math.max(b.max,a.xData.length-1),a.processData(),a.generatePoints();a.data.forEach(function(d,c){if(d&&d.options&&"undefined"!==typeof d.name){var e=b.nameToX(d);"undefined"!==typeof e&&e!==d.x&&(d.x=e,a.xData[c]=e)}})}))};a.prototype.setAxisTranslation=function(){var b=
this,a=b.max-b.min,d=b.linkedParent,c=!!b.categories,e=b.isXAxis,h=b.axisPointRange||0,f=0,g=0,y=b.transA;if(e||c||h){var k=b.getClosest();d?(f=d.minPointOffset,g=d.pointRangePadding):b.series.forEach(function(a){var d=c?1:e?F(a.options.pointRange,k,0):b.axisPointRange||0,A=a.options.pointPlacement;h=Math.max(h,d);if(!b.single||c)a=a.is("xrange")?!e:e,f=Math.max(f,a&&p(A)?0:d/2),g=Math.max(g,a&&"on"===A?0:d)});d=b.ordinal&&b.ordinal.slope&&k?b.ordinal.slope/k:1;b.minPointOffset=f*=d;b.pointRangePadding=
g*=d;b.pointRange=Math.min(h,b.single&&c?1:a);e&&(b.closestPointRange=k)}b.translationSlope=b.transA=y=b.staticScale||b.len/(a+g||1);b.transB=b.horiz?b.left:b.bottom;b.minPixelPadding=y*f;t(this,"afterSetAxisTranslation")};a.prototype.minFromRange=function(){return this.max-this.range};a.prototype.setTickInterval=function(a){var d=this,c=d.chart,e=d.logarithmic,f=d.options,p=d.isXAxis,g=d.isLinked,l=f.tickPixelInterval,G=d.categories,H=d.softThreshold,m=f.maxPadding,L=f.minPadding,n=f.tickInterval,
v=b(d.threshold)?d.threshold:null;d.dateTime||G||g||this.getTickAmount();var r=F(d.userMin,f.min);var P=F(d.userMax,f.max);if(g){d.linkedParent=c[d.coll][f.linkedTo];var D=d.linkedParent.getExtremes();d.min=F(D.min,D.dataMin);d.max=F(D.max,D.dataMax);f.type!==d.linkedParent.options.type&&B(11,1,c)}else{if(H&&k(v))if(d.dataMin>=v)D=v,L=0;else if(d.dataMax<=v){var I=v;m=0}d.min=F(r,D,d.dataMin);d.max=F(P,I,d.dataMax)}e&&(d.positiveValuesOnly&&!a&&0>=Math.min(d.min,F(d.dataMin,d.min))&&B(10,1,c),d.min=
q(e.log2lin(d.min),16),d.max=q(e.log2lin(d.max),16));d.range&&k(d.max)&&(d.userMin=d.min=r=Math.max(d.dataMin,d.minFromRange()),d.userMax=P=d.max,d.range=null);t(d,"foundExtremes");d.beforePadding&&d.beforePadding();d.adjustForMinRange();!(G||d.axisPointRange||d.stacking&&d.stacking.usePercentage||g)&&k(d.min)&&k(d.max)&&(c=d.max-d.min)&&(!k(r)&&L&&(d.min-=c*L),!k(P)&&m&&(d.max+=c*m));b(d.userMin)||(b(f.softMin)&&f.softMin<d.min&&(d.min=r=f.softMin),b(f.floor)&&(d.min=Math.max(d.min,f.floor)));b(d.userMax)||
(b(f.softMax)&&f.softMax>d.max&&(d.max=P=f.softMax),b(f.ceiling)&&(d.max=Math.min(d.max,f.ceiling)));H&&k(d.dataMin)&&(v=v||0,!k(r)&&d.min<v&&d.dataMin>=v?d.min=d.options.minRange?Math.min(v,d.max-d.minRange):v:!k(P)&&d.max>v&&d.dataMax<=v&&(d.max=d.options.minRange?Math.max(v,d.min+d.minRange):v));b(d.min)&&b(d.max)&&!this.chart.polar&&d.min>d.max&&(k(d.options.min)?d.max=d.min:k(d.options.max)&&(d.min=d.max));d.tickInterval=d.min===d.max||"undefined"===typeof d.min||"undefined"===typeof d.max?1:
g&&d.linkedParent&&!n&&l===d.linkedParent.options.tickPixelInterval?n=d.linkedParent.tickInterval:F(n,this.tickAmount?(d.max-d.min)/Math.max(this.tickAmount-1,1):void 0,G?1:(d.max-d.min)*l/Math.max(d.len,l));p&&!a&&(d.series.forEach(function(b){b.forceCrop=b.forceCropping&&b.forceCropping();b.processData(d.min!==(d.old&&d.old.min)||d.max!==(d.old&&d.old.max))}),t(this,"postProcessData"));d.setAxisTranslation();t(this,"initialAxisTranslation");d.pointRange&&!n&&(d.tickInterval=Math.max(d.pointRange,
d.tickInterval));a=F(f.minTickInterval,d.dateTime&&!d.series.some(function(b){return b.noSharedTooltip})?d.closestPointRange:0);!n&&d.tickInterval<a&&(d.tickInterval=a);d.dateTime||d.logarithmic||n||(d.tickInterval=y(d.tickInterval,void 0,h(d.tickInterval),F(f.allowDecimals,.5>d.tickInterval||void 0!==this.tickAmount),!!this.tickAmount));this.tickAmount||(d.tickInterval=d.unsquish());this.setTickPositions()};a.prototype.setTickPositions=function(){var b=this.options,d=b.tickPositions,a=this.getMinorTickInterval(),
c=this.hasVerticalPanning(),e="colorAxis"===this.coll,h=(e||!c)&&b.startOnTick;c=(e||!c)&&b.endOnTick;e=b.tickPositioner;this.tickmarkOffset=this.categories&&"between"===b.tickmarkPlacement&&1===this.tickInterval?.5:0;this.minorTickInterval="auto"===a&&this.tickInterval?this.tickInterval/5:a;this.single=this.min===this.max&&k(this.min)&&!this.tickAmount&&(parseInt(this.min,10)===this.min||!1!==b.allowDecimals);this.tickPositions=a=d&&d.slice();!a&&(this.ordinal&&this.ordinal.positions||!((this.max-
this.min)/this.tickInterval>Math.max(2*this.len,200))?a=this.dateTime?this.getTimeTicks(this.dateTime.normalizeTimeTickInterval(this.tickInterval,b.units),this.min,this.max,b.startOfWeek,this.ordinal&&this.ordinal.positions,this.closestPointRange,!0):this.logarithmic?this.logarithmic.getLogTickPositions(this.tickInterval,this.min,this.max):this.getLinearTickPositions(this.tickInterval,this.min,this.max):(a=[this.min,this.max],B(19,!1,this.chart)),a.length>this.len&&(a=[a[0],a.pop()],a[0]===a[1]&&
(a.length=1)),this.tickPositions=a,e&&(e=e.apply(this,[this.min,this.max])))&&(this.tickPositions=a=e);this.paddedTicks=a.slice(0);this.trimTicks(a,h,c);this.isLinked||(this.single&&2>a.length&&!this.categories&&!this.series.some(function(b){return b.is("heatmap")&&"between"===b.options.pointPlacement})&&(this.min-=.5,this.max+=.5),d||e||this.adjustTickAmount());t(this,"afterSetTickPositions")};a.prototype.trimTicks=function(b,d,a){var c=b[0],e=b[b.length-1],h=!this.isOrdinal&&this.minPointOffset||
0;t(this,"trimTicks");if(!this.isLinked){if(d&&-Infinity!==c)this.min=c;else for(;this.min-h>b[0];)b.shift();if(a)this.max=e;else for(;this.max+h<b[b.length-1];)b.pop();0===b.length&&k(c)&&!this.options.tickPositions&&b.push((e+c)/2)}};a.prototype.alignToOthers=function(){var b={},d=this.options,a;!1!==this.chart.options.chart.alignTicks&&d.alignTicks&&!1!==d.startOnTick&&!1!==d.endOnTick&&!this.logarithmic&&this.chart[this.coll].forEach(function(d){var c=d.options;c=[d.horiz?c.left:c.top,c.width,
c.height,c.pane].join();d.series.length&&(b[c]?a=!0:b[c]=1)});return a};a.prototype.getTickAmount=function(){var b=this.options,d=b.tickPixelInterval,a=b.tickAmount;!k(b.tickInterval)&&!a&&this.len<d&&!this.isRadial&&!this.logarithmic&&b.startOnTick&&b.endOnTick&&(a=2);!a&&this.alignToOthers()&&(a=Math.ceil(this.len/d)+1);4>a&&(this.finalTickAmt=a,a=5);this.tickAmount=a};a.prototype.adjustTickAmount=function(){var d=this.options,a=this.tickInterval,c=this.tickPositions,e=this.tickAmount,h=this.finalTickAmt,
f=c&&c.length,p=F(this.threshold,this.softThreshold?0:null);if(this.hasData()&&b(this.min)&&b(this.max)){if(f<e){for(;c.length<e;)c.length%2||this.min===p?c.push(q(c[c.length-1]+a)):c.unshift(q(c[0]-a));this.transA*=(f-1)/(e-1);this.min=d.startOnTick?c[0]:Math.min(this.min,c[0]);this.max=d.endOnTick?c[c.length-1]:Math.max(this.max,c[c.length-1])}else f>e&&(this.tickInterval*=2,this.setTickPositions());if(k(h)){for(a=d=c.length;a--;)(3===h&&1===a%2||2>=h&&0<a&&a<d-1)&&c.splice(a,1);this.finalTickAmt=
void 0}}};a.prototype.setScale=function(){var b=!1,d=!1;this.series.forEach(function(a){b=b||a.isDirtyData||a.isDirty;d=d||a.xAxis&&a.xAxis.isDirty||!1});this.setAxisSize();var a=this.len!==(this.old&&this.old.len);a||b||d||this.isLinked||this.forceRedraw||this.userMin!==(this.old&&this.old.userMin)||this.userMax!==(this.old&&this.old.userMax)||this.alignToOthers()?(this.stacking&&this.stacking.resetStacks(),this.forceRedraw=!1,this.getSeriesExtremes(),this.setTickInterval(),this.isDirty||(this.isDirty=
a||this.min!==(this.old&&this.old.min)||this.max!==(this.old&&this.old.max))):this.stacking&&this.stacking.cleanStacks();b&&this.panningState&&(this.panningState.isDirty=!0);t(this,"afterSetScale")};a.prototype.setExtremes=function(b,d,a,c,e){var h=this,f=h.chart;a=F(a,!0);h.series.forEach(function(b){delete b.kdTree});e=O(e,{min:b,max:d});t(h,"setExtremes",e,function(){h.userMin=b;h.userMax=d;h.eventArgs=e;a&&f.redraw(c)})};a.prototype.zoom=function(b,d){var a=this,c=this.dataMin,e=this.dataMax,
h=this.options,f=Math.min(c,F(h.min,c)),p=Math.max(e,F(h.max,e));b={newMin:b,newMax:d};t(this,"zoom",b,function(b){var d=b.newMin,h=b.newMax;if(d!==a.min||h!==a.max)a.allowZoomOutside||(k(c)&&(d<f&&(d=f),d>p&&(d=p)),k(e)&&(h<f&&(h=f),h>p&&(h=p))),a.displayBtn="undefined"!==typeof d||"undefined"!==typeof h,a.setExtremes(d,h,!1,void 0,{trigger:"zoom"});b.zoomed=!0});return b.zoomed};a.prototype.setAxisSize=function(){var b=this.chart,d=this.options,a=d.offsets||[0,0,0,0],c=this.horiz,e=this.width=Math.round(P(F(d.width,
b.plotWidth-a[3]+a[1]),b.plotWidth)),h=this.height=Math.round(P(F(d.height,b.plotHeight-a[0]+a[2]),b.plotHeight)),f=this.top=Math.round(P(F(d.top,b.plotTop+a[0]),b.plotHeight,b.plotTop));d=this.left=Math.round(P(F(d.left,b.plotLeft+a[3]),b.plotWidth,b.plotLeft));this.bottom=b.chartHeight-h-f;this.right=b.chartWidth-e-d;this.len=Math.max(c?e:h,0);this.pos=c?d:f};a.prototype.getExtremes=function(){var b=this.logarithmic;return{min:b?q(b.lin2log(this.min)):this.min,max:b?q(b.lin2log(this.max)):this.max,
dataMin:this.dataMin,dataMax:this.dataMax,userMin:this.userMin,userMax:this.userMax}};a.prototype.getThreshold=function(b){var d=this.logarithmic,a=d?d.lin2log(this.min):this.min;d=d?d.lin2log(this.max):this.max;null===b||-Infinity===b?b=a:Infinity===b?b=d:a>b?b=a:d<b&&(b=d);return this.translate(b,0,1,0,1)};a.prototype.autoLabelAlign=function(b){var d=(F(b,0)-90*this.side+720)%360;b={align:"center"};t(this,"autoLabelAlign",b,function(b){15<d&&165>d?b.align="right":195<d&&345>d&&(b.align="left")});
return b.align};a.prototype.tickSize=function(b){var d=this.options,a=F(d["tick"===b?"tickWidth":"minorTickWidth"],"tick"===b&&this.isXAxis&&!this.categories?1:0),c=d["tick"===b?"tickLength":"minorTickLength"];if(a&&c){"inside"===d[b+"Position"]&&(c=-c);var e=[c,a]}b={tickSize:e};t(this,"afterTickSize",b);return b.tickSize};a.prototype.labelMetrics=function(){var b=this.tickPositions&&this.tickPositions[0]||0;return this.chart.renderer.fontMetrics(this.options.labels.style.fontSize,this.ticks[b]&&
this.ticks[b].label)};a.prototype.unsquish=function(){var d=this.options.labels,a=this.horiz,c=this.tickInterval,h=this.len/(((this.categories?1:0)+this.max-this.min)/c),f=d.rotation,p=this.labelMetrics(),g=Math.max(this.max-this.min,0),y=function(b){var d=b/(h||1);d=1<d?Math.ceil(d):1;d*c>g&&Infinity!==b&&Infinity!==h&&g&&(d=Math.ceil(g/c));return q(d*c)},k=c,l,G,t=Number.MAX_VALUE;if(a){if(!d.staggerLines&&!d.step)if(b(f))var m=[f];else h<d.autoRotationLimit&&(m=d.autoRotation);m&&m.forEach(function(b){if(b===
f||b&&-90<=b&&90>=b){G=y(Math.abs(p.h/Math.sin(e*b)));var d=G+Math.abs(b/360);d<t&&(t=d,l=b,k=G)}})}else d.step||(k=y(p.h));this.autoRotation=m;this.labelRotation=F(l,b(f)?f:0);return k};a.prototype.getSlotWidth=function(d){var a=this.chart,c=this.horiz,e=this.options.labels,h=Math.max(this.tickPositions.length-(this.categories?0:1),1),f=a.margin[3];if(d&&b(d.slotWidth))return d.slotWidth;if(c&&2>e.step)return e.rotation?0:(this.staggerLines||1)*this.len/h;if(!c){d=e.style.width;if(void 0!==d)return parseInt(String(d),
10);if(f)return f-a.spacing[3]}return.33*a.chartWidth};a.prototype.renderUnsquish=function(){var b=this.chart,d=b.renderer,a=this.tickPositions,c=this.ticks,e=this.options.labels,h=e.style,f=this.horiz,g=this.getSlotWidth(),y=Math.max(1,Math.round(g-2*e.padding)),k={},G=this.labelMetrics(),l=h.textOverflow,t=0;p(e.rotation)||(k.rotation=e.rotation||0);a.forEach(function(b){b=c[b];b.movedLabel&&b.replaceMovedLabel();b&&b.label&&b.label.textPxLength>t&&(t=b.label.textPxLength)});this.maxLabelLength=
t;if(this.autoRotation)t>y&&t>G.h?k.rotation=this.labelRotation:this.labelRotation=0;else if(g){var m=y;if(!l){var F="clip";for(y=a.length;!f&&y--;){var L=a[y];if(L=c[L].label)L.styles&&"ellipsis"===L.styles.textOverflow?L.css({textOverflow:"clip"}):L.textPxLength>g&&L.css({width:g+"px"}),L.getBBox().height>this.len/a.length-(G.h-G.f)&&(L.specificTextOverflow="ellipsis")}}}k.rotation&&(m=t>.5*b.chartHeight?.33*b.chartHeight:t,l||(F="ellipsis"));if(this.labelAlign=e.align||this.autoLabelAlign(this.labelRotation))k.align=
this.labelAlign;a.forEach(function(b){var d=(b=c[b])&&b.label,a=h.width,e={};d&&(d.attr(k),b.shortenLabel?b.shortenLabel():m&&!a&&"nowrap"!==h.whiteSpace&&(m<d.textPxLength||"SPAN"===d.element.tagName)?(e.width=m+"px",l||(e.textOverflow=d.specificTextOverflow||F),d.css(e)):d.styles&&d.styles.width&&!e.width&&!a&&d.css({width:null}),delete d.specificTextOverflow,b.rotation=k.rotation)},this);this.tickRotCorr=d.rotCorr(G.b,this.labelRotation||0,0!==this.side)};a.prototype.hasData=function(){return this.series.some(function(b){return b.hasData()})||
this.options.showEmpty&&k(this.min)&&k(this.max)};a.prototype.addTitle=function(b){var d=this.chart.renderer,a=this.horiz,c=this.opposite,e=this.options.title,h=this.chart.styledMode,f;this.axisTitle||((f=e.textAlign)||(f=(a?{low:"left",middle:"center",high:"right"}:{low:c?"right":"left",middle:"center",high:c?"left":"right"})[e.align]),this.axisTitle=d.text(e.text||"",0,0,e.useHTML).attr({zIndex:7,rotation:e.rotation,align:f}).addClass("highcharts-axis-title"),h||this.axisTitle.css(G(e.style)),this.axisTitle.add(this.axisGroup),
this.axisTitle.isNew=!0);h||e.style.width||this.isRadial||this.axisTitle.css({width:this.len+"px"});this.axisTitle[b?"show":"hide"](b)};a.prototype.generateTick=function(b){var d=this.ticks;d[b]?d[b].addLabel():d[b]=new u(this,b)};a.prototype.getOffset=function(){var b=this,d=this,a=d.chart,c=a.renderer,e=d.options,h=d.tickPositions,f=d.ticks,p=d.horiz,g=d.side,y=a.inverted&&!d.isZAxis?[1,0,3,2][g]:g,G=d.hasData(),l=e.title,m=e.labels,q=a.axisOffset;a=a.clipOffset;var v=[-1,1,1,-1][g],n=e.className,
B=d.axisParent,r,P=0,D=0,ca=0;d.showAxis=r=G||e.showEmpty;d.staggerLines=d.horiz&&m.staggerLines||void 0;if(!d.axisGroup){var ia=function(d,a,e){return c.g(d).attr({zIndex:e}).addClass("highcharts-"+b.coll.toLowerCase()+a+" "+(b.isRadial?"highcharts-radial-axis"+a+" ":"")+(n||"")).add(B)};d.gridGroup=ia("grid","-grid",e.gridZIndex);d.axisGroup=ia("axis","",e.zIndex);d.labelGroup=ia("axis-labels","-labels",m.zIndex)}G||d.isLinked?(h.forEach(function(b){d.generateTick(b)}),d.renderUnsquish(),d.reserveSpaceDefault=
0===g||2===g||{1:"left",3:"right"}[g]===d.labelAlign,F(m.reserveSpace,"center"===d.labelAlign?!0:null,d.reserveSpaceDefault)&&h.forEach(function(b){ca=Math.max(f[b].getLabelSize(),ca)}),d.staggerLines&&(ca*=d.staggerLines),d.labelOffset=ca*(d.opposite?-1:1)):L(f,function(b,d){b.destroy();delete f[d]});if(l&&l.text&&!1!==l.enabled&&(d.addTitle(r),r&&!1!==l.reserveSpace)){d.titleOffset=P=d.axisTitle.getBBox()[p?"height":"width"];var I=l.offset;D=k(I)?0:F(l.margin,p?5:10)}d.renderLine();d.offset=v*F(e.offset,
q[g]?q[g]+(e.margin||0):0);d.tickRotCorr=d.tickRotCorr||{x:0,y:0};l=0===g?-d.labelMetrics().h:2===g?d.tickRotCorr.y:0;G=Math.abs(ca)+D;ca&&(G=G-l+v*(p?F(m.y,d.tickRotCorr.y+8*v):m.x));d.axisTitleMargin=F(I,G);d.getMaxLabelDimensions&&(d.maxLabelDimensions=d.getMaxLabelDimensions(f,h));p=this.tickSize("tick");q[g]=Math.max(q[g],(d.axisTitleMargin||0)+P+v*d.offset,G,h&&h.length&&p?p[0]+v*d.offset:0);e=e.offset?0:2*Math.floor(d.axisLine.strokeWidth()/2);a[y]=Math.max(a[y],e);t(this,"afterGetOffset")};
a.prototype.getLinePath=function(b){var d=this.chart,a=this.opposite,c=this.offset,e=this.horiz,h=this.left+(a?this.width:0)+c;c=d.chartHeight-this.bottom-(a?this.height:0)+c;a&&(b*=-1);return d.renderer.crispLine([["M",e?this.left:h,e?c:this.top],["L",e?d.chartWidth-this.right:h,e?c:d.chartHeight-this.bottom]],b)};a.prototype.renderLine=function(){this.axisLine||(this.axisLine=this.chart.renderer.path().addClass("highcharts-axis-line").add(this.axisGroup),this.chart.styledMode||this.axisLine.attr({stroke:this.options.lineColor,
"stroke-width":this.options.lineWidth,zIndex:7}))};a.prototype.getTitlePosition=function(){var b=this.horiz,d=this.left,a=this.top,c=this.len,e=this.options.title,h=b?d:a,f=this.opposite,p=this.offset,g=e.x,y=e.y,k=this.axisTitle,G=this.chart.renderer.fontMetrics(e.style.fontSize,k);k=Math.max(k.getBBox(null,0).height-G.h-1,0);c={low:h+(b?0:c),middle:h+c/2,high:h+(b?c:0)}[e.align];d=(b?a+this.height:d)+(b?1:-1)*(f?-1:1)*this.axisTitleMargin+[-k,k,G.f,-k][this.side];b={x:b?c+g:d+(f?this.width:0)+p+
g,y:b?d+y-(f?this.height:0)+p:c+y};t(this,"afterGetTitlePosition",{titlePosition:b});return b};a.prototype.renderMinorTick=function(b,d){var a=this.minorTicks;a[b]||(a[b]=new u(this,b,"minor"));d&&a[b].isNew&&a[b].render(null,!0);a[b].render(null,!1,1)};a.prototype.renderTick=function(b,d,a){var c=this.ticks;if(!this.isLinked||b>=this.min&&b<=this.max||this.grid&&this.grid.isColumn)c[b]||(c[b]=new u(this,b)),a&&c[b].isNew&&c[b].render(d,!0,-1),c[b].render(d)};a.prototype.render=function(){var d=this,
a=d.chart,c=d.logarithmic,e=d.options,h=d.isLinked,f=d.tickPositions,p=d.axisTitle,g=d.ticks,y=d.minorTicks,k=d.alternateBands,G=e.stackLabels,l=e.alternateGridColor,F=d.tickmarkOffset,q=d.axisLine,v=d.showAxis,n=m(a.renderer.globalAnimation),B,r;d.labelEdge.length=0;d.overlap=!1;[g,y,k].forEach(function(b){L(b,function(b){b.isActive=!1})});if(d.hasData()||h){var P=d.chart.hasRendered&&d.old&&b(d.old.min);d.minorTickInterval&&!d.categories&&d.getMinorTickPositions().forEach(function(b){d.renderMinorTick(b,
P)});f.length&&(f.forEach(function(b,a){d.renderTick(b,a,P)}),F&&(0===d.min||d.single)&&(g[-1]||(g[-1]=new u(d,-1,null,!0)),g[-1].render(-1)));l&&f.forEach(function(b,e){r="undefined"!==typeof f[e+1]?f[e+1]+F:d.max-F;0===e%2&&b<d.max&&r<=d.max+(a.polar?-F:F)&&(k[b]||(k[b]=new J.PlotLineOrBand(d)),B=b+F,k[b].options={from:c?c.lin2log(B):B,to:c?c.lin2log(r):r,color:l,className:"highcharts-alternate-grid"},k[b].render(),k[b].isActive=!0)});d._addedPlotLB||(d._addedPlotLB=!0,(e.plotLines||[]).concat(e.plotBands||
[]).forEach(function(b){d.addPlotBandOrLine(b)}))}[g,y,k].forEach(function(b){var d=[],c=n.duration;L(b,function(b,a){b.isActive||(b.render(a,!1,0),b.isActive=!1,d.push(a))});V(function(){for(var a=d.length;a--;)b[d[a]]&&!b[d[a]].isActive&&(b[d[a]].destroy(),delete b[d[a]])},b!==k&&a.hasRendered&&c?c:0)});q&&(q[q.isPlaced?"animate":"attr"]({d:this.getLinePath(q.strokeWidth())}),q.isPlaced=!0,q[v?"show":"hide"](v));p&&v&&(e=d.getTitlePosition(),b(e.y)?(p[p.isNew?"attr":"animate"](e),p.isNew=!1):(p.attr("y",
-9999),p.isNew=!0));G&&G.enabled&&d.stacking&&d.stacking.renderStackTotals();d.old={len:d.len,max:d.max,min:d.min,transA:d.transA,userMax:d.userMax,userMin:d.userMin};d.isDirty=!1;t(this,"afterRender")};a.prototype.redraw=function(){this.visible&&(this.render(),this.plotLinesAndBands.forEach(function(b){b.render()}));this.series.forEach(function(b){b.isDirty=!0})};a.prototype.getKeepProps=function(){return this.keepProps||a.keepProps};a.prototype.destroy=function(b){var d=this,a=d.plotLinesAndBands,
c=this.eventOptions;t(this,"destroy",{keepEvents:b});b||S(d);[d.ticks,d.minorTicks,d.alternateBands].forEach(function(b){r(b)});if(a)for(b=a.length;b--;)a[b].destroy();"axisLine axisTitle axisGroup gridGroup labelGroup cross scrollbar".split(" ").forEach(function(b){d[b]&&(d[b]=d[b].destroy())});for(var e in d.plotLinesAndBandsGroups)d.plotLinesAndBandsGroups[e]=d.plotLinesAndBandsGroups[e].destroy();L(d,function(b,a){-1===d.getKeepProps().indexOf(a)&&delete d[a]});this.eventOptions=c};a.prototype.drawCrosshair=
function(b,d){var a=this.crosshair,c=F(a&&a.snap,!0),e=this.chart,h,f=this.cross;t(this,"drawCrosshair",{e:b,point:d});b||(b=this.cross&&this.cross.e);if(a&&!1!==(k(d)||!c)){c?k(d)&&(h=F("colorAxis"!==this.coll?d.crosshairPos:null,this.isXAxis?d.plotX:this.len-d.plotY)):h=b&&(this.horiz?b.chartX-this.pos:this.len-b.chartY+this.pos);if(k(h)){var p={value:d&&(this.isXAxis?d.x:F(d.stackY,d.y)),translatedValue:h};e.polar&&O(p,{isCrosshair:!0,chartX:b&&b.chartX,chartY:b&&b.chartY,point:d});p=this.getPlotLinePath(p)||
null}if(!k(p)){this.hideCrosshair();return}c=this.categories&&!this.isRadial;f||(this.cross=f=e.renderer.path().addClass("highcharts-crosshair highcharts-crosshair-"+(c?"category ":"thin ")+(a.className||"")).attr({zIndex:F(a.zIndex,2)}).add(),e.styledMode||(f.attr({stroke:a.color||(c?C.parse(E.highlightColor20).setOpacity(.25).get():E.neutralColor20),"stroke-width":F(a.width,1)}).css({"pointer-events":"none"}),a.dashStyle&&f.attr({dashstyle:a.dashStyle})));f.show().attr({d:p});c&&!a.width&&f.attr({"stroke-width":this.transA});
this.cross.e=b}else this.hideCrosshair();t(this,"afterDrawCrosshair",{e:b,point:d})};a.prototype.hideCrosshair=function(){this.cross&&this.cross.hide();t(this,"afterHideCrosshair")};a.prototype.hasVerticalPanning=function(){var b=this.chart.options.chart.panning;return!!(b&&b.enabled&&/y/.test(b.type))};a.prototype.validatePositiveValue=function(d){return b(d)&&0<d};a.prototype.update=function(b,d){var a=this.chart;b=G(this.userOptions,b);this.destroy(!0);this.init(a,b);a.isDirtyBox=!0;F(d,!0)&&a.redraw()};
a.prototype.remove=function(b){for(var d=this.chart,a=this.coll,c=this.series,e=c.length;e--;)c[e]&&c[e].remove(!1);D(d.axes,this);D(d[a],this);d[a].forEach(function(b,d){b.options.index=b.userOptions.index=d});this.destroy();d.isDirtyBox=!0;F(b,!0)&&d.redraw()};a.prototype.setTitle=function(b,d){this.update({title:b},d)};a.prototype.setCategories=function(b,d){this.update({categories:b},d)};a.defaultOptions=w.defaultXAxisOptions;a.keepProps="extKey hcEvents names series userMax userMin".split(" ");
return a}();"";return a});M(a,"Core/Axis/DateTimeAxis.js",[a["Core/Utilities.js"]],function(a){var r=a.addEvent,C=a.getMagnitude,E=a.normalizeTickInterval,z=a.timeUnits,x;(function(a){function u(){return this.chart.time.getTimeTicks.apply(this.chart.time,arguments)}function n(a){"datetime"!==a.userOptions.type?this.dateTime=void 0:this.dateTime||(this.dateTime=new g(this))}var m=[];a.compose=function(a){-1===m.indexOf(a)&&(m.push(a),a.keepProps.push("dateTime"),a.prototype.getTimeTicks=u,r(a,"init",
n));return a};var g=function(){function a(a){this.axis=a}a.prototype.normalizeTimeTickInterval=function(a,c){var e=c||[["millisecond",[1,2,5,10,20,25,50,100,200,500]],["second",[1,2,5,10,15,30]],["minute",[1,2,5,10,15,30]],["hour",[1,2,3,4,6,8,12]],["day",[1,2]],["week",[1,2]],["month",[1,2,3,4,6]],["year",null]];c=e[e.length-1];var g=z[c[0]],l=c[1],k;for(k=0;k<e.length&&!(c=e[k],g=z[c[0]],l=c[1],e[k+1]&&a<=(g*l[l.length-1]+z[e[k+1][0]])/2);k++);g===z.year&&a<5*g&&(l=[1,2,5]);a=E(a/g,l,"year"===c[0]?
Math.max(C(a/g),1):1);return{unitRange:g,count:a,unitName:c[0]}};a.prototype.getXDateFormat=function(a,c){var e=this.axis;return e.closestPointRange?e.chart.time.getDateFormat(e.closestPointRange,a,e.options.startOfWeek,c)||c.year:c.day};return a}();a.Additions=g})(x||(x={}));return x});M(a,"Core/Axis/LogarithmicAxis.js",[a["Core/Utilities.js"]],function(a){var r=a.addEvent,C=a.getMagnitude,E=a.normalizeTickInterval,z=a.pick,x;(function(a){function u(a){var c=this.logarithmic;"logarithmic"!==a.userOptions.type?
this.logarithmic=void 0:c||(this.logarithmic=new g(this))}function n(){var a=this.logarithmic;a&&(this.lin2val=function(c){return a.lin2log(c)},this.val2lin=function(c){return a.log2lin(c)})}var m=[];a.compose=function(a){-1===m.indexOf(a)&&(m.push(a),a.keepProps.push("logarithmic"),r(a,"init",u),r(a,"afterInit",n));return a};var g=function(){function a(a){this.axis=a}a.prototype.getLogTickPositions=function(a,c,f,g){var e=this.axis,k=e.len,l=e.options,m=[];g||(this.minorAutoInterval=void 0);if(.5<=
a)a=Math.round(a),m=e.getLinearTickPositions(a,c,f);else if(.08<=a){var n=Math.floor(c),v,t=l=void 0;for(k=.3<a?[1,2,4]:.15<a?[1,2,4,6,8]:[1,2,3,4,5,6,7,8,9];n<f+1&&!t;n++){var h=k.length;for(v=0;v<h&&!t;v++){var d=this.log2lin(this.lin2log(n)*k[v]);d>c&&(!g||l<=f)&&"undefined"!==typeof l&&m.push(l);l>f&&(t=!0);l=d}}}else c=this.lin2log(c),f=this.lin2log(f),a=g?e.getMinorTickInterval():l.tickInterval,a=z("auto"===a?null:a,this.minorAutoInterval,l.tickPixelInterval/(g?5:1)*(f-c)/((g?k/e.tickPositions.length:
k)||1)),a=E(a,void 0,C(a)),m=e.getLinearTickPositions(a,c,f).map(this.log2lin),g||(this.minorAutoInterval=a/5);g||(e.tickInterval=a);return m};a.prototype.lin2log=function(a){return Math.pow(10,a)};a.prototype.log2lin=function(a){return Math.log(a)/Math.LN10};return a}();a.Additions=g})(x||(x={}));return x});M(a,"Core/Axis/PlotLineOrBand/PlotLineOrBandAxis.js",[a["Core/Utilities.js"]],function(a){var r=a.erase,C=a.extend,E=a.isNumber,z;(function(a){var x=[],u;a.compose=function(a,g){u||(u=a);-1===
x.indexOf(g)&&(x.push(g),C(g.prototype,n.prototype));return g};var n=function(){function a(){}a.prototype.getPlotBandPath=function(a,c,e){void 0===e&&(e=this.options);var g=this.getPlotLinePath({value:c,force:!0,acrossPanes:e.acrossPanes}),f=[],m=this.horiz;c=!E(this.min)||!E(this.max)||a<this.min&&c<this.min||a>this.max&&c>this.max;a=this.getPlotLinePath({value:a,force:!0,acrossPanes:e.acrossPanes});e=1;if(a&&g){if(c){var q=a.toString()===g.toString();e=0}for(c=0;c<a.length;c+=2){var k=a[c],n=a[c+
1],r=g[c],B=g[c+1];"M"!==k[0]&&"L"!==k[0]||"M"!==n[0]&&"L"!==n[0]||"M"!==r[0]&&"L"!==r[0]||"M"!==B[0]&&"L"!==B[0]||(m&&r[1]===k[1]?(r[1]+=e,B[1]+=e):m||r[2]!==k[2]||(r[2]+=e,B[2]+=e),f.push(["M",k[1],k[2]],["L",n[1],n[2]],["L",B[1],B[2]],["L",r[1],r[2]],["Z"]));f.isFlat=q}}return f};a.prototype.addPlotBand=function(a){return this.addPlotBandOrLine(a,"plotBands")};a.prototype.addPlotLine=function(a){return this.addPlotBandOrLine(a,"plotLines")};a.prototype.addPlotBandOrLine=function(a,c){var e=this,
g=this.userOptions,f=new u(this,a);this.visible&&(f=f.render());if(f){this._addedPlotLB||(this._addedPlotLB=!0,(g.plotLines||[]).concat(g.plotBands||[]).forEach(function(a){e.addPlotBandOrLine(a)}));if(c){var m=g[c]||[];m.push(a);g[c]=m}this.plotLinesAndBands.push(f)}return f};a.prototype.removePlotBandOrLine=function(a){var c=this.plotLinesAndBands,e=this.options,g=this.userOptions;if(c){for(var f=c.length;f--;)c[f].id===a&&c[f].destroy();[e.plotLines||[],g.plotLines||[],e.plotBands||[],g.plotBands||
[]].forEach(function(c){for(f=c.length;f--;)(c[f]||{}).id===a&&r(c,c[f])})}};a.prototype.removePlotBand=function(a){this.removePlotBandOrLine(a)};a.prototype.removePlotLine=function(a){this.removePlotBandOrLine(a)};return a}()})(z||(z={}));return z});M(a,"Core/Axis/PlotLineOrBand/PlotLineOrBand.js",[a["Core/Color/Palette.js"],a["Core/Axis/PlotLineOrBand/PlotLineOrBandAxis.js"],a["Core/Utilities.js"]],function(a,w,C){var r=C.arrayMax,z=C.arrayMin,x=C.defined,J=C.destroyObjectProperties,u=C.erase,n=
C.fireEvent,m=C.merge,g=C.objectEach,c=C.pick;C=function(){function e(a,c){this.axis=a;c&&(this.options=c,this.id=c.id)}e.compose=function(a){return w.compose(e,a)};e.prototype.render=function(){n(this,"render");var e=this,f=e.axis,v=f.horiz,q=f.logarithmic,k=e.options,r=k.color,D=c(k.zIndex,0),B=k.events,u={},t=f.chart.renderer,h=k.label,d=e.label,b=k.to,p=k.from,G=k.value,y=e.svgElem,L=[],F=x(p)&&x(b);L=x(G);var P=!y,S={"class":"highcharts-plot-"+(F?"band ":"line ")+(k.className||"")},Q=F?"bands":
"lines";q&&(p=q.log2lin(p),b=q.log2lin(b),G=q.log2lin(G));f.chart.styledMode||(L?(S.stroke=r||a.neutralColor40,S["stroke-width"]=c(k.width,1),k.dashStyle&&(S.dashstyle=k.dashStyle)):F&&(S.fill=r||a.highlightColor10,k.borderWidth&&(S.stroke=k.borderColor,S["stroke-width"]=k.borderWidth)));u.zIndex=D;Q+="-"+D;(q=f.plotLinesAndBandsGroups[Q])||(f.plotLinesAndBandsGroups[Q]=q=t.g("plot-"+Q).attr(u).add());P&&(e.svgElem=y=t.path().attr(S).add(q));if(L)L=f.getPlotLinePath({value:G,lineWidth:y.strokeWidth(),
acrossPanes:k.acrossPanes});else if(F)L=f.getPlotBandPath(p,b,k);else return;!e.eventsAdded&&B&&(g(B,function(b,d){y.on(d,function(b){B[d].apply(e,[b])})}),e.eventsAdded=!0);(P||!y.d)&&L&&L.length?y.attr({d:L}):y&&(L?(y.show(!0),y.animate({d:L})):y.d&&(y.hide(),d&&(e.label=d=d.destroy())));h&&(x(h.text)||x(h.formatter))&&L&&L.length&&0<f.width&&0<f.height&&!L.isFlat?(h=m({align:v&&F&&"center",x:v?!F&&4:10,verticalAlign:!v&&F&&"middle",y:v?F?16:10:F?6:-4,rotation:v&&!F&&90},h),this.renderLabel(h,L,
F,D)):d&&d.hide();return e};e.prototype.renderLabel=function(a,c,e,g){var f=this.axis,l=f.chart.renderer,q=this.label;q||(this.label=q=l.text(this.getLabelText(a),0,0,a.useHTML).attr({align:a.textAlign||a.align,rotation:a.rotation,"class":"highcharts-plot-"+(e?"band":"line")+"-label "+(a.className||""),zIndex:g}).add(),f.chart.styledMode||q.css(m({textOverflow:"ellipsis"},a.style)));g=c.xBounds||[c[0][1],c[1][1],e?c[2][1]:c[0][1]];c=c.yBounds||[c[0][2],c[1][2],e?c[2][2]:c[0][2]];e=z(g);l=z(c);q.align(a,
!1,{x:e,y:l,width:r(g)-e,height:r(c)-l});q.alignValue&&"left"!==q.alignValue||q.css({width:(90===q.rotation?f.height-(q.alignAttr.y-f.top):f.width-(q.alignAttr.x-f.left))+"px"});q.show(!0)};e.prototype.getLabelText=function(a){return x(a.formatter)?a.formatter.call(this):a.text};e.prototype.destroy=function(){u(this.axis.plotLinesAndBands,this);delete this.axis;J(this)};return e}();"";"";return C});M(a,"Core/Tooltip.js",[a["Core/FormatUtilities.js"],a["Core/Globals.js"],a["Core/Color/Palette.js"],
a["Core/Renderer/RendererUtilities.js"],a["Core/Renderer/RendererRegistry.js"],a["Core/Utilities.js"]],function(a,w,C,E,z,x){var r=a.format,u=w.doc,n=E.distribute,m=x.addEvent,g=x.clamp,c=x.css,e=x.defined,l=x.discardElement,f=x.extend,v=x.fireEvent,q=x.isArray,k=x.isNumber,I=x.isString,D=x.merge,B=x.pick,O=x.splat,t=x.syncTimeout;a=function(){function a(a,b){this.container=void 0;this.crosshairs=[];this.distance=0;this.isHidden=!0;this.isSticky=!1;this.now={};this.options={};this.outside=!1;this.chart=
a;this.init(a,b)}a.prototype.applyFilter=function(){var a=this.chart;a.renderer.definition({tagName:"filter",attributes:{id:"drop-shadow-"+a.index,opacity:.5},children:[{tagName:"feGaussianBlur",attributes:{"in":"SourceAlpha",stdDeviation:1}},{tagName:"feOffset",attributes:{dx:1,dy:1}},{tagName:"feComponentTransfer",children:[{tagName:"feFuncA",attributes:{type:"linear",slope:.3}}]},{tagName:"feMerge",children:[{tagName:"feMergeNode"},{tagName:"feMergeNode",attributes:{"in":"SourceGraphic"}}]}]})};
a.prototype.bodyFormatter=function(a){return a.map(function(b){var a=b.series.tooltipOptions;return(a[(b.point.formatPrefix||"point")+"Formatter"]||b.point.tooltipFormatter).call(b.point,a[(b.point.formatPrefix||"point")+"Format"]||"")})};a.prototype.cleanSplit=function(a){this.chart.series.forEach(function(b){var d=b&&b.tt;d&&(!d.isActive||a?b.tt=d.destroy():d.isActive=!1)})};a.prototype.defaultFormatter=function(a){var b=this.points||O(this);var d=[a.tooltipFooterHeaderFormatter(b[0])];d=d.concat(a.bodyFormatter(b));
d.push(a.tooltipFooterHeaderFormatter(b[0],!0));return d};a.prototype.destroy=function(){this.label&&(this.label=this.label.destroy());this.split&&this.tt&&(this.cleanSplit(this.chart,!0),this.tt=this.tt.destroy());this.renderer&&(this.renderer=this.renderer.destroy(),l(this.container));x.clearTimeout(this.hideTimer);x.clearTimeout(this.tooltipTimeout)};a.prototype.getAnchor=function(a,b){var d=this.chart,c=d.pointer,e=d.inverted,h=d.plotTop,f=d.plotLeft,g,k,t=0,l=0;a=O(a);this.followPointer&&b?("undefined"===
typeof b.chartX&&(b=c.normalize(b)),c=[b.chartX-f,b.chartY-h]):a[0].tooltipPos?c=a[0].tooltipPos:(a.forEach(function(b){g=b.series.yAxis;k=b.series.xAxis;t+=b.plotX||0;l+=b.plotLow?(b.plotLow+(b.plotHigh||0))/2:b.plotY||0;k&&g&&(e?(t+=h+d.plotHeight-k.len-k.pos,l+=f+d.plotWidth-g.len-g.pos):(t+=k.pos-f,l+=g.pos-h))}),t/=a.length,l/=a.length,c=[e?d.plotWidth-l:t,e?d.plotHeight-t:l],this.shared&&1<a.length&&b&&(e?c[0]=b.chartX-f:c[1]=b.chartY-h));return c.map(Math.round)};a.prototype.getLabel=function(){var a=
this,b=this.chart.styledMode,h=this.options,f="tooltip"+(e(h.className)?" "+h.className:""),g=h.style.pointerEvents||(!this.followPointer&&h.stickOnContact?"auto":"none"),k=function(){a.inContact=!0},t=function(b){var d=a.chart.hoverSeries;a.inContact=a.shouldStickOnContact()&&a.chart.pointer.inClass(b.relatedTarget,"highcharts-tooltip");if(!a.inContact&&d&&d.onMouseOut)d.onMouseOut()},l,q=this.chart.renderer;if(!this.label){if(this.outside){var n=this.chart.options.chart.style,v=z.getRendererType();
this.container=l=w.doc.createElement("div");l.className="highcharts-tooltip-container";c(l,{position:"absolute",top:"1px",pointerEvents:g,zIndex:Math.max(this.options.style.zIndex||0,(n&&n.zIndex||0)+3)});m(l,"mouseenter",k);m(l,"mouseleave",t);w.doc.body.appendChild(l);this.renderer=q=new v(l,0,0,n,void 0,void 0,q.styledMode)}this.split?this.label=q.g(f):(this.label=q.label("",0,0,h.shape,void 0,void 0,h.useHTML,void 0,f).attr({padding:h.padding,r:h.borderRadius}),b||this.label.attr({fill:h.backgroundColor,
"stroke-width":h.borderWidth}).css(h.style).css({pointerEvents:g}).shadow(h.shadow));b&&h.shadow&&(this.applyFilter(),this.label.attr({filter:"url(#drop-shadow-"+this.chart.index+")"}));if(a.outside&&!a.split){var r=this.label,B=r.xSetter,D=r.ySetter;r.xSetter=function(b){B.call(r,a.distance);l.style.left=b+"px"};r.ySetter=function(b){D.call(r,a.distance);l.style.top=b+"px"}}this.label.on("mouseenter",k).on("mouseleave",t).attr({zIndex:8}).add()}return this.label};a.prototype.getPosition=function(a,
b,c){var d=this.chart,e=this.distance,h={},f=d.inverted&&c.h||0,g=this.outside,p=g?u.documentElement.clientWidth-2*e:d.chartWidth,k=g?Math.max(u.body.scrollHeight,u.documentElement.scrollHeight,u.body.offsetHeight,u.documentElement.offsetHeight,u.documentElement.clientHeight):d.chartHeight,l=d.pointer.getChartPosition(),t=function(h){var f="x"===h;return[h,f?p:k,f?a:b].concat(g?[f?a*l.scaleX:b*l.scaleY,f?l.left-e+(c.plotX+d.plotLeft)*l.scaleX:l.top-e+(c.plotY+d.plotTop)*l.scaleY,0,f?p:k]:[f?a:b,f?
c.plotX+d.plotLeft:c.plotY+d.plotTop,f?d.plotLeft:d.plotTop,f?d.plotLeft+d.plotWidth:d.plotTop+d.plotHeight])},m=t("y"),q=t("x"),n,v=!this.followPointer&&B(c.ttBelow,!d.inverted===!!c.negative),r=function(b,a,d,c,p,k,y){var t=g?"y"===b?e*l.scaleY:e*l.scaleX:e,G=(d-c)/2,A=c<p-e,m=p+e+c<a,F=p-t-d+G;p=p+t-G;if(v&&m)h[b]=p;else if(!v&&A)h[b]=F;else if(A)h[b]=Math.min(y-c,0>F-f?F:F-f);else if(m)h[b]=Math.max(k,p+f+d>a?p:p+f);else return!1},D=function(b,a,d,c,f){var g;f<e||f>a-e?g=!1:h[b]=f<d/2?1:f>a-c/
2?a-c-2:f-d/2;return g},A=function(b){var a=m;m=q;q=a;n=b},U=function(){!1!==r.apply(0,m)?!1!==D.apply(0,q)||n||(A(!0),U()):n?h.x=h.y=0:(A(!0),U())};(d.inverted||1<this.len)&&A();U();return h};a.prototype.hide=function(a){var b=this;x.clearTimeout(this.hideTimer);a=B(a,this.options.hideDelay);this.isHidden||(this.hideTimer=t(function(){b.getLabel().fadeOut(a?void 0:a);b.isHidden=!0},a))};a.prototype.init=function(a,b){this.chart=a;this.options=b;this.crosshairs=[];this.now={x:0,y:0};this.isHidden=
!0;this.split=b.split&&!a.inverted&&!a.polar;this.shared=b.shared||this.split;this.outside=B(b.outside,!(!a.scrollablePixelsX&&!a.scrollablePixelsY))};a.prototype.shouldStickOnContact=function(){return!(this.followPointer||!this.options.stickOnContact)};a.prototype.isStickyOnContact=function(){return!(!this.shouldStickOnContact()||!this.inContact)};a.prototype.move=function(a,b,c,e){var d=this,h=d.now,g=!1!==d.options.animation&&!d.isHidden&&(1<Math.abs(a-h.x)||1<Math.abs(b-h.y)),p=d.followPointer||
1<d.len;f(h,{x:g?(2*h.x+a)/3:a,y:g?(h.y+b)/2:b,anchorX:p?void 0:g?(2*h.anchorX+c)/3:c,anchorY:p?void 0:g?(h.anchorY+e)/2:e});d.getLabel().attr(h);d.drawTracker();g&&(x.clearTimeout(this.tooltipTimeout),this.tooltipTimeout=setTimeout(function(){d&&d.move(a,b,c,e)},32))};a.prototype.refresh=function(a,b){var d=this.chart,c=this.options,e=O(a),h=e[0],f=[],g=c.formatter||this.defaultFormatter,k=this.shared,l=d.styledMode,t={};if(c.enabled){x.clearTimeout(this.hideTimer);this.followPointer=!this.split&&
h.series.tooltipOptions.followPointer;var m=this.getAnchor(a,b),n=m[0],r=m[1];!k||!q(a)&&a.series&&a.series.noSharedTooltip?t=h.getLabelConfig():(d.pointer.applyInactiveState(e),e.forEach(function(b){b.setState("hover");f.push(b.getLabelConfig())}),t={x:h.category,y:h.y},t.points=f);this.len=f.length;a=g.call(t,this);g=h.series;this.distance=B(g.tooltipOptions.distance,16);if(!1===a)this.hide();else{if(this.split)this.renderSplit(a,e);else if(e=n,k=r,b&&d.pointer.isDirectTouch&&(e=b.chartX-d.plotLeft,
k=b.chartY-d.plotTop),d.polar||!1===g.options.clip||g.shouldShowTooltip(e,k))b=this.getLabel(),c.style.width&&!l||b.css({width:this.chart.spacingBox.width+"px"}),b.attr({text:a&&a.join?a.join(""):a}),b.removeClass(/highcharts-color-[\d]+/g).addClass("highcharts-color-"+B(h.colorIndex,g.colorIndex)),l||b.attr({stroke:c.borderColor||h.color||g.color||C.neutralColor60}),this.updatePosition({plotX:n,plotY:r,negative:h.negative,ttBelow:h.ttBelow,h:m[2]||0});else{this.hide();return}this.isHidden&&this.label&&
this.label.attr({opacity:1}).show();this.isHidden=!1}v(this,"refresh")}};a.prototype.renderSplit=function(a,b){function d(b,a,d,e,h){void 0===h&&(h=!0);d?(a=Y?0:J,b=g(b-e/2,N.left,N.right-e-(c.outside?T:0))):(a-=da,b=h?b-e-z:b+z,b=g(b,h?b:N.left,N.right));return{x:b,y:a}}var c=this,e=c.chart,h=c.chart,k=h.chartWidth,l=h.chartHeight,t=h.plotHeight,m=h.plotLeft,q=h.plotTop,r=h.pointer,v=h.scrollablePixelsY;v=void 0===v?0:v;var D=h.scrollablePixelsX,x=h.scrollingContainer;x=void 0===x?{scrollLeft:0,
scrollTop:0}:x;var w=x.scrollLeft;x=x.scrollTop;var O=h.styledMode,z=c.distance,A=c.options,U=c.options.positioner,N=c.outside&&"number"!==typeof D?u.documentElement.getBoundingClientRect():{left:w,right:w+k,top:x,bottom:x+l},W=c.getLabel(),X=this.renderer||e.renderer,Y=!(!e.xAxis[0]||!e.xAxis[0].opposite);e=r.getChartPosition();var T=e.left;e=e.top;var da=q+x,E=0,J=t-v;I(a)&&(a=[!1,a]);a=a.slice(0,b.length+1).reduce(function(a,e,h){if(!1!==e&&""!==e){h=b[h-1]||{isHeader:!0,plotX:b[0].plotX,plotY:t,
series:{}};var f=h.isHeader,p=f?c:h.series;e=e.toString();var k=p.tt,l=h.isHeader;var y=h.series;var G="highcharts-color-"+B(h.colorIndex,y.colorIndex,"none");k||(k={padding:A.padding,r:A.borderRadius},O||(k.fill=A.backgroundColor,k["stroke-width"]=A.borderWidth),k=X.label("",0,0,A[l?"headerShape":"shape"],void 0,void 0,A.useHTML).addClass((l?"highcharts-tooltip-header ":"")+"highcharts-tooltip-box "+G).attr(k).add(W));k.isActive=!0;k.attr({text:e});O||k.css(A.style).shadow(A.shadow).attr({stroke:A.borderColor||
h.color||y.color||C.neutralColor80});p=p.tt=k;l=p.getBBox();e=l.width+p.strokeWidth();f&&(E=l.height,J+=E,Y&&(da-=E));y=h.plotX;y=void 0===y?0:y;G=h.plotY;G=void 0===G?0:G;k=h.series;if(h.isHeader){y=m+y;var F=q+t/2}else{var n=k.xAxis,ca=k.yAxis;y=n.pos+g(y,-z,n.len+z);k.shouldShowTooltip(0,ca.pos-q+G,{ignoreX:!0})&&(F=ca.pos+G)}y=g(y,N.left-z,N.right+z);"number"===typeof F?(l=l.height+1,G=U?U.call(c,e,l,h):d(y,F,f,e),a.push({align:U?0:void 0,anchorX:y,anchorY:F,boxWidth:e,point:h,rank:B(G.rank,f?
1:0),size:l,target:G.y,tt:p,x:G.x})):p.isActive=!1}return a},[]);!U&&a.some(function(b){var a=(c.outside?T:0)+b.anchorX;return a<N.left&&a+b.boxWidth<N.right?!0:a<T-N.left+b.boxWidth&&N.right-a>a})&&(a=a.map(function(b){var a=d(b.anchorX,b.anchorY,b.point.isHeader,b.boxWidth,!1);return f(b,{target:a.y,x:a.x})}));c.cleanSplit();n(a,J);var ba=T,ea=T;a.forEach(function(b){var a=b.x,d=b.boxWidth;b=b.isHeader;b||(c.outside&&T+a<ba&&(ba=T+a),!b&&c.outside&&ba+d>ea&&(ea=T+a))});a.forEach(function(b){var a=
b.x,d=b.anchorX,e=b.pos,h=b.point.isHeader;e={visibility:"undefined"===typeof e?"hidden":"inherit",x:a,y:e+da,anchorX:d,anchorY:b.anchorY};if(c.outside&&a<d){var f=T-ba;0<f&&(h||(e.x=a+f,e.anchorX=d+f),h&&(e.x=(ea-ba)/2,e.anchorX=d+f))}b.tt.attr(e)});a=c.container;v=c.renderer;c.outside&&a&&v&&(h=W.getBBox(),v.setSize(h.width+h.x,h.height+h.y,!1),a.style.left=ba+"px",a.style.top=e+"px")};a.prototype.drawTracker=function(){if(this.followPointer||!this.options.stickOnContact)this.tracker&&this.tracker.destroy();
else{var a=this.chart,b=this.label,c=this.shared?a.hoverPoints:a.hoverPoint;if(b&&c){var e={x:0,y:0,width:0,height:0};c=this.getAnchor(c);var h=b.getBBox();c[0]+=a.plotLeft-b.translateX;c[1]+=a.plotTop-b.translateY;e.x=Math.min(0,c[0]);e.y=Math.min(0,c[1]);e.width=0>c[0]?Math.max(Math.abs(c[0]),h.width-c[0]):Math.max(Math.abs(c[0]),h.width);e.height=0>c[1]?Math.max(Math.abs(c[1]),h.height-Math.abs(c[1])):Math.max(Math.abs(c[1]),h.height);this.tracker?this.tracker.attr(e):(this.tracker=b.renderer.rect(e).addClass("highcharts-tracker").add(b),
a.styledMode||this.tracker.attr({fill:"rgba(0,0,0,0)"}))}}};a.prototype.styledModeFormat=function(a){return a.replace('style="font-size: 10px"','class="highcharts-header"').replace(/style="color:{(point|series)\.color}"/g,'class="highcharts-color-{$1.colorIndex}"')};a.prototype.tooltipFooterHeaderFormatter=function(a,b){var d=a.series,c=d.tooltipOptions,e=d.xAxis,h=e&&e.dateTime;e={isFooter:b,labelConfig:a};var f=c.xDateFormat,g=c[b?"footerFormat":"headerFormat"];v(this,"headerFormatter",e,function(b){h&&
!f&&k(a.key)&&(f=h.getXDateFormat(a.key,c.dateTimeLabelFormats));h&&f&&(a.point&&a.point.tooltipDateKeys||["key"]).forEach(function(b){g=g.replace("{point."+b+"}","{point."+b+":"+f+"}")});d.chart.styledMode&&(g=this.styledModeFormat(g));b.text=r(g,{point:a,series:d},this.chart)});return e.text};a.prototype.update=function(a){this.destroy();D(!0,this.chart.options.tooltip.userOptions,a);this.init(this.chart,D(!0,this.options,a))};a.prototype.updatePosition=function(a){var b=this.chart,d=this.options,
e=b.pointer,h=this.getLabel();e=e.getChartPosition();var f=(d.positioner||this.getPosition).call(this,h.width,h.height,a),g=a.plotX+b.plotLeft;a=a.plotY+b.plotTop;if(this.outside){d=d.borderWidth+2*this.distance;this.renderer.setSize(h.width+d,h.height+d,!1);if(1!==e.scaleX||1!==e.scaleY)c(this.container,{transform:"scale("+e.scaleX+", "+e.scaleY+")"}),g*=e.scaleX,a*=e.scaleY;g+=e.left-f.x;a+=e.top-f.y}this.move(Math.round(f.x),Math.round(f.y||0),g,a)};return a}();"";return a});M(a,"Core/Series/Point.js",
[a["Core/Renderer/HTML/AST.js"],a["Core/Animation/AnimationUtilities.js"],a["Core/DefaultOptions.js"],a["Core/FormatUtilities.js"],a["Core/Utilities.js"]],function(a,w,C,E,z){var r=w.animObject,J=C.defaultOptions,u=E.format,n=z.addEvent,m=z.defined,g=z.erase,c=z.extend,e=z.fireEvent,l=z.getNestedProperty,f=z.isArray,v=z.isFunction,q=z.isNumber,k=z.isObject,I=z.merge,D=z.objectEach,B=z.pick,O=z.syncTimeout,t=z.removeEvent,h=z.uniqueKey;w=function(){function d(){this.colorIndex=this.category=void 0;
this.formatPrefix="point";this.id=void 0;this.isNull=!1;this.percentage=this.options=this.name=void 0;this.selected=!1;this.total=this.series=void 0;this.visible=!0;this.x=void 0}d.prototype.animateBeforeDestroy=function(){var b=this,a={x:b.startXPos,opacity:0},d=b.getGraphicalProps();d.singular.forEach(function(d){b[d]=b[d].animate("dataLabel"===d?{x:b[d].startXPos,y:b[d].startYPos,opacity:0}:a)});d.plural.forEach(function(a){b[a].forEach(function(a){a.element&&a.animate(c({x:b.startXPos},a.startYPos?
{x:a.startXPos,y:a.startYPos}:{}))})})};d.prototype.applyOptions=function(b,a){var e=this.series,h=e.options.pointValKey||e.pointValKey;b=d.prototype.optionsToObject.call(this,b);c(this,b);this.options=this.options?c(this.options,b):b;b.group&&delete this.group;b.dataLabels&&delete this.dataLabels;h&&(this.y=d.prototype.getNestedProperty.call(this,h));this.formatPrefix=(this.isNull=B(this.isValid&&!this.isValid(),null===this.x||!q(this.y)))?"null":"point";this.selected&&(this.state="select");"name"in
this&&"undefined"===typeof a&&e.xAxis&&e.xAxis.hasNames&&(this.x=e.xAxis.nameToX(this));"undefined"===typeof this.x&&e?this.x="undefined"===typeof a?e.autoIncrement():a:q(b.x)&&e.options.relativeXValue&&(this.x=e.autoIncrement(b.x));return this};d.prototype.destroy=function(){function b(){if(a.graphic||a.dataLabel||a.dataLabels)t(a),a.destroyElements();for(f in a)a[f]=null}var a=this,d=a.series,c=d.chart;d=d.options.dataSorting;var e=c.hoverPoints,h=r(a.series.chart.renderer.globalAnimation),f;a.legendItem&&
c.legend.destroyItem(a);e&&(a.setState(),g(e,a),e.length||(c.hoverPoints=null));if(a===c.hoverPoint)a.onMouseOut();d&&d.enabled?(this.animateBeforeDestroy(),O(b,h.duration)):b();c.pointCount--};d.prototype.destroyElements=function(b){var a=this;b=a.getGraphicalProps(b);b.singular.forEach(function(b){a[b]=a[b].destroy()});b.plural.forEach(function(b){a[b].forEach(function(b){b.element&&b.destroy()});delete a[b]})};d.prototype.firePointEvent=function(b,a,d){var c=this,h=this.series.options;(h.point.events[b]||
c.options&&c.options.events&&c.options.events[b])&&c.importEvents();"click"===b&&h.allowPointSelect&&(d=function(b){c.select&&c.select(null,b.ctrlKey||b.metaKey||b.shiftKey)});e(c,b,a,d)};d.prototype.getClassName=function(){return"highcharts-point"+(this.selected?" highcharts-point-select":"")+(this.negative?" highcharts-negative":"")+(this.isNull?" highcharts-null-point":"")+("undefined"!==typeof this.colorIndex?" highcharts-color-"+this.colorIndex:"")+(this.options.className?" "+this.options.className:
"")+(this.zone&&this.zone.className?" "+this.zone.className.replace("highcharts-negative",""):"")};d.prototype.getGraphicalProps=function(b){var a=this,d=[],c={singular:[],plural:[]},e;b=b||{graphic:1,dataLabel:1};b.graphic&&d.push("graphic","upperGraphic","shadowGroup");b.dataLabel&&d.push("dataLabel","dataLabelUpper","connector");for(e=d.length;e--;){var h=d[e];a[h]&&c.singular.push(h)}["dataLabel","connector"].forEach(function(d){var e=d+"s";b[d]&&a[e]&&c.plural.push(e)});return c};d.prototype.getLabelConfig=
function(){return{x:this.category,y:this.y,color:this.color,colorIndex:this.colorIndex,key:this.name||this.category,series:this.series,point:this,percentage:this.percentage,total:this.total||this.stackTotal}};d.prototype.getNestedProperty=function(b){if(b)return 0===b.indexOf("custom.")?l(b,this.options):this[b]};d.prototype.getZone=function(){var b=this.series,a=b.zones;b=b.zoneAxis||"y";var d,c=0;for(d=a[c];this[b]>=d.value;)d=a[++c];this.nonZonedColor||(this.nonZonedColor=this.color);this.color=
d&&d.color&&!this.options.color?d.color:this.nonZonedColor;return d};d.prototype.hasNewShapeType=function(){return(this.graphic&&(this.graphic.symbolName||this.graphic.element.nodeName))!==this.shapeType};d.prototype.init=function(b,a,d){this.series=b;this.applyOptions(a,d);this.id=m(this.id)?this.id:h();this.resolveColor();b.chart.pointCount++;e(this,"afterInit");return this};d.prototype.optionsToObject=function(b){var a=this.series,c=a.options.keys,e=c||a.pointArrayMap||["y"],h=e.length,g={},k=
0,l=0;if(q(b)||null===b)g[e[0]]=b;else if(f(b))for(!c&&b.length>h&&(a=typeof b[0],"string"===a?g.name=b[0]:"number"===a&&(g.x=b[0]),k++);l<h;)c&&"undefined"===typeof b[k]||(0<e[l].indexOf(".")?d.prototype.setNestedProperty(g,b[k],e[l]):g[e[l]]=b[k]),k++,l++;else"object"===typeof b&&(g=b,b.dataLabels&&(a._hasPointLabels=!0),b.marker&&(a._hasPointMarkers=!0));return g};d.prototype.resolveColor=function(){var b=this.series,a=b.chart.styledMode;var d=b.chart.options.chart.colorCount;delete this.nonZonedColor;
if(b.options.colorByPoint){if(!a){d=b.options.colors||b.chart.options.colors;var c=d[b.colorCounter];d=d.length}a=b.colorCounter;b.colorCounter++;b.colorCounter===d&&(b.colorCounter=0)}else a||(c=b.color),a=b.colorIndex;this.colorIndex=B(this.options.colorIndex,a);this.color=B(this.options.color,c)};d.prototype.setNestedProperty=function(b,a,d){d.split(".").reduce(function(b,d,c,e){b[d]=e.length-1===c?a:k(b[d],!0)?b[d]:{};return b[d]},b);return b};d.prototype.tooltipFormatter=function(b){var a=this.series,
d=a.tooltipOptions,c=B(d.valueDecimals,""),e=d.valuePrefix||"",h=d.valueSuffix||"";a.chart.styledMode&&(b=a.chart.tooltip.styledModeFormat(b));(a.pointArrayMap||["y"]).forEach(function(a){a="{point."+a;if(e||h)b=b.replace(RegExp(a+"}","g"),e+a+"}"+h);b=b.replace(RegExp(a+"}","g"),a+":,."+c+"f}")});return u(b,{point:this,series:this.series},a.chart)};d.prototype.update=function(b,a,d,c){function e(){h.applyOptions(b);var c=g&&h.hasDummyGraphic;c=null===h.y?!c:c;g&&c&&(h.graphic=g.destroy(),delete h.hasDummyGraphic);
k(b,!0)&&(g&&g.element&&b&&b.marker&&"undefined"!==typeof b.marker.symbol&&(h.graphic=g.destroy()),b&&b.dataLabels&&h.dataLabel&&(h.dataLabel=h.dataLabel.destroy()),h.connector&&(h.connector=h.connector.destroy()));t=h.index;f.updateParallelArrays(h,t);l.data[t]=k(l.data[t],!0)||k(b,!0)?h.options:B(b,l.data[t]);f.isDirty=f.isDirtyData=!0;!f.fixedBox&&f.hasCartesianSeries&&(p.isDirtyBox=!0);"point"===l.legendType&&(p.isDirtyLegend=!0);a&&p.redraw(d)}var h=this,f=h.series,g=h.graphic,p=f.chart,l=f.options,
t;a=B(a,!0);!1===c?e():h.firePointEvent("update",{options:b},e)};d.prototype.remove=function(b,a){this.series.removePoint(this.series.data.indexOf(this),b,a)};d.prototype.select=function(b,a){var d=this,c=d.series,e=c.chart;this.selectedStaging=b=B(b,!d.selected);d.firePointEvent(b?"select":"unselect",{accumulate:a},function(){d.selected=d.options.selected=b;c.options.data[c.data.indexOf(d)]=d.options;d.setState(b&&"select");a||e.getSelectedPoints().forEach(function(b){var a=b.series;b.selected&&
b!==d&&(b.selected=b.options.selected=!1,a.options.data[a.data.indexOf(b)]=b.options,b.setState(e.hoverPoints&&a.options.inactiveOtherPoints?"inactive":""),b.firePointEvent("unselect"))})});delete this.selectedStaging};d.prototype.onMouseOver=function(b){var a=this.series.chart,d=a.pointer;b=b?d.normalize(b):d.getChartCoordinatesFromPoint(this,a.inverted);d.runPointActions(b,this)};d.prototype.onMouseOut=function(){var b=this.series.chart;this.firePointEvent("mouseOut");this.series.options.inactiveOtherPoints||
(b.hoverPoints||[]).forEach(function(b){b.setState()});b.hoverPoints=b.hoverPoint=null};d.prototype.importEvents=function(){if(!this.hasImportedEvents){var b=this,a=I(b.series.options.point,b.options).events;b.events=a;D(a,function(a,d){v(a)&&n(b,d,a)});this.hasImportedEvents=!0}};d.prototype.setState=function(b,d){var h=this.series,f=this.state,g=h.options.states[b||"normal"]||{},k=J.plotOptions[h.type].marker&&h.options.marker,p=k&&!1===k.enabled,l=k&&k.states&&k.states[b||"normal"]||{},t=!1===
l.enabled,m=this.marker||{},n=h.chart,v=k&&h.markerAttribs,r=h.halo,D,I=h.stateMarkerGraphic;b=b||"";if(!(b===this.state&&!d||this.selected&&"select"!==b||!1===g.enabled||b&&(t||p&&!1===l.enabled)||b&&m.states&&m.states[b]&&!1===m.states[b].enabled)){this.state=b;v&&(D=h.markerAttribs(this,b));if(this.graphic&&!this.hasDummyGraphic){f&&this.graphic.removeClass("highcharts-point-"+f);b&&this.graphic.addClass("highcharts-point-"+b);if(!n.styledMode){var u=h.pointAttribs(this,b);var x=B(n.options.chart.animation,
g.animation);h.options.inactiveOtherPoints&&q(u.opacity)&&((this.dataLabels||[]).forEach(function(b){b&&b.animate({opacity:u.opacity},x)}),this.connector&&this.connector.animate({opacity:u.opacity},x));this.graphic.animate(u,x)}D&&this.graphic.animate(D,B(n.options.chart.animation,l.animation,k.animation));I&&I.hide()}else{if(b&&l){f=m.symbol||h.symbol;I&&I.currentSymbol!==f&&(I=I.destroy());if(D)if(I)I[d?"animate":"attr"]({x:D.x,y:D.y});else f&&(h.stateMarkerGraphic=I=n.renderer.symbol(f,D.x,D.y,
D.width,D.height).add(h.markerGroup),I.currentSymbol=f);!n.styledMode&&I&&I.attr(h.pointAttribs(this,b))}I&&(I[b&&this.isInside?"show":"hide"](),I.element.point=this,I.addClass(this.getClassName(),!0))}g=g.halo;D=(I=this.graphic||I)&&I.visibility||"inherit";g&&g.size&&I&&"hidden"!==D&&!this.isCluster?(r||(h.halo=r=n.renderer.path().add(I.parentGroup)),r.show()[d?"animate":"attr"]({d:this.haloPath(g.size)}),r.attr({"class":"highcharts-halo highcharts-color-"+B(this.colorIndex,h.colorIndex)+(this.className?
" "+this.className:""),visibility:D,zIndex:-1}),r.point=this,n.styledMode||r.attr(c({fill:this.color||h.color,"fill-opacity":g.opacity},a.filterUserAttributes(g.attributes||{})))):r&&r.point&&r.point.haloPath&&r.animate({d:r.point.haloPath(0)},null,r.hide);e(this,"afterSetState",{state:b})}};d.prototype.haloPath=function(b){return this.series.chart.renderer.symbols.circle(Math.floor(this.plotX)-b,this.plotY-b,2*b,2*b)};return d}();"";return w});M(a,"Core/Pointer.js",[a["Core/Color/Color.js"],a["Core/Globals.js"],
a["Core/Color/Palette.js"],a["Core/Tooltip.js"],a["Core/Utilities.js"]],function(a,w,C,E,z){var r=a.parse,J=w.charts,u=w.noop,n=z.addEvent,m=z.attr,g=z.css,c=z.defined,e=z.extend,l=z.find,f=z.fireEvent,v=z.isNumber,q=z.isObject,k=z.objectEach,I=z.offset,D=z.pick,B=z.splat;a=function(){function a(a,c){this.lastValidTouch={};this.pinchDown=[];this.runChartClick=!1;this.eventsToUnbind=[];this.chart=a;this.hasDragged=!1;this.options=c;this.init(a,c)}a.prototype.applyInactiveState=function(a){var c=[],
d;(a||[]).forEach(function(b){d=b.series;c.push(d);d.linkedParent&&c.push(d.linkedParent);d.linkedSeries&&(c=c.concat(d.linkedSeries));d.navigatorSeries&&c.push(d.navigatorSeries)});this.chart.series.forEach(function(b){-1===c.indexOf(b)?b.setState("inactive",!0):b.options.inactiveOtherPoints&&b.setAllPointsToState("inactive")})};a.prototype.destroy=function(){var c=this;this.eventsToUnbind.forEach(function(a){return a()});this.eventsToUnbind=[];w.chartCount||(a.unbindDocumentMouseUp&&(a.unbindDocumentMouseUp=
a.unbindDocumentMouseUp()),a.unbindDocumentTouchEnd&&(a.unbindDocumentTouchEnd=a.unbindDocumentTouchEnd()));clearInterval(c.tooltipTimeout);k(c,function(a,d){c[d]=void 0})};a.prototype.drag=function(a){var c=this.chart,d=c.options.chart,b=this.zoomHor,e=this.zoomVert,f=c.plotLeft,g=c.plotTop,k=c.plotWidth,l=c.plotHeight,t=this.mouseDownX||0,m=this.mouseDownY||0,n=q(d.panning)?d.panning&&d.panning.enabled:d.panning,v=d.panKey&&a[d.panKey+"Key"],B=a.chartX,D=a.chartY,I=this.selectionMarker;if(!I||!I.touch)if(B<
f?B=f:B>f+k&&(B=f+k),D<g?D=g:D>g+l&&(D=g+l),this.hasDragged=Math.sqrt(Math.pow(t-B,2)+Math.pow(m-D,2)),10<this.hasDragged){var u=c.isInsidePlot(t-f,m-g,{visiblePlotOnly:!0});c.hasCartesianSeries&&(this.zoomX||this.zoomY)&&u&&!v&&!I&&(this.selectionMarker=I=c.renderer.rect(f,g,b?1:k,e?1:l,0).attr({"class":"highcharts-selection-marker",zIndex:7}).add(),c.styledMode||I.attr({fill:d.selectionMarkerFill||r(C.highlightColor80).setOpacity(.25).get()}));I&&b&&(b=B-t,I.attr({width:Math.abs(b),x:(0<b?0:b)+
t}));I&&e&&(b=D-m,I.attr({height:Math.abs(b),y:(0<b?0:b)+m}));u&&!I&&n&&c.pan(a,d.panning)}};a.prototype.dragStart=function(a){var c=this.chart;c.mouseIsDown=a.type;c.cancelClick=!1;c.mouseDownX=this.mouseDownX=a.chartX;c.mouseDownY=this.mouseDownY=a.chartY};a.prototype.drop=function(a){var h=this,d=this.chart,b=this.hasPinched;if(this.selectionMarker){var k={originalEvent:a,xAxis:[],yAxis:[]},l=this.selectionMarker,t=l.attr?l.attr("x"):l.x,m=l.attr?l.attr("y"):l.y,q=l.attr?l.attr("width"):l.width,
n=l.attr?l.attr("height"):l.height,r;if(this.hasDragged||b)d.axes.forEach(function(d){if(d.zoomEnabled&&c(d.min)&&(b||h[{xAxis:"zoomX",yAxis:"zoomY"}[d.coll]])&&v(t)&&v(m)){var e=d.horiz,f="touchend"===a.type?d.minPixelPadding:0,g=d.toValue((e?t:m)+f);e=d.toValue((e?t+q:m+n)-f);k[d.coll].push({axis:d,min:Math.min(g,e),max:Math.max(g,e)});r=!0}}),r&&f(d,"selection",k,function(a){d.zoom(e(a,b?{animation:!1}:null))});v(d.index)&&(this.selectionMarker=this.selectionMarker.destroy());b&&this.scaleGroups()}d&&
v(d.index)&&(g(d.container,{cursor:d._cursor}),d.cancelClick=10<this.hasDragged,d.mouseIsDown=this.hasDragged=this.hasPinched=!1,this.pinchDown=[])};a.prototype.findNearestKDPoint=function(a,c,d){var b=this.chart,e=b.hoverPoint;b=b.tooltip;if(e&&b&&b.isStickyOnContact())return e;var h;a.forEach(function(b){var a=!(b.noSharedTooltip&&c)&&0>b.options.findNearestPointBy.indexOf("y");b=b.searchPoint(d,a);if((a=q(b,!0)&&b.series)&&!(a=!q(h,!0))){a=h.distX-b.distX;var e=h.dist-b.dist,f=(b.series.group&&
b.series.group.zIndex)-(h.series.group&&h.series.group.zIndex);a=0<(0!==a&&c?a:0!==e?e:0!==f?f:h.series.index>b.series.index?-1:1)}a&&(h=b)});return h};a.prototype.getChartCoordinatesFromPoint=function(a,c){var d=a.series,b=d.xAxis;d=d.yAxis;var e=a.shapeArgs;if(b&&d){var h=D(a.clientX,a.plotX),f=a.plotY||0;a.isNode&&e&&v(e.x)&&v(e.y)&&(h=e.x,f=e.y);return c?{chartX:d.len+d.pos-f,chartY:b.len+b.pos-h}:{chartX:h+b.pos,chartY:f+d.pos}}if(e&&e.x&&e.y)return{chartX:e.x,chartY:e.y}};a.prototype.getChartPosition=
function(){if(this.chartPosition)return this.chartPosition;var a=this.chart.container,c=I(a);this.chartPosition={left:c.left,top:c.top,scaleX:1,scaleY:1};var d=a.offsetWidth;a=a.offsetHeight;2<d&&2<a&&(this.chartPosition.scaleX=c.width/d,this.chartPosition.scaleY=c.height/a);return this.chartPosition};a.prototype.getCoordinates=function(a){var c={xAxis:[],yAxis:[]};this.chart.axes.forEach(function(d){c[d.isXAxis?"xAxis":"yAxis"].push({axis:d,value:d.toValue(a[d.horiz?"chartX":"chartY"])})});return c};
a.prototype.getHoverData=function(a,c,d,b,e,g){var h=[];b=!(!b||!a);var k={chartX:g?g.chartX:void 0,chartY:g?g.chartY:void 0,shared:e};f(this,"beforeGetHoverData",k);var p=c&&!c.stickyTracking?[c]:d.filter(function(b){return k.filter?k.filter(b):b.visible&&!(!e&&b.directTouch)&&D(b.options.enableMouseTracking,!0)&&b.stickyTracking});var t=b||!g?a:this.findNearestKDPoint(p,e,g);c=t&&t.series;t&&(e&&!c.noSharedTooltip?(p=d.filter(function(b){return k.filter?k.filter(b):b.visible&&!(!e&&b.directTouch)&&
D(b.options.enableMouseTracking,!0)&&!b.noSharedTooltip}),p.forEach(function(b){var a=l(b.points,function(b){return b.x===t.x&&!b.isNull});q(a)&&(b.chart.isBoosting&&(a=b.getPoint(a)),h.push(a))})):h.push(t));k={hoverPoint:t};f(this,"afterGetHoverData",k);return{hoverPoint:k.hoverPoint,hoverSeries:c,hoverPoints:h}};a.prototype.getPointFromEvent=function(a){a=a.target;for(var c;a&&!c;)c=a.point,a=a.parentNode;return c};a.prototype.onTrackerMouseOut=function(a){a=a.relatedTarget||a.toElement;var c=
this.chart.hoverSeries;this.isDirectTouch=!1;if(!(!c||!a||c.stickyTracking||this.inClass(a,"highcharts-tooltip")||this.inClass(a,"highcharts-series-"+c.index)&&this.inClass(a,"highcharts-tracker")))c.onMouseOut()};a.prototype.inClass=function(a,c){for(var d;a;){if(d=m(a,"class")){if(-1!==d.indexOf(c))return!0;if(-1!==d.indexOf("highcharts-container"))return!1}a=a.parentNode}};a.prototype.init=function(a,c){this.options=c;this.chart=a;this.runChartClick=!(!c.chart.events||!c.chart.events.click);this.pinchDown=
[];this.lastValidTouch={};E&&(a.tooltip=new E(a,c.tooltip),this.followTouchMove=D(c.tooltip.followTouchMove,!0));this.setDOMEvents()};a.prototype.normalize=function(a,c){var d=a.touches,b=d?d.length?d.item(0):D(d.changedTouches,a.changedTouches)[0]:a;c||(c=this.getChartPosition());d=b.pageX-c.left;b=b.pageY-c.top;d/=c.scaleX;b/=c.scaleY;return e(a,{chartX:Math.round(d),chartY:Math.round(b)})};a.prototype.onContainerClick=function(a){var c=this.chart,d=c.hoverPoint;a=this.normalize(a);var b=c.plotLeft,
g=c.plotTop;c.cancelClick||(d&&this.inClass(a.target,"highcharts-tracker")?(f(d.series,"click",e(a,{point:d})),c.hoverPoint&&d.firePointEvent("click",a)):(e(a,this.getCoordinates(a)),c.isInsidePlot(a.chartX-b,a.chartY-g,{visiblePlotOnly:!0})&&f(c,"click",a)))};a.prototype.onContainerMouseDown=function(a){var c=1===((a.buttons||a.button)&1);a=this.normalize(a);if(w.isFirefox&&0!==a.button)this.onContainerMouseMove(a);if("undefined"===typeof a.button||c)this.zoomOption(a),c&&a.preventDefault&&a.preventDefault(),
this.dragStart(a)};a.prototype.onContainerMouseLeave=function(c){var e=J[D(a.hoverChartIndex,-1)],d=this.chart.tooltip;d&&d.shouldStickOnContact()&&this.inClass(c.relatedTarget,"highcharts-tooltip-container")||(c=this.normalize(c),e&&(c.relatedTarget||c.toElement)&&(e.pointer.reset(),e.pointer.chartPosition=void 0),d&&!d.isHidden&&this.reset())};a.prototype.onContainerMouseEnter=function(a){delete this.chartPosition};a.prototype.onContainerMouseMove=function(a){var c=this.chart;a=this.normalize(a);
this.setHoverChartIndex();a.preventDefault||(a.returnValue=!1);("mousedown"===c.mouseIsDown||this.touchSelect(a))&&this.drag(a);c.openMenu||!this.inClass(a.target,"highcharts-tracker")&&!c.isInsidePlot(a.chartX-c.plotLeft,a.chartY-c.plotTop,{visiblePlotOnly:!0})||(this.inClass(a.target,"highcharts-no-tooltip")?this.reset(!1,0):this.runPointActions(a))};a.prototype.onDocumentTouchEnd=function(c){var e=J[D(a.hoverChartIndex,-1)];e&&e.pointer.drop(c)};a.prototype.onContainerTouchMove=function(a){if(this.touchSelect(a))this.onContainerMouseMove(a);
else this.touch(a)};a.prototype.onContainerTouchStart=function(a){if(this.touchSelect(a))this.onContainerMouseDown(a);else this.zoomOption(a),this.touch(a,!0)};a.prototype.onDocumentMouseMove=function(a){var c=this.chart,d=this.chartPosition;a=this.normalize(a,d);var b=c.tooltip;!d||b&&b.isStickyOnContact()||c.isInsidePlot(a.chartX-c.plotLeft,a.chartY-c.plotTop,{visiblePlotOnly:!0})||this.inClass(a.target,"highcharts-tracker")||this.reset()};a.prototype.onDocumentMouseUp=function(c){var e=J[D(a.hoverChartIndex,
-1)];e&&e.pointer.drop(c)};a.prototype.pinch=function(a){var c=this,d=c.chart,b=c.pinchDown,f=a.touches||[],g=f.length,k=c.lastValidTouch,l=c.hasZoom,m={},t=1===g&&(c.inClass(a.target,"highcharts-tracker")&&d.runTrackerClick||c.runChartClick),q={},n=c.selectionMarker;1<g?c.initiated=!0:1===g&&this.followTouchMove&&(c.initiated=!1);l&&c.initiated&&!t&&!1!==a.cancelable&&a.preventDefault();[].map.call(f,function(b){return c.normalize(b)});"touchstart"===a.type?([].forEach.call(f,function(a,d){b[d]=
{chartX:a.chartX,chartY:a.chartY}}),k.x=[b[0].chartX,b[1]&&b[1].chartX],k.y=[b[0].chartY,b[1]&&b[1].chartY],d.axes.forEach(function(b){if(b.zoomEnabled){var a=d.bounds[b.horiz?"h":"v"],c=b.minPixelPadding,e=b.toPixels(Math.min(D(b.options.min,b.dataMin),b.dataMin)),h=b.toPixels(Math.max(D(b.options.max,b.dataMax),b.dataMax)),f=Math.max(e,h);a.min=Math.min(b.pos,Math.min(e,h)-c);a.max=Math.max(b.pos+b.len,f+c)}}),c.res=!0):c.followTouchMove&&1===g?this.runPointActions(c.normalize(a)):b.length&&(n||
(c.selectionMarker=n=e({destroy:u,touch:!0},d.plotBox)),c.pinchTranslate(b,f,m,n,q,k),c.hasPinched=l,c.scaleGroups(m,q),c.res&&(c.res=!1,this.reset(!1,0)))};a.prototype.pinchTranslate=function(a,c,d,b,e,f){this.zoomHor&&this.pinchTranslateDirection(!0,a,c,d,b,e,f);this.zoomVert&&this.pinchTranslateDirection(!1,a,c,d,b,e,f)};a.prototype.pinchTranslateDirection=function(a,c,d,b,e,f,g,k){var h=this.chart,l=a?"x":"y",p=a?"X":"Y",m="chart"+p,y=a?"width":"height",t=h["plot"+(a?"Left":"Top")],q=h.inverted,
n=h.bounds[a?"h":"v"],r=1===c.length,v=c[0][m],B=!r&&c[1][m];c=function(){"number"===typeof I&&20<Math.abs(v-B)&&(D=k||Math.abs(N-I)/Math.abs(v-B));A=(t-N)/D+v;G=h["plot"+(a?"Width":"Height")]/D};var G,A,D=k||1,N=d[0][m],I=!r&&d[1][m];c();d=A;if(d<n.min){d=n.min;var L=!0}else d+G>n.max&&(d=n.max-G,L=!0);L?(N-=.8*(N-g[l][0]),"number"===typeof I&&(I-=.8*(I-g[l][1])),c()):g[l]=[N,I];q||(f[l]=A-t,f[y]=G);f=q?1/D:D;e[y]=G;e[l]=d;b[q?a?"scaleY":"scaleX":"scale"+p]=D;b["translate"+p]=f*t+(N-f*v)};a.prototype.reset=
function(a,c){var d=this.chart,b=d.hoverSeries,e=d.hoverPoint,h=d.hoverPoints,f=d.tooltip,g=f&&f.shared?h:e;a&&g&&B(g).forEach(function(b){b.series.isCartesian&&"undefined"===typeof b.plotX&&(a=!1)});if(a)f&&g&&B(g).length&&(f.refresh(g),f.shared&&h?h.forEach(function(b){b.setState(b.state,!0);b.series.isCartesian&&(b.series.xAxis.crosshair&&b.series.xAxis.drawCrosshair(null,b),b.series.yAxis.crosshair&&b.series.yAxis.drawCrosshair(null,b))}):e&&(e.setState(e.state,!0),d.axes.forEach(function(b){b.crosshair&&
e.series[b.coll]===b&&b.drawCrosshair(null,e)})));else{if(e)e.onMouseOut();h&&h.forEach(function(b){b.setState()});if(b)b.onMouseOut();f&&f.hide(c);this.unDocMouseMove&&(this.unDocMouseMove=this.unDocMouseMove());d.axes.forEach(function(b){b.hideCrosshair()});this.hoverX=d.hoverPoints=d.hoverPoint=null}};a.prototype.runPointActions=function(c,e){var d=this.chart,b=d.tooltip&&d.tooltip.options.enabled?d.tooltip:void 0,h=b?b.shared:!1,f=e||d.hoverPoint,g=f&&f.series||d.hoverSeries;e=this.getHoverData(f,
g,d.series,(!c||"touchmove"!==c.type)&&(!!e||g&&g.directTouch&&this.isDirectTouch),h,c);f=e.hoverPoint;g=e.hoverSeries;var k=e.hoverPoints;e=g&&g.tooltipOptions.followPointer&&!g.tooltipOptions.split;h=h&&g&&!g.noSharedTooltip;if(f&&(f!==d.hoverPoint||b&&b.isHidden)){(d.hoverPoints||[]).forEach(function(b){-1===k.indexOf(b)&&b.setState()});if(d.hoverSeries!==g)g.onMouseOver();this.applyInactiveState(k);(k||[]).forEach(function(b){b.setState("hover")});d.hoverPoint&&d.hoverPoint.firePointEvent("mouseOut");
if(!f.series)return;d.hoverPoints=k;d.hoverPoint=f;f.firePointEvent("mouseOver");b&&b.refresh(h?k:f,c)}else e&&b&&!b.isHidden&&(f=b.getAnchor([{}],c),d.isInsidePlot(f[0],f[1],{visiblePlotOnly:!0})&&b.updatePosition({plotX:f[0],plotY:f[1]}));this.unDocMouseMove||(this.unDocMouseMove=n(d.container.ownerDocument,"mousemove",function(b){var d=J[a.hoverChartIndex];if(d)d.pointer.onDocumentMouseMove(b)}),this.eventsToUnbind.push(this.unDocMouseMove));d.axes.forEach(function(b){var a=D((b.crosshair||{}).snap,
!0),e;a&&((e=d.hoverPoint)&&e.series[b.coll]===b||(e=l(k,function(a){return a.series[b.coll]===b})));e||!a?b.drawCrosshair(c,e):b.hideCrosshair()})};a.prototype.scaleGroups=function(a,c){var d=this.chart;d.series.forEach(function(b){var e=a||b.getPlotBox();b.xAxis&&b.xAxis.zoomEnabled&&b.group&&(b.group.attr(e),b.markerGroup&&(b.markerGroup.attr(e),b.markerGroup.clip(c?d.clipRect:null)),b.dataLabelsGroup&&b.dataLabelsGroup.attr(e))});d.clipRect.attr(c||d.clipBox)};a.prototype.setDOMEvents=function(){var c=
this,e=this.chart.container,d=e.ownerDocument;e.onmousedown=this.onContainerMouseDown.bind(this);e.onmousemove=this.onContainerMouseMove.bind(this);e.onclick=this.onContainerClick.bind(this);this.eventsToUnbind.push(n(e,"mouseenter",this.onContainerMouseEnter.bind(this)));this.eventsToUnbind.push(n(e,"mouseleave",this.onContainerMouseLeave.bind(this)));a.unbindDocumentMouseUp||(a.unbindDocumentMouseUp=n(d,"mouseup",this.onDocumentMouseUp.bind(this)));for(var b=this.chart.renderTo.parentElement;b&&
"BODY"!==b.tagName;)this.eventsToUnbind.push(n(b,"scroll",function(){delete c.chartPosition})),b=b.parentElement;w.hasTouch&&(this.eventsToUnbind.push(n(e,"touchstart",this.onContainerTouchStart.bind(this),{passive:!1})),this.eventsToUnbind.push(n(e,"touchmove",this.onContainerTouchMove.bind(this),{passive:!1})),a.unbindDocumentTouchEnd||(a.unbindDocumentTouchEnd=n(d,"touchend",this.onDocumentTouchEnd.bind(this),{passive:!1})))};a.prototype.setHoverChartIndex=function(){var c=this.chart,e=w.charts[D(a.hoverChartIndex,
-1)];if(e&&e!==c)e.pointer.onContainerMouseLeave({relatedTarget:!0});e&&e.mouseIsDown||(a.hoverChartIndex=c.index)};a.prototype.touch=function(a,c){var d=this.chart,b;this.setHoverChartIndex();if(1===a.touches.length)if(a=this.normalize(a),(b=d.isInsidePlot(a.chartX-d.plotLeft,a.chartY-d.plotTop,{visiblePlotOnly:!0}))&&!d.openMenu){c&&this.runPointActions(a);if("touchmove"===a.type){c=this.pinchDown;var e=c[0]?4<=Math.sqrt(Math.pow(c[0].chartX-a.chartX,2)+Math.pow(c[0].chartY-a.chartY,2)):!1}D(e,
!0)&&this.pinch(a)}else c&&this.reset();else 2===a.touches.length&&this.pinch(a)};a.prototype.touchSelect=function(a){return!(!this.chart.options.chart.zoomBySingleTouch||!a.touches||1!==a.touches.length)};a.prototype.zoomOption=function(a){var c=this.chart,d=c.options.chart;c=c.inverted;var b=d.zoomType||"";/touch/.test(a.type)&&(b=D(d.pinchType,b));this.zoomX=a=/x/.test(b);this.zoomY=d=/y/.test(b);this.zoomHor=a&&!c||d&&c;this.zoomVert=d&&!c||a&&c;this.hasZoom=a||d};return a}();"";return a});M(a,
"Core/MSPointer.js",[a["Core/Globals.js"],a["Core/Pointer.js"],a["Core/Utilities.js"]],function(a,w,C){function r(){var a=[];a.item=function(a){return this[a]};e(f,function(c){a.push({pageX:c.pageX,pageY:c.pageY,target:c.target})});return a}function z(a,c,e,f){var g=J[w.hoverChartIndex||NaN];"touch"!==a.pointerType&&a.pointerType!==a.MSPOINTER_TYPE_TOUCH||!g||(g=g.pointer,f(a),g[c]({type:e,target:a.currentTarget,preventDefault:n,touches:r()}))}var x=this&&this.__extends||function(){var a=function(c,
e){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,c){a.__proto__=c}||function(a,c){for(var e in c)c.hasOwnProperty(e)&&(a[e]=c[e])};return a(c,e)};return function(c,e){function f(){this.constructor=c}a(c,e);c.prototype=null===e?Object.create(e):(f.prototype=e.prototype,new f)}}(),J=a.charts,u=a.doc,n=a.noop,m=a.win,g=C.addEvent,c=C.css,e=C.objectEach,l=C.removeEvent,f={},v=!!m.PointerEvent;return function(e){function k(){return null!==e&&e.apply(this,arguments)||this}x(k,e);k.isRequired=
function(){return!(a.hasTouch||!m.PointerEvent&&!m.MSPointerEvent)};k.prototype.batchMSEvents=function(a){a(this.chart.container,v?"pointerdown":"MSPointerDown",this.onContainerPointerDown);a(this.chart.container,v?"pointermove":"MSPointerMove",this.onContainerPointerMove);a(u,v?"pointerup":"MSPointerUp",this.onDocumentPointerUp)};k.prototype.destroy=function(){this.batchMSEvents(l);e.prototype.destroy.call(this)};k.prototype.init=function(a,f){e.prototype.init.call(this,a,f);this.hasZoom&&c(a.container,
{"-ms-touch-action":"none","touch-action":"none"})};k.prototype.onContainerPointerDown=function(a){z(a,"onContainerTouchStart","touchstart",function(a){f[a.pointerId]={pageX:a.pageX,pageY:a.pageY,target:a.currentTarget}})};k.prototype.onContainerPointerMove=function(a){z(a,"onContainerTouchMove","touchmove",function(a){f[a.pointerId]={pageX:a.pageX,pageY:a.pageY};f[a.pointerId].target||(f[a.pointerId].target=a.currentTarget)})};k.prototype.onDocumentPointerUp=function(a){z(a,"onDocumentTouchEnd",
"touchend",function(a){delete f[a.pointerId]})};k.prototype.setDOMEvents=function(){e.prototype.setDOMEvents.call(this);(this.hasZoom||this.followTouchMove)&&this.batchMSEvents(g)};return k}(w)});M(a,"Core/Legend/Legend.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/FormatUtilities.js"],a["Core/Globals.js"],a["Core/Series/Point.js"],a["Core/Renderer/RendererUtilities.js"],a["Core/Utilities.js"]],function(a,w,C,E,z,x){var r=a.animObject,u=a.setAnimation,n=w.format;a=C.isFirefox;var m=C.marginNames;
C=C.win;var g=z.distribute,c=x.addEvent,e=x.createElement,l=x.css,f=x.defined,v=x.discardElement,q=x.find,k=x.fireEvent,I=x.isNumber,D=x.merge,B=x.pick,O=x.relativeLength,t=x.stableSort,h=x.syncTimeout;z=x.wrap;x=function(){function a(a,d){this.allItems=[];this.contentGroup=this.box=void 0;this.display=!1;this.group=void 0;this.offsetWidth=this.maxLegendWidth=this.maxItemWidth=this.legendWidth=this.legendHeight=this.lastLineHeight=this.lastItemY=this.itemY=this.itemX=this.itemMarginTop=this.itemMarginBottom=
this.itemHeight=this.initialItemY=0;this.options={};this.padding=0;this.pages=[];this.proximate=!1;this.scrollGroup=void 0;this.widthOption=this.totalItemWidth=this.titleHeight=this.symbolWidth=this.symbolHeight=0;this.chart=a;this.init(a,d)}a.prototype.init=function(a,d){this.chart=a;this.setOptions(d);d.enabled&&(this.render(),c(this.chart,"endResize",function(){this.legend.positionCheckboxes()}),this.proximate?this.unchartrender=c(this.chart,"render",function(){this.legend.proximatePositions();
this.legend.positionItems()}):this.unchartrender&&this.unchartrender())};a.prototype.setOptions=function(a){var b=B(a.padding,8);this.options=a;this.chart.styledMode||(this.itemStyle=a.itemStyle,this.itemHiddenStyle=D(this.itemStyle,a.itemHiddenStyle));this.itemMarginTop=a.itemMarginTop||0;this.itemMarginBottom=a.itemMarginBottom||0;this.padding=b;this.initialItemY=b-5;this.symbolWidth=B(a.symbolWidth,16);this.pages=[];this.proximate="proximate"===a.layout&&!this.chart.inverted;this.baseline=void 0};
a.prototype.update=function(a,d){var b=this.chart;this.setOptions(D(!0,this.options,a));this.destroy();b.isDirtyLegend=b.isDirtyBox=!0;B(d,!0)&&b.redraw();k(this,"afterUpdate")};a.prototype.colorizeItem=function(a,d){a.legendGroup[d?"removeClass":"addClass"]("highcharts-legend-item-hidden");if(!this.chart.styledMode){var b=this.options,c=a.legendItem,e=a.legendLine,h=a.legendSymbol,f=this.itemHiddenStyle.color;b=d?b.itemStyle.color:f;var g=d?a.color||f:f,l=a.options&&a.options.marker,p={fill:g};c&&
c.css({fill:b,color:b});e&&e.attr({stroke:g});h&&(l&&h.isMarker&&(p=a.pointAttribs(),d||(p.stroke=p.fill=f)),h.attr(p))}k(this,"afterColorizeItem",{item:a,visible:d})};a.prototype.positionItems=function(){this.allItems.forEach(this.positionItem,this);this.chart.isResizing||this.positionCheckboxes()};a.prototype.positionItem=function(a){var b=this,d=this.options,c=d.symbolPadding,e=!d.rtl,h=a._legendItemPos;d=h[0];h=h[1];var g=a.checkbox,l=a.legendGroup;l&&l.element&&(c={translateX:e?d:this.legendWidth-
d-2*c-4,translateY:h},e=function(){k(b,"afterPositionItem",{item:a})},f(l.translateY)?l.animate(c,void 0,e):(l.attr(c),e()));g&&(g.x=d,g.y=h)};a.prototype.destroyItem=function(a){var b=a.checkbox;["legendItem","legendLine","legendSymbol","legendGroup"].forEach(function(b){a[b]&&(a[b]=a[b].destroy())});b&&v(a.checkbox)};a.prototype.destroy=function(){function a(a){this[a]&&(this[a]=this[a].destroy())}this.getAllItems().forEach(function(b){["legendItem","legendGroup"].forEach(a,b)});"clipRect up down pager nav box title group".split(" ").forEach(a,
this);this.display=null};a.prototype.positionCheckboxes=function(){var a=this.group&&this.group.alignAttr,d=this.clipHeight||this.legendHeight,c=this.titleHeight;if(a){var e=a.translateY;this.allItems.forEach(function(b){var h=b.checkbox;if(h){var f=e+c+h.y+(this.scrollOffset||0)+3;l(h,{left:a.translateX+b.checkboxOffset+h.x-20+"px",top:f+"px",display:this.proximate||f>e-6&&f<e+d-6?"":"none"})}},this)}};a.prototype.renderTitle=function(){var a=this.options,d=this.padding,c=a.title,e=0;c.text&&(this.title||
(this.title=this.chart.renderer.label(c.text,d-3,d-4,null,null,null,a.useHTML,null,"legend-title").attr({zIndex:1}),this.chart.styledMode||this.title.css(c.style),this.title.add(this.group)),c.width||this.title.css({width:this.maxLegendWidth+"px"}),a=this.title.getBBox(),e=a.height,this.offsetWidth=a.width,this.contentGroup.attr({translateY:e}));this.titleHeight=e};a.prototype.setText=function(a){var b=this.options;a.legendItem.attr({text:b.labelFormat?n(b.labelFormat,a,this.chart):b.labelFormatter.call(a)})};
a.prototype.renderItem=function(a){var b=this.chart,d=b.renderer,c=this.options,e=this.symbolWidth,h=c.symbolPadding||0,f=this.itemStyle,g=this.itemHiddenStyle,k="horizontal"===c.layout?B(c.itemDistance,20):0,l=!c.rtl,m=!a.series,n=!m&&a.series.drawLegendSymbol?a.series:a,q=n.options,t=this.createCheckboxForItem&&q&&q.showCheckbox,v=c.useHTML,r=a.options.className,I=a.legendItem;q=e+h+k+(t?20:0);I||(a.legendGroup=d.g("legend-item").addClass("highcharts-"+n.type+"-series highcharts-color-"+a.colorIndex+
(r?" "+r:"")+(m?" highcharts-series-"+a.index:"")).attr({zIndex:1}).add(this.scrollGroup),a.legendItem=I=d.text("",l?e+h:-h,this.baseline||0,v),b.styledMode||I.css(D(a.visible?f:g)),I.attr({align:l?"left":"right",zIndex:2}).add(a.legendGroup),this.baseline||(this.fontMetrics=d.fontMetrics(b.styledMode?12:f.fontSize,I),this.baseline=this.fontMetrics.f+3+this.itemMarginTop,I.attr("y",this.baseline),this.symbolHeight=c.symbolHeight||this.fontMetrics.f,c.squareSymbol&&(this.symbolWidth=B(c.symbolWidth,
Math.max(this.symbolHeight,16)),q=this.symbolWidth+h+k+(t?20:0),l&&I.attr("x",this.symbolWidth+h))),n.drawLegendSymbol(this,a),this.setItemEvents&&this.setItemEvents(a,I,v));t&&!a.checkbox&&this.createCheckboxForItem&&this.createCheckboxForItem(a);this.colorizeItem(a,a.visible);!b.styledMode&&f.width||I.css({width:(c.itemWidth||this.widthOption||b.spacingBox.width)-q+"px"});this.setText(a);b=I.getBBox();a.itemWidth=a.checkboxOffset=c.itemWidth||a.legendItemWidth||b.width+q;this.maxItemWidth=Math.max(this.maxItemWidth,
a.itemWidth);this.totalItemWidth+=a.itemWidth;this.itemHeight=a.itemHeight=Math.round(a.legendItemHeight||b.height||this.symbolHeight)};a.prototype.layoutItem=function(a){var b=this.options,d=this.padding,c="horizontal"===b.layout,e=a.itemHeight,h=this.itemMarginBottom,f=this.itemMarginTop,g=c?B(b.itemDistance,20):0,k=this.maxLegendWidth;b=b.alignColumns&&this.totalItemWidth>k?this.maxItemWidth:a.itemWidth;c&&this.itemX-d+b>k&&(this.itemX=d,this.lastLineHeight&&(this.itemY+=f+this.lastLineHeight+
h),this.lastLineHeight=0);this.lastItemY=f+this.itemY+h;this.lastLineHeight=Math.max(e,this.lastLineHeight);a._legendItemPos=[this.itemX,this.itemY];c?this.itemX+=b:(this.itemY+=f+e+h,this.lastLineHeight=e);this.offsetWidth=this.widthOption||Math.max((c?this.itemX-d-(a.checkbox?0:g):b)+d,this.offsetWidth)};a.prototype.getAllItems=function(){var a=[];this.chart.series.forEach(function(b){var d=b&&b.options;b&&B(d.showInLegend,f(d.linkedTo)?!1:void 0,!0)&&(a=a.concat(b.legendItems||("point"===d.legendType?
b.data:b)))});k(this,"afterGetAllItems",{allItems:a});return a};a.prototype.getAlignment=function(){var a=this.options;return this.proximate?a.align.charAt(0)+"tv":a.floating?"":a.align.charAt(0)+a.verticalAlign.charAt(0)+a.layout.charAt(0)};a.prototype.adjustMargins=function(a,d){var b=this.chart,c=this.options,e=this.getAlignment();e&&[/(lth|ct|rth)/,/(rtv|rm|rbv)/,/(rbh|cb|lbh)/,/(lbv|lm|ltv)/].forEach(function(h,g){h.test(e)&&!f(a[g])&&(b[m[g]]=Math.max(b[m[g]],b.legend[(g+1)%2?"legendHeight":
"legendWidth"]+[1,-1,-1,1][g]*c[g%2?"x":"y"]+B(c.margin,12)+d[g]+(b.titleOffset[g]||0)))})};a.prototype.proximatePositions=function(){var a=this.chart,d=[],c="left"===this.options.align;this.allItems.forEach(function(b){var e;var h=c;if(b.yAxis){b.xAxis.options.reversed&&(h=!h);b.points&&(e=q(h?b.points:b.points.slice(0).reverse(),function(a){return I(a.plotY)}));h=this.itemMarginTop+b.legendItem.getBBox().height+this.itemMarginBottom;var f=b.yAxis.top-a.plotTop;b.visible?(e=e?e.plotY:b.yAxis.height,
e+=f-.3*h):e=f+b.yAxis.height;d.push({target:e,size:h,item:b})}},this);g(d,a.plotHeight).forEach(function(b){b.item._legendItemPos&&(b.item._legendItemPos[1]=a.plotTop-a.spacing[0]+b.pos)})};a.prototype.render=function(){var a=this.chart,d=a.renderer,c=this.options,e=this.padding,h=this.getAllItems(),f=this.group,g=this.box;this.itemX=e;this.itemY=this.initialItemY;this.lastItemY=this.offsetWidth=0;this.widthOption=O(c.width,a.spacingBox.width-e);var l=a.spacingBox.width-2*e-c.x;-1<["rm","lm"].indexOf(this.getAlignment().substring(0,
2))&&(l/=2);this.maxLegendWidth=this.widthOption||l;f||(this.group=f=d.g("legend").addClass(c.className||"").attr({zIndex:7}).add(),this.contentGroup=d.g().attr({zIndex:1}).add(f),this.scrollGroup=d.g().add(this.contentGroup));this.renderTitle();t(h,function(a,b){return(a.options&&a.options.legendIndex||0)-(b.options&&b.options.legendIndex||0)});c.reversed&&h.reverse();this.allItems=h;this.display=l=!!h.length;this.itemHeight=this.totalItemWidth=this.maxItemWidth=this.lastLineHeight=0;h.forEach(this.renderItem,
this);h.forEach(this.layoutItem,this);h=(this.widthOption||this.offsetWidth)+e;var m=this.lastItemY+this.lastLineHeight+this.titleHeight;m=this.handleOverflow(m);m+=e;g||(this.box=g=d.rect().addClass("highcharts-legend-box").attr({r:c.borderRadius}).add(f),g.isNew=!0);a.styledMode||g.attr({stroke:c.borderColor,"stroke-width":c.borderWidth||0,fill:c.backgroundColor||"none"}).shadow(c.shadow);0<h&&0<m&&(g[g.isNew?"attr":"animate"](g.crisp.call({},{x:0,y:0,width:h,height:m},g.strokeWidth())),g.isNew=
!1);g[l?"show":"hide"]();a.styledMode&&"none"===f.getStyle("display")&&(h=m=0);this.legendWidth=h;this.legendHeight=m;l&&this.align();this.proximate||this.positionItems();k(this,"afterRender")};a.prototype.align=function(a){void 0===a&&(a=this.chart.spacingBox);var b=this.chart,d=this.options,c=a.y;/(lth|ct|rth)/.test(this.getAlignment())&&0<b.titleOffset[0]?c+=b.titleOffset[0]:/(lbh|cb|rbh)/.test(this.getAlignment())&&0<b.titleOffset[2]&&(c-=b.titleOffset[2]);c!==a.y&&(a=D(a,{y:c}));this.group.align(D(d,
{width:this.legendWidth,height:this.legendHeight,verticalAlign:this.proximate?"top":d.verticalAlign}),!0,a)};a.prototype.handleOverflow=function(a){var b=this,d=this.chart,c=d.renderer,e=this.options,h=e.y,f="top"===e.verticalAlign,g=this.padding,k=e.maxHeight,l=e.navigation,m=B(l.animation,!0),n=l.arrowSize||12,q=this.pages,t=this.allItems,v=function(a){"number"===typeof a?N.attr({height:a}):N&&(b.clipRect=N.destroy(),b.contentGroup.clip());b.contentGroup.div&&(b.contentGroup.div.style.clip=a?"rect("+
g+"px,9999px,"+(g+a)+"px,0)":"auto")},r=function(a){b[a]=c.circle(0,0,1.3*n).translate(n/2,n/2).add(U);d.styledMode||b[a].attr("fill","rgba(0,0,0,0.0001)");return b[a]},I,A;h=d.spacingBox.height+(f?-h:h)-g;var U=this.nav,N=this.clipRect;"horizontal"!==e.layout||"middle"===e.verticalAlign||e.floating||(h/=2);k&&(h=Math.min(h,k));q.length=0;a&&0<h&&a>h&&!1!==l.enabled?(this.clipHeight=I=Math.max(h-20-this.titleHeight-g,0),this.currentPage=B(this.currentPage,1),this.fullHeight=a,t.forEach(function(a,
b){var d=a._legendItemPos[1],c=Math.round(a.legendItem.getBBox().height),e=q.length;if(!e||d-q[e-1]>I&&(A||d)!==q[e-1])q.push(A||d),e++;a.pageIx=e-1;A&&(t[b-1].pageIx=e-1);b===t.length-1&&d+c-q[e-1]>I&&d!==A&&(q.push(d),a.pageIx=e);d!==A&&(A=d)}),N||(N=b.clipRect=c.clipRect(0,g,9999,0),b.contentGroup.clip(N)),v(I),U||(this.nav=U=c.g().attr({zIndex:1}).add(this.group),this.up=c.symbol("triangle",0,0,n,n).add(U),r("upTracker").on("click",function(){b.scroll(-1,m)}),this.pager=c.text("",15,10).addClass("highcharts-legend-navigation"),
d.styledMode||this.pager.css(l.style),this.pager.add(U),this.down=c.symbol("triangle-down",0,0,n,n).add(U),r("downTracker").on("click",function(){b.scroll(1,m)})),b.scroll(0),a=h):U&&(v(),this.nav=U.destroy(),this.scrollGroup.attr({translateY:1}),this.clipHeight=0);return a};a.prototype.scroll=function(a,d){var b=this,c=this.chart,e=this.pages,f=e.length,g=this.clipHeight,l=this.options.navigation,m=this.pager,p=this.padding,n=this.currentPage+a;n>f&&(n=f);0<n&&("undefined"!==typeof d&&u(d,c),this.nav.attr({translateX:p,
translateY:g+this.padding+7+this.titleHeight,visibility:"visible"}),[this.up,this.upTracker].forEach(function(a){a.attr({"class":1===n?"highcharts-legend-nav-inactive":"highcharts-legend-nav-active"})}),m.attr({text:n+"/"+f}),[this.down,this.downTracker].forEach(function(a){a.attr({x:18+this.pager.getBBox().width,"class":n===f?"highcharts-legend-nav-inactive":"highcharts-legend-nav-active"})},this),c.styledMode||(this.up.attr({fill:1===n?l.inactiveColor:l.activeColor}),this.upTracker.css({cursor:1===
n?"default":"pointer"}),this.down.attr({fill:n===f?l.inactiveColor:l.activeColor}),this.downTracker.css({cursor:n===f?"default":"pointer"})),this.scrollOffset=-e[n-1]+this.initialItemY,this.scrollGroup.animate({translateY:this.scrollOffset}),this.currentPage=n,this.positionCheckboxes(),a=r(B(d,c.renderer.globalAnimation,!0)),h(function(){k(b,"afterScroll",{currentPage:n})},a.duration))};a.prototype.setItemEvents=function(a,d,c){var b=this,e=b.chart.renderer.boxWrapper,h=a instanceof E,f="highcharts-legend-"+
(h?"point":"series")+"-active",g=b.chart.styledMode,l=function(d){b.allItems.forEach(function(b){a!==b&&[b].concat(b.linkedSeries||[]).forEach(function(a){a.setState(d,!h)})})};(c?[d,a.legendSymbol]:[a.legendGroup]).forEach(function(c){if(c)c.on("mouseover",function(){a.visible&&l("inactive");a.setState("hover");a.visible&&e.addClass(f);g||d.css(b.options.itemHoverStyle)}).on("mouseout",function(){b.chart.styledMode||d.css(D(a.visible?b.itemStyle:b.itemHiddenStyle));l("");e.removeClass(f);a.setState()}).on("click",
function(b){var d=function(){a.setVisible&&a.setVisible();l(a.visible?"inactive":"")};e.removeClass(f);b={browserEvent:b};a.firePointEvent?a.firePointEvent("legendItemClick",b,d):k(a,"legendItemClick",b,d)})})};a.prototype.createCheckboxForItem=function(a){a.checkbox=e("input",{type:"checkbox",className:"highcharts-legend-checkbox",checked:a.selected,defaultChecked:a.selected},this.options.itemCheckboxStyle,this.chart.container);c(a.checkbox,"click",function(b){k(a.series||a,"checkboxClick",{checked:b.target.checked,
item:a},function(){a.select()})})};return a}();(/Trident\/7\.0/.test(C.navigator&&C.navigator.userAgent)||a)&&z(x.prototype,"positionItem",function(a,b){var d=this,c=function(){b._legendItemPos&&a.call(d,b)};c();d.bubbleLegend||setTimeout(c)});"";return x});M(a,"Core/Series/SeriesRegistry.js",[a["Core/Globals.js"],a["Core/DefaultOptions.js"],a["Core/Series/Point.js"],a["Core/Utilities.js"]],function(a,w,C,E){var r=w.defaultOptions,x=E.error,J=E.extendClass,u=E.merge,n;(function(m){function g(a,e){var c=
r.plotOptions||{},f=e.defaultOptions;e.prototype.pointClass||(e.prototype.pointClass=C);e.prototype.type=a;f&&(c[a]=f);m.seriesTypes[a]=e}m.seriesTypes=a.seriesTypes;m.getSeries=function(a,e){void 0===e&&(e={});var c=a.options.chart;c=e.type||c.type||c.defaultSeriesType||"";var f=m.seriesTypes[c];m||x(17,!0,a,{missingModuleFor:c});c=new f;"function"===typeof c.init&&c.init(a,e);return c};m.registerSeriesType=g;m.seriesType=function(a,e,l,f,n){var c=r.plotOptions||{};e=e||"";c[a]=u(c[e],l);g(a,J(m.seriesTypes[e]||
function(){},f));m.seriesTypes[a].prototype.type=a;n&&(m.seriesTypes[a].prototype.pointClass=J(C,n));return m.seriesTypes[a]}})(n||(n={}));return n});M(a,"Core/Chart/Chart.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Axis/Axis.js"],a["Core/FormatUtilities.js"],a["Core/Foundation.js"],a["Core/Globals.js"],a["Core/Legend/Legend.js"],a["Core/MSPointer.js"],a["Core/DefaultOptions.js"],a["Core/Color/Palette.js"],a["Core/Pointer.js"],a["Core/Renderer/RendererRegistry.js"],a["Core/Series/SeriesRegistry.js"],
a["Core/Renderer/SVG/SVGRenderer.js"],a["Core/Time.js"],a["Core/Utilities.js"],a["Core/Renderer/HTML/AST.js"]],function(a,w,C,E,z,x,J,u,n,m,g,c,e,l,f,v){var q=a.animate,k=a.animObject,r=a.setAnimation,D=C.numberFormat,B=E.registerEventOptions,O=z.charts,t=z.doc,h=z.marginNames,d=z.svg,b=z.win,p=u.defaultOptions,G=u.defaultTime,y=c.seriesTypes,L=f.addEvent,F=f.attr,P=f.cleanRecursively,S=f.createElement,Q=f.css,V=f.defined,fa=f.discardElement,H=f.erase,K=f.error,M=f.extend,ha=f.find,R=f.fireEvent,
Z=f.getStyle,A=f.isArray,U=f.isNumber,N=f.isObject,W=f.isString,X=f.merge,Y=f.objectEach,T=f.pick,da=f.pInt,ka=f.relativeLength,ja=f.removeEvent,ba=f.splat,ea=f.syncTimeout,ma=f.uniqueKey;a=function(){function a(a,b,d){this.series=this.renderTo=this.renderer=this.pointer=this.pointCount=this.plotWidth=this.plotTop=this.plotLeft=this.plotHeight=this.plotBox=this.options=this.numberFormatter=this.margin=this.legend=this.labelCollectors=this.isResizing=this.index=this.eventOptions=this.container=this.colorCounter=
this.clipBox=this.chartWidth=this.chartHeight=this.bounds=this.axisOffset=this.axes=void 0;this.sharedClips={};this.yAxis=this.xAxis=this.userOptions=this.titleOffset=this.time=this.symbolCounter=this.spacingBox=this.spacing=void 0;this.getArgs(a,b,d)}a.chart=function(b,d,c){return new a(b,d,c)};a.prototype.getArgs=function(a,b,d){W(a)||a.nodeName?(this.renderTo=a,this.init(b,d)):this.init(a,b)};a.prototype.init=function(a,b){var d=a.plotOptions||{};R(this,"init",{args:arguments},function(){var c=
X(p,a),e=c.chart;Y(c.plotOptions,function(a,b){N(a)&&(a.tooltip=d[b]&&X(d[b].tooltip)||void 0)});c.tooltip.userOptions=a.chart&&a.chart.forExport&&a.tooltip.userOptions||a.tooltip;this.userOptions=a;this.margin=[];this.spacing=[];this.bounds={h:{},v:{}};this.labelCollectors=[];this.callback=b;this.isResizing=0;this.options=c;this.axes=[];this.series=[];this.time=a.time&&Object.keys(a.time).length?new l(a.time):z.time;this.numberFormatter=e.numberFormatter||D;this.styledMode=e.styledMode;this.hasCartesianSeries=
e.showAxes;this.index=O.length;O.push(this);z.chartCount++;B(this,e);this.xAxis=[];this.yAxis=[];this.pointCount=this.colorCounter=this.symbolCounter=0;R(this,"afterInit");this.firstRender()})};a.prototype.initSeries=function(a){var b=this.options.chart;b=a.type||b.type||b.defaultSeriesType;var d=y[b];d||K(17,!0,this,{missingModuleFor:b});b=new d;"function"===typeof b.init&&b.init(this,a);return b};a.prototype.setSeriesData=function(){this.getSeriesOrderByLinks().forEach(function(a){a.points||a.data||
!a.enabledDataSorting||a.setData(a.options.data,!1)})};a.prototype.getSeriesOrderByLinks=function(){return this.series.concat().sort(function(a,b){return a.linkedSeries.length||b.linkedSeries.length?b.linkedSeries.length-a.linkedSeries.length:0})};a.prototype.orderSeries=function(a){var b=this.series;a=a||0;for(var d=b.length;a<d;++a)b[a]&&(b[a].index=a,b[a].name=b[a].getName())};a.prototype.isInsidePlot=function(a,b,d){void 0===d&&(d={});var c=this.inverted,e=this.plotBox,h=this.plotLeft,f=this.plotTop,
g=this.scrollablePlotBox,k=0;var l=0;d.visiblePlotOnly&&this.scrollingContainer&&(l=this.scrollingContainer,k=l.scrollLeft,l=l.scrollTop);var m=d.series;e=d.visiblePlotOnly&&g||e;g=d.inverted?b:a;b=d.inverted?a:b;a={x:g,y:b,isInsidePlot:!0};if(!d.ignoreX){var A=m&&(c?m.yAxis:m.xAxis)||{pos:h,len:Infinity};g=d.paneCoordinates?A.pos+g:h+g;g>=Math.max(k+h,A.pos)&&g<=Math.min(k+h+e.width,A.pos+A.len)||(a.isInsidePlot=!1)}!d.ignoreY&&a.isInsidePlot&&(c=m&&(c?m.xAxis:m.yAxis)||{pos:f,len:Infinity},d=d.paneCoordinates?
c.pos+b:f+b,d>=Math.max(l+f,c.pos)&&d<=Math.min(l+f+e.height,c.pos+c.len)||(a.isInsidePlot=!1));R(this,"afterIsInsidePlot",a);return a.isInsidePlot};a.prototype.redraw=function(a){R(this,"beforeRedraw");var b=this.hasCartesianSeries?this.axes:this.colorAxis||[],d=this.series,c=this.pointer,e=this.legend,h=this.userOptions.legend,f=this.renderer,g=f.isHidden(),k=[],l=this.isDirtyBox,m=this.isDirtyLegend;this.setResponsive&&this.setResponsive(!1);r(this.hasRendered?a:!1,this);g&&this.temporaryDisplay();
this.layOutTitles();for(a=d.length;a--;){var A=d[a];if(A.options.stacking||A.options.centerInCategory){var p=!0;if(A.isDirty){var n=!0;break}}}if(n)for(a=d.length;a--;)A=d[a],A.options.stacking&&(A.isDirty=!0);d.forEach(function(a){a.isDirty&&("point"===a.options.legendType?("function"===typeof a.updateTotals&&a.updateTotals(),m=!0):h&&(h.labelFormatter||h.labelFormat)&&(m=!0));a.isDirtyData&&R(a,"updatedData")});m&&e&&e.options.enabled&&(e.render(),this.isDirtyLegend=!1);p&&this.getStacks();b.forEach(function(a){a.updateNames();
a.setScale()});this.getMargins();b.forEach(function(a){a.isDirty&&(l=!0)});b.forEach(function(a){var b=a.min+","+a.max;a.extKey!==b&&(a.extKey=b,k.push(function(){R(a,"afterSetExtremes",M(a.eventArgs,a.getExtremes()));delete a.eventArgs}));(l||p)&&a.redraw()});l&&this.drawChartBox();R(this,"predraw");d.forEach(function(a){(l||a.isDirty)&&a.visible&&a.redraw();a.isDirtyData=!1});c&&c.reset(!0);f.draw();R(this,"redraw");R(this,"render");g&&this.temporaryDisplay(!0);k.forEach(function(a){a.call()})};
a.prototype.get=function(a){function b(b){return b.id===a||b.options&&b.options.id===a}for(var d=this.series,c=ha(this.axes,b)||ha(this.series,b),e=0;!c&&e<d.length;e++)c=ha(d[e].points||[],b);return c};a.prototype.getAxes=function(){var a=this,b=this.options,d=b.xAxis=ba(b.xAxis||{});b=b.yAxis=ba(b.yAxis||{});R(this,"getAxes");d.forEach(function(a,b){a.index=b;a.isX=!0});b.forEach(function(a,b){a.index=b});d.concat(b).forEach(function(b){new w(a,b)});R(this,"afterGetAxes")};a.prototype.getSelectedPoints=
function(){return this.series.reduce(function(a,b){b.getPointsCollection().forEach(function(b){T(b.selectedStaging,b.selected)&&a.push(b)});return a},[])};a.prototype.getSelectedSeries=function(){return this.series.filter(function(a){return a.selected})};a.prototype.setTitle=function(a,b,d){this.applyDescription("title",a);this.applyDescription("subtitle",b);this.applyDescription("caption",void 0);this.layOutTitles(d)};a.prototype.applyDescription=function(a,b){var d=this,c="title"===a?{color:n.neutralColor80,
fontSize:this.options.isStock?"16px":"18px"}:{color:n.neutralColor60};c=this.options[a]=X(!this.styledMode&&{style:c},this.options[a],b);var e=this[a];e&&b&&(this[a]=e=e.destroy());c&&!e&&(e=this.renderer.text(c.text,0,0,c.useHTML).attr({align:c.align,"class":"highcharts-"+a,zIndex:c.zIndex||4}).add(),e.update=function(b){d[{title:"setTitle",subtitle:"setSubtitle",caption:"setCaption"}[a]](b)},this.styledMode||e.css(c.style),this[a]=e)};a.prototype.layOutTitles=function(a){var b=[0,0,0],d=this.renderer,
c=this.spacingBox;["title","subtitle","caption"].forEach(function(a){var e=this[a],h=this.options[a],f=h.verticalAlign||"top";a="title"===a?"top"===f?-3:0:"top"===f?b[0]+2:0;var g;if(e){this.styledMode||(g=h.style&&h.style.fontSize);g=d.fontMetrics(g,e).b;e.css({width:(h.width||c.width+(h.widthAdjust||0))+"px"});var k=Math.round(e.getBBox(h.useHTML).height);e.align(M({y:"bottom"===f?g:a+g,height:k},h),!1,"spacingBox");h.floating||("top"===f?b[0]=Math.ceil(b[0]+k):"bottom"===f&&(b[2]=Math.ceil(b[2]+
k)))}},this);b[0]&&"top"===(this.options.title.verticalAlign||"top")&&(b[0]+=this.options.title.margin);b[2]&&"bottom"===this.options.caption.verticalAlign&&(b[2]+=this.options.caption.margin);var e=!this.titleOffset||this.titleOffset.join(",")!==b.join(",");this.titleOffset=b;R(this,"afterLayOutTitles");!this.isDirtyBox&&e&&(this.isDirtyBox=this.isDirtyLegend=e,this.hasRendered&&T(a,!0)&&this.isDirtyBox&&this.redraw())};a.prototype.getChartSize=function(){var a=this.options.chart,b=a.width;a=a.height;
var d=this.renderTo;V(b)||(this.containerWidth=Z(d,"width"));V(a)||(this.containerHeight=Z(d,"height"));this.chartWidth=Math.max(0,b||this.containerWidth||600);this.chartHeight=Math.max(0,ka(a,this.chartWidth)||(1<this.containerHeight?this.containerHeight:400))};a.prototype.temporaryDisplay=function(a){var b=this.renderTo;if(a)for(;b&&b.style;)b.hcOrigStyle&&(Q(b,b.hcOrigStyle),delete b.hcOrigStyle),b.hcOrigDetached&&(t.body.removeChild(b),b.hcOrigDetached=!1),b=b.parentNode;else for(;b&&b.style;){t.body.contains(b)||
b.parentNode||(b.hcOrigDetached=!0,t.body.appendChild(b));if("none"===Z(b,"display",!1)||b.hcOricDetached)b.hcOrigStyle={display:b.style.display,height:b.style.height,overflow:b.style.overflow},a={display:"block",overflow:"hidden"},b!==this.renderTo&&(a.height=0),Q(b,a),b.offsetWidth||b.style.setProperty("display","block","important");b=b.parentNode;if(b===t.body)break}};a.prototype.setClassName=function(a){this.container.className="highcharts-container "+(a||"")};a.prototype.getContainer=function(){var a=
this.options,b=a.chart,c=ma(),h,f=this.renderTo;f||(this.renderTo=f=b.renderTo);W(f)&&(this.renderTo=f=t.getElementById(f));f||K(13,!0,this);var k=da(F(f,"data-highcharts-chart"));U(k)&&O[k]&&O[k].hasRendered&&O[k].destroy();F(f,"data-highcharts-chart",this.index);f.innerHTML="";b.skipClone||f.offsetWidth||this.temporaryDisplay();this.getChartSize();k=this.chartWidth;var l=this.chartHeight;Q(f,{overflow:"hidden"});this.styledMode||(h=M({position:"relative",overflow:"hidden",width:k+"px",height:l+
"px",textAlign:"left",lineHeight:"normal",zIndex:0,"-webkit-tap-highlight-color":"rgba(0,0,0,0)",userSelect:"none","touch-action":"manipulation",outline:"none"},b.style||{}));this.container=c=S("div",{id:c},h,f);this._cursor=c.style.cursor;this.renderer=new (b.renderer||!d?g.getRendererType(b.renderer):e)(c,k,l,void 0,b.forExport,a.exporting&&a.exporting.allowHTML,this.styledMode);r(void 0,this);this.setClassName(b.className);if(this.styledMode)for(var m in a.defs)this.renderer.definition(a.defs[m]);
else this.renderer.setStyle(b.style);this.renderer.chartIndex=this.index;R(this,"afterGetContainer")};a.prototype.getMargins=function(a){var b=this.spacing,d=this.margin,c=this.titleOffset;this.resetMargins();c[0]&&!V(d[0])&&(this.plotTop=Math.max(this.plotTop,c[0]+b[0]));c[2]&&!V(d[2])&&(this.marginBottom=Math.max(this.marginBottom,c[2]+b[2]));this.legend&&this.legend.display&&this.legend.adjustMargins(d,b);R(this,"getMargins");a||this.getAxisMargins()};a.prototype.getAxisMargins=function(){var a=
this,b=a.axisOffset=[0,0,0,0],d=a.colorAxis,c=a.margin,e=function(a){a.forEach(function(a){a.visible&&a.getOffset()})};a.hasCartesianSeries?e(a.axes):d&&d.length&&e(d);h.forEach(function(d,e){V(c[e])||(a[d]+=b[e])});a.setChartSize()};a.prototype.reflow=function(a){var d=this,c=d.options.chart,e=d.renderTo,h=V(c.width)&&V(c.height),g=c.width||Z(e,"width");c=c.height||Z(e,"height");e=a?a.target:b;delete d.pointer.chartPosition;if(!h&&!d.isPrinting&&g&&c&&(e===b||e===t)){if(g!==d.containerWidth||c!==
d.containerHeight)f.clearTimeout(d.reflowTimeout),d.reflowTimeout=ea(function(){d.container&&d.setSize(void 0,void 0,!1)},a?100:0);d.containerWidth=g;d.containerHeight=c}};a.prototype.setReflow=function(a){var d=this;!1===a||this.unbindReflow?!1===a&&this.unbindReflow&&(this.unbindReflow=this.unbindReflow()):(this.unbindReflow=L(b,"resize",function(a){d.options&&d.reflow(a)}),L(this,"destroy",this.unbindReflow))};a.prototype.setSize=function(a,b,d){var c=this,e=c.renderer;c.isResizing+=1;r(d,c);d=
e.globalAnimation;c.oldChartHeight=c.chartHeight;c.oldChartWidth=c.chartWidth;"undefined"!==typeof a&&(c.options.chart.width=a);"undefined"!==typeof b&&(c.options.chart.height=b);c.getChartSize();c.styledMode||(d?q:Q)(c.container,{width:c.chartWidth+"px",height:c.chartHeight+"px"},d);c.setChartSize(!0);e.setSize(c.chartWidth,c.chartHeight,d);c.axes.forEach(function(a){a.isDirty=!0;a.setScale()});c.isDirtyLegend=!0;c.isDirtyBox=!0;c.layOutTitles();c.getMargins();c.redraw(d);c.oldChartHeight=null;R(c,
"resize");ea(function(){c&&R(c,"endResize",null,function(){--c.isResizing})},k(d).duration)};a.prototype.setChartSize=function(a){var b=this.inverted,d=this.renderer,c=this.chartWidth,e=this.chartHeight,h=this.options.chart,f=this.spacing,g=this.clipOffset,k,l,m,A;this.plotLeft=k=Math.round(this.plotLeft);this.plotTop=l=Math.round(this.plotTop);this.plotWidth=m=Math.max(0,Math.round(c-k-this.marginRight));this.plotHeight=A=Math.max(0,Math.round(e-l-this.marginBottom));this.plotSizeX=b?A:m;this.plotSizeY=
b?m:A;this.plotBorderWidth=h.plotBorderWidth||0;this.spacingBox=d.spacingBox={x:f[3],y:f[0],width:c-f[3]-f[1],height:e-f[0]-f[2]};this.plotBox=d.plotBox={x:k,y:l,width:m,height:A};b=2*Math.floor(this.plotBorderWidth/2);c=Math.ceil(Math.max(b,g[3])/2);e=Math.ceil(Math.max(b,g[0])/2);this.clipBox={x:c,y:e,width:Math.floor(this.plotSizeX-Math.max(b,g[1])/2-c),height:Math.max(0,Math.floor(this.plotSizeY-Math.max(b,g[2])/2-e))};a||(this.axes.forEach(function(a){a.setAxisSize();a.setAxisTranslation()}),
d.alignElements());R(this,"afterSetChartSize",{skipAxes:a})};a.prototype.resetMargins=function(){R(this,"resetMargins");var a=this,b=a.options.chart;["margin","spacing"].forEach(function(d){var c=b[d],e=N(c)?c:[c,c,c,c];["Top","Right","Bottom","Left"].forEach(function(c,h){a[d][h]=T(b[d+c],e[h])})});h.forEach(function(b,d){a[b]=T(a.margin[d],a.spacing[d])});a.axisOffset=[0,0,0,0];a.clipOffset=[0,0,0,0]};a.prototype.drawChartBox=function(){var a=this.options.chart,b=this.renderer,d=this.chartWidth,
c=this.chartHeight,e=this.styledMode,h=this.plotBGImage,f=a.backgroundColor,g=a.plotBackgroundColor,k=a.plotBackgroundImage,l=this.plotLeft,m=this.plotTop,A=this.plotWidth,p=this.plotHeight,n=this.plotBox,q=this.clipRect,N=this.clipBox,t=this.chartBackground,v=this.plotBackground,r=this.plotBorder,B,y="animate";t||(this.chartBackground=t=b.rect().addClass("highcharts-background").add(),y="attr");if(e)var I=B=t.strokeWidth();else{I=a.borderWidth||0;B=I+(a.shadow?8:0);f={fill:f||"none"};if(I||t["stroke-width"])f.stroke=
a.borderColor,f["stroke-width"]=I;t.attr(f).shadow(a.shadow)}t[y]({x:B/2,y:B/2,width:d-B-I%2,height:c-B-I%2,r:a.borderRadius});y="animate";v||(y="attr",this.plotBackground=v=b.rect().addClass("highcharts-plot-background").add());v[y](n);e||(v.attr({fill:g||"none"}).shadow(a.plotShadow),k&&(h?(k!==h.attr("href")&&h.attr("href",k),h.animate(n)):this.plotBGImage=b.image(k,l,m,A,p).add()));q?q.animate({width:N.width,height:N.height}):this.clipRect=b.clipRect(N);y="animate";r||(y="attr",this.plotBorder=
r=b.rect().addClass("highcharts-plot-border").attr({zIndex:1}).add());e||r.attr({stroke:a.plotBorderColor,"stroke-width":a.plotBorderWidth||0,fill:"none"});r[y](r.crisp({x:l,y:m,width:A,height:p},-r.strokeWidth()));this.isDirtyBox=!1;R(this,"afterDrawChartBox")};a.prototype.propFromSeries=function(){var a=this,b=a.options.chart,d=a.options.series,c,e,h;["inverted","angular","polar"].forEach(function(f){e=y[b.type||b.defaultSeriesType];h=b[f]||e&&e.prototype[f];for(c=d&&d.length;!h&&c--;)(e=y[d[c].type])&&
e.prototype[f]&&(h=!0);a[f]=h})};a.prototype.linkSeries=function(){var a=this,b=a.series;b.forEach(function(a){a.linkedSeries.length=0});b.forEach(function(b){var d=b.options.linkedTo;W(d)&&(d=":previous"===d?a.series[b.index-1]:a.get(d))&&d.linkedParent!==b&&(d.linkedSeries.push(b),b.linkedParent=d,d.enabledDataSorting&&b.setDataSortingOptions(),b.visible=T(b.options.visible,d.options.visible,b.visible))});R(this,"afterLinkSeries")};a.prototype.renderSeries=function(){this.series.forEach(function(a){a.translate();
a.render()})};a.prototype.renderLabels=function(){var a=this,b=a.options.labels;b.items&&b.items.forEach(function(d){var c=M(b.style,d.style),e=da(c.left)+a.plotLeft,h=da(c.top)+a.plotTop+12;delete c.left;delete c.top;a.renderer.text(d.html,e,h).attr({zIndex:2}).css(c).add()})};a.prototype.render=function(){var a=this.axes,b=this.colorAxis,d=this.renderer,c=this.options,e=function(a){a.forEach(function(a){a.visible&&a.render()})},h=0;this.setTitle();this.legend=new x(this,c.legend);this.getStacks&&
this.getStacks();this.getMargins(!0);this.setChartSize();c=this.plotWidth;a.some(function(a){if(a.horiz&&a.visible&&a.options.labels.enabled&&a.series.length)return h=21,!0});var f=this.plotHeight=Math.max(this.plotHeight-h,0);a.forEach(function(a){a.setScale()});this.getAxisMargins();var g=1.1<c/this.plotWidth,k=1.05<f/this.plotHeight;if(g||k)a.forEach(function(a){(a.horiz&&g||!a.horiz&&k)&&a.setTickInterval(!0)}),this.getMargins();this.drawChartBox();this.hasCartesianSeries?e(a):b&&b.length&&e(b);
this.seriesGroup||(this.seriesGroup=d.g("series-group").attr({zIndex:3}).add());this.renderSeries();this.renderLabels();this.addCredits();this.setResponsive&&this.setResponsive();this.hasRendered=!0};a.prototype.addCredits=function(a){var d=this,c=X(!0,this.options.credits,a);c.enabled&&!this.credits&&(this.credits=this.renderer.text(c.text+(this.mapCredits||""),0,0).addClass("highcharts-credits").on("click",function(){c.href&&(b.location.href=c.href)}).attr({align:c.position.align,zIndex:8}),d.styledMode||
this.credits.css(c.style),this.credits.add().align(c.position),this.credits.update=function(a){d.credits=d.credits.destroy();d.addCredits(a)})};a.prototype.destroy=function(){var a=this,b=a.axes,d=a.series,c=a.container,e=c&&c.parentNode,h;R(a,"destroy");a.renderer.forExport?H(O,a):O[a.index]=void 0;z.chartCount--;a.renderTo.removeAttribute("data-highcharts-chart");ja(a);for(h=b.length;h--;)b[h]=b[h].destroy();this.scroller&&this.scroller.destroy&&this.scroller.destroy();for(h=d.length;h--;)d[h]=
d[h].destroy();"title subtitle chartBackground plotBackground plotBGImage plotBorder seriesGroup clipRect credits pointer rangeSelector legend resetZoomButton tooltip renderer".split(" ").forEach(function(b){var d=a[b];d&&d.destroy&&(a[b]=d.destroy())});c&&(c.innerHTML="",ja(c),e&&fa(c));Y(a,function(b,d){delete a[d]})};a.prototype.firstRender=function(){var a=this,b=a.options;if(!a.isReadyToRender||a.isReadyToRender()){a.getContainer();a.resetMargins();a.setChartSize();a.propFromSeries();a.getAxes();
(A(b.series)?b.series:[]).forEach(function(b){a.initSeries(b)});a.linkSeries();a.setSeriesData();R(a,"beforeRender");m&&(J.isRequired()?a.pointer=new J(a,b):a.pointer=new m(a,b));a.render();a.pointer.getChartPosition();if(!a.renderer.imgCount&&!a.hasLoaded)a.onload();a.temporaryDisplay(!0)}};a.prototype.onload=function(){this.callbacks.concat([this.callback]).forEach(function(a){a&&"undefined"!==typeof this.index&&a.apply(this,[this])},this);R(this,"load");R(this,"render");V(this.index)&&this.setReflow(this.options.chart.reflow);
this.hasLoaded=!0};a.prototype.addSeries=function(a,b,d){var c=this,e;a&&(b=T(b,!0),R(c,"addSeries",{options:a},function(){e=c.initSeries(a);c.isDirtyLegend=!0;c.linkSeries();e.enabledDataSorting&&e.setData(a.data,!1);R(c,"afterAddSeries",{series:e});b&&c.redraw(d)}));return e};a.prototype.addAxis=function(a,b,d,c){return this.createAxis(b?"xAxis":"yAxis",{axis:a,redraw:d,animation:c})};a.prototype.addColorAxis=function(a,b,d){return this.createAxis("colorAxis",{axis:a,redraw:b,animation:d})};a.prototype.createAxis=
function(a,b){a=new w(this,X(b.axis,{index:this[a].length,isX:"xAxis"===a}));T(b.redraw,!0)&&this.redraw(b.animation);return a};a.prototype.showLoading=function(a){var b=this,d=b.options,c=d.loading,e=function(){h&&Q(h,{left:b.plotLeft+"px",top:b.plotTop+"px",width:b.plotWidth+"px",height:b.plotHeight+"px"})},h=b.loadingDiv,f=b.loadingSpan;h||(b.loadingDiv=h=S("div",{className:"highcharts-loading highcharts-loading-hidden"},null,b.container));f||(b.loadingSpan=f=S("span",{className:"highcharts-loading-inner"},
null,h),L(b,"redraw",e));h.className="highcharts-loading";v.setElementHTML(f,T(a,d.lang.loading,""));b.styledMode||(Q(h,M(c.style,{zIndex:10})),Q(f,c.labelStyle),b.loadingShown||(Q(h,{opacity:0,display:""}),q(h,{opacity:c.style.opacity||.5},{duration:c.showDuration||0})));b.loadingShown=!0;e()};a.prototype.hideLoading=function(){var a=this.options,b=this.loadingDiv;b&&(b.className="highcharts-loading highcharts-loading-hidden",this.styledMode||q(b,{opacity:0},{duration:a.loading.hideDuration||100,
complete:function(){Q(b,{display:"none"})}}));this.loadingShown=!1};a.prototype.update=function(a,b,d,c){var e=this,h={credits:"addCredits",title:"setTitle",subtitle:"setSubtitle",caption:"setCaption"},f=a.isResponsiveOptions,g=[],k,m;R(e,"update",{options:a});f||e.setResponsive(!1,!0);a=P(a,e.options);e.userOptions=X(e.userOptions,a);var A=a.chart;if(A){X(!0,e.options.chart,A);"className"in A&&e.setClassName(A.className);"reflow"in A&&e.setReflow(A.reflow);if("inverted"in A||"polar"in A||"type"in
A){e.propFromSeries();var p=!0}"alignTicks"in A&&(p=!0);"events"in A&&B(this,A);Y(A,function(a,b){-1!==e.propsRequireUpdateSeries.indexOf("chart."+b)&&(k=!0);-1!==e.propsRequireDirtyBox.indexOf(b)&&(e.isDirtyBox=!0);-1!==e.propsRequireReflow.indexOf(b)&&(f?e.isDirtyBox=!0:m=!0)});!e.styledMode&&A.style&&e.renderer.setStyle(e.options.chart.style||{})}!e.styledMode&&a.colors&&(this.options.colors=a.colors);a.time&&(this.time===G&&(this.time=new l(a.time)),X(!0,e.options.time,a.time));Y(a,function(b,
d){if(e[d]&&"function"===typeof e[d].update)e[d].update(b,!1);else if("function"===typeof e[h[d]])e[h[d]](b);else"colors"!==d&&-1===e.collectionsWithUpdate.indexOf(d)&&X(!0,e.options[d],a[d]);"chart"!==d&&-1!==e.propsRequireUpdateSeries.indexOf(d)&&(k=!0)});this.collectionsWithUpdate.forEach(function(b){if(a[b]){var c=[];e[b].forEach(function(a,b){a.options.isInternal||c.push(T(a.options.index,b))});ba(a[b]).forEach(function(a,h){var f=V(a.id),g;f&&(g=e.get(a.id));!g&&e[b]&&(g=e[b][c?c[h]:h])&&f&&
V(g.options.id)&&(g=void 0);g&&g.coll===b&&(g.update(a,!1),d&&(g.touched=!0));!g&&d&&e.collectionsWithInit[b]&&(e.collectionsWithInit[b][0].apply(e,[a].concat(e.collectionsWithInit[b][1]||[]).concat([!1])).touched=!0)});d&&e[b].forEach(function(a){a.touched||a.options.isInternal?delete a.touched:g.push(a)})}});g.forEach(function(a){a.chart&&a.remove&&a.remove(!1)});p&&e.axes.forEach(function(a){a.update({},!1)});k&&e.getSeriesOrderByLinks().forEach(function(a){a.chart&&a.update({},!1)},this);p=A&&
A.width;A=A&&(W(A.height)?ka(A.height,p||e.chartWidth):A.height);m||U(p)&&p!==e.chartWidth||U(A)&&A!==e.chartHeight?e.setSize(p,A,c):T(b,!0)&&e.redraw(c);R(e,"afterUpdate",{options:a,redraw:b,animation:c})};a.prototype.setSubtitle=function(a,b){this.applyDescription("subtitle",a);this.layOutTitles(b)};a.prototype.setCaption=function(a,b){this.applyDescription("caption",a);this.layOutTitles(b)};a.prototype.showResetZoom=function(){function a(){b.zoomOut()}var b=this,d=p.lang,c=b.options.chart.resetZoomButton,
e=c.theme,h=e.states,f="chart"===c.relativeTo||"spacingBox"===c.relativeTo?null:"scrollablePlotBox";R(this,"beforeShowResetZoom",null,function(){b.resetZoomButton=b.renderer.button(d.resetZoom,null,null,a,e,h&&h.hover).attr({align:c.position.align,title:d.resetZoomTitle}).addClass("highcharts-reset-zoom").add().align(c.position,!1,f)});R(this,"afterShowResetZoom")};a.prototype.zoomOut=function(){R(this,"selection",{resetSelection:!0},this.zoom)};a.prototype.zoom=function(a){var b=this,d=b.pointer,
c=b.inverted?d.mouseDownX:d.mouseDownY,e=!1,h;!a||a.resetSelection?(b.axes.forEach(function(a){h=a.zoom()}),d.initiated=!1):a.xAxis.concat(a.yAxis).forEach(function(a){var f=a.axis,g=b.inverted?f.left:f.top,k=b.inverted?g+f.width:g+f.height,l=f.isXAxis,A=!1;if(!l&&c>=g&&c<=k||l||!V(c))A=!0;d[l?"zoomX":"zoomY"]&&A&&(h=f.zoom(a.min,a.max),f.displayBtn&&(e=!0))});var f=b.resetZoomButton;e&&!f?b.showResetZoom():!e&&N(f)&&(b.resetZoomButton=f.destroy());h&&b.redraw(T(b.options.chart.animation,a&&a.animation,
100>b.pointCount))};a.prototype.pan=function(a,b){var d=this,c=d.hoverPoints;b="object"===typeof b?b:{enabled:b,type:"x"};var e=d.options.chart,h=d.options.mapNavigation&&d.options.mapNavigation.enabled;e&&e.panning&&(e.panning=b);var f=b.type,g;R(this,"pan",{originalEvent:a},function(){c&&c.forEach(function(a){a.setState()});var b=d.xAxis;"xy"===f?b=b.concat(d.yAxis):"y"===f&&(b=d.yAxis);var e={};b.forEach(function(b){if(b.options.panningEnabled&&!b.options.isInternal){var c=b.horiz,k=a[c?"chartX":
"chartY"];c=c?"mouseDownX":"mouseDownY";var l=d[c],A=b.minPointOffset||0,m=b.reversed&&!d.inverted||!b.reversed&&d.inverted?-1:1,p=b.getExtremes(),n=b.toValue(l-k,!0)+A*m,q=b.toValue(l+b.len-k,!0)-(A*m||b.isXAxis&&b.pointRangePadding||0),t=q<n;m=b.hasVerticalPanning();l=t?q:n;n=t?n:q;var N=b.panningState;!m||b.isXAxis||N&&!N.isDirty||b.series.forEach(function(a){var b=a.getProcessedData(!0);b=a.getExtremes(b.yData,!0);N||(N={startMin:Number.MAX_VALUE,startMax:-Number.MAX_VALUE});U(b.dataMin)&&U(b.dataMax)&&
(N.startMin=Math.min(T(a.options.threshold,Infinity),b.dataMin,N.startMin),N.startMax=Math.max(T(a.options.threshold,-Infinity),b.dataMax,N.startMax))});m=Math.min(T(N&&N.startMin,p.dataMin),A?p.min:b.toValue(b.toPixels(p.min)-b.minPixelPadding));q=Math.max(T(N&&N.startMax,p.dataMax),A?p.max:b.toValue(b.toPixels(p.max)+b.minPixelPadding));b.panningState=N;b.isOrdinal||(A=m-l,0<A&&(n+=A,l=m),A=n-q,0<A&&(n=q,l-=A),b.series.length&&l!==p.min&&n!==p.max&&l>=m&&n<=q&&(b.setExtremes(l,n,!1,!1,{trigger:"pan"}),
d.resetZoomButton||h||l===m||n===q||!f.match("y")||(d.showResetZoom(),b.displayBtn=!1),g=!0),e[c]=k)}});Y(e,function(a,b){d[b]=a});g&&d.redraw(!1);Q(d.container,{cursor:"move"})})};return a}();M(a.prototype,{callbacks:[],collectionsWithInit:{xAxis:[a.prototype.addAxis,[!0]],yAxis:[a.prototype.addAxis,[!1]],series:[a.prototype.addSeries]},collectionsWithUpdate:["xAxis","yAxis","series"],propsRequireDirtyBox:"backgroundColor borderColor borderWidth borderRadius plotBackgroundColor plotBackgroundImage plotBorderColor plotBorderWidth plotShadow shadow".split(" "),
propsRequireReflow:"margin marginTop marginRight marginBottom marginLeft spacing spacingTop spacingRight spacingBottom spacingLeft".split(" "),propsRequireUpdateSeries:"chart.inverted chart.polar chart.ignoreHiddenSeries chart.type colors plotOptions time tooltip".split(" ")});"";return a});M(a,"Core/Legend/LegendSymbol.js",[a["Core/Utilities.js"]],function(a){var r=a.merge,C=a.pick,E;(function(a){a.drawLineMarker=function(a){var x=this.options,u=a.symbolWidth,n=a.symbolHeight,m=n/2,g=this.chart.renderer,
c=this.legendGroup;a=a.baseline-Math.round(.3*a.fontMetrics.b);var e={},l=x.marker;this.chart.styledMode||(e={"stroke-width":x.lineWidth||0},x.dashStyle&&(e.dashstyle=x.dashStyle));this.legendLine=g.path([["M",0,a],["L",u,a]]).addClass("highcharts-graph").attr(e).add(c);l&&!1!==l.enabled&&u&&(x=Math.min(C(l.radius,m),m),0===this.symbol.indexOf("url")&&(l=r(l,{width:n,height:n}),x=0),this.legendSymbol=u=g.symbol(this.symbol,u/2-x,a-x,2*x,2*x,l).addClass("highcharts-point").add(c),u.isMarker=!0)};a.drawRectangle=
function(a,r){var u=a.symbolHeight,n=a.options.squareSymbol;r.legendSymbol=this.chart.renderer.rect(n?(a.symbolWidth-u)/2:0,a.baseline-u+1,n?u:a.symbolWidth,u,C(a.options.symbolRadius,u/2)).addClass("highcharts-point").attr({zIndex:3}).add(r.legendGroup)}})(E||(E={}));return E});M(a,"Core/Series/SeriesDefaults.js",[a["Core/Color/Palette.js"]],function(a){return{lineWidth:2,allowPointSelect:!1,crisp:!0,showCheckbox:!1,animation:{duration:1E3},events:{},marker:{enabledThreshold:2,lineColor:a.backgroundColor,
lineWidth:0,radius:4,states:{normal:{animation:!0},hover:{animation:{duration:50},enabled:!0,radiusPlus:2,lineWidthPlus:1},select:{fillColor:a.neutralColor20,lineColor:a.neutralColor100,lineWidth:2}}},point:{events:{}},dataLabels:{animation:{},align:"center",defer:!0,formatter:function(){var a=this.series.chart.numberFormatter;return"number"!==typeof this.y?"":a(this.y,-1)},padding:5,style:{fontSize:"11px",fontWeight:"bold",color:"contrast",textOutline:"1px contrast"},verticalAlign:"bottom",x:0,y:0},
cropThreshold:300,opacity:1,pointRange:0,softThreshold:!0,states:{normal:{animation:!0},hover:{animation:{duration:50},lineWidthPlus:1,marker:{},halo:{size:10,opacity:.25}},select:{animation:{duration:0}},inactive:{animation:{duration:50},opacity:.2}},stickyTracking:!0,turboThreshold:1E3,findNearestPointBy:"x"}});M(a,"Core/Series/Series.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/DefaultOptions.js"],a["Core/Foundation.js"],a["Core/Globals.js"],a["Core/Legend/LegendSymbol.js"],a["Core/Color/Palette.js"],
a["Core/Series/Point.js"],a["Core/Series/SeriesDefaults.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Renderer/SVG/SVGElement.js"],a["Core/Utilities.js"]],function(a,w,C,E,z,x,J,u,n,m,g){var c=a.animObject,e=a.setAnimation,l=w.defaultOptions,f=C.registerEventOptions,v=E.hasTouch,q=E.svg,k=E.win,r=n.seriesTypes,D=g.addEvent,B=g.arrayMax,O=g.arrayMin,t=g.clamp,h=g.cleanRecursively,d=g.correctFloat,b=g.defined,p=g.erase,G=g.error,y=g.extend,L=g.find,F=g.fireEvent,P=g.getNestedProperty,S=g.isArray,
Q=g.isNumber,V=g.isString,M=g.merge,H=g.objectEach,K=g.pick,la=g.removeEvent,ha=g.splat,R=g.syncTimeout;a=function(){function a(){this.zones=this.yAxis=this.xAxis=this.userOptions=this.tooltipOptions=this.processedYData=this.processedXData=this.points=this.options=this.linkedSeries=this.index=this.eventsToUnbind=this.eventOptions=this.data=this.chart=this._i=void 0}a.prototype.init=function(a,b){F(this,"init",{options:b});var d=this,c=a.series;this.eventsToUnbind=[];d.chart=a;d.options=d.setOptions(b);
b=d.options;d.linkedSeries=[];d.bindAxes();y(d,{name:b.name,state:"",visible:!1!==b.visible,selected:!0===b.selected});f(this,b);var e=b.events;if(e&&e.click||b.point&&b.point.events&&b.point.events.click||b.allowPointSelect)a.runTrackerClick=!0;d.getColor();d.getSymbol();d.parallelArrays.forEach(function(a){d[a+"Data"]||(d[a+"Data"]=[])});d.isCartesian&&(a.hasCartesianSeries=!0);var h;c.length&&(h=c[c.length-1]);d._i=K(h&&h._i,-1)+1;d.opacity=d.options.opacity;a.orderSeries(this.insert(c));b.dataSorting&&
b.dataSorting.enabled?d.setDataSortingOptions():d.points||d.data||d.setData(b.data,!1);F(this,"afterInit")};a.prototype.is=function(a){return r[a]&&this instanceof r[a]};a.prototype.insert=function(a){var b=this.options.index,d;if(Q(b)){for(d=a.length;d--;)if(b>=K(a[d].options.index,a[d]._i)){a.splice(d+1,0,this);break}-1===d&&a.unshift(this);d+=1}else a.push(this);return K(d,a.length-1)};a.prototype.bindAxes=function(){var a=this,b=a.options,d=a.chart,c;F(this,"bindAxes",null,function(){(a.axisTypes||
[]).forEach(function(e){var h=0;d[e].forEach(function(d){c=d.options;if(b[e]===h&&!c.isInternal||"undefined"!==typeof b[e]&&b[e]===c.id||"undefined"===typeof b[e]&&0===c.index)a.insert(d.series),a[e]=d,d.isDirty=!0;c.isInternal||h++});a[e]||a.optionalAxis===e||G(18,!0,d)})});F(this,"afterBindAxes")};a.prototype.updateParallelArrays=function(a,b){var d=a.series,c=arguments,e=Q(b)?function(c){var e="y"===c&&d.toYData?d.toYData(a):a[c];d[c+"Data"][b]=e}:function(a){Array.prototype[b].apply(d[a+"Data"],
Array.prototype.slice.call(c,2))};d.parallelArrays.forEach(e)};a.prototype.hasData=function(){return this.visible&&"undefined"!==typeof this.dataMax&&"undefined"!==typeof this.dataMin||this.visible&&this.yData&&0<this.yData.length};a.prototype.autoIncrement=function(a){var b=this.options,d=b.pointIntervalUnit,c=b.relativeXValue,e=this.chart.time,h=this.xIncrement,f;h=K(h,b.pointStart,0);this.pointInterval=f=K(this.pointInterval,b.pointInterval,1);c&&Q(a)&&(f*=a);d&&(b=new e.Date(h),"day"===d?e.set("Date",
b,e.get("Date",b)+f):"month"===d?e.set("Month",b,e.get("Month",b)+f):"year"===d&&e.set("FullYear",b,e.get("FullYear",b)+f),f=b.getTime()-h);if(c&&Q(a))return h+f;this.xIncrement=h+f;return h};a.prototype.setDataSortingOptions=function(){var a=this.options;y(this,{requireSorting:!1,sorted:!1,enabledDataSorting:!0,allowDG:!1});b(a.pointRange)||(a.pointRange=1)};a.prototype.setOptions=function(a){var d=this.chart,c=d.options,e=c.plotOptions,h=d.userOptions||{};a=M(a);d=d.styledMode;var f={plotOptions:e,
userOptions:a};F(this,"setOptions",f);var g=f.plotOptions[this.type],k=h.plotOptions||{};this.userOptions=f.userOptions;h=M(g,e.series,h.plotOptions&&h.plotOptions[this.type],a);this.tooltipOptions=M(l.tooltip,l.plotOptions.series&&l.plotOptions.series.tooltip,l.plotOptions[this.type].tooltip,c.tooltip.userOptions,e.series&&e.series.tooltip,e[this.type].tooltip,a.tooltip);this.stickyTracking=K(a.stickyTracking,k[this.type]&&k[this.type].stickyTracking,k.series&&k.series.stickyTracking,this.tooltipOptions.shared&&
!this.noSharedTooltip?!0:h.stickyTracking);null===g.marker&&delete h.marker;this.zoneAxis=h.zoneAxis;e=this.zones=(h.zones||[]).slice();!h.negativeColor&&!h.negativeFillColor||h.zones||(c={value:h[this.zoneAxis+"Threshold"]||h.threshold||0,className:"highcharts-negative"},d||(c.color=h.negativeColor,c.fillColor=h.negativeFillColor),e.push(c));e.length&&b(e[e.length-1].value)&&e.push(d?{}:{color:this.color,fillColor:this.fillColor});F(this,"afterSetOptions",{options:h});return h};a.prototype.getName=
function(){return K(this.options.name,"Series "+(this.index+1))};a.prototype.getCyclic=function(a,d,c){var e=this.chart,h=this.userOptions,f=a+"Index",g=a+"Counter",k=c?c.length:K(e.options.chart[a+"Count"],e[a+"Count"]);if(!d){var l=K(h[f],h["_"+f]);b(l)||(e.series.length||(e[g]=0),h["_"+f]=l=e[g]%k,e[g]+=1);c&&(d=c[l])}"undefined"!==typeof l&&(this[f]=l);this[a]=d};a.prototype.getColor=function(){this.chart.styledMode?this.getCyclic("color"):this.options.colorByPoint?this.color=x.neutralColor20:
this.getCyclic("color",this.options.color||l.plotOptions[this.type].color,this.chart.options.colors)};a.prototype.getPointsCollection=function(){return(this.hasGroupedData?this.points:this.data)||[]};a.prototype.getSymbol=function(){this.getCyclic("symbol",this.options.marker.symbol,this.chart.options.symbols)};a.prototype.findPointIndex=function(a,b){var d=a.id,c=a.x,e=this.points,h=this.options.dataSorting,f,g;if(d)h=this.chart.get(d),h instanceof J&&(f=h);else if(this.linkedParent||this.enabledDataSorting||
this.options.relativeXValue)if(f=function(b){return!b.touched&&b.index===a.index},h&&h.matchByName?f=function(b){return!b.touched&&b.name===a.name}:this.options.relativeXValue&&(f=function(b){return!b.touched&&b.options.x===a.x}),f=L(e,f),!f)return;if(f){var k=f&&f.index;"undefined"!==typeof k&&(g=!0)}"undefined"===typeof k&&Q(c)&&(k=this.xData.indexOf(c,b));-1!==k&&"undefined"!==typeof k&&this.cropped&&(k=k>=this.cropStart?k-this.cropStart:k);!g&&Q(k)&&e[k]&&e[k].touched&&(k=void 0);return k};a.prototype.updateData=
function(a,d){var c=this.options,e=c.dataSorting,h=this.points,f=[],g=this.requireSorting,k=a.length===h.length,l,m,A,p=!0;this.xIncrement=null;a.forEach(function(a,d){var m=b(a)&&this.pointClass.prototype.optionsToObject.call({series:this},a)||{},p=m.x;if(m.id||Q(p)){if(m=this.findPointIndex(m,A),-1===m||"undefined"===typeof m?f.push(a):h[m]&&a!==c.data[m]?(h[m].update(a,!1,null,!1),h[m].touched=!0,g&&(A=m+1)):h[m]&&(h[m].touched=!0),!k||d!==m||e&&e.enabled||this.hasDerivedData)l=!0}else f.push(a)},
this);if(l)for(a=h.length;a--;)(m=h[a])&&!m.touched&&m.remove&&m.remove(!1,d);else!k||e&&e.enabled?p=!1:(a.forEach(function(a,b){a!==h[b].y&&h[b].update&&h[b].update(a,!1,null,!1)}),f.length=0);h.forEach(function(a){a&&(a.touched=!1)});if(!p)return!1;f.forEach(function(a){this.addPoint(a,!1,null,null,!1)},this);null===this.xIncrement&&this.xData&&this.xData.length&&(this.xIncrement=B(this.xData),this.autoIncrement());return!0};a.prototype.setData=function(a,b,d,c){var e=this,h=e.points,f=h&&h.length||
0,g=e.options,k=e.chart,l=g.dataSorting,m=e.xAxis,A=g.turboThreshold,p=this.xData,n=this.yData,q=e.pointArrayMap;q=q&&q.length;var t=g.keys,v,r=0,B=1,y=null;a=a||[];var N=a.length;b=K(b,!0);l&&l.enabled&&(a=this.sortData(a));!1!==c&&N&&f&&!e.cropped&&!e.hasGroupedData&&e.visible&&!e.isSeriesBoosting&&(v=this.updateData(a,d));if(!v){e.xIncrement=null;e.colorCounter=0;this.parallelArrays.forEach(function(a){e[a+"Data"].length=0});if(A&&N>A)if(y=e.getFirstValidPoint(a),Q(y))for(d=0;d<N;d++)p[d]=this.autoIncrement(),
n[d]=a[d];else if(S(y))if(q)for(d=0;d<N;d++)c=a[d],p[d]=c[0],n[d]=c.slice(1,q+1);else for(t&&(r=t.indexOf("x"),B=t.indexOf("y"),r=0<=r?r:0,B=0<=B?B:1),d=0;d<N;d++)c=a[d],p[d]=c[r],n[d]=c[B];else G(12,!1,k);else for(d=0;d<N;d++)"undefined"!==typeof a[d]&&(c={series:e},e.pointClass.prototype.applyOptions.apply(c,[a[d]]),e.updateParallelArrays(c,d));n&&V(n[0])&&G(14,!0,k);e.data=[];e.options.data=e.userOptions.data=a;for(d=f;d--;)h[d]&&h[d].destroy&&h[d].destroy();m&&(m.minRange=m.userMinRange);e.isDirty=
k.isDirtyBox=!0;e.isDirtyData=!!h;d=!1}"point"===g.legendType&&(this.processData(),this.generatePoints());b&&k.redraw(d)};a.prototype.sortData=function(a){var d=this,c=d.options.dataSorting.sortKey||"y",e=function(a,d){return b(d)&&a.pointClass.prototype.optionsToObject.call({series:a},d)||{}};a.forEach(function(b,c){a[c]=e(d,b);a[c].index=c},this);a.concat().sort(function(a,b){a=P(c,a);b=P(c,b);return b<a?-1:b>a?1:0}).forEach(function(a,b){a.x=b},this);d.linkedSeries&&d.linkedSeries.forEach(function(b){var d=
b.options,c=d.data;d.dataSorting&&d.dataSorting.enabled||!c||(c.forEach(function(d,h){c[h]=e(b,d);a[h]&&(c[h].x=a[h].x,c[h].index=h)}),b.setData(c,!1))});return a};a.prototype.getProcessedData=function(a){var b=this.xAxis,d=this.options,c=d.cropThreshold,e=a||this.getExtremesFromAll||d.getExtremesFromAll,h=this.isCartesian;a=b&&b.val2lin;d=!(!b||!b.logarithmic);var f=0,g=this.xData,k=this.yData,l=this.requireSorting;var m=!1;var A=g.length;if(b){m=b.getExtremes();var p=m.min;var n=m.max;m=b.categories&&
!b.names.length}if(h&&this.sorted&&!e&&(!c||A>c||this.forceCrop))if(g[A-1]<p||g[0]>n)g=[],k=[];else if(this.yData&&(g[0]<p||g[A-1]>n)){var q=this.cropData(this.xData,this.yData,p,n);g=q.xData;k=q.yData;f=q.start;q=!0}for(c=g.length||1;--c;)if(b=d?a(g[c])-a(g[c-1]):g[c]-g[c-1],0<b&&("undefined"===typeof t||b<t))var t=b;else 0>b&&l&&!m&&(G(15,!1,this.chart),l=!1);return{xData:g,yData:k,cropped:q,cropStart:f,closestPointRange:t}};a.prototype.processData=function(a){var b=this.xAxis;if(this.isCartesian&&
!this.isDirty&&!b.isDirty&&!this.yAxis.isDirty&&!a)return!1;a=this.getProcessedData();this.cropped=a.cropped;this.cropStart=a.cropStart;this.processedXData=a.xData;this.processedYData=a.yData;this.closestPointRange=this.basePointRange=a.closestPointRange};a.prototype.cropData=function(a,b,d,c,e){var h=a.length,f,g=0,k=h;e=K(e,this.cropShoulder);for(f=0;f<h;f++)if(a[f]>=d){g=Math.max(0,f-e);break}for(d=f;d<h;d++)if(a[d]>c){k=d+e;break}return{xData:a.slice(g,k),yData:b.slice(g,k),start:g,end:k}};a.prototype.generatePoints=
function(){var a=this.options,b=a.data,d=this.processedXData,c=this.processedYData,e=this.pointClass,h=d.length,f=this.cropStart||0,g=this.hasGroupedData,k=a.keys,l=[];a=a.dataGrouping&&a.dataGrouping.groupAll?f:0;var m,p,n=this.data;if(!n&&!g){var q=[];q.length=b.length;n=this.data=q}k&&g&&(this.options.keys=!1);for(p=0;p<h;p++){q=f+p;if(g){var t=(new e).init(this,[d[p]].concat(ha(c[p])));t.dataGroup=this.groupMap[a+p];t.dataGroup.options&&(t.options=t.dataGroup.options,y(t,t.dataGroup.options),
delete t.dataLabels)}else(t=n[q])||"undefined"===typeof b[q]||(n[q]=t=(new e).init(this,b[q],d[p]));t&&(t.index=g?a+p:q,l[p]=t)}this.options.keys=k;if(n&&(h!==(m=n.length)||g))for(p=0;p<m;p++)p!==f||g||(p+=h),n[p]&&(n[p].destroyElements(),n[p].plotX=void 0);this.data=n;this.points=l;F(this,"afterGeneratePoints")};a.prototype.getXExtremes=function(a){return{min:O(a),max:B(a)}};a.prototype.getExtremes=function(a,b){var d=this.xAxis,c=this.yAxis,e=this.processedXData||this.xData,h=[],f=this.requireSorting?
this.cropShoulder:0;c=c?c.positiveValuesOnly:!1;var g,k=0,l=0,m=0;a=a||this.stackedYData||this.processedYData||[];var p=a.length;if(d){var n=d.getExtremes();k=n.min;l=n.max}for(g=0;g<p;g++){var A=e[g];n=a[g];var q=(Q(n)||S(n))&&(n.length||0<n||!c);A=b||this.getExtremesFromAll||this.options.getExtremesFromAll||this.cropped||!d||(e[g+f]||A)>=k&&(e[g-f]||A)<=l;if(q&&A)if(q=n.length)for(;q--;)Q(n[q])&&(h[m++]=n[q]);else h[m++]=n}a={dataMin:O(h),dataMax:B(h)};F(this,"afterGetExtremes",{dataExtremes:a});
return a};a.prototype.applyExtremes=function(){var a=this.getExtremes();this.dataMin=a.dataMin;this.dataMax=a.dataMax;return a};a.prototype.getFirstValidPoint=function(a){for(var b=a.length,d=0,c=null;null===c&&d<b;)c=a[d],d++;return c};a.prototype.translate=function(){this.processedXData||this.processData();this.generatePoints();var a=this.options,c=a.stacking,e=this.xAxis,h=e.categories,f=this.enabledDataSorting,g=this.yAxis,k=this.points,l=k.length,m=!!this.modifyValue,p=this.pointPlacementToXValue(),
n=!!p,q=a.threshold,v=a.startFromThreshold?q:0,r=this.zoneAxis||"y",B,y,I=Number.MAX_VALUE;for(B=0;B<l;B++){var D=k[B],u=D.x,G=void 0,x=void 0,w=D.y,L=D.low,z=c&&g.stacking&&g.stacking.stacks[(this.negStacks&&w<(v?0:q)?"-":"")+this.stackKey];if(g.positiveValuesOnly&&!g.validatePositiveValue(w)||e.positiveValuesOnly&&!e.validatePositiveValue(u))D.isNull=!0;D.plotX=y=d(t(e.translate(u,0,0,0,1,p,"flags"===this.type),-1E5,1E5));if(c&&this.visible&&z&&z[u]){var C=this.getStackIndicator(C,u,this.index);
D.isNull||(G=z[u],x=G.points[C.key])}S(x)&&(L=x[0],w=x[1],L===v&&C.key===z[u].base&&(L=K(Q(q)&&q,g.min)),g.positiveValuesOnly&&0>=L&&(L=null),D.total=D.stackTotal=G.total,D.percentage=G.total&&D.y/G.total*100,D.stackY=w,this.irregularWidths||G.setOffset(this.pointXOffset||0,this.barW||0));D.yBottom=b(L)?t(g.translate(L,0,1,0,1),-1E5,1E5):null;m&&(w=this.modifyValue(w,D));D.plotY=void 0;Q(w)&&(G=g.translate(w,!1,!0,!1,!0),"undefined"!==typeof G&&(D.plotY=t(G,-1E5,1E5)));D.isInside=this.isPointInside(D);
D.clientX=n?d(e.translate(u,0,0,0,1,p)):y;D.negative=D[r]<(a[r+"Threshold"]||q||0);D.category=h&&"undefined"!==typeof h[D.x]?h[D.x]:D.x;if(!D.isNull&&!1!==D.visible){"undefined"!==typeof H&&(I=Math.min(I,Math.abs(y-H)));var H=y}D.zone=this.zones.length&&D.getZone();!D.graphic&&this.group&&f&&(D.isNew=!0)}this.closestPointRangePx=I;F(this,"afterTranslate")};a.prototype.getValidPoints=function(a,b,d){var c=this.chart;return(a||this.points||[]).filter(function(a){return b&&!c.isInsidePlot(a.plotX,a.plotY,
{inverted:c.inverted})?!1:!1!==a.visible&&(d||!a.isNull)})};a.prototype.getClipBox=function(a,b){var d=this.options,c=this.chart,e=c.inverted,h=this.xAxis,f=h&&this.yAxis,g=c.options.chart.scrollablePlotArea||{};a&&!1===d.clip&&f?a=e?{y:-c.chartWidth+f.len+f.pos,height:c.chartWidth,width:c.chartHeight,x:-c.chartHeight+h.len+h.pos}:{y:-f.pos,height:c.chartHeight,width:c.chartWidth,x:-h.pos}:(a=this.clipBox||c.clipBox,b&&(a.width=c.plotSizeX,a.x=(c.scrollablePixelsX||0)*(g.scrollPositionX||0)));return b?
{width:a.width,x:a.x}:a};a.prototype.getSharedClipKey=function(a){if(this.sharedClipKey)return this.sharedClipKey;var b=[a&&a.duration,a&&a.easing,a&&a.defer,this.getClipBox(a).height,this.options.xAxis,this.options.yAxis].join();if(!1!==this.options.clip||a)this.sharedClipKey=b;return b};a.prototype.setClip=function(a){var b=this.chart,d=this.options,c=b.renderer,e=b.inverted,h=this.clipBox,f=this.getClipBox(a),g=this.getSharedClipKey(a),k=b.sharedClips[g],l=b.sharedClips[g+"m"];a&&(f.width=0,e&&
(f.x=b.plotHeight+(!1!==d.clip?0:b.plotTop)));k?b.hasLoaded||k.attr(f):(a&&(b.sharedClips[g+"m"]=l=c.clipRect(e?(b.plotSizeX||0)+99:-99,e?-b.plotLeft:-b.plotTop,99,e?b.chartWidth:b.chartHeight)),b.sharedClips[g]=k=c.clipRect(f),k.count={length:0});a&&!k.count[this.index]&&(k.count[this.index]=!0,k.count.length+=1);if(!1!==d.clip||a)this.group.clip(a||h?k:b.clipRect),this.markerGroup.clip(l);a||(k.count[this.index]&&(delete k.count[this.index],--k.count.length),0===k.count.length&&(h||(b.sharedClips[g]=
k.destroy()),l&&(b.sharedClips[g+"m"]=l.destroy())))};a.prototype.animate=function(a){var b=this.chart,d=c(this.options.animation),e=this.sharedClipKey;if(a)this.setClip(d);else if(e){a=b.sharedClips[e];e=b.sharedClips[e+"m"];var h=this.getClipBox(d,!0);a&&a.animate(h,d);e&&e.animate({width:h.width+99,x:h.x-(b.inverted?0:99)},d)}};a.prototype.afterAnimate=function(){this.setClip();F(this,"afterAnimate");this.finishedAnimating=!0};a.prototype.drawPoints=function(){var a=this.points,b=this.chart,d=
this.options.marker,c=this[this.specialGroup]||this.markerGroup,e=this.xAxis,h=K(d.enabled,!e||e.isRadial?!0:null,this.closestPointRangePx>=d.enabledThreshold*d.radius),f,g;if(!1!==d.enabled||this._hasPointMarkers)for(f=0;f<a.length;f++){var k=a[f];var l=(g=k.graphic)?"animate":"attr";var m=k.marker||{};var p=!!k.marker;if((h&&"undefined"===typeof m.enabled||m.enabled)&&!k.isNull&&!1!==k.visible){var n=K(m.symbol,this.symbol,"rect");var q=this.markerAttribs(k,k.selected&&"select");this.enabledDataSorting&&
(k.startXPos=e.reversed?-(q.width||0):e.width);var t=!1!==k.isInside;g?g[t?"show":"hide"](t).animate(q):t&&(0<(q.width||0)||k.hasImage)&&(k.graphic=g=b.renderer.symbol(n,q.x,q.y,q.width,q.height,p?m:d).add(c),this.enabledDataSorting&&b.hasRendered&&(g.attr({x:k.startXPos}),l="animate"));g&&"animate"===l&&g[t?"show":"hide"](t).animate(q);if(g&&!b.styledMode)g[l](this.pointAttribs(k,k.selected&&"select"));g&&g.addClass(k.getClassName(),!0)}else g&&(k.graphic=g.destroy())}};a.prototype.markerAttribs=
function(a,b){var d=this.options,c=d.marker,e=a.marker||{},h=e.symbol||c.symbol,f=K(e.radius,c.radius);b&&(c=c.states[b],b=e.states&&e.states[b],f=K(b&&b.radius,c&&c.radius,f+(c&&c.radiusPlus||0)));a.hasImage=h&&0===h.indexOf("url");a.hasImage&&(f=0);a={x:d.crisp?Math.floor(a.plotX-f):a.plotX-f,y:a.plotY-f};f&&(a.width=a.height=2*f);return a};a.prototype.pointAttribs=function(a,b){var d=this.options.marker,c=a&&a.options,e=c&&c.marker||{},h=c&&c.color,f=a&&a.color,g=a&&a.zone&&a.zone.color,k=this.color;
a=K(e.lineWidth,d.lineWidth);c=1;k=h||g||f||k;h=e.fillColor||d.fillColor||k;f=e.lineColor||d.lineColor||k;b=b||"normal";d=d.states[b];b=e.states&&e.states[b]||{};a=K(b.lineWidth,d.lineWidth,a+K(b.lineWidthPlus,d.lineWidthPlus,0));h=b.fillColor||d.fillColor||h;f=b.lineColor||d.lineColor||f;c=K(b.opacity,d.opacity,c);return{stroke:f,"stroke-width":a,fill:h,opacity:c}};a.prototype.destroy=function(a){var b=this,d=b.chart,c=/AppleWebKit\/533/.test(k.navigator.userAgent),e=b.data||[],h,f,l,n;F(b,"destroy");
this.removeEvents(a);(b.axisTypes||[]).forEach(function(a){(n=b[a])&&n.series&&(p(n.series,b),n.isDirty=n.forceRedraw=!0)});b.legendItem&&b.chart.legend.destroyItem(b);for(f=e.length;f--;)(l=e[f])&&l.destroy&&l.destroy();b.clips&&b.clips.forEach(function(a){return a.destroy()});g.clearTimeout(b.animationTimeout);H(b,function(a,b){a instanceof m&&!a.survive&&(h=c&&"group"===b?"hide":"destroy",a[h]())});d.hoverSeries===b&&(d.hoverSeries=void 0);p(d.series,b);d.orderSeries();H(b,function(d,c){a&&"hcEvents"===
c||delete b[c]})};a.prototype.applyZones=function(){var a=this,b=this.chart,d=b.renderer,c=this.zones,e=this.clips||[],h=this.graph,f=this.area,g=Math.max(b.chartWidth,b.chartHeight),k=this[(this.zoneAxis||"y")+"Axis"],l=b.inverted,m,p,n,q,v,r,B,y,D=!1;if(c.length&&(h||f)&&k&&"undefined"!==typeof k.min){var I=k.reversed;var F=k.horiz;h&&!this.showLine&&h.hide();f&&f.hide();var u=k.getExtremes();c.forEach(function(c,A){m=I?F?b.plotWidth:0:F?0:k.toPixels(u.min)||0;m=t(K(p,m),0,g);p=t(Math.round(k.toPixels(K(c.value,
u.max),!0)||0),0,g);D&&(m=p=k.toPixels(u.max));q=Math.abs(m-p);v=Math.min(m,p);r=Math.max(m,p);k.isXAxis?(n={x:l?r:v,y:0,width:q,height:g},F||(n.x=b.plotHeight-n.x)):(n={x:0,y:l?r:v,width:g,height:q},F&&(n.y=b.plotWidth-n.y));l&&d.isVML&&(n=k.isXAxis?{x:0,y:I?v:r,height:n.width,width:b.chartWidth}:{x:n.y-b.plotLeft-b.spacingBox.x,y:0,width:n.height,height:b.chartHeight});e[A]?e[A].animate(n):e[A]=d.clipRect(n);B=a["zone-area-"+A];y=a["zone-graph-"+A];h&&y&&y.clip(e[A]);f&&B&&B.clip(e[A]);D=c.value>
u.max;a.resetZones&&0===p&&(p=void 0)});this.clips=e}else a.visible&&(h&&h.show(!0),f&&f.show(!0))};a.prototype.invertGroups=function(a){function b(){["group","markerGroup"].forEach(function(b){d[b]&&(c.renderer.isVML&&d[b].attr({width:d.yAxis.len,height:d.xAxis.len}),d[b].width=d.yAxis.len,d[b].height=d.xAxis.len,d[b].invert(d.isRadialSeries?!1:a))})}var d=this,c=d.chart;d.xAxis&&(d.eventsToUnbind.push(D(c,"resize",b)),b(),d.invertGroups=b)};a.prototype.plotGroup=function(a,d,c,e,h){var f=this[a],
g=!f;c={visibility:c,zIndex:e||.1};"undefined"===typeof this.opacity||this.chart.styledMode||"inactive"===this.state||(c.opacity=this.opacity);g&&(this[a]=f=this.chart.renderer.g().add(h));f.addClass("highcharts-"+d+" highcharts-series-"+this.index+" highcharts-"+this.type+"-series "+(b(this.colorIndex)?"highcharts-color-"+this.colorIndex+" ":"")+(this.options.className||"")+(f.hasClass("highcharts-tracker")?" highcharts-tracker":""),!0);f.attr(c)[g?"attr":"animate"](this.getPlotBox());return f};
a.prototype.getPlotBox=function(){var a=this.chart,b=this.xAxis,d=this.yAxis;a.inverted&&(b=d,d=this.xAxis);return{translateX:b?b.left:a.plotLeft,translateY:d?d.top:a.plotTop,scaleX:1,scaleY:1}};a.prototype.removeEvents=function(a){a||la(this);this.eventsToUnbind.length&&(this.eventsToUnbind.forEach(function(a){a()}),this.eventsToUnbind.length=0)};a.prototype.render=function(){var a=this,b=a.chart,d=a.options,e=c(d.animation),h=a.visible?"inherit":"hidden",f=d.zIndex,g=a.hasRendered,k=b.seriesGroup,
l=b.inverted,m=!a.finishedAnimating&&b.renderer.isSVG&&e.duration;F(this,"render");var p=a.plotGroup("group","series",h,f,k);a.markerGroup=a.plotGroup("markerGroup","markers",h,f,k);m&&a.animate&&a.animate(!0);p.inverted=K(a.invertible,a.isCartesian)?l:!1;a.drawGraph&&(a.drawGraph(),a.applyZones());a.visible&&a.drawPoints();a.drawDataLabels&&a.drawDataLabels();a.redrawPoints&&a.redrawPoints();a.drawTracker&&!1!==a.options.enableMouseTracking&&a.drawTracker();a.invertGroups(l);!1===d.clip||a.sharedClipKey||
g||p.clip(b.clipRect);m&&a.animate&&a.animate();g||(m&&e.defer&&(m+=e.defer),a.animationTimeout=R(function(){a.afterAnimate()},m||0));a.isDirty=!1;a.hasRendered=!0;F(a,"afterRender")};a.prototype.redraw=function(){var a=this.chart,b=this.isDirty||this.isDirtyData,d=this.group,c=this.xAxis,e=this.yAxis;d&&(a.inverted&&d.attr({width:a.plotWidth,height:a.plotHeight}),d.animate({translateX:K(c&&c.left,a.plotLeft),translateY:K(e&&e.top,a.plotTop)}));this.translate();this.render();b&&delete this.kdTree};
a.prototype.searchPoint=function(a,b){var d=this.xAxis,c=this.yAxis,e=this.chart.inverted;return this.searchKDTree({clientX:e?d.len-a.chartY+d.pos:a.chartX-d.pos,plotY:e?c.len-a.chartX+c.pos:a.chartY-c.pos},b,a)};a.prototype.buildKDTree=function(a){function b(a,c,e){var h=a&&a.length;if(h){var f=d.kdAxisArray[c%e];a.sort(function(a,b){return a[f]-b[f]});h=Math.floor(h/2);return{point:a[h],left:b(a.slice(0,h),c+1,e),right:b(a.slice(h+1),c+1,e)}}}this.buildingKdTree=!0;var d=this,c=-1<d.options.findNearestPointBy.indexOf("y")?
2:1;delete d.kdTree;R(function(){d.kdTree=b(d.getValidPoints(null,!d.directTouch),c,c);d.buildingKdTree=!1},d.options.kdNow||a&&"touchstart"===a.type?0:1)};a.prototype.searchKDTree=function(a,d,c){function e(a,d,c,l){var m=d.point,p=h.kdAxisArray[c%l],n=m,q=b(a[f])&&b(m[f])?Math.pow(a[f]-m[f],2):null;var t=b(a[g])&&b(m[g])?Math.pow(a[g]-m[g],2):null;t=(q||0)+(t||0);m.dist=b(t)?Math.sqrt(t):Number.MAX_VALUE;m.distX=b(q)?Math.sqrt(q):Number.MAX_VALUE;p=a[p]-m[p];t=0>p?"left":"right";q=0>p?"right":"left";
d[t]&&(t=e(a,d[t],c+1,l),n=t[k]<n[k]?t:m);d[q]&&Math.sqrt(p*p)<n[k]&&(a=e(a,d[q],c+1,l),n=a[k]<n[k]?a:n);return n}var h=this,f=this.kdAxisArray[0],g=this.kdAxisArray[1],k=d?"distX":"dist";d=-1<h.options.findNearestPointBy.indexOf("y")?2:1;this.kdTree||this.buildingKdTree||this.buildKDTree(c);if(this.kdTree)return e(a,this.kdTree,d,d)};a.prototype.pointPlacementToXValue=function(){var a=this.options,b=a.pointRange,d=this.xAxis;a=a.pointPlacement;"between"===a&&(a=d.reversed?-.5:.5);return Q(a)?a*(b||
d.pointRange):0};a.prototype.isPointInside=function(a){return"undefined"!==typeof a.plotY&&"undefined"!==typeof a.plotX&&0<=a.plotY&&a.plotY<=this.yAxis.len&&0<=a.plotX&&a.plotX<=this.xAxis.len};a.prototype.drawTracker=function(){var a=this,b=a.options,d=b.trackByArea,c=[].concat(d?a.areaPath:a.graphPath),e=a.chart,h=e.pointer,f=e.renderer,g=e.options.tooltip.snap,k=a.tracker,l=function(b){if(e.hoverSeries!==a)a.onMouseOver()},m="rgba(192,192,192,"+(q?.0001:.002)+")";k?k.attr({d:c}):a.graph&&(a.tracker=
f.path(c).attr({visibility:a.visible?"visible":"hidden",zIndex:2}).addClass(d?"highcharts-tracker-area":"highcharts-tracker-line").add(a.group),e.styledMode||a.tracker.attr({"stroke-linecap":"round","stroke-linejoin":"round",stroke:m,fill:d?m:"none","stroke-width":a.graph.strokeWidth()+(d?0:2*g)}),[a.tracker,a.markerGroup,a.dataLabelsGroup].forEach(function(a){if(a&&(a.addClass("highcharts-tracker").on("mouseover",l).on("mouseout",function(a){h.onTrackerMouseOut(a)}),b.cursor&&!e.styledMode&&a.css({cursor:b.cursor}),
v))a.on("touchstart",l)}));F(this,"afterDrawTracker")};a.prototype.addPoint=function(a,b,d,c,e){var h=this.options,f=this.data,g=this.chart,k=this.xAxis;k=k&&k.hasNames&&k.names;var l=h.data,m=this.xData,p;b=K(b,!0);var n={series:this};this.pointClass.prototype.applyOptions.apply(n,[a]);var q=n.x;var t=m.length;if(this.requireSorting&&q<m[t-1])for(p=!0;t&&m[t-1]>q;)t--;this.updateParallelArrays(n,"splice",t,0,0);this.updateParallelArrays(n,t);k&&n.name&&(k[q]=n.name);l.splice(t,0,a);p&&(this.data.splice(t,
0,null),this.processData());"point"===h.legendType&&this.generatePoints();d&&(f[0]&&f[0].remove?f[0].remove(!1):(f.shift(),this.updateParallelArrays(n,"shift"),l.shift()));!1!==e&&F(this,"addPoint",{point:n});this.isDirtyData=this.isDirty=!0;b&&g.redraw(c)};a.prototype.removePoint=function(a,b,d){var c=this,h=c.data,f=h[a],g=c.points,k=c.chart,l=function(){g&&g.length===h.length&&g.splice(a,1);h.splice(a,1);c.options.data.splice(a,1);c.updateParallelArrays(f||{series:c},"splice",a,1);f&&f.destroy();
c.isDirty=!0;c.isDirtyData=!0;b&&k.redraw()};e(d,k);b=K(b,!0);f?f.firePointEvent("remove",null,l):l()};a.prototype.remove=function(a,b,d,c){function e(){h.destroy(c);f.isDirtyLegend=f.isDirtyBox=!0;f.linkSeries();K(a,!0)&&f.redraw(b)}var h=this,f=h.chart;!1!==d?F(h,"remove",null,e):e()};a.prototype.update=function(a,b){a=h(a,this.userOptions);F(this,"update",{options:a});var d=this,c=d.chart,e=d.userOptions,f=d.initialType||d.type,g=c.options.plotOptions,k=r[f].prototype,l=d.finishedAnimating&&{animation:!1},
m={},p,n=["eventOptions","navigatorSeries","baseSeries"],q=a.type||e.type||c.options.chart.type,t=!(this.hasDerivedData||q&&q!==this.type||"undefined"!==typeof a.pointStart||"undefined"!==typeof a.pointInterval||"undefined"!==typeof a.relativeXValue||d.hasOptionChanged("dataGrouping")||d.hasOptionChanged("pointStart")||d.hasOptionChanged("pointInterval")||d.hasOptionChanged("pointIntervalUnit")||d.hasOptionChanged("keys"));q=q||f;t&&(n.push("data","isDirtyData","points","processedXData","processedYData",
"xIncrement","cropped","_hasPointMarkers","_hasPointLabels","clips","nodes","layout","mapMap","mapData","minY","maxY","minX","maxX"),!1!==a.visible&&n.push("area","graph"),d.parallelArrays.forEach(function(a){n.push(a+"Data")}),a.data&&(a.dataSorting&&y(d.options.dataSorting,a.dataSorting),this.setData(a.data,!1)));a=M(e,l,{index:"undefined"===typeof e.index?d.index:e.index,pointStart:K(g&&g.series&&g.series.pointStart,e.pointStart,d.xData[0])},!t&&{data:d.options.data},a);t&&a.data&&(a.data=d.options.data);
n=["group","markerGroup","dataLabelsGroup","transformGroup"].concat(n);n.forEach(function(a){n[a]=d[a];delete d[a]});g=!1;if(r[q]){if(g=q!==d.type,d.remove(!1,!1,!1,!0),g)if(Object.setPrototypeOf)Object.setPrototypeOf(d,r[q].prototype);else{l=Object.hasOwnProperty.call(d,"hcEvents")&&d.hcEvents;for(p in k)d[p]=void 0;y(d,r[q].prototype);l?d.hcEvents=l:delete d.hcEvents}}else G(17,!0,c,{missingModuleFor:q});n.forEach(function(a){d[a]=n[a]});d.init(c,a);if(t&&this.points){var v=d.options;!1===v.visible?
(m.graphic=1,m.dataLabel=1):d._hasPointLabels||(a=v.marker,k=v.dataLabels,!a||!1!==a.enabled&&(e.marker&&e.marker.symbol)===a.symbol||(m.graphic=1),k&&!1===k.enabled&&(m.dataLabel=1));this.points.forEach(function(a){a&&a.series&&(a.resolveColor(),Object.keys(m).length&&a.destroyElements(m),!1===v.showInLegend&&a.legendItem&&c.legend.destroyItem(a))},this)}d.initialType=f;c.linkSeries();g&&d.linkedSeries.length&&(d.isDirtyData=!0);F(this,"afterUpdate");K(b,!0)&&c.redraw(t?void 0:!1)};a.prototype.setName=
function(a){this.name=this.options.name=this.userOptions.name=a;this.chart.isDirtyLegend=!0};a.prototype.hasOptionChanged=function(a){var b=this.options[a],d=this.chart.options.plotOptions,c=this.userOptions[a];return c?b!==c:b!==K(d&&d[this.type]&&d[this.type][a],d&&d.series&&d.series[a],b)};a.prototype.onMouseOver=function(){var a=this.chart,b=a.hoverSeries;a.pointer.setHoverChartIndex();if(b&&b!==this)b.onMouseOut();this.options.events.mouseOver&&F(this,"mouseOver");this.setState("hover");a.hoverSeries=
this};a.prototype.onMouseOut=function(){var a=this.options,b=this.chart,d=b.tooltip,c=b.hoverPoint;b.hoverSeries=null;if(c)c.onMouseOut();this&&a.events.mouseOut&&F(this,"mouseOut");!d||this.stickyTracking||d.shared&&!this.noSharedTooltip||d.hide();b.series.forEach(function(a){a.setState("",!0)})};a.prototype.setState=function(a,b){var d=this,c=d.options,e=d.graph,h=c.inactiveOtherPoints,f=c.states,g=K(f[a||"normal"]&&f[a||"normal"].animation,d.chart.options.chart.animation),k=c.lineWidth,l=0,m=c.opacity;
a=a||"";if(d.state!==a&&([d.group,d.markerGroup,d.dataLabelsGroup].forEach(function(b){b&&(d.state&&b.removeClass("highcharts-series-"+d.state),a&&b.addClass("highcharts-series-"+a))}),d.state=a,!d.chart.styledMode)){if(f[a]&&!1===f[a].enabled)return;a&&(k=f[a].lineWidth||k+(f[a].lineWidthPlus||0),m=K(f[a].opacity,m));if(e&&!e.dashstyle)for(c={"stroke-width":k},e.animate(c,g);d["zone-graph-"+l];)d["zone-graph-"+l].animate(c,g),l+=1;h||[d.group,d.markerGroup,d.dataLabelsGroup,d.labelBySeries].forEach(function(a){a&&
a.animate({opacity:m},g)})}b&&h&&d.points&&d.setAllPointsToState(a||void 0)};a.prototype.setAllPointsToState=function(a){this.points.forEach(function(b){b.setState&&b.setState(a)})};a.prototype.setVisible=function(a,b){var d=this,c=d.chart,e=d.legendItem,h=c.options.chart.ignoreHiddenSeries,f=d.visible,g=(d.visible=a=d.options.visible=d.userOptions.visible="undefined"===typeof a?!f:a)?"show":"hide";["group","dataLabelsGroup","markerGroup","tracker","tt"].forEach(function(a){if(d[a])d[a][g]()});if(c.hoverSeries===
d||(c.hoverPoint&&c.hoverPoint.series)===d)d.onMouseOut();e&&c.legend.colorizeItem(d,a);d.isDirty=!0;d.options.stacking&&c.series.forEach(function(a){a.options.stacking&&a.visible&&(a.isDirty=!0)});d.linkedSeries.forEach(function(b){b.setVisible(a,!1)});h&&(c.isDirtyBox=!0);F(d,g);!1!==b&&c.redraw()};a.prototype.show=function(){this.setVisible(!0)};a.prototype.hide=function(){this.setVisible(!1)};a.prototype.select=function(a){this.selected=a=this.options.selected="undefined"===typeof a?!this.selected:
a;this.checkbox&&(this.checkbox.checked=a);F(this,a?"select":"unselect")};a.prototype.shouldShowTooltip=function(a,b,d){void 0===d&&(d={});d.series=this;d.visiblePlotOnly=!0;return this.chart.isInsidePlot(a,b,d)};a.defaultOptions=u;return a}();y(a.prototype,{axisTypes:["xAxis","yAxis"],coll:"series",colorCounter:0,cropShoulder:1,directTouch:!1,drawLegendSymbol:z.drawLineMarker,isCartesian:!0,kdAxisArray:["clientX","plotY"],parallelArrays:["x","y"],pointClass:J,requireSorting:!0,sorted:!0});n.series=
a;"";"";return a});M(a,"Extensions/ScrollablePlotArea.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Axis/Axis.js"],a["Core/Chart/Chart.js"],a["Core/Series/Series.js"],a["Core/Renderer/RendererRegistry.js"],a["Core/Utilities.js"]],function(a,w,C,E,z,x){var r=a.stop,u=x.addEvent,n=x.createElement,m=x.merge,g=x.pick;u(C,"afterSetChartSize",function(a){var c=this.options.chart.scrollablePlotArea,g=c&&c.minWidth;c=c&&c.minHeight;if(!this.renderer.forExport){if(g){if(this.scrollablePixelsX=g=Math.max(0,
g-this.chartWidth)){this.scrollablePlotBox=this.renderer.scrollablePlotBox=m(this.plotBox);this.plotBox.width=this.plotWidth+=g;this.inverted?this.clipBox.height+=g:this.clipBox.width+=g;var f={1:{name:"right",value:g}}}}else c&&(this.scrollablePixelsY=g=Math.max(0,c-this.chartHeight))&&(this.scrollablePlotBox=this.renderer.scrollablePlotBox=m(this.plotBox),this.plotBox.height=this.plotHeight+=g,this.inverted?this.clipBox.width+=g:this.clipBox.height+=g,f={2:{name:"bottom",value:g}});f&&!a.skipAxes&&
this.axes.forEach(function(a){f[a.side]?a.getPlotLinePath=function(){var c=f[a.side].name,e=this[c];this[c]=e-f[a.side].value;var g=w.prototype.getPlotLinePath.apply(this,arguments);this[c]=e;return g}:(a.setAxisSize(),a.setAxisTranslation())})}});u(C,"render",function(){this.scrollablePixelsX||this.scrollablePixelsY?(this.setUpScrolling&&this.setUpScrolling(),this.applyFixed()):this.fixedDiv&&this.applyFixed()});C.prototype.setUpScrolling=function(){var a=this,e={WebkitOverflowScrolling:"touch",
overflowX:"hidden",overflowY:"hidden"};this.scrollablePixelsX&&(e.overflowX="auto");this.scrollablePixelsY&&(e.overflowY="auto");this.scrollingParent=n("div",{className:"highcharts-scrolling-parent"},{position:"relative"},this.renderTo);this.scrollingContainer=n("div",{className:"highcharts-scrolling"},e,this.scrollingParent);u(this.scrollingContainer,"scroll",function(){a.pointer&&delete a.pointer.chartPosition});this.innerContainer=n("div",{className:"highcharts-inner-container"},null,this.scrollingContainer);
this.innerContainer.appendChild(this.container);this.setUpScrolling=null};C.prototype.moveFixedElements=function(){var a=this.container,e=this.fixedRenderer,g=".highcharts-contextbutton .highcharts-credits .highcharts-legend .highcharts-legend-checkbox .highcharts-navigator-series .highcharts-navigator-xaxis .highcharts-navigator-yaxis .highcharts-navigator .highcharts-reset-zoom .highcharts-drillup-button .highcharts-scrollbar .highcharts-subtitle .highcharts-title".split(" "),f;this.scrollablePixelsX&&
!this.inverted?f=".highcharts-yaxis":this.scrollablePixelsX&&this.inverted?f=".highcharts-xaxis":this.scrollablePixelsY&&!this.inverted?f=".highcharts-xaxis":this.scrollablePixelsY&&this.inverted&&(f=".highcharts-yaxis");f&&g.push(f+":not(.highcharts-radial-axis)",f+"-labels:not(.highcharts-radial-axis-labels)");g.forEach(function(c){[].forEach.call(a.querySelectorAll(c),function(a){(a.namespaceURI===e.SVG_NS?e.box:e.box.parentNode).appendChild(a);a.style.pointerEvents="auto"})})};C.prototype.applyFixed=
function(){var a=!this.fixedDiv,e=this.options.chart,l=e.scrollablePlotArea,f=z.getRendererType();a?(this.fixedDiv=n("div",{className:"highcharts-fixed"},{position:"absolute",overflow:"hidden",pointerEvents:"none",zIndex:(e.style&&e.style.zIndex||0)+2,top:0},null,!0),this.scrollingContainer&&this.scrollingContainer.parentNode.insertBefore(this.fixedDiv,this.scrollingContainer),this.renderTo.style.overflow="visible",this.fixedRenderer=e=new f(this.fixedDiv,this.chartWidth,this.chartHeight,this.options.chart.style),
this.scrollableMask=e.path().attr({fill:this.options.chart.backgroundColor||"#fff","fill-opacity":g(l.opacity,.85),zIndex:-1}).addClass("highcharts-scrollable-mask").add(),u(this,"afterShowResetZoom",this.moveFixedElements),u(this,"afterDrilldown",this.moveFixedElements),u(this,"afterLayOutTitles",this.moveFixedElements)):this.fixedRenderer.setSize(this.chartWidth,this.chartHeight);if(this.scrollableDirty||a)this.scrollableDirty=!1,this.moveFixedElements();e=this.chartWidth+(this.scrollablePixelsX||
0);f=this.chartHeight+(this.scrollablePixelsY||0);r(this.container);this.container.style.width=e+"px";this.container.style.height=f+"px";this.renderer.boxWrapper.attr({width:e,height:f,viewBox:[0,0,e,f].join(" ")});this.chartBackground.attr({width:e,height:f});this.scrollingContainer.style.height=this.chartHeight+"px";a&&(l.scrollPositionX&&(this.scrollingContainer.scrollLeft=this.scrollablePixelsX*l.scrollPositionX),l.scrollPositionY&&(this.scrollingContainer.scrollTop=this.scrollablePixelsY*l.scrollPositionY));
f=this.axisOffset;a=this.plotTop-f[0]-1;l=this.plotLeft-f[3]-1;e=this.plotTop+this.plotHeight+f[2]+1;f=this.plotLeft+this.plotWidth+f[1]+1;var m=this.plotLeft+this.plotWidth-(this.scrollablePixelsX||0),q=this.plotTop+this.plotHeight-(this.scrollablePixelsY||0);a=this.scrollablePixelsX?[["M",0,a],["L",this.plotLeft-1,a],["L",this.plotLeft-1,e],["L",0,e],["Z"],["M",m,a],["L",this.chartWidth,a],["L",this.chartWidth,e],["L",m,e],["Z"]]:this.scrollablePixelsY?[["M",l,0],["L",l,this.plotTop-1],["L",f,this.plotTop-
1],["L",f,0],["Z"],["M",l,q],["L",l,this.chartHeight],["L",f,this.chartHeight],["L",f,q],["Z"]]:[["M",0,0]];"adjustHeight"!==this.redrawTrigger&&this.scrollableMask.attr({d:a})};u(w,"afterInit",function(){this.chart.scrollableDirty=!0});u(E,"show",function(){this.chart.scrollableDirty=!0});""});M(a,"Core/Axis/StackingAxis.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Axis/Axis.js"],a["Core/Utilities.js"]],function(a,w,C){var r=a.getDeferredAnimation,z=C.addEvent,x=C.destroyObjectProperties,
J=C.fireEvent,u=C.isNumber,n=C.objectEach,m;(function(a){function c(){var a=this.stacking;if(a){var c=a.stacks;n(c,function(a,e){x(a);c[e]=null});a&&a.stackTotalGroup&&a.stackTotalGroup.destroy()}}function e(){this.stacking||(this.stacking=new f(this))}var g=[];a.compose=function(a){-1===g.indexOf(a)&&(g.push(a),z(a,"init",e),z(a,"destroy",c));return a};var f=function(){function a(a){this.oldStacks={};this.stacks={};this.stacksTouched=0;this.axis=a}a.prototype.buildStacks=function(){var a=this.axis,
c=a.series,e=a.options.reversedStacks,f=c.length,g;if(!a.isXAxis){this.usePercentage=!1;for(g=f;g--;){var l=c[e?g:f-g-1];l.setStackedPoints();l.setGroupedPoints()}for(g=0;g<f;g++)c[g].modifyStacks();J(a,"afterBuildStacks")}};a.prototype.cleanStacks=function(){if(!this.axis.isXAxis){if(this.oldStacks)var a=this.stacks=this.oldStacks;n(a,function(a){n(a,function(a){a.cumulative=a.total})})}};a.prototype.resetStacks=function(){var a=this,c=a.stacks;a.axis.isXAxis||n(c,function(c){n(c,function(e,f){u(e.touched)&&
e.touched<a.stacksTouched?(e.destroy(),delete c[f]):(e.total=null,e.cumulative=null)})})};a.prototype.renderStackTotals=function(){var a=this.axis,c=a.chart,e=c.renderer,f=this.stacks;a=r(c,a.options.stackLabels&&a.options.stackLabels.animation||!1);var g=this.stackTotalGroup=this.stackTotalGroup||e.g("stack-labels").attr({visibility:"visible",zIndex:6,opacity:0}).add();g.translate(c.plotLeft,c.plotTop);n(f,function(a){n(a,function(a){a.render(g)})});g.animate({opacity:1},a)};return a}();a.Additions=
f})(m||(m={}));return m});M(a,"Extensions/Stacking.js",[a["Core/Axis/Axis.js"],a["Core/Chart/Chart.js"],a["Core/FormatUtilities.js"],a["Core/Globals.js"],a["Core/Series/Series.js"],a["Core/Axis/StackingAxis.js"],a["Core/Utilities.js"]],function(a,w,C,E,z,x,J){var r=C.format,n=J.correctFloat,m=J.defined,g=J.destroyObjectProperties,c=J.isArray,e=J.isNumber,l=J.objectEach,f=J.pick,v=function(){function a(a,c,e,f,g){var k=a.chart.inverted;this.axis=a;this.isNegative=e;this.options=c=c||{};this.x=f;this.total=
null;this.points={};this.hasValidPoints=!1;this.stack=g;this.rightCliff=this.leftCliff=0;this.alignOptions={align:c.align||(k?e?"left":"right":"center"),verticalAlign:c.verticalAlign||(k?"middle":e?"bottom":"top"),y:c.y,x:c.x};this.textAlign=c.textAlign||(k?e?"right":"left":"center")}a.prototype.destroy=function(){g(this,this.axis)};a.prototype.render=function(a){var c=this.axis.chart,e=this.options,g=e.format;g=g?r(g,this,c):e.formatter.call(this);this.label?this.label.attr({text:g,visibility:"hidden"}):
(this.label=c.renderer.label(g,null,null,e.shape,null,null,e.useHTML,!1,"stack-labels"),g={r:e.borderRadius||0,text:g,rotation:e.rotation,padding:f(e.padding,5),visibility:"hidden"},c.styledMode||(g.fill=e.backgroundColor,g.stroke=e.borderColor,g["stroke-width"]=e.borderWidth,this.label.css(e.style)),this.label.attr(g),this.label.added||this.label.add(a));this.label.labelrank=c.plotSizeY};a.prototype.setOffset=function(a,c,g,l,n){var k=this.axis,h=k.chart;l=k.translate(k.stacking.usePercentage?100:
l?l:this.total,0,0,0,1);g=k.translate(g?g:0);g=m(l)&&Math.abs(l-g);a=f(n,h.xAxis[0].translate(this.x))+a;k=m(l)&&this.getStackBox(h,this,a,l,c,g,k);c=this.label;g=this.isNegative;a="justify"===f(this.options.overflow,"justify");var d=this.textAlign;c&&k&&(n=c.getBBox(),l=c.padding,d="left"===d?h.inverted?-l:l:"right"===d?n.width:h.inverted&&"center"===d?n.width/2:h.inverted?g?n.width+l:-l:n.width/2,g=h.inverted?n.height/2:g?-l:n.height,this.alignOptions.x=f(this.options.x,0),this.alignOptions.y=f(this.options.y,
0),k.x-=d,k.y-=g,c.align(this.alignOptions,null,k),h.isInsidePlot(c.alignAttr.x+d-this.alignOptions.x,c.alignAttr.y+g-this.alignOptions.y)?c.show():(c.alignAttr.y=-9999,a=!1),a&&z.prototype.justifyDataLabel.call(this.axis,c,this.alignOptions,c.alignAttr,n,k),c.attr({x:c.alignAttr.x,y:c.alignAttr.y}),f(!a&&this.options.crop,!0)&&((h=e(c.x)&&e(c.y)&&h.isInsidePlot(c.x-l+c.width,c.y)&&h.isInsidePlot(c.x+l,c.y))||c.hide()))};a.prototype.getStackBox=function(a,c,e,f,g,l,h){var d=c.axis.reversed,b=a.inverted,
k=h.height+h.pos-(b?a.plotLeft:a.plotTop);c=c.isNegative&&!d||!c.isNegative&&d;return{x:b?c?f-h.right:f-l+h.pos-a.plotLeft:e+a.xAxis[0].transB-a.plotLeft,y:b?h.height-e-g:c?k-f-l:k-f,width:b?l:g,height:b?g:l}};return a}();w.prototype.getStacks=function(){var a=this,c=a.inverted;a.yAxis.forEach(function(a){a.stacking&&a.stacking.stacks&&a.hasVisibleSeries&&(a.stacking.oldStacks=a.stacking.stacks)});a.series.forEach(function(e){var g=e.xAxis&&e.xAxis.options||{};!e.options.stacking||!0!==e.visible&&
!1!==a.options.chart.ignoreHiddenSeries||(e.stackKey=[e.type,f(e.options.stack,""),c?g.top:g.left,c?g.height:g.width].join())})};x.compose(a);z.prototype.setGroupedPoints=function(){var a=this.yAxis.stacking;this.options.centerInCategory&&(this.is("column")||this.is("columnrange"))&&!this.options.stacking&&1<this.chart.series.length?z.prototype.setStackedPoints.call(this,"group"):a&&l(a.stacks,function(c,e){"group"===e.slice(-5)&&(l(c,function(a){return a.destroy()}),delete a.stacks[e])})};z.prototype.setStackedPoints=
function(a){var e=a||this.options.stacking;if(e&&(!0===this.visible||!1===this.chart.options.chart.ignoreHiddenSeries)){var g=this.processedXData,l=this.processedYData,q=[],r=l.length,t=this.options,h=t.threshold,d=f(t.startFromThreshold&&h,0);t=t.stack;a=a?this.type+","+e:this.stackKey;var b="-"+a,p=this.negStacks,u=this.yAxis,y=u.stacking.stacks,x=u.stacking.oldStacks,F,w;u.stacking.stacksTouched+=1;for(w=0;w<r;w++){var z=g[w];var C=l[w];var E=this.getStackIndicator(E,z,this.index);var J=E.key;
var H=(F=p&&C<(d?0:h))?b:a;y[H]||(y[H]={});y[H][z]||(x[H]&&x[H][z]?(y[H][z]=x[H][z],y[H][z].total=null):y[H][z]=new v(u,u.options.stackLabels,F,z,t));H=y[H][z];null!==C?(H.points[J]=H.points[this.index]=[f(H.cumulative,d)],m(H.cumulative)||(H.base=J),H.touched=u.stacking.stacksTouched,0<E.index&&!1===this.singleStacks&&(H.points[J][0]=H.points[this.index+","+z+",0"][0])):H.points[J]=H.points[this.index]=null;"percent"===e?(F=F?a:b,p&&y[F]&&y[F][z]?(F=y[F][z],H.total=F.total=Math.max(F.total,H.total)+
Math.abs(C)||0):H.total=n(H.total+(Math.abs(C)||0))):"group"===e?(c(C)&&(C=C[0]),null!==C&&(H.total=(H.total||0)+1)):H.total=n(H.total+(C||0));H.cumulative="group"===e?(H.total||1)-1:f(H.cumulative,d)+(C||0);null!==C&&(H.points[J].push(H.cumulative),q[w]=H.cumulative,H.hasValidPoints=!0)}"percent"===e&&(u.stacking.usePercentage=!0);"group"!==e&&(this.stackedYData=q);u.stacking.oldStacks={}}};z.prototype.modifyStacks=function(){var a=this,c=a.stackKey,e=a.yAxis.stacking.stacks,f=a.processedXData,g,
l=a.options.stacking;a[l+"Stacker"]&&[c,"-"+c].forEach(function(c){for(var h=f.length,d,b;h--;)if(d=f[h],g=a.getStackIndicator(g,d,a.index,c),b=(d=e[c]&&e[c][d])&&d.points[g.key])a[l+"Stacker"](b,d,h)})};z.prototype.percentStacker=function(a,c,e){c=c.total?100/c.total:0;a[0]=n(a[0]*c);a[1]=n(a[1]*c);this.stackedYData[e]=a[1]};z.prototype.getStackIndicator=function(a,c,e,f){!m(a)||a.x!==c||f&&a.key!==f?a={x:c,index:0,key:f}:a.index++;a.key=[e,c,a.index].join();return a};E.StackItem=v;"";return E.StackItem});
M(a,"Series/Line/LineSeries.js",[a["Core/Color/Palette.js"],a["Core/Series/Series.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(a,w,C,E){var r=this&&this.__extends||function(){var a=function(n,m){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,c){a.__proto__=c}||function(a,c){for(var e in c)c.hasOwnProperty(e)&&(a[e]=c[e])};return a(n,m)};return function(n,m){function g(){this.constructor=n}a(n,m);n.prototype=null===m?Object.create(m):(g.prototype=m.prototype,
new g)}}(),x=E.defined,J=E.merge;E=function(u){function n(){var a=null!==u&&u.apply(this,arguments)||this;a.data=void 0;a.options=void 0;a.points=void 0;return a}r(n,u);n.prototype.drawGraph=function(){var m=this,g=this.options,c=(this.gappedPath||this.getGraphPath).call(this),e=this.chart.styledMode,l=[["graph","highcharts-graph"]];e||l[0].push(g.lineColor||this.color||a.neutralColor20,g.dashStyle);l=m.getZonesGraphs(l);l.forEach(function(a,l){var f=a[0],k=m[f],n=k?"animate":"attr";k?(k.endX=m.preventGraphAnimation?
null:c.xMap,k.animate({d:c})):c.length&&(m[f]=k=m.chart.renderer.path(c).addClass(a[1]).attr({zIndex:1}).add(m.group));k&&!e&&(f={stroke:a[2],"stroke-width":g.lineWidth,fill:m.fillGraph&&m.color||"none"},a[3]?f.dashstyle=a[3]:"square"!==g.linecap&&(f["stroke-linecap"]=f["stroke-linejoin"]="round"),k[n](f).shadow(2>l&&g.shadow));k&&(k.startX=c.xMap,k.isArea=c.isArea)})};n.prototype.getGraphPath=function(a,g,c){var e=this,l=e.options,f=[],m=[],n,k=l.step;a=a||e.points;var r=a.reversed;r&&a.reverse();
(k={right:1,center:2}[k]||k&&3)&&r&&(k=4-k);a=this.getValidPoints(a,!1,!(l.connectNulls&&!g&&!c));a.forEach(function(q,r){var v=q.plotX,t=q.plotY,h=a[r-1];(q.leftCliff||h&&h.rightCliff)&&!c&&(n=!0);q.isNull&&!x(g)&&0<r?n=!l.connectNulls:q.isNull&&!g?n=!0:(0===r||n?r=[["M",q.plotX,q.plotY]]:e.getPointSpline?r=[e.getPointSpline(a,q,r)]:k?(r=1===k?[["L",h.plotX,t]]:2===k?[["L",(h.plotX+v)/2,h.plotY],["L",(h.plotX+v)/2,t]]:[["L",v,h.plotY]],r.push(["L",v,t])):r=[["L",v,t]],m.push(q.x),k&&(m.push(q.x),
2===k&&m.push(q.x)),f.push.apply(f,r),n=!1)});f.xMap=m;return e.graphPath=f};n.prototype.getZonesGraphs=function(a){this.zones.forEach(function(g,c){c=["zone-graph-"+c,"highcharts-graph highcharts-zone-graph-"+c+" "+(g.className||"")];this.chart.styledMode||c.push(g.color||this.color,g.dashStyle||this.options.dashStyle);a.push(c)},this);return a};n.defaultOptions=J(w.defaultOptions,{});return n}(w);C.registerSeriesType("line",E);"";return E});M(a,"Series/Area/AreaSeries.js",[a["Core/Color/Color.js"],
a["Core/Legend/LegendSymbol.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(a,w,C,E){var r=this&&this.__extends||function(){var a=function(c,e){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,c){a.__proto__=c}||function(a,c){for(var e in c)c.hasOwnProperty(e)&&(a[e]=c[e])};return a(c,e)};return function(c,e){function g(){this.constructor=c}a(c,e);c.prototype=null===e?Object.create(e):(g.prototype=e.prototype,new g)}}(),x=a.parse,J=C.seriesTypes.line;a=
E.extend;var u=E.merge,n=E.objectEach,m=E.pick;E=function(a){function c(){var c=null!==a&&a.apply(this,arguments)||this;c.data=void 0;c.options=void 0;c.points=void 0;return c}r(c,a);c.prototype.drawGraph=function(){this.areaPath=[];a.prototype.drawGraph.apply(this);var c=this,g=this.areaPath,f=this.options,n=[["area","highcharts-area",this.color,f.fillColor]];this.zones.forEach(function(a,e){n.push(["zone-area-"+e,"highcharts-area highcharts-zone-area-"+e+" "+a.className,a.color||c.color,a.fillColor||
f.fillColor])});n.forEach(function(a){var e=a[0],l=c[e],n=l?"animate":"attr",q={};l?(l.endX=c.preventGraphAnimation?null:g.xMap,l.animate({d:g})):(q.zIndex=0,l=c[e]=c.chart.renderer.path(g).addClass(a[1]).add(c.group),l.isArea=!0);c.chart.styledMode||(q.fill=m(a[3],x(a[2]).setOpacity(m(f.fillOpacity,.75)).get()));l[n](q);l.startX=g.xMap;l.shiftUnit=f.step?2:1})};c.prototype.getGraphPath=function(a){var c=J.prototype.getGraphPath,e=this.options,g=e.stacking,n=this.yAxis,k,r=[],u=[],B=this.index,x=
n.stacking.stacks[this.stackKey],t=e.threshold,h=Math.round(n.getThreshold(e.threshold));e=m(e.connectNulls,"percent"===g);var d=function(b,d,c){var e=a[b];b=g&&x[e.x].points[B];var f=e[c+"Null"]||0;c=e[c+"Cliff"]||0;e=!0;if(c||f){var k=(f?b[0]:b[1])+c;var l=b[0]+c;e=!!f}else!g&&a[d]&&a[d].isNull&&(k=l=t);"undefined"!==typeof k&&(u.push({plotX:p,plotY:null===k?h:n.getThreshold(k),isNull:e,isCliff:!0}),r.push({plotX:p,plotY:null===l?h:n.getThreshold(l),doCurve:!1}))};a=a||this.points;g&&(a=this.getStackPoints(a));
for(k=0;k<a.length;k++){g||(a[k].leftCliff=a[k].rightCliff=a[k].leftNull=a[k].rightNull=void 0);var b=a[k].isNull;var p=m(a[k].rectPlotX,a[k].plotX);var G=g?m(a[k].yBottom,h):h;if(!b||e)e||d(k,k-1,"left"),b&&!g&&e||(u.push(a[k]),r.push({x:k,plotX:p,plotY:G})),e||d(k,k+1,"right")}k=c.call(this,u,!0,!0);r.reversed=!0;b=c.call(this,r,!0,!0);(G=b[0])&&"M"===G[0]&&(b[0]=["L",G[1],G[2]]);b=k.concat(b);b.length&&b.push(["Z"]);c=c.call(this,u,!1,e);b.xMap=k.xMap;this.areaPath=b;return c};c.prototype.getStackPoints=
function(a){var c=this,e=[],g=[],r=this.xAxis,k=this.yAxis,u=k.stacking.stacks[this.stackKey],x={},B=k.series,w=B.length,t=k.options.reversedStacks?1:-1,h=B.indexOf(c);a=a||this.points;if(this.options.stacking){for(var d=0;d<a.length;d++)a[d].leftNull=a[d].rightNull=void 0,x[a[d].x]=a[d];n(u,function(a,b){null!==a.total&&g.push(b)});g.sort(function(a,b){return a-b});var b=B.map(function(a){return a.visible});g.forEach(function(a,d){var f=0,l,n;if(x[a]&&!x[a].isNull)e.push(x[a]),[-1,1].forEach(function(e){var f=
1===e?"rightNull":"leftNull",k=0,m=u[g[d+e]];if(m)for(var p=h;0<=p&&p<w;){var r=B[p].index;l=m.points[r];l||(r===c.index?x[a][f]=!0:b[p]&&(n=u[a].points[r])&&(k-=n[1]-n[0]));p+=t}x[a][1===e?"rightCliff":"leftCliff"]=k});else{for(var p=h;0<=p&&p<w;){if(l=u[a].points[B[p].index]){f=l[1];break}p+=t}f=m(f,0);f=k.translate(f,0,1,0,1);e.push({isNull:!0,plotX:r.translate(a,0,0,0,1),x:a,plotY:f,yBottom:f})}})}return e};c.defaultOptions=u(J.defaultOptions,{threshold:0});return c}(J);a(E.prototype,{singleStacks:!1,
drawLegendSymbol:w.drawRectangle});C.registerSeriesType("area",E);"";return E});M(a,"Series/Spline/SplineSeries.js",[a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(a,w){var r=this&&this.__extends||function(){var a=function(r,n){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,g){a.__proto__=g}||function(a,g){for(var c in g)g.hasOwnProperty(c)&&(a[c]=g[c])};return a(r,n)};return function(r,n){function m(){this.constructor=r}a(r,n);r.prototype=null===n?Object.create(n):
(m.prototype=n.prototype,new m)}}(),E=a.seriesTypes.line,z=w.merge,x=w.pick;w=function(a){function u(){var n=null!==a&&a.apply(this,arguments)||this;n.data=void 0;n.options=void 0;n.points=void 0;return n}r(u,a);u.prototype.getPointSpline=function(a,m,g){var c=m.plotX||0,e=m.plotY||0,l=a[g-1];g=a[g+1];if(l&&!l.isNull&&!1!==l.doCurve&&!m.isCliff&&g&&!g.isNull&&!1!==g.doCurve&&!m.isCliff){a=l.plotY||0;var f=g.plotX||0;g=g.plotY||0;var n=0;var r=(1.5*c+(l.plotX||0))/2.5;var k=(1.5*e+a)/2.5;f=(1.5*c+
f)/2.5;var u=(1.5*e+g)/2.5;f!==r&&(n=(u-k)*(f-c)/(f-r)+e-u);k+=n;u+=n;k>a&&k>e?(k=Math.max(a,e),u=2*e-k):k<a&&k<e&&(k=Math.min(a,e),u=2*e-k);u>g&&u>e?(u=Math.max(g,e),k=2*e-u):u<g&&u<e&&(u=Math.min(g,e),k=2*e-u);m.rightContX=f;m.rightContY=u}m=["C",x(l.rightContX,l.plotX,0),x(l.rightContY,l.plotY,0),x(r,c,0),x(k,e,0),c,e];l.rightContX=l.rightContY=void 0;return m};u.defaultOptions=z(E.defaultOptions);return u}(E);a.registerSeriesType("spline",w);"";return w});M(a,"Series/AreaSpline/AreaSplineSeries.js",
[a["Series/Area/AreaSeries.js"],a["Series/Spline/SplineSeries.js"],a["Core/Legend/LegendSymbol.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(a,w,C,E,z){var r=this&&this.__extends||function(){var a=function(g,c){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,c){a.__proto__=c}||function(a,c){for(var e in c)c.hasOwnProperty(e)&&(a[e]=c[e])};return a(g,c)};return function(g,c){function e(){this.constructor=g}a(g,c);g.prototype=null===c?Object.create(c):
(e.prototype=c.prototype,new e)}}(),J=a.prototype,u=z.extend,n=z.merge;z=function(m){function g(){var a=null!==m&&m.apply(this,arguments)||this;a.data=void 0;a.points=void 0;a.options=void 0;return a}r(g,m);g.defaultOptions=n(w.defaultOptions,a.defaultOptions);return g}(w);u(z.prototype,{getGraphPath:J.getGraphPath,getStackPoints:J.getStackPoints,drawGraph:J.drawGraph,drawLegendSymbol:C.drawRectangle});E.registerSeriesType("areaspline",z);"";return z});M(a,"Series/Column/ColumnSeries.js",[a["Core/Animation/AnimationUtilities.js"],
a["Core/Color/Color.js"],a["Core/Globals.js"],a["Core/Legend/LegendSymbol.js"],a["Core/Color/Palette.js"],a["Core/Series/Series.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(a,w,C,E,z,x,J,u){var n=this&&this.__extends||function(){var a=function(c,d){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,d){a.__proto__=d}||function(a,d){for(var b in d)d.hasOwnProperty(b)&&(a[b]=d[b])};return a(c,d)};return function(c,d){function b(){this.constructor=c}a(c,d);
c.prototype=null===d?Object.create(d):(b.prototype=d.prototype,new b)}}(),m=a.animObject,g=w.parse,c=C.hasTouch;a=C.noop;var e=u.clamp,l=u.css,f=u.defined,r=u.extend,q=u.fireEvent,k=u.isArray,I=u.isNumber,D=u.merge,B=u.pick,O=u.objectEach;u=function(a){function h(){var d=null!==a&&a.apply(this,arguments)||this;d.borderWidth=void 0;d.data=void 0;d.group=void 0;d.options=void 0;d.points=void 0;return d}n(h,a);h.prototype.animate=function(a){var b=this,d=this.yAxis,c=b.options,h=this.chart.inverted,
f={},g=h?"translateX":"translateY";if(a)f.scaleY=.001,a=e(d.toPixels(c.threshold),d.pos,d.pos+d.len),h?f.translateX=a-d.len:f.translateY=a,b.clipBox&&b.setClip(),b.group.attr(f);else{var k=Number(b.group.attr(g));b.group.animate({scaleY:1},r(m(b.options.animation),{step:function(a,c){b.group&&(f[g]=k+c.pos*(d.pos-k),b.group.attr(f))}}))}};h.prototype.init=function(d,b){a.prototype.init.apply(this,arguments);var c=this;d=c.chart;d.hasRendered&&d.series.forEach(function(a){a.type===c.type&&(a.isDirty=
!0)})};h.prototype.getColumnMetrics=function(){var a=this,b=a.options,c=a.xAxis,e=a.yAxis,h=c.options.reversedStacks;h=c.reversed&&!h||!c.reversed&&h;var f={},g,k=0;!1===b.grouping?k=1:a.chart.series.forEach(function(b){var d=b.yAxis,c=b.options;if(b.type===a.type&&(b.visible||!a.chart.options.chart.ignoreHiddenSeries)&&e.len===d.len&&e.pos===d.pos){if(c.stacking&&"group"!==c.stacking){g=b.stackKey;"undefined"===typeof f[g]&&(f[g]=k++);var h=f[g]}else!1!==c.grouping&&(h=k++);b.columnIndex=h}});var l=
Math.min(Math.abs(c.transA)*(c.ordinal&&c.ordinal.slope||b.pointRange||c.closestPointRange||c.tickInterval||1),c.len),m=l*b.groupPadding,n=(l-2*m)/(k||1);b=Math.min(b.maxPointWidth||c.len,B(b.pointWidth,n*(1-2*b.pointPadding)));a.columnMetrics={width:b,offset:(n-b)/2+(m+((a.columnIndex||0)+(h?1:0))*n-l/2)*(h?-1:1),paddedWidth:n,columnCount:k};return a.columnMetrics};h.prototype.crispCol=function(a,b,c,e){var d=this.chart,h=this.borderWidth,f=-(h%2?.5:0);h=h%2?.5:1;d.inverted&&d.renderer.isVML&&(h+=
1);this.options.crisp&&(c=Math.round(a+c)+f,a=Math.round(a)+f,c-=a);e=Math.round(b+e)+h;f=.5>=Math.abs(b)&&.5<e;b=Math.round(b)+h;e-=b;f&&e&&(--b,e+=1);return{x:a,y:b,width:c,height:e}};h.prototype.adjustForMissingColumns=function(a,b,c,e){var d=this,h=this.options.stacking;if(!c.isNull&&1<e.columnCount){var f=0,g=0;O(this.yAxis.stacking&&this.yAxis.stacking.stacks,function(a){if("number"===typeof c.x&&(a=a[c.x.toString()])){var b=a.points[d.index],e=a.total;h?(b&&(f=g),a.hasValidPoints&&g++):k(b)&&
(f=b[1],g=e||0)}});a=(c.plotX||0)+((g-1)*e.paddedWidth+b)/2-b-f*e.paddedWidth}return a};h.prototype.translate=function(){var a=this,b=a.chart,c=a.options,h=a.dense=2>a.closestPointRange*a.xAxis.transA;h=a.borderWidth=B(c.borderWidth,h?0:1);var g=a.xAxis,k=a.yAxis,l=c.threshold,m=a.translatedThreshold=k.getThreshold(l),n=B(c.minPointLength,5),r=a.getColumnMetrics(),t=r.width,q=a.pointXOffset=r.offset,v=a.dataMin,u=a.dataMax,w=a.barW=Math.max(t,1+2*h);b.inverted&&(m-=.5);c.pointPadding&&(w=Math.ceil(w));
x.prototype.translate.apply(a);a.points.forEach(function(d){var h=B(d.yBottom,m),p=999+Math.abs(h),y=d.plotX||0;p=e(d.plotY,-p,k.len+p);var x=Math.min(p,h),F=Math.max(p,h)-x,D=t,G=y+q,z=w;n&&Math.abs(F)<n&&(F=n,y=!k.reversed&&!d.negative||k.reversed&&d.negative,I(l)&&I(u)&&d.y===l&&u<=l&&(k.min||0)<l&&(v!==u||(k.max||0)<=l)&&(y=!y),x=Math.abs(x-m)>n?h-n:m-(y?n:0));f(d.options.pointWidth)&&(D=z=Math.ceil(d.options.pointWidth),G-=Math.round((D-t)/2));c.centerInCategory&&(G=a.adjustForMissingColumns(G,
D,d,r));d.barX=G;d.pointWidth=D;d.tooltipPos=b.inverted?[e(k.len+k.pos-b.plotLeft-p,k.pos-b.plotLeft,k.len+k.pos-b.plotLeft),g.len+g.pos-b.plotTop-G-z/2,F]:[g.left-b.plotLeft+G+z/2,e(p+k.pos-b.plotTop,k.pos-b.plotTop,k.len+k.pos-b.plotTop),F];d.shapeType=a.pointClass.prototype.shapeType||"rect";d.shapeArgs=a.crispCol.apply(a,d.isNull?[G,m,z,0]:[G,x,z,F])})};h.prototype.drawGraph=function(){this.group[this.dense?"addClass":"removeClass"]("highcharts-dense-data")};h.prototype.pointAttribs=function(a,
b){var d=this.options,c=this.pointAttrToOptions||{},e=c.stroke||"borderColor",h=c["stroke-width"]||"borderWidth",f=a&&a.color||this.color,k=a&&a[e]||d[e]||f;c=a&&a.options.dashStyle||d.dashStyle;var l=a&&a[h]||d[h]||this[h]||0,m=B(a&&a.opacity,d.opacity,1);if(a&&this.zones.length){var n=a.getZone();f=a.options.color||n&&(n.color||a.nonZonedColor)||this.color;n&&(k=n.borderColor||k,c=n.dashStyle||c,l=n.borderWidth||l)}b&&a&&(a=D(d.states[b],a.options.states&&a.options.states[b]||{}),b=a.brightness,
f=a.color||"undefined"!==typeof b&&g(f).brighten(a.brightness).get()||f,k=a[e]||k,l=a[h]||l,c=a.dashStyle||c,m=B(a.opacity,m));e={fill:f,stroke:k,"stroke-width":l,opacity:m};c&&(e.dashstyle=c);return e};h.prototype.drawPoints=function(){var a=this,b=this.chart,c=a.options,e=b.renderer,h=c.animationLimit||250,f;a.points.forEach(function(d){var g=d.graphic,k=!!g,l=g&&b.pointCount<h?"animate":"attr";if(I(d.plotY)&&null!==d.y){f=d.shapeArgs;g&&d.hasNewShapeType()&&(g=g.destroy());a.enabledDataSorting&&
(d.startXPos=a.xAxis.reversed?-(f?f.width||0:0):a.xAxis.width);g||(d.graphic=g=e[d.shapeType](f).add(d.group||a.group))&&a.enabledDataSorting&&b.hasRendered&&b.pointCount<h&&(g.attr({x:d.startXPos}),k=!0,l="animate");if(g&&k)g[l](D(f));if(c.borderRadius)g[l]({r:c.borderRadius});b.styledMode||g[l](a.pointAttribs(d,d.selected&&"select")).shadow(!1!==d.allowShadow&&c.shadow,null,c.stacking&&!c.borderRadius);g&&(g.addClass(d.getClassName(),!0),g.attr({visibility:d.visible?"inherit":"hidden"}))}else g&&
(d.graphic=g.destroy())})};h.prototype.drawTracker=function(){var a=this,b=a.chart,e=b.pointer,h=function(a){var b=e.getPointFromEvent(a);"undefined"!==typeof b&&(e.isDirectTouch=!0,b.onMouseOver(a))},f;a.points.forEach(function(a){f=k(a.dataLabels)?a.dataLabels:a.dataLabel?[a.dataLabel]:[];a.graphic&&(a.graphic.element.point=a);f.forEach(function(b){b.div?b.div.point=a:b.element.point=a})});a._hasTracking||(a.trackerGroups.forEach(function(d){if(a[d]){a[d].addClass("highcharts-tracker").on("mouseover",
h).on("mouseout",function(a){e.onTrackerMouseOut(a)});if(c)a[d].on("touchstart",h);!b.styledMode&&a.options.cursor&&a[d].css(l).css({cursor:a.options.cursor})}}),a._hasTracking=!0);q(this,"afterDrawTracker")};h.prototype.remove=function(){var a=this,b=a.chart;b.hasRendered&&b.series.forEach(function(b){b.type===a.type&&(b.isDirty=!0)});x.prototype.remove.apply(a,arguments)};h.defaultOptions=D(x.defaultOptions,{borderRadius:0,centerInCategory:!1,groupPadding:.2,marker:null,pointPadding:.1,minPointLength:0,
cropThreshold:50,pointRange:null,states:{hover:{halo:!1,brightness:.1},select:{color:z.neutralColor20,borderColor:z.neutralColor100}},dataLabels:{align:void 0,verticalAlign:void 0,y:void 0},startFromThreshold:!0,stickyTracking:!1,tooltip:{distance:6},threshold:0,borderColor:z.backgroundColor});return h}(x);r(u.prototype,{cropShoulder:0,directTouch:!0,drawLegendSymbol:E.drawRectangle,getSymbol:a,negStacks:!0,trackerGroups:["group","dataLabelsGroup"]});J.registerSeriesType("column",u);"";"";return u});
M(a,"Core/Series/DataLabel.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/FormatUtilities.js"],a["Core/Color/Palette.js"],a["Core/Utilities.js"]],function(a,w,C,E){var r=a.getDeferredAnimation,x=w.format,J=E.defined,u=E.extend,n=E.fireEvent,m=E.isArray,g=E.merge,c=E.objectEach,e=E.pick,l=E.splat,f;(function(a){function f(a,c,b,f,g){var d=this,h=this.chart,k=this.isCartesian&&h.inverted,l=this.enabledDataSorting,m=e(a.dlBox&&a.dlBox.centerX,a.plotX,-9999),n=e(a.plotY,-9999),p=c.getBBox(),r=
b.rotation,t=b.align,q=h.isInsidePlot(m,Math.round(n),{inverted:k,paneCoordinates:!0,series:d}),v=function(b){l&&d.xAxis&&!B&&d.setDataLabelStartPos(a,c,g,q,b)},B="justify"===e(b.overflow,l?"none":"justify"),x=this.visible&&!1!==a.visible&&(a.series.forceDL||l&&!B||q||e(b.inside,!!this.options.stacking)&&f&&h.isInsidePlot(m,k?f.x+1:f.y+f.height-1,{inverted:k,paneCoordinates:!0,series:d}));if(x){var w=h.renderer.fontMetrics(h.styledMode?void 0:b.style.fontSize,c).b;f=u({x:k?this.yAxis.len-n:m,y:Math.round(k?
this.xAxis.len-m:n),width:0,height:0},f);u(b,{width:p.width,height:p.height});r?(B=!1,m=h.renderer.rotCorr(w,r),m={x:f.x+(b.x||0)+f.width/2+m.x,y:f.y+(b.y||0)+{top:0,middle:.5,bottom:1}[b.verticalAlign]*f.height},v(m),c[g?"attr":"animate"](m).attr({align:t}),v=(r+720)%360,v=180<v&&360>v,"left"===t?m.y-=v?p.height:0:"center"===t?(m.x-=p.width/2,m.y-=p.height/2):"right"===t&&(m.x-=p.width,m.y-=v?0:p.height),c.placed=!0,c.alignAttr=m):(v(f),c.align(b,void 0,f),m=c.alignAttr);B&&0<=f.height?this.justifyDataLabel(c,
b,m,p,f,g):e(b.crop,!0)&&(x=h.isInsidePlot(m.x,m.y,{paneCoordinates:!0,series:d})&&h.isInsidePlot(m.x+p.width,m.y+p.height,{paneCoordinates:!0,series:d}));if(b.shape&&!r)c[g?"attr":"animate"]({anchorX:k?h.plotWidth-a.plotY:a.plotX,anchorY:k?h.plotHeight-a.plotX:a.plotY})}g&&l&&(c.placed=!1);x||l&&!B||(c.hide(!0),c.placed=!1)}function k(a,c){var b=c.filter;return b?(c=b.operator,a=a[b.property],b=b.value,">"===c&&a>b||"<"===c&&a<b||">="===c&&a>=b||"<="===c&&a<=b||"=="===c&&a==b||"==="===c&&a===b?!0:
!1):!0}function v(){var a=this,d=a.chart,b=a.options,f=a.points,g=a.hasRendered||0,t=d.renderer,q=b.dataLabels,v,u=q.animation;u=q.defer?r(d,u,a):{defer:0,duration:0};q=B(B(d.options.plotOptions&&d.options.plotOptions.series&&d.options.plotOptions.series.dataLabels,d.options.plotOptions&&d.options.plotOptions[a.type]&&d.options.plotOptions[a.type].dataLabels),q);n(this,"drawDataLabels");if(m(q)||q.enabled||a._hasPointLabels){var w=a.plotGroup("dataLabelsGroup","data-labels",g?"inherit":"hidden",q.zIndex||
6);w.attr({opacity:+g});!g&&(g=a.dataLabelsGroup)&&(a.visible&&w.show(!0),g[b.animation?"animate":"attr"]({opacity:1},u));f.forEach(function(f){v=l(B(q,f.dlOptions||f.options&&f.options.dataLabels));v.forEach(function(h,g){var l=h.enabled&&(!f.isNull||f.dataLabelOnNull)&&k(f,h),m=f.connectors?f.connectors[g]:f.connector,n=f.dataLabels?f.dataLabels[g]:f.dataLabel,p=e(h.distance,f.labelDistance),r=!n;if(l){var q=f.getLabelConfig();var v=e(h[f.formatPrefix+"Format"],h.format);q=J(v)?x(v,q,d):(h[f.formatPrefix+
"Formatter"]||h.formatter).call(q,h);v=h.style;var u=h.rotation;d.styledMode||(v.color=e(h.color,v.color,a.color,C.neutralColor100),"contrast"===v.color?(f.contrastColor=t.getContrast(f.color||a.color),v.color=!J(p)&&h.inside||0>p||b.stacking?f.contrastColor:C.neutralColor100):delete f.contrastColor,b.cursor&&(v.cursor=b.cursor));var B={r:h.borderRadius||0,rotation:u,padding:h.padding,zIndex:1};d.styledMode||(B.fill=h.backgroundColor,B.stroke=h.borderColor,B["stroke-width"]=h.borderWidth);c(B,function(a,
b){"undefined"===typeof a&&delete B[b]})}!n||l&&J(q)?l&&J(q)&&(n?B.text=q:(f.dataLabels=f.dataLabels||[],n=f.dataLabels[g]=u?t.text(q,0,-9999,h.useHTML).addClass("highcharts-data-label"):t.label(q,0,-9999,h.shape,null,null,h.useHTML,null,"data-label"),g||(f.dataLabel=n),n.addClass(" highcharts-data-label-color-"+f.colorIndex+" "+(h.className||"")+(h.useHTML?" highcharts-tracker":""))),n.options=h,n.attr(B),d.styledMode||n.css(v).shadow(h.shadow),n.added||n.add(w),h.textPath&&!h.useHTML&&(n.setTextPath(f.getDataLabelPath&&
f.getDataLabelPath(n)||f.graphic,h.textPath),f.dataLabelPath&&!h.textPath.enabled&&(f.dataLabelPath=f.dataLabelPath.destroy())),a.alignDataLabel(f,n,h,null,r)):(f.dataLabel=f.dataLabel&&f.dataLabel.destroy(),f.dataLabels&&(1===f.dataLabels.length?delete f.dataLabels:delete f.dataLabels[g]),g||delete f.dataLabel,m&&(f.connector=f.connector.destroy(),f.connectors&&(1===f.connectors.length?delete f.connectors:delete f.connectors[g])))})})}n(this,"afterDrawDataLabels")}function w(a,c,b,e,f,g){var d=this.chart,
h=c.align,k=c.verticalAlign,l=a.box?0:a.padding||0,m=c.x;m=void 0===m?0:m;var n=c.y;n=void 0===n?0:n;var p=(b.x||0)+l;if(0>p){"right"===h&&0<=m?(c.align="left",c.inside=!0):m-=p;var r=!0}p=(b.x||0)+e.width-l;p>d.plotWidth&&("left"===h&&0>=m?(c.align="right",c.inside=!0):m+=d.plotWidth-p,r=!0);p=b.y+l;0>p&&("bottom"===k&&0<=n?(c.verticalAlign="top",c.inside=!0):n-=p,r=!0);p=(b.y||0)+e.height-l;p>d.plotHeight&&("top"===k&&0>=n?(c.verticalAlign="bottom",c.inside=!0):n+=d.plotHeight-p,r=!0);r&&(c.x=m,
c.y=n,a.placed=!g,a.align(c,void 0,f));return r}function B(a,c){var b=[],d;if(m(a)&&!m(c))b=a.map(function(a){return g(a,c)});else if(m(c)&&!m(a))b=c.map(function(b){return g(a,b)});else if(m(a)||m(c))for(d=Math.max(a.length,c.length);d--;)b[d]=g(a[d],c[d]);else b=g(a,c);return b}function z(a,c,b,e,f){var d=this.chart,h=d.inverted,g=this.xAxis,k=g.reversed,l=h?c.height/2:c.width/2;a=(a=a.pointWidth)?a/2:0;c.startXPos=h?f.x:k?-l-a:g.width-l+a;c.startYPos=h?k?this.yAxis.height-l+a:-l-a:f.y;e?"hidden"===
c.visibility&&(c.show(),c.attr({opacity:0}).animate({opacity:1})):c.attr({opacity:1}).animate({opacity:0},void 0,c.hide);d.hasRendered&&(b&&c.attr({x:c.startXPos,y:c.startYPos}),c.placed=!0)}var t=[];a.compose=function(a){if(-1===t.indexOf(a)){var c=a.prototype;t.push(a);c.alignDataLabel=f;c.drawDataLabels=v;c.justifyDataLabel=w;c.setDataLabelStartPos=z}}})(f||(f={}));"";return f});M(a,"Series/Column/ColumnDataLabel.js",[a["Core/Series/DataLabel.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],
function(a,w,C){var r=w.series,z=C.merge,x=C.pick,J;(function(u){function n(a,c,e,l,f){var g=this.chart.inverted,m=a.series,k=a.dlBox||a.shapeArgs,n=x(a.below,a.plotY>x(this.translatedThreshold,m.yAxis.len)),u=x(e.inside,!!this.options.stacking);k&&(l=z(k),0>l.y&&(l.height+=l.y,l.y=0),k=l.y+l.height-m.yAxis.len,0<k&&k<l.height&&(l.height-=k),g&&(l={x:m.yAxis.len-l.y-l.height,y:m.xAxis.len-l.x-l.width,width:l.height,height:l.width}),u||(g?(l.x+=n?0:l.width,l.width=0):(l.y+=n?l.height:0,l.height=0)));
e.align=x(e.align,!g||u?"center":n?"right":"left");e.verticalAlign=x(e.verticalAlign,g||u?"middle":n?"top":"bottom");r.prototype.alignDataLabel.call(this,a,c,e,l,f);e.inside&&a.contrastColor&&c.css({color:a.contrastColor})}var m=[];u.compose=function(g){a.compose(r);-1===m.indexOf(g)&&(m.push(g),g.prototype.alignDataLabel=n)}})(J||(J={}));return J});M(a,"Series/Bar/BarSeries.js",[a["Series/Column/ColumnSeries.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(a,w,C){var r=this&&
this.__extends||function(){var a=function(r,n){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,g){a.__proto__=g}||function(a,g){for(var c in g)g.hasOwnProperty(c)&&(a[c]=g[c])};return a(r,n)};return function(r,n){function m(){this.constructor=r}a(r,n);r.prototype=null===n?Object.create(n):(m.prototype=n.prototype,new m)}}(),z=C.extend,x=C.merge;C=function(w){function u(){var a=null!==w&&w.apply(this,arguments)||this;a.data=void 0;a.options=void 0;a.points=void 0;return a}r(u,w);
u.defaultOptions=x(a.defaultOptions,{});return u}(a);z(C.prototype,{inverted:!0});w.registerSeriesType("bar",C);"";return C});M(a,"Series/Scatter/ScatterSeries.js",[a["Series/Column/ColumnSeries.js"],a["Series/Line/LineSeries.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(a,w,C,E){var r=this&&this.__extends||function(){var a=function(m,g){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,e){a.__proto__=e}||function(a,e){for(var c in e)e.hasOwnProperty(c)&&
(a[c]=e[c])};return a(m,g)};return function(m,g){function c(){this.constructor=m}a(m,g);m.prototype=null===g?Object.create(g):(c.prototype=g.prototype,new c)}}(),x=E.addEvent,J=E.extend,u=E.merge;E=function(a){function m(){var g=null!==a&&a.apply(this,arguments)||this;g.data=void 0;g.options=void 0;g.points=void 0;return g}r(m,a);m.prototype.applyJitter=function(){var a=this,c=this.options.jitter,e=this.points.length;c&&this.points.forEach(function(g,f){["x","y"].forEach(function(l,m){var k="plot"+
l.toUpperCase();if(c[l]&&!g.isNull){var n=a[l+"Axis"];var r=c[l]*n.transA;if(n&&!n.isLog){var q=Math.max(0,g[k]-r);n=Math.min(n.len,g[k]+r);m=1E4*Math.sin(f+m*e);g[k]=q+(n-q)*(m-Math.floor(m));"x"===l&&(g.clientX=g.plotX)}}})})};m.prototype.drawGraph=function(){this.options.lineWidth?a.prototype.drawGraph.call(this):this.graph&&(this.graph=this.graph.destroy())};m.defaultOptions=u(w.defaultOptions,{lineWidth:0,findNearestPointBy:"xy",jitter:{x:0,y:0},marker:{enabled:!0},tooltip:{headerFormat:'<span style="color:{point.color}">\u25cf</span> <span style="font-size: 10px"> {series.name}</span><br/>',
pointFormat:"x: <b>{point.x}</b><br/>y: <b>{point.y}</b><br/>"}});return m}(w);J(E.prototype,{drawTracker:a.prototype.drawTracker,sorted:!1,requireSorting:!1,noSharedTooltip:!0,trackerGroups:["group","markerGroup","dataLabelsGroup"],takeOrdinalPosition:!1});x(E,"afterTranslate",function(){this.applyJitter()});C.registerSeriesType("scatter",E);"";return E});M(a,"Mixins/CenteredSeries.js",[a["Core/Globals.js"],a["Core/Series/Series.js"],a["Core/Utilities.js"]],function(a,w,C){var r=C.isNumber,z=C.pick,
x=C.relativeLength,J=a.deg2rad;return a.CenteredSeriesMixin={getCenter:function(){var a=this.options,n=this.chart,m=2*(a.slicedOffset||0),g=n.plotWidth-2*m,c=n.plotHeight-2*m,e=a.center,l=Math.min(g,c),f=a.size,r=a.innerSize||0;"string"===typeof f&&(f=parseFloat(f));"string"===typeof r&&(r=parseFloat(r));a=[z(e[0],"50%"),z(e[1],"50%"),z(f&&0>f?void 0:a.size,"100%"),z(r&&0>r?void 0:a.innerSize||0,"0%")];!n.angular||this instanceof w||(a[3]=0);for(e=0;4>e;++e)f=a[e],n=2>e||2===e&&/%$/.test(f),a[e]=
x(f,[g,c,l,a[2]][e])+(n?m:0);a[3]>a[2]&&(a[3]=a[2]);return a},getStartAndEndRadians:function(a,n){a=r(a)?a:0;n=r(n)&&n>a&&360>n-a?n:a+360;return{start:J*(a+-90),end:J*(n+-90)}}}});M(a,"Series/Pie/PiePoint.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Series/Point.js"],a["Core/Utilities.js"]],function(a,w,C){var r=this&&this.__extends||function(){var a=function(c,e){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,c){a.__proto__=c}||function(a,c){for(var e in c)c.hasOwnProperty(e)&&
(a[e]=c[e])};return a(c,e)};return function(c,e){function g(){this.constructor=c}a(c,e);c.prototype=null===e?Object.create(e):(g.prototype=e.prototype,new g)}}(),z=a.setAnimation,x=C.addEvent,J=C.defined;a=C.extend;var u=C.isNumber,n=C.pick,m=C.relativeLength;w=function(a){function c(){var c=null!==a&&a.apply(this,arguments)||this;c.labelDistance=void 0;c.options=void 0;c.series=void 0;return c}r(c,a);c.prototype.getConnectorPath=function(){var a=this.labelPosition,c=this.series.options.dataLabels,
f=this.connectorShapes,g=c.connectorShape;f[g]&&(g=f[g]);return g.call(this,{x:a.final.x,y:a.final.y,alignment:a.alignment},a.connectorPosition,c)};c.prototype.getTranslate=function(){return this.sliced?this.slicedTranslation:{translateX:0,translateY:0}};c.prototype.haloPath=function(a){var c=this.shapeArgs;return this.sliced||!this.visible?[]:this.series.chart.renderer.symbols.arc(c.x,c.y,c.r+a,c.r+a,{innerR:c.r-1,start:c.start,end:c.end})};c.prototype.init=function(){var c=this;a.prototype.init.apply(this,
arguments);this.name=n(this.name,"Slice");var g=function(a){c.slice("select"===a.type)};x(this,"select",g);x(this,"unselect",g);return this};c.prototype.isValid=function(){return u(this.y)&&0<=this.y};c.prototype.setVisible=function(a,c){var e=this,g=this.series,l=g.chart,k=g.options.ignoreHiddenPoint;c=n(c,k);a!==this.visible&&(this.visible=this.options.visible=a="undefined"===typeof a?!this.visible:a,g.options.data[g.data.indexOf(this)]=this.options,["graphic","dataLabel","connector","shadowGroup"].forEach(function(c){if(e[c])e[c][a?
"show":"hide"](a)}),this.legendItem&&l.legend.colorizeItem(this,a),a||"hover"!==this.state||this.setState(""),k&&(g.isDirty=!0),c&&l.redraw())};c.prototype.slice=function(a,c,f){var e=this.series;z(f,e.chart);n(c,!0);this.sliced=this.options.sliced=J(a)?a:!this.sliced;e.options.data[e.data.indexOf(this)]=this.options;this.graphic&&this.graphic.animate(this.getTranslate());this.shadowGroup&&this.shadowGroup.animate(this.getTranslate())};return c}(w);a(w.prototype,{connectorShapes:{fixedOffset:function(a,
c,e){var g=c.breakAt;c=c.touchingSliceAt;return[["M",a.x,a.y],e.softConnector?["C",a.x+("left"===a.alignment?-5:5),a.y,2*g.x-c.x,2*g.y-c.y,g.x,g.y]:["L",g.x,g.y],["L",c.x,c.y]]},straight:function(a,c){c=c.touchingSliceAt;return[["M",a.x,a.y],["L",c.x,c.y]]},crookedLine:function(a,c,e){c=c.touchingSliceAt;var g=this.series,f=g.center[0],n=g.chart.plotWidth,r=g.chart.plotLeft;g=a.alignment;var k=this.shapeArgs.r;e=m(e.crookDistance,1);n="left"===g?f+k+(n+r-f-k)*(1-e):r+(f-k)*e;e=["L",n,a.y];f=!0;if("left"===
g?n>a.x||n<c.x:n<a.x||n>c.x)f=!1;a=[["M",a.x,a.y]];f&&a.push(e);a.push(["L",c.x,c.y]);return a}}});return w});M(a,"Series/Pie/PieSeries.js",[a["Mixins/CenteredSeries.js"],a["Series/Column/ColumnSeries.js"],a["Core/Globals.js"],a["Core/Legend/LegendSymbol.js"],a["Core/Color/Palette.js"],a["Series/Pie/PiePoint.js"],a["Core/Series/Series.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Renderer/SVG/Symbols.js"],a["Core/Utilities.js"]],function(a,w,C,E,z,x,J,u,n,m){var g=this&&this.__extends||function(){var a=
function(c,e){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,c){a.__proto__=c}||function(a,c){for(var e in c)c.hasOwnProperty(e)&&(a[e]=c[e])};return a(c,e)};return function(c,e){function f(){this.constructor=c}a(c,e);c.prototype=null===e?Object.create(e):(f.prototype=e.prototype,new f)}}(),c=a.getStartAndEndRadians;C=C.noop;var e=m.clamp,l=m.extend,f=m.fireEvent,r=m.merge,q=m.pick,k=m.relativeLength;m=function(a){function l(){var c=null!==a&&a.apply(this,arguments)||this;c.center=
void 0;c.data=void 0;c.maxLabelDistance=void 0;c.options=void 0;c.points=void 0;return c}g(l,a);l.prototype.animate=function(a){var c=this,e=c.points,f=c.startAngleRad;a||e.forEach(function(a){var b=a.graphic,d=a.shapeArgs;b&&d&&(b.attr({r:q(a.startR,c.center&&c.center[3]/2),start:f,end:f}),b.animate({r:d.r,start:d.start,end:d.end},c.options.animation))})};l.prototype.drawEmpty=function(){var a=this.startAngleRad,c=this.endAngleRad,e=this.options;if(0===this.total&&this.center){var f=this.center[0];
var d=this.center[1];this.graph||(this.graph=this.chart.renderer.arc(f,d,this.center[1]/2,0,a,c).addClass("highcharts-empty-series").add(this.group));this.graph.attr({d:n.arc(f,d,this.center[2]/2,0,{start:a,end:c,innerR:this.center[3]/2})});this.chart.styledMode||this.graph.attr({"stroke-width":e.borderWidth,fill:e.fillColor||"none",stroke:e.color||z.neutralColor20})}else this.graph&&(this.graph=this.graph.destroy())};l.prototype.drawPoints=function(){var a=this.chart.renderer;this.points.forEach(function(c){c.graphic&&
c.hasNewShapeType()&&(c.graphic=c.graphic.destroy());c.graphic||(c.graphic=a[c.shapeType](c.shapeArgs).add(c.series.group),c.delayedRendering=!0)})};l.prototype.generatePoints=function(){a.prototype.generatePoints.call(this);this.updateTotals()};l.prototype.getX=function(a,c,f){var h=this.center,d=this.radii?this.radii[f.index]||0:h[2]/2;a=Math.asin(e((a-h[1])/(d+f.labelDistance),-1,1));return h[0]+(c?-1:1)*Math.cos(a)*(d+f.labelDistance)+(0<f.labelDistance?(c?-1:1)*this.options.dataLabels.padding:
0)};l.prototype.hasData=function(){return!!this.processedXData.length};l.prototype.redrawPoints=function(){var a=this,c=a.chart,e=c.renderer,f=a.options.shadow,d,b,g,k;this.drawEmpty();!f||a.shadowGroup||c.styledMode||(a.shadowGroup=e.g("shadow").attr({zIndex:-1}).add(a.group));a.points.forEach(function(h){var l={};b=h.graphic;if(!h.isNull&&b){var m=void 0;k=h.shapeArgs;d=h.getTranslate();c.styledMode||(m=h.shadowGroup,f&&!m&&(m=h.shadowGroup=e.g("shadow").add(a.shadowGroup)),m&&m.attr(d),g=a.pointAttribs(h,
h.selected&&"select"));h.delayedRendering?(b.setRadialReference(a.center).attr(k).attr(d),c.styledMode||b.attr(g).attr({"stroke-linejoin":"round"}).shadow(f,m),h.delayedRendering=!1):(b.setRadialReference(a.center),c.styledMode||r(!0,l,g),r(!0,l,k,d),b.animate(l));b.attr({visibility:h.visible?"inherit":"hidden"});b.addClass(h.getClassName(),!0)}else b&&(h.graphic=b.destroy())})};l.prototype.sortByAngle=function(a,c){a.sort(function(a,e){return"undefined"!==typeof a.angle&&(e.angle-a.angle)*c})};l.prototype.translate=
function(a){this.generatePoints();var e=this.options,g=e.slicedOffset,h=g+(e.borderWidth||0),d=c(e.startAngle,e.endAngle),b=this.startAngleRad=d.start;d=(this.endAngleRad=d.end)-b;var l=this.points,m=e.dataLabels.distance;e=e.ignoreHiddenPoint;var n=l.length,r,v=0;a||(this.center=a=this.getCenter());for(r=0;r<n;r++){var u=l[r];var x=b+v*d;!u.isValid()||e&&!u.visible||(v+=u.percentage/100);var w=b+v*d;var B={x:a[0],y:a[1],r:a[2]/2,innerR:a[3]/2,start:Math.round(1E3*x)/1E3,end:Math.round(1E3*w)/1E3};
u.shapeType="arc";u.shapeArgs=B;u.labelDistance=q(u.options.dataLabels&&u.options.dataLabels.distance,m);u.labelDistance=k(u.labelDistance,B.r);this.maxLabelDistance=Math.max(this.maxLabelDistance||0,u.labelDistance);w=(w+x)/2;w>1.5*Math.PI?w-=2*Math.PI:w<-Math.PI/2&&(w+=2*Math.PI);u.slicedTranslation={translateX:Math.round(Math.cos(w)*g),translateY:Math.round(Math.sin(w)*g)};B=Math.cos(w)*a[2]/2;var z=Math.sin(w)*a[2]/2;u.tooltipPos=[a[0]+.7*B,a[1]+.7*z];u.half=w<-Math.PI/2||w>Math.PI/2?1:0;u.angle=
w;x=Math.min(h,u.labelDistance/5);u.labelPosition={natural:{x:a[0]+B+Math.cos(w)*u.labelDistance,y:a[1]+z+Math.sin(w)*u.labelDistance},"final":{},alignment:0>u.labelDistance?"center":u.half?"right":"left",connectorPosition:{breakAt:{x:a[0]+B+Math.cos(w)*x,y:a[1]+z+Math.sin(w)*x},touchingSliceAt:{x:a[0]+B,y:a[1]+z}}}}f(this,"afterTranslate")};l.prototype.updateTotals=function(){var a=this.points,c=a.length,e=this.options.ignoreHiddenPoint,f,d=0;for(f=0;f<c;f++){var b=a[f];!b.isValid()||e&&!b.visible||
(d+=b.y)}this.total=d;for(f=0;f<c;f++)b=a[f],b.percentage=0<d&&(b.visible||!e)?b.y/d*100:0,b.total=d};l.defaultOptions=r(J.defaultOptions,{center:[null,null],clip:!1,colorByPoint:!0,dataLabels:{allowOverlap:!0,connectorPadding:5,connectorShape:"fixedOffset",crookDistance:"70%",distance:30,enabled:!0,formatter:function(){return this.point.isNull?void 0:this.point.name},softConnector:!0,x:0},fillColor:void 0,ignoreHiddenPoint:!0,inactiveOtherPoints:!0,legendType:"point",marker:null,size:null,showInLegend:!1,
slicedOffset:10,stickyTracking:!1,tooltip:{followPointer:!0},borderColor:z.backgroundColor,borderWidth:1,lineWidth:void 0,states:{hover:{brightness:.1}}});return l}(J);l(m.prototype,{axisTypes:[],directTouch:!0,drawGraph:void 0,drawLegendSymbol:E.drawRectangle,drawTracker:w.prototype.drawTracker,getCenter:a.getCenter,getSymbol:C,isCartesian:!1,noSharedTooltip:!0,pointAttribs:w.prototype.pointAttribs,pointClass:x,requireSorting:!1,searchPoint:C,trackerGroups:["group","dataLabelsGroup"]});u.registerSeriesType("pie",
m);"";return m});M(a,"Series/Pie/PieDataLabel.js",[a["Core/Series/DataLabel.js"],a["Core/Globals.js"],a["Core/Color/Palette.js"],a["Core/Renderer/RendererUtilities.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(a,w,C,E,z,x){var r=w.noop,u=E.distribute,n=z.series,m=x.arrayMax,g=x.clamp,c=x.defined,e=x.merge,l=x.pick,f=x.relativeLength,v;(function(q){function k(){var a=this,f=a.data,d=a.chart,b=a.options.dataLabels||{},g=b.connectorPadding,k=d.plotWidth,r=d.plotHeight,q=d.plotLeft,
v=Math.round(d.chartWidth/3),w=a.center,x=w[2]/2,B=w[1],z=[[],[]],D=[0,0,0,0],E=a.dataLabelPositioners,I,J,M,O,Z,A,U,N,W,X,Y,T;a.visible&&(b.enabled||a._hasPointLabels)&&(f.forEach(function(a){a.dataLabel&&a.visible&&a.dataLabel.shortened&&(a.dataLabel.attr({width:"auto"}).css({width:"auto",textOverflow:"clip"}),a.dataLabel.shortened=!1)}),n.prototype.drawDataLabels.apply(a),f.forEach(function(a){a.dataLabel&&(a.visible?(z[a.half].push(a),a.dataLabel._pos=null,!c(b.style.width)&&!c(a.options.dataLabels&&
a.options.dataLabels.style&&a.options.dataLabels.style.width)&&a.dataLabel.getBBox().width>v&&(a.dataLabel.css({width:Math.round(.7*v)+"px"}),a.dataLabel.shortened=!0)):(a.dataLabel=a.dataLabel.destroy(),a.dataLabels&&1===a.dataLabels.length&&delete a.dataLabels))}),z.forEach(function(e,f){var h=e.length,m=[],n;if(h){a.sortByAngle(e,f-.5);if(0<a.maxLabelDistance){var p=Math.max(0,B-x-a.maxLabelDistance);var t=Math.min(B+x+a.maxLabelDistance,d.plotHeight);e.forEach(function(a){0<a.labelDistance&&a.dataLabel&&
(a.top=Math.max(0,B-x-a.labelDistance),a.bottom=Math.min(B+x+a.labelDistance,d.plotHeight),n=a.dataLabel.getBBox().height||21,a.distributeBox={target:a.labelPosition.natural.y-a.top+n/2,size:n,rank:a.y},m.push(a.distributeBox))});p=t+n-p;u(m,p,p/5)}for(Y=0;Y<h;Y++){I=e[Y];A=I.labelPosition;O=I.dataLabel;X=!1===I.visible?"hidden":"inherit";W=p=A.natural.y;m&&c(I.distributeBox)&&("undefined"===typeof I.distributeBox.pos?X="hidden":(U=I.distributeBox.size,W=E.radialDistributionY(I)));delete I.positionIndex;
if(b.justify)N=E.justify(I,x,w);else switch(b.alignTo){case "connectors":N=E.alignToConnectors(e,f,k,q);break;case "plotEdges":N=E.alignToPlotEdges(O,f,k,q);break;default:N=E.radialDistributionX(a,I,W,p)}O._attr={visibility:X,align:A.alignment};T=I.options.dataLabels||{};O._pos={x:N+l(T.x,b.x)+({left:g,right:-g}[A.alignment]||0),y:W+l(T.y,b.y)-10};A.final.x=N;A.final.y=W;l(b.crop,!0)&&(Z=O.getBBox().width,p=null,N-Z<g&&1===f?(p=Math.round(Z-N+g),D[3]=Math.max(p,D[3])):N+Z>k-g&&0===f&&(p=Math.round(N+
Z-k+g),D[1]=Math.max(p,D[1])),0>W-U/2?D[0]=Math.max(Math.round(-W+U/2),D[0]):W+U/2>r&&(D[2]=Math.max(Math.round(W+U/2-r),D[2])),O.sideOverflow=p)}}}),0===m(D)||this.verifyDataLabelOverflow(D))&&(this.placeDataLabels(),this.points.forEach(function(c){T=e(b,c.options.dataLabels);if(J=l(T.connectorWidth,1)){var f;M=c.connector;if((O=c.dataLabel)&&O._pos&&c.visible&&0<c.labelDistance){X=O._attr.visibility;if(f=!M)c.connector=M=d.renderer.path().addClass("highcharts-data-label-connector  highcharts-color-"+
c.colorIndex+(c.className?" "+c.className:"")).add(a.dataLabelsGroup),d.styledMode||M.attr({"stroke-width":J,stroke:T.connectorColor||c.color||C.neutralColor60});M[f?"attr":"animate"]({d:c.getConnectorPath()});M.attr("visibility",X)}else M&&(c.connector=M.destroy())}}))}function v(){this.points.forEach(function(a){var c=a.dataLabel,d;c&&a.visible&&((d=c._pos)?(c.sideOverflow&&(c._attr.width=Math.max(c.getBBox().width-c.sideOverflow,0),c.css({width:c._attr.width+"px",textOverflow:(this.options.dataLabels.style||
{}).textOverflow||"ellipsis"}),c.shortened=!0),c.attr(c._attr),c[c.moved?"animate":"attr"](d),c.moved=!0):c&&c.attr({y:-9999}));delete a.distributeBox},this)}function w(a){var c=this.center,d=this.options,b=d.center,e=d.minSize||80,k=null!==d.size;if(!k){if(null!==b[0])var l=Math.max(c[2]-Math.max(a[1],a[3]),e);else l=Math.max(c[2]-a[1]-a[3],e),c[0]+=(a[3]-a[1])/2;null!==b[1]?l=g(l,e,c[2]-Math.max(a[0],a[2])):(l=g(l,e,c[2]-a[0]-a[2]),c[1]+=(a[0]-a[2])/2);l<c[2]?(c[2]=l,c[3]=Math.min(f(d.innerSize||
0,l),l),this.translate(c),this.drawDataLabels&&this.drawDataLabels()):k=!0}return k}var x=[],z={radialDistributionY:function(a){return a.top+a.distributeBox.pos},radialDistributionX:function(a,c,d,b){return a.getX(d<c.top+2||d>c.bottom-2?b:d,c.half,c)},justify:function(a,c,d){return d[0]+(a.half?-1:1)*(c+a.labelDistance)},alignToPlotEdges:function(a,c,d,b){a=a.getBBox().width;return c?a+b:d-a-b},alignToConnectors:function(a,c,d,b){var e=0,f;a.forEach(function(a){f=a.dataLabel.getBBox().width;f>e&&
(e=f)});return c?e+b:d-e-b}};q.compose=function(c){a.compose(n);-1===x.indexOf(c)&&(x.push(c),c=c.prototype,c.dataLabelPositioners=z,c.alignDataLabel=r,c.drawDataLabels=k,c.placeDataLabels=v,c.verifyDataLabelOverflow=w)}})(v||(v={}));return v});M(a,"Extensions/OverlappingDataLabels.js",[a["Core/Chart/Chart.js"],a["Core/Utilities.js"]],function(a,w){function r(a,g){var c=!1;if(a){var e=a.newOpacity;a.oldOpacity!==e&&(a.alignAttr&&a.placed?(a[e?"removeClass":"addClass"]("highcharts-data-label-hidden"),
c=!0,a.alignAttr.opacity=e,a[a.isOld?"animate":"attr"](a.alignAttr,null,function(){g.styledMode||a.css({pointerEvents:e?"auto":"none"})}),z(g,"afterHideOverlappingLabel")):a.attr({opacity:e}));a.isOld=!0}return c}var E=w.addEvent,z=w.fireEvent,x=w.isArray,J=w.isNumber,u=w.objectEach,n=w.pick;E(a,"render",function(){var a=this,g=[];(this.labelCollectors||[]).forEach(function(a){g=g.concat(a())});(this.yAxis||[]).forEach(function(a){a.stacking&&a.options.stackLabels&&!a.options.stackLabels.allowOverlap&&
u(a.stacking.stacks,function(a){u(a,function(a){a.label&&"hidden"!==a.label.visibility&&g.push(a.label)})})});(this.series||[]).forEach(function(c){var e=c.options.dataLabels;c.visible&&(!1!==e.enabled||c._hasPointLabels)&&(e=function(c){return c.forEach(function(c){c.visible&&(x(c.dataLabels)?c.dataLabels:c.dataLabel?[c.dataLabel]:[]).forEach(function(e){var f=e.options;e.labelrank=n(f.labelrank,c.labelrank,c.shapeArgs&&c.shapeArgs.height);f.allowOverlap?(e.oldOpacity=e.opacity,e.newOpacity=1,r(e,
a)):g.push(e)})})},e(c.nodes||[]),e(c.points))});this.hideOverlappingLabels(g)});a.prototype.hideOverlappingLabels=function(a){var g=this,c=a.length,e=g.renderer,l,f,m,n=!1;var k=function(a){var c,f=a.box?0:a.padding||0,g=c=0,d;if(a&&(!a.alignAttr||a.placed)){var b=a.alignAttr||{x:a.attr("x"),y:a.attr("y")};var k=a.parentGroup;a.width||(c=a.getBBox(),a.width=c.width,a.height=c.height,c=e.fontMetrics(null,a.element).h);var l=a.width-2*f;(d={left:"0",center:"0.5",right:"1"}[a.alignValue])?g=+d*l:J(a.x)&&
Math.round(a.x)!==a.translateX&&(g=a.x-a.translateX);return{x:b.x+(k.translateX||0)+f-(g||0),y:b.y+(k.translateY||0)+f-c,width:a.width-2*f,height:a.height-2*f}}};for(f=0;f<c;f++)if(l=a[f])l.oldOpacity=l.opacity,l.newOpacity=1,l.absoluteBox=k(l);a.sort(function(a,c){return(c.labelrank||0)-(a.labelrank||0)});for(f=0;f<c;f++){var u=(k=a[f])&&k.absoluteBox;for(l=f+1;l<c;++l){var w=(m=a[l])&&m.absoluteBox;!u||!w||k===m||0===k.newOpacity||0===m.newOpacity||w.x>=u.x+u.width||w.x+w.width<=u.x||w.y>=u.y+u.height||
w.y+w.height<=u.y||((k.labelrank<m.labelrank?k:m).newOpacity=0)}}a.forEach(function(a){r(a,g)&&(n=!0)});n&&z(g,"afterHideAllOverlappingLabels")}});M(a,"Core/Responsive.js",[a["Core/Utilities.js"]],function(a){var r=a.extend,C=a.find,E=a.isArray,z=a.isObject,x=a.merge,J=a.objectEach,u=a.pick,n=a.splat,m=a.uniqueKey,g;(function(a){var c=[];a.compose=function(a){-1===c.indexOf(a)&&(c.push(a),r(a.prototype,g.prototype));return a};var g=function(){function a(){}a.prototype.currentOptions=function(a){function c(a,
f,g,k){var h;J(a,function(a,b){if(!k&&-1<e.collectionsWithUpdate.indexOf(b)&&f[b])for(a=n(a),g[b]=[],h=0;h<Math.max(a.length,f[b].length);h++)f[b][h]&&(void 0===a[h]?g[b][h]=f[b][h]:(g[b][h]={},c(a[h],f[b][h],g[b][h],k+1)));else z(a)?(g[b]=E(a)?[]:{},c(a,f[b]||{},g[b],k+1)):g[b]="undefined"===typeof f[b]?null:f[b]})}var e=this,f={};c(a,this.options,f,0);return f};a.prototype.matchResponsiveRule=function(a,c){var e=a.condition;(e.callback||function(){return this.chartWidth<=u(e.maxWidth,Number.MAX_VALUE)&&
this.chartHeight<=u(e.maxHeight,Number.MAX_VALUE)&&this.chartWidth>=u(e.minWidth,0)&&this.chartHeight>=u(e.minHeight,0)}).call(this)&&c.push(a._id)};a.prototype.setResponsive=function(a,c){var e=this,f=this.options.responsive,g=this.currentResponsive,l=[];!c&&f&&f.rules&&f.rules.forEach(function(a){"undefined"===typeof a._id&&(a._id=m());e.matchResponsiveRule(a,l)},this);c=x.apply(void 0,l.map(function(a){return C((f||{}).rules||[],function(c){return c._id===a})}).map(function(a){return a&&a.chartOptions}));
c.isResponsiveOptions=!0;l=l.toString()||void 0;l!==(g&&g.ruleIds)&&(g&&this.update(g.undoOptions,a,!0),l?(g=this.currentOptions(c),g.isResponsiveOptions=!0,this.currentResponsive={ruleIds:l,mergedOptions:c,undoOptions:g},this.update(c,a,!0)):this.currentResponsive=void 0)};return a}()})(g||(g={}));"";"";return g});M(a,"masters/highcharts.src.js",[a["Core/Globals.js"],a["Core/Utilities.js"],a["Core/DefaultOptions.js"],a["Core/Animation/Fx.js"],a["Core/Animation/AnimationUtilities.js"],a["Core/Renderer/HTML/AST.js"],
a["Core/FormatUtilities.js"],a["Core/Renderer/RendererUtilities.js"],a["Core/Renderer/SVG/SVGElement.js"],a["Core/Renderer/SVG/SVGRenderer.js"],a["Core/Renderer/HTML/HTMLElement.js"],a["Core/Renderer/HTML/HTMLRenderer.js"],a["Core/Axis/Axis.js"],a["Core/Axis/DateTimeAxis.js"],a["Core/Axis/LogarithmicAxis.js"],a["Core/Axis/PlotLineOrBand/PlotLineOrBand.js"],a["Core/Axis/Tick.js"],a["Core/Tooltip.js"],a["Core/Series/Point.js"],a["Core/Pointer.js"],a["Core/MSPointer.js"],a["Core/Legend/Legend.js"],a["Core/Chart/Chart.js"],
a["Core/Series/Series.js"],a["Core/Series/SeriesRegistry.js"],a["Series/Column/ColumnSeries.js"],a["Series/Column/ColumnDataLabel.js"],a["Series/Pie/PieSeries.js"],a["Series/Pie/PieDataLabel.js"],a["Core/Series/DataLabel.js"],a["Core/Responsive.js"],a["Core/Color/Color.js"],a["Core/Time.js"]],function(a,w,C,E,z,x,J,u,n,m,g,c,e,l,f,v,q,k,I,D,B,M,t,h,d,b,p,G,y,L,F,P,S){a.animate=z.animate;a.animObject=z.animObject;a.getDeferredAnimation=z.getDeferredAnimation;a.setAnimation=z.setAnimation;a.stop=z.stop;
a.timers=E.timers;a.AST=x;a.Axis=e;a.Chart=t;a.chart=t.chart;a.Fx=E;a.Legend=M;a.PlotLineOrBand=v;a.Point=I;a.Pointer=B.isRequired()?B:D;a.Series=h;a.SVGElement=n;a.SVGRenderer=m;a.Tick=q;a.Time=S;a.Tooltip=k;a.Color=P;a.color=P.parse;c.compose(m);g.compose(n);a.defaultOptions=C.defaultOptions;a.getOptions=C.getOptions;a.time=C.defaultTime;a.setOptions=C.setOptions;a.dateFormat=J.dateFormat;a.format=J.format;a.numberFormat=J.numberFormat;a.addEvent=w.addEvent;a.arrayMax=w.arrayMax;a.arrayMin=w.arrayMin;
a.attr=w.attr;a.clearTimeout=w.clearTimeout;a.correctFloat=w.correctFloat;a.createElement=w.createElement;a.css=w.css;a.defined=w.defined;a.destroyObjectProperties=w.destroyObjectProperties;a.discardElement=w.discardElement;a.distribute=u.distribute;a.erase=w.erase;a.error=w.error;a.extend=w.extend;a.extendClass=w.extendClass;a.find=w.find;a.fireEvent=w.fireEvent;a.getMagnitude=w.getMagnitude;a.getStyle=w.getStyle;a.inArray=w.inArray;a.isArray=w.isArray;a.isClass=w.isClass;a.isDOMElement=w.isDOMElement;
a.isFunction=w.isFunction;a.isNumber=w.isNumber;a.isObject=w.isObject;a.isString=w.isString;a.keys=w.keys;a.merge=w.merge;a.normalizeTickInterval=w.normalizeTickInterval;a.objectEach=w.objectEach;a.offset=w.offset;a.pad=w.pad;a.pick=w.pick;a.pInt=w.pInt;a.relativeLength=w.relativeLength;a.removeEvent=w.removeEvent;a.seriesType=d.seriesType;a.splat=w.splat;a.stableSort=w.stableSort;a.syncTimeout=w.syncTimeout;a.timeUnits=w.timeUnits;a.uniqueKey=w.uniqueKey;a.useSerialIds=w.useSerialIds;a.wrap=w.wrap;
p.compose(b);L.compose(h);l.compose(e);f.compose(e);y.compose(G);v.compose(e);F.compose(t);return a});a["masters/highcharts.src.js"]._modules=a;return a["masters/highcharts.src.js"]});
//# sourceMappingURL=highcharts.js.map
/*
 Highcharts JS v9.2.2 (2021-08-24)

 (c) 2009-2021 Torstein Honsi

 License: www.highcharts.com/license
*/
'use strict';(function(e){"object"===typeof module&&module.exports?(e["default"]=e,module.exports=e):"function"===typeof define&&define.amd?define("highcharts/highcharts-more",["highcharts"],function(z){e(z);e.Highcharts=z;return e}):e("undefined"!==typeof Highcharts?Highcharts:void 0)})(function(e){function z(e,d,h,c){e.hasOwnProperty(d)||(e[d]=c.apply(null,h))}e=e?e._modules:{};z(e,"Extensions/Pane.js",[e["Core/Chart/Chart.js"],e["Core/Globals.js"],e["Core/Color/Palette.js"],e["Core/Pointer.js"],
e["Core/Utilities.js"],e["Mixins/CenteredSeries.js"]],function(e,d,h,c,a,t){function m(b,p,a){return Math.sqrt(Math.pow(b-a[0],2)+Math.pow(p-a[1],2))<=a[2]/2}var l=a.addEvent,r=a.extend,x=a.merge,b=a.pick,q=a.splat;e.prototype.collectionsWithUpdate.push("pane");a=function(){function b(b,a){this.options=this.chart=this.center=this.background=void 0;this.coll="pane";this.defaultOptions={center:["50%","50%"],size:"85%",innerSize:"0%",startAngle:0};this.defaultBackgroundOptions={shape:"circle",borderWidth:1,
borderColor:h.neutralColor20,backgroundColor:{linearGradient:{x1:0,y1:0,x2:0,y2:1},stops:[[0,h.backgroundColor],[1,h.neutralColor10]]},from:-Number.MAX_VALUE,innerRadius:0,to:Number.MAX_VALUE,outerRadius:"105%"};this.init(b,a)}b.prototype.init=function(b,a){this.chart=a;this.background=[];a.pane.push(this);this.setOptions(b)};b.prototype.setOptions=function(b){this.options=x(this.defaultOptions,this.chart.angular?{background:{}}:void 0,b)};b.prototype.render=function(){var b=this.options,a=this.options.background,
k=this.chart.renderer;this.group||(this.group=k.g("pane-group").attr({zIndex:b.zIndex||0}).add());this.updateCenter();if(a)for(a=q(a),b=Math.max(a.length,this.background.length||0),k=0;k<b;k++)a[k]&&this.axis?this.renderBackground(x(this.defaultBackgroundOptions,a[k]),k):this.background[k]&&(this.background[k]=this.background[k].destroy(),this.background.splice(k,1))};b.prototype.renderBackground=function(b,a){var k="animate",p={"class":"highcharts-pane "+(b.className||"")};this.chart.styledMode||
r(p,{fill:b.backgroundColor,stroke:b.borderColor,"stroke-width":b.borderWidth});this.background[a]||(this.background[a]=this.chart.renderer.path().add(this.group),k="attr");this.background[a][k]({d:this.axis.getPlotBandPath(b.from,b.to,b)}).attr(p)};b.prototype.updateCenter=function(b){this.center=(b||this.axis||{}).center=t.getCenter.call(this)};b.prototype.update=function(b,a){x(!0,this.options,b);this.setOptions(this.options);this.render();this.chart.axes.forEach(function(b){b.pane===this&&(b.pane=
null,b.update({},a))},this)};return b}();e.prototype.getHoverPane=function(b){var a=this,k;b&&a.pane.forEach(function(p){var q=b.chartX-a.plotLeft,v=b.chartY-a.plotTop;m(a.inverted?v:q,a.inverted?q:v,p.center)&&(k=p)});return k};l(e,"afterIsInsidePlot",function(b){this.polar&&(b.isInsidePlot=this.pane.some(function(a){return m(b.x,b.y,a.center)}))});l(c,"beforeGetHoverData",function(a){var k=this.chart;k.polar?(k.hoverPane=k.getHoverPane(a),a.filter=function(q){return q.visible&&!(!a.shared&&q.directTouch)&&
b(q.options.enableMouseTracking,!0)&&(!k.hoverPane||q.xAxis.pane===k.hoverPane)}):k.hoverPane=void 0});l(c,"afterGetHoverData",function(b){var a=this.chart;b.hoverPoint&&b.hoverPoint.plotX&&b.hoverPoint.plotY&&a.hoverPane&&!m(b.hoverPoint.plotX,b.hoverPoint.plotY,a.hoverPane.center)&&(b.hoverPoint=void 0)});d.Pane=a;return d.Pane});z(e,"Core/Axis/RadialAxis.js",[e["Core/Axis/AxisDefaults.js"],e["Core/DefaultOptions.js"],e["Core/Globals.js"],e["Core/Utilities.js"]],function(e,d,h,c){var a=d.defaultOptions,
t=h.noop,m=c.addEvent,l=c.correctFloat,r=c.defined,x=c.extend,b=c.fireEvent,q=c.merge,k=c.pick,p=c.relativeLength,v=c.wrap,B;(function(c){function d(){this.autoConnect=this.isCircular&&"undefined"===typeof k(this.userMax,this.options.max)&&l(this.endAngleRad-this.startAngleRad)===l(2*Math.PI);!this.isCircular&&this.chart.inverted&&this.max++;this.autoConnect&&(this.max+=this.categories&&1||this.pointRange||this.closestPointRange||0)}function y(){var f=this;return function(){if(f.isRadial&&f.tickPositions&&
f.options.labels&&!0!==f.options.labels.allowOverlap)return f.tickPositions.map(function(g){return f.ticks[g]&&f.ticks[g].label}).filter(function(f){return!!f})}}function h(){return t}function g(f,g,b){var n=this.pane.center,u=f.value;if(this.isCircular){if(r(u))f.point&&(a=f.point.shapeArgs||{},a.start&&(u=this.chart.inverted?this.translate(f.point.rectPlotY,!0):f.point.x));else{var a=f.chartX||0;var w=f.chartY||0;u=this.translate(Math.atan2(w-b,a-g)-this.startAngleRad,!0)}f=this.getPosition(u);
a=f.x;w=f.y}else r(u)||(a=f.chartX,w=f.chartY),r(a)&&r(w)&&(b=n[1]+this.chart.plotTop,u=this.translate(Math.min(Math.sqrt(Math.pow(a-g,2)+Math.pow(w-b,2)),n[2]/2)-n[3]/2,!0));return[u,a||0,w||0]}function f(f,g,b){f=this.pane.center;var u=this.chart,n=this.left||0,a=this.top||0,w=k(g,f[2]/2-this.offset);"undefined"===typeof b&&(b=this.horiz?0:this.center&&-this.center[3]/2);b&&(w+=b);this.isCircular||"undefined"!==typeof g?(g=this.chart.renderer.symbols.arc(n+f[0],a+f[1],w,w,{start:this.startAngleRad,
end:this.endAngleRad,open:!0,innerR:0}),g.xBounds=[n+f[0]],g.yBounds=[a+f[1]-w]):(g=this.postTranslate(this.angleRad,w),g=[["M",this.center[0]+u.plotLeft,this.center[1]+u.plotTop],["L",g.x,g.y]]);return g}function u(){this.constructor.prototype.getOffset.call(this);this.chart.axisOffset[this.side]=0}function n(f,g,b){var u=this.chart,n=function(f){if("string"===typeof f){var g=parseInt(f,10);y.test(f)&&(g=g*A/100);return g}return f},a=this.center,w=this.startAngleRad,A=a[2]/2,q=Math.min(this.offset,
0),p=this.left||0,v=this.top||0,y=/%$/,F=this.isCircular,c=k(n(b.outerRadius),A),d=n(b.innerRadius);n=k(n(b.thickness),10);if("polygon"===this.options.gridLineInterpolation)q=this.getPlotLinePath({value:f}).concat(this.getPlotLinePath({value:g,reverse:!0}));else{f=Math.max(f,this.min);g=Math.min(g,this.max);f=this.translate(f);g=this.translate(g);F||(c=f||0,d=g||0);if("circle"!==b.shape&&F)b=w+(f||0),w+=g||0;else{b=-Math.PI/2;w=1.5*Math.PI;var l=!0}c-=q;q=u.renderer.symbols.arc(p+a[0],v+a[1],c,c,
{start:Math.min(b,w),end:Math.max(b,w),innerR:k(d,c-(n-q)),open:l});F&&(F=(w+b)/2,p=p+a[0]+a[2]/2*Math.cos(F),q.xBounds=F>-Math.PI/2&&F<Math.PI/2?[p,u.plotWidth]:[0,p],q.yBounds=[v+a[1]+a[2]/2*Math.sin(F)],q.yBounds[0]+=F>-Math.PI&&0>F||F>Math.PI?-10:10)}return q}function w(f){var g=this,b=this.pane.center,n=this.chart,u=n.inverted,a=f.reverse,w=this.pane.options.background?this.pane.options.background[0]||this.pane.options.background:{},q=w.innerRadius||"0%",A=w.outerRadius||"100%",k=b[0]+n.plotLeft,
v=b[1]+n.plotTop,F=this.height,y=f.isCrosshair;w=b[3]/2;var c=f.value,d;var l=this.getPosition(c);var h=l.x;l=l.y;y&&(l=this.getCrosshairPosition(f,k,v),c=l[0],h=l[1],l=l[2]);if(this.isCircular)c=Math.sqrt(Math.pow(h-k,2)+Math.pow(l-v,2)),a="string"===typeof q?p(q,1):q/c,n="string"===typeof A?p(A,1):A/c,b&&w&&(w/=c,a<w&&(a=w),n<w&&(n=w)),b=[["M",k+a*(h-k),v-a*(v-l)],["L",h-(1-n)*(h-k),l+(1-n)*(v-l)]];else if((c=this.translate(c))&&(0>c||c>F)&&(c=0),"circle"===this.options.gridLineInterpolation)b=
this.getLinePath(0,c,w);else if(b=[],n[u?"yAxis":"xAxis"].forEach(function(f){f.pane===g.pane&&(d=f)}),d)for(k=d.tickPositions,d.autoConnect&&(k=k.concat([k[0]])),a&&(k=k.slice().reverse()),c&&(c+=w),v=0;v<k.length;v++)w=d.getPosition(k[v],c),b.push(v?["L",w.x,w.y]:["M",w.x,w.y]);return b}function A(f,g){f=this.translate(f);return this.postTranslate(this.isCircular?f:this.angleRad,k(this.isCircular?g:0>f?0:f,this.center[2]/2)-this.offset)}function F(){var f=this.center,g=this.chart,b=this.options.title;
return{x:g.plotLeft+f[0]+(b.x||0),y:g.plotTop+f[1]-{high:.5,middle:.25,low:0}[b.align]*f[2]+(b.y||0)}}function J(b){b.beforeSetTickPositions=d;b.createLabelCollector=y;b.getCrosshairPosition=g;b.getLinePath=f;b.getOffset=u;b.getPlotBandPath=n;b.getPlotLinePath=w;b.getPosition=A;b.getTitlePosition=F;b.postTranslate=N;b.setAxisSize=E;b.setAxisTranslation=z;b.setOptions=O}function B(){var f=this.chart,g=this.options,b=this.pane,n=b&&b.options;f.angular&&this.isXAxis||!b||!f.angular&&!f.polar||(this.angleRad=
(g.angle||0)*Math.PI/180,this.startAngleRad=(n.startAngle-90)*Math.PI/180,this.endAngleRad=(k(n.endAngle,n.startAngle+360)-90)*Math.PI/180,this.offset=g.offset||0)}function P(f){this.isRadial&&(f.align=void 0,f.preventDefault())}function H(){if(this.chart&&this.chart.labelCollectors){var f=this.labelCollector?this.chart.labelCollectors.indexOf(this.labelCollector):-1;0<=f&&this.chart.labelCollectors.splice(f,1)}}function K(f){var g=this.chart,b=g.inverted,n=g.angular,u=g.polar,a=this.isXAxis,w=this.coll,
k=n&&a,A=g.options;f=f.userOptions.pane||0;f=this.pane=g.pane&&g.pane[f];var p;if("colorAxis"===w)this.isRadial=!1;else{if(n){if(k?(this.isHidden=!0,this.createLabelCollector=h,this.getOffset=t,this.render=this.redraw=Q,this.setTitle=this.setCategories=this.setScale=t):J(this),p=!a)this.defaultPolarOptions=R}else u&&(J(this),this.defaultPolarOptions=(p=this.horiz)?S:q("xAxis"===w?e.defaultXAxisOptions:e.defaultYAxisOptions,T),b&&"yAxis"===w&&(this.defaultPolarOptions.stackLabels=e.defaultYAxisOptions.stackLabels,
this.defaultPolarOptions.reversedStacks=!0));n||u?(this.isRadial=!0,A.chart.zoomType=null,this.labelCollector||(this.labelCollector=this.createLabelCollector()),this.labelCollector&&g.labelCollectors.push(this.labelCollector)):this.isRadial=!1;f&&p&&(f.axis=this);this.isCircular=p}}function C(){this.isRadial&&this.beforeSetTickPositions()}function D(f){var g=this.label;if(g){var b=this.axis,n=g.getBBox(),u=b.options.labels,a=(b.translate(this.pos)+b.startAngleRad+Math.PI/2)/Math.PI*180%360,w=Math.round(a),
q=r(u.y)?0:.3*-n.height,A=u.y,v=20,F=u.align,c="end",y=0>w?w+360:w,l=y,d=0,h=0;if(b.isRadial){var m=b.getPosition(this.pos,b.center[2]/2+p(k(u.distance,-25),b.center[2]/2,-b.center[2]/2));"auto"===u.rotation?g.attr({rotation:a}):r(A)||(A=b.chart.renderer.fontMetrics(g.styles&&g.styles.fontSize).b-n.height/2);r(F)||(b.isCircular?(n.width>b.len*b.tickInterval/(b.max-b.min)&&(v=0),F=a>v&&a<180-v?"left":a>180+v&&a<360-v?"right":"center"):F="center",g.attr({align:F}));if("auto"===F&&2===b.tickPositions.length&&
b.isCircular){90<y&&180>y?y=180-y:270<y&&360>=y&&(y=540-y);180<l&&360>=l&&(l=360-l);if(b.pane.options.startAngle===w||b.pane.options.startAngle===w+360||b.pane.options.startAngle===w-360)c="start";F=-90<=w&&90>=w||-360<=w&&-270>=w||270<=w&&360>=w?"start"===c?"right":"left":"start"===c?"left":"right";70<l&&110>l&&(F="center");15>y||180<=y&&195>y?d=.3*n.height:15<=y&&35>=y?d="start"===c?0:.75*n.height:195<=y&&215>=y?d="start"===c?.75*n.height:0:35<y&&90>=y?d="start"===c?.25*-n.height:n.height:215<y&&
270>=y&&(d="start"===c?n.height:.25*-n.height);15>l?h="start"===c?.15*-n.height:.15*n.height:165<l&&180>=l&&(h="start"===c?.15*n.height:.15*-n.height);g.attr({align:F});g.translate(h,d+q)}f.pos.x=m.x+(u.x||0);f.pos.y=m.y+(A||0)}}}function G(f){this.axis.getPosition&&x(f.pos,this.axis.getPosition(this.pos))}function N(f,g){var b=this.chart,n=this.center;f=this.startAngleRad+f;return{x:b.plotLeft+n[0]+Math.cos(f)*g,y:b.plotTop+n[1]+Math.sin(f)*g}}function Q(){this.isDirty=!1}function E(){this.constructor.prototype.setAxisSize.call(this);
if(this.isRadial){this.pane.updateCenter(this);var f=this.center=this.pane.center.slice();if(this.isCircular)this.sector=this.endAngleRad-this.startAngleRad;else{var g=this.postTranslate(this.angleRad,f[3]/2);f[0]=g.x-this.chart.plotLeft;f[1]=g.y-this.chart.plotTop}this.len=this.width=this.height=(f[2]-f[3])*k(this.sector,1)/2}}function z(){this.constructor.prototype.setAxisTranslation.call(this);this.center&&(this.transA=this.isCircular?(this.endAngleRad-this.startAngleRad)/(this.max-this.min||1):
(this.center[2]-this.center[3])/2/(this.max-this.min||1),this.minPixelPadding=this.isXAxis?this.transA*this.minPointOffset:0)}function O(f){f=this.options=q(this.constructor.defaultOptions,this.defaultPolarOptions,a[this.coll],f);f.plotBands||(f.plotBands=[]);b(this,"afterSetOptions")}function U(f,g,b,n,u,w,a){var k=this.axis;k.isRadial?(f=k.getPosition(this.pos,k.center[2]/2+n),g=["M",g,b,"L",f.x,f.y]):g=f.call(this,g,b,n,u,w,a);return g}var M=[],S={gridLineWidth:1,labels:{align:void 0,distance:15,
x:0,y:void 0,style:{textOverflow:"none"}},maxPadding:0,minPadding:0,showLastLabel:!1,tickLength:0},R={labels:{align:"center",x:0,y:void 0},minorGridLineWidth:0,minorTickInterval:"auto",minorTickLength:10,minorTickPosition:"inside",minorTickWidth:1,tickLength:10,tickPosition:"inside",tickWidth:2,title:{rotation:0},zIndex:2},T={gridLineInterpolation:"circle",gridLineWidth:1,labels:{align:"right",x:-3,y:-2},showLastLabel:!1,title:{x:4,text:null,rotation:90}};c.compose=function(f,g){-1===M.indexOf(f)&&
(M.push(f),m(f,"afterInit",B),m(f,"autoLabelAlign",P),m(f,"destroy",H),m(f,"init",K),m(f,"initialAxisTranslation",C));-1===M.indexOf(g)&&(M.push(g),m(g,"afterGetLabelPosition",D),m(g,"afterGetPosition",G),v(g.prototype,"getMarkPath",U));return f}})(B||(B={}));return B});z(e,"Series/AreaRange/AreaRangePoint.js",[e["Series/Area/AreaSeries.js"],e["Core/Series/Point.js"],e["Core/Utilities.js"]],function(e,d,h){var c=this&&this.__extends||function(){var a=function(c,l){a=Object.setPrototypeOf||{__proto__:[]}instanceof
Array&&function(b,a){b.__proto__=a}||function(b,a){for(var k in a)a.hasOwnProperty(k)&&(b[k]=a[k])};return a(c,l)};return function(c,l){function b(){this.constructor=c}a(c,l);c.prototype=null===l?Object.create(l):(b.prototype=l.prototype,new b)}}(),a=d.prototype,t=h.defined,m=h.isNumber;return function(l){function d(){var a=null!==l&&l.apply(this,arguments)||this;a.high=void 0;a.low=void 0;a.options=void 0;a.plotHigh=void 0;a.plotLow=void 0;a.plotHighX=void 0;a.plotLowX=void 0;a.plotX=void 0;a.series=
void 0;return a}c(d,l);d.prototype.setState=function(){var c=this.state,b=this.series,q=b.chart.polar;t(this.plotHigh)||(this.plotHigh=b.yAxis.toPixels(this.high,!0));t(this.plotLow)||(this.plotLow=this.plotY=b.yAxis.toPixels(this.low,!0));b.stateMarkerGraphic&&(b.lowerStateMarkerGraphic=b.stateMarkerGraphic,b.stateMarkerGraphic=b.upperStateMarkerGraphic);this.graphic=this.upperGraphic;this.plotY=this.plotHigh;q&&(this.plotX=this.plotHighX);a.setState.apply(this,arguments);this.state=c;this.plotY=
this.plotLow;this.graphic=this.lowerGraphic;q&&(this.plotX=this.plotLowX);b.stateMarkerGraphic&&(b.upperStateMarkerGraphic=b.stateMarkerGraphic,b.stateMarkerGraphic=b.lowerStateMarkerGraphic,b.lowerStateMarkerGraphic=void 0);a.setState.apply(this,arguments)};d.prototype.haloPath=function(){var c=this.series.chart.polar,b=[];this.plotY=this.plotLow;c&&(this.plotX=this.plotLowX);this.isInside&&(b=a.haloPath.apply(this,arguments));this.plotY=this.plotHigh;c&&(this.plotX=this.plotHighX);this.isTopInside&&
(b=b.concat(a.haloPath.apply(this,arguments)));return b};d.prototype.isValid=function(){return m(this.low)&&m(this.high)};return d}(e.prototype.pointClass)});z(e,"Series/AreaRange/AreaRangeSeries.js",[e["Series/AreaRange/AreaRangePoint.js"],e["Series/Area/AreaSeries.js"],e["Series/Column/ColumnSeries.js"],e["Core/Globals.js"],e["Core/Series/Series.js"],e["Core/Series/SeriesRegistry.js"],e["Core/Utilities.js"]],function(e,d,h,c,a,t,m){var l=this&&this.__extends||function(){var b=function(a,k){b=Object.setPrototypeOf||
{__proto__:[]}instanceof Array&&function(b,g){b.__proto__=g}||function(b,g){for(var f in g)g.hasOwnProperty(f)&&(b[f]=g[f])};return b(a,k)};return function(a,k){function q(){this.constructor=a}b(a,k);a.prototype=null===k?Object.create(k):(q.prototype=k.prototype,new q)}}(),r=d.prototype,x=h.prototype;h=c.noop;var b=a.prototype,q=m.defined,k=m.extend,p=m.isArray,v=m.pick,B=m.merge;a=function(a){function c(){var b=null!==a&&a.apply(this,arguments)||this;b.data=void 0;b.options=void 0;b.points=void 0;
b.lowerStateMarkerGraphic=void 0;b.xAxis=void 0;return b}l(c,a);c.prototype.toYData=function(b){return[b.low,b.high]};c.prototype.highToXY=function(b){var a=this.chart,g=this.xAxis.postTranslate(b.rectPlotX||0,this.yAxis.len-b.plotHigh);b.plotHighX=g.x-a.plotLeft;b.plotHigh=g.y-a.plotTop;b.plotLowX=b.plotX};c.prototype.translate=function(){var b=this,a=b.yAxis,g=!!b.modifyValue;r.translate.apply(b);b.points.forEach(function(f){var u=f.high,n=f.plotY;f.isNull?f.plotY=null:(f.plotLow=n,f.plotHigh=a.translate(g?
b.modifyValue(u,f):u,0,1,0,1),g&&(f.yBottom=f.plotHigh))});this.chart.polar&&this.points.forEach(function(f){b.highToXY(f);f.tooltipPos=[(f.plotHighX+f.plotLowX)/2,(f.plotHigh+f.plotLow)/2]})};c.prototype.getGraphPath=function(b){var a=[],g=[],f,u=r.getGraphPath;var n=this.options;var w=this.chart.polar,k=w&&!1!==n.connectEnds,q=n.connectNulls,c=n.step;b=b||this.points;for(f=b.length;f--;){var p=b[f];var l=w?{plotX:p.rectPlotX,plotY:p.yBottom,doCurve:!1}:{plotX:p.plotX,plotY:p.plotY,doCurve:!1};p.isNull||
k||q||b[f+1]&&!b[f+1].isNull||g.push(l);var d={polarPlotY:p.polarPlotY,rectPlotX:p.rectPlotX,yBottom:p.yBottom,plotX:v(p.plotHighX,p.plotX),plotY:p.plotHigh,isNull:p.isNull};g.push(d);a.push(d);p.isNull||k||q||b[f-1]&&!b[f-1].isNull||g.push(l)}b=u.call(this,b);c&&(!0===c&&(c="left"),n.step={left:"right",center:"center",right:"left"}[c]);a=u.call(this,a);g=u.call(this,g);n.step=c;n=[].concat(b,a);!this.chart.polar&&g[0]&&"M"===g[0][0]&&(g[0]=["L",g[0][1],g[0][2]]);this.graphPath=n;this.areaPath=b.concat(g);
n.isArea=!0;n.xMap=b.xMap;this.areaPath.xMap=b.xMap;return n};c.prototype.drawDataLabels=function(){var a=this.points,q=a.length,g,f=[],u=this.options.dataLabels,n,w=this.chart.inverted;if(u){if(p(u)){var A=u[0]||{enabled:!1};var c=u[1]||{enabled:!1}}else A=k({},u),A.x=u.xHigh,A.y=u.yHigh,c=k({},u),c.x=u.xLow,c.y=u.yLow;if(A.enabled||this._hasPointLabels){for(g=q;g--;)if(n=a[g]){var v=A.inside?n.plotHigh<n.plotLow:n.plotHigh>n.plotLow;n.y=n.high;n._plotY=n.plotY;n.plotY=n.plotHigh;f[g]=n.dataLabel;
n.dataLabel=n.dataLabelUpper;n.below=v;w?A.align||(A.align=v?"right":"left"):A.verticalAlign||(A.verticalAlign=v?"top":"bottom")}this.options.dataLabels=A;b.drawDataLabels&&b.drawDataLabels.apply(this,arguments);for(g=q;g--;)if(n=a[g])n.dataLabelUpper=n.dataLabel,n.dataLabel=f[g],delete n.dataLabels,n.y=n.low,n.plotY=n._plotY}if(c.enabled||this._hasPointLabels){for(g=q;g--;)if(n=a[g])v=c.inside?n.plotHigh<n.plotLow:n.plotHigh>n.plotLow,n.below=!v,w?c.align||(c.align=v?"left":"right"):c.verticalAlign||
(c.verticalAlign=v?"bottom":"top");this.options.dataLabels=c;b.drawDataLabels&&b.drawDataLabels.apply(this,arguments)}if(A.enabled)for(g=q;g--;)if(n=a[g])n.dataLabels=[n.dataLabelUpper,n.dataLabel].filter(function(f){return!!f});this.options.dataLabels=u}};c.prototype.alignDataLabel=function(){x.alignDataLabel.apply(this,arguments)};c.prototype.drawPoints=function(){var a=this.points.length,c;b.drawPoints.apply(this,arguments);for(c=0;c<a;){var g=this.points[c];g.origProps={plotY:g.plotY,plotX:g.plotX,
isInside:g.isInside,negative:g.negative,zone:g.zone,y:g.y};g.lowerGraphic=g.graphic;g.graphic=g.upperGraphic;g.plotY=g.plotHigh;q(g.plotHighX)&&(g.plotX=g.plotHighX);g.y=v(g.high,g.origProps.y);g.negative=g.y<(this.options.threshold||0);this.zones.length&&(g.zone=g.getZone());this.chart.polar||(g.isInside=g.isTopInside="undefined"!==typeof g.plotY&&0<=g.plotY&&g.plotY<=this.yAxis.len&&0<=g.plotX&&g.plotX<=this.xAxis.len);c++}b.drawPoints.apply(this,arguments);for(c=0;c<a;)g=this.points[c],g.upperGraphic=
g.graphic,g.graphic=g.lowerGraphic,g.origProps&&(k(g,g.origProps),delete g.origProps),c++};c.defaultOptions=B(d.defaultOptions,{lineWidth:1,threshold:null,tooltip:{pointFormat:'<span style="color:{series.color}">\u25cf</span> {series.name}: <b>{point.low}</b> - <b>{point.high}</b><br/>'},trackByArea:!0,dataLabels:{align:void 0,verticalAlign:void 0,xLow:0,xHigh:0,yLow:0,yHigh:0}});return c}(d);k(a.prototype,{pointArrayMap:["low","high"],pointValKey:"low",deferTranslatePolar:!0,pointClass:e,setStackedPoints:h});
t.registerSeriesType("arearange",a);"";return a});z(e,"Series/AreaSplineRange/AreaSplineRangeSeries.js",[e["Series/AreaRange/AreaRangeSeries.js"],e["Core/Series/SeriesRegistry.js"],e["Core/Utilities.js"]],function(e,d,h){var c=this&&this.__extends||function(){var a=function(c,l){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(b,a){b.__proto__=a}||function(b,a){for(var c in a)a.hasOwnProperty(c)&&(b[c]=a[c])};return a(c,l)};return function(c,l){function b(){this.constructor=c}a(c,
l);c.prototype=null===l?Object.create(l):(b.prototype=l.prototype,new b)}}(),a=d.seriesTypes.spline,t=h.merge;h=h.extend;var m=function(a){function l(){var c=null!==a&&a.apply(this,arguments)||this;c.options=void 0;c.data=void 0;c.points=void 0;return c}c(l,a);l.defaultOptions=t(e.defaultOptions);return l}(e);h(m.prototype,{getPointSpline:a.prototype.getPointSpline});d.registerSeriesType("areasplinerange",m);"";return m});z(e,"Series/BoxPlot/BoxPlotSeries.js",[e["Series/Column/ColumnSeries.js"],e["Core/Globals.js"],
e["Core/Color/Palette.js"],e["Core/Series/SeriesRegistry.js"],e["Core/Utilities.js"]],function(e,d,h,c,a){var t=this&&this.__extends||function(){var a=function(b,c){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(b,a){b.__proto__=a}||function(b,a){for(var c in a)a.hasOwnProperty(c)&&(b[c]=a[c])};return a(b,c)};return function(b,c){function k(){this.constructor=b}a(b,c);b.prototype=null===c?Object.create(c):(k.prototype=c.prototype,new k)}}();d=d.noop;var m=a.extend,l=a.merge,r=a.pick;
a=function(a){function b(){var b=null!==a&&a.apply(this,arguments)||this;b.data=void 0;b.options=void 0;b.points=void 0;return b}t(b,a);b.prototype.pointAttribs=function(){return{}};b.prototype.translate=function(){var b=this.yAxis,c=this.pointArrayMap;a.prototype.translate.apply(this);this.points.forEach(function(a){c.forEach(function(c){null!==a[c]&&(a[c+"Plot"]=b.translate(a[c],0,1,0,1))});a.plotHigh=a.highPlot})};b.prototype.drawPoints=function(){var b=this,a=b.options,c=b.chart,v=c.renderer,
l,d,h,m,e,g,f=0,u,n,w,A,F=!1!==b.doQuartiles,t,x=b.options.whiskerLength;b.points.forEach(function(k){var p=k.graphic,q=p?"animate":"attr",y=k.shapeArgs,B={},J={},L={},H={},I=k.color||b.color;"undefined"!==typeof k.plotY&&(u=Math.round(y.width),n=Math.floor(y.x),w=n+u,A=Math.round(u/2),l=Math.floor(F?k.q1Plot:k.lowPlot),d=Math.floor(F?k.q3Plot:k.lowPlot),h=Math.floor(k.highPlot),m=Math.floor(k.lowPlot),p||(k.graphic=p=v.g("point").add(b.group),k.stem=v.path().addClass("highcharts-boxplot-stem").add(p),
x&&(k.whiskers=v.path().addClass("highcharts-boxplot-whisker").add(p)),F&&(k.box=v.path(void 0).addClass("highcharts-boxplot-box").add(p)),k.medianShape=v.path(void 0).addClass("highcharts-boxplot-median").add(p)),c.styledMode||(J.stroke=k.stemColor||a.stemColor||I,J["stroke-width"]=r(k.stemWidth,a.stemWidth,a.lineWidth),J.dashstyle=k.stemDashStyle||a.stemDashStyle||a.dashStyle,k.stem.attr(J),x&&(L.stroke=k.whiskerColor||a.whiskerColor||I,L["stroke-width"]=r(k.whiskerWidth,a.whiskerWidth,a.lineWidth),
L.dashstyle=k.whiskerDashStyle||a.whiskerDashStyle||a.dashStyle,k.whiskers.attr(L)),F&&(B.fill=k.fillColor||a.fillColor||I,B.stroke=a.lineColor||I,B["stroke-width"]=a.lineWidth||0,B.dashstyle=k.boxDashStyle||a.boxDashStyle||a.dashStyle,k.box.attr(B)),H.stroke=k.medianColor||a.medianColor||I,H["stroke-width"]=r(k.medianWidth,a.medianWidth,a.lineWidth),H.dashstyle=k.medianDashStyle||a.medianDashStyle||a.dashStyle,k.medianShape.attr(H)),g=k.stem.strokeWidth()%2/2,f=n+A+g,p=[["M",f,d],["L",f,h],["M",
f,l],["L",f,m]],k.stem[q]({d:p}),F&&(g=k.box.strokeWidth()%2/2,l=Math.floor(l)+g,d=Math.floor(d)+g,n+=g,w+=g,p=[["M",n,d],["L",n,l],["L",w,l],["L",w,d],["L",n,d],["Z"]],k.box[q]({d:p})),x&&(g=k.whiskers.strokeWidth()%2/2,h+=g,m+=g,t=/%$/.test(x)?A*parseFloat(x)/100:x/2,p=[["M",f-t,h],["L",f+t,h],["M",f-t,m],["L",f+t,m]],k.whiskers[q]({d:p})),e=Math.round(k.medianPlot),g=k.medianShape.strokeWidth()%2/2,e+=g,p=[["M",n,e],["L",w,e]],k.medianShape[q]({d:p}))})};b.prototype.toYData=function(b){return[b.low,
b.q1,b.median,b.q3,b.high]};b.defaultOptions=l(e.defaultOptions,{threshold:null,tooltip:{pointFormat:'<span style="color:{point.color}">\u25cf</span> <b> {series.name}</b><br/>Maximum: {point.high}<br/>Upper quartile: {point.q3}<br/>Median: {point.median}<br/>Lower quartile: {point.q1}<br/>Minimum: {point.low}<br/>'},whiskerLength:"50%",fillColor:h.backgroundColor,lineWidth:1,medianWidth:2,whiskerWidth:2});return b}(e);m(a.prototype,{pointArrayMap:["low","q1","median","q3","high"],pointValKey:"high",
drawDataLabels:d,setStackedPoints:d});c.registerSeriesType("boxplot",a);"";return a});z(e,"Series/Bubble/BubbleLegendDefaults.js",[e["Core/Color/Palette.js"]],function(e){return{borderColor:void 0,borderWidth:2,className:void 0,color:void 0,connectorClassName:void 0,connectorColor:void 0,connectorDistance:60,connectorWidth:1,enabled:!1,labels:{className:void 0,allowOverlap:!1,format:"",formatter:void 0,align:"right",style:{fontSize:"10px",color:e.neutralColor100},x:0,y:0},maxSize:60,minSize:10,legendIndex:0,
ranges:{value:void 0,borderColor:void 0,color:void 0,connectorColor:void 0},sizeBy:"area",sizeByAbsoluteValue:!1,zIndex:1,zThreshold:0}});z(e,"Series/Bubble/BubbleLegendItem.js",[e["Core/Color/Color.js"],e["Core/FormatUtilities.js"],e["Core/Globals.js"],e["Core/Utilities.js"]],function(e,d,h,c){var a=e.parse,t=h.noop,m=c.arrayMax,l=c.arrayMin,r=c.isNumber,x=c.merge,b=c.pick,q=c.stableSort;"";return function(){function c(b,a){this.options=this.symbols=this.visible=this.selected=this.ranges=this.movementX=
this.maxLabel=this.legendSymbol=this.legendItemWidth=this.legendItemHeight=this.legendItem=this.legendGroup=this.legend=this.fontMetrics=this.chart=void 0;this.setState=t;this.init(b,a)}c.prototype.init=function(b,a){this.options=b;this.visible=!0;this.chart=a.chart;this.legend=a};c.prototype.addToLegend=function(b){b.splice(this.options.legendIndex,0,this)};c.prototype.drawLegendSymbol=function(a){var c=this.chart,k=this.options,p=b(a.options.itemDistance,20),l=k.ranges,d=k.connectorDistance;this.fontMetrics=
c.renderer.fontMetrics(k.labels.style.fontSize);l&&l.length&&r(l[0].value)?(q(l,function(b,g){return g.value-b.value}),this.ranges=l,this.setOptions(),this.render(),a=this.getMaxLabelSize(),l=this.ranges[0].radius,c=2*l,d=d-l+a.width,d=0<d?d:0,this.maxLabel=a,this.movementX="left"===k.labels.align?d:0,this.legendItemWidth=c+d+p,this.legendItemHeight=c+this.fontMetrics.h/2):a.options.bubbleLegend.autoRanges=!0};c.prototype.setOptions=function(){var c=this.ranges,k=this.options,l=this.chart.series[k.seriesIndex],
q=this.legend.baseline,d={zIndex:k.zIndex,"stroke-width":k.borderWidth},h={zIndex:k.zIndex,"stroke-width":k.connectorWidth},e={align:this.legend.options.rtl||"left"===k.labels.align?"right":"left",zIndex:k.zIndex},g=l.options.marker.fillOpacity,f=this.chart.styledMode;c.forEach(function(u,n){f||(d.stroke=b(u.borderColor,k.borderColor,l.color),d.fill=b(u.color,k.color,1!==g?a(l.color).setOpacity(g).get("rgba"):l.color),h.stroke=b(u.connectorColor,k.connectorColor,l.color));c[n].radius=this.getRangeRadius(u.value);
c[n]=x(c[n],{center:c[0].radius-c[n].radius+q});f||x(!0,c[n],{bubbleAttribs:x(d),connectorAttribs:x(h),labelAttribs:e})},this)};c.prototype.getRangeRadius=function(b){var a=this.options;return this.chart.series[this.options.seriesIndex].getRadius.call(this,a.ranges[a.ranges.length-1].value,a.ranges[0].value,a.minSize,a.maxSize,b)};c.prototype.render=function(){var b=this.chart.renderer,a=this.options.zThreshold;this.symbols||(this.symbols={connectors:[],bubbleItems:[],labels:[]});this.legendSymbol=
b.g("bubble-legend");this.legendItem=b.g("bubble-legend-item");this.legendSymbol.translateX=0;this.legendSymbol.translateY=0;this.ranges.forEach(function(b){b.value>=a&&this.renderRange(b)},this);this.legendSymbol.add(this.legendItem);this.legendItem.add(this.legendGroup);this.hideOverlappingLabels()};c.prototype.renderRange=function(b){var a=this.options,c=a.labels,k=this.chart,l=k.series[a.seriesIndex],d=k.renderer,q=this.symbols;k=q.labels;var g=b.center,f=Math.abs(b.radius),u=a.connectorDistance||
0,n=c.align,w=a.connectorWidth,A=this.ranges[0].radius||0,p=g-f-a.borderWidth/2+w/2,h=this.fontMetrics;h=h.f/2-(h.h-h.f)/2;var e=d.styledMode;u=this.legend.options.rtl||"left"===n?-u:u;"center"===n&&(u=0,a.connectorDistance=0,b.labelAttribs.align="center");n=p+a.labels.y;var m=A+u+a.labels.x;q.bubbleItems.push(d.circle(A,g+((p%1?1:.5)-(w%2?0:.5)),f).attr(e?{}:b.bubbleAttribs).addClass((e?"highcharts-color-"+l.colorIndex+" ":"")+"highcharts-bubble-legend-symbol "+(a.className||"")).add(this.legendSymbol));
q.connectors.push(d.path(d.crispLine([["M",A,p],["L",A+u,p]],a.connectorWidth)).attr(e?{}:b.connectorAttribs).addClass((e?"highcharts-color-"+this.options.seriesIndex+" ":"")+"highcharts-bubble-legend-connectors "+(a.connectorClassName||"")).add(this.legendSymbol));b=d.text(this.formatLabel(b),m,n+h).attr(e?{}:b.labelAttribs).css(e?{}:c.style).addClass("highcharts-bubble-legend-labels "+(a.labels.className||"")).add(this.legendSymbol);k.push(b);b.placed=!0;b.alignAttr={x:m,y:n+h}};c.prototype.getMaxLabelSize=
function(){var b,a;this.symbols.labels.forEach(function(c){a=c.getBBox(!0);b=b?a.width>b.width?a:b:a});return b||{}};c.prototype.formatLabel=function(b){var a=this.options,c=a.labels.formatter;a=a.labels.format;var k=this.chart.numberFormatter;return a?d.format(a,b):c?c.call(b):k(b.value,1)};c.prototype.hideOverlappingLabels=function(){var b=this.chart,a=this.symbols;!this.options.labels.allowOverlap&&a&&(b.hideOverlappingLabels(a.labels),a.labels.forEach(function(b,c){b.newOpacity?b.newOpacity!==
b.oldOpacity&&a.connectors[c].show():a.connectors[c].hide()}))};c.prototype.getRanges=function(){var a=this.legend.bubbleLegend,c=a.options.ranges,k,d=Number.MAX_VALUE,q=-Number.MAX_VALUE;a.chart.series.forEach(function(a){a.isBubble&&!a.ignoreSeries&&(k=a.zData.filter(r),k.length&&(d=b(a.options.zMin,Math.min(d,Math.max(l(k),!1===a.options.displayNegative?a.options.zThreshold:-Number.MAX_VALUE))),q=b(a.options.zMax,Math.max(q,m(k)))))});var h=d===q?[{value:q}]:[{value:d},{value:(d+q)/2},{value:q,
autoRanges:!0}];c.length&&c[0].radius&&h.reverse();h.forEach(function(b,a){c&&c[a]&&(h[a]=x(c[a],b))});return h};c.prototype.predictBubbleSizes=function(){var b=this.chart,a=this.fontMetrics,c=b.legend.options,k="horizontal"===c.layout,l=k?b.legend.lastLineHeight:0,d=b.plotSizeX,q=b.plotSizeY,g=b.series[this.options.seriesIndex];b=Math.ceil(g.minPxSize);var f=Math.ceil(g.maxPxSize),u=Math.min(q,d);g=g.options.maxSize;if(c.floating||!/%$/.test(g))a=f;else if(g=parseFloat(g),a=(u+l-a.h/2)*g/100/(g/
100+1),k&&q-a>=d||!k&&d-a>=q)a=f;return[b,Math.ceil(a)]};c.prototype.updateRanges=function(b,a){var c=this.legend.options.bubbleLegend;c.minSize=b;c.maxSize=a;c.ranges=this.getRanges()};c.prototype.correctSizes=function(){var b=this.legend,a=this.chart.series[this.options.seriesIndex];1<Math.abs(Math.ceil(a.maxPxSize)-this.options.maxSize)&&(this.updateRanges(this.options.minSize,a.maxPxSize),b.render())};return c}()});z(e,"Series/Bubble/BubbleLegendComposition.js",[e["Series/Bubble/BubbleLegendDefaults.js"],
e["Series/Bubble/BubbleLegendItem.js"],e["Core/DefaultOptions.js"],e["Core/Utilities.js"]],function(e,d,h,c){var a=h.setOptions,t=c.addEvent,m=c.objectEach,l=c.wrap,r;(function(c){function b(b,a,c){var g=this.legend,f=0<=q(this);if(g&&g.options.enabled&&g.bubbleLegend&&g.options.bubbleLegend.autoRanges&&f){var u=g.bubbleLegend.options;f=g.bubbleLegend.predictBubbleSizes();g.bubbleLegend.updateRanges(f[0],f[1]);u.placed||(g.group.placed=!1,g.allItems.forEach(function(f){f.legendGroup.translateY=null}));
g.render();this.getMargins();this.axes.forEach(function(f){f.visible&&f.render();u.placed||(f.setScale(),f.updateNames(),m(f.ticks,function(f){f.isNew=!0;f.isNewLabel=!0}))});u.placed=!0;this.getMargins();b.call(this,a,c);g.bubbleLegend.correctSizes();r(g,k(g))}else b.call(this,a,c),g&&g.options.enabled&&g.bubbleLegend&&(g.render(),r(g,k(g)))}function q(b){b=b.series;for(var a=0;a<b.length;){if(b[a]&&b[a].isBubble&&b[a].visible&&b[a].zData.length)return a;a++}return-1}function k(b){b=b.allItems;var a=
[],c=b.length,g,f=0;for(g=0;g<c;g++)if(b[g].legendItemHeight&&(b[g].itemHeight=b[g].legendItemHeight),b[g]===b[c-1]||b[g+1]&&b[g]._legendItemPos[1]!==b[g+1]._legendItemPos[1]){a.push({height:0});var u=a[a.length-1];for(f;f<=g;f++)b[f].itemHeight>u.height&&(u.height=b[f].itemHeight);u.step=g}return a}function h(b){var a=this.bubbleLegend,c=this.options,g=c.bubbleLegend,f=q(this.chart);a&&a.ranges&&a.ranges.length&&(g.ranges.length&&(g.autoRanges=!!g.ranges[0].autoRanges),this.destroyItem(a));0<=f&&
c.enabled&&g.enabled&&(g.seriesIndex=f,this.bubbleLegend=new d(g,this),this.bubbleLegend.addToLegend(b.allItems))}function v(){var b=this.chart,a=this.visible,c=this.chart.legend;c&&c.bubbleLegend&&(this.visible=!a,this.ignoreSeries=a,b=0<=q(b),c.bubbleLegend.visible!==b&&(c.update({bubbleLegend:{enabled:b}}),c.bubbleLegend.visible=b),this.visible=a)}function r(b,a){var c=b.options.rtl,g,f,u,n=0;b.allItems.forEach(function(b,k){g=b.legendGroup.translateX;f=b._legendItemPos[1];if((u=b.movementX)||
c&&b.ranges)u=c?g-b.options.maxSize/2:g+u,b.legendGroup.attr({translateX:u});k>a[n].step&&n++;b.legendGroup.attr({translateY:Math.round(f+a[n].height/2)});b._legendItemPos[1]=f+a[n].height/2})}var x=[];c.compose=function(c,k,d){-1===x.indexOf(c)&&(x.push(c),a({legend:{bubbleLegend:e}}),l(c.prototype,"drawChartBox",b));-1===x.indexOf(k)&&(x.push(k),t(k,"afterGetAllItems",h));-1===x.indexOf(d)&&(x.push(d),t(d,"legendItemClick",v))}})(r||(r={}));return r});z(e,"Series/Bubble/BubblePoint.js",[e["Core/Series/Point.js"],
e["Core/Series/SeriesRegistry.js"],e["Core/Utilities.js"]],function(e,d,h){var c=this&&this.__extends||function(){var a=function(c,d){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,c){a.__proto__=c}||function(a,c){for(var d in c)c.hasOwnProperty(d)&&(a[d]=c[d])};return a(c,d)};return function(c,d){function l(){this.constructor=c}a(c,d);c.prototype=null===d?Object.create(d):(l.prototype=d.prototype,new l)}}();h=h.extend;d=function(a){function d(){var c=null!==a&&a.apply(this,arguments)||
this;c.options=void 0;c.series=void 0;return c}c(d,a);d.prototype.haloPath=function(a){return e.prototype.haloPath.call(this,0===a?0:(this.marker?this.marker.radius||0:0)+a)};return d}(d.seriesTypes.scatter.prototype.pointClass);h(d.prototype,{ttBelow:!1});return d});z(e,"Series/Bubble/BubbleSeries.js",[e["Core/Axis/Axis.js"],e["Series/Bubble/BubbleLegendComposition.js"],e["Series/Bubble/BubblePoint.js"],e["Core/Color/Color.js"],e["Core/Globals.js"],e["Core/Series/Series.js"],e["Core/Series/SeriesRegistry.js"],
e["Core/Utilities.js"]],function(e,d,h,c,a,t,m,l){var r=this&&this.__extends||function(){var b=function(f,a){b=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(b,f){b.__proto__=f}||function(b,f){for(var a in f)f.hasOwnProperty(a)&&(b[a]=f[a])};return b(f,a)};return function(f,a){function g(){this.constructor=f}b(f,a);f.prototype=null===a?Object.create(a):(g.prototype=a.prototype,new g)}}(),x=c.parse;c=a.noop;var b=m.seriesTypes;a=b.column;var q=b.scatter,k=l.arrayMax,p=l.arrayMin,v=
l.clamp,B=l.extend,H=l.isNumber,D=l.merge,y=l.pick,I=l.pInt;l=function(b){function f(){var f=null!==b&&b.apply(this,arguments)||this;f.data=void 0;f.maxPxSize=void 0;f.minPxSize=void 0;f.options=void 0;f.points=void 0;f.radii=void 0;f.yData=void 0;f.zData=void 0;return f}r(f,b);f.prototype.animate=function(b){!b&&this.points.length<this.options.animationLimit&&this.points.forEach(function(b){var f=b.graphic;f&&f.width&&(this.hasRendered||f.attr({x:b.plotX,y:b.plotY,width:1,height:1}),f.animate(this.markerAttribs(b),
this.options.animation))},this)};f.prototype.getRadii=function(b,f,a){var g=this.zData,c=this.yData,n=a.minPxSize,u=a.maxPxSize,k=[];var w=0;for(a=g.length;w<a;w++){var d=g[w];k.push(this.getRadius(b,f,n,u,d,c[w]))}this.radii=k};f.prototype.getRadius=function(b,f,a,g,c,k){var n=this.options,u="width"!==n.sizeBy,w=n.zThreshold,d=f-b,q=.5;if(null===k||null===c)return null;if(H(c)){n.sizeByAbsoluteValue&&(c=Math.abs(c-w),d=Math.max(f-w,Math.abs(b-w)),b=0);if(c<b)return a/2-1;0<d&&(q=(c-b)/d)}u&&0<=q&&
(q=Math.sqrt(q));return Math.ceil(a+q*(g-a))/2};f.prototype.hasData=function(){return!!this.processedXData.length};f.prototype.pointAttribs=function(b,f){var a=this.options.marker.fillOpacity;b=t.prototype.pointAttribs.call(this,b,f);1!==a&&(b.fill=x(b.fill).setOpacity(a).get("rgba"));return b};f.prototype.translate=function(){var f,a=this.data,g=this.radii;b.prototype.translate.call(this);for(f=a.length;f--;){var c=a[f];var k=g?g[f]:0;H(k)&&k>=this.minPxSize/2?(c.marker=B(c.marker,{radius:k,width:2*
k,height:2*k}),c.dlBox={x:c.plotX-k,y:c.plotY-k,width:2*k,height:2*k}):c.shapeArgs=c.plotY=c.dlBox=void 0}};f.compose=d.compose;f.defaultOptions=D(q.defaultOptions,{dataLabels:{formatter:function(){var b=this.series.chart.numberFormatter,f=this.point.z;return H(f)?b(f,-1):""},inside:!0,verticalAlign:"middle"},animationLimit:250,marker:{lineColor:null,lineWidth:1,fillOpacity:.5,radius:null,states:{hover:{radiusPlus:0}},symbol:"circle"},minSize:8,maxSize:"20%",softThreshold:!1,states:{hover:{halo:{size:5}}},
tooltip:{pointFormat:"({point.x}, {point.y}), Size: {point.z}"},turboThreshold:0,zThreshold:0,zoneAxis:"z"});return f}(q);B(l.prototype,{alignDataLabel:a.prototype.alignDataLabel,applyZones:c,bubblePadding:!0,buildKDTree:c,directTouch:!0,isBubble:!0,pointArrayMap:["y","z"],pointClass:h,parallelArrays:["x","y","z"],trackerGroups:["group","dataLabelsGroup"],specialGroup:"group",zoneAxis:"z"});e.prototype.beforePadding=function(){var b=this,f=this.len,a=this.chart,c=0,w=f,d=this.isXAxis,q=d?"xData":
"yData",l=this.min,h={},e=Math.min(a.plotWidth,a.plotHeight),m=Number.MAX_VALUE,r=-Number.MAX_VALUE,x=this.max-l,t=f/x,B=[];this.series.forEach(function(f){var g=f.options;!f.bubblePadding||!f.visible&&a.options.chart.ignoreHiddenSeries||(b.allowZoomOutside=!0,B.push(f),d&&(["minSize","maxSize"].forEach(function(b){var f=g[b],a=/%$/.test(f);f=I(f);h[b]=a?e*f/100:f}),f.minPxSize=h.minSize,f.maxPxSize=Math.max(h.maxSize,h.minSize),f=f.zData.filter(H),f.length&&(m=y(g.zMin,v(p(f),!1===g.displayNegative?
g.zThreshold:-Number.MAX_VALUE,m)),r=y(g.zMax,Math.max(r,k(f))))))});B.forEach(function(f){var a=f[q],g=a.length;d&&f.getRadii(m,r,f);if(0<x)for(;g--;)if(H(a[g])&&b.dataMin<=a[g]&&a[g]<=b.max){var n=f.radii?f.radii[g]:0;c=Math.min((a[g]-l)*t-n,c);w=Math.max((a[g]-l)*t+n,w)}});B.length&&0<x&&!this.logarithmic&&(w-=f,t*=(f+Math.max(0,c)-Math.min(w,f))/f,[["min","userMin",c],["max","userMax",w]].forEach(function(f){"undefined"===typeof y(b.options[f[0]],b[f[1]])&&(b[f[0]]+=f[2]/t)}))};m.registerSeriesType("bubble",
l);"";"";return l});z(e,"Series/ColumnRange/ColumnRangePoint.js",[e["Core/Series/SeriesRegistry.js"],e["Core/Utilities.js"]],function(e,d){var h=this&&this.__extends||function(){var a=function(c,d){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,b){a.__proto__=b}||function(a,b){for(var c in b)b.hasOwnProperty(c)&&(a[c]=b[c])};return a(c,d)};return function(c,d){function l(){this.constructor=c}a(c,d);c.prototype=null===d?Object.create(d):(l.prototype=d.prototype,new l)}}(),c=e.seriesTypes;
e=c.column.prototype.pointClass;var a=d.extend,t=d.isNumber;d=function(a){function c(){var c=null!==a&&a.apply(this,arguments)||this;c.series=void 0;c.options=void 0;c.barX=void 0;c.pointWidth=void 0;c.shapeType=void 0;return c}h(c,a);c.prototype.isValid=function(){return t(this.low)};return c}(c.arearange.prototype.pointClass);a(d.prototype,{setState:e.prototype.setState});return d});z(e,"Series/ColumnRange/ColumnRangeSeries.js",[e["Series/ColumnRange/ColumnRangePoint.js"],e["Core/Globals.js"],e["Core/Series/SeriesRegistry.js"],
e["Core/Utilities.js"]],function(e,d,h,c){var a=this&&this.__extends||function(){var b=function(a,c){b=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(b,a){b.__proto__=a}||function(b,a){for(var c in a)a.hasOwnProperty(c)&&(b[c]=a[c])};return b(a,c)};return function(a,c){function k(){this.constructor=a}b(a,c);a.prototype=null===c?Object.create(c):(k.prototype=c.prototype,new k)}}();d=d.noop;var t=h.seriesTypes,m=t.arearange,l=t.column,r=l.prototype,x=m.prototype,b=c.clamp,q=c.merge,
k=c.pick;c=c.extend;var p={pointRange:null,marker:null,states:{hover:{halo:!1}}};t=function(c){function d(){var b=null!==c&&c.apply(this,arguments)||this;b.data=void 0;b.points=void 0;b.options=void 0;return b}a(d,c);d.prototype.setOptions=function(){q(!0,arguments[0],{stacking:void 0});return x.setOptions.apply(this,arguments)};d.prototype.translate=function(){var a=this,c=a.yAxis,d=a.xAxis,q=d.startAngleRad,g,f=a.chart,u=a.xAxis.isRadial,n=Math.max(f.chartWidth,f.chartHeight)+999,w;r.translate.apply(a);
a.points.forEach(function(l){var h=l.shapeArgs||{},A=a.options.minPointLength;l.plotHigh=w=b(c.translate(l.high,0,1,0,1),-n,n);l.plotLow=b(l.plotY,-n,n);var e=w;var p=k(l.rectPlotY,l.plotY)-w;Math.abs(p)<A?(A-=p,p+=A,e-=A/2):0>p&&(p*=-1,e-=p);u?(g=l.barX+q,l.shapeType="arc",l.shapeArgs=a.polarArc(e+p,e,g,g+l.pointWidth)):(h.height=p,h.y=e,A=h.x,A=void 0===A?0:A,h=h.width,h=void 0===h?0:h,l.tooltipPos=f.inverted?[c.len+c.pos-f.plotLeft-e-p/2,d.len+d.pos-f.plotTop-A-h/2,p]:[d.left-f.plotLeft+A+h/2,
c.pos-f.plotTop+e+p/2,p])})};d.prototype.crispCol=function(){return r.crispCol.apply(this,arguments)};d.prototype.drawPoints=function(){return r.drawPoints.apply(this,arguments)};d.prototype.drawTracker=function(){return r.drawTracker.apply(this,arguments)};d.prototype.getColumnMetrics=function(){return r.getColumnMetrics.apply(this,arguments)};d.prototype.pointAttribs=function(){return r.pointAttribs.apply(this,arguments)};d.prototype.adjustForMissingColumns=function(){return r.adjustForMissingColumns.apply(this,
arguments)};d.prototype.animate=function(){return r.animate.apply(this,arguments)};d.prototype.translate3dPoints=function(){return r.translate3dPoints.apply(this,arguments)};d.prototype.translate3dShapes=function(){return r.translate3dShapes.apply(this,arguments)};d.defaultOptions=q(l.defaultOptions,m.defaultOptions,p);return d}(m);c(t.prototype,{directTouch:!0,trackerGroups:["group","dataLabelsGroup"],drawGraph:d,getSymbol:d,polarArc:function(){return r.polarArc.apply(this,arguments)},pointClass:e});
h.registerSeriesType("columnrange",t);"";return t});z(e,"Series/ColumnPyramid/ColumnPyramidSeries.js",[e["Series/Column/ColumnSeries.js"],e["Core/Series/SeriesRegistry.js"],e["Core/Utilities.js"]],function(e,d,h){var c=this&&this.__extends||function(){var a=function(c,b){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(b,a){b.__proto__=a}||function(b,a){for(var c in a)a.hasOwnProperty(c)&&(b[c]=a[c])};return a(c,b)};return function(c,b){function d(){this.constructor=c}a(c,b);c.prototype=
null===b?Object.create(b):(d.prototype=b.prototype,new d)}}(),a=e.prototype,t=h.clamp,m=h.merge,l=h.pick;h=function(d){function h(){var b=null!==d&&d.apply(this,arguments)||this;b.data=void 0;b.options=void 0;b.points=void 0;return b}c(h,d);h.prototype.translate=function(){var b=this,c=b.chart,k=b.options,d=b.dense=2>b.closestPointRange*b.xAxis.transA;d=b.borderWidth=l(k.borderWidth,d?0:1);var h=b.yAxis,e=k.threshold,m=b.translatedThreshold=h.getThreshold(e),x=l(k.minPointLength,5),r=b.getColumnMetrics(),
I=r.width,g=b.barW=Math.max(I,1+2*d),f=b.pointXOffset=r.offset;c.inverted&&(m-=.5);k.pointPadding&&(g=Math.ceil(g));a.translate.apply(b);b.points.forEach(function(a){var n=l(a.yBottom,m),d=999+Math.abs(n),u=t(a.plotY,-d,h.len+d);d=a.plotX+f;var q=g/2,p=Math.min(u,n);n=Math.max(u,n)-p;var v;a.barX=d;a.pointWidth=I;a.tooltipPos=c.inverted?[h.len+h.pos-c.plotLeft-u,b.xAxis.len-d-q,n]:[d+q,u+h.pos-c.plotTop,n];u=e+(a.total||a.y);"percent"===k.stacking&&(u=e+(0>a.y)?-100:100);u=h.toPixels(u,!0);var r=
(v=c.plotHeight-u-(c.plotHeight-m))?q*(p-u)/v:0;var y=v?q*(p+n-u)/v:0;v=d-r+q;r=d+r+q;var K=d+y+q;y=d-y+q;var C=p-x;var B=p+n;0>a.y&&(C=p,B=p+n+x);c.inverted&&(K=c.plotWidth-p,v=u-(c.plotWidth-m),r=q*(u-K)/v,y=q*(u-(K-n))/v,v=d+q+r,r=v-2*r,K=d-y+q,y=d+y+q,C=p,B=p+n-x,0>a.y&&(B=p+n+x));a.shapeType="path";a.shapeArgs={x:v,y:C,width:r-v,height:n,d:[["M",v,C],["L",r,C],["L",K,B],["L",y,B],["Z"]]}})};h.defaultOptions=m(e.defaultOptions,{});return h}(e);d.registerSeriesType("columnpyramid",h);"";return h});
z(e,"Series/ErrorBar/ErrorBarSeries.js",[e["Series/BoxPlot/BoxPlotSeries.js"],e["Series/Column/ColumnSeries.js"],e["Core/Color/Palette.js"],e["Core/Series/SeriesRegistry.js"],e["Core/Utilities.js"]],function(e,d,h,c,a){var t=this&&this.__extends||function(){var a=function(b,c){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(b,a){b.__proto__=a}||function(b,a){for(var c in a)a.hasOwnProperty(c)&&(b[c]=a[c])};return a(b,c)};return function(b,c){function d(){this.constructor=b}a(b,c);
b.prototype=null===c?Object.create(c):(d.prototype=c.prototype,new d)}}(),m=c.seriesTypes.arearange,l=a.merge;a=a.extend;var r=function(a){function b(){var b=null!==a&&a.apply(this,arguments)||this;b.data=void 0;b.options=void 0;b.points=void 0;return b}t(b,a);b.prototype.getColumnMetrics=function(){return this.linkedParent&&this.linkedParent.columnMetrics||d.prototype.getColumnMetrics.call(this)};b.prototype.drawDataLabels=function(){var b=this.pointValKey;m&&(m.prototype.drawDataLabels.call(this),
this.data.forEach(function(a){a.y=a[b]}))};b.prototype.toYData=function(b){return[b.low,b.high]};b.defaultOptions=l(e.defaultOptions,{color:h.neutralColor100,grouping:!1,linkedTo:":previous",tooltip:{pointFormat:'<span style="color:{point.color}">\u25cf</span> {series.name}: <b>{point.low}</b> - <b>{point.high}</b><br/>'},whiskerWidth:null});return b}(e);a(r.prototype,{pointArrayMap:["low","high"],pointValKey:"high",doQuartiles:!1});c.registerSeriesType("errorbar",r);"";return r});z(e,"Series/Gauge/GaugePoint.js",
[e["Core/Series/SeriesRegistry.js"]],function(e){var d=this&&this.__extends||function(){var d=function(c,a){d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,c){a.__proto__=c}||function(a,c){for(var d in c)c.hasOwnProperty(d)&&(a[d]=c[d])};return d(c,a)};return function(c,a){function h(){this.constructor=c}d(c,a);c.prototype=null===a?Object.create(a):(h.prototype=a.prototype,new h)}}();return function(h){function c(){var a=null!==h&&h.apply(this,arguments)||this;a.options=void 0;
a.series=void 0;a.shapeArgs=void 0;return a}d(c,h);c.prototype.setState=function(a){this.state=a};return c}(e.series.prototype.pointClass)});z(e,"Series/Gauge/GaugeSeries.js",[e["Series/Gauge/GaugePoint.js"],e["Core/Globals.js"],e["Core/Color/Palette.js"],e["Core/Series/SeriesRegistry.js"],e["Core/Utilities.js"]],function(e,d,h,c,a){var t=this&&this.__extends||function(){var b=function(a,c){b=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(b,a){b.__proto__=a}||function(b,a){for(var c in a)a.hasOwnProperty(c)&&
(b[c]=a[c])};return b(a,c)};return function(a,c){function d(){this.constructor=a}b(a,c);a.prototype=null===c?Object.create(c):(d.prototype=c.prototype,new d)}}();d=d.noop;var m=c.series,l=c.seriesTypes.column,r=a.clamp,x=a.isNumber,b=a.extend,q=a.merge,k=a.pick,p=a.pInt;a=function(b){function a(){var a=null!==b&&b.apply(this,arguments)||this;a.data=void 0;a.points=void 0;a.options=void 0;a.yAxis=void 0;return a}t(a,b);a.prototype.translate=function(){var b=this.yAxis,a=this.options,c=b.center;this.generatePoints();
this.points.forEach(function(d){var g=q(a.dial,d.dial),f=p(k(g.radius,"80%"))*c[2]/200,u=p(k(g.baseLength,"70%"))*f/100,n=p(k(g.rearLength,"10%"))*f/100,w=g.baseWidth||3,l=g.topWidth||1,h=a.overshoot,e=b.startAngleRad+b.translate(d.y,null,null,null,!0);if(x(h)||!1===a.wrap)h=x(h)?h/180*Math.PI:0,e=r(e,b.startAngleRad-h,b.endAngleRad+h);e=180*e/Math.PI;d.shapeType="path";d.shapeArgs={d:g.path||[["M",-n,-w/2],["L",u,-w/2],["L",f,-l/2],["L",f,l/2],["L",u,w/2],["L",-n,w/2],["Z"]],translateX:c[0],translateY:c[1],
rotation:e};d.plotX=c[0];d.plotY=c[1]})};a.prototype.drawPoints=function(){var b=this,a=b.chart,c=b.yAxis.center,d=b.pivot,g=b.options,f=g.pivot,u=a.renderer;b.points.forEach(function(f){var c=f.graphic,d=f.shapeArgs,n=d.d,k=q(g.dial,f.dial);c?(c.animate(d),d.d=n):f.graphic=u[f.shapeType](d).attr({rotation:d.rotation,zIndex:1}).addClass("highcharts-dial").add(b.group);if(!a.styledMode)f.graphic[c?"animate":"attr"]({stroke:k.borderColor||"none","stroke-width":k.borderWidth||0,fill:k.backgroundColor||
h.neutralColor100})});d?d.animate({translateX:c[0],translateY:c[1]}):(b.pivot=u.circle(0,0,k(f.radius,5)).attr({zIndex:2}).addClass("highcharts-pivot").translate(c[0],c[1]).add(b.group),a.styledMode||b.pivot.attr({"stroke-width":f.borderWidth||0,stroke:f.borderColor||h.neutralColor20,fill:f.backgroundColor||h.neutralColor100}))};a.prototype.animate=function(b){var a=this;b||a.points.forEach(function(b){var c=b.graphic;c&&(c.attr({rotation:180*a.yAxis.startAngleRad/Math.PI}),c.animate({rotation:b.shapeArgs.rotation},
a.options.animation))})};a.prototype.render=function(){this.group=this.plotGroup("group","series",this.visible?"visible":"hidden",this.options.zIndex,this.chart.seriesGroup);m.prototype.render.call(this);this.group.clip(this.chart.clipRect)};a.prototype.setData=function(b,a){m.prototype.setData.call(this,b,!1);this.processData();this.generatePoints();k(a,!0)&&this.chart.redraw()};a.prototype.hasData=function(){return!!this.points.length};a.defaultOptions=q(m.defaultOptions,{dataLabels:{borderColor:h.neutralColor20,
borderRadius:3,borderWidth:1,crop:!1,defer:!1,enabled:!0,verticalAlign:"top",y:15,zIndex:2},dial:{},pivot:{},tooltip:{headerFormat:""},showInLegend:!1});return a}(m);b(a.prototype,{angular:!0,directTouch:!0,drawGraph:d,drawTracker:l.prototype.drawTracker,fixedBox:!0,forceDL:!0,noSharedTooltip:!0,pointClass:e,trackerGroups:["group","dataLabelsGroup"]});c.registerSeriesType("gauge",a);"";return a});z(e,"Series/PackedBubble/PackedBubblePoint.js",[e["Core/Chart/Chart.js"],e["Core/Series/Point.js"],e["Core/Series/SeriesRegistry.js"]],
function(e,d,h){var c=this&&this.__extends||function(){var a=function(c,d){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,c){a.__proto__=c}||function(a,c){for(var d in c)c.hasOwnProperty(d)&&(a[d]=c[d])};return a(c,d)};return function(c,d){function l(){this.constructor=c}a(c,d);c.prototype=null===d?Object.create(d):(l.prototype=d.prototype,new l)}}();return function(a){function h(){var c=null!==a&&a.apply(this,arguments)||this;c.degree=NaN;c.mass=NaN;c.radius=NaN;c.options=void 0;
c.series=void 0;c.value=null;return c}c(h,a);h.prototype.destroy=function(){this.series.layout&&this.series.layout.removeElementFromCollection(this,this.series.layout.nodes);return d.prototype.destroy.apply(this,arguments)};h.prototype.firePointEvent=function(){var a=this.series.options;if(this.isParentNode&&a.parentNode){var c=a.allowPointSelect;a.allowPointSelect=a.parentNode.allowPointSelect;d.prototype.firePointEvent.apply(this,arguments);a.allowPointSelect=c}else d.prototype.firePointEvent.apply(this,
arguments)};h.prototype.select=function(){var a=this.series.chart;this.isParentNode?(a.getSelectedPoints=a.getSelectedParentNodes,d.prototype.select.apply(this,arguments),a.getSelectedPoints=e.prototype.getSelectedPoints):d.prototype.select.apply(this,arguments)};return h}(h.seriesTypes.bubble.prototype.pointClass)});z(e,"Series/Networkgraph/DraggableNodes.js",[e["Core/Chart/Chart.js"],e["Core/Globals.js"],e["Core/Utilities.js"]],function(e,d,h){var c=h.addEvent;d.dragNodesMixin={onMouseDown:function(a,
c){c=this.chart.pointer.normalize(c);a.fixedPosition={chartX:c.chartX,chartY:c.chartY,plotX:a.plotX,plotY:a.plotY};a.inDragMode=!0},onMouseMove:function(a,c){if(a.fixedPosition&&a.inDragMode){var d=this.chart,h=d.pointer.normalize(c);c=a.fixedPosition.chartX-h.chartX;h=a.fixedPosition.chartY-h.chartY;var e=void 0,x=void 0,b=d.graphLayoutsLookup;if(5<Math.abs(c)||5<Math.abs(h))e=a.fixedPosition.plotX-c,x=a.fixedPosition.plotY-h,d.isInsidePlot(e,x)&&(a.plotX=e,a.plotY=x,a.hasDragged=!0,this.redrawHalo(a),
b.forEach(function(b){b.restartSimulation()}))}},onMouseUp:function(a,c){a.fixedPosition&&(a.hasDragged&&(this.layout.enableSimulation?this.layout.start():this.chart.redraw()),a.inDragMode=a.hasDragged=!1,this.options.fixedDraggable||delete a.fixedPosition)},redrawHalo:function(a){a&&this.halo&&this.halo.attr({d:a.haloPath(this.options.states.hover.halo.size)})}};c(e,"load",function(){var a=this,d,h,e;a.container&&(d=c(a.container,"mousedown",function(d){var l=a.hoverPoint;l&&l.series&&l.series.hasDraggableNodes&&
l.series.options.draggable&&(l.series.onMouseDown(l,d),h=c(a.container,"mousemove",function(b){return l&&l.series&&l.series.onMouseMove(l,b)}),e=c(a.container.ownerDocument,"mouseup",function(b){h();e();return l&&l.series&&l.series.onMouseUp(l,b)}))}));c(a,"destroy",function(){d()})})});z(e,"Series/Networkgraph/Integrations.js",[e["Core/Globals.js"]],function(e){e.networkgraphIntegrations={verlet:{attractiveForceFunction:function(d,h){return(h-d)/d},repulsiveForceFunction:function(d,h){return(h-d)/
d*(h>d?1:0)},barycenter:function(){var d=this.options.gravitationalConstant,h=this.barycenter.xFactor,c=this.barycenter.yFactor;h=(h-(this.box.left+this.box.width)/2)*d;c=(c-(this.box.top+this.box.height)/2)*d;this.nodes.forEach(function(a){a.fixedPosition||(a.plotX-=h/a.mass/a.degree,a.plotY-=c/a.mass/a.degree)})},repulsive:function(d,h,c){h=h*this.diffTemperature/d.mass/d.degree;d.fixedPosition||(d.plotX+=c.x*h,d.plotY+=c.y*h)},attractive:function(d,h,c){var a=d.getMass(),e=-c.x*h*this.diffTemperature;
h=-c.y*h*this.diffTemperature;d.fromNode.fixedPosition||(d.fromNode.plotX-=e*a.fromNode/d.fromNode.degree,d.fromNode.plotY-=h*a.fromNode/d.fromNode.degree);d.toNode.fixedPosition||(d.toNode.plotX+=e*a.toNode/d.toNode.degree,d.toNode.plotY+=h*a.toNode/d.toNode.degree)},integrate:function(d,h){var c=-d.options.friction,a=d.options.maxSpeed,e=(h.plotX+h.dispX-h.prevX)*c;c*=h.plotY+h.dispY-h.prevY;var m=Math.abs,l=m(e)/(e||1);m=m(c)/(c||1);e=l*Math.min(a,Math.abs(e));c=m*Math.min(a,Math.abs(c));h.prevX=
h.plotX+h.dispX;h.prevY=h.plotY+h.dispY;h.plotX+=e;h.plotY+=c;h.temperature=d.vectorLength({x:e,y:c})},getK:function(d){return Math.pow(d.box.width*d.box.height/d.nodes.length,.5)}},euler:{attractiveForceFunction:function(d,e){return d*d/e},repulsiveForceFunction:function(d,e){return e*e/d},barycenter:function(){var d=this.options.gravitationalConstant,e=this.barycenter.xFactor,c=this.barycenter.yFactor;this.nodes.forEach(function(a){if(!a.fixedPosition){var h=a.getDegree();h*=1+h/2;a.dispX+=(e-a.plotX)*
d*h/a.degree;a.dispY+=(c-a.plotY)*d*h/a.degree}})},repulsive:function(d,e,c,a){d.dispX+=c.x/a*e/d.degree;d.dispY+=c.y/a*e/d.degree},attractive:function(d,e,c,a){var h=d.getMass(),m=c.x/a*e;e*=c.y/a;d.fromNode.fixedPosition||(d.fromNode.dispX-=m*h.fromNode/d.fromNode.degree,d.fromNode.dispY-=e*h.fromNode/d.fromNode.degree);d.toNode.fixedPosition||(d.toNode.dispX+=m*h.toNode/d.toNode.degree,d.toNode.dispY+=e*h.toNode/d.toNode.degree)},integrate:function(d,e){e.dispX+=e.dispX*d.options.friction;e.dispY+=
e.dispY*d.options.friction;var c=e.temperature=d.vectorLength({x:e.dispX,y:e.dispY});0!==c&&(e.plotX+=e.dispX/c*Math.min(Math.abs(e.dispX),d.temperature),e.plotY+=e.dispY/c*Math.min(Math.abs(e.dispY),d.temperature))},getK:function(d){return Math.pow(d.box.width*d.box.height/d.nodes.length,.3)}}}});z(e,"Series/Networkgraph/QuadTree.js",[e["Core/Globals.js"],e["Core/Utilities.js"]],function(e,d){d=d.extend;var h=e.QuadTreeNode=function(c){this.box=c;this.boxSize=Math.min(c.width,c.height);this.nodes=
[];this.body=this.isInternal=!1;this.isEmpty=!0};d(h.prototype,{insert:function(c,a){this.isInternal?this.nodes[this.getBoxPosition(c)].insert(c,a-1):(this.isEmpty=!1,this.body?a?(this.isInternal=!0,this.divideBox(),!0!==this.body&&(this.nodes[this.getBoxPosition(this.body)].insert(this.body,a-1),this.body=!0),this.nodes[this.getBoxPosition(c)].insert(c,a-1)):(a=new h({top:c.plotX,left:c.plotY,width:.1,height:.1}),a.body=c,a.isInternal=!1,this.nodes.push(a)):(this.isInternal=!1,this.body=c))},updateMassAndCenter:function(){var c=
0,a=0,d=0;this.isInternal?(this.nodes.forEach(function(e){e.isEmpty||(c+=e.mass,a+=e.plotX*e.mass,d+=e.plotY*e.mass)}),a/=c,d/=c):this.body&&(c=this.body.mass,a=this.body.plotX,d=this.body.plotY);this.mass=c;this.plotX=a;this.plotY=d},divideBox:function(){var c=this.box.width/2,a=this.box.height/2;this.nodes[0]=new h({left:this.box.left,top:this.box.top,width:c,height:a});this.nodes[1]=new h({left:this.box.left+c,top:this.box.top,width:c,height:a});this.nodes[2]=new h({left:this.box.left+c,top:this.box.top+
a,width:c,height:a});this.nodes[3]=new h({left:this.box.left,top:this.box.top+a,width:c,height:a})},getBoxPosition:function(c){var a=c.plotY<this.box.top+this.box.height/2;return c.plotX<this.box.left+this.box.width/2?a?0:3:a?1:2}});e=e.QuadTree=function(c,a,d,e){this.box={left:c,top:a,width:d,height:e};this.maxDepth=25;this.root=new h(this.box,"0");this.root.isInternal=!0;this.root.isRoot=!0;this.root.divideBox()};d(e.prototype,{insertNodes:function(c){c.forEach(function(a){this.root.insert(a,this.maxDepth)},
this)},visitNodeRecursive:function(c,a,d){var e;c||(c=this.root);c===this.root&&a&&(e=a(c));!1!==e&&(c.nodes.forEach(function(c){if(c.isInternal){a&&(e=a(c));if(!1===e)return;this.visitNodeRecursive(c,a,d)}else c.body&&a&&a(c.body);d&&d(c)},this),c===this.root&&d&&d(c))},calculateMassAndCenter:function(){this.visitNodeRecursive(null,null,function(c){c.updateMassAndCenter()})}})});z(e,"Series/Networkgraph/Layouts.js",[e["Core/Chart/Chart.js"],e["Core/Animation/AnimationUtilities.js"],e["Core/Globals.js"],
e["Core/Utilities.js"]],function(e,d,h,c){var a=d.setAnimation;d=c.addEvent;var t=c.clamp,m=c.defined,l=c.extend,r=c.isFunction,x=c.pick;h.layouts={"reingold-fruchterman":function(){}};l(h.layouts["reingold-fruchterman"].prototype,{init:function(b){this.options=b;this.nodes=[];this.links=[];this.series=[];this.box={x:0,y:0,width:0,height:0};this.setInitialRendering(!0);this.integration=h.networkgraphIntegrations[b.integration];this.enableSimulation=b.enableSimulation;this.attractiveForce=x(b.attractiveForce,
this.integration.attractiveForceFunction);this.repulsiveForce=x(b.repulsiveForce,this.integration.repulsiveForceFunction);this.approximation=b.approximation},updateSimulation:function(b){this.enableSimulation=x(b,this.options.enableSimulation)},start:function(){var b=this.series,a=this.options;this.currentStep=0;this.forces=b[0]&&b[0].forces||[];this.chart=b[0]&&b[0].chart;this.initialRendering&&(this.initPositions(),b.forEach(function(b){b.finishedAnimating=!0;b.render()}));this.setK();this.resetSimulation(a);
this.enableSimulation&&this.step()},step:function(){var b=this,a=this.series;b.currentStep++;"barnes-hut"===b.approximation&&(b.createQuadTree(),b.quadTree.calculateMassAndCenter());b.forces.forEach(function(a){b[a+"Forces"](b.temperature)});b.applyLimits(b.temperature);b.temperature=b.coolDown(b.startTemperature,b.diffTemperature,b.currentStep);b.prevSystemTemperature=b.systemTemperature;b.systemTemperature=b.getSystemTemperature();b.enableSimulation&&(a.forEach(function(b){b.chart&&b.render()}),
b.maxIterations--&&isFinite(b.temperature)&&!b.isStable()?(b.simulation&&h.win.cancelAnimationFrame(b.simulation),b.simulation=h.win.requestAnimationFrame(function(){b.step()})):b.simulation=!1)},stop:function(){this.simulation&&h.win.cancelAnimationFrame(this.simulation)},setArea:function(b,a,c,d){this.box={left:b,top:a,width:c,height:d}},setK:function(){this.k=this.options.linkLength||this.integration.getK(this)},addElementsToCollection:function(b,a){b.forEach(function(b){-1===a.indexOf(b)&&a.push(b)})},
removeElementFromCollection:function(b,a){b=a.indexOf(b);-1!==b&&a.splice(b,1)},clear:function(){this.nodes.length=0;this.links.length=0;this.series.length=0;this.resetSimulation()},resetSimulation:function(){this.forcedStop=!1;this.systemTemperature=0;this.setMaxIterations();this.setTemperature();this.setDiffTemperature()},restartSimulation:function(){this.simulation?this.resetSimulation():(this.setInitialRendering(!1),this.enableSimulation?this.start():this.setMaxIterations(1),this.chart&&this.chart.redraw(),
this.setInitialRendering(!0))},setMaxIterations:function(b){this.maxIterations=x(b,this.options.maxIterations)},setTemperature:function(){this.temperature=this.startTemperature=Math.sqrt(this.nodes.length)},setDiffTemperature:function(){this.diffTemperature=this.startTemperature/(this.options.maxIterations+1)},setInitialRendering:function(b){this.initialRendering=b},createQuadTree:function(){this.quadTree=new h.QuadTree(this.box.left,this.box.top,this.box.width,this.box.height);this.quadTree.insertNodes(this.nodes)},
initPositions:function(){var b=this.options.initialPositions;r(b)?(b.call(this),this.nodes.forEach(function(b){m(b.prevX)||(b.prevX=b.plotX);m(b.prevY)||(b.prevY=b.plotY);b.dispX=0;b.dispY=0})):"circle"===b?this.setCircularPositions():this.setRandomPositions()},setCircularPositions:function(){function b(a){a.linksFrom.forEach(function(a){h[a.toNode.id]||(h[a.toNode.id]=!0,l.push(a.toNode),b(a.toNode))})}var a=this.box,c=this.nodes,d=2*Math.PI/(c.length+1),e=c.filter(function(b){return 0===b.linksTo.length}),
l=[],h={},m=this.options.initialPositionRadius;e.forEach(function(a){l.push(a);b(a)});l.length?c.forEach(function(b){-1===l.indexOf(b)&&l.push(b)}):l=c;l.forEach(function(b,c){b.plotX=b.prevX=x(b.plotX,a.width/2+m*Math.cos(c*d));b.plotY=b.prevY=x(b.plotY,a.height/2+m*Math.sin(c*d));b.dispX=0;b.dispY=0})},setRandomPositions:function(){function b(b){b=b*b/Math.PI;return b-=Math.floor(b)}var a=this.box,c=this.nodes,d=c.length+1;c.forEach(function(c,e){c.plotX=c.prevX=x(c.plotX,a.width*b(e));c.plotY=
c.prevY=x(c.plotY,a.height*b(d+e));c.dispX=0;c.dispY=0})},force:function(b){this.integration[b].apply(this,Array.prototype.slice.call(arguments,1))},barycenterForces:function(){this.getBarycenter();this.force("barycenter")},getBarycenter:function(){var b=0,a=0,c=0;this.nodes.forEach(function(d){a+=d.plotX*d.mass;c+=d.plotY*d.mass;b+=d.mass});return this.barycenter={x:a,y:c,xFactor:a/b,yFactor:c/b}},barnesHutApproximation:function(b,a){var c=this.getDistXY(b,a),d=this.vectorLength(c);if(b!==a&&0!==
d)if(a.isInternal)if(a.boxSize/d<this.options.theta&&0!==d){var e=this.repulsiveForce(d,this.k);this.force("repulsive",b,e*a.mass,c,d);var l=!1}else l=!0;else e=this.repulsiveForce(d,this.k),this.force("repulsive",b,e*a.mass,c,d);return l},repulsiveForces:function(){var b=this;"barnes-hut"===b.approximation?b.nodes.forEach(function(a){b.quadTree.visitNodeRecursive(null,function(c){return b.barnesHutApproximation(a,c)})}):b.nodes.forEach(function(a){b.nodes.forEach(function(c){if(a!==c&&!a.fixedPosition){var d=
b.getDistXY(a,c);var e=b.vectorLength(d);if(0!==e){var k=b.repulsiveForce(e,b.k);b.force("repulsive",a,k*c.mass,d,e)}}})})},attractiveForces:function(){var b=this,a,c,d;b.links.forEach(function(e){e.fromNode&&e.toNode&&(a=b.getDistXY(e.fromNode,e.toNode),c=b.vectorLength(a),0!==c&&(d=b.attractiveForce(c,b.k),b.force("attractive",e,d,a,c)))})},applyLimits:function(){var b=this;b.nodes.forEach(function(a){a.fixedPosition||(b.integration.integrate(b,a),b.applyLimitBox(a,b.box),a.dispX=0,a.dispY=0)})},
applyLimitBox:function(b,a){var c=b.radius;b.plotX=t(b.plotX,a.left+c,a.width-c);b.plotY=t(b.plotY,a.top+c,a.height-c)},coolDown:function(a,c,d){return a-c*d},isStable:function(){return.00001>Math.abs(this.systemTemperature-this.prevSystemTemperature)||0>=this.temperature},getSystemTemperature:function(){return this.nodes.reduce(function(a,c){return a+c.temperature},0)},vectorLength:function(a){return Math.sqrt(a.x*a.x+a.y*a.y)},getDistR:function(a,c){a=this.getDistXY(a,c);return this.vectorLength(a)},
getDistXY:function(a,c){var b=a.plotX-c.plotX;a=a.plotY-c.plotY;return{x:b,y:a,absX:Math.abs(b),absY:Math.abs(a)}}});d(e,"predraw",function(){this.graphLayoutsLookup&&this.graphLayoutsLookup.forEach(function(a){a.stop()})});d(e,"render",function(){function b(a){a.maxIterations--&&isFinite(a.temperature)&&!a.isStable()&&!a.enableSimulation&&(a.beforeStep&&a.beforeStep(),a.step(),d=!1,c=!0)}var c=!1;if(this.graphLayoutsLookup){a(!1,this);for(this.graphLayoutsLookup.forEach(function(a){a.start()});!d;){var d=
!0;this.graphLayoutsLookup.forEach(b)}c&&this.series.forEach(function(a){a&&a.layout&&a.render()})}});d(e,"beforePrint",function(){this.graphLayoutsLookup&&(this.graphLayoutsLookup.forEach(function(a){a.updateSimulation(!1)}),this.redraw())});d(e,"afterPrint",function(){this.graphLayoutsLookup&&this.graphLayoutsLookup.forEach(function(a){a.updateSimulation()});this.redraw()})});z(e,"Series/PackedBubble/PackedBubbleComposition.js",[e["Core/Chart/Chart.js"],e["Core/Globals.js"],e["Core/Utilities.js"]],
function(e,d,h){var c=d.layouts["reingold-fruchterman"],a=h.addEvent,t=h.extendClass,m=h.pick;e.prototype.getSelectedParentNodes=function(){var a=[];this.series.forEach(function(c){c.parentNode&&c.parentNode.selected&&a.push(c.parentNode)});return a};d.networkgraphIntegrations.packedbubble={repulsiveForceFunction:function(a,c,d,b){return Math.min(a,(d.marker.radius+b.marker.radius)/2)},barycenter:function(){var a=this,c=a.options.gravitationalConstant,d=a.box,b=a.nodes,e,k;b.forEach(function(l){a.options.splitSeries&&
!l.isParentNode?(e=l.series.parentNode.plotX,k=l.series.parentNode.plotY):(e=d.width/2,k=d.height/2);l.fixedPosition||(l.plotX-=(l.plotX-e)*c/(l.mass*Math.sqrt(b.length)),l.plotY-=(l.plotY-k)*c/(l.mass*Math.sqrt(b.length)))})},repulsive:function(a,c,d,b){var e=c*this.diffTemperature/a.mass/a.degree;c=d.x*e;d=d.y*e;a.fixedPosition||(a.plotX+=c,a.plotY+=d);b.fixedPosition||(b.plotX-=c,b.plotY-=d)},integrate:d.networkgraphIntegrations.verlet.integrate,getK:d.noop};d.layouts.packedbubble=t(c,{beforeStep:function(){this.options.marker&&
this.series.forEach(function(a){a&&a.calculateParentRadius()})},isStable:function(){var a=Math.abs(this.prevSystemTemperature-this.systemTemperature);return 1>Math.abs(10*this.systemTemperature/Math.sqrt(this.nodes.length))&&.00001>a||0>=this.temperature},setCircularPositions:function(){var a=this,c=a.box,d=a.nodes,b=2*Math.PI/(d.length+1),e,k,h=a.options.initialPositionRadius;d.forEach(function(d,l){a.options.splitSeries&&!d.isParentNode?(e=d.series.parentNode.plotX,k=d.series.parentNode.plotY):
(e=c.width/2,k=c.height/2);d.plotX=d.prevX=m(d.plotX,e+h*Math.cos(d.index||l*b));d.plotY=d.prevY=m(d.plotY,k+h*Math.sin(d.index||l*b));d.dispX=0;d.dispY=0})},repulsiveForces:function(){var a=this,c,d,b,e=a.options.bubblePadding;a.nodes.forEach(function(k){k.degree=k.mass;k.neighbours=0;a.nodes.forEach(function(h){c=0;k===h||k.fixedPosition||!a.options.seriesInteraction&&k.series!==h.series||(b=a.getDistXY(k,h),d=a.vectorLength(b)-(k.marker.radius+h.marker.radius+e),0>d&&(k.degree+=.01,k.neighbours++,
c=a.repulsiveForce(-d/Math.sqrt(k.neighbours),a.k,k,h)),a.force("repulsive",k,c*h.mass,b,h,d))})})},applyLimitBox:function(a){if(this.options.splitSeries&&!a.isParentNode&&this.options.parentNodeLimit){var d=this.getDistXY(a,a.series.parentNode);var e=a.series.parentNodeRadius-a.marker.radius-this.vectorLength(d);0>e&&e>-2*a.marker.radius&&(a.plotX-=.01*d.x,a.plotY-=.01*d.y)}c.prototype.applyLimitBox.apply(this,arguments)}});a(e,"beforeRedraw",function(){this.allDataPoints&&delete this.allDataPoints})});
z(e,"Series/PackedBubble/PackedBubbleSeries.js",[e["Core/Color/Color.js"],e["Core/Globals.js"],e["Series/PackedBubble/PackedBubblePoint.js"],e["Core/Series/SeriesRegistry.js"],e["Core/Utilities.js"]],function(e,d,h,c,a){var t=this&&this.__extends||function(){var a=function(b,f){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,b){a.__proto__=b}||function(a,b){for(var f in b)b.hasOwnProperty(f)&&(a[f]=b[f])};return a(b,f)};return function(b,f){function c(){this.constructor=b}a(b,
f);b.prototype=null===f?Object.create(f):(c.prototype=f.prototype,new c)}}(),m=e.parse,l=c.series,r=c.seriesTypes.bubble,x=a.addEvent,b=a.clamp,q=a.defined,k=a.extend,p=a.fireEvent,v=a.isArray,B=a.isNumber,z=a.merge,D=a.pick,y=d.dragNodesMixin;e=function(a){function c(){var b=null!==a&&a.apply(this,arguments)||this;b.chart=void 0;b.data=void 0;b.layout=void 0;b.options=void 0;b.points=void 0;b.xData=void 0;return b}t(c,a);c.prototype.accumulateAllPoints=function(a){var b=a.chart,c=[],f,d;for(f=0;f<
b.series.length;f++)if(a=b.series[f],a.is("packedbubble")&&a.visible||!b.options.chart.ignoreHiddenSeries)for(d=0;d<a.yData.length;d++)c.push([null,null,a.yData[d],a.index,d,{id:d,marker:{radius:0}}]);return c};c.prototype.addLayout=function(){var a=this.options.layoutAlgorithm,b=this.chart.graphLayoutsStorage,c=this.chart.graphLayoutsLookup,g=this.chart.options.chart;b||(this.chart.graphLayoutsStorage=b={},this.chart.graphLayoutsLookup=c=[]);var e=b[a.type];e||(a.enableSimulation=q(g.forExport)?
!g.forExport:a.enableSimulation,b[a.type]=e=new d.layouts[a.type],e.init(a),c.splice(e.index,0,e));this.layout=e;this.points.forEach(function(a){a.mass=2;a.degree=1;a.collisionNmb=1});e.setArea(0,0,this.chart.plotWidth,this.chart.plotHeight);e.addElementsToCollection([this],e.series);e.addElementsToCollection(this.points,e.nodes)};c.prototype.addSeriesLayout=function(){var a=this.options.layoutAlgorithm,b=this.chart.graphLayoutsStorage,c=this.chart.graphLayoutsLookup,g=z(a,a.parentNodeOptions,{enableSimulation:this.layout.options.enableSimulation});
var e=b[a.type+"-series"];e||(b[a.type+"-series"]=e=new d.layouts[a.type],e.init(g),c.splice(e.index,0,e));this.parentNodeLayout=e;this.createParentNodes()};c.prototype.calculateParentRadius=function(){var a=this.seriesBox();this.parentNodeRadius=b(Math.sqrt(2*this.parentNodeMass/Math.PI)+20,20,a?Math.max(Math.sqrt(Math.pow(a.width,2)+Math.pow(a.height,2))/2+20,20):Math.sqrt(2*this.parentNodeMass/Math.PI)+20);this.parentNode&&(this.parentNode.marker.radius=this.parentNode.radius=this.parentNodeRadius)};
c.prototype.calculateZExtremes=function(){var a=this.options.zMin,b=this.options.zMax,c=Infinity,d=-Infinity;if(a&&b)return[a,b];this.chart.series.forEach(function(a){a.yData.forEach(function(a){q(a)&&(a>d&&(d=a),a<c&&(c=a))})});a=D(a,c);b=D(b,d);return[a,b]};c.prototype.checkOverlap=function(a,b){var c=a[0]-b[0],f=a[1]-b[1];return-.001>Math.sqrt(c*c+f*f)-Math.abs(a[2]+b[2])};c.prototype.createParentNodes=function(){var a=this,b=a.chart,c=a.parentNodeLayout,d,g=a.parentNode,e=a.pointClass;a.parentNodeMass=
0;a.points.forEach(function(b){a.parentNodeMass+=Math.PI*Math.pow(b.marker.radius,2)});a.calculateParentRadius();c.nodes.forEach(function(b){b.seriesIndex===a.index&&(d=!0)});c.setArea(0,0,b.plotWidth,b.plotHeight);d||(g||(g=(new e).init(this,{mass:a.parentNodeRadius/2,marker:{radius:a.parentNodeRadius},dataLabels:{inside:!1},dataLabelOnNull:!0,degree:a.parentNodeRadius,isParentNode:!0,seriesIndex:a.index})),a.parentNode&&(g.plotX=a.parentNode.plotX,g.plotY=a.parentNode.plotY),a.parentNode=g,c.addElementsToCollection([a],
c.series),c.addElementsToCollection([g],c.nodes))};c.prototype.deferLayout=function(){var a=this.options.layoutAlgorithm;this.visible&&(this.addLayout(),a.splitSeries&&this.addSeriesLayout())};c.prototype.destroy=function(){this.chart.graphLayoutsLookup&&this.chart.graphLayoutsLookup.forEach(function(a){a.removeElementFromCollection(this,a.series)},this);this.parentNode&&this.parentNodeLayout&&(this.parentNodeLayout.removeElementFromCollection(this.parentNode,this.parentNodeLayout.nodes),this.parentNode.dataLabel&&
(this.parentNode.dataLabel=this.parentNode.dataLabel.destroy()));l.prototype.destroy.apply(this,arguments)};c.prototype.drawDataLabels=function(){var a=this.options.dataLabels.textPath,b=this.points;l.prototype.drawDataLabels.apply(this,arguments);this.parentNode&&(this.parentNode.formatPrefix="parentNode",this.points=[this.parentNode],this.options.dataLabels.textPath=this.options.dataLabels.parentNodeTextPath,l.prototype.drawDataLabels.apply(this,arguments),this.points=b,this.options.dataLabels.textPath=
a)};c.prototype.drawGraph=function(){if(this.layout&&this.layout.options.splitSeries){var a=this.chart;var b=this.layout.options.parentNodeOptions.marker;var c={fill:b.fillColor||m(this.color).brighten(.4).get(),opacity:b.fillOpacity,stroke:b.lineColor||this.color,"stroke-width":b.lineWidth};this.parentNodesGroup||(this.parentNodesGroup=this.plotGroup("parentNodesGroup","parentNode",this.visible?"inherit":"hidden",.1,a.seriesGroup),this.group.attr({zIndex:2}));this.calculateParentRadius();b=z({x:this.parentNode.plotX-
this.parentNodeRadius,y:this.parentNode.plotY-this.parentNodeRadius,width:2*this.parentNodeRadius,height:2*this.parentNodeRadius},c);this.parentNode.graphic||(this.graph=this.parentNode.graphic=a.renderer.symbol(c.symbol).add(this.parentNodesGroup));this.parentNode.graphic.attr(b)}};c.prototype.drawTracker=function(){var b=this.parentNode;a.prototype.drawTracker.call(this);if(b){var c=v(b.dataLabels)?b.dataLabels:b.dataLabel?[b.dataLabel]:[];b.graphic&&(b.graphic.element.point=b);c.forEach(function(a){a.div?
a.div.point=b:a.element.point=b})}};c.prototype.getPointRadius=function(){var a=this,c=a.chart,d=a.options,g=d.useSimulation,e=Math.min(c.plotWidth,c.plotHeight),k={},h=[],l=c.allDataPoints,q,p,m,r;["minSize","maxSize"].forEach(function(a){var b=parseInt(d[a],10),c=/%$/.test(d[a]);k[a]=c?e*b/100:b*Math.sqrt(l.length)});c.minRadius=q=k.minSize/Math.sqrt(l.length);c.maxRadius=p=k.maxSize/Math.sqrt(l.length);var v=g?a.calculateZExtremes():[q,p];(l||[]).forEach(function(c,f){m=g?b(c[2],v[0],v[1]):c[2];
r=a.getRadius(v[0],v[1],q,p,m);0===r&&(r=null);l[f][2]=r;h.push(r)});a.radii=h};c.prototype.init=function(){l.prototype.init.apply(this,arguments);this.eventsToUnbind.push(x(this,"updatedData",function(){this.chart.series.forEach(function(a){a.type===this.type&&(a.isDirty=!0)},this)}));return this};c.prototype.onMouseUp=function(a){if(a.fixedPosition&&!a.removed){var b,c,f=this.layout,d=this.parentNodeLayout;d&&f.options.dragBetweenSeries&&d.nodes.forEach(function(d){a&&a.marker&&d!==a.series.parentNode&&
(b=f.getDistXY(a,d),c=f.vectorLength(b)-d.marker.radius-a.marker.radius,0>c&&(d.series.addPoint(z(a.options,{plotX:a.plotX,plotY:a.plotY}),!1),f.removeElementFromCollection(a,f.nodes),a.remove()))});y.onMouseUp.apply(this,arguments)}};c.prototype.placeBubbles=function(a){var b=this.checkOverlap,c=this.positionBubble,f=[],d=1,g=0,e=0;var k=[];var h;a=a.sort(function(a,b){return b[2]-a[2]});if(a.length){f.push([[0,0,a[0][2],a[0][3],a[0][4]]]);if(1<a.length)for(f.push([[0,0-a[1][2]-a[0][2],a[1][2],a[1][3],
a[1][4]]]),h=2;h<a.length;h++)a[h][2]=a[h][2]||1,k=c(f[d][g],f[d-1][e],a[h]),b(k,f[d][0])?(f.push([]),e=0,f[d+1].push(c(f[d][g],f[d][0],a[h])),d++,g=0):1<d&&f[d-1][e+1]&&b(k,f[d-1][e+1])?(e++,f[d].push(c(f[d][g],f[d-1][e],a[h])),g++):(g++,f[d].push(k));this.chart.stages=f;this.chart.rawPositions=[].concat.apply([],f);this.resizeRadius();k=this.chart.rawPositions}return k};c.prototype.positionBubble=function(a,b,c){var f=Math.sqrt,d=Math.asin,g=Math.acos,e=Math.pow,k=Math.abs;f=f(e(a[0]-b[0],2)+e(a[1]-
b[1],2));g=g((e(f,2)+e(c[2]+b[2],2)-e(c[2]+a[2],2))/(2*(c[2]+b[2])*f));d=d(k(a[0]-b[0])/f);a=(0>a[1]-b[1]?0:Math.PI)+g+d*(0>(a[0]-b[0])*(a[1]-b[1])?1:-1);return[b[0]+(b[2]+c[2])*Math.sin(a),b[1]-(b[2]+c[2])*Math.cos(a),c[2],c[3],c[4]]};c.prototype.render=function(){var a=[];l.prototype.render.apply(this,arguments);this.options.dataLabels.allowOverlap||(this.data.forEach(function(b){v(b.dataLabels)&&b.dataLabels.forEach(function(b){a.push(b)})}),this.options.useSimulation&&this.chart.hideOverlappingLabels(a))};
c.prototype.resizeRadius=function(){var a=this.chart,b=a.rawPositions,c=Math.min,d=Math.max,g=a.plotLeft,e=a.plotTop,k=a.plotHeight,h=a.plotWidth,l,q,p;var m=l=Number.POSITIVE_INFINITY;var r=q=Number.NEGATIVE_INFINITY;for(p=0;p<b.length;p++){var v=b[p][2];m=c(m,b[p][0]-v);r=d(r,b[p][0]+v);l=c(l,b[p][1]-v);q=d(q,b[p][1]+v)}p=[r-m,q-l];c=c.apply([],[(h-g)/p[0],(k-e)/p[1]]);if(1e-10<Math.abs(c-1)){for(p=0;p<b.length;p++)b[p][2]*=c;this.placeBubbles(b)}else a.diffY=k/2+e-l-(q-l)/2,a.diffX=h/2+g-m-(r-
m)/2};c.prototype.seriesBox=function(){var a=this.chart,b=Math.max,c=Math.min,d,g=[a.plotLeft,a.plotLeft+a.plotWidth,a.plotTop,a.plotTop+a.plotHeight];this.data.forEach(function(a){q(a.plotX)&&q(a.plotY)&&a.marker.radius&&(d=a.marker.radius,g[0]=c(g[0],a.plotX-d),g[1]=b(g[1],a.plotX+d),g[2]=c(g[2],a.plotY-d),g[3]=b(g[3],a.plotY+d))});return B(g.width/g.height)?g:null};c.prototype.setVisible=function(){var a=this;l.prototype.setVisible.apply(a,arguments);a.parentNodeLayout&&a.graph?a.visible?(a.graph.show(),
a.parentNode.dataLabel&&a.parentNode.dataLabel.show()):(a.graph.hide(),a.parentNodeLayout.removeElementFromCollection(a.parentNode,a.parentNodeLayout.nodes),a.parentNode.dataLabel&&a.parentNode.dataLabel.hide()):a.layout&&(a.visible?a.layout.addElementsToCollection(a.points,a.layout.nodes):a.points.forEach(function(b){a.layout.removeElementFromCollection(b,a.layout.nodes)}))};c.prototype.translate=function(){var a=this.chart,b=this.data,c=this.index,d,g=this.options.useSimulation;this.processedXData=
this.xData;this.generatePoints();q(a.allDataPoints)||(a.allDataPoints=this.accumulateAllPoints(this),this.getPointRadius());if(g)var e=a.allDataPoints;else e=this.placeBubbles(a.allDataPoints),this.options.draggable=!1;for(d=0;d<e.length;d++)if(e[d][3]===c){var h=b[e[d][4]];var l=D(e[d][2],void 0);g||(h.plotX=e[d][0]-a.plotLeft+a.diffX,h.plotY=e[d][1]-a.plotTop+a.diffY);B(l)&&(h.marker=k(h.marker,{radius:l,width:2*l,height:2*l}),h.radius=l)}g&&this.deferLayout();p(this,"afterTranslate")};c.defaultOptions=
z(r.defaultOptions,{minSize:"10%",maxSize:"50%",sizeBy:"area",zoneAxis:"y",crisp:!1,tooltip:{pointFormat:"Value: {point.value}"},draggable:!0,useSimulation:!0,parentNode:{allowPointSelect:!1},dataLabels:{formatter:function(){var a=this.series.chart.numberFormatter,b=this.point.value;return B(b)?a(b,-1):""},parentNodeFormatter:function(){return this.name},parentNodeTextPath:{enabled:!0},padding:0,style:{transition:"opacity 2000ms"}},layoutAlgorithm:{initialPositions:"circle",initialPositionRadius:20,
bubblePadding:5,parentNodeLimit:!1,seriesInteraction:!0,dragBetweenSeries:!1,parentNodeOptions:{maxIterations:400,gravitationalConstant:.03,maxSpeed:50,initialPositionRadius:100,seriesInteraction:!0,marker:{fillColor:null,fillOpacity:1,lineWidth:1,lineColor:null,symbol:"circle"}},enableSimulation:!0,type:"packedbubble",integration:"packedbubble",maxIterations:1E3,splitSeries:!1,maxSpeed:5,gravitationalConstant:.01,friction:-.981}});return c}(r);k(e.prototype,{alignDataLabel:l.prototype.alignDataLabel,
axisTypes:[],directTouch:!0,forces:["barycenter","repulsive"],hasDraggableNodes:!0,isCartesian:!1,noSharedTooltip:!0,onMouseDown:y.onMouseDown,onMouseMove:y.onMouseMove,pointArrayMap:["value"],pointClass:h,pointValKey:"value",redrawHalo:y.redrawHalo,requireSorting:!1,searchPoint:d.noop,trackerGroups:["group","dataLabelsGroup","parentNodesGroup"]});c.registerSeriesType("packedbubble",e);"";"";return e});z(e,"Series/Polygon/PolygonSeries.js",[e["Core/Globals.js"],e["Core/Legend/LegendSymbol.js"],e["Core/Series/SeriesRegistry.js"],
e["Core/Utilities.js"]],function(e,d,h,c){var a=this&&this.__extends||function(){var a=function(b,c){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,b){a.__proto__=b}||function(a,b){for(var c in b)b.hasOwnProperty(c)&&(a[c]=b[c])};return a(b,c)};return function(b,c){function d(){this.constructor=b}a(b,c);b.prototype=null===c?Object.create(c):(d.prototype=c.prototype,new d)}}();e=e.noop;var t=h.series,m=h.seriesTypes,l=m.area,r=m.line,x=m.scatter;m=c.extend;var b=c.merge;c=function(c){function d(){var a=
null!==c&&c.apply(this,arguments)||this;a.data=void 0;a.options=void 0;a.points=void 0;return a}a(d,c);d.prototype.getGraphPath=function(){for(var a=r.prototype.getGraphPath.call(this),b=a.length+1;b--;)(b===a.length||"M"===a[b][0])&&0<b&&a.splice(b,0,["Z"]);return this.areaPath=a};d.prototype.drawGraph=function(){this.options.fillColor=this.color;l.prototype.drawGraph.call(this)};d.defaultOptions=b(x.defaultOptions,{marker:{enabled:!1,states:{hover:{enabled:!1}}},stickyTracking:!1,tooltip:{followPointer:!0,
pointFormat:""},trackByArea:!0});return d}(x);m(c.prototype,{type:"polygon",drawLegendSymbol:d.drawRectangle,drawTracker:t.prototype.drawTracker,setStackedPoints:e});h.registerSeriesType("polygon",c);"";return c});z(e,"Core/Axis/WaterfallAxis.js",[e["Extensions/Stacking.js"],e["Core/Utilities.js"]],function(e,d){var h=d.addEvent,c=d.objectEach,a;(function(a){function d(){var a=this.waterfall.stacks;a&&(a.changed=!1,delete a.alreadyChanged)}function l(){var a=this.options.stackLabels;a&&a.enabled&&
this.waterfall.stacks&&this.waterfall.renderStackTotals()}function r(){for(var a=this.axes,b=this.series,c=b.length;c--;)b[c].options.stacking&&(a.forEach(function(a){a.isXAxis||(a.waterfall.stacks.changed=!0)}),c=0)}function x(){this.waterfall||(this.waterfall=new b(this))}var b=function(){function a(a){this.axis=a;this.stacks={changed:!1}}a.prototype.renderStackTotals=function(){var a=this.axis,b=a.waterfall.stacks,d=a.stacking&&a.stacking.stackTotalGroup,h=new e(a,a.options.stackLabels,!1,0,void 0);
this.dummyStackItem=h;c(b,function(a){c(a,function(a){h.total=a.stackTotal;a.label&&(h.label=a.label);e.prototype.render.call(h,d);a.label=h.label;delete h.label})});h.total=null};return a}();a.Composition=b;a.compose=function(a,b){h(a,"init",x);h(a,"afterBuildStacks",d);h(a,"afterRender",l);h(b,"beforeRedraw",r)}})(a||(a={}));return a});z(e,"Series/Waterfall/WaterfallPoint.js",[e["Series/Column/ColumnSeries.js"],e["Core/Series/Point.js"],e["Core/Utilities.js"]],function(e,d,h){var c=this&&this.__extends||
function(){var a=function(c,d){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,c){a.__proto__=c}||function(a,c){for(var b in c)c.hasOwnProperty(b)&&(a[b]=c[b])};return a(c,d)};return function(c,d){function e(){this.constructor=c}a(c,d);c.prototype=null===d?Object.create(d):(e.prototype=d.prototype,new e)}}(),a=h.isNumber;return function(e){function h(){var a=null!==e&&e.apply(this,arguments)||this;a.options=void 0;a.series=void 0;return a}c(h,e);h.prototype.getClassName=function(){var a=
d.prototype.getClassName.call(this);this.isSum?a+=" highcharts-sum":this.isIntermediateSum&&(a+=" highcharts-intermediate-sum");return a};h.prototype.isValid=function(){return a(this.y)||this.isSum||!!this.isIntermediateSum};return h}(e.prototype.pointClass)});z(e,"Series/Waterfall/WaterfallSeries.js",[e["Core/Axis/Axis.js"],e["Core/Chart/Chart.js"],e["Core/Color/Palette.js"],e["Core/Series/SeriesRegistry.js"],e["Core/Utilities.js"],e["Core/Axis/WaterfallAxis.js"],e["Series/Waterfall/WaterfallPoint.js"]],
function(e,d,h,c,a,t,m){var l=this&&this.__extends||function(){var a=function(b,c){a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,b){a.__proto__=b}||function(a,b){for(var c in b)b.hasOwnProperty(c)&&(a[c]=b[c])};return a(b,c)};return function(b,c){function d(){this.constructor=b}a(b,c);b.prototype=null===c?Object.create(c):(d.prototype=c.prototype,new d)}}(),r=c.seriesTypes,x=r.column,b=r.line,q=a.arrayMax,k=a.arrayMin,p=a.correctFloat;r=a.extend;var v=a.isNumber,z=a.merge,D=
a.objectEach,L=a.pick;a=function(a){function c(){var b=null!==a&&a.apply(this,arguments)||this;b.chart=void 0;b.data=void 0;b.options=void 0;b.points=void 0;b.stackedYNeg=void 0;b.stackedYPos=void 0;b.stackKey=void 0;b.xData=void 0;b.yAxis=void 0;b.yData=void 0;return b}l(c,a);c.prototype.generatePoints=function(){var a;x.prototype.generatePoints.apply(this);var b=0;for(a=this.points.length;b<a;b++){var c=this.points[b];var d=this.processedYData[b];if(c.isIntermediateSum||c.isSum)c.y=p(d)}};c.prototype.translate=
function(){var a=this.options,b=this.yAxis,c=L(a.minPointLength,5),d=c/2,e=a.threshold||0,h=e,k=e;a=a.stacking;var l=b.waterfall.stacks[this.stackKey];x.prototype.translate.apply(this);for(var q=this.points,p=0;p<q.length;p++){var m=q[p];var r=this.processedYData[p];var C=m.shapeArgs;if(C&&v(r)){var t=[0,r];var G=m.y;if(a){if(l){t=l[p];if("overlap"===a){var y=t.stackState[t.stateIndex--];y=0<=G?y:y-G;Object.hasOwnProperty.call(t,"absolutePos")&&delete t.absolutePos;Object.hasOwnProperty.call(t,"absoluteNeg")&&
delete t.absoluteNeg}else 0<=G?(y=t.threshold+t.posTotal,t.posTotal-=G):(y=t.threshold+t.negTotal,t.negTotal-=G,y-=G),!t.posTotal&&Object.hasOwnProperty.call(t,"absolutePos")&&(t.posTotal=t.absolutePos,delete t.absolutePos),!t.negTotal&&Object.hasOwnProperty.call(t,"absoluteNeg")&&(t.negTotal=t.absoluteNeg,delete t.absoluteNeg);m.isSum||(t.connectorThreshold=t.threshold+t.stackTotal);b.reversed?(r=0<=G?y-G:y+G,G=y):(r=y,G=y-G);m.below=r<=e;C.y=b.translate(r,!1,!0,!1,!0)||0;C.height=Math.abs(C.y-(b.translate(G,
!1,!0,!1,!0)||0));if(G=b.waterfall.dummyStackItem)G.x=p,G.label=l[p].label,G.setOffset(this.pointXOffset||0,this.barW||0,this.stackedYNeg[p],this.stackedYPos[p])}}else y=Math.max(h,h+G)+t[0],C.y=b.translate(y,!1,!0,!1,!0)||0,m.isSum?(C.y=b.translate(t[1],!1,!0,!1,!0)||0,C.height=Math.min(b.translate(t[0],!1,!0,!1,!0)||0,b.len)-C.y,m.below=t[1]<=e):m.isIntermediateSum?(0<=G?(r=t[1]+k,G=k):(r=k,G=t[1]+k),b.reversed&&(r^=G,G^=r,r^=G),C.y=b.translate(r,!1,!0,!1,!0)||0,C.height=Math.abs(C.y-Math.min(b.translate(G,
!1,!0,!1,!0)||0,b.len)),k+=t[1],m.below=r<=e):(C.height=0<r?(b.translate(h,!1,!0,!1,!0)||0)-C.y:(b.translate(h,!1,!0,!1,!0)||0)-(b.translate(h-r,!1,!0,!1,!0)||0),h+=r,m.below=h<e),0>C.height&&(C.y+=C.height,C.height*=-1);m.plotY=C.y=Math.round(C.y||0)-this.borderWidth%2/2;C.height=Math.max(Math.round(C.height||0),.001);m.yBottom=C.y+C.height;C.height<=c&&!m.isNull?(C.height=c,C.y-=d,m.plotY=C.y,m.minPointLengthOffset=0>m.y?-d:d):(m.isNull&&(C.width=0),m.minPointLengthOffset=0);G=m.plotY+(m.negative?
C.height:0);m.below&&(m.plotY+=C.height);m.tooltipPos&&(this.chart.inverted?m.tooltipPos[0]=b.len-G:m.tooltipPos[1]=G)}}};c.prototype.processData=function(b){var c=this.options,d=this.yData,g=c.data,e=d.length,h=c.threshold||0,k,l,m,q,r;for(r=l=k=m=q=0;r<e;r++){var t=d[r];var v=g&&g[r]?g[r]:{};"sum"===t||v.isSum?d[r]=p(l):"intermediateSum"===t||v.isIntermediateSum?(d[r]=p(k),k=0):(l+=t,k+=t);m=Math.min(l,m);q=Math.max(l,q)}a.prototype.processData.call(this,b);c.stacking||(this.dataMin=m+h,this.dataMax=
q)};c.prototype.toYData=function(a){return a.isSum?"sum":a.isIntermediateSum?"intermediateSum":a.y};c.prototype.updateParallelArrays=function(b,c){a.prototype.updateParallelArrays.call(this,b,c);if("sum"===this.yData[0]||"intermediateSum"===this.yData[0])this.yData[0]=null};c.prototype.pointAttribs=function(a,b){var c=this.options.upColor;c&&!a.options.color&&(a.color=0<a.y?c:null);a=x.prototype.pointAttribs.call(this,a,b);delete a.dashstyle;return a};c.prototype.getGraphPath=function(){return[["M",
0,0]]};c.prototype.getCrispPath=function(){var a=this.data,b=this.yAxis,c=a.length,d=Math.round(this.graph.strokeWidth())%2/2,e=Math.round(this.borderWidth)%2/2,h=this.xAxis.reversed,k=this.yAxis.reversed,l=this.options.stacking,m=[],p;for(p=1;p<c;p++){var q=a[p].shapeArgs;var r=a[p-1];var t=a[p-1].shapeArgs;var v=b.waterfall.stacks[this.stackKey];var x=0<r.y?-t.height:0;v&&t&&q&&(v=v[p-1],l?(v=v.connectorThreshold,x=Math.round(b.translate(v,0,1,0,1)+(k?x:0))-d):x=t.y+r.minPointLengthOffset+e-d,m.push(["M",
(t.x||0)+(h?0:t.width||0),x],["L",(q.x||0)+(h?q.width||0:0),x]));t&&m.length&&(!l&&0>r.y&&!k||0<r.y&&k)&&((r=m[m.length-2])&&"number"===typeof r[2]&&(r[2]+=t.height||0),(r=m[m.length-1])&&"number"===typeof r[2]&&(r[2]+=t.height||0))}return m};c.prototype.drawGraph=function(){b.prototype.drawGraph.call(this);this.graph.attr({d:this.getCrispPath()})};c.prototype.setStackedPoints=function(){function a(a,b,c,d){if(H)for(c;c<H;c++)z.stackState[c]+=d;else z.stackState[0]=a,H=z.stackState.length;z.stackState.push(z.stackState[H-
1]+b)}var b=this.options,c=this.yAxis.waterfall.stacks,d=b.threshold,e=d||0,h=e,k=this.stackKey,l=this.xData,m=l.length,p,q,r;this.yAxis.stacking.usePercentage=!1;var t=q=r=e;if(this.visible||!this.chart.options.chart.ignoreHiddenSeries){var v=c.changed;(p=c.alreadyChanged)&&0>p.indexOf(k)&&(v=!0);c[k]||(c[k]={});p=c[k];for(var x=0;x<m;x++){var y=l[x];if(!p[y]||v)p[y]={negTotal:0,posTotal:0,stackTotal:0,threshold:0,stateIndex:0,stackState:[],label:v&&p[y]?p[y].label:void 0};var z=p[y];var E=this.yData[x];
0<=E?z.posTotal+=E:z.negTotal+=E;var B=b.data[x];y=z.absolutePos=z.posTotal;var D=z.absoluteNeg=z.negTotal;z.stackTotal=y+D;var H=z.stackState.length;B&&B.isIntermediateSum?(a(r,q,0,r),r=q,q=d,e^=h,h^=e,e^=h):B&&B.isSum?(a(d,t,H),e=d):(a(e,E,0,t),B&&(t+=E,q+=E));z.stateIndex++;z.threshold=e;e+=z.stackTotal}c.changed=!1;c.alreadyChanged||(c.alreadyChanged=[]);c.alreadyChanged.push(k)}};c.prototype.getExtremes=function(){var a=this.options.stacking;if(a){var b=this.yAxis;b=b.waterfall.stacks;var c=
this.stackedYNeg=[];var d=this.stackedYPos=[];"overlap"===a?D(b[this.stackKey],function(a){c.push(k(a.stackState));d.push(q(a.stackState))}):D(b[this.stackKey],function(a){c.push(a.negTotal+a.threshold);d.push(a.posTotal+a.threshold)});return{dataMin:k(c),dataMax:q(d)}}return{dataMin:this.dataMin,dataMax:this.dataMax}};c.defaultOptions=z(x.defaultOptions,{dataLabels:{inside:!0},lineWidth:1,lineColor:h.neutralColor80,dashStyle:"Dot",borderColor:h.neutralColor80,states:{hover:{lineWidthPlus:0}}});return c}(x);
r(a.prototype,{getZonesGraphs:b.prototype.getZonesGraphs,pointValKey:"y",showLine:!0,pointClass:m});c.registerSeriesType("waterfall",a);t.compose(e,d);"";return a});z(e,"Extensions/Polar.js",[e["Core/Animation/AnimationUtilities.js"],e["Core/Chart/Chart.js"],e["Core/Globals.js"],e["Extensions/Pane.js"],e["Core/Pointer.js"],e["Core/Series/Series.js"],e["Core/Series/SeriesRegistry.js"],e["Core/Renderer/SVG/SVGRenderer.js"],e["Core/Utilities.js"]],function(e,d,h,c,a,t,m,l,r){var x=e.animObject;m=m.seriesTypes;
var b=r.addEvent,q=r.defined,k=r.find,p=r.isNumber,v=r.pick,z=r.splat,H=r.uniqueKey;e=r.wrap;var D=t.prototype;a=a.prototype;D.searchPointByAngle=function(a){var b=this.chart,c=this.xAxis.pane.center;return this.searchKDTree({clientX:180+-180/Math.PI*Math.atan2(a.chartX-c[0]-b.plotLeft,a.chartY-c[1]-b.plotTop)})};D.getConnectors=function(a,b,c,d){var f=d?1:0;var e=0<=b&&b<=a.length-1?b:0>b?a.length-1+b:0;b=0>e-1?a.length-(1+f):e-1;f=e+1>a.length-1?f:e+1;var g=a[b];f=a[f];var h=g.plotX;g=g.plotY;var k=
f.plotX;var l=f.plotY;f=a[e].plotX;e=a[e].plotY;h=(1.5*f+h)/2.5;g=(1.5*e+g)/2.5;k=(1.5*f+k)/2.5;var n=(1.5*e+l)/2.5;l=Math.sqrt(Math.pow(h-f,2)+Math.pow(g-e,2));var m=Math.sqrt(Math.pow(k-f,2)+Math.pow(n-e,2));h=Math.atan2(g-e,h-f);n=Math.PI/2+(h+Math.atan2(n-e,k-f))/2;Math.abs(h-n)>Math.PI/2&&(n-=Math.PI);h=f+Math.cos(n)*l;g=e+Math.sin(n)*l;k=f+Math.cos(Math.PI+n)*m;n=e+Math.sin(Math.PI+n)*m;f={rightContX:k,rightContY:n,leftContX:h,leftContY:g,plotX:f,plotY:e};c&&(f.prevPointCont=this.getConnectors(a,
b,!1,d));return f};D.toXY=function(a){var b=this.chart,c=this.xAxis,d=this.yAxis,e=a.plotX,g=a.plotY,h=a.series,k=b.inverted,l=a.y,m=k?e:d.len-g;k&&h&&!h.isRadialBar&&(a.plotY=g="number"===typeof l?d.translate(l)||0:0);a.rectPlotX=e;a.rectPlotY=g;d.center&&(m+=d.center[3]/2);p(g)&&(d=k?d.postTranslate(g,m):c.postTranslate(e,m),a.plotX=a.polarPlotX=d.x-b.plotLeft,a.plotY=a.polarPlotY=d.y-b.plotTop);this.kdByAngle?(b=(e/Math.PI*180+c.pane.options.startAngle)%360,0>b&&(b+=360),a.clientX=b):a.clientX=
a.plotX};m.spline&&(e(m.spline.prototype,"getPointSpline",function(a,b,c,d){this.chart.polar?d?(a=this.getConnectors(b,d,!0,this.connectEnds),b=a.prevPointCont&&a.prevPointCont.rightContX,c=a.prevPointCont&&a.prevPointCont.rightContY,a=["C",p(b)?b:a.plotX,p(c)?c:a.plotY,p(a.leftContX)?a.leftContX:a.plotX,p(a.leftContY)?a.leftContY:a.plotY,a.plotX,a.plotY]):a=["M",c.plotX,c.plotY]:a=a.call(this,b,c,d);return a}),m.areasplinerange&&(m.areasplinerange.prototype.getPointSpline=m.spline.prototype.getPointSpline));
b(t,"afterTranslate",function(){var a=this.chart;if(a.polar&&this.xAxis){(this.kdByAngle=a.tooltip&&a.tooltip.shared)?this.searchPoint=this.searchPointByAngle:this.options.findNearestPointBy="xy";if(!this.preventPostTranslate)for(var c=this.points,d=c.length;d--;)this.toXY(c[d]),!a.hasParallelCoordinates&&!this.yAxis.reversed&&c[d].y<this.yAxis.min&&(c[d].isNull=!0);this.hasClipCircleSetter||(this.hasClipCircleSetter=!!this.eventsToUnbind.push(b(this,"afterRender",function(){if(a.polar){var b=this.yAxis.pane.center;
this.clipCircle?this.clipCircle.animate({x:b[0],y:b[1],r:b[2]/2,innerR:b[3]/2}):this.clipCircle=a.renderer.clipCircle(b[0],b[1],b[2]/2,b[3]/2);this.group.clip(this.clipCircle);this.setClip=h.noop}})))}},{order:2});e(m.line.prototype,"getGraphPath",function(a,b){var c=this,d;if(this.chart.polar){b=b||this.points;for(d=0;d<b.length;d++)if(!b[d].isNull){var e=d;break}if(!1!==this.options.connectEnds&&"undefined"!==typeof e){this.connectEnds=!0;b.splice(b.length,0,b[e]);var f=!0}b.forEach(function(a){"undefined"===
typeof a.polarPlotY&&c.toXY(a)})}d=a.apply(this,[].slice.call(arguments,1));f&&b.pop();return d});var y=function(a,b){var c=this,d=this.chart,e=this.options.animation,f=this.group,g=this.markerGroup,k=this.xAxis.center,l=d.plotLeft,m=d.plotTop,p,q,r,t;if(d.polar)if(c.isRadialBar)b||(c.startAngleRad=v(c.translatedThreshold,c.xAxis.startAngleRad),h.seriesTypes.pie.prototype.animate.call(c,b));else{if(d.renderer.isSVG)if(e=x(e),c.is("column")){if(!b){var y=k[3]/2;c.points.forEach(function(a){p=a.graphic;
r=(q=a.shapeArgs)&&q.r;t=q&&q.innerR;p&&q&&(p.attr({r:y,innerR:y}),p.animate({r:r,innerR:t},c.options.animation))})}}else b?(a={translateX:k[0]+l,translateY:k[1]+m,scaleX:.001,scaleY:.001},f.attr(a),g&&g.attr(a)):(a={translateX:l,translateY:m,scaleX:1,scaleY:1},f.animate(a,e),g&&g.animate(a,e))}else a.call(this,b)};e(D,"animate",y);if(m.column){var I=m.arearange.prototype;m=m.column.prototype;m.polarArc=function(a,b,c,d){var e=this.xAxis.center,f=this.yAxis.len,g=e[3]/2;b=f-b+g;a=f-v(a,f)+g;this.yAxis.reversed&&
(0>b&&(b=g),0>a&&(a=g));return{x:e[0],y:e[1],r:b,innerR:a,start:c,end:d}};e(m,"animate",y);e(m,"translate",function(a){var b=this.options,c=b.stacking,d=this.chart,e=this.xAxis,g=this.yAxis,h=g.reversed,k=g.center,l=e.startAngleRad,m=e.endAngleRad-l;this.preventPostTranslate=!0;a.call(this);if(e.isRadial){a=this.points;e=a.length;var t=g.translate(g.min);var v=g.translate(g.max);b=b.threshold||0;if(d.inverted&&p(b)){var x=g.translate(b);q(x)&&(0>x?x=0:x>m&&(x=m),this.translatedThreshold=x+l)}for(;e--;){b=
a[e];var y=b.barX;var z=b.x;var B=b.y;b.shapeType="arc";if(d.inverted){b.plotY=g.translate(B);if(c&&g.stacking){if(B=g.stacking.stacks[(0>B?"-":"")+this.stackKey],this.visible&&B&&B[z]&&!b.isNull){var D=B[z].points[this.getStackIndicator(void 0,z,this.index).key];var E=g.translate(D[0]);D=g.translate(D[1]);q(E)&&(E=r.clamp(E,0,m))}}else E=x,D=b.plotY;E>D&&(D=[E,E=D][0]);if(!h)if(E<t)E=t;else if(D>v)D=v;else{if(D<t||E>v)E=D=0}else if(D>t)D=t;else if(E<v)E=v;else if(E>t||D<v)E=D=m;g.min>g.max&&(E=D=
h?m:0);E+=l;D+=l;k&&(b.barX=y+=k[3]/2);z=Math.max(y,0);B=Math.max(y+b.pointWidth,0);b.shapeArgs={x:k&&k[0],y:k&&k[1],r:B,innerR:z,start:E,end:D};b.opacity=E===D?0:void 0;b.plotY=(q(this.translatedThreshold)&&(E<this.translatedThreshold?E:D))-l}else E=y+l,b.shapeArgs=this.polarArc(b.yBottom,b.plotY,E,E+b.pointWidth);this.toXY(b);d.inverted?(y=g.postTranslate(b.rectPlotY,y+b.pointWidth/2),b.tooltipPos=[y.x-d.plotLeft,y.y-d.plotTop]):b.tooltipPos=[b.plotX,b.plotY];k&&(b.ttBelow=b.plotY>k[1])}}});m.findAlignments=
function(a,b){null===b.align&&(b.align=20<a&&160>a?"left":200<a&&340>a?"right":"center");null===b.verticalAlign&&(b.verticalAlign=45>a||315<a?"bottom":135<a&&225>a?"top":"middle");return b};I&&(I.findAlignments=m.findAlignments);e(m,"alignDataLabel",function(a,b,c,d,e,h){var f=this.chart,g=v(d.inside,!!this.options.stacking);f.polar?(a=b.rectPlotX/Math.PI*180,f.inverted?(this.forceDL=f.isInsidePlot(b.plotX,Math.round(b.plotY)),g&&b.shapeArgs?(e=b.shapeArgs,e=this.yAxis.postTranslate(((e.start||0)+
(e.end||0))/2-this.xAxis.startAngleRad,b.barX+b.pointWidth/2),e={x:e.x-f.plotLeft,y:e.y-f.plotTop}):b.tooltipPos&&(e={x:b.tooltipPos[0],y:b.tooltipPos[1]}),d.align=v(d.align,"center"),d.verticalAlign=v(d.verticalAlign,"middle")):this.findAlignments&&(d=this.findAlignments(a,d)),D.alignDataLabel.call(this,b,c,d,e,h),this.isRadialBar&&b.shapeArgs&&b.shapeArgs.start===b.shapeArgs.end&&c.hide(!0)):a.call(this,b,c,d,e,h)})}e(a,"getCoordinates",function(a,b){var c=this.chart,d={xAxis:[],yAxis:[]};c.polar?
c.axes.forEach(function(a){var e=a.isXAxis,f=a.center;if("colorAxis"!==a.coll){var g=b.chartX-f[0]-c.plotLeft;f=b.chartY-f[1]-c.plotTop;d[e?"xAxis":"yAxis"].push({axis:a,value:a.translate(e?Math.PI-Math.atan2(g,f):Math.sqrt(Math.pow(g,2)+Math.pow(f,2)),!0)})}}):d=a.call(this,b);return d});l.prototype.clipCircle=function(a,b,c,d){var e=H(),f=this.createElement("clipPath").attr({id:e}).add(this.defs);a=d?this.arc(a,b,c,d,0,2*Math.PI).add(f):this.circle(a,b,c).add(f);a.id=e;a.clipPath=f;return a};b(d,
"getAxes",function(){this.pane||(this.pane=[]);this.options.pane=z(this.options.pane);this.options.pane.forEach(function(a){new c(a,this)},this)});b(d,"afterDrawChartBox",function(){this.pane.forEach(function(a){a.render()})});b(t,"afterInit",function(){var a=this.chart;a.inverted&&a.polar&&(this.isRadialSeries=!0,this.is("column")&&(this.isRadialBar=!0))});e(d.prototype,"get",function(a,b){return k(this.pane||[],function(a){return a.options.id===b})||a.call(this,b)})});z(e,"masters/highcharts-more.src.js",
[e["Core/Globals.js"],e["Core/Axis/RadialAxis.js"],e["Series/Bubble/BubbleSeries.js"]],function(e,d,h){d.compose(e.Axis,e.Tick);h.compose(e.Chart,e.Legend,e.Series)})});
//# sourceMappingURL=highcharts-more.js.map
/*
 Highcharts JS v9.2.2 (2021-08-24)

 Data module

 (c) 2012-2021 Torstein Honsi

 License: www.highcharts.com/license
*/
'use strict';(function(b){"object"===typeof module&&module.exports?(b["default"]=b,module.exports=b):"function"===typeof define&&define.amd?define("highcharts/modules/data",["highcharts"],function(p){b(p);b.Highcharts=p;return b}):b("undefined"!==typeof Highcharts?Highcharts:void 0)})(function(b){function p(b,e,v,p){b.hasOwnProperty(e)||(b[e]=p.apply(null,v))}b=b?b._modules:{};p(b,"Core/HttpUtilities.js",[b["Core/Globals.js"],b["Core/Utilities.js"]],function(b,e){var p=b.doc,u=e.createElement,D=e.discardElement,
q=e.merge,E=e.objectEach,y={ajax:function(b){var l=q(!0,{url:!1,type:"get",dataType:"json",success:!1,error:!1,data:!1,headers:{}},b);b={json:"application/json",xml:"application/xml",text:"text/plain",octet:"application/octet-stream"};var e=new XMLHttpRequest;if(!l.url)return!1;e.open(l.type.toUpperCase(),l.url,!0);l.headers["Content-Type"]||e.setRequestHeader("Content-Type",b[l.dataType]||b.text);E(l.headers,function(b,l){e.setRequestHeader(l,b)});e.onreadystatechange=function(){if(4===e.readyState){if(200===
e.status){var b=e.responseText;if("json"===l.dataType)try{b=JSON.parse(b)}catch(A){l.error&&l.error(e,A);return}return l.success&&l.success(b)}l.error&&l.error(e,e.responseText)}};try{l.data=JSON.stringify(l.data)}catch(F){}e.send(l.data||!0)},getJSON:function(b,e){y.ajax({url:b,success:e,dataType:"json",headers:{"Content-Type":"text/plain"}})},post:function(b,e,v){var l=u("form",q({method:"post",action:b,enctype:"multipart/form-data"},v),{display:"none"},p.body);E(e,function(b,e){u("input",{type:"hidden",
name:e,value:b},null,l)});l.submit();D(l)}};"";return y});p(b,"Extensions/Data.js",[b["Core/Chart/Chart.js"],b["Core/Globals.js"],b["Core/HttpUtilities.js"],b["Core/Series/Point.js"],b["Core/Series/SeriesRegistry.js"],b["Core/Utilities.js"]],function(b,e,p,I,D,q){var u=e.doc,y=p.ajax,v=D.seriesTypes;p=q.addEvent;var l=q.defined,J=q.extend,F=q.fireEvent,A=q.isNumber,B=q.merge,K=q.objectEach,G=q.pick,L=q.splat;q=function(){function b(a,c,h){this.options=this.rawColumns=this.firstRowAsNames=this.chartOptions=
this.chart=void 0;this.dateFormats={"YYYY/mm/dd":{regex:/^([0-9]{4})[\-\/\.]([0-9]{1,2})[\-\/\.]([0-9]{1,2})$/,parser:function(a){return a?Date.UTC(+a[1],a[2]-1,+a[3]):NaN}},"dd/mm/YYYY":{regex:/^([0-9]{1,2})[\-\/\.]([0-9]{1,2})[\-\/\.]([0-9]{4})$/,parser:function(a){return a?Date.UTC(+a[3],a[2]-1,+a[1]):NaN},alternative:"mm/dd/YYYY"},"mm/dd/YYYY":{regex:/^([0-9]{1,2})[\-\/\.]([0-9]{1,2})[\-\/\.]([0-9]{4})$/,parser:function(a){return a?Date.UTC(+a[3],a[1]-1,+a[2]):NaN}},"dd/mm/YY":{regex:/^([0-9]{1,2})[\-\/\.]([0-9]{1,2})[\-\/\.]([0-9]{2})$/,
parser:function(a){if(!a)return NaN;var c=+a[3];c=c>(new Date).getFullYear()-2E3?c+1900:c+2E3;return Date.UTC(c,a[2]-1,+a[1])},alternative:"mm/dd/YY"},"mm/dd/YY":{regex:/^([0-9]{1,2})[\-\/\.]([0-9]{1,2})[\-\/\.]([0-9]{2})$/,parser:function(a){return a?Date.UTC(+a[3]+2E3,a[1]-1,+a[2]):NaN}}};this.init(a,c,h)}b.prototype.init=function(a,c,h){var d=a.decimalPoint;c&&(this.chartOptions=c);h&&(this.chart=h);"."!==d&&","!==d&&(d=void 0);this.options=a;this.columns=a.columns||this.rowsToColumns(a.rows)||
[];this.firstRowAsNames=G(a.firstRowAsNames,this.firstRowAsNames,!0);this.decimalRegex=d&&new RegExp("^(-?[0-9]+)"+d+"([0-9]+)$");this.rawColumns=[];if(this.columns.length){this.dataFound();var g=!0}this.hasURLOption(a)&&(clearTimeout(this.liveDataTimeout),g=!1);g||(g=this.fetchLiveData());g||(g=!!this.parseCSV().length);g||(g=!!this.parseTable().length);g||(g=this.parseGoogleSpreadsheet());!g&&a.afterComplete&&a.afterComplete()};b.prototype.hasURLOption=function(a){return!(!a||!(a.rowsURL||a.csvURL||
a.columnsURL))};b.prototype.getColumnDistribution=function(){var a=this.chartOptions,c=this.options,h=[],d=function(a){return(v[a||"line"].prototype.pointArrayMap||[0]).length},g=a&&a.chart&&a.chart.type,t=[],b=[],k=0;c=c&&c.seriesMapping||a&&a.series&&a.series.map(function(){return{x:0}})||[];var f;(a&&a.series||[]).forEach(function(a){t.push(d(a.type||g))});c.forEach(function(a){h.push(a.x||0)});0===h.length&&h.push(0);c.forEach(function(c){var h=new H,e=t[k]||d(g),m=(a&&a.series||[])[k]||{},C=
v[m.type||g||"line"].prototype.pointArrayMap,p=C||["y"];(l(c.x)||m.isCartesian||!C)&&h.addColumnReader(c.x,"x");K(c,function(a,c){"x"!==c&&h.addColumnReader(a,c)});for(f=0;f<e;f++)h.hasReader(p[f])||h.addColumnReader(void 0,p[f]);b.push(h);k++});c=v[g||"line"].prototype.pointArrayMap;"undefined"===typeof c&&(c=["y"]);this.valueCount={global:d(g),xColumns:h,individual:t,seriesBuilders:b,globalPointArrayMap:c}};b.prototype.dataFound=function(){this.options.switchRowsAndColumns&&(this.columns=this.rowsToColumns(this.columns));
this.getColumnDistribution();this.parseTypes();!1!==this.parsed()&&this.complete()};b.prototype.parseCSV=function(a){function c(a,c,h,d){function b(c){k=a[c];t=a[c-1];n=a[c+1]}function g(a){l.length<w+1&&l.push([a]);l[w][l[w].length-1]!==a&&l[w].push(a)}function e(){f>r||r>C?(++r,m=""):(!isNaN(parseFloat(m))&&isFinite(m)?(m=parseFloat(m),g("number")):isNaN(Date.parse(m))?g("string"):(m=m.replace(/\//g,"-"),g("date")),p.length<w+1&&p.push([]),h||(p[w][c]=m),m="",++w,++r)}var x=0,k="",t="",n="",m="",
r=0,w=0;if(a.trim().length&&"#"!==a.trim()[0]){for(;x<a.length;x++)if(b(x),'"'===k)for(b(++x);x<a.length&&('"'!==k||'"'===t||'"'===n);){if('"'!==k||'"'===k&&'"'!==t)m+=k;b(++x)}else d&&d[k]?d[k](k,m)&&e():k===q?e():m+=k;e()}}function h(a){var c=0,h=0,d=!1;a.some(function(a,d){var b=!1,g="";if(13<d)return!0;for(var k=0;k<a.length;k++){d=a[k];var e=a[k+1];var t=a[k-1];if("#"===d)break;if('"'===d)if(b){if('"'!==t&&'"'!==e){for(;" "===e&&k<a.length;)e=a[++k];"undefined"!==typeof r[e]&&r[e]++;b=!1}}else b=
!0;else"undefined"!==typeof r[d]?(g=g.trim(),isNaN(Date.parse(g))?!isNaN(g)&&isFinite(g)||r[d]++:r[d]++,g=""):g+=d;","===d&&h++;"."===d&&c++}});d=r[";"]>r[","]?";":",";b.decimalPoint||(b.decimalPoint=c>h?".":",",g.decimalRegex=new RegExp("^(-?[0-9]+)"+b.decimalPoint+"([0-9]+)$"));return d}function d(a,c){var d=[],h=0,k=!1,e=[],t=[],f;if(!c||c>a.length)c=a.length;for(;h<c;h++)if("undefined"!==typeof a[h]&&a[h]&&a[h].length){var n=a[h].trim().replace(/\//g," ").replace(/\-/g," ").replace(/\./g," ").split(" ");
d=["","",""];for(f=0;f<n.length;f++)f<d.length&&(n[f]=parseInt(n[f],10),n[f]&&(t[f]=!t[f]||t[f]<n[f]?n[f]:t[f],"undefined"!==typeof e[f]?e[f]!==n[f]&&(e[f]=!1):e[f]=n[f],31<n[f]?d[f]=100>n[f]?"YY":"YYYY":12<n[f]&&31>=n[f]?(d[f]="dd",k=!0):d[f].length||(d[f]="mm")))}if(k){for(f=0;f<e.length;f++)!1!==e[f]?12<t[f]&&"YY"!==d[f]&&"YYYY"!==d[f]&&(d[f]="YY"):12<t[f]&&"mm"===d[f]&&(d[f]="dd");3===d.length&&"dd"===d[1]&&"dd"===d[2]&&(d[2]="YY");a=d.join("/");return(b.dateFormats||g.dateFormats)[a]?a:(F("deduceDateFailed"),
"YYYY/mm/dd")}return"YYYY/mm/dd"}var g=this,b=a||this.options,e=b.csv;a="undefined"!==typeof b.startRow&&b.startRow?b.startRow:0;var k=b.endRow||Number.MAX_VALUE,f="undefined"!==typeof b.startColumn&&b.startColumn?b.startColumn:0,C=b.endColumn||Number.MAX_VALUE,n=0,l=[],r={",":0,";":0,"\t":0};var p=this.columns=[];e&&b.beforeParse&&(e=b.beforeParse.call(this,e));if(e){e=e.replace(/\r\n/g,"\n").replace(/\r/g,"\n").split(b.lineDelimiter||"\n");if(!a||0>a)a=0;if(!k||k>=e.length)k=e.length-1;if(b.itemDelimiter)var q=
b.itemDelimiter;else q=null,q=h(e);var z=0;for(n=a;n<=k;n++)"#"===e[n][0]?z++:c(e[n],n-a-z);b.columnTypes&&0!==b.columnTypes.length||!l.length||!l[0].length||"date"!==l[0][1]||b.dateFormat||(b.dateFormat=d(p[0]));this.dataFound()}return p};b.prototype.parseTable=function(){var a=this.options,c=a.table,h=this.columns||[],d=a.startRow||0,b=a.endRow||Number.MAX_VALUE,e=a.startColumn||0,m=a.endColumn||Number.MAX_VALUE;c&&("string"===typeof c&&(c=u.getElementById(c)),[].forEach.call(c.getElementsByTagName("tr"),
function(a,c){c>=d&&c<=b&&[].forEach.call(a.children,function(a,b){var g=h[b-e],f=1;if(("TD"===a.tagName||"TH"===a.tagName)&&b>=e&&b<=m)for(h[b-e]||(h[b-e]=[]),h[b-e][c-d]=a.innerHTML;c-d>=f&&void 0===g[c-d-f];)g[c-d-f]=null,f++})}),this.dataFound());return h};b.prototype.fetchLiveData=function(){function a(g){function f(f,k,t){function n(){e&&h.liveDataURL===f&&(c.liveDataTimeout=setTimeout(a,m))}if(!f||!/^(http|\/|\.\/|\.\.\/)/.test(f))return f&&d.error&&d.error("Invalid URL"),!1;g&&(clearTimeout(c.liveDataTimeout),
h.liveDataURL=f);y({url:f,dataType:t||"json",success:function(a){h&&h.series&&k(a);n()},error:function(a,c){3>++b&&n();return d.error&&d.error(c,a)}});return!0}f(k.csvURL,function(a){h.update({data:{csv:a}})},"text")||f(k.rowsURL,function(a){h.update({data:{rows:a}})})||f(k.columnsURL,function(a){h.update({data:{columns:a}})})}var c=this,h=this.chart,d=this.options,b=0,e=d.enablePolling,m=1E3*(d.dataRefreshRate||2),k=B(d);if(!this.hasURLOption(d))return!1;1E3>m&&(m=1E3);delete d.csvURL;delete d.rowsURL;
delete d.columnsURL;a(!0);return this.hasURLOption(d)};b.prototype.parseGoogleSpreadsheet=function(){function a(c){var b=["https://sheets.googleapis.com/v4/spreadsheets",d,"values",m(),"?alt=json&majorDimension=COLUMNS&valueRenderOption=UNFORMATTED_VALUE&dateTimeRenderOption=FORMATTED_STRING&key="+h.googleAPIKey].join("/");y({url:b,dataType:"json",success:function(d){c(d);h.enablePolling&&setTimeout(function(){a(c)},e)},error:function(a,c){return h.error&&h.error(c,a)}})}var c=this,h=this.options,
d=h.googleSpreadsheetKey,b=this.chart,e=Math.max(1E3*(h.dataRefreshRate||2),4E3),m=function(){if(h.googleSpreadsheetRange)return h.googleSpreadsheetRange;var a=("ABCDEFGHIJKLMNOPQRSTUVWXYZ".charAt(h.startColumn||0)||"A")+((h.startRow||0)+1),c="ABCDEFGHIJKLMNOPQRSTUVWXYZ".charAt(G(h.endColumn,-1))||"ZZ";l(h.endRow)&&(c+=h.endRow+1);return a+":"+c};d&&(delete h.googleSpreadsheetKey,a(function(a){a=a.values;if(!a||0===a.length)return!1;var d=a.reduce(function(a,c){return Math.max(a,c.length)},0);a.forEach(function(a){for(var c=
0;c<d;c++)"undefined"===typeof a[c]&&(a[c]=null)});b&&b.series?b.update({data:{columns:a}}):(c.columns=a,c.dataFound())}));return!1};b.prototype.trim=function(a,c){"string"===typeof a&&(a=a.replace(/^\s+|\s+$/g,""),c&&/^[0-9\s]+$/.test(a)&&(a=a.replace(/\s/g,"")),this.decimalRegex&&(a=a.replace(this.decimalRegex,"$1.$2")));return a};b.prototype.parseTypes=function(){for(var a=this.columns,c=a.length;c--;)this.parseColumn(a[c],c)};b.prototype.parseColumn=function(a,c){var b=this.rawColumns,d=this.columns,
g=a.length,e=this.firstRowAsNames,m=-1!==this.valueCount.xColumns.indexOf(c),k,f=[],l=this.chartOptions,n,p=(this.options.columnTypes||[])[c];l=m&&(l&&l.xAxis&&"category"===L(l.xAxis)[0].type||"string"===p);for(b[c]||(b[c]=[]);g--;){var r=f[g]||a[g];var q=this.trim(r);var z=this.trim(r,!0);var u=parseFloat(z);"undefined"===typeof b[c][g]&&(b[c][g]=q);l||0===g&&e?a[g]=""+q:+z===u?(a[g]=u,31536E6<u&&"float"!==p?a.isDatetime=!0:a.isNumeric=!0,"undefined"!==typeof a[g+1]&&(n=u>a[g+1])):(q&&q.length&&
(k=this.parseDate(r)),m&&A(k)&&"float"!==p?(f[g]=r,a[g]=k,a.isDatetime=!0,"undefined"!==typeof a[g+1]&&(r=k>a[g+1],r!==n&&"undefined"!==typeof n&&(this.alternativeFormat?(this.dateFormat=this.alternativeFormat,g=a.length,this.alternativeFormat=this.dateFormats[this.dateFormat].alternative):a.unsorted=!0),n=r)):(a[g]=""===q?null:q,0!==g&&(a.isDatetime||a.isNumeric)&&(a.mixed=!0)))}m&&a.mixed&&(d[c]=b[c]);if(m&&n&&this.options.sort)for(c=0;c<d.length;c++)d[c].reverse(),e&&d[c].unshift(d[c].pop())};
b.prototype.parseDate=function(a){var c=this.options.parseDate,b,d=this.options.dateFormat||this.dateFormat,g;if(c)var e=c(a);else if("string"===typeof a){if(d)(c=this.dateFormats[d])||(c=this.dateFormats["YYYY/mm/dd"]),(g=a.match(c.regex))&&(e=c.parser(g));else for(b in this.dateFormats)if(c=this.dateFormats[b],g=a.match(c.regex)){this.dateFormat=b;this.alternativeFormat=c.alternative;e=c.parser(g);break}g||(a.match(/:.+(GMT|UTC|[Z+-])/)&&(a=a.replace(/\s*(?:GMT|UTC)?([+-])(\d\d)(\d\d)$/,"$1$2:$3").replace(/(?:\s+|GMT|UTC)([+-])/,
"$1").replace(/(\d)\s*(?:GMT|UTC|Z)$/,"$1+00:00")),g=Date.parse(a),"object"===typeof g&&null!==g&&g.getTime?e=g.getTime()-6E4*g.getTimezoneOffset():A(g)&&(e=g-6E4*(new Date(g)).getTimezoneOffset()))}return e};b.prototype.rowsToColumns=function(a){var c,b;if(a){var d=[];var g=a.length;for(c=0;c<g;c++){var e=a[c].length;for(b=0;b<e;b++)d[b]||(d[b]=[]),d[b][c]=a[c][b]}}return d};b.prototype.getData=function(){if(this.columns)return this.rowsToColumns(this.columns).slice(1)};b.prototype.parsed=function(){if(this.options.parsed)return this.options.parsed.call(this,
this.columns)};b.prototype.getFreeIndexes=function(a,c){var b,d=[],g=[];for(b=0;b<a;b+=1)d.push(!0);for(a=0;a<c.length;a+=1){var e=c[a].getReferencedColumnIndexes();for(b=0;b<e.length;b+=1)d[e[b]]=!1}for(b=0;b<d.length;b+=1)d[b]&&g.push(b);return g};b.prototype.complete=function(){var a=this.columns,c,b=this.options,d,e,l=[];if(b.complete||b.afterComplete){if(this.firstRowAsNames)for(d=0;d<a.length;d++)a[d].name=a[d].shift();var m=[];var k=this.getFreeIndexes(a.length,this.valueCount.seriesBuilders);
for(d=0;d<this.valueCount.seriesBuilders.length;d++){var f=this.valueCount.seriesBuilders[d];f.populateColumns(k)&&l.push(f)}for(;0<k.length;){f=new H;f.addColumnReader(0,"x");d=k.indexOf(0);-1!==d&&k.splice(d,1);for(d=0;d<this.valueCount.global;d++)f.addColumnReader(void 0,this.valueCount.globalPointArrayMap[d]);f.populateColumns(k)&&l.push(f)}0<l.length&&0<l[0].readers.length&&(f=a[l[0].readers[0].columnIndex],"undefined"!==typeof f&&(f.isDatetime?c="datetime":f.isNumeric||(c="category")));if("category"===
c)for(d=0;d<l.length;d++)for(f=l[d],k=0;k<f.readers.length;k++)"x"===f.readers[k].configName&&(f.readers[k].configName="name");for(d=0;d<l.length;d++){f=l[d];k=[];for(e=0;e<a[0].length;e++)k[e]=f.read(a,e);m[d]={data:k};f.name&&(m[d].name=f.name);"category"===c&&(m[d].turboThreshold=0)}a={series:m};c&&(a.xAxis={type:c},"category"===c&&(a.xAxis.uniqueNames=!1));b.complete&&b.complete(a);b.afterComplete&&b.afterComplete(a)}};b.prototype.update=function(a,c){var b=this.chart;a&&(a.afterComplete=function(a){a&&
(a.xAxis&&b.xAxis[0]&&a.xAxis.type===b.xAxis[0].options.type&&delete a.xAxis,b.update(a,c,!0))},B(!0,b.options.data,a),this.init(b.options.data))};return b}();e.data=function(b,a,c){return new e.Data(b,a,c)};p(b,"init",function(b){var a=this,c=b.args[0]||{},h=b.args[1];c&&c.data&&!a.hasDataDef&&(a.hasDataDef=!0,a.data=new e.Data(J(c.data,{afterComplete:function(b){var d;if(Object.hasOwnProperty.call(c,"series"))if("object"===typeof c.series)for(d=Math.max(c.series.length,b&&b.series?b.series.length:
0);d--;){var e=c.series[d]||{};c.series[d]=B(e,b&&b.series?b.series[d]:{})}else delete c.series;c=B(b,c);a.init(c,h)}}),c,a),b.preventDefault())});var H=function(){function b(){this.readers=[];this.pointIsArray=!0;this.name=void 0}b.prototype.populateColumns=function(a){var b=!0;this.readers.forEach(function(b){"undefined"===typeof b.columnIndex&&(b.columnIndex=a.shift())});this.readers.forEach(function(a){"undefined"===typeof a.columnIndex&&(b=!1)});return b};b.prototype.read=function(a,b){var c=
this.pointIsArray,d=c?[]:{};this.readers.forEach(function(e){var g=a[e.columnIndex][b];c?d.push(g):0<e.configName.indexOf(".")?I.prototype.setNestedProperty(d,g,e.configName):d[e.configName]=g});if("undefined"===typeof this.name&&2<=this.readers.length){var e=this.getReferencedColumnIndexes();2<=e.length&&(e.shift(),e.sort(function(a,b){return a-b}),this.name=a[e.shift()].name)}return d};b.prototype.addColumnReader=function(a,b){this.readers.push({columnIndex:a,configName:b});"x"!==b&&"y"!==b&&"undefined"!==
typeof b&&(this.pointIsArray=!1)};b.prototype.getReferencedColumnIndexes=function(){var a,b=[];for(a=0;a<this.readers.length;a+=1){var e=this.readers[a];"undefined"!==typeof e.columnIndex&&b.push(e.columnIndex)}return b};b.prototype.hasReader=function(a){var b;for(b=0;b<this.readers.length;b+=1){var e=this.readers[b];if(e.configName===a)return!0}};return b}();e.Data=q;return e.Data});p(b,"masters/modules/data.src.js",[b["Core/Globals.js"],b["Core/HttpUtilities.js"]],function(b,e){b.HttpUtilities=
e;b.ajax=e.ajax;b.getJSON=e.getJSON;b.post=e.post})});
//# sourceMappingURL=data.js.map
/*
 Highcharts JS v9.3.1 (2021-11-05)

 Exporting module

 (c) 2010-2021 Torstein Honsi

 License: www.highcharts.com/license
*/
'use strict';(function(a){"object"===typeof module&&module.exports?(a["default"]=a,module.exports=a):"function"===typeof define&&define.amd?define("highcharts/modules/exporting",["highcharts"],function(g){a(g);a.Highcharts=g;return a}):a("undefined"!==typeof Highcharts?Highcharts:void 0)})(function(a){function g(a,e,r,t){a.hasOwnProperty(e)||(a[e]=t.apply(null,r))}a=a?a._modules:{};g(a,"Extensions/FullScreen.js",[a["Core/Chart/Chart.js"],a["Core/Globals.js"],a["Core/Renderer/HTML/AST.js"],a["Core/Utilities.js"]],
function(a,e,r,t){var l=t.addEvent;t=function(){function a(d){this.chart=d;this.isOpen=!1;d=d.renderTo;this.browserProps||("function"===typeof d.requestFullscreen?this.browserProps={fullscreenChange:"fullscreenchange",requestFullscreen:"requestFullscreen",exitFullscreen:"exitFullscreen"}:d.mozRequestFullScreen?this.browserProps={fullscreenChange:"mozfullscreenchange",requestFullscreen:"mozRequestFullScreen",exitFullscreen:"mozCancelFullScreen"}:d.webkitRequestFullScreen?this.browserProps={fullscreenChange:"webkitfullscreenchange",
requestFullscreen:"webkitRequestFullScreen",exitFullscreen:"webkitExitFullscreen"}:d.msRequestFullscreen&&(this.browserProps={fullscreenChange:"MSFullscreenChange",requestFullscreen:"msRequestFullscreen",exitFullscreen:"msExitFullscreen"}))}a.prototype.close=function(){var d=this.chart,a=d.options.chart;if(this.isOpen&&this.browserProps&&d.container.ownerDocument instanceof Document)d.container.ownerDocument[this.browserProps.exitFullscreen]();this.unbindFullscreenEvent&&(this.unbindFullscreenEvent=
this.unbindFullscreenEvent());d.setSize(this.origWidth,this.origHeight,!1);this.origHeight=this.origWidth=void 0;a.width=this.origWidthOption;a.height=this.origHeightOption;this.origHeightOption=this.origWidthOption=void 0;this.isOpen=!1;this.setButtonText()};a.prototype.open=function(){var d=this,a=d.chart,b=a.options.chart;b&&(d.origWidthOption=b.width,d.origHeightOption=b.height);d.origWidth=a.chartWidth;d.origHeight=a.chartHeight;if(d.browserProps){var k=l(a.container.ownerDocument,d.browserProps.fullscreenChange,
function(){d.isOpen?(d.isOpen=!1,d.close()):(a.setSize(null,null,!1),d.isOpen=!0,d.setButtonText())}),e=l(a,"destroy",k);d.unbindFullscreenEvent=function(){k();e()};if(b=a.renderTo[d.browserProps.requestFullscreen]())b["catch"](function(){alert("Full screen is not supported inside a frame.")})}};a.prototype.setButtonText=function(){var d=this.chart,a=d.exportDivElements,b=d.options.exporting,k=b&&b.buttons&&b.buttons.contextButton.menuItems;d=d.options.lang;b&&b.menuItemDefinitions&&d&&d.exitFullscreen&&
d.viewFullscreen&&k&&a&&(a=a[k.indexOf("viewFullscreen")])&&r.setElementHTML(a,this.isOpen?d.exitFullscreen:b.menuItemDefinitions.viewFullscreen.text||d.viewFullscreen)};a.prototype.toggle=function(){this.isOpen?this.close():this.open()};return a}();e.Fullscreen=t;l(a,"beforeRender",function(){this.fullscreen=new e.Fullscreen(this)});return e.Fullscreen});g(a,"Core/Chart/ChartNavigationComposition.js",[],function(){var a;(function(a){a.compose=function(a){a.navigation||(a.navigation=new e(a));return a};
var e=function(){function a(a){this.updates=[];this.chart=a}a.prototype.addUpdate=function(a){this.chart.navigation.updates.push(a)};a.prototype.update=function(a,k){var d=this;this.updates.forEach(function(e){e.call(d.chart,a,k)})};return a}();a.Additions=e})(a||(a={}));return a});g(a,"Extensions/Exporting/ExportingDefaults.js",[a["Core/Globals.js"]],function(a){return{exporting:{type:"image/png",url:"https://export.highcharts.com/",printMaxWidth:780,scale:2,buttons:{contextButton:{className:"highcharts-contextbutton",
menuClassName:"highcharts-contextmenu",symbol:"menu",titleKey:"contextButtonTitle",menuItems:"viewFullscreen printChart separator downloadPNG downloadJPEG downloadPDF downloadSVG".split(" ")}},menuItemDefinitions:{viewFullscreen:{textKey:"viewFullscreen",onclick:function(){this.fullscreen.toggle()}},printChart:{textKey:"printChart",onclick:function(){this.print()}},separator:{separator:!0},downloadPNG:{textKey:"downloadPNG",onclick:function(){this.exportChart()}},downloadJPEG:{textKey:"downloadJPEG",
onclick:function(){this.exportChart({type:"image/jpeg"})}},downloadPDF:{textKey:"downloadPDF",onclick:function(){this.exportChart({type:"application/pdf"})}},downloadSVG:{textKey:"downloadSVG",onclick:function(){this.exportChart({type:"image/svg+xml"})}}}},lang:{viewFullscreen:"View in full screen",exitFullscreen:"Exit from full screen",printChart:"Print chart",downloadPNG:"Download PNG image",downloadJPEG:"Download JPEG image",downloadPDF:"Download PDF document",downloadSVG:"Download SVG vector image",
contextButtonTitle:"Chart context menu"},navigation:{buttonOptions:{symbolSize:14,symbolX:12.5,symbolY:10.5,align:"right",buttonSpacing:3,height:22,verticalAlign:"top",width:24,symbolFill:"#666666",symbolStroke:"#666666",symbolStrokeWidth:3,theme:{padding:5}},menuStyle:{border:"1px solid #999999",background:"#ffffff",padding:"5px 0"},menuItemStyle:{padding:"0.5em 1em",color:"#333333",background:"none",fontSize:a.isTouchDevice?"14px":"11px",transition:"background 250ms, color 250ms"},menuItemHoverStyle:{background:"#335cad",
color:"#ffffff"}}}});g(a,"Extensions/Exporting/ExportingSymbols.js",[],function(){var a;(function(a){function e(a,d,e,b){return[["M",a,d+2.5],["L",a+e,d+2.5],["M",a,d+b/2+.5],["L",a+e,d+b/2+.5],["M",a,d+b-1.5],["L",a+e,d+b-1.5]]}function l(a,d,e,b){a=b/3-2;b=[];return b=b.concat(this.circle(e-a,d,a,a),this.circle(e-a,d+a+4,a,a),this.circle(e-a,d+2*(a+4),a,a))}var g=[];a.compose=function(a){-1===g.indexOf(a)&&(g.push(a),a=a.prototype.symbols,a.menu=e,a.menuball=l.bind(a))}})(a||(a={}));return a});
g(a,"Core/HttpUtilities.js",[a["Core/Globals.js"],a["Core/Utilities.js"]],function(a,e){var l=a.doc,g=e.createElement,z=e.discardElement,k=e.merge,d=e.objectEach,J={ajax:function(a){var b=k(!0,{url:!1,type:"get",dataType:"json",success:!1,error:!1,data:!1,headers:{}},a);a={json:"application/json",xml:"application/xml",text:"text/plain",octet:"application/octet-stream"};var e=new XMLHttpRequest;if(!b.url)return!1;e.open(b.type.toUpperCase(),b.url,!0);b.headers["Content-Type"]||e.setRequestHeader("Content-Type",
a[b.dataType]||a.text);d(b.headers,function(a,d){e.setRequestHeader(d,a)});e.onreadystatechange=function(){if(4===e.readyState){if(200===e.status){var a=e.responseText;if("json"===b.dataType)try{a=JSON.parse(a)}catch(q){b.error&&b.error(e,q);return}return b.success&&b.success(a)}b.error&&b.error(e,e.responseText)}};try{b.data=JSON.stringify(b.data)}catch(x){}e.send(b.data||!0)},getJSON:function(a,d){J.ajax({url:a,success:d,dataType:"json",headers:{"Content-Type":"text/plain"}})},post:function(a,e,
r){var b=g("form",k({method:"post",action:a,enctype:"multipart/form-data"},r),{display:"none"},l.body);d(e,function(a,d){g("input",{type:"hidden",name:d,value:a},null,b)});b.submit();z(b)}};"";return J});g(a,"Extensions/Exporting/Exporting.js",[a["Core/Renderer/HTML/AST.js"],a["Core/Chart/Chart.js"],a["Core/Chart/ChartNavigationComposition.js"],a["Core/DefaultOptions.js"],a["Extensions/Exporting/ExportingDefaults.js"],a["Extensions/Exporting/ExportingSymbols.js"],a["Core/Globals.js"],a["Core/HttpUtilities.js"],
a["Core/Utilities.js"]],function(a,e,g,t,z,k,d,J,b){e=t.defaultOptions;var l=d.doc,r=d.win,x=b.addEvent,q=b.css,E=b.createElement,K=b.discardElement,F=b.extend,P=b.find,G=b.fireEvent,Q=b.isObject,m=b.merge,L=b.objectEach,w=b.pick,R=b.removeEvent,S=b.uniqueKey,H;(function(e){function t(a){var c=this,d=c.renderer,b=m(c.options.navigation.buttonOptions,a),e=b.onclick,B=b.menuItems,n=b.symbolSize||12;c.btnCount||(c.btnCount=0);c.exportDivElements||(c.exportDivElements=[],c.exportSVGElements=[]);if(!1!==
b.enabled&&b.theme){var f=b.theme,C=f.states,l=C&&C.hover;C=C&&C.select;var D;c.styledMode||(f.fill=w(f.fill,"#ffffff"),f.stroke=w(f.stroke,"none"));delete f.states;e?D=function(a){a&&a.stopPropagation();e.call(c,a)}:B&&(D=function(a){a&&a.stopPropagation();c.contextMenu(p.menuClassName,B,p.translateX,p.translateY,p.width,p.height,p);p.setState(2)});b.text&&b.symbol?f.paddingLeft=w(f.paddingLeft,30):b.text||F(f,{width:b.width,height:b.height,padding:0});c.styledMode||(f["stroke-linecap"]="round",
f.fill=w(f.fill,"#ffffff"),f.stroke=w(f.stroke,"none"));var p=d.button(b.text,0,0,D,f,l,C).addClass(a.className).attr({title:w(c.options.lang[b._titleKey||b.titleKey],"")});p.menuClassName=a.menuClassName||"highcharts-menu-"+c.btnCount++;if(b.symbol){var g=d.symbol(b.symbol,b.symbolX-n/2,b.symbolY-n/2,n,n,{width:n,height:n}).addClass("highcharts-button-symbol").attr({zIndex:1}).add(p);c.styledMode||g.attr({stroke:b.symbolStroke,fill:b.symbolFill,"stroke-width":b.symbolStrokeWidth||1})}p.add(c.exportingGroup).align(F(b,
{width:p.width,x:w(b.x,c.buttonOffset)}),!0,"spacingBox");c.buttonOffset+=(p.width+b.buttonSpacing)*("right"===b.align?-1:1);c.exportSVGElements.push(p,g)}}function z(){if(this.printReverseInfo){var a=this.printReverseInfo,b=a.childNodes,d=a.origDisplay;a=a.resetParams;this.moveContainers(this.renderTo);[].forEach.call(b,function(a,c){1===a.nodeType&&(a.style.display=d[c]||"")});this.isPrinting=!1;a&&this.setSize.apply(this,a);delete this.printReverseInfo;I=void 0;G(this,"afterPrint")}}function H(){var a=
l.body,b=this.options.exporting.printMaxWidth,d={childNodes:a.childNodes,origDisplay:[],resetParams:void 0};this.isPrinting=!0;this.pointer.reset(null,0);G(this,"beforePrint");b&&this.chartWidth>b&&(d.resetParams=[this.options.chart.width,void 0,!1],this.setSize(b,void 0,!1));[].forEach.call(d.childNodes,function(a,c){1===a.nodeType&&(d.origDisplay[c]=a.style.display,a.style.display="none")});this.moveContainers(a);this.printReverseInfo=d}function T(a){a.renderExporting();x(a,"redraw",a.renderExporting);
x(a,"destroy",a.destroyExport)}function U(c,d,e,y,g,B,n){var f=this,u=f.options.navigation,A=f.chartWidth,D=f.chartHeight,p="cache-"+c,v=Math.max(g,B),h=f[p];if(!h){f.exportContextMenu=f[p]=h=E("div",{className:c},{position:"absolute",zIndex:1E3,padding:v+"px",pointerEvents:"auto"},f.fixedDiv||f.container);var m=E("ul",{className:"highcharts-menu"},{listStyle:"none",margin:0,padding:0},h);f.styledMode||q(m,F({MozBoxShadow:"3px 3px 10px #888",WebkitBoxShadow:"3px 3px 10px #888",boxShadow:"3px 3px 10px #888"},
u.menuStyle));h.hideMenu=function(){q(h,{display:"none"});n&&n.setState(0);f.openMenu=!1;q(f.renderTo,{overflow:"hidden"});q(f.container,{overflow:"hidden"});b.clearTimeout(h.hideTimer);G(f,"exportMenuHidden")};f.exportEvents.push(x(h,"mouseleave",function(){h.hideTimer=r.setTimeout(h.hideMenu,500)}),x(h,"mouseenter",function(){b.clearTimeout(h.hideTimer)}),x(l,"mouseup",function(a){f.pointer.inClass(a.target,c)||h.hideMenu()}),x(h,"click",function(){f.openMenu&&h.hideMenu()}));d.forEach(function(c){"string"===
typeof c&&(c=f.options.exporting.menuItemDefinitions[c]);if(Q(c,!0)){var b=void 0;c.separator?b=E("hr",void 0,void 0,m):("viewData"===c.textKey&&f.isDataTableVisible&&(c.textKey="hideData"),b=E("li",{className:"highcharts-menu-item",onclick:function(a){a&&a.stopPropagation();h.hideMenu();c.onclick&&c.onclick.apply(f,arguments)}},void 0,m),a.setElementHTML(b,c.text||f.options.lang[c.textKey]),f.styledMode||(b.onmouseover=function(){q(this,u.menuItemHoverStyle)},b.onmouseout=function(){q(this,u.menuItemStyle)},
q(b,F({cursor:"pointer"},u.menuItemStyle))));f.exportDivElements.push(b)}});f.exportDivElements.push(m,h);f.exportMenuWidth=h.offsetWidth;f.exportMenuHeight=h.offsetHeight}d={display:"block"};e+f.exportMenuWidth>A?d.right=A-e-g-v+"px":d.left=e-v+"px";y+B+f.exportMenuHeight>D&&"top"!==n.alignOptions.verticalAlign?d.bottom=D-y-v+"px":d.top=y+B-v+"px";q(h,d);q(f.renderTo,{overflow:""});q(f.container,{overflow:""});f.openMenu=!0;G(f,"exportMenuShown")}function V(a){var c=a?a.target:this,d=c.exportSVGElements,
e=c.exportDivElements;a=c.exportEvents;var g;d&&(d.forEach(function(a,b){a&&(a.onclick=a.ontouchstart=null,g="cache-"+a.menuClassName,c[g]&&delete c[g],d[b]=a.destroy())}),d.length=0);c.exportingGroup&&(c.exportingGroup.destroy(),delete c.exportingGroup);e&&(e.forEach(function(a,c){a&&(b.clearTimeout(a.hideTimer),R(a,"mouseleave"),e[c]=a.onmouseout=a.onmouseover=a.ontouchstart=a.onclick=null,K(a))}),e.length=0);a&&(a.forEach(function(a){a()}),a.length=0)}function W(a,b){b=this.getSVGForExport(a,b);
a=m(this.options.exporting,a);J.post(a.url,{filename:a.filename?a.filename.replace(/\//g,"-"):this.getFilename(),type:a.type,width:a.width||0,scale:a.scale,svg:b},a.formAttributes)}function X(){this.styledMode&&this.inlineStyles();return this.container.innerHTML}function Y(){var a=this.userOptions.title&&this.userOptions.title.text,b=this.options.exporting.filename;if(b)return b.replace(/\//g,"-");"string"===typeof a&&(b=a.toLowerCase().replace(/<\/?[^>]+(>|$)/g,"").replace(/[\s_]+/g,"-").replace(/[^a-z0-9\-]/g,
"").replace(/^[\-]+/g,"").replace(/[\-]+/g,"-").substr(0,24).replace(/[\-]+$/g,""));if(!b||5>b.length)b="chart";return b}function Z(a){var b,c=m(this.options,a);c.plotOptions=m(this.userOptions.plotOptions,a&&a.plotOptions);c.time=m(this.userOptions.time,a&&a.time);var d=E("div",null,{position:"absolute",top:"-9999em",width:this.chartWidth+"px",height:this.chartHeight+"px"},l.body),e=this.renderTo.style.width;var g=this.renderTo.style.height;e=c.exporting.sourceWidth||c.chart.width||/px$/.test(e)&&
parseInt(e,10)||(c.isGantt?800:600);g=c.exporting.sourceHeight||c.chart.height||/px$/.test(g)&&parseInt(g,10)||400;F(c.chart,{animation:!1,renderTo:d,forExport:!0,renderer:"SVGRenderer",width:e,height:g});c.exporting.enabled=!1;delete c.data;c.series=[];this.series.forEach(function(a){b=m(a.userOptions,{animation:!1,enableMouseTracking:!1,showCheckbox:!1,visible:a.visible});b.isInternal||c.series.push(b)});var n={};this.axes.forEach(function(a){a.userOptions.internalKey||(a.userOptions.internalKey=
S());a.options.isInternal||(n[a.coll]||(n[a.coll]=!0,c[a.coll]=[]),c[a.coll].push(m(a.userOptions,{visible:a.visible})))});var f=new this.constructor(c,this.callback);a&&["xAxis","yAxis","series"].forEach(function(c){var b={};a[c]&&(b[c]=a[c],f.update(b))});this.axes.forEach(function(a){var c=P(f.axes,function(c){return c.options.internalKey===a.userOptions.internalKey}),b=a.getExtremes(),d=b.userMin;b=b.userMax;c&&("undefined"!==typeof d&&d!==c.min||"undefined"!==typeof b&&b!==c.max)&&c.setExtremes(d,
b,!0,!1)});g=f.getChartHTML();G(this,"getSVG",{chartCopy:f});g=this.sanitizeSVG(g,c);c=null;f.destroy();K(d);return g}function aa(a,b){var c=this.options.exporting;return this.getSVG(m({chart:{borderRadius:0}},c.chartOptions,b,{exporting:{sourceWidth:a&&a.sourceWidth||c.sourceWidth,sourceHeight:a&&a.sourceHeight||c.sourceHeight}}))}function M(a){return a.replace(/([A-Z])/g,function(a,c){return"-"+c.toLowerCase()})}function ba(){function a(c){function e(a,d){u=l=!1;if(g.length){for(k=g.length;k--&&
!l;)l=g[k].test(d);u=!l}"transform"===d&&"none"===a&&(u=!0);for(k=b.length;k--&&!u;)u=b[k].test(d)||"function"===typeof a;u||q[d]===a&&"svg"!==c.nodeName||y[c.nodeName][d]===a||(N&&-1===N.indexOf(d)?f+=M(d)+":"+a+";":a&&c.setAttribute(M(d),a))}var f="",u,l,k;if(1===c.nodeType&&-1===ca.indexOf(c.nodeName)){var h=r.getComputedStyle(c,null);var q="svg"===c.nodeName?{}:r.getComputedStyle(c.parentNode,null);if(!y[c.nodeName]){v=n.getElementsByTagName("svg")[0];var A=n.createElementNS(c.namespaceURI,c.nodeName);
v.appendChild(A);y[c.nodeName]=m(r.getComputedStyle(A,null));"text"===c.nodeName&&delete y.text.fill;v.removeChild(A)}if(d.isFirefox||d.isMS)for(var t in h)e(h[t],t);else L(h,e);f&&(h=c.getAttribute("style"),c.setAttribute("style",(h?h+";":"")+f));"svg"===c.nodeName&&c.setAttribute("stroke-width","1px");"text"!==c.nodeName&&[].forEach.call(c.children||c.childNodes,a)}}var b=da,g=e.inlineWhitelist,y={},v,k=l.createElement("iframe");q(k,{width:"1px",height:"1px",visibility:"hidden"});l.body.appendChild(k);
var n=k.contentWindow.document;n.open();n.write('<svg xmlns="http://www.w3.org/2000/svg"></svg>');n.close();a(this.container.querySelector("svg"));v.parentNode.removeChild(v);k.parentNode.removeChild(k)}function ea(a){(this.fixedDiv?[this.fixedDiv,this.scrollingContainer]:[this.container]).forEach(function(c){a.appendChild(c)})}function fa(){var a=this;a.exporting={update:function(c,b){a.isDirtyExporting=!0;m(!0,a.options.exporting,c);w(b,!0)&&a.redraw()}};g.compose(a).navigation.addUpdate(function(c,
b){a.isDirtyExporting=!0;m(!0,a.options.navigation,c);w(b,!0)&&a.redraw()})}function ha(){var a=this;a.isPrinting||(I=a,d.isSafari||a.beforePrint(),setTimeout(function(){r.focus();r.print();d.isSafari||setTimeout(function(){a.afterPrint()},1E3)},1))}function ia(){var a=this,b=a.options.exporting,d=b.buttons,e=a.isDirtyExporting||!a.exportSVGElements;a.buttonOffset=0;a.isDirtyExporting&&a.destroyExport();e&&!1!==b.enabled&&(a.exportEvents=[],a.exportingGroup=a.exportingGroup||a.renderer.g("exporting-group").attr({zIndex:3}).add(),
L(d,function(b){a.addButton(b)}),a.isDirtyExporting=!1)}function ja(a,b){var c=a.indexOf("</svg>")+6,d=a.substr(c);a=a.substr(0,c);b&&b.exporting&&b.exporting.allowHTML&&d&&(d='<foreignObject x="0" y="0" width="'+b.chart.width+'" height="'+b.chart.height+'"><body xmlns="http://www.w3.org/1999/xhtml">'+d.replace(/(<(?:img|br).*?(?=>))>/g,"$1 />")+"</body></foreignObject>",a=a.replace("</svg>",d+"</svg>"));a=a.replace(/zIndex="[^"]+"/g,"").replace(/symbolName="[^"]+"/g,"").replace(/jQuery[0-9]+="[^"]+"/g,
"").replace(/url\(("|&quot;)(.*?)("|&quot;);?\)/g,"url($2)").replace(/url\([^#]+#/g,"url(#").replace(/<svg /,'<svg xmlns:xlink="http://www.w3.org/1999/xlink" ').replace(/ (|NS[0-9]+:)href=/g," xlink:href=").replace(/\n/," ").replace(/(fill|stroke)="rgba\(([ 0-9]+,[ 0-9]+,[ 0-9]+),([ 0-9\.]+)\)"/g,'$1="rgb($2)" $1-opacity="$3"').replace(/&nbsp;/g,"\u00a0").replace(/&shy;/g,"\u00ad");this.ieSanitizeSVG&&(a=this.ieSanitizeSVG(a));return a}var O=[],da=[/-/,/^(clipPath|cssText|d|height|width)$/,/^font$/,
/[lL]ogical(Width|Height)$/,/perspective/,/TapHighlightColor/,/^transition/,/^length$/],N="fill stroke strokeLinecap strokeLinejoin strokeWidth textAnchor x y".split(" ");e.inlineWhitelist=[];var ca=["clipPath","defs","desc"],I;e.compose=function(a,b){k.compose(b);-1===O.indexOf(a)&&(O.push(a),b=a.prototype,b.afterPrint=z,b.exportChart=W,b.inlineStyles=ba,b.print=ha,b.sanitizeSVG=ja,b.getChartHTML=X,b.getSVG=Z,b.getSVGForExport=aa,b.getFilename=Y,b.moveContainers=ea,b.beforePrint=H,b.contextMenu=
U,b.addButton=t,b.destroyExport=V,b.renderExporting=ia,b.callbacks.push(T),x(a,"init",fa),d.isSafari&&d.win.matchMedia("print").addListener(function(a){I&&(a.matches?I.beforePrint():I.afterPrint())}))}})(H||(H={}));e.exporting=m(z.exporting,e.exporting);e.lang=m(z.lang,e.lang);e.navigation=m(z.navigation,e.navigation);"";"";return H});g(a,"masters/modules/exporting.src.js",[a["Core/Globals.js"],a["Extensions/Exporting/Exporting.js"],a["Core/HttpUtilities.js"]],function(a,e,g){a.HttpUtilities=g;a.ajax=
g.ajax;a.getJSON=g.getJSON;a.post=g.post;e.compose(a.Chart,a.Renderer)})});
//# sourceMappingURL=exporting.js.map
/*
 Highcharts JS v9.2.2 (2021-08-24)

 Plugin for displaying a message when there is no data visible in chart.

 (c) 2010-2021 Highsoft AS
 Author: Oystein Moseng

 License: www.highcharts.com/license
*/
'use strict';(function(a){"object"===typeof module&&module.exports?(a["default"]=a,module.exports=a):"function"===typeof define&&define.amd?define("highcharts/modules/no-data-to-display",["highcharts"],function(b){a(b);a.Highcharts=b;return a}):a("undefined"!==typeof Highcharts?Highcharts:void 0)})(function(a){function b(a,b,e,g){a.hasOwnProperty(b)||(a[b]=g.apply(null,e))}a=a?a._modules:{};b(a,"Extensions/NoDataToDisplay.js",[a["Core/Renderer/HTML/AST.js"],a["Core/Chart/Chart.js"],a["Core/DefaultOptions.js"],
a["Core/Color/Palette.js"],a["Core/Utilities.js"]],function(a,b,e,g,d){var f=e.getOptions;e=d.addEvent;var h=d.extend;d=b.prototype;f=f();h(f.lang,{noData:"No data to display"});f.noData={attr:{zIndex:1},position:{x:0,y:0,align:"center",verticalAlign:"middle"},style:{fontWeight:"bold",fontSize:"12px",color:g.neutralColor60}};d.showNoData=function(b){var c=this.options;b=b||c&&c.lang.noData||"";c=c&&(c.noData||{});this.renderer&&(this.noDataLabel||(this.noDataLabel=this.renderer.label(b,0,0,void 0,
void 0,void 0,c.useHTML,void 0,"no-data").add()),this.styledMode||this.noDataLabel.attr(a.filterUserAttributes(c.attr||{})).css(c.style||{}),this.noDataLabel.align(h(this.noDataLabel.getBBox(),c.position||{}),!1,"plotBox"))};d.hideNoData=function(){this.noDataLabel&&(this.noDataLabel=this.noDataLabel.destroy())};d.hasData=function(){for(var a=this.series||[],b=a.length;b--;)if(a[b].hasData()&&!a[b].options.isInternal)return!0;return this.loadingShown};e(b,"render",function(){this.hasData()?this.hideNoData():
this.showNoData()})});b(a,"masters/modules/no-data-to-display.src.js",[],function(){})});
//# sourceMappingURL=no-data-to-display.js.map
/* variables to be used throughout chart options */
var ChartFontFamily = 'IBM Plex Sans, Arial, sans-serif';
var DarkGray = '#6F7070';
var MediumGray = '#AFB0AE';
var LightGray = '#F8F9FA';
var RecessionGray = 'rgba(175,176,174,0.3)';

/* set values for recession bands used in datetime charts, if not previously defined */
if (typeof recessionBands == 'undefined') {
	var recessionBands = [
		{ id: 'recession', color: RecessionGray, from: Date.UTC(1923,4,1), to: Date.UTC(1924,5,1) },
		{ id: 'recession', color: RecessionGray, from: Date.UTC(1926,9,1), to: Date.UTC(1927,10,1) },
		{ id: 'recession', color: RecessionGray, from: Date.UTC(1929,7,1), to: Date.UTC(1933,2,1) },
		{ id: 'recession', color: RecessionGray, from: Date.UTC(1937,4,1), to: Date.UTC(1938,5,1) },
		{ id: 'recession', color: RecessionGray, from: Date.UTC(1945,1,1), to: Date.UTC(1945,9,1) },
		{ id: 'recession', color: RecessionGray, from: Date.UTC(1948,10,1), to: Date.UTC(1949,9,1) },
		{ id: 'recession', color: RecessionGray, from: Date.UTC(1953,6,1), to: Date.UTC(1954,4,1) },
		{ id: 'recession', color: RecessionGray, from: Date.UTC(1957,7,1), to: Date.UTC(1958,3,1) },
		{ id: 'recession', color: RecessionGray, from: Date.UTC(1960,3,1), to: Date.UTC(1961,1,1) },
		{ id: 'recession', color: RecessionGray, from: Date.UTC(1969,11,1), to: Date.UTC(1970,10,1) },
		{ id: 'recession', color: RecessionGray, from: Date.UTC(1973,10,1), to: Date.UTC(1975,2,1) },
		{ id: 'recession', color: RecessionGray, from: Date.UTC(1980,0,1), to: Date.UTC(1980,6,1) },
		{ id: 'recession', color: RecessionGray, from: Date.UTC(1981,6,1), to: Date.UTC(1982,10,1) },
		{ id: 'recession', color: RecessionGray, from: Date.UTC(1990,6,1), to: Date.UTC(1991,2,1) },
		{ id: 'recession', color: RecessionGray, from: Date.UTC(2001,2,1), to: Date.UTC(2001,10,1) },
		{ id: 'recession', color: RecessionGray, from: Date.UTC(2007,11,1), to: Date.UTC(2009,5,1) },
		{ id: 'recession', color: RecessionGray, from: Date.UTC(2020,1,1), to: Date.UTC(2020,3,1) }
	];
}

/* set global settings for all Highcharts visualizations */
function setChartDefaults(chartWidth,chartHeight,chartSourceLine,chartSourceLineOffset, chartBorderWidth, chartColors, fontType) {


	if (!chartWidth) chartWidth = 650;
	if (!chartHeight) chartHeight = 450;
	if (!chartSourceLine) chartSourceLine = 'Source: Atlanta Fed';
	if (!chartSourceLineOffset) chartSourceLineOffset =  50;
	if (!chartBorderWidth) chartBorderWidth = 1;
	if (!fontType) fontType = "";


	//var defaultColors = ['#6929c4', /* Purple 70 */
	//		'#1192e8', /* Cyan 50 */
	//		'#005d5d', /* violet */
	//		'#CAB2D6', /* light violet */
	//		'#E31A1C', /* red */
	//		'#FB9A99', /* light red */
	//		'#FF7F00', /* orange */
	//		'#FDBF6F', /* light orange */
	//		'#33A02C', /* green */
	//		'#B2DF8A', /* light green */
	//		'#CC2870', /* magenta */
	//		'#E593B7' /* light magenta */];
			
			
	var defaultColors = ['#0E4768', /* "Bank" blue */
			'#768F40', /* green */
			'#F5892F', /* orange */
			'#581F54', /* purple */
			'#5588A3', /* light blue */
			'#084225', /* dark green */
			'#B59236', /* gold */
			'#8B4823', /* dark orange */
			'#756A5C', /* brown */
			'#A01D23', /* red */
			'#000000', /* black */
			'#B89078', /* faded dark orange; tan */
			'#CF8788', /* faded red; coral */
			'#AB8EA9', /* faded purple; mauve */
			'#9BB4A9', /* faded dark green; mint */
			'#B5C7D1'  /* faded "Bank" blue; sky */
			];
	
	var darkColors = ['#8a3ffc','#33b1ff','#007d79','#ff7eb6','#fa4d56','#fff1f1','#6fdc8c','#4589ff','#d12771','#d2a106','#08bdba'];
	
	var responsive = [{
				condition: { maxWidth: 500 },
				chartOptions: {
					legend: { 
						itemStyle: { font: '10px ' + ChartFontFamily }
					},
					subtitle: { 
						style: { font: '11px ' + ChartFontFamily }
					},
					title: { 
						style: { font: 'bold 13px ' + ChartFontFamily }
					},
					xAxis: {
						labels: { style: { font: '10px ' + ChartFontFamily } }, 
						title: { style: { font: '10px ' + ChartFontFamily } }
					},
					yAxis: [{
						labels: { style: { font: '10px ' + ChartFontFamily } }, 
						title: { style: { font: '10px ' + ChartFontFamily } }
					},{ /* right-side for dual-axis charts; add blank title to avoid default "Values" appearing for charts with one y axis */
						labels: { style: { font: '10px ' + ChartFontFamily } }, 
						title: { style: { font: '10px ' + ChartFontFamily }, text: '' }
					}],
					rangeSelector: { 
						buttonPosition: { align: 'left', x: -20 },
						buttonTheme: {
							style: { fontSize: '10px', fontFamily: ChartFontFamily }
						},
						inputStyle: { fontSize: '10px', fontFamily: ChartFontFamily },
						labelStyle: { fontSize: '10px', fontFamily: ChartFontFamily }
					}
				}
			}];
	
	var colors = [];
	if(!chartColors) {
		colors = defaultColors;
	} else {
		colors = darkColors;
	}
	
	var chartFontSize = "14px";
	var legendFontSize = "13px ";
	var tooltipFontSize = "12px";
	var axisFontSize = "10px ";
	
	
	if(fontType == "small") {
		chartFontSize = "18px";
		legendFontSize = "17px ";
		tooltipFontSize = "16px";
		axisFontSize = "14px ";	
		
		responsive = [];
	}
	else if(fontType == "regular") {
		chartFontSize = "20px";
		legendFontSize = "19px ";
		tooltipFontSize = "18px";
		axisFontSize = "16px ";	
		
		responsive = [];
	} else if(fontType == "large") {
		chartFontSize = "24px";
		legendFontSize = "23px ";
		tooltipFontSize = "22px";
		axisFontSize = "20px ";	
		
		responsive = [];
	}
	
	Highcharts.setOptions({
		chart: { 
			borderColor: MediumGray, borderWidth: chartBorderWidth, zoomType: 'x', 
			style: { color: DarkGray, fontFamily: ChartFontFamily, fontSize: chartFontSize }
		},
		colors: colors,
		credits: { enabled: true, text: '', style: { color: '#FFFFFF', font: '9px ' + ChartFontFamily }, position: { align: 'right', y: -10 } },
		exporting: {
			scale: 1, allowHTML: true, 
			chartOptions: {
				chart: { height: chartHeight, width: chartWidth },
				legend: { enabled: true },
				rangeSelector: { enabled: false }
			},
			enableImages: true,
			buttons: {
				contextButton: { 
					text: 'Export',
                    menuItems: [{
                        text: 'Print this chart', onclick: function () { 
							this.print();
							thisTitle = this.options.title.text; newTitle = thisTitle.replace("<br>",": "); newTitle = thisTitle.replace("<br />",": "); 
							window.dataLayer = window.dataLayer || [];
							window.dataLayer.push({ 'event': 'Highcharts', 'category': 'Highcharts', 'action': 'print', 'label': newTitle + ' | ' + document.title });
						}
					}, {
                        separator: true, 
					}, {
                        text: 'Save as PNG', onclick: function () { 
							this.exportChart();
							thisTitle = this.options.title.text; newTitle = thisTitle.replace("<br>",": "); newTitle = thisTitle.replace("<br />",": ");
							window.dataLayer = window.dataLayer || [];
							window.dataLayer.push({ 'event': 'Highcharts', 'category': 'Highcharts', 'action': 'png', 'label': newTitle + ' | ' + document.title });
						}
                    }, {
                        text: 'Save as JPEG', onclick: function () { 
							this.exportChart({ type: 'image/jpeg' });
							thisTitle = this.options.title.text; newTitle = thisTitle.replace("<br>",": "); newTitle = thisTitle.replace("<br />",": ");
							window.dataLayer = window.dataLayer || [];
							window.dataLayer.push({ 'event': 'Highcharts', 'category': 'Highcharts', 'action': 'jpeg', 'label': newTitle + ' | ' + document.title });
						}
                    }, {
                        text: 'Save as SVG', onclick: function () { 
							this.exportChart({ type: 'image/svg+xml' });
							thisTitle = this.options.title.text; newTitle = thisTitle.replace("<br>",": "); newTitle = thisTitle.replace("<br />",": ");
							window.dataLayer = window.dataLayer || [];
							window.dataLayer.push({ 'event': 'Highcharts', 'category': 'Highcharts', 'action': 'svg', 'label': newTitle + ' | ' + document.title });
						}
                    }, {
                        text: 'Save as PDF', onclick: function () { 
							this.exportChart({ type: 'application/pdf' }); 
							thisTitle = this.options.title.text; newTitle = thisTitle.replace("<br>",": "); newTitle = thisTitle.replace("<br />",": ");
							window.dataLayer = window.dataLayer || [];
							window.dataLayer.push({ 'event': 'Highcharts', 'category': 'Highcharts', 'action': 'pdf', 'label': newTitle + ' | ' + document.title });
						}
                    }]
				}
			}
		},
		lang: { thousandsSep: ',', noData: "No data are available for this selection." },
		legend: { 
			enabled: true, align: 'right', backgroundColor: '#FFFFFF', borderRadius: 5, borderWidth: 1, layout: 'horizontal', symbolWidth: 20, verticalAlign: 'top', 
			itemStyle: { color: DarkGray, font: '13px ' + ChartFontFamily, paddingTop: '2px', paddingBottom: '2px' }, useHTML: false, itemMarginTop: 2, itemMarginBottom: 2
		},
		navigation: {
			menuStyle : { 
				fontFamily: ChartFontFamily, fontSize: '18px', color: DarkGray
			}
		},
		noData: {
			attr: { zIndex: 10 }, style: { fontFamily: ChartFontFamily, fontWeight: 'bold', fontSize: '18px', color: DarkGray }
		},
		plotOptions: {
			area: { marker: { enabled: false } },
			line: { marker: { enabled: false } },
			scatter: { marker: { enabled: true } },
			spline: { marker: { enabled: false } },
			
                        series: {
				events: {
					hide: function () {
						thisTitle = this.chart.title.textStr; newTitle = thisTitle.replace("<br>",": "); newTitle = thisTitle.replace("<br />",": "); 
						window.dataLayer = window.dataLayer || [];
						window.dataLayer.push({ 'event': 'Highcharts', 'category': 'Highcharts', 'action': 'hideSeries', 'label': newTitle + ' (series: ' + this.name + ') | ' + document.title });
					}, 
					show: function () { 
						thisTitle = this.chart.title.textStr; newTitle = thisTitle.replace("<br>",": "); newTitle = thisTitle.replace("<br />",": "); 
						window.dataLayer = window.dataLayer || [];
						window.dataLayer.push({ 'event': 'Highcharts', 'category': 'Highcharts', 'action': 'showSeries', 'label': newTitle + ' (series: ' + this.name + ') | ' + document.title });
					}
				} // end events
			} // end series
                      
		},
		subtitle: { align: 'left', style: { color: DarkGray, font: '14px ' + ChartFontFamily }, x: 5 },
		title: { align: 'left', style: { color: '#000000', font: '18px ' + ChartFontFamily }, x: 5, y: 15 },
		xAxis: {
			lineColor: DarkGray, lineWidth: 2, tickmarkPlacement: 'on',
			labels: { style: { fontSize: axisFontSize  } }, 
			title: { style: { fontSize: axisFontSize  } }
		},
		yAxis: {
			lineColor: DarkGray, lineWidth: 0, tickmarkPlacement: 'on',
			labels: { style: { fontSize: axisFontSize  } }, 
			title: { style: { fontSize: axisFontSize  } }, 
			plotLines: [{ value: 0, color: '#ABABAB', width: 2, zIndex: 1 }]
		},
		tooltip: {
			style: { fontFamily: ChartFontFamily, fontSize: tooltipFontSize }              
		},
		/* for charts using Highstock date ranges */
		rangeSelector: { 
			enabled: true,
			verticalAlign: 'top',
			inputDateFormat: '%b %Y', /* for datepicker interface */
			buttons: [
				{ type: 'year', count: 1, text: '1y' },
				{ type: 'year', count: 5, text: '5y' },
				{ type: 'year', count: 10, text: '10y' },
				{ type: 'year', count: 20, text: '20y' },
				{ type: 'all', text: 'All' }
			],
			buttonTheme: {
				fill: LightGray, stroke: MediumGray,
				style: { color: DarkGray, fontSize: '14px', fontFamily: ChartFontFamily }
			},
			inputStyle: { color: DarkGray, fontSize: '14px', fontFamily: ChartFontFamily },
			labelStyle: { color: DarkGray, fontSize: '14px', fontFamily: ChartFontFamily }
		},
		responsive: {
			rules: responsive
		}
	});	
}

/* https://stackoverflow.com/questions/39860063/jquery-datepicker-with-highstocks-highcharts and http://jsfiddle.net/BWEm5/ */
function setHighstockDatePickers(chart) {

	/* apply the date pickers and set specific ranges for this chart */
	var extremes = chart.xAxis[0].getExtremes();

	setTimeout(function() {
		$('input.highcharts-range-selector', $('#' + chart.options.chart.renderTo)).datepicker({
			/* add one day to each extreme to get to start of calendar month */
			minDate: new Date(extremes.dataMin + 86400000),
			maxDate: new Date(extremes.dataMax + 86400000),
		})
	}, 0);
	/* set the format for the date pickers */
	$.datepicker.setDefaults({
		dateFormat: 'MM yy', changeMonth: true, changeYear: true, showButtonPanel: true,
		/* http://www.jquerybyexample.net/2012/06/show-only-month-and-year-in-jquery-ui.html */
		 onClose: function() {
			var iMonth = $("#ui-datepicker-div .ui-datepicker-month :selected").val();
			var iYear = $("#ui-datepicker-div .ui-datepicker-year :selected").val();
			$(this).datepicker('setDate', new Date(iYear, iMonth, 1));
		 },
		 beforeShow: function() {
		   if ((selDate = $(this).val()).length > 0) {
			  iYear = selDate.substring(selDate.length - 4, selDate.length);
			  iMonth = jQuery.inArray(selDate.substring(0, selDate.length - 5), $(this).datepicker('option', 'monthNames'));
			  $(this).datepicker('option', 'defaultDate', new Date(iYear, iMonth, 1));
			  $(this).datepicker('setDate', new Date(iYear, iMonth, 1));
		   }
		}
	});

}

/* set branding for the bottom of the chart */
function setChartBranding(chartObject,chartWidth,chartHeight,chartSourceLine,chartSourceLineOffset) {
	if (!chartWidth) chartWidth = 650;
	if (!chartHeight) chartHeight = 450;
	if (!chartSourceLine) chartSourceLine = 'Source: Atlanta Fed';
	if (!chartSourceLineOffset) chartSourceLineOffset = 50;


	/* set branding in exported versions */
	chartObject.update({ 
		exporting: {
			chartOptions: {
				chart: { 
					events: { 
						load: function() { 
							this.renderer.text(chartSourceLine,15,chartHeight-chartSourceLineOffset).css({ color: '#756A5B', font: '11px IBM Plex Sans, Arial, sans-serif', width: chartWidth-50 }).add(); 
							/*this.renderer.image('https://www.frbatlanta.org/-/media/images/logos/FRBAlogo-Column-1Line.png', 15, chartHeight-28, 296, 20).attr({ zIndex: 3 }).add(); 
							*/
							/* EDB 3/31/23
							this.renderer.image('https://www.atlantafed.org/-/media/images/logos/atlantafed-highcharts-logo-svg.svg', 15, chartHeight-28, 296, 20).attr({ zIndex: 3 }).add();
                                                        */
                                                        this.renderer.image('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASgAAAAUCAYAAAA+yKB7AAAACXBIWXMAAAsTAAALEwEAmpwYAAAF8WlUWHRYTUw6Y29tLmFkb2JlLnhtcAAAAAAAPD94cGFja2V0IGJlZ2luPSLvu78iIGlkPSJXNU0wTXBDZWhpSHpyZVN6TlRjemtjOWQiPz4gPHg6eG1wbWV0YSB4bWxuczp4PSJhZG9iZTpuczptZXRhLyIgeDp4bXB0az0iQWRvYmUgWE1QIENvcmUgNS42LWMxNDggNzkuMTY0MDM2LCAyMDE5LzA4LzEzLTAxOjA2OjU3ICAgICAgICAiPiA8cmRmOlJERiB4bWxuczpyZGY9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkvMDIvMjItcmRmLXN5bnRheC1ucyMiPiA8cmRmOkRlc2NyaXB0aW9uIHJkZjphYm91dD0iIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtbG5zOmRjPSJodHRwOi8vcHVybC5vcmcvZGMvZWxlbWVudHMvMS4xLyIgeG1sbnM6cGhvdG9zaG9wPSJodHRwOi8vbnMuYWRvYmUuY29tL3Bob3Rvc2hvcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb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WS+nZVdmQ9Jd5jYbTz6pJ3yf8mRh3tK9y/quR5P6tS30XR/o8lfShplhxaMDvKLpHDTvJlRhXqP0s+Wk9IMVgrlI3TuCi7vTw/P4rfZDkG6Mgouzx+dwT/fpIW5eq+sMJ7DJDH+j55fi+SQ2DS/VT/gCp9kX7bR9sXyXFkpxXuD5fncJo/KbShuaQPcm29Xp77D0bblgb9+OAfqpXxohyXOCPyVwbfBZFfEel1QU99XuyzLnKfJ6T4tm0lLcjR58phBinm8aE6qWatd2+svRxVA293vBNPC6m5JfYzzV1Nmd2wXf8IlT/Q3B37Wh7Apk13Vj5ezqMXPiJ/G5sA6SSiLupYiCO4ewatzE/SN9r1MpmpuSfeDW/FO+5W8X6tsdn5Gqt+hLkl3omn4j5J//ZQfM9NsSY0HfvYwJrZ7lgTfJLsFChhk3iXnljjewtrwJWOrvtgh+hUVg47aIlPwZLPsRd2wFb7Wr411oYWVeHpgPusDp/CVdPEe0Q7puPduR73QzPsyH+/QrnVjVOLqHsa7q9OeAdvg/ttOtasumATp1M8exrWKlrj8doM+6Jm4TEVlftnC/x/aXOwCZYf65tx1HgrVh9i0Dae+0609T0y/y14znWOd6iL9r6BNZfWwJfjGS9FG/rgtTgXj/eHufraYb9zS+yTWoDn3T7Yl/kC7scNsdbVDa+B14OvDav2GUHvh11Gr5BpVS2wbOmGXT4z8fgMBt5siIDaGMfZLMZ+kctY+195N6EJ/yyow+vnGSxgVuBT8l2qFfq8oyEfQy7GJxdzsT9oTTvMm9CEf2YMxRrJ/lhDaU5tf6vyuUZDNCio/s8BTWhCEyqjHz7+f4Lsn0LuW68t+gfA3wDOy8qrzHNSRQAAAABJRU5ErkJggg==', 15, chartHeight-28, 296, 20).attr({ zIndex: 3 }).add();
							this.renderer.rect(1, chartHeight-34, chartWidth-3, 32, 0).attr({ 'stroke-width': 0, fill: '#000000', zIndex: 2 }).add(); 
							
							
							this.update({ credits: { text: 'Exported on: ' + Highcharts.dateFormat('%A, %B %e, %Y', Date.now()) } });
						}
					}
				}
			}
		}
	});
	/* set branding in browser version; check to see whether responsive condition exists to adjust sizing */
	if (chartObject.hasOwnProperty('currentResponsive')) {
		chartObject.renderer.text(chartSourceLine,15,chartHeight-chartSourceLineOffset,true).css({ color: '#756A5B', font: '9px IBM Plex Sans, Arial, sans-serif', marginRight: '15px', wordWrap: 'break-word', whiteSpace: 'normal', lineHeight: 'normal' }).add();
		/* hide label for the export menu at small sizes; needs to be declared here vs. the general responsive rules */
		chartObject.update({
			exporting: {
				buttons: {
					contextButton: { text: null }
				}
			}
		});
	} else {
		chartObject.renderer.text(chartSourceLine,15,chartHeight-chartSourceLineOffset,true).css({ color: '#756A5B', font: '11px IBM Plex Sans, Arial, sans-serif', marginRight: '15px', wordWrap: 'break-word', whiteSpace: 'normal', lineHeight: '140%' }).add();
	} 
	chartObject.renderer.image('https://www.frbatlanta.org/-/media/images/logos/atlantafed-highcharts-logo.png', 15, chartHeight-28, 296, 20).attr({ zIndex: 3 }).add();
	chartObject.renderer.rect(1, chartHeight-36, chartWidth-3, 34, 0).attr({ 'stroke-width': 0, fill: '#000000', zIndex: 2 }).add();
}
var updateDate = ["10/10/2024"];
var chart_dates = ["1/1/1997","2/1/1997","3/1/1997","4/1/1997","5/1/1997","6/1/1997","7/1/1997","8/1/1997","9/1/1997","10/1/1997","11/1/1997","12/1/1997","1/1/1998","2/1/1998","3/1/1998","4/1/1998","5/1/1998","6/1/1998","7/1/1998","8/1/1998","9/1/1998","10/1/1998","11/1/1998","12/1/1998","1/1/1999","2/1/1999","3/1/1999","4/1/1999","5/1/1999","6/1/1999","7/1/1999","8/1/1999","9/1/1999","10/1/1999","11/1/1999","12/1/1999","1/1/2000","2/1/2000","3/1/2000","4/1/2000","5/1/2000","6/1/2000","7/1/2000","8/1/2000","9/1/2000","10/1/2000","11/1/2000","12/1/2000","1/1/2001","2/1/2001","3/1/2001","4/1/2001","5/1/2001","6/1/2001","7/1/2001","8/1/2001","9/1/2001","10/1/2001","11/1/2001","12/1/2001","1/1/2002","2/1/2002","3/1/2002","4/1/2002","5/1/2002","6/1/2002","7/1/2002","8/1/2002","9/1/2002","10/1/2002","11/1/2002","12/1/2002","1/1/2003","2/1/2003","3/1/2003","4/1/2003","5/1/2003","6/1/2003","7/1/2003","8/1/2003","9/1/2003","10/1/2003","11/1/2003","12/1/2003","1/1/2004","2/1/2004","3/1/2004","4/1/2004","5/1/2004","6/1/2004","7/1/2004","8/1/2004","9/1/2004","10/1/2004","11/1/2004","12/1/2004","1/1/2005","2/1/2005","3/1/2005","4/1/2005","5/1/2005","6/1/2005","7/1/2005","8/1/2005","9/1/2005","10/1/2005","11/1/2005","12/1/2005","1/1/2006","2/1/2006","3/1/2006","4/1/2006","5/1/2006","6/1/2006","7/1/2006","8/1/2006","9/1/2006","10/1/2006","11/1/2006","12/1/2006","1/1/2007","2/1/2007","3/1/2007","4/1/2007","5/1/2007","6/1/2007","7/1/2007","8/1/2007","9/1/2007","10/1/2007","11/1/2007","12/1/2007","1/1/2008","2/1/2008","3/1/2008","4/1/2008","5/1/2008","6/1/2008","7/1/2008","8/1/2008","9/1/2008","10/1/2008","11/1/2008","12/1/2008","1/1/2009","2/1/2009","3/1/2009","4/1/2009","5/1/2009","6/1/2009","7/1/2009","8/1/2009","9/1/2009","10/1/2009","11/1/2009","12/1/2009","1/1/2010","2/1/2010","3/1/2010","4/1/2010","5/1/2010","6/1/2010","7/1/2010","8/1/2010","9/1/2010","10/1/2010","11/1/2010","12/1/2010","1/1/2011","2/1/2011","3/1/2011","4/1/2011","5/1/2011","6/1/2011","7/1/2011","8/1/2011","9/1/2011","10/1/2011","11/1/2011","12/1/2011","1/1/2012","2/1/2012","3/1/2012","4/1/2012","5/1/2012","6/1/2012","7/1/2012","8/1/2012","9/1/2012","10/1/2012","11/1/2012","12/1/2012","1/1/2013","2/1/2013","3/1/2013","4/1/2013","5/1/2013","6/1/2013","7/1/2013","8/1/2013","9/1/2013","10/1/2013","11/1/2013","12/1/2013","1/1/2014","2/1/2014","3/1/2014","4/1/2014","5/1/2014","6/1/2014","7/1/2014","8/1/2014","9/1/2014","10/1/2014","11/1/2014","12/1/2014","1/1/2015","2/1/2015","3/1/2015","4/1/2015","5/1/2015","6/1/2015","7/1/2015","8/1/2015","9/1/2015","10/1/2015","11/1/2015","12/1/2015","1/1/2016","2/1/2016","3/1/2016","4/1/2016","5/1/2016","6/1/2016","7/1/2016","8/1/2016","9/1/2016","10/1/2016","11/1/2016","12/1/2016","1/1/2017","2/1/2017","3/1/2017","4/1/2017","5/1/2017","6/1/2017","7/1/2017","8/1/2017","9/1/2017","10/1/2017","11/1/2017","12/1/2017","1/1/2018","2/1/2018","3/1/2018","4/1/2018","5/1/2018","6/1/2018","7/1/2018","8/1/2018","9/1/2018","10/1/2018","11/1/2018","12/1/2018","1/1/2019","2/1/2019","3/1/2019","4/1/2019","5/1/2019","6/1/2019","7/1/2019","8/1/2019","9/1/2019","10/1/2019","11/1/2019","12/1/2019","1/1/2020","2/1/2020","3/1/2020","4/1/2020","5/1/2020","6/1/2020","7/1/2020","8/1/2020","9/1/2020","10/1/2020","11/1/2020","12/1/2020","1/1/2021","2/1/2021","3/1/2021","4/1/2021","5/1/2021","6/1/2021","7/1/2021","8/1/2021","9/1/2021","10/1/2021","11/1/2021","12/1/2021","1/1/2022","2/1/2022","3/1/2022","4/1/2022","5/1/2022","6/1/2022","7/1/2022","8/1/2022","9/1/2022","10/1/2022","11/1/2022","12/1/2022","1/1/2023","2/1/2023","3/1/2023","4/1/2023","5/1/2023","6/1/2023","7/1/2023","8/1/2023","9/1/2023","10/1/2023","11/1/2023","12/1/2023","1/1/2024","2/1/2024","3/1/2024","4/1/2024","5/1/2024","6/1/2024","7/1/2024","8/1/2024","9/1/2024"];
var chart_overall = [null,null,4.5,4.6,4.5,4.6,4.8,4.9,4.8,4.8,4.8,4.9,4.9,4.8,4.6,4.9,5.2,5.4,5.4,5.3,5.1,5,4.9,5,5,5,5.2,5.2,5.2,4.9,5,4.8,5,5.1,5.2,5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.6,14.6,14.2,14.1,13.5,13.3,13.4,13.2,13.1,12.5,12.9,13.1,13.4,13.1,12.9,12.9,12.9,13,13,12.7,12.7,12.2,12.2,11.7,12,12.3,12.6,12.7,12.9,13.2,13.2,13.3,13.3,13.3,13.1,13.2,13.2,12.9,12.9,12.8,13.2,13.3,13.8,13.8,14,14,13.8,13.7,13.3,13.7,13.7,13.8,13.9,13.8,14.2,14.3,13.9,14,13.8,14.3,14.3,14.8,14.7,14.7,14.7,15.4,15.5,15.4,14.9,15,14.8,14.3,13.9,14.1,14.5,14.8,14.7,14.6,14.3,14.2,14.2,14,13.5,12.8,12.4,12.3,12.7,13,12.7,12.4,11.9,11.8,11.1,11.1,10.9,11,10.6,10.9,11,11.1,11.3,11.1,10.8,10.5,10.2,10.5,10.5,11,11.1,11.1,11,11,11.2,11.4,11.9,11.7,12.1,11.7,11.7,11.4,10.9,10.9,11.3,11.8,12.2,11.7,11.6,11.5,11.4,11.5,11.9,12.1,12.3,12.3,12.2,12,11.9,12.2,12.4,12.3,11.9,11.4,11.4,11.5,12.1,12.1,12.2,11.8,12.2,12.2,12.6,12.7,13,12.7,12.3,12.6,13.1,14,14.2,14,13.6,13.5,13.8,14,13.7,13.8,13.6,13.5,13.7,14.1,14.8,15,14.6,14.6,14.3,14.9,14.7,14.6,13.8,13.3,13.9,14.3,14.4,13.7,13.7,14.2,14,13.7,13,13.5,13.8,14,13.9,14.2,13.9,13.6,13.5,13.7,13.8,13.3,13.6,14.2,14.3,14.4,13.9,14.1,14.5,14.7,14.7,14.6,14.2,14.1,13.4,13.9,13.9,14.2,14,13.8,13.9,14.3,14.7,15.2,15.1,15.3,14.5,14.7,14.2,14.6,14.3,13.8,13.3,12.9,13.4,14.3,15,15.5,15.7,16,16.6,17.2,17.9,18.2,18.6,18.6,19.1,19.2,19.2,18.2,17.7,17.6,17.9,18.1,17.9,18,17.5,17.7,17,16.9,16.2,15.9,15.7,16,16.2,16.2,15.4,14.8,15.5,16.1,16,15.4,14.7,15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5,12.6,13,13.4,13.7,13.5,13.9,14.1,13.8,13.9,13.3,13.4,13.4,13.8,13.8,13.5,12.8,12.9,12.7,13,12.9,13.2,13.2,12.8,13.1,13.1,13.3,12.9,13,12.6,12.1,12.1,12.4,12.2,11.8,11.6,12.1,12.2,12.6,12.5,12.2,11.8,11.6,11.6,11.3,11.5,11,11.4,11,11.6,11.5,11.7,11.7,11.5,11.2,11.2,11.5,11.7,11.2,11.4,11.2,11.6,11.6,12,12,11.7,11.8,11.7,12.1,12.3,12.6,13,13.3,14.2,14.3,14.7,14.6,15.2,15.5,16.1,15.9,15.7,15.6,15.7,15.9,16.1,16,16.4,16.1,16.8,16.1,17.1,16.8,17.1,16,16.1,16.2,16.1,16.3,16,16.7,16,16.1,15.8,16.1,16.3,15.8,15.9,16.2,16.7,17.2,17.2,16.9,16.3,15.5,15.3,15.1,15.5,15.5,15.6,15.7,16.1,16.1,16,15.8,15.6,15.5,15,15.1,14.9,15.1,15.6,15.7,16.1,15.6,15.4,15,15.1,15,14.6,14.1,14,14.2,14.3,14.5,14.6,14.7,14.5,14.9,14.7,14.6,14.3,14.6,14.6,14.1,13.7,13.4,13.1,13.6,13.7,13.5,13,13.5,14.7,15,14.5,13.9,13.9,14.4,14.7,14.7,14.6,14.1,13.9,14.1,14.4,14.9,14.3,14.3,14.3,14.4,14.2,13.8,14,14.3,13.9,13.4,13.4,13.4,13.4,13.3,13.7,13.4,13.3,12.9,13.9,13.6,13.5,12.7,13.4,13.6,13.7,13.9,14.1,14.2,13.8,13.8,14.5,14.7,14.7,14,14.3,14.2,13.9,13.5,13.9,14.6,14.2,13.9,13.4,13.4,12.9,12.9,12.8,12.3,11.4,11,11.1,11.4,11.1,11.2,11.1,12.1,12.1,11.9,11.2,11.2,11.2,10.9,10.5,10.3,10.8,11.2,12.1,12.1,12,11.4,11.6,12.3,12.6,12.5,11.9,12.1,12.2,12.8,12.9,12.3];
var ethnicity_White = [null,null,null,null,null,null,null,null,null,null,null,4.7,4.8,4.7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2.2,2.2,2.3,2.3,2.3,2.3,2.3,2.3,2.3,2.4,2.5,2.5,2.6,2.6,2.7,2.8,2.9,2.9,3,3.1,3.1,3.1,3.1,3.1,3.1,3.1,3.2,3.1,3.1,3.2,3.2,3.2,3.3,3.4,3.5,3.5,3.5,3.5,3.5,3.5,3.5,3.5,3.4,3.5,3.5,3.4,3.3,3.3,3.3,3.3,3.2,3.3,3.2,3.2,3.3,3.2,3.2,3.2,3.3,3.4,3.5,3.5,3.5,3.5,3.6,3.6,3.7,3.7,3.7,3.7,3.7,3.6,3.7,3.7,3.7,3.7,3.6,3.7,3.6,3.6,3.6,3.6,3.6,3.6,3.5,3.5,3.5,3.5,3.5,3.4,3.4,3.5,3.5,3.6,3.6,3.7,3.8,4,4.3,4.5,4.7,5,5.3,5.5,5.7,5.9,6,6.2,6.3,6.3,6.3,6.4,6.3,6.3,6.1,6,6,5.8,5.8,5.6,5.6,5.5,5.4,5.2,5.3,5.2,5.1,5.1,5,5];

var chartOptions_wageGrowthTracker;
var chart_wageGrowthTracker = "";
 
var PickerMaxDefault = chart_dates.length-1;
var PickerMinDefault = chart_dates.length-60;

var sliderMinHistory = 0;
var sliderMaxHistory = 0;

$(document).ready(function () {
  /* set chart dimensions based on iframe and container_WageGrowth sizes */
  var iframeWidth_wageGrowthTracker = "650";
  var iframeHeight_wageGrowthTracker = "390";
  var sourceLine_wageGrowthTracker = "Sources: Current Population Survey, Bureau of Labor Statistics and author's calculations.";
/*
    "Note: The blue shaded area reflects the inclusion of the April 2024 data, which coincided with introduction of new privacy measures in the underlying data behind the Wage Growth Tracker. More information is available here. ";
  */
  var BreakBlue = 'rgba(15, 158, 213, 0.3)';
  
  var mma3Reccession = [];
  
  var mma3 = {
            id: 'break',
            color: BreakBlue,
            from: Date.UTC(2024,3,1),
            to: Date.UTC(2024,5,1)
          };
  var mma12 = {
            id: 'break',
            color: BreakBlue,
            from: Date.UTC(2024,3,1),
            to: Date.UTC(2025,6,1)
          };
		  
	 /* set placeholders for details about the chart */
 
   mma3Reccession = arrayCopy(recessionBands);
   //mma3Reccession.push({id: 'break', color: BreakBlue, from: Date.UTC(2024,3,1), to: Date.UTC(2024,5,1)} );			  
  
  var ChartStartDate = chart_dates[0].split("/");
  
  var ChartStartDateUTC = Date.UTC(
      ChartStartDate[2],
      ChartStartDate[0] - 1,
      ChartStartDate[1]
    );
	
   /* define local chart attributes */
  chartOptions_wageGrowthTracker = {
    chart: {
      marginBottom: 110,
      marginRight: 20,
      type: "line",
      resetZoomButton: {
        position: {
          x: -80,
          y: -45,
        },
      },
    },
    exporting: {
      chartOptions: {
        legend: { enabled: true },
      },
      filename: "atlanta-fed_wage-growth-tracker",
    },
    legend: { 
           // EDB floating: true, 
           verticalAlign: "bottom", 
           y: 120, 
           x: -50 
     },
    subtitle: { text: "" },
    title: { text: "" },
    tooltip: {
      formatter: function () {
        var s =
          '<span style="font-size: 14px;">' +
          Highcharts.dateFormat("%B %Y", this.x) +
          "</span>";
        $.each(this.points, function (i, point) {
          s +=
            '<br /><span style="color: ' +
            point.series.color +
            ';">●</span> ' +
            point.series.name +
            ": " +
            Highcharts.numberFormat(point.y, 1) +
            "%";
        });
        return s;
      },
      shared: true,
    },
    plotOptions: {
      series: {
        pointStart: ChartStartDateUTC,  
        pointIntervalUnit: "month",
      },
    },
    xAxis: {
      labels: { y: 20 },
      type: "datetime",
      plotBands: mma3Reccession
    },
    yAxis: {
      min: 0,
      title: { text: "Percent" },
    },
    series: [],
  };	
   
/* initialize local variables */
  var PickerMaxDate, PickerMinDate, PickerMaxDateUTC, PickerMinDateUTC;
  var PickerLabels = [];
  var PickerLabelsTemp = [];
  var monthNames = [
    "January",
    "February",
    "March",
    "April",
    "May",
    "June",
    "July",
    "August",
    "September",
    "October",
    "November",
    "December",
  ];
  
  


  /* generate the user-readable labels for the picker/slider */

  for (var p = 0; p < chart_dates.length; p++) {
    PickerLabelsTemp = chart_dates[p].split("/");
    PickerLabels.push(
      monthNames[PickerLabelsTemp[0] - 1].substring(0, 3) +
        " " +
        PickerLabelsTemp[2]
    );
  }
  
  function arrayCopy(parent) {
	var child = [];
	
	for(var i = 0; i < parent.length; i++) {
		child.push(parent[i]);
	}
	
	return child;
  }
 
  /* draw the chart */
  function drawChart_wageGrowthTracker(whichChart) {
    /* set chart dimensions based on iframe and container_WageGrowth sizes */
    iframeWidth_wageGrowthTracker = $(".wageGrowthCharts").width();
    iframeHeight_wageGrowthTracker = $(".wageGrowthCharts").height();

    /* set both the chart series and the configuration array to zero to prevent repeated values */
    chartOptions_wageGrowthTracker.series.length = 0;

    chartOptions_wageGrowthTracker.xAxis.tickInterval =
      1000 * 60 * 60 * 24 * 365 * 2;
    chartOptions_wageGrowthTracker.yAxis.tickInterval = 1;
	

    switch (whichChart) {
      case "weighted":
	  
	//    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
        //chart_wageGrowthTracker.xAxis[0].addPlotBand(mma3);
		
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Overall unweighted",
          data: chart_overall,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "Overall weighted",
          data: chart_weightedOverall,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[2] = {
          name: "Overall weighted, 1997 characteristics",
          data: chart_weighted97Overall,
          visible: true,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_wageGrowthTracker";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.4;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.subtitle.text =
          "three-month moving average of median wage growth, hourly data";
        chartOptions_wageGrowthTracker.title.text =
          "Wage Growth Tracker, Weighted Series";
        break;
      case "hourlyweekly":
	  
//	    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
 //       chart_wageGrowthTracker.xAxis[0].addPlotBand(mma3);
	  
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Hourly basis",
          data: chart_overall,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "Weekly basis",
          data: chart_overallWeekly,
          visible: true,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_wageGrowthTracker";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.4;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.subtitle.text =
          "three-month moving averages of median wage growth";
        chartOptions_wageGrowthTracker.title.text =
          "Wage Growth Tracker by Hourly or Weekly Earnings";
        break;
      case "ethnicity":
	  
//	    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
 //       chart_wageGrowthTracker.xAxis[0].addPlotBand(mma12);
	  
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Overall",
          data: TwelveMonthMovingAverage,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "White",
          data: ethnicity_White,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[2] = {
          name: "Non-white",
          data: ethnicity_NonWhite,
          visible: true,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_wageGrowthTracker";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.26;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.subtitle.text =
          "12-month moving averages of median wage growth, hourly data";
        chartOptions_wageGrowthTracker.title.text =
          "Wage Growth Tracker by Race";
        break;
      case "education":
	  
//	    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
 //       chart_wageGrowthTracker.xAxis[0].addPlotBand(mma12);
		
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Overall",
          data: TwelveMonthMovingAverage,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "High school",
          data: education_HighSchool,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[2] = {
          name: "Associate's degree",
          data: education_Associates,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[3] = {
          name: "Bachelor's degree",
          data: education_Bachelors,
          visible: true,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_wageGrowthTracker";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.4;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.subtitle.text =
          "12-month moving averages of median wage growth, hourly data";
        chartOptions_wageGrowthTracker.title.text =
          "Wage Growth Tracker by Education";
        break;
      case "age":
	  
//	    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
//        chart_wageGrowthTracker.xAxis[0].addPlotBand(mma12);
	  
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Overall",
          data: TwelveMonthMovingAverage,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "16-24",
          data: age_16to24,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[2] = {
          name: "25-54",
          data: age_25to54,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[3] = {
          name: "55+",
          data: age_55plus,
          visible: true,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_wageGrowthTracker";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.2;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.subtitle.text =
          "12-month moving averages of median wage growth, hourly data";
        chartOptions_wageGrowthTracker.title.text =
          "Wage Growth Tracker by Age";
        break;
      case "census":
	   
//	    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
//        chart_wageGrowthTracker.xAxis[0].addPlotBand(mma12);
	  
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Overall",
          data: TwelveMonthMovingAverage,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "New England",
          data: census_NewEngland,
          visible: false,
        };
        chartOptions_wageGrowthTracker.series[2] = {
          name: "Middle Atlantic",
          data: census_MiddleAtlantic,
          visible: false,
        };
        chartOptions_wageGrowthTracker.series[3] = {
          name: "East North Central",
          data: census_EastNorthCentral,
          visible: false,
        };
        chartOptions_wageGrowthTracker.series[4] = {
          name: "West North Central",
          data: census_WestNorthCentral,
          visible: false,
        };
        chartOptions_wageGrowthTracker.series[5] = {
          name: "South Atlantic",
          data: census_SouthAtlantic,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[6] = {
          name: "East South Central",
          data: census_EastSouthCentral,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[7] = {
          name: "West South Central",
          data: census_WestSouthCentral,
          visible: false,
        };
        chartOptions_wageGrowthTracker.series[8] = {
          name: "Mountain",
          data: census_Mountain,
          visible: false,
        };
        chartOptions_wageGrowthTracker.series[9] = {
          name: "Pacific",
          data: census_Pacific,
          visible: false,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_wageGrowthTracker";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.26;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.subtitle.text =
          "12-month moving averages of median wage growth, hourly data";
        chartOptions_wageGrowthTracker.title.text =
          "Wage Growth Tracker by Census Division";
        break;
      case "occupation":
	  
//	    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
 //       chart_wageGrowthTracker.xAxis[0].addPlotBand(mma12);
	  
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Overall",
          data: TwelveMonthMovingAverage,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "High Skill",
          data: occupation_HighSkill,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[2] = {
          name: "Low Skill",
          data: occupation_LowSkill,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[3] = {
          name: "Mid Skill",
          data: occupation_MidSkill,
          visible: true,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_wageGrowthTracker";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.2;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.subtitle.text =
          "12-month moving averages of median wage growth, hourly data";
        chartOptions_wageGrowthTracker.title.text =
          "Wage Growth Tracker by Occupation";
        break;
      case "industry":
	  
//	    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
 //       chart_wageGrowthTracker.xAxis[0].addPlotBand(mma12);
	  
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Overall",
          data: TwelveMonthMovingAverage,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "Construction and mining",
          data: industry_ConstructionMining,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[2] = {
          name: "Education and health",
          data: industry_EducationHealth,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[3] = {
          name: "Finance and business services",
          data: industry_FinancialServices,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[4] = {
          name: "Leisure and hospitality",
          data: industry_LeisureHospitality,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[5] = {
          name: "Manufacturing",
          data: industry_Manufacturing,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[6] = {
          name: "Public administration",
          data: industry_PublicAdministration,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[7] = {
          name: "Trade and transportation",
          data: industry_TradeUtilities,
          visible: true,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_wageGrowthTracker";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.4;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.subtitle.text =
          "12-month moving averages of median wage growth, hourly data";
        chartOptions_wageGrowthTracker.title.text =
          "Wage Growth Tracker by Industry";
        break;
      case "uftpt":
	    
//	    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
//        chart_wageGrowthTracker.xAxis[0].addPlotBand(mma12);
	  
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Overall",
          data: TwelveMonthMovingAverage,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "Full-time",
          data: UFTPT_FullTime,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[2] = {
          name: "Part-time",
          data: UFTPT_PartTime,
          visible: true,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_wageGrowthTracker";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.26;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.subtitle.text =
          "12-month moving averages of median wage growth, hourly data";
        chartOptions_wageGrowthTracker.title.text =
          "Wage Growth Tracker by Full-Time or Part-Time";
        break;
      case "msa":
	  
//	    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
//        chart_wageGrowthTracker.xAxis[0].addPlotBand(mma12);
		
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Overall",
          data: TwelveMonthMovingAverage,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "MSA",
          data: MSA,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[2] = {
          name: "Non-MSA",
          data: NonMSA,
          visible: true,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_wageGrowthTracker";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.26;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.subtitle.text =
          "12-month moving averages of median wage growth, hourly data";
        chartOptions_wageGrowthTracker.title.text =
          "Wage Growth Tracker by MSA or Non-MSA";
        break;
      case "gender":
	  
//	    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
//        chart_wageGrowthTracker.xAxis[0].addPlotBand(mma12);
		
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Overall",
          data: TwelveMonthMovingAverage,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "Female",
          data: gender_Female,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[2] = {
          name: "Male",
          data: gender_Male,
          visible: true,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_wageGrowthTracker";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.26;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.subtitle.text =
          "12-month moving average of median wage growth, hourly data";
        chartOptions_wageGrowthTracker.title.text =
          "Wage Growth Tracker by Gender";
        break;
      case "job":
	  
//	    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
//        chart_wageGrowthTracker.xAxis[0].addPlotBand(mma12);
		
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Overall",
          data: TwelveMonthMovingAverage,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "Job stayer",
          data: job_Stayer,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[2] = {
          name: "Job switcher",
          data: job_Switcher,
          visible: true,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_wageGrowthTracker";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.26;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.subtitle.text =
          "12-month moving average of median wage growth, hourly data";
        chartOptions_wageGrowthTracker.title.text =
          "Wage Growth Tracker by Job Switcher/Stayer";
        break;
      case "wagelevel":
	  
//	    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
//        chart_wageGrowthTracker.xAxis[0].addPlotBand(mma12);
	  
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Overall",
          data: TwelveMonthMovingAverage,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "1st quartile",
          data: WageLevel1st,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[2] = {
          name: "2nd quartile",
          data: WageLevel2nd,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[3] = {
          name: "3rd quartile",
          data: WageLevel3rd,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[4] = {
          name: "4th quartile",
          data: WageLevel4th,
          visible: true,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_wageGrowthTracker";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.26;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.subtitle.text =
          "12-month moving average of median wage growth for each category, hourly data";
        chartOptions_wageGrowthTracker.title.text =
          "Wage Growth Tracker by Wage Level";
        break;
      case "paidhourly":
	  
//	    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
//        chart_wageGrowthTracker.xAxis[0].addPlotBand(mma12);
	  
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Overall",
          data: TwelveMonthMovingAverage,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "Paid hourly",
          data: PaidHourly,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[2] = {
          name: "Not paid hourly",
          data: NotPaidHourly,
          visible: true,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_wageGrowthTracker";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.26;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.subtitle.text =
          "12-month moving average of median wage growth, hourly data";
        chartOptions_wageGrowthTracker.title.text =
          "Wage Growth Tracker by Hourly Pay";
        break;
      case "chart1":
	  
//	    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
//        chart_wageGrowthTracker.xAxis[0].addPlotBand(mma3);
	  
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Smoothed (3 month-average)",
          data: chart1_Smoothed,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "Non-smoothed",
          data: chart1_NonSmoothed,
          visible: true,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_medianWageGrowth";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.4;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.subtitle.text = "";
        chartOptions_wageGrowthTracker.title.text = "Median Wage Growth";
        break;
      case "chart2":
	  
//	    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
  //      chart_wageGrowthTracker.xAxis[0].addPlotBand(mma12);
		
        chartOptions_wageGrowthTracker.series[0] = {
          name: "25th percentile",
          data: chart2_25thPct,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "75th percentile",
          data: chart2_75thPct,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[2] = {
          name: "Median",
          data: chart2_Median,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[3] = {
          name: "Average",
          data: chart2_Average,
          visible: true,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_individualWageGrowth";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.4;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.yAxis.min = null;
        chartOptions_wageGrowthTracker.yAxis.tickInterval = 5;
        chartOptions_wageGrowthTracker.subtitle.text = "";
        chartOptions_wageGrowthTracker.title.text =
          "Chart 1<br />Distribution of Individual Wage Growth";
        break;
      case "chart3":
	  
//	    chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
 //       chart_wageGrowthTracker.xAxis[0].addPlotBand(mma12);
	  
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Median wage growth",
          data: chart3_MedianWageGrowth,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "Zero wage change",
          data: chart3_ZeroWageChange,
          visible: true,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_zeroWageChange";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.4;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.yAxis.tickInterval = 5;
        chartOptions_wageGrowthTracker.subtitle.text = "";
        chartOptions_wageGrowthTracker.title.text =
          "Chart 2<br />Percent of Individuals with Zero Wage Change";
        break;
      default:
/*	  
	    if(chart_wageGrowthTracker != '') {
			chart_wageGrowthTracker.xAxis[0].removePlotBand("break");
			chart_wageGrowthTracker.xAxis[0].addPlotBand(mma3);
		}
*/	  
        chartOptions_wageGrowthTracker.series[0] = {
          name: "Overall unweighted",
          data: chart_overall,
          visible: true,
        };
        chartOptions_wageGrowthTracker.series[1] = {
          name: "Services",
          data: chart_services,
          visible: false,
        };
        chartOptions_wageGrowthTracker.series[2] = {
          name: "Usually full-time",
          data: chart_fulltime,
          visible: false,
        };
        chartOptions_wageGrowthTracker.series[3] = {
          name: "College degree",
          data: chart_college,
          visible: false,
        };
        chartOptions_wageGrowthTracker.series[4] = {
          name: "Prime-age",
          data: chart_primeage,
          visible: false,
        };
        chartOptions_wageGrowthTracker.series[5] = {
          name: "Female",
          data: chart_female,
          visible: false,
        };
        chartOptions_wageGrowthTracker.series[6] = {
          name: "Male",
          data: chart_male,
          visible: false,
        };
        chartOptions_wageGrowthTracker.series[7] = {
          name: "Job stayer",
          data: chart_jobStayer,
          visible: false,
        };
        chartOptions_wageGrowthTracker.series[8] = {
          name: "Job switcher",
          data: chart_jobSwitcher,
          visible: false,
        };
        chartOptions_wageGrowthTracker.series[9] = {
          name: "Paid hourly",
          data: chart_paidHourly,
          visible: false,
        };
        chartOptions_wageGrowthTracker.series[10] = {
          pointStart: Date.UTC(1983, 0, 1),
          name: "Overall, back to 1983",
          data: chart_1983Smoothed,
          visible: false,
        };
        chartOptions_wageGrowthTracker.chart.renderTo =
          "container_wageGrowthTracker";
        chartOptions_wageGrowthTracker.legend.itemWidth =
          iframeWidth_wageGrowthTracker * 0.26;
        chartOptions_wageGrowthTracker.legend.width =
          iframeWidth_wageGrowthTracker * 0.8;
        chartOptions_wageGrowthTracker.subtitle.text =
          "three-month moving average of median wage growth, hourly data";
        chartOptions_wageGrowthTracker.title.text = "Wage Growth Tracker";
        break;
    }

   
   /* draw the chart, then add the source line and branding */
    setChartDefaults(
      iframeWidth_wageGrowthTracker,
      iframeHeight_wageGrowthTracker,
      sourceLine_wageGrowthTracker,
      50
    );
		
	chart_wageGrowthTracker = new Highcharts.Chart(
      chartOptions_wageGrowthTracker
    );    

	setChartBranding(
      chart_wageGrowthTracker,
      iframeWidth_wageGrowthTracker,
      iframeHeight_wageGrowthTracker,
      sourceLine_wageGrowthTracker,
      55
    );

	 /* code to handle the picker/slider element */
    if ($(".datePickerSlider").length > 0) {
	
	if(sliderMinHistory == 0 && sliderMaxHistory ==0 ) {
	   sliderMinHistory = PickerMaxDefault - 60;
	   sliderMaxHistory = PickerMaxDefault;
	}
  
  
    $(".datePickerSlider")
      .slider({
        range: true,
        min: 0,
        max: PickerMaxDefault,
        values: [sliderMinHistory, sliderMaxHistory],
	// use to be change	
        stop: function (event, ui) {
              
              sliderMinHistory = ui.values[0];
	      sliderMaxHistory = ui.values[1];
              
              	
              	PickerMaxDate = chart_dates[sliderMaxHistory].split("/");
    		PickerMinDate = chart_dates[sliderMinHistory].split("/");
    		var PickerMaxDateUTCTemp = Date.UTC(
      			PickerMaxDate[2],
      			PickerMaxDate[0] - 1,
      			PickerMaxDate[1]
    		);
    		var PickerMinDateUTCTemp = Date.UTC(
      			PickerMinDate[2],
      			PickerMinDate[0] - 1,
      			PickerMinDate[1]
    		);
	
    		//drawChart_wageGrowthTracker($("#chartOptions option:selected").val());
                drawChart_wageGrowthTracker($('.buttonActive')[0].getAttribute("chartview"));

	
    		chart_wageGrowthTracker.xAxis[0].setExtremes(
		  PickerMinDateUTCTemp,
		  PickerMaxDateUTCTemp
		);

	      
        }
        /* add labels to the picker; this addendum needs the "jQuery UI Slider Pips and Floats" library added to work */
      })
      .slider("float", { labels: PickerLabels });

    /* reset the chart back to the default date range */
    $(".datePickerWrap input[type='button']").click(function (e) {
       
      $(".datePickerSlider").slider("values", [
        PickerMinDefault,
        PickerMaxDefault,
      ]);

      sliderMinHistory = PickerMinDefault
      sliderMaxHistory = PickerMaxDefault,
                       	
              	setChartRange(PickerMinDefault, PickerMaxDefault);
              	
              	PickerMaxDate = chart_dates[sliderMaxHistory].split("/");
    		PickerMinDate = chart_dates[sliderMinHistory].split("/");
    		var PickerMaxDateUTCTemp = Date.UTC(
      			PickerMaxDate[2],
      			PickerMaxDate[0] - 1,
      			PickerMaxDate[1]
    		);
    		var PickerMinDateUTCTemp = Date.UTC(
      			PickerMinDate[2],
      			PickerMinDate[0] - 1,
      			PickerMinDate[1]
    		);
	
    		//_wageGrowthTracker($("#chartOptions option:selected").val());
                drawChart_wageGrowthTracker($('.buttonActive')[0].getAttribute("chartview"));

	
    		chart_wageGrowthTracker.xAxis[0].setExtremes(
		  PickerMinDateUTCTemp,
		  PickerMaxDateUTCTemp
		);

    });
  }
  
  /* function to set the extremes of the chart based on values */
  function setChartRange(thisMin, thisMax) {
  
    PickerMaxDate = chart_dates[thisMax].split("/");
    PickerMinDate = chart_dates[thisMin].split("/");
    PickerMaxDateUTC = Date.UTC(
      PickerMaxDate[2],
      PickerMaxDate[0] - 1,
      PickerMaxDate[1]
    );
    PickerMinDateUTC = Date.UTC(
      PickerMinDate[2],
      PickerMinDate[0] - 1,
      PickerMinDate[1]
    );
	
	if(chart_wageGrowthTracker.xAxis[0] != 'undefined') {
		chart_wageGrowthTracker.xAxis[0].setExtremes(
		  PickerMinDateUTC,
		  PickerMaxDateUTC
		);
	}
    
  }

  
  /* set the chart on page load */
 

    /* fix to resolve bug that clears certain axis settings when chart viewed in mobile/smaller viewport */
    chart_wageGrowthTracker.xAxis[0].update({
      labels: { y: 20 },
      type: "datetime",
      plotBands: mma3,
    });
    chart_wageGrowthTracker.yAxis[0].update({
      title: { text: "Percent" },
    });
	
	// juicy
	setChartRange(PickerMinDefault, PickerMaxDefault);

	//drawChart_wageGrowthTracker($("#chartOptions option:selected").val()); // EDB

    /* add extra menu item (will be applied to all charts on this page) */
    Highcharts.getOptions().exporting.buttons.contextButton.menuItems.push({
      text: "Download Excel spreadsheet",
      onclick: function () {
        window.open(
          "/-/media/Documents/datafiles/chcs/wage-growth-tracker/wage-growth-data.xlsx?la=en"
        );
        thisTitle = this.options.title.text;
        newTitle = thisTitle.replace("<br>", ": ");
        newTitle = thisTitle.replace("<br />", ": ");
        window.dataLayer = window.dataLayer || [];
        window.dataLayer.push({
          event: "Highcharts",
          category: "Highcharts",
          action: "excel",
          label: newTitle + " | " + document.title,
        });
      },
    });
  }

  /* update the display date <div> with the formatted date */
  var monthNames = [
    "January",
    "February",
    "March",
    "April",
    "May",
    "June",
    "July",
    "August",
    "September",
    "October",
    "November",
    "December",
  ];
  var date = new Date(updateDate);
  $("#dateUpdated").html(
    "Updated on " +
      monthNames[date.getMonth()] +
      " " +
      date.getDate() +
      ", " +
      date.getFullYear()
  );

  /* user changes the chart type */
  $("#chartOptions").change(function () {
    drawChart_wageGrowthTracker($("#chartOptions option:selected").val());	
  });

  /* switch between chart views whenever a user clicks on the buttons */
  $(".trackerOptions").click(function (e) {
    e.preventDefault();
    $(".trackerOptions").removeClass("buttonActive");
    $(this).addClass("buttonActive");
    chartview = $(this).attr("chartview");
			
	PickerMaxDate = chart_dates[sliderMaxHistory].split("/");
    PickerMinDate = chart_dates[sliderMinHistory].split("/");
    var PickerMaxDateUTCTemp = Date.UTC(
      PickerMaxDate[2],
      PickerMaxDate[0] - 1,
      PickerMaxDate[1]
    );
    var PickerMinDateUTCTemp = Date.UTC(
      PickerMinDate[2],
      PickerMinDate[0] - 1,
      PickerMinDate[1]
    );
	
    drawChart_wageGrowthTracker(chartview);
	
    chart_wageGrowthTracker.xAxis[0].setExtremes(
		  PickerMinDateUTCTemp,
		  PickerMaxDateUTCTemp
		);
  });

  /* load charts when a tab or accordion is clicked */
  $(".tabHead li>a")
    .add(".tabBody li>a")
    .click(function () {

      activeTab = $(this).attr("href");
      drawChart_wageGrowthTracker();
      drawChart_wageGrowthTracker("chart1");
      drawChart_wageGrowthTracker("chart2");
      drawChart_wageGrowthTracker("chart3");
    });

$(".nav-tabs li>a")
    .add(".tabBody li>a")
    .click(function () {
      activeTab = $(this).attr("href");
      drawChart_wageGrowthTracker();
      drawChart_wageGrowthTracker("chart1");
      drawChart_wageGrowthTracker("chart2");
      drawChart_wageGrowthTracker("chart3");
    });

  /* draw charts when the browser window is loaded or resized (see https://stackoverflow.com/a/1974797/2596103) */
  $(window)
    .on("resize", function () {
      if ($("#content-object-tab").width() < 700) {
        $('.wageGrowthCharts').width(parseInt($('#content-object-tab').width()));
        $(".wageGrowthCharts").height(500);

        chartOptions_wageGrowthTracker.legend.verticalAlign = "top";
        chartOptions_wageGrowthTracker.legend.x= -20;
        chartOptions_wageGrowthTracker.legend.y= 0;

      } else {
        //$(".wageGrowthCharts").width(parseInt($(".tabs").width() * 0.75));
        $('.wageGrowthCharts').width(parseInt($('#content-object-tab').width() * 0.75));
        $(".wageGrowthCharts").height(500);
         chartOptions_wageGrowthTracker.legend.verticalAlign = "bottom";
         chartOptions_wageGrowthTracker.legend.x= -50;
         chartOptions_wageGrowthTracker.legend.y= 120;
      }
         drawChart_wageGrowthTracker($('.buttonActive')[0].getAttribute("chartview"));

    })
    .resize();	
});

$(function() {
	const isNumericInput = (event) => {
		const key = event.keyCode;
		return ((key >= 48 && key <= 57) || // Allow number line
			(key >= 96 && key <= 105) // Allow number pad
		);
	};

	const isModifierKey = (event) => {
		const key = event.keyCode;
		return (event.shiftKey === true || key === 35 || key === 36) || // Allow Shift, Home, End
			(key === 8 || key === 9 || key === 13 || key === 46) || // Allow Backspace, Tab, Enter, Delete
			(key > 36 && key < 41) || // Allow left, up, right, down
			(
				// Allow Ctrl/Command + A,C,V,X,Z
				(event.ctrlKey === true || event.metaKey === true) &&
				(key === 65 || key === 67 || key === 86 || key === 88 || key === 90)
			)
	};

	const enforceFormat = (event) => {
		// Input must be of a valid number format or a modifier key, and not longer than ten digits
		if(!isNumericInput(event) && !isModifierKey(event)){
			event.preventDefault();
		}
	};

	const formatToPhone = (event) => {
		if(isModifierKey(event)) {return;}

		const target = event.target;
		const input = event.target.value.replace(/\D/g,'').substring(0,10); // First ten digits of input only
		const areaCode = input.substring(0,3);
		const middle = input.substring(3,6);
		const last = input.substring(6,10);

		if(input.length > 6){target.value = `${areaCode}-${middle}-${last}`;}
		else if(input.length > 3){target.value = `${areaCode}-${middle}`;}
		else if(input.length > 0){target.value = `${areaCode}`;}
	};

	let inputElements = document.querySelectorAll('.phone-number-formatting');

	inputElements.forEach((item) => {
		item.addEventListener('keydown',enforceFormat);
		item.addEventListener('keyup',formatToPhone);
	});
});
$(document).ready(function(){
    // bootsrtap tab control setup
    $('.nav-tabs a').click(function (e) {
      e.preventDefault();
      $(this).tab('show');
    });
    // Manage HISTORY (back button behavior) for tabs
    // add a hash to the URL when the user clicks on a tab
    // relies on https://github.com/devote/HTML5-History-API/ to support pushState()
    $('a[data-toggle="tab"]').on('click', function(e) {
      history.pushState(null, null, $(this).attr('href'));
    });
    // // navigate to a tab when the history changes
    showTabFromUrl = function(e) {
      if (location.hash.substr(0,3)=="#/#") {
        hashToUse = location.hash.substr(2);
      } else {
        hashToUse = location.hash;
      }
      var activeTab = $('[href="' + hashToUse + '"]');
      if (activeTab.length) {
        activeTab.tab('show');
      } else {
        $('.nav-tabs a:first').tab('show');
      }
    }
    // cross-browser call to bind showTab
    if (!window.addEventListener) {
      window.attachEvent("popstate", showTabFromUrl);
    } else {
      window.addEventListener("popstate", showTabFromUrl, false);
    }

    showTabFromUrl();

  });// doc ready

 