From fed611bd9ee125673529ac3005e7a7625c62e2bc Mon Sep 17 00:00:00 2001 From: Clay Diffrient Date: Thu, 14 Apr 2016 23:30:45 -0600 Subject: [PATCH] release v1.1.1 --- CHANGELOG.md | 6 + bower.json | 2 +- dist/react-modal.js | 1887 +-------------------------------------- dist/react-modal.min.js | 18 +- package.json | 4 +- 5 files changed, 43 insertions(+), 1874 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 50e83b79..d2d4b87f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,9 @@ +v1.1.1 - Fri, 15 Apr 2016 05:30:45 GMT +-------------------------------------- + +- + + v1.1.0 - Tue, 12 Apr 2016 13:03:08 GMT -------------------------------------- diff --git a/bower.json b/bower.json index f852c351..ad7d58e3 100644 --- a/bower.json +++ b/bower.json @@ -1,6 +1,6 @@ { "name": "react-modal", - "version": "1.1.0", + "version": "1.1.1", "homepage": "https://github.com/rackt/react-modal", "authors": [ "Ryan Florence", diff --git a/dist/react-modal.js b/dist/react-modal.js index f2e85c65..f16e70c2 100644 --- a/dist/react-modal.js +++ b/dist/react-modal.js @@ -1,1870 +1,17 @@ -(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.ReactModal = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o 0) - this.closeWithTimeout(); - else - this.closeWithoutTimeout(); - }, - - focusContent: function() { - this.refs.content.focus(); - }, - - closeWithTimeout: function() { - this.setState({beforeClose: true}, function() { - this.closeTimer = setTimeout(this.closeWithoutTimeout, this.props.closeTimeoutMS); - }.bind(this)); - }, - - closeWithoutTimeout: function() { - this.setState({ - afterOpen: false, - beforeClose: false - }, this.afterClose); - }, - - afterClose: function() { - focusManager.returnFocus(); - focusManager.teardownScopedFocus(); - }, - - handleKeyDown: function(event) { - if (event.keyCode == 9 /*tab*/) scopeTab(this.refs.content, event); - if (event.keyCode == 27 /*esc*/) { - event.preventDefault(); - this.requestClose(); - } - }, - - handleOverlayClick: function(event) { - var node = event.target - - while (node) { - if (node === this.refs.content) return - node = node.parentNode - } - - if (this.props.shouldCloseOnOverlayClick) { - if (this.ownerHandlesClose()) - this.requestClose(); - else - this.focusContent(); - } - }, - - requestClose: function() { - if (this.ownerHandlesClose()) - this.props.onRequestClose(); - }, - - ownerHandlesClose: function() { - return this.props.onRequestClose; - }, - - shouldBeClosed: function() { - return !this.props.isOpen && !this.state.beforeClose; - }, - - buildClassName: function(which, additional) { - var className = CLASS_NAMES[which].base; - if (this.state.afterOpen) - className += ' '+CLASS_NAMES[which].afterOpen; - if (this.state.beforeClose) - className += ' '+CLASS_NAMES[which].beforeClose; - return additional ? className + ' ' + additional : className; - }, - - render: function() { - var contentStyles = (this.props.className) ? {} : this.props.defaultStyles.content; - var overlayStyles = (this.props.overlayClassName) ? {} : this.props.defaultStyles.overlay; - - return this.shouldBeClosed() ? div() : ( - div({ - ref: "overlay", - className: this.buildClassName('overlay', this.props.overlayClassName), - style: Assign({}, overlayStyles, this.props.style.overlay || {}), - onClick: this.handleOverlayClick - }, - div({ - ref: "content", - style: Assign({}, contentStyles, this.props.style.content || {}), - className: this.buildClassName('content', this.props.className), - tabIndex: "-1", - onKeyDown: this.handleKeyDown - }, - this.props.children - ) - ) - ); - } -}); - -},{"../helpers/focusManager":4,"../helpers/scopeTab":5,"lodash.assign":16}],3:[function(require,module,exports){ -var _element = typeof document !== 'undefined' ? document.body : null; - -function setElement(element) { - if (typeof element === 'string') { - var el = document.querySelectorAll(element); - element = 'length' in el ? el[0] : el; - } - _element = element || _element; - return _element; -} - -function hide(appElement) { - validateElement(appElement); - (appElement || _element).setAttribute('aria-hidden', 'true'); -} - -function show(appElement) { - validateElement(appElement); - (appElement || _element).removeAttribute('aria-hidden'); -} - -function toggle(shouldHide, appElement) { - if (shouldHide) - hide(appElement); - else - show(appElement); -} - -function validateElement(appElement) { - if (!appElement && !_element) - throw new Error('react-modal: You must set an element with `Modal.setAppElement(el)` to make this accessible'); -} - -function resetForTesting() { - _element = document.body; -} - -exports.toggle = toggle; -exports.setElement = setElement; -exports.show = show; -exports.hide = hide; -exports.resetForTesting = resetForTesting; - -},{}],4:[function(require,module,exports){ -var findTabbable = require('../helpers/tabbable'); -var modalElement = null; -var focusLaterElement = null; -var needToFocus = false; - -function handleBlur(event) { - needToFocus = true; -} - -function handleFocus(event) { - if (needToFocus) { - needToFocus = false; - if (!modalElement) { - return; - } - // need to see how jQuery shims document.on('focusin') so we don't need the - // setTimeout, firefox doesn't support focusin, if it did, we could focus - // the element outside of a setTimeout. Side-effect of this implementation - // is that the document.body gets focus, and then we focus our element right - // after, seems fine. - setTimeout(function() { - if (modalElement.contains(document.activeElement)) - return; - var el = (findTabbable(modalElement)[0] || modalElement); - el.focus(); - }, 0); - } -} - -exports.markForFocusLater = function() { - focusLaterElement = document.activeElement; -}; - -exports.returnFocus = function() { - try { - focusLaterElement.focus(); - } - catch (e) { - console.warn('You tried to return focus to '+focusLaterElement+' but it is not in the DOM anymore'); - } - focusLaterElement = null; -}; - -exports.setupScopedFocus = function(element) { - modalElement = element; - - if (window.addEventListener) { - window.addEventListener('blur', handleBlur, false); - document.addEventListener('focus', handleFocus, true); - } else { - window.attachEvent('onBlur', handleBlur); - document.attachEvent('onFocus', handleFocus); - } -}; - -exports.teardownScopedFocus = function() { - modalElement = null; - - if (window.addEventListener) { - window.removeEventListener('blur', handleBlur); - document.removeEventListener('focus', handleFocus); - } else { - window.detachEvent('onBlur', handleBlur); - document.detachEvent('onFocus', handleFocus); - } -}; - -},{"../helpers/tabbable":6}],5:[function(require,module,exports){ -var findTabbable = require('../helpers/tabbable'); - -module.exports = function(node, event) { - var tabbable = findTabbable(node); - if (!tabbable.length) { - event.preventDefault(); - return; - } - var finalTabbable = tabbable[event.shiftKey ? 0 : tabbable.length - 1]; - var leavingFinalTabbable = ( - finalTabbable === document.activeElement || - // handle immediate shift+tab after opening with mouse - node === document.activeElement - ); - if (!leavingFinalTabbable) return; - event.preventDefault(); - var target = tabbable[event.shiftKey ? tabbable.length - 1 : 0]; - target.focus(); -}; - -},{"../helpers/tabbable":6}],6:[function(require,module,exports){ -/*! - * Adapted from jQuery UI core - * - * http://jqueryui.com - * - * Copyright 2014 jQuery Foundation and other contributors - * Released under the MIT license. - * http://jquery.org/license - * - * http://api.jqueryui.com/category/ui-core/ - */ - -function focusable(element, isTabIndexNotNaN) { - var nodeName = element.nodeName.toLowerCase(); - return (/input|select|textarea|button|object/.test(nodeName) ? - !element.disabled : - "a" === nodeName ? - element.href || isTabIndexNotNaN : - isTabIndexNotNaN) && visible(element); -} - -function hidden(el) { - return (el.offsetWidth <= 0 && el.offsetHeight <= 0) || - el.style.display === 'none'; -} - -function visible(element) { - while (element) { - if (element === document.body) break; - if (hidden(element)) return false; - element = element.parentNode; - } - return true; -} - -function tabbable(element) { - var tabIndex = element.getAttribute('tabindex'); - if (tabIndex === null) tabIndex = undefined; - var isTabIndexNaN = isNaN(tabIndex); - return (isTabIndexNaN || tabIndex >= 0) && focusable(element, !isTabIndexNaN); -} - -function findTabbableDescendants(element) { - return [].slice.call(element.querySelectorAll('*'), 0).filter(function(el) { - return tabbable(el); - }); -} - -module.exports = findTabbableDescendants; - -},{}],7:[function(require,module,exports){ -module.exports = require('./components/Modal'); - -},{"./components/Modal":1}],8:[function(require,module,exports){ -module.exports = function(opts) { - return new ElementClass(opts) -} - -function indexOf(arr, prop) { - if (arr.indexOf) return arr.indexOf(prop) - for (var i = 0, len = arr.length; i < len; i++) - if (arr[i] === prop) return i - return -1 -} - -function ElementClass(opts) { - if (!(this instanceof ElementClass)) return new ElementClass(opts) - var self = this - if (!opts) opts = {} - - // similar doing instanceof HTMLElement but works in IE8 - if (opts.nodeType) opts = {el: opts} - - this.opts = opts - this.el = opts.el || document.body - if (typeof this.el !== 'object') this.el = document.querySelector(this.el) -} - -ElementClass.prototype.add = function(className) { - var el = this.el - if (!el) return - if (el.className === "") return el.className = className - var classes = el.className.split(' ') - if (indexOf(classes, className) > -1) return classes - classes.push(className) - el.className = classes.join(' ') - return classes -} - -ElementClass.prototype.remove = function(className) { - var el = this.el - if (!el) return - if (el.className === "") return - var classes = el.className.split(' ') - var idx = indexOf(classes, className) - if (idx > -1) classes.splice(idx, 1) - el.className = classes.join(' ') - return classes -} - -ElementClass.prototype.has = function(className) { - var el = this.el - if (!el) return - var classes = el.className.split(' ') - return indexOf(classes, className) > -1 -} - -ElementClass.prototype.toggle = function(className) { - var el = this.el - if (!el) return - if (this.has(className)) this.remove(className) - else this.add(className) -} - -},{}],9:[function(require,module,exports){ -/*! - Copyright (c) 2015 Jed Watson. - Based on code that is Copyright 2013-2015, Facebook, Inc. - All rights reserved. -*/ - -(function () { - 'use strict'; - - var canUseDOM = !!( - typeof window !== 'undefined' && - window.document && - window.document.createElement - ); - - var ExecutionEnvironment = { - - canUseDOM: canUseDOM, - - canUseWorkers: typeof Worker !== 'undefined', - - canUseEventListeners: - canUseDOM && !!(window.addEventListener || window.attachEvent), - - canUseViewport: canUseDOM && !!window.screen - - }; - - if (typeof define === 'function' && typeof define.amd === 'object' && define.amd) { - define(function () { - return ExecutionEnvironment; - }); - } else if (typeof module !== 'undefined' && module.exports) { - module.exports = ExecutionEnvironment; - } else { - window.ExecutionEnvironment = ExecutionEnvironment; - } - -}()); - -},{}],10:[function(require,module,exports){ -/** - * lodash 3.2.0 (Custom Build) - * Build: `lodash modern modularize exports="npm" -o ./` - * Copyright 2012-2015 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */ -var baseCopy = require('lodash._basecopy'), - keys = require('lodash.keys'); - -/** - * The base implementation of `_.assign` without support for argument juggling, - * multiple sources, and `customizer` functions. - * - * @private - * @param {Object} object The destination object. - * @param {Object} source The source object. - * @returns {Object} Returns `object`. - */ -function baseAssign(object, source) { - return source == null - ? object - : baseCopy(source, keys(source), object); -} - -module.exports = baseAssign; - -},{"lodash._basecopy":11,"lodash.keys":19}],11:[function(require,module,exports){ -/** - * lodash 3.0.1 (Custom Build) - * Build: `lodash modern modularize exports="npm" -o ./` - * Copyright 2012-2015 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */ - -/** - * Copies properties of `source` to `object`. - * - * @private - * @param {Object} source The object to copy properties from. - * @param {Array} props The property names to copy. - * @param {Object} [object={}] The object to copy properties to. - * @returns {Object} Returns `object`. - */ -function baseCopy(source, props, object) { - object || (object = {}); - - var index = -1, - length = props.length; - - while (++index < length) { - var key = props[index]; - object[key] = source[key]; - } - return object; -} - -module.exports = baseCopy; - -},{}],12:[function(require,module,exports){ -/** - * lodash 3.0.1 (Custom Build) - * Build: `lodash modern modularize exports="npm" -o ./` - * Copyright 2012-2015 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */ - -/** - * A specialized version of `baseCallback` which only supports `this` binding - * and specifying the number of arguments to provide to `func`. - * - * @private - * @param {Function} func The function to bind. - * @param {*} thisArg The `this` binding of `func`. - * @param {number} [argCount] The number of arguments to provide to `func`. - * @returns {Function} Returns the callback. - */ -function bindCallback(func, thisArg, argCount) { - if (typeof func != 'function') { - return identity; - } - if (thisArg === undefined) { - return func; - } - switch (argCount) { - case 1: return function(value) { - return func.call(thisArg, value); - }; - case 3: return function(value, index, collection) { - return func.call(thisArg, value, index, collection); - }; - case 4: return function(accumulator, value, index, collection) { - return func.call(thisArg, accumulator, value, index, collection); - }; - case 5: return function(value, other, key, object, source) { - return func.call(thisArg, value, other, key, object, source); - }; - } - return function() { - return func.apply(thisArg, arguments); - }; -} - -/** - * This method returns the first argument provided to it. - * - * @static - * @memberOf _ - * @category Utility - * @param {*} value Any value. - * @returns {*} Returns `value`. - * @example - * - * var object = { 'user': 'fred' }; - * - * _.identity(object) === object; - * // => true - */ -function identity(value) { - return value; -} - -module.exports = bindCallback; - -},{}],13:[function(require,module,exports){ -/** - * lodash 3.1.1 (Custom Build) - * Build: `lodash modern modularize exports="npm" -o ./` - * Copyright 2012-2015 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */ -var bindCallback = require('lodash._bindcallback'), - isIterateeCall = require('lodash._isiterateecall'), - restParam = require('lodash.restparam'); - -/** - * Creates a function that assigns properties of source object(s) to a given - * destination object. - * - * **Note:** This function is used to create `_.assign`, `_.defaults`, and `_.merge`. - * - * @private - * @param {Function} assigner The function to assign values. - * @returns {Function} Returns the new assigner function. - */ -function createAssigner(assigner) { - return restParam(function(object, sources) { - var index = -1, - length = object == null ? 0 : sources.length, - customizer = length > 2 ? sources[length - 2] : undefined, - guard = length > 2 ? sources[2] : undefined, - thisArg = length > 1 ? sources[length - 1] : undefined; - - if (typeof customizer == 'function') { - customizer = bindCallback(customizer, thisArg, 5); - length -= 2; - } else { - customizer = typeof thisArg == 'function' ? thisArg : undefined; - length -= (customizer ? 1 : 0); - } - if (guard && isIterateeCall(sources[0], sources[1], guard)) { - customizer = length < 3 ? undefined : customizer; - length = 1; - } - while (++index < length) { - var source = sources[index]; - if (source) { - assigner(object, source, customizer); - } - } - return object; - }); -} - -module.exports = createAssigner; - -},{"lodash._bindcallback":12,"lodash._isiterateecall":15,"lodash.restparam":20}],14:[function(require,module,exports){ -/** - * lodash 3.9.1 (Custom Build) - * Build: `lodash modern modularize exports="npm" -o ./` - * Copyright 2012-2015 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */ - -/** `Object#toString` result references. */ -var funcTag = '[object Function]'; - -/** Used to detect host constructors (Safari > 5). */ -var reIsHostCtor = /^\[object .+?Constructor\]$/; - -/** - * Checks if `value` is object-like. - * - * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. - */ -function isObjectLike(value) { - return !!value && typeof value == 'object'; -} - -/** Used for native method references. */ -var objectProto = Object.prototype; - -/** Used to resolve the decompiled source of functions. */ -var fnToString = Function.prototype.toString; - -/** Used to check objects for own properties. */ -var hasOwnProperty = objectProto.hasOwnProperty; - -/** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) - * of values. - */ -var objToString = objectProto.toString; - -/** Used to detect if a method is native. */ -var reIsNative = RegExp('^' + - fnToString.call(hasOwnProperty).replace(/[\\^$.*+?()[\]{}|]/g, '\\$&') - .replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$' -); - -/** - * Gets the native function at `key` of `object`. - * - * @private - * @param {Object} object The object to query. - * @param {string} key The key of the method to get. - * @returns {*} Returns the function if it's native, else `undefined`. - */ -function getNative(object, key) { - var value = object == null ? undefined : object[key]; - return isNative(value) ? value : undefined; -} - -/** - * Checks if `value` is classified as a `Function` object. - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. - * @example - * - * _.isFunction(_); - * // => true - * - * _.isFunction(/abc/); - * // => false - */ -function isFunction(value) { - // The use of `Object#toString` avoids issues with the `typeof` operator - // in older versions of Chrome and Safari which return 'function' for regexes - // and Safari 8 equivalents which return 'object' for typed array constructors. - return isObject(value) && objToString.call(value) == funcTag; -} - -/** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(1); - * // => false - */ -function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); -} - -/** - * Checks if `value` is a native function. - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a native function, else `false`. - * @example - * - * _.isNative(Array.prototype.push); - * // => true - * - * _.isNative(_); - * // => false - */ -function isNative(value) { - if (value == null) { - return false; - } - if (isFunction(value)) { - return reIsNative.test(fnToString.call(value)); - } - return isObjectLike(value) && reIsHostCtor.test(value); -} - -module.exports = getNative; - -},{}],15:[function(require,module,exports){ -/** - * lodash 3.0.9 (Custom Build) - * Build: `lodash modern modularize exports="npm" -o ./` - * Copyright 2012-2015 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */ - -/** Used to detect unsigned integer values. */ -var reIsUint = /^\d+$/; - -/** - * Used as the [maximum length](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-number.max_safe_integer) - * of an array-like value. - */ -var MAX_SAFE_INTEGER = 9007199254740991; - -/** - * The base implementation of `_.property` without support for deep paths. - * - * @private - * @param {string} key The key of the property to get. - * @returns {Function} Returns the new function. - */ -function baseProperty(key) { - return function(object) { - return object == null ? undefined : object[key]; - }; -} - -/** - * Gets the "length" property value of `object`. - * - * **Note:** This function is used to avoid a [JIT bug](https://bugs.webkit.org/show_bug.cgi?id=142792) - * that affects Safari on at least iOS 8.1-8.3 ARM64. - * - * @private - * @param {Object} object The object to query. - * @returns {*} Returns the "length" value. - */ -var getLength = baseProperty('length'); - -/** - * Checks if `value` is array-like. - * - * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is array-like, else `false`. - */ -function isArrayLike(value) { - return value != null && isLength(getLength(value)); -} - -/** - * Checks if `value` is a valid array-like index. - * - * @private - * @param {*} value The value to check. - * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index. - * @returns {boolean} Returns `true` if `value` is a valid index, else `false`. - */ -function isIndex(value, length) { - value = (typeof value == 'number' || reIsUint.test(value)) ? +value : -1; - length = length == null ? MAX_SAFE_INTEGER : length; - return value > -1 && value % 1 == 0 && value < length; -} - -/** - * Checks if the provided arguments are from an iteratee call. - * - * @private - * @param {*} value The potential iteratee value argument. - * @param {*} index The potential iteratee index or key argument. - * @param {*} object The potential iteratee object argument. - * @returns {boolean} Returns `true` if the arguments are from an iteratee call, else `false`. - */ -function isIterateeCall(value, index, object) { - if (!isObject(object)) { - return false; - } - var type = typeof index; - if (type == 'number' - ? (isArrayLike(object) && isIndex(index, object.length)) - : (type == 'string' && index in object)) { - var other = object[index]; - return value === value ? (value === other) : (other !== other); - } - return false; -} - -/** - * Checks if `value` is a valid array-like length. - * - * **Note:** This function is based on [`ToLength`](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength). - * - * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a valid length, else `false`. - */ -function isLength(value) { - return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; -} - -/** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(1); - * // => false - */ -function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); -} - -module.exports = isIterateeCall; - -},{}],16:[function(require,module,exports){ -/** - * lodash 3.2.0 (Custom Build) - * Build: `lodash modern modularize exports="npm" -o ./` - * Copyright 2012-2015 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */ -var baseAssign = require('lodash._baseassign'), - createAssigner = require('lodash._createassigner'), - keys = require('lodash.keys'); - -/** - * A specialized version of `_.assign` for customizing assigned values without - * support for argument juggling, multiple sources, and `this` binding `customizer` - * functions. - * - * @private - * @param {Object} object The destination object. - * @param {Object} source The source object. - * @param {Function} customizer The function to customize assigned values. - * @returns {Object} Returns `object`. - */ -function assignWith(object, source, customizer) { - var index = -1, - props = keys(source), - length = props.length; - - while (++index < length) { - var key = props[index], - value = object[key], - result = customizer(value, source[key], key, object, source); - - if ((result === result ? (result !== value) : (value === value)) || - (value === undefined && !(key in object))) { - object[key] = result; - } - } - return object; -} - -/** - * Assigns own enumerable properties of source object(s) to the destination - * object. Subsequent sources overwrite property assignments of previous sources. - * If `customizer` is provided it is invoked to produce the assigned values. - * The `customizer` is bound to `thisArg` and invoked with five arguments: - * (objectValue, sourceValue, key, object, source). - * - * **Note:** This method mutates `object` and is based on - * [`Object.assign`](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-object.assign). - * - * @static - * @memberOf _ - * @alias extend - * @category Object - * @param {Object} object The destination object. - * @param {...Object} [sources] The source objects. - * @param {Function} [customizer] The function to customize assigned values. - * @param {*} [thisArg] The `this` binding of `customizer`. - * @returns {Object} Returns `object`. - * @example - * - * _.assign({ 'user': 'barney' }, { 'age': 40 }, { 'user': 'fred' }); - * // => { 'user': 'fred', 'age': 40 } - * - * // using a customizer callback - * var defaults = _.partialRight(_.assign, function(value, other) { - * return _.isUndefined(value) ? other : value; - * }); - * - * defaults({ 'user': 'barney' }, { 'age': 36 }, { 'user': 'fred' }); - * // => { 'user': 'barney', 'age': 36 } - */ -var assign = createAssigner(function(object, source, customizer) { - return customizer - ? assignWith(object, source, customizer) - : baseAssign(object, source); -}); - -module.exports = assign; - -},{"lodash._baseassign":10,"lodash._createassigner":13,"lodash.keys":19}],17:[function(require,module,exports){ -/** - * lodash 3.0.8 (Custom Build) - * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */ - -/** Used as references for various `Number` constants. */ -var MAX_SAFE_INTEGER = 9007199254740991; - -/** `Object#toString` result references. */ -var argsTag = '[object Arguments]', - funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; - -/** Used for built-in method references. */ -var objectProto = Object.prototype; - -/** Used to check objects for own properties. */ -var hasOwnProperty = objectProto.hasOwnProperty; - -/** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) - * of values. - */ -var objectToString = objectProto.toString; - -/** Built-in value references. */ -var propertyIsEnumerable = objectProto.propertyIsEnumerable; - -/** - * The base implementation of `_.property` without support for deep paths. - * - * @private - * @param {string} key The key of the property to get. - * @returns {Function} Returns the new function. - */ -function baseProperty(key) { - return function(object) { - return object == null ? undefined : object[key]; - }; -} - -/** - * Gets the "length" property value of `object`. - * - * **Note:** This function is used to avoid a [JIT bug](https://bugs.webkit.org/show_bug.cgi?id=142792) - * that affects Safari on at least iOS 8.1-8.3 ARM64. - * - * @private - * @param {Object} object The object to query. - * @returns {*} Returns the "length" value. - */ -var getLength = baseProperty('length'); - -/** - * Checks if `value` is likely an `arguments` object. - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. - * @example - * - * _.isArguments(function() { return arguments; }()); - * // => true - * - * _.isArguments([1, 2, 3]); - * // => false - */ -function isArguments(value) { - // Safari 8.1 incorrectly makes `arguments.callee` enumerable in strict mode. - return isArrayLikeObject(value) && hasOwnProperty.call(value, 'callee') && - (!propertyIsEnumerable.call(value, 'callee') || objectToString.call(value) == argsTag); -} - -/** - * Checks if `value` is array-like. A value is considered array-like if it's - * not a function and has a `value.length` that's an integer greater than or - * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`. - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is array-like, else `false`. - * @example - * - * _.isArrayLike([1, 2, 3]); - * // => true - * - * _.isArrayLike(document.body.children); - * // => true - * - * _.isArrayLike('abc'); - * // => true - * - * _.isArrayLike(_.noop); - * // => false - */ -function isArrayLike(value) { - return value != null && isLength(getLength(value)) && !isFunction(value); -} - -/** - * This method is like `_.isArrayLike` except that it also checks if `value` - * is an object. - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an array-like object, else `false`. - * @example - * - * _.isArrayLikeObject([1, 2, 3]); - * // => true - * - * _.isArrayLikeObject(document.body.children); - * // => true - * - * _.isArrayLikeObject('abc'); - * // => false - * - * _.isArrayLikeObject(_.noop); - * // => false - */ -function isArrayLikeObject(value) { - return isObjectLike(value) && isArrayLike(value); -} - -/** - * Checks if `value` is classified as a `Function` object. - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. - * @example - * - * _.isFunction(_); - * // => true - * - * _.isFunction(/abc/); - * // => false - */ -function isFunction(value) { - // The use of `Object#toString` avoids issues with the `typeof` operator - // in Safari 8 which returns 'object' for typed array and weak map constructors, - // and PhantomJS 1.9 which returns 'function' for `NodeList` instances. - var tag = isObject(value) ? objectToString.call(value) : ''; - return tag == funcTag || tag == genTag; -} - -/** - * Checks if `value` is a valid array-like length. - * - * **Note:** This function is loosely based on [`ToLength`](http://ecma-international.org/ecma-262/6.0/#sec-tolength). - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a valid length, else `false`. - * @example - * - * _.isLength(3); - * // => true - * - * _.isLength(Number.MIN_VALUE); - * // => false - * - * _.isLength(Infinity); - * // => false - * - * _.isLength('3'); - * // => false - */ -function isLength(value) { - return typeof value == 'number' && - value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; -} - -/** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(_.noop); - * // => true - * - * _.isObject(null); - * // => false - */ -function isObject(value) { - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); -} - -/** - * Checks if `value` is object-like. A value is object-like if it's not `null` - * and has a `typeof` result of "object". - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. - * @example - * - * _.isObjectLike({}); - * // => true - * - * _.isObjectLike([1, 2, 3]); - * // => true - * - * _.isObjectLike(_.noop); - * // => false - * - * _.isObjectLike(null); - * // => false - */ -function isObjectLike(value) { - return !!value && typeof value == 'object'; -} - -module.exports = isArguments; - -},{}],18:[function(require,module,exports){ -/** - * lodash 3.0.4 (Custom Build) - * Build: `lodash modern modularize exports="npm" -o ./` - * Copyright 2012-2015 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */ - -/** `Object#toString` result references. */ -var arrayTag = '[object Array]', - funcTag = '[object Function]'; - -/** Used to detect host constructors (Safari > 5). */ -var reIsHostCtor = /^\[object .+?Constructor\]$/; - -/** - * Checks if `value` is object-like. - * - * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. - */ -function isObjectLike(value) { - return !!value && typeof value == 'object'; -} - -/** Used for native method references. */ -var objectProto = Object.prototype; - -/** Used to resolve the decompiled source of functions. */ -var fnToString = Function.prototype.toString; - -/** Used to check objects for own properties. */ -var hasOwnProperty = objectProto.hasOwnProperty; - -/** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) - * of values. - */ -var objToString = objectProto.toString; - -/** Used to detect if a method is native. */ -var reIsNative = RegExp('^' + - fnToString.call(hasOwnProperty).replace(/[\\^$.*+?()[\]{}|]/g, '\\$&') - .replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$' -); - -/* Native method references for those with the same name as other `lodash` methods. */ -var nativeIsArray = getNative(Array, 'isArray'); - -/** - * Used as the [maximum length](http://ecma-international.org/ecma-262/6.0/#sec-number.max_safe_integer) - * of an array-like value. - */ -var MAX_SAFE_INTEGER = 9007199254740991; - -/** - * Gets the native function at `key` of `object`. - * - * @private - * @param {Object} object The object to query. - * @param {string} key The key of the method to get. - * @returns {*} Returns the function if it's native, else `undefined`. - */ -function getNative(object, key) { - var value = object == null ? undefined : object[key]; - return isNative(value) ? value : undefined; -} - -/** - * Checks if `value` is a valid array-like length. - * - * **Note:** This function is based on [`ToLength`](http://ecma-international.org/ecma-262/6.0/#sec-tolength). - * - * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a valid length, else `false`. - */ -function isLength(value) { - return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; -} - -/** - * Checks if `value` is classified as an `Array` object. - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. - * @example - * - * _.isArray([1, 2, 3]); - * // => true - * - * _.isArray(function() { return arguments; }()); - * // => false - */ -var isArray = nativeIsArray || function(value) { - return isObjectLike(value) && isLength(value.length) && objToString.call(value) == arrayTag; -}; - -/** - * Checks if `value` is classified as a `Function` object. - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. - * @example - * - * _.isFunction(_); - * // => true - * - * _.isFunction(/abc/); - * // => false - */ -function isFunction(value) { - // The use of `Object#toString` avoids issues with the `typeof` operator - // in older versions of Chrome and Safari which return 'function' for regexes - // and Safari 8 equivalents which return 'object' for typed array constructors. - return isObject(value) && objToString.call(value) == funcTag; -} - -/** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(1); - * // => false - */ -function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); -} - -/** - * Checks if `value` is a native function. - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a native function, else `false`. - * @example - * - * _.isNative(Array.prototype.push); - * // => true - * - * _.isNative(_); - * // => false - */ -function isNative(value) { - if (value == null) { - return false; - } - if (isFunction(value)) { - return reIsNative.test(fnToString.call(value)); - } - return isObjectLike(value) && reIsHostCtor.test(value); -} - -module.exports = isArray; - -},{}],19:[function(require,module,exports){ -/** - * lodash 3.1.2 (Custom Build) - * Build: `lodash modern modularize exports="npm" -o ./` - * Copyright 2012-2015 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */ -var getNative = require('lodash._getnative'), - isArguments = require('lodash.isarguments'), - isArray = require('lodash.isarray'); - -/** Used to detect unsigned integer values. */ -var reIsUint = /^\d+$/; - -/** Used for native method references. */ -var objectProto = Object.prototype; - -/** Used to check objects for own properties. */ -var hasOwnProperty = objectProto.hasOwnProperty; - -/* Native method references for those with the same name as other `lodash` methods. */ -var nativeKeys = getNative(Object, 'keys'); - -/** - * Used as the [maximum length](http://ecma-international.org/ecma-262/6.0/#sec-number.max_safe_integer) - * of an array-like value. - */ -var MAX_SAFE_INTEGER = 9007199254740991; - -/** - * The base implementation of `_.property` without support for deep paths. - * - * @private - * @param {string} key The key of the property to get. - * @returns {Function} Returns the new function. - */ -function baseProperty(key) { - return function(object) { - return object == null ? undefined : object[key]; - }; -} - -/** - * Gets the "length" property value of `object`. - * - * **Note:** This function is used to avoid a [JIT bug](https://bugs.webkit.org/show_bug.cgi?id=142792) - * that affects Safari on at least iOS 8.1-8.3 ARM64. - * - * @private - * @param {Object} object The object to query. - * @returns {*} Returns the "length" value. - */ -var getLength = baseProperty('length'); - -/** - * Checks if `value` is array-like. - * - * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is array-like, else `false`. - */ -function isArrayLike(value) { - return value != null && isLength(getLength(value)); -} - -/** - * Checks if `value` is a valid array-like index. - * - * @private - * @param {*} value The value to check. - * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index. - * @returns {boolean} Returns `true` if `value` is a valid index, else `false`. - */ -function isIndex(value, length) { - value = (typeof value == 'number' || reIsUint.test(value)) ? +value : -1; - length = length == null ? MAX_SAFE_INTEGER : length; - return value > -1 && value % 1 == 0 && value < length; -} - -/** - * Checks if `value` is a valid array-like length. - * - * **Note:** This function is based on [`ToLength`](http://ecma-international.org/ecma-262/6.0/#sec-tolength). - * - * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a valid length, else `false`. - */ -function isLength(value) { - return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; -} - -/** - * A fallback implementation of `Object.keys` which creates an array of the - * own enumerable property names of `object`. - * - * @private - * @param {Object} object The object to query. - * @returns {Array} Returns the array of property names. - */ -function shimKeys(object) { - var props = keysIn(object), - propsLength = props.length, - length = propsLength && object.length; - - var allowIndexes = !!length && isLength(length) && - (isArray(object) || isArguments(object)); - - var index = -1, - result = []; - - while (++index < propsLength) { - var key = props[index]; - if ((allowIndexes && isIndex(key, length)) || hasOwnProperty.call(object, key)) { - result.push(key); - } - } - return result; -} - -/** - * Checks if `value` is the [language type](https://es5.github.io/#x8) of `Object`. - * (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(1); - * // => false - */ -function isObject(value) { - // Avoid a V8 JIT bug in Chrome 19-20. - // See https://code.google.com/p/v8/issues/detail?id=2291 for more details. - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); -} - -/** - * Creates an array of the own enumerable property names of `object`. - * - * **Note:** Non-object values are coerced to objects. See the - * [ES spec](http://ecma-international.org/ecma-262/6.0/#sec-object.keys) - * for more details. - * - * @static - * @memberOf _ - * @category Object - * @param {Object} object The object to query. - * @returns {Array} Returns the array of property names. - * @example - * - * function Foo() { - * this.a = 1; - * this.b = 2; - * } - * - * Foo.prototype.c = 3; - * - * _.keys(new Foo); - * // => ['a', 'b'] (iteration order is not guaranteed) - * - * _.keys('hi'); - * // => ['0', '1'] - */ -var keys = !nativeKeys ? shimKeys : function(object) { - var Ctor = object == null ? undefined : object.constructor; - if ((typeof Ctor == 'function' && Ctor.prototype === object) || - (typeof object != 'function' && isArrayLike(object))) { - return shimKeys(object); - } - return isObject(object) ? nativeKeys(object) : []; -}; - -/** - * Creates an array of the own and inherited enumerable property names of `object`. - * - * **Note:** Non-object values are coerced to objects. - * - * @static - * @memberOf _ - * @category Object - * @param {Object} object The object to query. - * @returns {Array} Returns the array of property names. - * @example - * - * function Foo() { - * this.a = 1; - * this.b = 2; - * } - * - * Foo.prototype.c = 3; - * - * _.keysIn(new Foo); - * // => ['a', 'b', 'c'] (iteration order is not guaranteed) - */ -function keysIn(object) { - if (object == null) { - return []; - } - if (!isObject(object)) { - object = Object(object); - } - var length = object.length; - length = (length && isLength(length) && - (isArray(object) || isArguments(object)) && length) || 0; - - var Ctor = object.constructor, - index = -1, - isProto = typeof Ctor == 'function' && Ctor.prototype === object, - result = Array(length), - skipIndexes = length > 0; - - while (++index < length) { - result[index] = (index + ''); - } - for (var key in object) { - if (!(skipIndexes && isIndex(key, length)) && - !(key == 'constructor' && (isProto || !hasOwnProperty.call(object, key)))) { - result.push(key); - } - } - return result; -} - -module.exports = keys; - -},{"lodash._getnative":14,"lodash.isarguments":17,"lodash.isarray":18}],20:[function(require,module,exports){ -/** - * lodash 3.6.1 (Custom Build) - * Build: `lodash modern modularize exports="npm" -o ./` - * Copyright 2012-2015 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */ - -/** Used as the `TypeError` message for "Functions" methods. */ -var FUNC_ERROR_TEXT = 'Expected a function'; - -/* Native method references for those with the same name as other `lodash` methods. */ -var nativeMax = Math.max; - -/** - * Creates a function that invokes `func` with the `this` binding of the - * created function and arguments from `start` and beyond provided as an array. - * - * **Note:** This method is based on the [rest parameter](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/rest_parameters). - * - * @static - * @memberOf _ - * @category Function - * @param {Function} func The function to apply a rest parameter to. - * @param {number} [start=func.length-1] The start position of the rest parameter. - * @returns {Function} Returns the new function. - * @example - * - * var say = _.restParam(function(what, names) { - * return what + ' ' + _.initial(names).join(', ') + - * (_.size(names) > 1 ? ', & ' : '') + _.last(names); - * }); - * - * say('hello', 'fred', 'barney', 'pebbles'); - * // => 'hello fred, barney, & pebbles' - */ -function restParam(func, start) { - if (typeof func != 'function') { - throw new TypeError(FUNC_ERROR_TEXT); - } - start = nativeMax(start === undefined ? (func.length - 1) : (+start || 0), 0); - return function() { - var args = arguments, - index = -1, - length = nativeMax(args.length - start, 0), - rest = Array(length); - - while (++index < length) { - rest[index] = args[start + index]; - } - switch (start) { - case 0: return func.call(this, rest); - case 1: return func.call(this, args[0], rest); - case 2: return func.call(this, args[0], args[1], rest); - } - var otherArgs = Array(start + 1); - index = -1; - while (++index < start) { - otherArgs[index] = args[index]; - } - otherArgs[start] = rest; - return func.apply(this, otherArgs); - }; -} - -module.exports = restParam; - -},{}]},{},[7])(7) -}); \ No newline at end of file +!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react"),require("react-dom")):"function"==typeof define&&define.amd?define(["react","react-dom"],t):"object"==typeof exports?exports.ReactModal=t(require("react"),require("react-dom")):e.ReactModal=t(e.react,e["react-dom"])}(this,function(e,t){return function(e){function t(o){if(n[o])return n[o].exports;var r=n[o]={exports:{},id:o,loaded:!1};return e[o].call(r.exports,r,r.exports,t),r.loaded=!0,r.exports}var n={};return t.m=e,t.c=n,t.p="/",t(0)}([function(e,t,n){"use strict";e.exports=n(6)},function(e,t){"use strict";/*! + * Adapted from jQuery UI core + * + * http://jqueryui.com + * + * Copyright 2014 jQuery Foundation and other contributors + * Released under the MIT license. + * http://jquery.org/license + * + * http://api.jqueryui.com/category/ui-core/ + */ +function n(e,t){var n=e.nodeName.toLowerCase();return(/input|select|textarea|button|object/.test(n)?!e.disabled:"a"===n?e.href||t:t)&&r(e)}function o(e){return e.offsetWidth<=0&&e.offsetHeight<=0||"none"===e.style.display}function r(e){for(;e&&e!==document.body;){if(o(e))return!1;e=e.parentNode}return!0}function i(e){var t=e.getAttribute("tabindex");null===t&&(t=void 0);var o=isNaN(t);return(o||t>=0)&&n(e,!o)}function s(e){return[].slice.call(e.querySelectorAll("*"),0).filter(function(e){return i(e)})}e.exports=s},function(e,t,n){function o(e,t,n){for(var o=-1,r=s(t),i=r.length;++o-1&&e%1==0&&t>e}function s(e){return"number"==typeof e&&e>-1&&e%1==0&&m>=e}function u(e){for(var t=a(e),n=t.length,o=n&&e.length,r=!!o&&s(o)&&(p(e)||f(e)),u=-1,c=[];++u0;++o0?this.closeWithTimeout():this.closeWithoutTimeout())},focusContent:function(){this.refs.content.focus()},closeWithTimeout:function(){this.setState({beforeClose:!0},function(){this.closeTimer=setTimeout(this.closeWithoutTimeout,this.props.closeTimeoutMS)}.bind(this))},closeWithoutTimeout:function(){this.setState({afterOpen:!1,beforeClose:!1},this.afterClose)},afterClose:function(){i.returnFocus(),i.teardownScopedFocus()},handleKeyDown:function(e){9==e.keyCode&&s(this.refs.content,e),27==e.keyCode&&(e.preventDefault(),this.requestClose())},handleOverlayClick:function(e){for(var t=e.target;t;){if(t===this.refs.content)return;t=t.parentNode}this.props.shouldCloseOnOverlayClick&&(this.ownerHandlesClose()?this.requestClose():this.focusContent())},requestClose:function(){this.ownerHandlesClose()&&this.props.onRequestClose()},ownerHandlesClose:function(){return this.props.onRequestClose},shouldBeClosed:function(){return!this.props.isOpen&&!this.state.beforeClose},buildClassName:function(e,t){var n=c[e].base;return this.state.afterOpen&&(n+=" "+c[e].afterOpen),this.state.beforeClose&&(n+=" "+c[e].beforeClose),t?n+" "+t:n},render:function(){var e=this.props.className?{}:this.props.defaultStyles.content,t=this.props.overlayClassName?{}:this.props.defaultStyles.overlay;return this.shouldBeClosed()?r():r({ref:"overlay",className:this.buildClassName("overlay",this.props.overlayClassName),style:u({},t,this.props.style.overlay||{}),onClick:this.handleOverlayClick},r({ref:"content",style:u({},e,this.props.style.content||{}),className:this.buildClassName("content",this.props.className),tabIndex:"-1",onKeyDown:this.handleKeyDown},this.props.children))}})},function(e,t){"use strict";function n(e){if("string"==typeof e){var t=document.querySelectorAll(e);e="length"in t?t[0]:t}return c=e||c}function o(e){s(e),(e||c).setAttribute("aria-hidden","true")}function r(e){s(e),(e||c).removeAttribute("aria-hidden")}function i(e,t){e?o(t):r(t)}function s(e){if(!e&&!c)throw new Error("react-modal: You must set an element with `Modal.setAppElement(el)` to make this accessible")}function u(){c=document.body}var c="undefined"!=typeof document?document.body:null;t.toggle=i,t.setElement=n,t.show=r,t.hide=o,t.resetForTesting=u},function(e,t,n){"use strict";function o(e){c=!0}function r(e){if(c){if(c=!1,!s)return;setTimeout(function(){if(!s.contains(document.activeElement)){var e=i(s)[0]||s;e.focus()}},0)}}var i=n(1),s=null,u=null,c=!1;t.markForFocusLater=function(){u=document.activeElement},t.returnFocus=function(){try{u.focus()}catch(e){console.warn("You tried to return focus to "+u+" but it is not in the DOM anymore")}u=null},t.setupScopedFocus=function(e){s=e,window.addEventListener?(window.addEventListener("blur",o,!1),document.addEventListener("focus",r,!0)):(window.attachEvent("onBlur",o),document.attachEvent("onFocus",r))},t.teardownScopedFocus=function(){s=null,window.addEventListener?(window.removeEventListener("blur",o),document.removeEventListener("focus",r)):(window.detachEvent("onBlur",o),document.detachEvent("onFocus",r))}},function(e,t,n){"use strict";var o=n(1);e.exports=function(e,t){var n=o(e);if(!n.length)return void t.preventDefault();var r=n[t.shiftKey?0:n.length-1],i=r===document.activeElement||e===document.activeElement;if(i){t.preventDefault();var s=n[t.shiftKey?n.length-1:0];s.focus()}}},function(e,t){function n(e,t){if(e.indexOf)return e.indexOf(t);for(var n=0,o=e.length;o>n;n++)if(e[n]===t)return n;return-1}function o(e){if(!(this instanceof o))return new o(e);e||(e={}),e.nodeType&&(e={el:e}),this.opts=e,this.el=e.el||document.body,"object"!=typeof this.el&&(this.el=document.querySelector(this.el))}e.exports=function(e){return new o(e)},o.prototype.add=function(e){var t=this.el;if(t){if(""===t.className)return t.className=e;var o=t.className.split(" ");return n(o,e)>-1?o:(o.push(e),t.className=o.join(" "),o)}},o.prototype.remove=function(e){var t=this.el;if(t&&""!==t.className){var o=t.className.split(" "),r=n(o,e);return r>-1&&o.splice(r,1),t.className=o.join(" "),o}},o.prototype.has=function(e){var t=this.el;if(t){var o=t.className.split(" ");return n(o,e)>-1}},o.prototype.toggle=function(e){var t=this.el;t&&(this.has(e)?this.remove(e):this.add(e))}},function(e,t,n){var o;/*! + Copyright (c) 2015 Jed Watson. + Based on code that is Copyright 2013-2015, Facebook, Inc. + All rights reserved. + */ +!function(){"use strict";var r=!("undefined"==typeof window||!window.document||!window.document.createElement),i={canUseDOM:r,canUseWorkers:"undefined"!=typeof Worker,canUseEventListeners:r&&!(!window.addEventListener&&!window.attachEvent),canUseViewport:r&&!!window.screen};o=function(){return i}.call(t,n,t,e),!(void 0!==o&&(e.exports=o))}()},function(e,t,n){function o(e,t){return null==t?e:r(t,i(t),e)}var r=n(14),i=n(3);e.exports=o},function(e,t){function n(e,t,n){n||(n={});for(var o=-1,r=t.length;++o2?n[s-2]:void 0,c=s>2?n[2]:void 0,a=s>1?n[s-1]:void 0;for("function"==typeof u?(u=r(u,a,5),s-=2):(u="function"==typeof a?a:void 0,s-=u?1:0),c&&i(n[0],n[1],c)&&(u=3>s?void 0:u,s=1);++o-1&&e%1==0&&t>e}function i(e,t,n){if(!u(n))return!1;var i=typeof t;if("number"==i?o(n)&&r(t,n.length):"string"==i&&t in n){var s=n[t];return e===e?e===s:s!==s}return!1}function s(e){return"number"==typeof e&&e>-1&&e%1==0&&a>=e}function u(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}var c=/^\d+$/,a=9007199254740991,l=n("length");e.exports=i},function(e,t){function n(e){return function(t){return null==t?void 0:t[e]}}function o(e){return i(e)&&v.call(e,"callee")&&(!m.call(e,"callee")||y.call(e)==f)}function r(e){return null!=e&&u(b(e))&&!s(e)}function i(e){return a(e)&&r(e)}function s(e){var t=c(e)?y.call(e):"";return t==p||t==d}function u(e){return"number"==typeof e&&e>-1&&e%1==0&&l>=e}function c(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function a(e){return!!e&&"object"==typeof e}var l=9007199254740991,f="[object Arguments]",p="[object Function]",d="[object GeneratorFunction]",h=Object.prototype,v=h.hasOwnProperty,y=h.toString,m=h.propertyIsEnumerable,b=n("length");e.exports=o},function(e,t){function n(e){return!!e&&"object"==typeof e}function o(e,t){var n=null==e?void 0:e[t];return u(n)?n:void 0}function r(e){return"number"==typeof e&&e>-1&&e%1==0&&m>=e}function i(e){return s(e)&&h.call(e)==a}function s(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function u(e){return null==e?!1:i(e)?v.test(p.call(e)):n(e)&&l.test(e)}var c="[object Array]",a="[object Function]",l=/^\[object .+?Constructor\]$/,f=Object.prototype,p=Function.prototype.toString,d=f.hasOwnProperty,h=f.toString,v=RegExp("^"+p.call(d).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),y=o(Array,"isArray"),m=9007199254740991,b=y||function(e){return n(e)&&r(e.length)&&h.call(e)==c};e.exports=b},function(e,t){function n(e,t){if("function"!=typeof e)throw new TypeError(o);return t=r(void 0===t?e.length-1:+t||0,0),function(){for(var n=arguments,o=-1,i=r(n.length-t,0),s=Array(i);++o0?this.closeWithTimeout():this.closeWithoutTimeout())},focusContent:function(){this.refs.content.focus()},closeWithTimeout:function(){this.setState({beforeClose:!0},function(){this.closeTimer=setTimeout(this.closeWithoutTimeout,this.props.closeTimeoutMS)}.bind(this))},closeWithoutTimeout:function(){this.setState({afterOpen:!1,beforeClose:!1},this.afterClose)},afterClose:function(){focusManager.returnFocus(),focusManager.teardownScopedFocus()},handleKeyDown:function(event){9==event.keyCode&&scopeTab(this.refs.content,event),27==event.keyCode&&(event.preventDefault(),this.requestClose())},handleOverlayClick:function(event){for(var node=event.target;node;){if(node===this.refs.content)return;node=node.parentNode}this.props.shouldCloseOnOverlayClick&&(this.ownerHandlesClose()?this.requestClose():this.focusContent())},requestClose:function(){this.ownerHandlesClose()&&this.props.onRequestClose()},ownerHandlesClose:function(){return this.props.onRequestClose},shouldBeClosed:function(){return!this.props.isOpen&&!this.state.beforeClose},buildClassName:function(which,additional){var className=CLASS_NAMES[which].base;return this.state.afterOpen&&(className+=" "+CLASS_NAMES[which].afterOpen),this.state.beforeClose&&(className+=" "+CLASS_NAMES[which].beforeClose),additional?className+" "+additional:className},render:function(){var contentStyles=this.props.className?{}:this.props.defaultStyles.content,overlayStyles=this.props.overlayClassName?{}:this.props.defaultStyles.overlay;return this.shouldBeClosed()?div():div({ref:"overlay",className:this.buildClassName("overlay",this.props.overlayClassName),style:Assign({},overlayStyles,this.props.style.overlay||{}),onClick:this.handleOverlayClick},div({ref:"content",style:Assign({},contentStyles,this.props.style.content||{}),className:this.buildClassName("content",this.props.className),tabIndex:"-1",onKeyDown:this.handleKeyDown},this.props.children))}})},{"../helpers/focusManager":4,"../helpers/scopeTab":5,"lodash.assign":16}],3:[function(require,module,exports){function setElement(element){if("string"==typeof element){var el=document.querySelectorAll(element);element="length"in el?el[0]:el}return _element=element||_element}function hide(appElement){validateElement(appElement),(appElement||_element).setAttribute("aria-hidden","true")}function show(appElement){validateElement(appElement),(appElement||_element).removeAttribute("aria-hidden")}function toggle(shouldHide,appElement){shouldHide?hide(appElement):show(appElement)}function validateElement(appElement){if(!appElement&&!_element)throw new Error("react-modal: You must set an element with `Modal.setAppElement(el)` to make this accessible")}function resetForTesting(){_element=document.body}var _element="undefined"!=typeof document?document.body:null;exports.toggle=toggle,exports.setElement=setElement,exports.show=show,exports.hide=hide,exports.resetForTesting=resetForTesting},{}],4:[function(require,module,exports){function handleBlur(event){needToFocus=!0}function handleFocus(event){if(needToFocus){if(needToFocus=!1,!modalElement)return;setTimeout(function(){if(!modalElement.contains(document.activeElement)){var el=findTabbable(modalElement)[0]||modalElement;el.focus()}},0)}}var findTabbable=require("../helpers/tabbable"),modalElement=null,focusLaterElement=null,needToFocus=!1;exports.markForFocusLater=function(){focusLaterElement=document.activeElement},exports.returnFocus=function(){try{focusLaterElement.focus()}catch(e){console.warn("You tried to return focus to "+focusLaterElement+" but it is not in the DOM anymore")}focusLaterElement=null},exports.setupScopedFocus=function(element){modalElement=element,window.addEventListener?(window.addEventListener("blur",handleBlur,!1),document.addEventListener("focus",handleFocus,!0)):(window.attachEvent("onBlur",handleBlur),document.attachEvent("onFocus",handleFocus))},exports.teardownScopedFocus=function(){modalElement=null,window.addEventListener?(window.removeEventListener("blur",handleBlur),document.removeEventListener("focus",handleFocus)):(window.detachEvent("onBlur",handleBlur),document.detachEvent("onFocus",handleFocus))}},{"../helpers/tabbable":6}],5:[function(require,module,exports){var findTabbable=require("../helpers/tabbable");module.exports=function(node,event){var tabbable=findTabbable(node);if(!tabbable.length)return void event.preventDefault();var finalTabbable=tabbable[event.shiftKey?0:tabbable.length-1],leavingFinalTabbable=finalTabbable===document.activeElement||node===document.activeElement;if(leavingFinalTabbable){event.preventDefault();var target=tabbable[event.shiftKey?tabbable.length-1:0];target.focus()}}},{"../helpers/tabbable":6}],6:[function(require,module,exports){function focusable(element,isTabIndexNotNaN){var nodeName=element.nodeName.toLowerCase();return(/input|select|textarea|button|object/.test(nodeName)?!element.disabled:"a"===nodeName?element.href||isTabIndexNotNaN:isTabIndexNotNaN)&&visible(element)}function hidden(el){return el.offsetWidth<=0&&el.offsetHeight<=0||"none"===el.style.display}function visible(element){for(;element&&element!==document.body;){if(hidden(element))return!1;element=element.parentNode}return!0}function tabbable(element){var tabIndex=element.getAttribute("tabindex");null===tabIndex&&(tabIndex=void 0);var isTabIndexNaN=isNaN(tabIndex);return(isTabIndexNaN||tabIndex>=0)&&focusable(element,!isTabIndexNaN)}function findTabbableDescendants(element){return[].slice.call(element.querySelectorAll("*"),0).filter(function(el){return tabbable(el)})}module.exports=findTabbableDescendants},{}],7:[function(require,module,exports){module.exports=require("./components/Modal")},{"./components/Modal":1}],8:[function(require,module,exports){function indexOf(arr,prop){if(arr.indexOf)return arr.indexOf(prop);for(var i=0,len=arr.length;len>i;i++)if(arr[i]===prop)return i;return-1}function ElementClass(opts){if(!(this instanceof ElementClass))return new ElementClass(opts);opts||(opts={}),opts.nodeType&&(opts={el:opts}),this.opts=opts,this.el=opts.el||document.body,"object"!=typeof this.el&&(this.el=document.querySelector(this.el))}module.exports=function(opts){return new ElementClass(opts)},ElementClass.prototype.add=function(className){var el=this.el;if(el){if(""===el.className)return el.className=className;var classes=el.className.split(" ");return indexOf(classes,className)>-1?classes:(classes.push(className),el.className=classes.join(" "),classes)}},ElementClass.prototype.remove=function(className){var el=this.el;if(el&&""!==el.className){var classes=el.className.split(" "),idx=indexOf(classes,className);return idx>-1&&classes.splice(idx,1),el.className=classes.join(" "),classes}},ElementClass.prototype.has=function(className){var el=this.el;if(el){var classes=el.className.split(" ");return indexOf(classes,className)>-1}},ElementClass.prototype.toggle=function(className){var el=this.el;el&&(this.has(className)?this.remove(className):this.add(className))}},{}],9:[function(require,module,exports){!function(){"use strict";var canUseDOM=!("undefined"==typeof window||!window.document||!window.document.createElement),ExecutionEnvironment={canUseDOM:canUseDOM,canUseWorkers:"undefined"!=typeof Worker,canUseEventListeners:canUseDOM&&!(!window.addEventListener&&!window.attachEvent),canUseViewport:canUseDOM&&!!window.screen};"function"==typeof define&&"object"==typeof define.amd&&define.amd?define(function(){return ExecutionEnvironment}):"undefined"!=typeof module&&module.exports?module.exports=ExecutionEnvironment:window.ExecutionEnvironment=ExecutionEnvironment}()},{}],10:[function(require,module,exports){function baseAssign(object,source){return null==source?object:baseCopy(source,keys(source),object)}var baseCopy=require("lodash._basecopy"),keys=require("lodash.keys");module.exports=baseAssign},{"lodash._basecopy":11,"lodash.keys":19}],11:[function(require,module,exports){function baseCopy(source,props,object){object||(object={});for(var index=-1,length=props.length;++index2?sources[length-2]:void 0,guard=length>2?sources[2]:void 0,thisArg=length>1?sources[length-1]:void 0;for("function"==typeof customizer?(customizer=bindCallback(customizer,thisArg,5),length-=2):(customizer="function"==typeof thisArg?thisArg:void 0,length-=customizer?1:0),guard&&isIterateeCall(sources[0],sources[1],guard)&&(customizer=3>length?void 0:customizer,length=1);++index-1&&value%1==0&&length>value}function isIterateeCall(value,index,object){if(!isObject(object))return!1;var type=typeof index;if("number"==type?isArrayLike(object)&&isIndex(index,object.length):"string"==type&&index in object){var other=object[index];return value===value?value===other:other!==other}return!1}function isLength(value){return"number"==typeof value&&value>-1&&value%1==0&&MAX_SAFE_INTEGER>=value}function isObject(value){var type=typeof value;return!!value&&("object"==type||"function"==type)}var reIsUint=/^\d+$/,MAX_SAFE_INTEGER=9007199254740991,getLength=baseProperty("length");module.exports=isIterateeCall},{}],16:[function(require,module,exports){function assignWith(object,source,customizer){for(var index=-1,props=keys(source),length=props.length;++index-1&&value%1==0&&MAX_SAFE_INTEGER>=value}function isObject(value){var type=typeof value;return!!value&&("object"==type||"function"==type)}function isObjectLike(value){return!!value&&"object"==typeof value}var MAX_SAFE_INTEGER=9007199254740991,argsTag="[object Arguments]",funcTag="[object Function]",genTag="[object GeneratorFunction]",objectProto=Object.prototype,hasOwnProperty=objectProto.hasOwnProperty,objectToString=objectProto.toString,propertyIsEnumerable=objectProto.propertyIsEnumerable,getLength=baseProperty("length");module.exports=isArguments},{}],18:[function(require,module,exports){function isObjectLike(value){return!!value&&"object"==typeof value}function getNative(object,key){var value=null==object?void 0:object[key];return isNative(value)?value:void 0}function isLength(value){return"number"==typeof value&&value>-1&&value%1==0&&MAX_SAFE_INTEGER>=value}function isFunction(value){return isObject(value)&&objToString.call(value)==funcTag}function isObject(value){var type=typeof value;return!!value&&("object"==type||"function"==type)}function isNative(value){return null==value?!1:isFunction(value)?reIsNative.test(fnToString.call(value)):isObjectLike(value)&&reIsHostCtor.test(value)}var arrayTag="[object Array]",funcTag="[object Function]",reIsHostCtor=/^\[object .+?Constructor\]$/,objectProto=Object.prototype,fnToString=Function.prototype.toString,hasOwnProperty=objectProto.hasOwnProperty,objToString=objectProto.toString,reIsNative=RegExp("^"+fnToString.call(hasOwnProperty).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),nativeIsArray=getNative(Array,"isArray"),MAX_SAFE_INTEGER=9007199254740991,isArray=nativeIsArray||function(value){return isObjectLike(value)&&isLength(value.length)&&objToString.call(value)==arrayTag};module.exports=isArray},{}],19:[function(require,module,exports){function baseProperty(key){return function(object){return null==object?void 0:object[key]}}function isArrayLike(value){return null!=value&&isLength(getLength(value))}function isIndex(value,length){return value="number"==typeof value||reIsUint.test(value)?+value:-1,length=null==length?MAX_SAFE_INTEGER:length,value>-1&&value%1==0&&length>value}function isLength(value){return"number"==typeof value&&value>-1&&value%1==0&&MAX_SAFE_INTEGER>=value}function shimKeys(object){for(var props=keysIn(object),propsLength=props.length,length=propsLength&&object.length,allowIndexes=!!length&&isLength(length)&&(isArray(object)||isArguments(object)),index=-1,result=[];++index0;++index=0)&&n(e,!o)}function s(e){return[].slice.call(e.querySelectorAll("*"),0).filter(function(e){return i(e)})}e.exports=s},function(e,t,n){function o(e,t,n){for(var o=-1,r=s(t),i=r.length;++o-1&&e%1==0&&t>e}function s(e){return"number"==typeof e&&e>-1&&e%1==0&&m>=e}function u(e){for(var t=a(e),n=t.length,o=n&&e.length,r=!!o&&s(o)&&(p(e)||f(e)),u=-1,c=[];++u0;++o0?this.closeWithTimeout():this.closeWithoutTimeout())},focusContent:function(){this.refs.content.focus()},closeWithTimeout:function(){this.setState({beforeClose:!0},function(){this.closeTimer=setTimeout(this.closeWithoutTimeout,this.props.closeTimeoutMS)}.bind(this))},closeWithoutTimeout:function(){this.setState({afterOpen:!1,beforeClose:!1},this.afterClose)},afterClose:function(){i.returnFocus(),i.teardownScopedFocus()},handleKeyDown:function(e){9==e.keyCode&&s(this.refs.content,e),27==e.keyCode&&(e.preventDefault(),this.requestClose())},handleOverlayClick:function(e){for(var t=e.target;t;){if(t===this.refs.content)return;t=t.parentNode}this.props.shouldCloseOnOverlayClick&&(this.ownerHandlesClose()?this.requestClose():this.focusContent())},requestClose:function(){this.ownerHandlesClose()&&this.props.onRequestClose()},ownerHandlesClose:function(){return this.props.onRequestClose},shouldBeClosed:function(){return!this.props.isOpen&&!this.state.beforeClose},buildClassName:function(e,t){var n=c[e].base;return this.state.afterOpen&&(n+=" "+c[e].afterOpen),this.state.beforeClose&&(n+=" "+c[e].beforeClose),t?n+" "+t:n},render:function(){var e=this.props.className?{}:this.props.defaultStyles.content,t=this.props.overlayClassName?{}:this.props.defaultStyles.overlay;return this.shouldBeClosed()?r():r({ref:"overlay",className:this.buildClassName("overlay",this.props.overlayClassName),style:u({},t,this.props.style.overlay||{}),onClick:this.handleOverlayClick},r({ref:"content",style:u({},e,this.props.style.content||{}),className:this.buildClassName("content",this.props.className),tabIndex:"-1",onKeyDown:this.handleKeyDown},this.props.children))}})},function(e,t){"use strict";function n(e){if("string"==typeof e){var t=document.querySelectorAll(e);e="length"in t?t[0]:t}return c=e||c}function o(e){s(e),(e||c).setAttribute("aria-hidden","true")}function r(e){s(e),(e||c).removeAttribute("aria-hidden")}function i(e,t){e?o(t):r(t)}function s(e){if(!e&&!c)throw new Error("react-modal: You must set an element with `Modal.setAppElement(el)` to make this accessible")}function u(){c=document.body}var c="undefined"!=typeof document?document.body:null;t.toggle=i,t.setElement=n,t.show=r,t.hide=o,t.resetForTesting=u},function(e,t,n){"use strict";function o(e){c=!0}function r(e){if(c){if(c=!1,!s)return;setTimeout(function(){if(!s.contains(document.activeElement)){var e=i(s)[0]||s;e.focus()}},0)}}var i=n(1),s=null,u=null,c=!1;t.markForFocusLater=function(){u=document.activeElement},t.returnFocus=function(){try{u.focus()}catch(e){console.warn("You tried to return focus to "+u+" but it is not in the DOM anymore")}u=null},t.setupScopedFocus=function(e){s=e,window.addEventListener?(window.addEventListener("blur",o,!1),document.addEventListener("focus",r,!0)):(window.attachEvent("onBlur",o),document.attachEvent("onFocus",r))},t.teardownScopedFocus=function(){s=null,window.addEventListener?(window.removeEventListener("blur",o),document.removeEventListener("focus",r)):(window.detachEvent("onBlur",o),document.detachEvent("onFocus",r))}},function(e,t,n){"use strict";var o=n(1);e.exports=function(e,t){var n=o(e);if(!n.length)return void t.preventDefault();var r=n[t.shiftKey?0:n.length-1],i=r===document.activeElement||e===document.activeElement;if(i){t.preventDefault();var s=n[t.shiftKey?n.length-1:0];s.focus()}}},function(e,t){function n(e,t){if(e.indexOf)return e.indexOf(t);for(var n=0,o=e.length;o>n;n++)if(e[n]===t)return n;return-1}function o(e){return this instanceof o?(e||(e={}),e.nodeType&&(e={el:e}),this.opts=e,this.el=e.el||document.body,"object"!=typeof this.el&&(this.el=document.querySelector(this.el)),void 0):new o(e)}e.exports=function(e){return new o(e)},o.prototype.add=function(e){var t=this.el;if(t){if(""===t.className)return t.className=e;var o=t.className.split(" ");return n(o,e)>-1?o:(o.push(e),t.className=o.join(" "),o)}},o.prototype.remove=function(e){var t=this.el;if(t&&""!==t.className){var o=t.className.split(" "),r=n(o,e);return r>-1&&o.splice(r,1),t.className=o.join(" "),o}},o.prototype.has=function(e){var t=this.el;if(t){var o=t.className.split(" ");return n(o,e)>-1}},o.prototype.toggle=function(e){var t=this.el;t&&(this.has(e)?this.remove(e):this.add(e))}},function(e,t,n){var o;/*! + Copyright (c) 2015 Jed Watson. + Based on code that is Copyright 2013-2015, Facebook, Inc. + All rights reserved. + */ +!function(){"use strict";var r=!("undefined"==typeof window||!window.document||!window.document.createElement),i={canUseDOM:r,canUseWorkers:"undefined"!=typeof Worker,canUseEventListeners:r&&!(!window.addEventListener&&!window.attachEvent),canUseViewport:r&&!!window.screen};o=function(){return i}.call(t,n,t,e),!(void 0!==o&&(e.exports=o))}()},function(e,t,n){function o(e,t){return null==t?e:r(t,i(t),e)}var r=n(14),i=n(3);e.exports=o},function(e,t){function n(e,t,n){n||(n={});for(var o=-1,r=t.length;++o2?n[s-2]:void 0,c=s>2?n[2]:void 0,a=s>1?n[s-1]:void 0;for("function"==typeof u?(u=r(u,a,5),s-=2):(u="function"==typeof a?a:void 0,s-=u?1:0),c&&i(n[0],n[1],c)&&(u=3>s?void 0:u,s=1);++o-1&&e%1==0&&t>e}function i(e,t,n){if(!u(n))return!1;var i=typeof t;if("number"==i?o(n)&&r(t,n.length):"string"==i&&t in n){var s=n[t];return e===e?e===s:s!==s}return!1}function s(e){return"number"==typeof e&&e>-1&&e%1==0&&a>=e}function u(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}var c=/^\d+$/,a=9007199254740991,l=n("length");e.exports=i},function(e,t){function n(e){return function(t){return null==t?void 0:t[e]}}function o(e){return i(e)&&v.call(e,"callee")&&(!m.call(e,"callee")||y.call(e)==f)}function r(e){return null!=e&&u(b(e))&&!s(e)}function i(e){return a(e)&&r(e)}function s(e){var t=c(e)?y.call(e):"";return t==p||t==d}function u(e){return"number"==typeof e&&e>-1&&e%1==0&&l>=e}function c(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function a(e){return!!e&&"object"==typeof e}var l=9007199254740991,f="[object Arguments]",p="[object Function]",d="[object GeneratorFunction]",h=Object.prototype,v=h.hasOwnProperty,y=h.toString,m=h.propertyIsEnumerable,b=n("length");e.exports=o},function(e,t){function n(e){return!!e&&"object"==typeof e}function o(e,t){var n=null==e?void 0:e[t];return u(n)?n:void 0}function r(e){return"number"==typeof e&&e>-1&&e%1==0&&m>=e}function i(e){return s(e)&&h.call(e)==a}function s(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function u(e){return null==e?!1:i(e)?v.test(p.call(e)):n(e)&&l.test(e)}var c="[object Array]",a="[object Function]",l=/^\[object .+?Constructor\]$/,f=Object.prototype,p=Function.prototype.toString,d=f.hasOwnProperty,h=f.toString,v=RegExp("^"+p.call(d).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),y=o(Array,"isArray"),m=9007199254740991,b=y||function(e){return n(e)&&r(e.length)&&h.call(e)==c};e.exports=b},function(e,t){function n(e,t){if("function"!=typeof e)throw new TypeError(o);return t=r(void 0===t?e.length-1:+t||0,0),function(){for(var n=arguments,o=-1,i=r(n.length-t,0),s=Array(i);++o