text: (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.Lightbox = 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<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
  'use strict';
  
  Object.defineProperty(exports, '__esModule', {
      value: true
  });
  
  var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })();
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
  
  var _inlineStylePrefixerStatic = require('inline-style-prefixer/static');
  
  var _inlineStylePrefixerStatic2 = _interopRequireDefault(_inlineStylePrefixerStatic);
  
  var _util = require('./util');
  
  /**
   * Generate CSS for a selector and some styles.
   *
   * This function handles the media queries, pseudo selectors, and descendant
   * styles that can be used in aphrodite styles.
   *
   * @param {string} selector: A base CSS selector for the styles to be generated
   *     with.
   * @param {Object} styleTypes: A list of properties of the return type of
   *     StyleSheet.create, e.g. [styles.red, styles.blue].
   * @param stringHandlers: See `generateCSSRuleset`
   * @param useImportant: See `generateCSSRuleset`
   *
   * To actually generate the CSS special-construct-less styles are passed to
   * `generateCSSRuleset`.
   *
   * For instance, a call to
   *
   *     generateCSSInner(".foo", {
   *       color: "red",
   *       "@media screen": {
   *         height: 20,
   *         ":hover": {
   *           backgroundColor: "black"
   *         }
   *       },
   *       ":active": {
   *         fontWeight: "bold",
   *         ">>bar": {
   *           _names: { "foo_bar": true },
   *           height: 10,
   *         }
   *       }
   *     });
   *
   * will make 5 calls to `generateCSSRuleset`:
   *
   *     generateCSSRuleset(".foo", { color: "red" }, ...)
   *     generateCSSRuleset(".foo:active", { fontWeight: "bold" }, ...)
   *     generateCSSRuleset(".foo:active .foo_bar", { height: 10 }, ...)
   *     // These 2 will be wrapped in @media screen {}
   *     generateCSSRuleset(".foo", { height: 20 }, ...)
   *     generateCSSRuleset(".foo:hover", { backgroundColor: "black" }, ...)
   */
  var generateCSS = function generateCSS(selector, styleTypes, stringHandlers, useImportant) {
      var merged = styleTypes.reduce(_util.recursiveMerge);
  
      var declarations = {};
      var mediaQueries = {};
      var pseudoStyles = {};
  
      Object.keys(merged).forEach(function (key) {
          if (key[0] === ':') {
              pseudoStyles[key] = merged[key];
          } else if (key[0] === '@') {
              mediaQueries[key] = merged[key];
          } else {
              declarations[key] = merged[key];
          }
      });
  
      return generateCSSRuleset(selector, declarations, stringHandlers, useImportant) + Object.keys(pseudoStyles).map(function (pseudoSelector) {
          return generateCSSRuleset(selector + pseudoSelector, pseudoStyles[pseudoSelector], stringHandlers, useImportant);
      }).join("") + Object.keys(mediaQueries).map(function (mediaQuery) {
          var ruleset = generateCSS(selector, [mediaQueries[mediaQuery]], stringHandlers, useImportant);
          return mediaQuery + '{' + ruleset + '}';
      }).join("");
  };
  
  exports.generateCSS = generateCSS;
  /**
   * Helper method of generateCSSRuleset to facilitate custom handling of certain
   * CSS properties. Used for e.g. font families.
   *
   * See generateCSSRuleset for usage and documentation of paramater types.
   */
  var runStringHandlers = function runStringHandlers(declarations, stringHandlers) {
      var result = {};
  
      Object.keys(declarations).forEach(function (key) {
          // If a handler exists for this particular key, let it interpret
          // that value first before continuing
          if (stringHandlers && stringHandlers.hasOwnProperty(key)) {
              result[key] = stringHandlers[key](declarations[key]);
          } else {
              result[key] = declarations[key];
          }
      });
  
      return result;
  };
  
  /**
   * Generate a CSS ruleset with the selector and containing the declarations.
   *
   * This function assumes that the given declarations don't contain any special
   * children (such as media queries, pseudo-selectors, or descendant styles).
   *
   * Note that this method does not deal with nesting used for e.g.
   * psuedo-selectors or media queries. That responsibility is left to  the
   * `generateCSS` function.
   *
   * @param {string} selector: the selector associated with the ruleset
   * @param {Object} declarations: a map from camelCased CSS property name to CSS
   *     property value.
   * @param {Object.<string, function>} stringHandlers: a map from camelCased CSS
   *     property name to a function which will map the given value to the value
   *     that is output.
   * @param {bool} useImportant: A boolean saying whether to append "!important"
   *     to each of the CSS declarations.
   * @returns {string} A string of raw CSS.
   *
   * Examples:
   *
   *    generateCSSRuleset(".blah", { color: "red" })
   *    -> ".blah{color: red !important;}"
   *    generateCSSRuleset(".blah", { color: "red" }, {}, false)
   *    -> ".blah{color: red}"
   *    generateCSSRuleset(".blah", { color: "red" }, {color: c => c.toUpperCase})
   *    -> ".blah{color: RED}"
   *    generateCSSRuleset(".blah:hover", { color: "red" })
   *    -> ".blah:hover{color: red}"
   */
  var generateCSSRuleset = function generateCSSRuleset(selector, declarations, stringHandlers, useImportant) {
      var handledDeclarations = runStringHandlers(declarations, stringHandlers);
  
      var prefixedDeclarations = (0, _inlineStylePrefixerStatic2['default'])(handledDeclarations);
  
      var prefixedRules = (0, _util.flatten)((0, _util.objectToPairs)(prefixedDeclarations).map(function (_ref) {
          var _ref2 = _slicedToArray(_ref, 2);
  
          var key = _ref2[0];
          var value = _ref2[1];
  
          if (Array.isArray(value)) {
              var _ret = (function () {
                  // inline-style-prefix-all returns an array when there should be
                  // multiple rules, we will flatten to single rules
  
                  var prefixedValues = [];
                  var unprefixedValues = [];
  
                  value.forEach(function (v) {
                      if (v.indexOf('-') === 0) {
                          prefixedValues.push(v);
                      } else {
                          unprefixedValues.push(v);
                      }
                  });
  
                  prefixedValues.sort();
                  unprefixedValues.sort();
  
                  return {
                      v: prefixedValues.concat(unprefixedValues).map(function (v) {
                          return [key, v];
                      })
                  };
              })();
  
              if (typeof _ret === 'object') return _ret.v;
          }
          return [[key, value]];
      }));
  
      var rules = prefixedRules.map(function (_ref3) {
          var _ref32 = _slicedToArray(_ref3, 2);
  
          var key = _ref32[0];
          var value = _ref32[1];
  
          var stringValue = (0, _util.stringifyValue)(key, value);
          var ret = (0, _util.kebabifyStyleName)(key) + ':' + stringValue + ';';
          return useImportant === false ? ret : (0, _util.importantify)(ret);
      }).join("");
  
      if (rules) {
          return selector + '{' + rules + '}';
      } else {
          return "";
      }
  };
  exports.generateCSSRuleset = generateCSSRuleset;
  },{"./util":5,"inline-style-prefixer/static":23}],2:[function(require,module,exports){
  'use strict';
  
  Object.defineProperty(exports, '__esModule', {
      value: true
  });
  
  var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })();
  
  var _util = require('./util');
  
  var _inject = require('./inject');
  
  var StyleSheet = {
      create: function create(sheetDefinition) {
          return (0, _util.mapObj)(sheetDefinition, function (_ref) {
              var _ref2 = _slicedToArray(_ref, 2);
  
              var key = _ref2[0];
              var val = _ref2[1];
  
              return [key, {
                  // TODO(emily): Make a 'production' mode which doesn't prepend
                  // the class name here, to make the generated CSS smaller.
                  _name: key + '_' + (0, _util.hashObject)(val),
                  _definition: val
              }];
          });
      },
  
      rehydrate: function rehydrate() {
          var renderedClassNames = arguments.length <= 0 || arguments[0] === undefined ? [] : arguments[0];
  
          (0, _inject.addRenderedClassNames)(renderedClassNames);
      }
  };
  
  /**
   * Utilities for using Aphrodite server-side.
   */
  var StyleSheetServer = {
      renderStatic: function renderStatic(renderFunc) {
          (0, _inject.reset)();
          (0, _inject.startBuffering)();
          var html = renderFunc();
          var cssContent = (0, _inject.flushToString)();
  
          return {
              html: html,
              css: {
                  content: cssContent,
                  renderedClassNames: (0, _inject.getRenderedClassNames)()
              }
          };
      }
  };
  
  /**
   * Utilities for using Aphrodite in tests.
   *
   * Not meant to be used in production.
   */
  var StyleSheetTestUtils = {
      /**
       * Prevent styles from being injected into the DOM.
       *
       * This is useful in situations where you'd like to test rendering UI
       * components which use Aphrodite without any of the side-effects of
       * Aphrodite happening. Particularly useful for testing the output of
       * components when you have no DOM, e.g. testing in Node without a fake DOM.
       *
       * Should be paired with a subsequent call to
       * clearBufferAndResumeStyleInjection.
       */
      suppressStyleInjection: function suppressStyleInjection() {
          (0, _inject.reset)();
          (0, _inject.startBuffering)();
      },
  
      /**
       * Opposite method of preventStyleInject.
       */
      clearBufferAndResumeStyleInjection: function clearBufferAndResumeStyleInjection() {
          (0, _inject.reset)();
      }
  };
  
  var css = function css() {
      for (var _len = arguments.length, styleDefinitions = Array(_len), _key = 0; _key < _len; _key++) {
          styleDefinitions[_key] = arguments[_key];
      }
  
      var useImportant = true; // Append !important to all style definitions
      return (0, _inject.injectAndGetClassName)(useImportant, styleDefinitions);
  };
  
  exports['default'] = {
      StyleSheet: StyleSheet,
      StyleSheetServer: StyleSheetServer,
      StyleSheetTestUtils: StyleSheetTestUtils,
      css: css
  };
  module.exports = exports['default'];
  },{"./inject":3,"./util":5}],3:[function(require,module,exports){
  'use strict';
  
  Object.defineProperty(exports, '__esModule', {
      value: true
  });
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
  
  var _asap = require('asap');
  
  var _asap2 = _interopRequireDefault(_asap);
  
  var _generate = require('./generate');
  
  var _util = require('./util');
  
  // The current <style> tag we are inserting into, or null if we haven't
  // inserted anything yet. We could find this each time using
  // `document.querySelector("style[data-aphrodite"])`, but holding onto it is
  // faster.
  var styleTag = null;
  
  // Inject a string of styles into a <style> tag in the head of the document. This
  // will automatically create a style tag and then continue to use it for
  // multiple injections. It will also use a style tag with the `data-aphrodite`
  // tag on it if that exists in the DOM. This could be used for e.g. reusing the
  // same style tag that server-side rendering inserts.
  var injectStyleTag = function injectStyleTag(cssContents) {
      if (styleTag == null) {
          // Try to find a style tag with the `data-aphrodite` attribute first.
          styleTag = document.querySelector("style[data-aphrodite]");
  
          // If that doesn't work, generate a new style tag.
          if (styleTag == null) {
              // Taken from
              // http://stackoverflow.com/questions/524696/how-to-create-a-style-tag-with-javascript
              var head = document.head || document.getElementsByTagName('head')[0];
              styleTag = document.createElement('style');
  
              styleTag.type = 'text/css';
              styleTag.setAttribute("data-aphrodite", "");
              head.appendChild(styleTag);
          }
      }
  
      if (styleTag.styleSheet) {
          styleTag.styleSheet.cssText += cssContents;
      } else {
          styleTag.appendChild(document.createTextNode(cssContents));
      }
  };
  
  // Custom handlers for stringifying CSS values that have side effects
  // (such as fontFamily, which can cause @font-face rules to be injected)
  var stringHandlers = {
      // With fontFamily we look for objects that are passed in and interpret
      // them as @font-face rules that we need to inject. The value of fontFamily
      // can either be a string (as normal), an object (a single font face), or
      // an array of objects and strings.
      fontFamily: function fontFamily(val) {
          if (Array.isArray(val)) {
              return val.map(fontFamily).join(",");
          } else if (typeof val === "object") {
              injectStyleOnce(val.fontFamily, "@font-face", [val], false);
              return '"' + val.fontFamily + '"';
          } else {
              return val;
          }
      },
  
      // With animationName we look for an object that contains keyframes and
      // inject them as an `@keyframes` block, returning a uniquely generated
      // name. The keyframes object should look like
      //  animationName: {
      //    from: {
      //      left: 0,
      //      top: 0,
      //    },
      //    '50%': {
      //      left: 15,
      //      top: 5,
      //    },
      //    to: {
      //      left: 20,
      //      top: 20,
      //    }
      //  }
      // TODO(emily): `stringHandlers` doesn't let us rename the key, so I have
      // to use `animationName` here. Improve that so we can call this
      // `animation` instead of `animationName`.
      animationName: function animationName(val) {
          if (typeof val !== "object") {
              return val;
          }
  
          // Generate a unique name based on the hash of the object. We can't
          // just use the hash because the name can't start with a number.
          // TODO(emily): this probably makes debugging hard, allow a custom
          // name?
          var name = 'keyframe_' + (0, _util.hashObject)(val);
  
          // Since keyframes need 3 layers of nesting, we use `generateCSS` to
          // build the inner layers and wrap it in `@keyframes` ourselves.
          var finalVal = '@keyframes ' + name + '{';
          Object.keys(val).forEach(function (key) {
              finalVal += (0, _generate.generateCSS)(key, [val[key]], stringHandlers, false);
          });
          finalVal += '}';
  
          injectGeneratedCSSOnce(name, finalVal);
  
          return name;
      }
  };
  
  // This is a map from Aphrodite's generated class names to `true` (acting as a
  // set of class names)
  var alreadyInjected = {};
  
  // This is the buffer of styles which have not yet been flushed.
  var injectionBuffer = "";
  
  // A flag to tell if we are already buffering styles. This could happen either
  // because we scheduled a flush call already, so newly added styles will
  // already be flushed, or because we are statically buffering on the server.
  var isBuffering = false;
  
  var injectGeneratedCSSOnce = function injectGeneratedCSSOnce(key, generatedCSS) {
      if (!alreadyInjected[key]) {
          if (!isBuffering) {
              // We should never be automatically buffering on the server (or any
              // place without a document), so guard against that.
              if (typeof document === "undefined") {
                  throw new Error("Cannot automatically buffer without a document");
              }
  
              // If we're not already buffering, schedule a call to flush the
              // current styles.
              isBuffering = true;
              (0, _asap2['default'])(flushToStyleTag);
          }
  
          injectionBuffer += generatedCSS;
          alreadyInjected[key] = true;
      }
  };
  
  var injectStyleOnce = function injectStyleOnce(key, selector, definitions, useImportant) {
      if (!alreadyInjected[key]) {
          var generated = (0, _generate.generateCSS)(selector, definitions, stringHandlers, useImportant);
  
          injectGeneratedCSSOnce(key, generated);
      }
  };
  
  exports.injectStyleOnce = injectStyleOnce;
  var reset = function reset() {
      injectionBuffer = "";
      alreadyInjected = {};
      isBuffering = false;
      styleTag = null;
  };
  
  exports.reset = reset;
  var startBuffering = function startBuffering() {
      if (isBuffering) {
          throw new Error("Cannot buffer while already buffering");
      }
      isBuffering = true;
  };
  
  exports.startBuffering = startBuffering;
  var flushToString = function flushToString() {
      isBuffering = false;
      var ret = injectionBuffer;
      injectionBuffer = "";
      return ret;
  };
  
  exports.flushToString = flushToString;
  var flushToStyleTag = function flushToStyleTag() {
      var cssContent = flushToString();
      if (cssContent.length > 0) {
          injectStyleTag(cssContent);
      }
  };
  
  exports.flushToStyleTag = flushToStyleTag;
  var getRenderedClassNames = function getRenderedClassNames() {
      return Object.keys(alreadyInjected);
  };
  
  exports.getRenderedClassNames = getRenderedClassNames;
  var addRenderedClassNames = function addRenderedClassNames(classNames) {
      classNames.forEach(function (className) {
          alreadyInjected[className] = true;
      });
  };
  
  exports.addRenderedClassNames = addRenderedClassNames;
  /**
   * Inject styles associated with the passed style definition objects, and return
   * an associated CSS class name.
   *
   * @param {boolean} useImportant If true, will append !important to generated
   *     CSS output. e.g. {color: red} -> "color: red !important".
   * @param {Object[]} styleDefinitions style definition objects as returned as
   *     properties of the return value of StyleSheet.create().
   */
  var injectAndGetClassName = function injectAndGetClassName(useImportant, styleDefinitions) {
      // Filter out falsy values from the input, to allow for
      // `css(a, test && c)`
      var validDefinitions = styleDefinitions.filter(function (def) {
          return def;
      });
  
      // Break if there aren't any valid styles.
      if (validDefinitions.length === 0) {
          return "";
      }
  
      var className = validDefinitions.map(function (s) {
          return s._name;
      }).join("-o_O-");
      injectStyleOnce(className, '.' + className, validDefinitions.map(function (d) {
          return d._definition;
      }), useImportant);
  
      return className;
  };
  exports.injectAndGetClassName = injectAndGetClassName;
  },{"./generate":1,"./util":5,"asap":7}],4:[function(require,module,exports){
  // Module with the same interface as the core aphrodite module,
  // except that styles injected do not automatically have !important
  // appended to them.
  //
  'use strict';
  
  Object.defineProperty(exports, '__esModule', {
      value: true
  });
  
  var _inject = require('./inject');
  
  var _indexJs = require('./index.js');
  
  var css = function css() {
      for (var _len = arguments.length, styleDefinitions = Array(_len), _key = 0; _key < _len; _key++) {
          styleDefinitions[_key] = arguments[_key];
      }
  
      var useImportant = false; // Don't append !important to style definitions
      return (0, _inject.injectAndGetClassName)(useImportant, styleDefinitions);
  };
  
  exports.StyleSheet = _indexJs.StyleSheet;
  exports.StyleSheetServer = _indexJs.StyleSheetServer;
  exports.StyleSheetTestUtils = _indexJs.StyleSheetTestUtils;
  exports.css = css;
  },{"./index.js":2,"./inject":3}],5:[function(require,module,exports){
  // {K1: V1, K2: V2, ...} -> [[K1, V1], [K2, V2]]
  'use strict';
  
  Object.defineProperty(exports, '__esModule', {
      value: true
  });
  
  var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i['return']) _i['return'](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError('Invalid attempt to destructure non-iterable instance'); } }; })();
  
  var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
  
  var objectToPairs = function objectToPairs(obj) {
      return Object.keys(obj).map(function (key) {
          return [key, obj[key]];
      });
  };
  
  exports.objectToPairs = objectToPairs;
  // [[K1, V1], [K2, V2]] -> {K1: V1, K2: V2, ...}
  var pairsToObject = function pairsToObject(pairs) {
      var result = {};
      pairs.forEach(function (_ref) {
          var _ref2 = _slicedToArray(_ref, 2);
  
          var key = _ref2[0];
          var val = _ref2[1];
  
          result[key] = val;
      });
      return result;
  };
  
  var mapObj = function mapObj(obj, fn) {
      return pairsToObject(objectToPairs(obj).map(fn));
  };
  
  exports.mapObj = mapObj;
  // Flattens an array one level
  // [[A], [B, C, [D]]] -> [A, B, C, [D]]
  var flatten = function flatten(list) {
      return list.reduce(function (memo, x) {
          return memo.concat(x);
      }, []);
  };
  
  exports.flatten = flatten;
  var UPPERCASE_RE = /([A-Z])/g;
  var MS_RE = /^ms-/;
  
  var kebabify = function kebabify(string) {
      return string.replace(UPPERCASE_RE, '-$1').toLowerCase();
  };
  var kebabifyStyleName = function kebabifyStyleName(string) {
      return kebabify(string).replace(MS_RE, '-ms-');
  };
  
  exports.kebabifyStyleName = kebabifyStyleName;
  var recursiveMerge = function recursiveMerge(a, b) {
      // TODO(jlfwong): Handle malformed input where a and b are not the same
      // type.
  
      if (typeof a !== 'object') {
          return b;
      }
  
      var ret = _extends({}, a);
  
      Object.keys(b).forEach(function (key) {
          if (ret.hasOwnProperty(key)) {
              ret[key] = recursiveMerge(a[key], b[key]);
          } else {
              ret[key] = b[key];
          }
      });
  
      return ret;
  };
  
  exports.recursiveMerge = recursiveMerge;
  /**
   * CSS properties which accept numbers but are not in units of "px".
   * Taken from React's CSSProperty.js
   */
  var isUnitlessNumber = {
      animationIterationCount: true,
      borderImageOutset: true,
      borderImageSlice: true,
      borderImageWidth: true,
      boxFlex: true,
      boxFlexGroup: true,
      boxOrdinalGroup: true,
      columnCount: true,
      flex: true,
      flexGrow: true,
      flexPositive: true,
      flexShrink: true,
      flexNegative: true,
      flexOrder: true,
      gridRow: true,
      gridColumn: true,
      fontWeight: true,
      lineClamp: true,
      lineHeight: true,
      opacity: true,
      order: true,
      orphans: true,
      tabSize: true,
      widows: true,
      zIndex: true,
      zoom: true,
  
      // SVG-related properties
      fillOpacity: true,
      floodOpacity: true,
      stopOpacity: true,
      strokeDasharray: true,
      strokeDashoffset: true,
      strokeMiterlimit: true,
      strokeOpacity: true,
      strokeWidth: true
  };
  
  /**
   * Taken from React's CSSProperty.js
   *
   * @param {string} prefix vendor-specific prefix, eg: Webkit
   * @param {string} key style name, eg: transitionDuration
   * @return {string} style name prefixed with `prefix`, properly camelCased, eg:
   * WebkitTransitionDuration
   */
  function prefixKey(prefix, key) {
      return prefix + key.charAt(0).toUpperCase() + key.substring(1);
  }
  
  /**
   * Support style names that may come passed in prefixed by adding permutations
   * of vendor prefixes.
   * Taken from React's CSSProperty.js
   */
  var prefixes = ['Webkit', 'ms', 'Moz', 'O'];
  
  // Using Object.keys here, or else the vanilla for-in loop makes IE8 go into an
  // infinite loop, because it iterates over the newly added props too.
  // Taken from React's CSSProperty.js
  Object.keys(isUnitlessNumber).forEach(function (prop) {
      prefixes.forEach(function (prefix) {
          isUnitlessNumber[prefixKey(prefix, prop)] = isUnitlessNumber[prop];
      });
  });
  
  var stringifyValue = function stringifyValue(key, prop) {
      if (typeof prop === "number") {
          if (isUnitlessNumber[key]) {
              return "" + prop;
          } else {
              return prop + "px";
          }
      } else {
          return prop;
      }
  };
  
  exports.stringifyValue = stringifyValue;
  /**
   * JS Implementation of MurmurHash2
   *
   * @author <a href="mailto:gary.court@gmail.com">Gary Court</a>
   * @see http://github.com/garycourt/murmurhash-js
   * @author <a href="mailto:aappleby@gmail.com">Austin Appleby</a>
   * @see http://sites.google.com/site/murmurhash/
   *
   * @param {string} str ASCII only
   * @return {string} Base 36 encoded hash result
   */
  function murmurhash2_32_gc(str) {
      var l = str.length;
      var h = l;
      var i = 0;
      var k = undefined;
  
      while (l >= 4) {
          k = str.charCodeAt(i) & 0xff | (str.charCodeAt(++i) & 0xff) << 8 | (str.charCodeAt(++i) & 0xff) << 16 | (str.charCodeAt(++i) & 0xff) << 24;
  
          k = (k & 0xffff) * 0x5bd1e995 + (((k >>> 16) * 0x5bd1e995 & 0xffff) << 16);
          k ^= k >>> 24;
          k = (k & 0xffff) * 0x5bd1e995 + (((k >>> 16) * 0x5bd1e995 & 0xffff) << 16);
  
          h = (h & 0xffff) * 0x5bd1e995 + (((h >>> 16) * 0x5bd1e995 & 0xffff) << 16) ^ k;
  
          l -= 4;
          ++i;
      }
  
      switch (l) {
          case 3:
              h ^= (str.charCodeAt(i + 2) & 0xff) << 16;
          case 2:
              h ^= (str.charCodeAt(i + 1) & 0xff) << 8;
          case 1:
              h ^= str.charCodeAt(i) & 0xff;
              h = (h & 0xffff) * 0x5bd1e995 + (((h >>> 16) * 0x5bd1e995 & 0xffff) << 16);
      }
  
      h ^= h >>> 13;
      h = (h & 0xffff) * 0x5bd1e995 + (((h >>> 16) * 0x5bd1e995 & 0xffff) << 16);
      h ^= h >>> 15;
  
      return (h >>> 0).toString(36);
  }
  
  // Hash a javascript object using JSON.stringify. This is very fast, about 3
  // microseconds on my computer for a sample object:
  // http://jsperf.com/test-hashfnv32a-hash/5
  //
  // Note that this uses JSON.stringify to stringify the objects so in order for
  // this to produce consistent hashes browsers need to have a consistent
  // ordering of objects. Ben Alpert says that Facebook depends on this, so we
  // can probably depend on this too.
  var hashObject = function hashObject(object) {
      return murmurhash2_32_gc(JSON.stringify(object));
  };
  
  exports.hashObject = hashObject;
  var IMPORTANT_RE = /^([^:]+:.*?)( !important)?;$/;
  
  // Given a single style rule string like "a: b;", adds !important to generate
  // "a: b !important;".
  var importantify = function importantify(string) {
      return string.replace(IMPORTANT_RE, function (_, base, important) {
          return base + " !important;";
      });
  };
  exports.importantify = importantify;
  },{}],6:[function(require,module,exports){
  module.exports = require('./lib/no-important.js');
  
  },{"./lib/no-important.js":4}],7:[function(require,module,exports){
  "use strict";
  
  // rawAsap provides everything we need except exception management.
  var rawAsap = require("./raw");
  // RawTasks are recycled to reduce GC churn.
  var freeTasks = [];
  // We queue errors to ensure they are thrown in right order (FIFO).
  // Array-as-queue is good enough here, since we are just dealing with exceptions.
  var pendingErrors = [];
  var requestErrorThrow = rawAsap.makeRequestCallFromTimer(throwFirstError);
  
  function throwFirstError() {
      if (pendingErrors.length) {
          throw pendingErrors.shift();
      }
  }
  
  /**
   * Calls a task as soon as possible after returning, in its own event, with priority
   * over other events like animation, reflow, and repaint. An error thrown from an
   * event will not interrupt, nor even substantially slow down the processing of
   * other events, but will be rather postponed to a lower priority event.
   * @param {{call}} task A callable object, typically a function that takes no
   * arguments.
   */
  module.exports = asap;
  function asap(task) {
      var rawTask;
      if (freeTasks.length) {
          rawTask = freeTasks.pop();
      } else {
          rawTask = new RawTask();
      }
      rawTask.task = task;
      rawAsap(rawTask);
  }
  
  // We wrap tasks with recyclable task objects.  A task object implements
  // `call`, just like a function.
  function RawTask() {
      this.task = null;
  }
  
  // The sole purpose of wrapping the task is to catch the exception and recycle
  // the task object after its single use.
  RawTask.prototype.call = function () {
      try {
          this.task.call();
      } catch (error) {
          if (asap.onerror) {
              // This hook exists purely for testing purposes.
              // Its name will be periodically randomized to break any code that
              // depends on its existence.
              asap.onerror(error);
          } else {
              // In a web browser, exceptions are not fatal. However, to avoid
              // slowing down the queue of pending tasks, we rethrow the error in a
              // lower priority turn.
              pendingErrors.push(error);
              requestErrorThrow();
          }
      } finally {
          this.task = null;
          freeTasks[freeTasks.length] = this;
      }
  };
  
  },{"./raw":8}],8:[function(require,module,exports){
  (function (global){
  "use strict";
  
  // Use the fastest means possible to execute a task in its own turn, with
  // priority over other events including IO, animation, reflow, and redraw
  // events in browsers.
  //
  // An exception thrown by a task will permanently interrupt the processing of
  // subsequent tasks. The higher level `asap` function ensures that if an
  // exception is thrown by a task, that the task queue will continue flushing as
  // soon as possible, but if you use `rawAsap` directly, you are responsible to
  // either ensure that no exceptions are thrown from your task, or to manually
  // call `rawAsap.requestFlush` if an exception is thrown.
  module.exports = rawAsap;
  function rawAsap(task) {
      if (!queue.length) {
          requestFlush();
          flushing = true;
      }
      // Equivalent to push, but avoids a function call.
      queue[queue.length] = task;
  }
  
  var queue = [];
  // Once a flush has been requested, no further calls to `requestFlush` are
  // necessary until the next `flush` completes.
  var flushing = false;
  // `requestFlush` is an implementation-specific method that attempts to kick
  // off a `flush` event as quickly as possible. `flush` will attempt to exhaust
  // the event queue before yielding to the browser's own event loop.
  var requestFlush;
  // The position of the next task to execute in the task queue. This is
  // preserved between calls to `flush` so that it can be resumed if
  // a task throws an exception.
  var index = 0;
  // If a task schedules additional tasks recursively, the task queue can grow
  // unbounded. To prevent memory exhaustion, the task queue will periodically
  // truncate already-completed tasks.
  var capacity = 1024;
  
  // The flush function processes all tasks that have been scheduled with
  // `rawAsap` unless and until one of those tasks throws an exception.
  // If a task throws an exception, `flush` ensures that its state will remain
  // consistent and will resume where it left off when called again.
  // However, `flush` does not make any arrangements to be called again if an
  // exception is thrown.
  function flush() {
      while (index < queue.length) {
          var currentIndex = index;
          // Advance the index before calling the task. This ensures that we will
          // begin flushing on the next task the task throws an error.
          index = index + 1;
          queue[currentIndex].call();
          // Prevent leaking memory for long chains of recursive calls to `asap`.
          // If we call `asap` within tasks scheduled by `asap`, the queue will
          // grow, but to avoid an O(n) walk for every task we execute, we don't
          // shift tasks off the queue after they have been executed.
          // Instead, we periodically shift 1024 tasks off the queue.
          if (index > capacity) {
              // Manually shift all values starting at the index back to the
              // beginning of the queue.
              for (var scan = 0, newLength = queue.length - index; scan < newLength; scan++) {
                  queue[scan] = queue[scan + index];
              }
              queue.length -= index;
              index = 0;
          }
      }
      queue.length = 0;
      index = 0;
      flushing = false;
  }
  
  // `requestFlush` is implemented using a strategy based on data collected from
  // every available SauceLabs Selenium web driver worker at time of writing.
  // https://docs.google.com/spreadsheets/d/1mG-5UYGup5qxGdEMWkhP6BWCz053NUb2E1QoUTU16uA/edit#gid=783724593
  
  // Safari 6 and 6.1 for desktop, iPad, and iPhone are the only browsers that
  // have WebKitMutationObserver but not un-prefixed MutationObserver.
  // Must use `global` instead of `window` to work in both frames and web
  // workers. `global` is a provision of Browserify, Mr, Mrs, or Mop.
  var BrowserMutationObserver = global.MutationObserver || global.WebKitMutationObserver;
  
  // MutationObservers are desirable because they have high priority and work
  // reliably everywhere they are implemented.
  // They are implemented in all modern browsers.
  //
  // - Android 4-4.3
  // - Chrome 26-34
  // - Firefox 14-29
  // - Internet Explorer 11
  // - iPad Safari 6-7.1
  // - iPhone Safari 7-7.1
  // - Safari 6-7
  if (typeof BrowserMutationObserver === "function") {
      requestFlush = makeRequestCallFromMutationObserver(flush);
  
  // MessageChannels are desirable because they give direct access to the HTML
  // task queue, are implemented in Internet Explorer 10, Safari 5.0-1, and Opera
  // 11-12, and in web workers in many engines.
  // Although message channels yield to any queued rendering and IO tasks, they
  // would be better than imposing the 4ms delay of timers.
  // However, they do not work reliably in Internet Explorer or Safari.
  
  // Internet Explorer 10 is the only browser that has setImmediate but does
  // not have MutationObservers.
  // Although setImmediate yields to the browser's renderer, it would be
  // preferrable to falling back to setTimeout since it does not have
  // the minimum 4ms penalty.
  // Unfortunately there appears to be a bug in Internet Explorer 10 Mobile (and
  // Desktop to a lesser extent) that renders both setImmediate and
  // MessageChannel useless for the purposes of ASAP.
  // https://github.com/kriskowal/q/issues/396
  
  // Timers are implemented universally.
  // We fall back to timers in workers in most engines, and in foreground
  // contexts in the following browsers.
  // However, note that even this simple case requires nuances to operate in a
  // broad spectrum of browsers.
  //
  // - Firefox 3-13
  // - Internet Explorer 6-9
  // - iPad Safari 4.3
  // - Lynx 2.8.7
  } else {
      requestFlush = makeRequestCallFromTimer(flush);
  }
  
  // `requestFlush` requests that the high priority event queue be flushed as
  // soon as possible.
  // This is useful to prevent an error thrown in a task from stalling the event
  // queue if the exception handled by Node.js’s
  // `process.on("uncaughtException")` or by a domain.
  rawAsap.requestFlush = requestFlush;
  
  // To request a high priority event, we induce a mutation observer by toggling
  // the text of a text node between "1" and "-1".
  function makeRequestCallFromMutationObserver(callback) {
      var toggle = 1;
      var observer = new BrowserMutationObserver(callback);
      var node = document.createTextNode("");
      observer.observe(node, {characterData: true});
      return function requestCall() {
          toggle = -toggle;
          node.data = toggle;
      };
  }
  
  // The message channel technique was discovered by Malte Ubl and was the
  // original foundation for this library.
  // http://www.nonblocking.io/2011/06/windownexttick.html
  
  // Safari 6.0.5 (at least) intermittently fails to create message ports on a
  // page's first load. Thankfully, this version of Safari supports
  // MutationObservers, so we don't need to fall back in that case.
  
  // function makeRequestCallFromMessageChannel(callback) {
  //     var channel = new MessageChannel();
  //     channel.port1.onmessage = callback;
  //     return function requestCall() {
  //         channel.port2.postMessage(0);
  //     };
  // }
  
  // For reasons explained above, we are also unable to use `setImmediate`
  // under any circumstances.
  // Even if we were, there is another bug in Internet Explorer 10.
  // It is not sufficient to assign `setImmediate` to `requestFlush` because
  // `setImmediate` must be called *by name* and therefore must be wrapped in a
  // closure.
  // Never forget.
  
  // function makeRequestCallFromSetImmediate(callback) {
  //     return function requestCall() {
  //         setImmediate(callback);
  //     };
  // }
  
  // Safari 6.0 has a problem where timers will get lost while the user is
  // scrolling. This problem does not impact ASAP because Safari 6.0 supports
  // mutation observers, so that implementation is used instead.
  // However, if we ever elect to use timers in Safari, the prevalent work-around
  // is to add a scroll event listener that calls for a flush.
  
  // `setTimeout` does not call the passed callback if the delay is less than
  // approximately 7 in web workers in Firefox 8 through 18, and sometimes not
  // even then.
  
  function makeRequestCallFromTimer(callback) {
      return function requestCall() {
          // We dispatch a timeout with a specified delay of 0 for engines that
          // can reliably accommodate that request. This will usually be snapped
          // to a 4 milisecond delay, but once we're flushing, there's no delay
          // between events.
          var timeoutHandle = setTimeout(handleTimer, 0);
          // However, since this timer gets frequently dropped in Firefox
          // workers, we enlist an interval handle that will try to fire
          // an event 20 times per second until it succeeds.
          var intervalHandle = setInterval(handleTimer, 50);
  
          function handleTimer() {
              // Whichever timer succeeds will cancel both timers and
              // execute the callback.
              clearTimeout(timeoutHandle);
              clearInterval(intervalHandle);
              callback();
          }
      };
  }
  
  // This is for `asap.js` only.
  // Its name will be periodically randomized to break any code that depends on
  // its existence.
  rawAsap.makeRequestCallFromTimer = makeRequestCallFromTimer;
  
  // ASAP was originally a nextTick shim included in Q. This was factored out
  // into this ASAP package. It was later adapted to RSVP which made further
  // amendments. These decisions, particularly to marginalize MessageChannel and
  // to capture the MutationObserver implementation in a closure, were integrated
  // back into ASAP proper.
  // https://github.com/tildeio/rsvp.js/blob/cddf7232546a9cf858524b75cde6f9edf72620a7/lib/rsvp/asap.js
  
  }).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
  },{}],9:[function(require,module,exports){
  'use strict';
  
  var uppercasePattern = /[A-Z]/g;
  var msPattern = /^ms-/;
  
  function hyphenateStyleName(string) {
      return string
          .replace(uppercasePattern, '-$&')
          .toLowerCase()
          .replace(msPattern, '-ms-');
  }
  
  module.exports = hyphenateStyleName;
  
  },{}],10:[function(require,module,exports){
  'use strict';
  
  Object.defineProperty(exports, "__esModule", {
    value: true
  });
  exports.default = calc;
  
  var _joinPrefixedValue = require('../../utils/joinPrefixedValue');
  
  var _joinPrefixedValue2 = _interopRequireDefault(_joinPrefixedValue);
  
  var _isPrefixedValue = require('../../utils/isPrefixedValue');
  
  var _isPrefixedValue2 = _interopRequireDefault(_isPrefixedValue);
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
  
  function calc(property, value) {
    if (typeof value === 'string' && !(0, _isPrefixedValue2.default)(value) && value.indexOf('calc(') > -1) {
      return (0, _joinPrefixedValue2.default)(property, value, function (prefix, value) {
        return value.replace(/calc\(/g, prefix + 'calc(');
      });
    }
  }
  module.exports = exports['default'];
  },{"../../utils/isPrefixedValue":21,"../../utils/joinPrefixedValue":22}],11:[function(require,module,exports){
  'use strict';
  
  Object.defineProperty(exports, "__esModule", {
    value: true
  });
  exports.default = cursor;
  
  var _joinPrefixedValue = require('../../utils/joinPrefixedValue');
  
  var _joinPrefixedValue2 = _interopRequireDefault(_joinPrefixedValue);
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
  
  var values = {
    'zoom-in': true,
    'zoom-out': true,
    grab: true,
    grabbing: true
  };
  
  function cursor(property, value) {
    if (property === 'cursor' && values[value]) {
      return (0, _joinPrefixedValue2.default)(property, value);
    }
  }
  module.exports = exports['default'];
  },{"../../utils/joinPrefixedValue":22}],12:[function(require,module,exports){
  'use strict';
  
  Object.defineProperty(exports, "__esModule", {
    value: true
  });
  exports.default = flex;
  var values = { flex: true, 'inline-flex': true };
  
  function flex(property, value) {
    if (property === 'display' && values[value]) {
      return {
        display: ['-webkit-box', '-moz-box', '-ms-' + value + 'box', '-webkit-' + value, value]
      };
    }
  }
  module.exports = exports['default'];
  },{}],13:[function(require,module,exports){
  'use strict';
  
  Object.defineProperty(exports, "__esModule", {
    value: true
  });
  exports.default = flexboxIE;
  
  function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
  
  var alternativeValues = {
    'space-around': 'distribute',
    'space-between': 'justify',
    'flex-start': 'start',
    'flex-end': 'end'
  };
  var alternativeProps = {
    alignContent: 'msFlexLinePack',
    alignSelf: 'msFlexItemAlign',
    alignItems: 'msFlexAlign',
    justifyContent: 'msFlexPack',
    order: 'msFlexOrder',
    flexGrow: 'msFlexPositive',
    flexShrink: 'msFlexNegative',
    flexBasis: 'msPreferredSize'
  };
  
  function flexboxIE(property, value) {
    if (alternativeProps[property]) {
      return _defineProperty({}, alternativeProps[property], alternativeValues[value] || value);
    }
  }
  module.exports = exports['default'];
  },{}],14:[function(require,module,exports){
  'use strict';
  
  Object.defineProperty(exports, "__esModule", {
    value: true
  });
  exports.default = flexboxOld;
  
  function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
  
  var alternativeValues = {
    'space-around': 'justify',
    'space-between': 'justify',
    'flex-start': 'start',
    'flex-end': 'end',
    'wrap-reverse': 'multiple',
    wrap: 'multiple'
  };
  
  var alternativeProps = {
    alignItems: 'WebkitBoxAlign',
    justifyContent: 'WebkitBoxPack',
    flexWrap: 'WebkitBoxLines'
  };
  
  function flexboxOld(property, value) {
    if (property === 'flexDirection') {
      return {
        WebkitBoxOrient: value.indexOf('column') > -1 ? 'vertical' : 'horizontal',
        WebkitBoxDirection: value.indexOf('reverse') > -1 ? 'reverse' : 'normal'
      };
    }
    if (alternativeProps[property]) {
      return _defineProperty({}, alternativeProps[property], alternativeValues[value] || value);
    }
  }
  module.exports = exports['default'];
  },{}],15:[function(require,module,exports){
  'use strict';
  
  Object.defineProperty(exports, "__esModule", {
    value: true
  });
  exports.default = gradient;
  
  var _joinPrefixedValue = require('../../utils/joinPrefixedValue');
  
  var _joinPrefixedValue2 = _interopRequireDefault(_joinPrefixedValue);
  
  var _isPrefixedValue = require('../../utils/isPrefixedValue');
  
  var _isPrefixedValue2 = _interopRequireDefault(_isPrefixedValue);
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
  
  var values = /linear-gradient|radial-gradient|repeating-linear-gradient|repeating-radial-gradient/;
  
  function gradient(property, value) {
    if (typeof value === 'string' && !(0, _isPrefixedValue2.default)(value) && value.match(values) !== null) {
      return (0, _joinPrefixedValue2.default)(property, value);
    }
  }
  module.exports = exports['default'];
  },{"../../utils/isPrefixedValue":21,"../../utils/joinPrefixedValue":22}],16:[function(require,module,exports){
  'use strict';
  
  Object.defineProperty(exports, "__esModule", {
    value: true
  });
  exports.default = sizing;
  
  var _joinPrefixedValue = require('../../utils/joinPrefixedValue');
  
  var _joinPrefixedValue2 = _interopRequireDefault(_joinPrefixedValue);
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
  
  var properties = {
    maxHeight: true,
    maxWidth: true,
    width: true,
    height: true,
    columnWidth: true,
    minWidth: true,
    minHeight: true
  };
  var values = {
    'min-content': true,
    'max-content': true,
    'fill-available': true,
    'fit-content': true,
    'contain-floats': true
  };
  
  function sizing(property, value) {
    if (properties[property] && values[value]) {
      return (0, _joinPrefixedValue2.default)(property, value);
    }
  }
  module.exports = exports['default'];
  },{"../../utils/joinPrefixedValue":22}],17:[function(require,module,exports){
  'use strict';
  
  Object.defineProperty(exports, "__esModule", {
    value: true
  });
  exports.default = transition;
  
  var _hyphenateStyleName = require('hyphenate-style-name');
  
  var _hyphenateStyleName2 = _interopRequireDefault(_hyphenateStyleName);
  
  var _capitalizeString = require('../../utils/capitalizeString');
  
  var _capitalizeString2 = _interopRequireDefault(_capitalizeString);
  
  var _isPrefixedValue = require('../../utils/isPrefixedValue');
  
  var _isPrefixedValue2 = _interopRequireDefault(_isPrefixedValue);
  
  var _prefixProps = require('../prefixProps');
  
  var _prefixProps2 = _interopRequireDefault(_prefixProps);
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
  
  function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
  
  var properties = {
    transition: true,
    transitionProperty: true,
    WebkitTransition: true,
    WebkitTransitionProperty: true
  };
  
  function transition(property, value) {
    // also check for already prefixed transitions
    if (typeof value === 'string' && properties[property]) {
      var _ref2;
  
      var outputValue = prefixValue(value);
      var webkitOutput = outputValue.split(/,(?![^()]*(?:\([^()]*\))?\))/g).filter(function (value) {
        return value.match(/-moz-|-ms-/) === null;
      }).join(',');
  
      // if the property is already prefixed
      if (property.indexOf('Webkit') > -1) {
        return _defineProperty({}, property, webkitOutput);
      }
  
      return _ref2 = {}, _defineProperty(_ref2, 'Webkit' + (0, _capitalizeString2.default)(property), webkitOutput), _defineProperty(_ref2, property, outputValue), _ref2;
    }
  }
  
  function prefixValue(value) {
    if ((0, _isPrefixedValue2.default)(value)) {
      return value;
    }
  
    // only split multi values, not cubic beziers
    var multipleValues = value.split(/,(?![^()]*(?:\([^()]*\))?\))/g);
  
    // iterate each single value and check for transitioned properties
    // that need to be prefixed as well
    multipleValues.forEach(function (val, index) {
      multipleValues[index] = Object.keys(_prefixProps2.default).reduce(function (out, prefix) {
        var dashCasePrefix = '-' + prefix.toLowerCase() + '-';
  
        Object.keys(_prefixProps2.default[prefix]).forEach(function (prop) {
          var dashCaseProperty = (0, _hyphenateStyleName2.default)(prop);
  
          if (val.indexOf(dashCaseProperty) > -1 && dashCaseProperty !== 'order') {
            // join all prefixes and create a new value
            out = val.replace(dashCaseProperty, dashCasePrefix + dashCaseProperty) + ',' + out;
          }
        });
        return out;
      }, val);
    });
  
    return multipleValues.join(',');
  }
  module.exports = exports['default'];
  },{"../../utils/capitalizeString":20,"../../utils/isPrefixedValue":21,"../prefixProps":19,"hyphenate-style-name":9}],18:[function(require,module,exports){
  'use strict';
  
  Object.defineProperty(exports, "__esModule", {
    value: true
  });
  exports.default = prefixAll;
  
  var _prefixProps = require('./prefixProps');
  
  var _prefixProps2 = _interopRequireDefault(_prefixProps);
  
  var _capitalizeString = require('../utils/capitalizeString');
  
  var _capitalizeString2 = _interopRequireDefault(_capitalizeString);
  
  var _calc = require('./plugins/calc');
  
  var _calc2 = _interopRequireDefault(_calc);
  
  var _cursor = require('./plugins/cursor');
  
  var _cursor2 = _interopRequireDefault(_cursor);
  
  var _flex = require('./plugins/flex');
  
  var _flex2 = _interopRequireDefault(_flex);
  
  var _sizing = require('./plugins/sizing');
  
  var _sizing2 = _interopRequireDefault(_sizing);
  
  var _gradient = require('./plugins/gradient');
  
  var _gradient2 = _interopRequireDefault(_gradient);
  
  var _transition = require('./plugins/transition');
  
  var _transition2 = _interopRequireDefault(_transition);
  
  var _flexboxIE = require('./plugins/flexboxIE');
  
  var _flexboxIE2 = _interopRequireDefault(_flexboxIE);
  
  var _flexboxOld = require('./plugins/flexboxOld');
  
  var _flexboxOld2 = _interopRequireDefault(_flexboxOld);
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
  
  // special flexbox specifications
  
  
  var plugins = [_calc2.default, _cursor2.default, _sizing2.default, _gradient2.default, _transition2.default, _flexboxIE2.default, _flexboxOld2.default, _flex2.default];
  
  /**
   * Returns a prefixed version of the style object using all vendor prefixes
   * @param {Object} styles - Style object that gets prefixed properties added
   * @returns {Object} - Style object with prefixed properties and values
   */
  function prefixAll(styles) {
    Object.keys(styles).forEach(function (property) {
      var value = styles[property];
      if (value instanceof Object && !Array.isArray(value)) {
        // recurse through nested style objects
        styles[property] = prefixAll(value);
      } else {
        Object.keys(_prefixProps2.default).forEach(function (prefix) {
          var properties = _prefixProps2.default[prefix];
          // add prefixes if needed
          if (properties[property]) {
            styles[prefix + (0, _capitalizeString2.default)(property)] = value;
          }
        });
      }
    });
  
    Object.keys(styles).forEach(function (property) {
      [].concat(styles[property]).forEach(function (value, index) {
        // resolve every special plugins
        plugins.forEach(function (plugin) {
          return assignStyles(styles, plugin(property, value));
        });
      });
    });
  
    return styles;
  }
  
  function assignStyles(base) {
    var extend = arguments.length <= 1 || arguments[1] === undefined ? {} : arguments[1];
  
    Object.keys(extend).forEach(function (property) {
      var baseValue = base[property];
      if (Array.isArray(baseValue)) {
        [].concat(extend[property]).forEach(function (value) {
          var valueIndex = baseValue.indexOf(value);
          if (valueIndex > -1) {
            base[property].splice(valueIndex, 1);
          }
          base[property].push(value);
        });
      } else {
        base[property] = extend[property];
      }
    });
  }
  module.exports = exports['default'];
  },{"../utils/capitalizeString":20,"./plugins/calc":10,"./plugins/cursor":11,"./plugins/flex":12,"./plugins/flexboxIE":13,"./plugins/flexboxOld":14,"./plugins/gradient":15,"./plugins/sizing":16,"./plugins/transition":17,"./prefixProps":19}],19:[function(require,module,exports){
  "use strict";
  
  Object.defineProperty(exports, "__esModule", {
    value: true
  });
  exports.default = { "Webkit": { "transform": true, "transformOrigin": true, "transformOriginX": true, "transformOriginY": true, "backfaceVisibility": true, "perspective": true, "perspectiveOrigin": true, "transformStyle": true, "transformOriginZ": true, "animation": true, "animationDelay": true, "animationDirection": true, "animationFillMode": true, "animationDuration": true, "animationIterationCount": true, "animationName": true, "animationPlayState": true, "animationTimingFunction": true, "appearance": true, "userSelect": true, "fontKerning": true, "textEmphasisPosition": true, "textEmphasis": true, "textEmphasisStyle": true, "textEmphasisColor": true, "boxDecorationBreak": true, "clipPath": true, "maskImage": true, "maskMode": true, "maskRepeat": true, "maskPosition": true, "maskClip": true, "maskOrigin": true, "maskSize": true, "maskComposite": true, "mask": true, "maskBorderSource": true, "maskBorderMode": true, "maskBorderSlice": true, "maskBorderWidth": true, "maskBorderOutset": true, "maskBorderRepeat": true, "maskBorder": true, "maskType": true, "textDecorationStyle": true, "textDecorationSkip": true, "textDecorationLine": true, "textDecorationColor": true, "filter": true, "fontFeatureSettings": true, "breakAfter": true, "breakBefore": true, "breakInside": true, "columnCount": true, "columnFill": true, "columnGap": true, "columnRule": true, "columnRuleColor": true, "columnRuleStyle": true, "columnRuleWidth": true, "columns": true, "columnSpan": true, "columnWidth": true, "flex": true, "flexBasis": true, "flexDirection": true, "flexGrow": true, "flexFlow": true, "flexShrink": true, "flexWrap": true, "alignContent": true, "alignItems": true, "alignSelf": true, "justifyContent": true, "order": true, "transition": true, "transitionDelay": true, "transitionDuration": true, "transitionProperty": true, "transitionTimingFunction": true, "backdropFilter": true, "scrollSnapType": true, "scrollSnapPointsX": true, "scrollSnapPointsY": true, "scrollSnapDestination": true, "scrollSnapCoordinate": true, "shapeImageThreshold": true, "shapeImageMargin": true, "shapeImageOutside": true, "hyphens": true, "flowInto": true, "flowFrom": true, "regionFragment": true, "textSizeAdjust": true, "borderImage": true, "borderImageOutset": true, "borderImageRepeat": true, "borderImageSlice": true, "borderImageSource": true, "borderImageWidth": true, "tabSize": true, "objectFit": true, "objectPosition": true }, "Moz": { "appearance": true, "userSelect": true, "boxSizing": true, "textAlignLast": true, "textDecorationStyle": true, "textDecorationSkip": true, "textDecorationLine": true, "textDecorationColor": true, "tabSize": true, "hyphens": true, "fontFeatureSettings": true, "breakAfter": true, "breakBefore": true, "breakInside": true, "columnCount": true, "columnFill": true, "columnGap": true, "columnRule": true, "columnRuleColor": true, "columnRuleStyle": true, "columnRuleWidth": true, "columns": true, "columnSpan": true, "columnWidth": true }, "ms": { "flex": true, "flexBasis": false, "flexDirection": true, "flexGrow": false, "flexFlow": true, "flexShrink": false, "flexWrap": true, "alignContent": false, "alignItems": false, "alignSelf": false, "justifyContent": false, "order": false, "transform": true, "transformOrigin": true, "transformOriginX": true, "transformOriginY": true, "userSelect": true, "wrapFlow": true, "wrapThrough": true, "wrapMargin": true, "scrollSnapType": true, "scrollSnapPointsX": true, "scrollSnapPointsY": true, "scrollSnapDestination": true, "scrollSnapCoordinate": true, "touchAction": true, "hyphens": true, "flowInto": true, "flowFrom": true, "breakBefore": true, "breakAfter": true, "breakInside": true, "regionFragment": true, "gridTemplateColumns": true, "gridTemplateRows": true, "gridTemplateAreas": true, "gridTemplate": true, "gridAutoColumns": true, "gridAutoRows": true, "gridAutoFlow": true, "grid": true, "gridRowStart": true, "gridColumnStart": true, "gridRowEnd": true, "gridRow": true, "gridColumn": true, "gridColumnEnd": true, "gridColumnGap": true, "gridRowGap": true, "gridArea": true, "gridGap": true, "textSizeAdjust": true } };
  module.exports = exports["default"];
  },{}],20:[function(require,module,exports){
  "use strict";
  
  Object.defineProperty(exports, "__esModule", {
    value: true
  });
  // helper to capitalize strings
  
  exports.default = function (str) {
    return str.charAt(0).toUpperCase() + str.slice(1);
  };
  
  module.exports = exports["default"];
  },{}],21:[function(require,module,exports){
  'use strict';
  
  Object.defineProperty(exports, "__esModule", {
    value: true
  });
  
  exports.default = function (value) {
    if (Array.isArray(value)) value = value.join(',');
  
    return value.match(/-webkit-|-moz-|-ms-/) !== null;
  };
  
  module.exports = exports['default'];
  },{}],22:[function(require,module,exports){
  'use strict';
  
  Object.defineProperty(exports, "__esModule", {
    value: true
  });
  
  function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
  
  // returns a style object with a single concated prefixed value string
  
  exports.default = function (property, value) {
    var replacer = arguments.length <= 2 || arguments[2] === undefined ? function (prefix, value) {
      return prefix + value;
    } : arguments[2];
    return _defineProperty({}, property, ['-webkit-', '-moz-', ''].map(function (prefix) {
      return replacer(prefix, value);
    }));
  };
  
  module.exports = exports['default'];
  },{}],23:[function(require,module,exports){
  module.exports = require('./lib/static/prefixAll')
  
  },{"./lib/static/prefixAll":18}],24:[function(require,module,exports){
  (function (global){
  'use strict';
  
  Object.defineProperty(exports, '__esModule', {
  	value: true
  });
  
  var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
  
  var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } };
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
  
  function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }
  
  function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }
  
  var _react = (typeof window !== "undefined" ? window['React'] : typeof global !== "undefined" ? global['React'] : null);
  
  var _react2 = _interopRequireDefault(_react);
  
  var _aphroditeNoImportant = require('aphrodite/no-important');
  
  var _reactScrolllock = require('react-scrolllock');
  
  var _reactScrolllock2 = _interopRequireDefault(_reactScrolllock);
  
  var _theme = require('./theme');
  
  var _theme2 = _interopRequireDefault(_theme);
  
  var _componentsArrow = require('./components/Arrow');
  
  var _componentsArrow2 = _interopRequireDefault(_componentsArrow);
  
  var _componentsContainer = require('./components/Container');
  
  var _componentsContainer2 = _interopRequireDefault(_componentsContainer);
  
  var _componentsFooter = require('./components/Footer');
  
  var _componentsFooter2 = _interopRequireDefault(_componentsFooter);
  
  var _componentsHeader = require('./components/Header');
  
  var _componentsHeader2 = _interopRequireDefault(_componentsHeader);
  
  var _componentsPaginatedThumbnails = require('./components/PaginatedThumbnails');
  
  var _componentsPaginatedThumbnails2 = _interopRequireDefault(_componentsPaginatedThumbnails);
  
  var _componentsPortal = require('./components/Portal');
  
  var _componentsPortal2 = _interopRequireDefault(_componentsPortal);
  
  var _utils = require('./utils');
  
  var Lightbox = (function (_Component) {
  	_inherits(Lightbox, _Component);
  
  	function Lightbox() {
  		_classCallCheck(this, Lightbox);
  
  		_get(Object.getPrototypeOf(Lightbox.prototype), 'constructor', this).call(this);
  
  		_utils.bindFunctions.call(this, ['gotoNext', 'gotoPrev', 'handleKeyboardInput']);
  	}
  
  	_createClass(Lightbox, [{
  		key: 'getChildContext',
  		value: function getChildContext() {
  			return {
  				theme: this.props.theme
  			};
  		}
  	}, {
  		key: 'componentDidMount',
  		value: function componentDidMount() {
  			if (this.props.isOpen && this.props.enableKeyboardInput) {
  				window.addEventListener('keydown', this.handleKeyboardInput);
  			}
  		}
  	}, {
  		key: 'componentWillReceiveProps',
  		value: function componentWillReceiveProps(nextProps) {
  			if (!_utils.canUseDom) return;
  
  			// preload images
  			if (nextProps.preloadNextImage) {
  				var currentIndex = this.props.currentImage;
  				var nextIndex = nextProps.currentImage + 1;
  				var prevIndex = nextProps.currentImage - 1;
  				var preloadIndex = undefined;
  
  				if (currentIndex && nextProps.currentImage > currentIndex) {
  					preloadIndex = nextIndex;
  				} else if (currentIndex && nextProps.currentImage < currentIndex) {
  					preloadIndex = prevIndex;
  				}
  
  				// if we know the user's direction just get one image
  				// otherwise, to be safe, we need to grab one in each direction
  				if (preloadIndex) {
  					this.preloadImage(preloadIndex);
  				} else {
  					this.preloadImage(prevIndex);
  					this.preloadImage(nextIndex);
  				}
  			}
  
  			// add/remove event listeners
  			if (!this.props.isOpen && nextProps.isOpen && nextProps.enableKeyboardInput) {
  				window.addEventListener('keydown', this.handleKeyboardInput);
  			}
  			if (!nextProps.isOpen && nextProps.enableKeyboardInput) {
  				window.removeEventListener('keydown', this.handleKeyboardInput);
  			}
  		}
  	}, {
  		key: 'componentWillUnmount',
  		value: function componentWillUnmount() {
  			if (this.props.enableKeyboardInput) {
  				window.removeEventListener('keydown', this.handleKeyboardInput);
  			}
  		}
  
  		// ==============================
  		// METHODS
  		// ==============================
  
  	}, {
  		key: 'preloadImage',
  		value: function preloadImage(idx) {
  			var image = this.props.images[idx];
  
  			if (!image) return;
  
  			var img = new Image();
  
  			img.src = image.src;
  
  			if (image.srcset) {
  				img.srcset = image.srcset.join();
  			}
  		}
  	}, {
  		key: 'gotoNext',
  		value: function gotoNext(event) {
  			if (this.props.currentImage === this.props.images.length - 1) return;
  			if (event) {
  				event.preventDefault();
  				event.stopPropagation();
  			}
  			this.props.onClickNext();
  		}
  	}, {
  		key: 'gotoPrev',
  		value: function gotoPrev(event) {
  			if (this.props.currentImage === 0) return;
  			if (event) {
  				event.preventDefault();
  				event.stopPropagation();
  			}
  			this.props.onClickPrev();
  		}
  	}, {
  		key: 'handleKeyboardInput',
  		value: function handleKeyboardInput(event) {
  			if (event.keyCode === 37) {
  				// left
  				this.gotoPrev(event);
  				return true;
  			} else if (event.keyCode === 39) {
  				// right
  				this.gotoNext(event);
  				return true;
  			} else if (event.keyCode === 27) {
  				// esc
  				this.props.onClose();
  				return true;
  			}
  			return false;
  		}
  
  		// ==============================
  		// RENDERERS
  		// ==============================
  
  	}, {
  		key: 'renderArrowPrev',
  		value: function renderArrowPrev() {
  			if (this.props.currentImage === 0) return null;
  
  			return _react2['default'].createElement(_componentsArrow2['default'], {
  				direction: 'left',
  				icon: 'arrowLeft',
  				onClick: this.gotoPrev,
  				title: 'Previous (Left arrow key)',
  				type: 'button'
  			});
  		}
  	}, {
  		key: 'renderArrowNext',
  		value: function renderArrowNext() {
  			if (this.props.currentImage === this.props.images.length - 1) return null;
  
  			return _react2['default'].createElement(_componentsArrow2['default'], {
  				direction: 'right',
  				icon: 'arrowRight',
  				onClick: this.gotoNext,
  				title: 'Previous (Right arrow key)',
  				type: 'button'
  			});
  		}
  	}, {
  		key: 'renderDialog',
  		value: function renderDialog() {
  			var _props = this.props;
  			var backdropClosesModal = _props.backdropClosesModal;
  			var customControls = _props.customControls;
  			var isOpen = _props.isOpen;
  			var onClose = _props.onClose;
  			var showCloseButton = _props.showCloseButton;
  			var showThumbnails = _props.showThumbnails;
  			var width = _props.width;
  
  			if (!isOpen) return _react2['default'].createElement('span', { key: 'closed' });
  
  			var offsetThumbnails = 0;
  			if (showThumbnails) {
  				offsetThumbnails = _theme2['default'].thumbnail.size + _theme2['default'].container.gutter.vertical;
  			}
  
  			return _react2['default'].createElement(
  				_componentsContainer2['default'],
  				{
  					key: 'open',
  					onClick: !!backdropClosesModal && onClose,
  					onTouchEnd: !!backdropClosesModal && onClose
  				},
  				_react2['default'].createElement(
  					'div',
  					{ className: (0, _aphroditeNoImportant.css)(classes.content), style: { marginBottom: offsetThumbnails, maxWidth: width } },
  					_react2['default'].createElement(_componentsHeader2['default'], {
  						customControls: customControls,
  						onClose: onClose,
  						showCloseButton: showCloseButton
  					}),
  					this.renderImages()
  				),
  				this.renderThumbnails(),
  				this.renderArrowPrev(),
  				this.renderArrowNext(),
  				_react2['default'].createElement(_reactScrolllock2['default'], null)
  			);
  		}
  	}, {
  		key: 'renderImages',
  		value: function renderImages() {
  			var _props2 = this.props;
  			var currentImage = _props2.currentImage;
  			var images = _props2.images;
  			var imageCountSeparator = _props2.imageCountSeparator;
  			var onClickImage = _props2.onClickImage;
  			var showImageCount = _props2.showImageCount;
  			var showThumbnails = _props2.showThumbnails;
  
  			if (!images || !images.length) return null;
  
  			var image = images[currentImage];
  
  			var srcset = undefined;
  			var sizes = undefined;
  
  			if (image.srcset) {
  				srcset = image.srcset.join();
  				sizes = '100vw';
  			}
  
  			var thumbnailsSize = showThumbnails ? _theme2['default'].thumbnail.size : 0;
  			var heightOffset = _theme2['default'].header.height + _theme2['default'].footer.height + thumbnailsSize + _theme2['default'].container.gutter.vertical + 'px';
  
  			return _react2['default'].createElement(
  				'figure',
  				{ className: (0, _aphroditeNoImportant.css)(classes.figure) },
  				_react2['default'].createElement('img', {
  					className: (0, _aphroditeNoImportant.css)(classes.image),
  					onClick: !!onClickImage && onClickImage,
  					sizes: sizes,
  					src: image.src,
  					srcSet: srcset,
  					style: {
  						cursor: this.props.onClickImage ? 'pointer' : 'auto',
  						maxHeight: 'calc(100vh - ' + heightOffset + ')'
  					}
  				}),
  				_react2['default'].createElement(_componentsFooter2['default'], {
  					caption: images[currentImage].caption,
  					countCurrent: currentImage + 1,
  					countSeparator: imageCountSeparator,
  					countTotal: images.length,
  					showCount: showImageCount
  				})
  			);
  		}
  	}, {
  		key: 'renderThumbnails',
  		value: function renderThumbnails() {
  			var _props3 = this.props;
  			var images = _props3.images;
  			var currentImage = _props3.currentImage;
  			var onClickThumbnail = _props3.onClickThumbnail;
  			var showThumbnails = _props3.showThumbnails;
  			var thumbnailOffset = _props3.thumbnailOffset;
  
  			if (!showThumbnails) return;
  
  			return _react2['default'].createElement(_componentsPaginatedThumbnails2['default'], {
  				currentImage: currentImage,
  				images: images,
  				offset: thumbnailOffset,
  				onClickThumbnail: onClickThumbnail
  			});
  		}
  	}, {
  		key: 'render',
  		value: function render() {
  			return _react2['default'].createElement(
  				_componentsPortal2['default'],
  				null,
  				this.renderDialog()
  			);
  		}
  	}]);
  
  	return Lightbox;
  })(_react.Component);
  
  Lightbox.propTypes = {
  	backdropClosesModal: _react.PropTypes.bool,
  	currentImage: _react.PropTypes.number,
  	customControls: _react.PropTypes.arrayOf(_react.PropTypes.node),
  	enableKeyboardInput: _react.PropTypes.bool,
  	imageCountSeparator: _react.PropTypes.string,
  	images: _react.PropTypes.arrayOf(_react.PropTypes.shape({
  		src: _react.PropTypes.string.isRequired,
  		srcset: _react.PropTypes.array,
  		caption: _react.PropTypes.oneOfType([_react.PropTypes.string, _react.PropTypes.element]),
  		thumbnail: _react.PropTypes.string
  	})).isRequired,
  	isOpen: _react.PropTypes.bool,
  	onClickImage: _react.PropTypes.func,
  	onClickNext: _react.PropTypes.func,
  	onClickPrev: _react.PropTypes.func,
  	onClose: _react.PropTypes.func.isRequired,
  	preloadNextImage: _react.PropTypes.bool,
  	showCloseButton: _react.PropTypes.bool,
  	showImageCount: _react.PropTypes.bool,
  	showThumbnails: _react.PropTypes.bool,
  	theme: _react.PropTypes.object,
  	thumbnailOffset: _react.PropTypes.number,
  	width: _react.PropTypes.number
  };
  Lightbox.defaultProps = {
  	currentImage: 0,
  	enableKeyboardInput: true,
  	imageCountSeparator: ' of ',
  	onClickShowNextImage: true,
  	preloadNextImage: true,
  	showCloseButton: true,
  	showImageCount: true,
  	theme: {},
  	thumbnailOffset: 2,
  	width: 1024
  };
  Lightbox.childContextTypes = {
  	theme: _react.PropTypes.object.isRequired
  };
  
  var classes = _aphroditeNoImportant.StyleSheet.create({
  	content: {
  		position: 'relative'
  	},
  	figure: {
  		margin: 0 },
  	// remove browser default
  	image: {
  		display: 'block', // removes browser default gutter
  		height: 'auto',
  		margin: '0 auto', // maintain center on very short screens OR very narrow image
  		maxWidth: '100%',
  
  		// disable user select
  		WebkitTouchCallout: 'none',
  		userSelect: 'none'
  	}
  });
  
  exports['default'] = Lightbox;
  module.exports = exports['default'];
  /*
  Re-implement when react warning "unknown props"
  https://fb.me/react-unknown-prop is resolved
  <Swipeable onSwipedLeft={this.gotoNext} onSwipedRight={this.gotoPrev} />
  */
  
  }).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
  },{"./components/Arrow":25,"./components/Container":26,"./components/Footer":27,"./components/Header":28,"./components/PaginatedThumbnails":30,"./components/Portal":32,"./theme":38,"./utils":42,"aphrodite/no-important":6,"react-scrolllock":undefined}],25:[function(require,module,exports){
  (function (global){
  'use strict';
  
  var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
  
  function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; }
  
  var _react = (typeof window !== "undefined" ? window['React'] : typeof global !== "undefined" ? global['React'] : null);
  
  var _react2 = _interopRequireDefault(_react);
  
  var _aphroditeNoImportant = require('aphrodite/no-important');
  
  var _theme = require('../theme');
  
  var _theme2 = _interopRequireDefault(_theme);
  
  var _utils = require('../utils');
  
  var _Icon = require('./Icon');
  
  var _Icon2 = _interopRequireDefault(_Icon);
  
  function Arrow(_ref, _ref2) {
  	var direction = _ref.direction;
  	var icon = _ref.icon;
  	var onClick = _ref.onClick;
  	var size = _ref.size;
  
  	var props = _objectWithoutProperties(_ref, ['direction', 'icon', 'onClick', 'size']);
  
  	var theme = _ref2.theme;
  
  	var classes = _aphroditeNoImportant.StyleSheet.create((0, _utils.deepMerge)(defaultStyles, theme));
  
  	return _react2['default'].createElement(
  		'button',
  		_extends({
  			type: 'button',
  			className: (0, _aphroditeNoImportant.css)(classes.arrow, classes['arrow__direction__' + direction], size && classes['arrow__size__' + size]),
  			onClick: onClick,
  			onTouchEnd: onClick
  		}, props),
  		_react2['default'].createElement(_Icon2['default'], { fill: !!theme.arrow && theme.arrow.fill || _theme2['default'].arrow.fill, type: icon })
  	);
  };
  
  Arrow.propTypes = {
  	direction: _react.PropTypes.oneOf(['left', 'right']),
  	icon: _react.PropTypes.string,
  	onClick: _react.PropTypes.func.isRequired,
  	size: _react.PropTypes.oneOf(['medium', 'small']).isRequired
  };
  Arrow.defaultProps = {
  	size: 'medium'
  };
  Arrow.contextTypes = {
  	theme: _react.PropTypes.object.isRequired
  };
  
  var defaultStyles = {
  	arrow: {
  		background: 'none',
  		border: 'none',
  		borderRadius: 4,
  		cursor: 'pointer',
  		outline: 'none',
  		padding: 10, // increase hit area
  		position: 'absolute',
  		top: '50%',
  
  		// disable user select
  		WebkitTouchCallout: 'none',
  		userSelect: 'none'
  	},
  
  	// sizees
  	arrow__size__medium: {
  		height: _theme2['default'].arrow.height,
  		marginTop: _theme2['default'].arrow.height / -2,
  		width: 40,
  
  		'@media (min-width: 768px)': {
  			width: 70
  		}
  	},
  	arrow__size__small: {
  		height: _theme2['default'].thumbnail.size,
  		marginTop: _theme2['default'].thumbnail.size / -2,
  		width: 30,
  
  		'@media (min-width: 500px)': {
  			width: 40
  		}
  	},
  
  	// direction
  	arrow__direction__right: {
  		right: _theme2['default'].container.gutter.horizontal
  	},
  	arrow__direction__left: {
  		left: _theme2['default'].container.gutter.horizontal
  	}
  };
  
  module.exports = Arrow;
  
  }).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
  },{"../theme":38,"../utils":42,"./Icon":29,"aphrodite/no-important":6}],26:[function(require,module,exports){
  (function (global){
  'use strict';
  
  var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
  
  function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; }
  
  var _react = (typeof window !== "undefined" ? window['React'] : typeof global !== "undefined" ? global['React'] : null);
  
  var _react2 = _interopRequireDefault(_react);
  
  var _aphroditeNoImportant = require('aphrodite/no-important');
  
  var _theme = require('../theme');
  
  var _theme2 = _interopRequireDefault(_theme);
  
  var _utils = require('../utils');
  
  function Container(_ref, _ref2) {
  	var props = _objectWithoutProperties(_ref, []);
  
  	var theme = _ref2.theme;
  
  	var classes = _aphroditeNoImportant.StyleSheet.create((0, _utils.deepMerge)(defaultStyles, theme));
  
  	return _react2['default'].createElement('div', _extends({
  		className: (0, _aphroditeNoImportant.css)(classes.container)
  	}, props));
  };
  
  Container.contextTypes = {
  	theme: _react.PropTypes.object.isRequired
  };
  
  var defaultStyles = {
  	container: {
  		alignItems: 'center',
  		backgroundColor: _theme2['default'].container.background,
  		boxSizing: 'border-box',
  		display: 'flex',
  		height: '100%',
  		justifyContent: 'center',
  		left: 0,
  		paddingBottom: _theme2['default'].container.gutter.vertical,
  		paddingLeft: _theme2['default'].container.gutter.horizontal,
  		paddingRight: _theme2['default'].container.gutter.horizontal,
  		paddingTop: _theme2['default'].container.gutter.vertical,
  		position: 'fixed',
  		top: 0,
  		width: '100%',
  		zIndex: _theme2['default'].container.zIndex
  	}
  };
  
  module.exports = Container;
  
  }).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
  },{"../theme":38,"../utils":42,"aphrodite/no-important":6}],27:[function(require,module,exports){
  (function (global){
  'use strict';
  
  var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
  
  function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; }
  
  var _react = (typeof window !== "undefined" ? window['React'] : typeof global !== "undefined" ? global['React'] : null);
  
  var _react2 = _interopRequireDefault(_react);
  
  var _aphroditeNoImportant = require('aphrodite/no-important');
  
  var _theme = require('../theme');
  
  var _theme2 = _interopRequireDefault(_theme);
  
  var _utils = require('../utils');
  
  function Footer(_ref, _ref2) {
  	var caption = _ref.caption;
  	var countCurrent = _ref.countCurrent;
  	var countSeparator = _ref.countSeparator;
  	var countTotal = _ref.countTotal;
  	var showCount = _ref.showCount;
  
  	var props = _objectWithoutProperties(_ref, ['caption', 'countCurrent', 'countSeparator', 'countTotal', 'showCount']);
  
  	var theme = _ref2.theme;
  
  	if (!caption && !showCount) return null;
  
  	var classes = _aphroditeNoImportant.StyleSheet.create((0, _utils.deepMerge)(defaultStyles, theme));
  
  	var imageCount = showCount ? _react2['default'].createElement(
  		'div',
  		{ className: (0, _aphroditeNoImportant.css)(classes.footerCount) },
  		countCurrent,
  		countSeparator,
  		countTotal
  	) : _react2['default'].createElement('span', null);
  
  	return _react2['default'].createElement(
  		'div',
  		_extends({ className: (0, _aphroditeNoImportant.css)(classes.footer) }, props),
  		caption ? _react2['default'].createElement(
  			'figcaption',
  			{ className: (0, _aphroditeNoImportant.css)(classes.footerCaption) },
  			caption
  		) : _react2['default'].createElement('span', null),
  		imageCount
  	);
  };
  
  Footer.propTypes = {
  	caption: _react.PropTypes.oneOfType([_react.PropTypes.string, _react.PropTypes.element]),
  	countCurrent: _react.PropTypes.number,
  	countSeparator: _react.PropTypes.string,
  	countTotal: _react.PropTypes.number,
  	showCount: _react.PropTypes.bool
  };
  Footer.contextTypes = {
  	theme: _react.PropTypes.object.isRequired
  };
  
  var defaultStyles = {
  	footer: {
  		boxSizing: 'border-box',
  		color: _theme2['default'].footer.color,
  		cursor: 'auto',
  		display: 'flex',
  		justifyContent: 'space-between',
  		left: 0,
  		lineHeight: 1.3,
  		paddingBottom: _theme2['default'].footer.gutter.vertical,
  		paddingLeft: _theme2['default'].footer.gutter.horizontal,
  		paddingRight: _theme2['default'].footer.gutter.horizontal,
  		paddingTop: _theme2['default'].footer.gutter.vertical
  	},
  	footerCount: {
  		color: _theme2['default'].footer.count.color,
  		fontSize: _theme2['default'].footer.count.fontSize,
  		paddingLeft: '1em' },
  	// add a small gutter for the caption
  	footerCaption: {
  		flex: '1 1 0'
  	}
  };
  
  module.exports = Footer;
  
  }).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
  },{"../theme":38,"../utils":42,"aphrodite/no-important":6}],28:[function(require,module,exports){
  (function (global){
  'use strict';
  
  var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
  
  function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; }
  
  var _react = (typeof window !== "undefined" ? window['React'] : typeof global !== "undefined" ? global['React'] : null);
  
  var _react2 = _interopRequireDefault(_react);
  
  var _aphroditeNoImportant = require('aphrodite/no-important');
  
  var _theme = require('../theme');
  
  var _theme2 = _interopRequireDefault(_theme);
  
  var _utils = require('../utils');
  
  var _Icon = require('./Icon');
  
  var _Icon2 = _interopRequireDefault(_Icon);
  
  function Header(_ref, _ref2) {
  	var customControls = _ref.customControls;
  	var onClose = _ref.onClose;
  	var showCloseButton = _ref.showCloseButton;
  
  	var props = _objectWithoutProperties(_ref, ['customControls', 'onClose', 'showCloseButton']);
  
  	var theme = _ref2.theme;
  
  	var classes = _aphroditeNoImportant.StyleSheet.create((0, _utils.deepMerge)(defaultStyles, theme));
  
  	return _react2['default'].createElement(
  		'div',
  		_extends({ className: (0, _aphroditeNoImportant.css)(classes.header) }, props),
  		customControls ? customControls : _react2['default'].createElement('span', null),
  		!!showCloseButton && _react2['default'].createElement(
  			'button',
  			{
  				title: 'Close (Esc)',
  				className: (0, _aphroditeNoImportant.css)(classes.close),
  				onClick: onClose
  			},
  			_react2['default'].createElement(_Icon2['default'], { fill: !!theme.close && theme.close.fill || _theme2['default'].close.fill, type: 'close' })
  		)
  	);
  };
  
  Header.propTypes = {
  	customControls: _react.PropTypes.array,
  	onClose: _react.PropTypes.func.isRequired,
  	showCloseButton: _react.PropTypes.bool
  };
  Header.contextTypes = {
  	theme: _react.PropTypes.object.isRequired
  };
  
  var defaultStyles = {
  	header: {
  		display: 'flex',
  		justifyContent: 'space-between',
  		height: _theme2['default'].header.height
  	},
  	close: {
  		background: 'none',
  		border: 'none',
  		cursor: 'pointer',
  		outline: 'none',
  		position: 'relative',
  		top: 0,
  		verticalAlign: 'bottom',
  
  		// increase hit area
  		height: _theme2['default'].close.height + 20,
  		marginRight: -10,
  		padding: 10,
  		width: _theme2['default'].close.width + 20
  	}
  };
  
  module.exports = Header;
  
  }).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
  },{"../theme":38,"../utils":42,"./Icon":29,"aphrodite/no-important":6}],29:[function(require,module,exports){
  (function (global){
  'use strict';
  
  Object.defineProperty(exports, '__esModule', {
  	value: true
  });
  
  var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
  
  function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; }
  
  var _react = (typeof window !== "undefined" ? window['React'] : typeof global !== "undefined" ? global['React'] : null);
  
  var _react2 = _interopRequireDefault(_react);
  
  var _icons = require('../icons');
  
  var _icons2 = _interopRequireDefault(_icons);
  
  var Icon = function Icon(_ref) {
  	var fill = _ref.fill;
  	var type = _ref.type;
  
  	var props = _objectWithoutProperties(_ref, ['fill', 'type']);
  
  	var icon = _icons2['default'][type];
  
  	return _react2['default'].createElement('span', _extends({
  		dangerouslySetInnerHTML: { __html: icon(fill) }
  	}, props));
  };
  
  Icon.propTypes = {
  	fill: _react.PropTypes.string,
  	type: _react.PropTypes.oneOf(Object.keys(_icons2['default']))
  };
  Icon.defaultProps = {
  	fill: 'white'
  };
  
  exports['default'] = Icon;
  module.exports = exports['default'];
  
  }).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
  },{"../icons":37}],30:[function(require,module,exports){
  (function (global){
  'use strict';
  
  Object.defineProperty(exports, '__esModule', {
  	value: true
  });
  
  var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
  
  var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
  
  var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } };
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
  
  function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }
  
  function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }
  
  var _react = (typeof window !== "undefined" ? window['React'] : typeof global !== "undefined" ? global['React'] : null);
  
  var _react2 = _interopRequireDefault(_react);
  
  var _aphroditeNoImportant = require('aphrodite/no-important');
  
  var _Thumbnail = require('./Thumbnail');
  
  var _Thumbnail2 = _interopRequireDefault(_Thumbnail);
  
  var _Arrow = require('./Arrow');
  
  var _Arrow2 = _interopRequireDefault(_Arrow);
  
  var _theme = require('../theme');
  
  var _theme2 = _interopRequireDefault(_theme);
  
  var classes = _aphroditeNoImportant.StyleSheet.create({
  	paginatedThumbnails: {
  		bottom: _theme2['default'].container.gutter.vertical,
  		height: _theme2['default'].thumbnail.size,
  		padding: '0 50px',
  		position: 'absolute',
  		textAlign: 'center',
  		whiteSpace: 'nowrap'
  	}
  });
  
  var arrowStyles = {
  	height: _theme2['default'].thumbnail.size + _theme2['default'].thumbnail.gutter * 2,
  	width: 40
  };
  
  var PaginatedThumbnails = (function (_Component) {
  	_inherits(PaginatedThumbnails, _Component);
  
  	function PaginatedThumbnails(props) {
  		_classCallCheck(this, PaginatedThumbnails);
  
  		_get(Object.getPrototypeOf(PaginatedThumbnails.prototype), 'constructor', this).call(this, props);
  
  		this.state = {
  			hasCustomPage: false
  		};
  
  		this.gotoPrev = this.gotoPrev.bind(this);
  		this.gotoNext = this.gotoNext.bind(this);
  	}
  
  	_createClass(PaginatedThumbnails, [{
  		key: 'componentWillReceiveProps',
  		value: function componentWillReceiveProps(nextProps) {
  			// Component should be controlled, flush state when currentImage changes
  			if (nextProps.currentImage !== this.props.currentImage) {
  				this.setState({
  					hasCustomPage: false
  				});
  			}
  		}
  
  		// ==============================
  		// METHODS
  		// ==============================
  
  	}, {
  		key: 'getFirst',
  		value: function getFirst() {
  			var _props = this.props;
  			var currentImage = _props.currentImage;
  			var offset = _props.offset;
  
  			if (this.state.hasCustomPage) {
  				return this.clampFirst(this.state.first);
  			}
  			return this.clampFirst(currentImage - offset);
  		}
  	}, {
  		key: 'setFirst',
  		value: function setFirst(event, newFirst) {
  			var first = this.state.first;
  
  			if (event) {
  				event.preventDefault();
  				event.stopPropagation();
  			}
  
  			if (first === newFirst) return;
  
  			this.setState({
  				hasCustomPage: true,
  				first: newFirst
  			});
  		}
  	}, {
  		key: 'gotoPrev',
  		value: function gotoPrev(event) {
  			this.setFirst(event, this.getFirst() - this.props.offset);
  		}
  	}, {
  		key: 'gotoNext',
  		value: function gotoNext(event) {
  			this.setFirst(event, this.getFirst() + this.props.offset);
  		}
  	}, {
  		key: 'clampFirst',
  		value: function clampFirst(value) {
  			var _props2 = this.props;
  			var images = _props2.images;
  			var offset = _props2.offset;
  
  			var totalCount = 2 * offset + 1; // show $offset extra thumbnails on each side
  
  			if (value < 0) {
  				return 0;
  			} else if (value + totalCount > images.length) {
  				// Too far
  				return images.length - totalCount;
  			} else {
  				return value;
  			}
  		}
  
  		// ==============================
  		// RENDERERS
  		// ==============================
  
  	}, {
  		key: 'renderArrowPrev',
  		value: function renderArrowPrev() {
  			if (this.getFirst() <= 0) return null;
  
  			return _react2['default'].createElement(_Arrow2['default'], {
  				direction: 'left',
  				size: 'small',
  				icon: 'arrowLeft',
  				onClick: this.gotoPrev,
  				style: arrowStyles,
  				title: 'Previous (Left arrow key)',
  				type: 'button'
  			});
  		}
  	}, {
  		key: 'renderArrowNext',
  		value: function renderArrowNext() {
  			var _props3 = this.props;
  			var offset = _props3.offset;
  			var images = _props3.images;
  
  			var totalCount = 2 * offset + 1;
  			if (this.getFirst() + totalCount >= images.length) return null;
  
  			return _react2['default'].createElement(_Arrow2['default'], {
  				direction: 'right',
  				size: 'small',
  				icon: 'arrowRight',
  				onClick: this.gotoNext,
  				style: arrowStyles,
  				title: 'Previous (Right arrow key)',
  				type: 'button'
  			});
  		}
  	}, {
  		key: 'render',
  		value: function render() {
  			var _props4 = this.props;
  			var images = _props4.images;
  			var currentImage = _props4.currentImage;
  			var onClickThumbnail = _props4.onClickThumbnail;
  			var offset = _props4.offset;
  
  			var totalCount = 2 * offset + 1; // show $offset extra thumbnails on each side
  			var thumbnails = [];
  			var baseOffset = 0;
  			if (images.length <= totalCount) {
  				thumbnails = images;
  			} else {
  				// Try to center current image in list
  				baseOffset = this.getFirst();
  				thumbnails = images.slice(baseOffset, baseOffset + totalCount);
  			}
  
  			return _react2['default'].createElement(
  				'div',
  				{ className: (0, _aphroditeNoImportant.css)(classes.paginatedThumbnails) },
  				this.renderArrowPrev(),
  				thumbnails.map(function (img, idx) {
  					return _react2['default'].createElement(_Thumbnail2['default'], _extends({ key: baseOffset + idx
  					}, img, {
  						index: baseOffset + idx,
  						onClick: onClickThumbnail,
  						active: baseOffset + idx === currentImage }));
  				}),
  				this.renderArrowNext()
  			);
  		}
  	}]);
  
  	return PaginatedThumbnails;
  })(_react.Component);
  
  exports['default'] = PaginatedThumbnails;
  
  PaginatedThumbnails.propTypes = {
  	currentImage: _react.PropTypes.number,
  	images: _react.PropTypes.array,
  	offset: _react.PropTypes.number,
  	onClickThumbnail: _react.PropTypes.func.isRequired
  };
  module.exports = exports['default'];
  
  }).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
  },{"../theme":38,"./Arrow":25,"./Thumbnail":33,"aphrodite/no-important":6}],31:[function(require,module,exports){
  (function (global){
  'use strict';
  
  Object.defineProperty(exports, '__esModule', {
  	value: true
  });
  
  var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
  
  var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } };
  
  function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }
  
  function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }
  
  var _react = (typeof window !== "undefined" ? window['React'] : typeof global !== "undefined" ? global['React'] : null);
  
  // Pass the Lightbox context through to the Portal's descendents
  // StackOverflow discussion http://goo.gl/oclrJ9
  
  var PassContext = (function (_Component) {
  	_inherits(PassContext, _Component);
  
  	function PassContext() {
  		_classCallCheck(this, PassContext);
  
  		_get(Object.getPrototypeOf(PassContext.prototype), 'constructor', this).apply(this, arguments);
  	}
  
  	_createClass(PassContext, [{
  		key: 'getChildContext',
  		value: function getChildContext() {
  			return this.props.context;
  		}
  	}, {
  		key: 'render',
  		value: function render() {
  			return _react.Children.only(this.props.children);
  		}
  	}]);
  
  	return PassContext;
  })(_react.Component);
  
  ;
  
  PassContext.propTypes = {
  	context: _react.PropTypes.object.isRequired
  };
  PassContext.childContextTypes = {
  	theme: _react.PropTypes.object
  };
  
  exports['default'] = PassContext;
  module.exports = exports['default'];
  
  }).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
  },{}],32:[function(require,module,exports){
  (function (global){
  'use strict';
  
  Object.defineProperty(exports, '__esModule', {
  	value: true
  });
  
  var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
  
  var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
  
  var _get = function get(_x, _x2, _x3) { var _again = true; _function: while (_again) { var object = _x, property = _x2, receiver = _x3; _again = false; if (object === null) object = Function.prototype; var desc = Object.getOwnPropertyDescriptor(object, property); if (desc === undefined) { var parent = Object.getPrototypeOf(object); if (parent === null) { return undefined; } else { _x = parent; _x2 = property; _x3 = receiver; _again = true; desc = parent = undefined; continue _function; } } else if ('value' in desc) { return desc.value; } else { var getter = desc.get; if (getter === undefined) { return undefined; } return getter.call(receiver); } } };
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
  
  function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }
  
  function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }
  
  var _react = (typeof window !== "undefined" ? window['React'] : typeof global !== "undefined" ? global['React'] : null);
  
  var _react2 = _interopRequireDefault(_react);
  
  var _reactAddonsCssTransitionGroup = require('react-addons-css-transition-group');
  
  var _reactAddonsCssTransitionGroup2 = _interopRequireDefault(_reactAddonsCssTransitionGroup);
  
  var _reactDom = require('react-dom');
  
  var _PassContext = require('./PassContext');
  
  var _PassContext2 = _interopRequireDefault(_PassContext);
  
  var Portal = (function (_Component) {
  	_inherits(Portal, _Component);
  
  	function Portal() {
  		_classCallCheck(this, Portal);
  
  		_get(Object.getPrototypeOf(Portal.prototype), 'constructor', this).call(this);
  		this.portalElement = null;
  	}
  
  	_createClass(Portal, [{
  		key: 'componentDidMount',
  		value: function componentDidMount() {
  			var p = document.createElement('div');
  			document.body.appendChild(p);
  			this.portalElement = p;
  			this.componentDidUpdate();
  		}
  	}, {
  		key: 'componentDidUpdate',
  		value: function componentDidUpdate() {
  			// Animate fade on mount/unmount
  			var duration = 200;
  			var styles = '\n\t\t\t\t.fade-enter { opacity: 0.01; }\n\t\t\t\t.fade-enter.fade-enter-active { opacity: 1; transition: opacity ' + duration + 'ms; }\n\t\t\t\t.fade-leave { opacity: 1; }\n\t\t\t\t.fade-leave.fade-leave-active { opacity: 0.01; transition: opacity ' + duration + 'ms; }\n\t\t';
  
  			(0, _reactDom.render)(_react2['default'].createElement(
  				_PassContext2['default'],
  				{ context: this.context },
  				_react2['default'].createElement(
  					'div',
  					null,
  					_react2['default'].createElement(
  						'style',
  						null,
  						styles
  					),
  					_react2['default'].createElement(_reactAddonsCssTransitionGroup2['default'], _extends({
  						component: 'div',
  						transitionName: 'fade',
  						transitionEnterTimeout: duration,
  						transitionLeaveTimeout: duration
  					}, this.props))
  				)
  			), this.portalElement);
  		}
  	}, {
  		key: 'componentWillUnmount',
  		value: function componentWillUnmount() {
  			document.body.removeChild(this.portalElement);
  		}
  	}, {
  		key: 'render',
  		value: function render() {
  			return null;
  		}
  	}]);
  
  	return Portal;
  })(_react.Component);
  
  exports['default'] = Portal;
  
  Portal.contextTypes = {
  	theme: _react.PropTypes.object.isRequired
  };
  module.exports = exports['default'];
  
  }).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
  },{"./PassContext":31,"react-addons-css-transition-group":undefined,"react-dom":undefined}],33:[function(require,module,exports){
  (function (global){
  'use strict';
  
  Object.defineProperty(exports, '__esModule', {
  	value: true
  });
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
  
  var _react = (typeof window !== "undefined" ? window['React'] : typeof global !== "undefined" ? global['React'] : null);
  
  var _react2 = _interopRequireDefault(_react);
  
  var _aphroditeNoImportant = require('aphrodite/no-important');
  
  var _theme = require('../theme');
  
  var _theme2 = _interopRequireDefault(_theme);
  
  var _utils = require('../utils');
  
  function Thumbnail(_ref, _ref2) {
  	var index = _ref.index;
  	var src = _ref.src;
  	var thumbnail = _ref.thumbnail;
  	var active = _ref.active;
  	var onClick = _ref.onClick;
  	var theme = _ref2.theme;
  
  	var url = thumbnail ? thumbnail : src;
  	var classes = _aphroditeNoImportant.StyleSheet.create((0, _utils.deepMerge)(defaultStyles, theme));
  
  	return _react2['default'].createElement('div', {
  		className: (0, _aphroditeNoImportant.css)(classes.thumbnail, active && classes.thumbnail__active),
  		onClick: function (e) {
  			e.preventDefault();
  			e.stopPropagation();
  
  			onClick(index);
  		},
  		style: { backgroundImage: 'url("' + url + '")' }
  	});
  }
  
  Thumbnail.propTypes = {
  	active: _react.PropTypes.bool,
  	index: _react.PropTypes.number,
  	onClick: _react.PropTypes.func.isRequired,
  	src: _react.PropTypes.string,
  	thumbnail: _react.PropTypes.string
  };
  
  Thumbnail.contextTypes = {
  	theme: _react.PropTypes.object.isRequired
  };
  
  var defaultStyles = {
  	thumbnail: {
  		backgroundPosition: 'center',
  		backgroundSize: 'cover',
  		borderRadius: 2,
  		boxShadow: 'inset 0 0 0 1px hsla(0,0%,100%,.2)',
  		cursor: 'pointer',
  		display: 'inline-block',
  		height: _theme2['default'].thumbnail.size,
  		margin: _theme2['default'].thumbnail.gutter,
  		overflow: 'hidden',
  		width: _theme2['default'].thumbnail.size
  	},
  	thumbnail__active: {
  		boxShadow: 'inset 0 0 0 2px ' + _theme2['default'].thumbnail.activeBorderColor
  	}
  };
  
  exports['default'] = Thumbnail;
  module.exports = exports['default'];
  
  }).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
  },{"../theme":38,"../utils":42,"aphrodite/no-important":6}],34:[function(require,module,exports){
  "use strict";
  
  Object.defineProperty(exports, "__esModule", {
  	value: true
  });
  
  exports["default"] = function (fill) {
  	return "<svg fill=\"" + fill + "\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" x=\"0px\" y=\"0px\" width=\"100%\" height=\"100%\" viewBox=\"0 0 512 512\" xml:space=\"preserve\">\n\t\t<path d=\"M213.7,256L213.7,256L213.7,256L380.9,81.9c4.2-4.3,4.1-11.4-0.2-15.8l-29.9-30.6c-4.3-4.4-11.3-4.5-15.5-0.2L131.1,247.9 c-2.2,2.2-3.2,5.2-3,8.1c-0.1,3,0.9,5.9,3,8.1l204.2,212.7c4.2,4.3,11.2,4.2,15.5-0.2l29.9-30.6c4.3-4.4,4.4-11.5,0.2-15.8 L213.7,256z\"/>\n\t</svg>";
  };
  
  module.exports = exports["default"];
  
  },{}],35:[function(require,module,exports){
  "use strict";
  
  Object.defineProperty(exports, "__esModule", {
  	value: true
  });
  
  exports["default"] = function (fill) {
  	return "<svg fill=\"" + fill + "\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" x=\"0px\" y=\"0px\" width=\"100%\" height=\"100%\" viewBox=\"0 0 512 512\" xml:space=\"preserve\">\n\t\t<path d=\"M298.3,256L298.3,256L298.3,256L131.1,81.9c-4.2-4.3-4.1-11.4,0.2-15.8l29.9-30.6c4.3-4.4,11.3-4.5,15.5-0.2l204.2,212.7 c2.2,2.2,3.2,5.2,3,8.1c0.1,3-0.9,5.9-3,8.1L176.7,476.8c-4.2,4.3-11.2,4.2-15.5-0.2L131.3,446c-4.3-4.4-4.4-11.5-0.2-15.8 L298.3,256z\"/>\n\t</svg>";
  };
  
  module.exports = exports["default"];
  
  },{}],36:[function(require,module,exports){
  "use strict";
  
  Object.defineProperty(exports, "__esModule", {
  	value: true
  });
  
  exports["default"] = function (fill) {
  	return "<svg fill=\"" + fill + "\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" x=\"0px\" y=\"0px\" width=\"100%\" height=\"100%\" viewBox=\"0 0 512 512\" style=\"enable-background:new 0 0 512 512;\" xml:space=\"preserve\">\n\t\t<path d=\"M443.6,387.1L312.4,255.4l131.5-130c5.4-5.4,5.4-14.2,0-19.6l-37.4-37.6c-2.6-2.6-6.1-4-9.8-4c-3.7,0-7.2,1.5-9.8,4 L256,197.8L124.9,68.3c-2.6-2.6-6.1-4-9.8-4c-3.7,0-7.2,1.5-9.8,4L68,105.9c-5.4,5.4-5.4,14.2,0,19.6l131.5,130L68.4,387.1 c-2.6,2.6-4.1,6.1-4.1,9.8c0,3.7,1.4,7.2,4.1,9.8l37.4,37.6c2.7,2.7,6.2,4.1,9.8,4.1c3.5,0,7.1-1.3,9.8-4.1L256,313.1l130.7,131.1 c2.7,2.7,6.2,4.1,9.8,4.1c3.5,0,7.1-1.3,9.8-4.1l37.4-37.6c2.6-2.6,4.1-6.1,4.1-9.8C447.7,393.2,446.2,389.7,443.6,387.1z\"/>\n\t</svg>";
  };
  
  module.exports = exports["default"];
  
  },{}],37:[function(require,module,exports){
  'use strict';
  
  module.exports = {
  	arrowLeft: require('./arrowLeft'),
  	arrowRight: require('./arrowRight'),
  	close: require('./close')
  };
  
  },{"./arrowLeft":34,"./arrowRight":35,"./close":36}],38:[function(require,module,exports){
  // ==============================
  // THEME
  // ==============================
  
  'use strict';
  
  var theme = {};
  
  // container
  theme.container = {
  	background: 'rgba(0, 0, 0, 0.8)',
  	gutter: {
  		horizontal: 10,
  		vertical: 10
  	},
  	zIndex: 2001
  };
  
  // header
  theme.header = {
  	height: 40
  };
  theme.close = {
  	fill: 'white',
  	height: 20,
  	width: 20
  };
  
  // footer
  theme.footer = {
  	color: 'white',
  	count: {
  		color: 'rgba(255, 255, 255, 0.75)',
  		fontSize: '0.85em'
  	},
  	height: 40,
  	gutter: {
  		horizontal: 0,
  		vertical: 5
  	}
  };
  
  // thumbnails
  theme.thumbnail = {
  	activeBorderColor: 'white',
  	size: 50,
  	gutter: 2
  };
  
  // arrow
  theme.arrow = {
  	background: 'black',
  	fill: 'white',
  	height: 120
  };
  
  module.exports = theme;
  
  },{}],39:[function(require,module,exports){
  /**
  	Bind multiple component methods:
  
  	* @param {this} context
  	* @param {Array} functions
  
  	constructor() {
  		...
  		bindFunctions.call(this, ['handleClick', 'handleOther']);
  	}
  */
  
  "use strict";
  
  module.exports = function bindFunctions(functions) {
  	var _this = this;
  
  	functions.forEach(function (f) {
  		return _this[f] = _this[f].bind(_this);
  	});
  };
  
  },{}],40:[function(require,module,exports){
  // Return true if window + document
  
  'use strict';
  
  module.exports = !!(typeof window !== 'undefined' && window.document && window.document.createElement);
  
  },{}],41:[function(require,module,exports){
  'use strict';
  
  var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
  
  function deepMerge(target) {
  	var source = arguments.length <= 1 || arguments[1] === undefined ? {} : arguments[1];
  
  	var extended = _extends({}, target);
  
  	Object.keys(source).forEach(function (key) {
  		if (typeof source[key] !== 'object' || !source[key]) {
  			extended[key] = source[key];
  		} else {
  			if (!target[key]) {
  				extended[key] = source[key];
  			} else {
  				extended[key] = deepMerge(target[key], source[key]);
  			}
  		}
  	});
  
  	return extended;
  }
  
  module.exports = deepMerge;
  
  },{}],42:[function(require,module,exports){
  'use strict';
  
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
  
  var _bindFunctions = require('./bindFunctions');
  
  var _bindFunctions2 = _interopRequireDefault(_bindFunctions);
  
  var _canUseDom = require('./canUseDom');
  
  var _canUseDom2 = _interopRequireDefault(_canUseDom);
  
  var _deepMerge = require('./deepMerge');
  
  var _deepMerge2 = _interopRequireDefault(_deepMerge);
  
  module.exports = {
  	bindFunctions: _bindFunctions2['default'],
  	canUseDom: _canUseDom2['default'],
  	deepMerge: _deepMerge2['default']
  };
  
  },{"./bindFunctions":39,"./canUseDom":40,"./deepMerge":41}]},{},[24])(24)
  });