Socket
Socket
Sign inDemoInstall

react-view-pager

Package Overview
Dependencies
29
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.5.0 to 0.5.1

3

CHANGELOG.md
## CHANGELOG
### 0.5.1
Update react-motion [#63](https://github.com/souporserious/react-view-pager/pull/63)
### 0.5.0

@@ -3,0 +6,0 @@ Support React 15.5.0 PropTypes [#58](https://github.com/souporserious/react-view-pager/pull/58)

6

dist/react-view-pager.min.js
/*!
* React View Pager 0.5.0
* React View Pager 0.5.1
* https://github.com/souporserious/react-view-pager
* Copyright (c) 2017 React View Pager Authors
*/
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react"),require("resize-observer-polyfill"),require("get-prefix"),require("react-dom"),require("react-motion")):"function"==typeof define&&define.amd?define(["react","resize-observer-polyfill","get-prefix","react-dom","react-motion"],t):"object"==typeof exports?exports.ReactViewPager=t(require("react"),require("resize-observer-polyfill"),require("get-prefix"),require("react-dom"),require("react-motion")):e.ReactViewPager=t(e.React,e.ResizeObserver,e.getPrefix,e.ReactDOM,e.ReactMotion)}(this,function(e,t,n,i,r){return function(e){function t(i){if(n[i])return n[i].exports;var r=n[i]={exports:{},id:i,loaded:!1};return e[i].call(r.exports,r,r.exports,t),r.loaded=!0,r.exports}var n={};return t.m=e,t.c=n,t.p="dist/",t(0)}([function(e,t,n){"use strict";function i(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.utils=t.AnimatedView=t.View=t.Track=t.Frame=t.ViewPager=void 0;var r=n(1),o=i(r),a=n(13),s=i(a),u=n(19),c=i(u),f=n(21),l=i(f),p=n(22),h=i(p),d=n(11),v=i(d);t.ViewPager=o.default,t.Frame=s.default,t.Track=c.default,t.View=l.default,t.AnimatedView=h.default,t.utils=v.default},function(e,t,n){"use strict";function i(e){return e&&e.__esModule?e:{default:e}}function r(e,t){var n={};for(var i in e)t.indexOf(i)>=0||Object.prototype.hasOwnProperty.call(e,i)&&(n[i]=e[i]);return n}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u=function(){function e(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return function(t,n,i){return n&&e(t.prototype,n),i&&e(t,i),t}}(),c=n(2),f=(i(c),n(!function(){var e=new Error('Cannot find module "prop-types"');throw e.code="MODULE_NOT_FOUND",e}())),l=i(f),p=n(3),h=i(p),d=function(e){function t(e){o(this,t);var n=a(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e)),i=new h.default,r=function(){return n.forceUpdate()};return i.on("viewChange",r),i.on("hydrated",r),n._pager=i,n}return s(t,e),u(t,[{key:"getChildContext",value:function(){return{pager:this._pager}}},{key:"componentDidMount",value:function(){var e=this;requestAnimationFrame(function(){e._pager.hydrate()})}},{key:"getInstance",value:function(){return this._pager}},{key:"render",value:function(){var e=this.props,t=e.tag,n=r(e,["tag"]);return(0,c.createElement)(t,n)}}]),t}(c.Component);d.childContextTypes={pager:l.default.instanceOf(h.default)},d.propTypes={tag:l.default.string},d.defaultProps={tag:"div"},t.default=d,e.exports=t.default},function(t,n){t.exports=e},function(e,t,n){"use strict";function i(e){return e&&e.__esModule?e:{default:e}}function r(e,t){var n={};for(var i in e)t.indexOf(i)>=0||Object.prototype.hasOwnProperty.call(e,i)&&(n[i]=e[i]);return n}function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function u(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var c=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},f=function(){function e(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return function(t,n,i){return n&&e(t.prototype,n),i&&e(t,i),t}}(),l=n(4),p=i(l),h=n(5),d=i(h),v=n(6),y=i(v),g=n(9),w=i(g),b=n(10),m=i(b),_=n(11),x=n(12)("transform"),S="undefined"!=typeof window,O=function(e){function t(){return a(this,t),s(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return u(t,e),f(t,[{key:"getStyles",value:function(e){var t=this.pager.getPositionValue(e),n=t.x,i=t.y,r=this.pager.getTrackSize(),a=o({},x,"translate3d("+n+"px, "+i+"px, 0)");if(r){var s=this.pager.options,u=s.axis,c=s.viewsToShow,f="x"===u?"width":"height";a[f]="auto"===c?r:this.pager.views.length/c*100+"%"}return a}}]),t}(m.default),k=function(e){function t(e){var n=e.index,i=r(e,["index"]);a(this,t);var o=s(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,i));return o.index=n,o.inBounds=!0,o.tabbableChildren=[],o.setCurrent(!1),o.setVisible(!1),o.setTarget(),o.setOrigin(),setTimeout(function(){o.tabbableChildren=(0,d.default)(o.node),o.setTabbableChildren()}),o}return u(t,e),f(t,[{key:"setCurrent",value:function(e){this.isCurrent=e}},{key:"setVisible",value:function(e){this.isVisible=e,this.setTabbableChildren()}},{key:"setTabbableChildren",value:function(){for(var e=0;e<this.tabbableChildren.length;e++)this.tabbableChildren[e].tabIndex=this.isCurrent?0:-1}},{key:"setTarget",value:function(){var e=this.pager.options,t=e.align,n=(e.viewsToShow,this.pager.getStartCoords(this.index));t&&(n+=this.pager.getAlignOffset(this)),this.target=n}},{key:"setOrigin",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.pager.trackPosition;this.origin=this.target-e}},{key:"getStyles",value:function(){var e=this.pager.options,t=e.axis,n=e.viewsToShow,i=e.infinite,r={};return"x"===t&&(r.display="inline-block",r.verticalAlign="top"),"auto"!==n&&(r["x"===t?"width":"height"]=100/this.pager.views.length+"%"),i&&!this.inBounds&&(r.position="relative",r["y"===t?"top":"left"]=this.getPosition()),c({},r,this.pager.animationBus.getStyles(this))}}]),t}(m.default),T={viewsToShow:1,viewsToMove:1,align:0,contain:!1,axis:"x",autoSize:!1,animations:[],infinite:!1,instant:!1,swipe:!0,swipeThreshold:.5,flickTimeout:300,accessibility:!0},P=function(){function e(){var t=this,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};a(this,e),this.hydrate=function(){t.frame.setSize(),t.track.setSize(),t.views.forEach(function(e){e.setSize(),e.setTarget()}),t.setPositionValue(),t.setViewStyles(),t.emit("hydrated")};var i=(0,p.default)();this.on=i.on,this.emit=i.emit,this.off=i.off,this.views=[],this.currentIndex=0,this.currentView=null,this.currentTween=0,this.trackPosition=0,this.isSwiping=!1,this.options=c({},T,n),this.animationBus=new y.default({animations:this.options.animations,origin:function(e){return e.origin}}),S&&(this.resizeObserver=new w.default(function(){t.hydrate()}))}return f(e,[{key:"setOptions",value:function(e){var t=this.options;this.options=c({},this.options,e),this.animationBus.animations=this.options.animations,t.viewsToShow!==this.options.viewsToShow&&this.emit("viewChange",this.getCurrentIndicies())}},{key:"addFrame",value:function(e){this.frame=new m.default({node:e,pager:this})}},{key:"addTrack",value:function(e){this.track=new O({node:e,pager:this})}},{key:"addView",value:function(e){var t=this.views.length,n=new k({node:e,index:t,pager:this});return this.views.push(n),this.currentView||this.setCurrentView({index:t,suppressEvent:!0}),S&&this.resizeObserver.observe(e),this.emit("viewAdded"),n}},{key:"removeView",value:function(e){this.views=this.views.filter(function(t){return e!==t}),S&&this.resizeObserver.disconnect(e.node),this.emit("viewRemoved")}},{key:"prev",value:function(){this.setCurrentView({direction:-1})}},{key:"next",value:function(){this.setCurrentView({direction:1})}},{key:"setCurrentView",value:function(e){var t=e.direction,n=void 0===t?0:t,i=e.index,r=void 0===i?this.currentIndex:i,o=e.suppressEvent,a=void 0!==o&&o,s=this.options,u=s.viewsToMove,c=s.infinite,f=r+n*u,l=this.currentIndex,p=c?f:(0,_.clamp)(f,0,this.views.length-1),h=this.getView(l),d=this.getView(p);this.currentIndex=p,this.currentView=d,h.setCurrent(!1),d.setCurrent(!0);var v=p,y=p+u-1;(0,_.range)(v,y,this.views.length);this.views.forEach(function(e,t){e.setVisible(t===p)}),this.setPositionValue(),a||this.emit("viewChange",this.getCurrentIndicies())}},{key:"setPositionValue",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.currentView?this.currentView.target:0;if(!this.isSwiping){var t=this.options,n=t.viewsToShow,i=t.autoSize,r=t.infinite,o=t.contain,a=this.getTrackSize();if(r&&(e-=(Math.floor(this.currentIndex/this.views.length)||0)*a),o){var s="auto"===n&&i||n<=1?0:this.getFrameSize({autoSize:!1});e=(0,_.clamp)(e,s-a,0)}}this.trackPosition=e}},{key:"setViewStyles",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=this.options,n=t.infinite,i=t.align,r=(this.getFrameSize(),this.getTrackSize()),o=(0,_.modulo)(e,-r);this.views.reduce(function(t,a,s){var u=a.getSize(),c=t+u,f=t;return c+u*i<Math.abs(o)?(n&&(f+=r-t),a.inBounds=!1):a.inBounds=!0,a.setPosition(f),a.setOrigin(e),c},0)}},{key:"getNumericViewsToShow",value:function(){return isNaN(this.options.viewsToShow)?1:this.options.viewsToShow}},{key:"getMaxDimensions",value:function(e){var t=this,n=this.options.axis,i=[],r=[];return e.forEach(function(e){var n=isNaN(e)?e:t.getView(e);i.push(n.getSize("width")),r.push(n.getSize("height"))}),{width:"x"===n?(0,_.sum)(i):(0,_.max)(i),height:"y"===n?(0,_.sum)(r):(0,_.max)(r)}}},{key:"getCurrentIndicies",value:function(){var e=this.options,t=e.infinite,n=e.contain,i=[],r=isNaN(this.options.viewsToShow)?1:this.options.viewsToShow,o=this.currentIndex,a=this.currentIndex+(r-1);if(n){o=(0,_.clamp)(o,0,this.views.length-r),a=(0,_.clamp)(a,0,this.views.length-1);for(var s=o;s<=a;s++)i.push(s)}else for(var u=o;u<=a;u++)i.push(t?(0,_.modulo)(u,this.views.length):(0,_.clamp)(u,0,this.views.length-1));return i}},{key:"getFrameSize",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.autoSize,n=void 0===t?this.options.autoSize:t,i=e.fullSize,r=void 0!==i&&i,o={width:0,height:0};if(this.views.length)if(n){var a=this.getCurrentIndicies();o=this.getMaxDimensions(a)}else this.frame&&(o={width:this.frame.getSize("width"),height:this.frame.getSize("height")});return r?o:o["x"===this.options.axis?"width":"height"]}},{key:"getTrackSize",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=e?this.views.length:this.views.length-1,n=0;return this.views.slice(0,t).forEach(function(e){n+=e.getSize()}),n}},{key:"getView",value:function(e){return this.views[(0,_.modulo)(e,this.views.length)]}},{key:"getStartCoords",value:function(e){var t=0;return this.views.slice(0,e).forEach(function(e){t-=e.getSize()}),t}},{key:"getAlignOffset",value:function(e){var t=this.getFrameSize({autoSize:!1}),n=e.getSize();return(t-n)*this.options.align}},{key:"getPositionValue",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.trackPosition,t=this.options,n=t.infinite,i=(t.contain,{x:0,y:0});if(this.currentTween=e,n){var r=this.getTrackSize();e=(0,_.modulo)(e,-r)||0}return this.emit("scroll",{progress:e/this.getTrackSize(!1),position:e}),i[this.options.axis]=e,i}},{key:"resetViewIndex",value:function(){this.setCurrentView({index:(0,_.modulo)(this.currentIndex,this.views.length),suppressEvent:!0})}}]),e}();t.default=P,e.exports=t.default},function(e,t){"use strict";function n(e){function t(t){var n=t.toLowerCase();return e[n]||(e[n]=[])}return e=e||{},{on:function(e,n){t(e).push(n)},off:function(e,n){var i=t(e),r=i.indexOf(n);~r&&i.splice(r,1)},emit:function(e,n){t("*").concat(t(e)).forEach(function(e){e(n)})}}}e.exports=n},function(e,t){"use strict";function n(){function e(n,i){if(n===document.documentElement)return!1;for(var r=0,o=t.length;r<o;r++)if(t[r][0]===n)return t[r][1];i=i||window.getComputedStyle(n);var a=!1;return"none"===i.display?a=!0:n.parentNode&&(a=e(n.parentNode)),t.push([n,a]),a}var t=[];return function(t){if(t===document.documentElement)return!1;var n=window.getComputedStyle(t);return!!e(t,n)||"hidden"===n.visibility}}e.exports=function(e){for(var t,i,r=[],o=[],a=n(),s=["input","select","a[href]","textarea","button","[tabindex]"],u=e.querySelectorAll(s),c=0,f=u.length;c<f;c++)t=u[c],i=t.tabIndex,i<0||"INPUT"===t.tagName&&"hidden"===t.type||t.disabled||a(t)||(0===i?r.push(t):o.push({tabIndex:i,node:t}));var l=o.sort(function(e,t){return e.tabIndex-t.tabIndex}).map(function(e){return e.node});return Array.prototype.push.apply(l,r),l}},function(e,t,n){"use strict";function i(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0});var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return function(t,n,i){return n&&e(t.prototype,n),i&&e(t,i),t}}(),a=n(7),s=i(a),u={perspective:"px",rotate:"deg",rotateX:"deg",rotateY:"deg",rotateZ:"deg",scale:"",scaleX:"",scaleY:"",scaleZ:"",skew:"deg",skewX:"deg",skewY:"deg",translateX:"px",translateY:"px",translateZ:"px"},c=Object.keys(u),f=function(){function e(t){var n=t.animations,i=t.element,o=t.origin;r(this,e),this.animations=n,this.element=i,this.origin=o}return o(e,[{key:"getStyles",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.element,t=this.origin(e),n=[],i={};return this.animations.forEach(function(e){var r=e.prop,o=e.unit||u[r]||"",a=(0,s.default)(e.stops)(t);c.indexOf(r)>-1?n.push(r+"("+a+o+")"):i[r]=""+a+o}),n.length&&(i.transform=n.join(" ")),i}},{key:"applyStyles",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.element,t=this.getStyles(e);Object.keys(t).forEach(function(n){return e.style[n]=t[n]})}}]),e}();t.default=f,e.exports=t.default},function(e,t,n){"use strict";function i(e){return e&&e.__esModule?e:{default:e}}function r(e){var t=[],n=[],i=[],r=[];e.forEach(function(e){var o=s(e,2),a=o[0],u=o[1];t.push(a),isNaN(u)?(n.push(parseInt(u.substr(1,2),16)),i.push(parseInt(u.substr(3,2),16)),r.push(parseInt(u.substr(5,2),16))):n.push(u)});var o=(0,c.default)(t,n);if(!i.length||!r.length)return function(e){return o(e)};var u=function(){var e=(0,c.default)(t,i),n=(0,c.default)(t,r);return{v:function(t){return"rgb("+Math.round(o(t))+", "+Math.round(e(t))+", "+Math.round(n(t))+")"}}}();return"object"===("undefined"==typeof u?"undefined":a(u))?u.v:void 0}var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};Object.defineProperty(t,"__esModule",{value:!0});var a="function"==typeof Symbol&&"symbol"===o(Symbol.iterator)?function(e){return"undefined"==typeof e?"undefined":o(e)}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":"undefined"==typeof e?"undefined":o(e)},s=function(){function e(e,t){var n=[],i=!0,r=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(i=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);i=!0);}catch(e){r=!0,o=e}finally{try{!i&&s.return&&s.return()}finally{if(r)throw o}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();t.default=r;var u=n(8),c=i(u);e.exports=t.default},function(e,t){"use strict";function n(e,t){return function(n){if(n<=e[0])return t[0];if(n>=e[e.length-1])return t[e.length-1];for(var i=0,r=e.length-1;r-i>1;){var o=i+r>>1;n<e[o]?r=o:i=o}return t[i]+(t[r]-t[i])/(e[r]-e[i])*(n-e[i])}}Object.defineProperty(t,"__esModule",{value:!0}),t.default=n,e.exports=t.default},function(e,n){e.exports=t},function(e,t){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return function(t,n,i){return n&&e(t.prototype,n),i&&e(t,i),t}}(),r=function(){function e(t){var i=t.node,r=t.pager,o=t.width,a=t.height;n(this,e),this.node=i,this.pager=r,this.x=this.y=0,this.setSize(o,a)}return i(e,[{key:"setSize",value:function(e,t){this.width=e||this.node.offsetWidth,this.height=t||this.node.offsetHeight}},{key:"setPosition",value:function(e){this[this.pager.options.axis]=e}},{key:"getSize",value:function(e){if("width"===e||"height"===e)return this[e];var t=this.pager.options.axis;return this["x"===t?"width":"height"]}},{key:"getPosition",value:function(){return this[this.pager.options.axis]}}]),e}();t.default=r,e.exports=t.default},function(e,t){"use strict";function n(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}function i(e,t){return(e%t+t)%t}function r(e,t,n){return Math.min(Math.max(t,e),n)}function o(e){return e.reduce(function(e,t){return e+t},0)}function a(e){return Math.max.apply(null,e)}function s(e,t,r){return[].concat(n(Array(1+t-e))).map(function(t){return r?i(e+t,r):e+t})}Object.defineProperty(t,"__esModule",{value:!0}),t.modulo=i,t.clamp=r,t.sum=o,t.max=a,t.range=s},function(e,t){e.exports=n},function(e,t,n){"use strict";function i(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},u=function(){function e(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return function(t,n,i){return n&&e(t.prototype,n),i&&e(t,i),t}}(),c=n(2),f=i(c),l=n(!function(){var e=new Error('Cannot find module "prop-types"');throw e.code="MODULE_NOT_FOUND",e}()),p=i(l),h=n(14),d=n(15),v=n(3),y=i(v),g=n(16),w=i(g),b=n(17),m=i(b),_=n(18),x=i(_),S={tag:p.default.any,autoSize:p.default.oneOf([!0,!1,"width","height"]),accessibility:p.default.bool,springConfig:p.default.objectOf(p.default.number)},O=function(e){function t(e){r(this,t);var n=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n._setFrameSize=function(){var e=n.context.pager.getFrameSize({fullSize:!0});e.width&&e.height&&n.setState(e,function(){n.state.instant&&n.setState({instant:!1})})},n.state={width:0,height:0,instant:!0},n._hydrate=!1,n}return a(t,e),u(t,[{key:"componentWillMount",value:function(){var e=this.context.pager,t=this.props,n=t.autoSize,i=t.accessibility;e.setOptions({autoSize:n,accessibility:i}),this._swipe=new w.default(e),this._keyboard=new m.default(e)}},{key:"componentDidMount",value:function(){var e=this.context.pager;e.addFrame((0,h.findDOMNode)(this)),this._setFrameSize(),e.on("viewChange",this._setFrameSize),e.on("hydrated",this._setFrameSize)}},{key:"componentWillReceiveProps",value:function(e){var t=e.autoSize,n=e.accessibility;this.props.autoSize===t&&this.props.accessibility===n||(this.context.pager.setOptions({autoSize:t,accessibility:n}),this._hydrate=!0)}},{key:"componentDidUpdate",value:function(e){this._hydrate&&(this.context.pager.hydrate(),this._hydrate=!1)}},{key:"_getFrameStyle",value:function(){var e=this.props.springConfig,t=this.state,n=t.width,i=t.height,r=t.instant;return{maxWidth:r?n:(0,d.spring)(n,e),height:r?i:(0,d.spring)(i,e)}}},{key:"_renderFrame",value:function(e){var t=(this.context.pager,this.props),n=t.tag,i=t.accessibility,r=(0,x.default)(s({},this._swipe.getEvents(),this._keyboard.getEvents(),{tabIndex:i?0:null}),this.props,S);return(0,c.createElement)(n,s({},r,{style:s({},e,r.style)}))}},{key:"render",value:function(){var e=this,t=this.props.autoSize,n=(this.state.height,{position:"relative",overflow:"hidden"});return t?f.default.createElement(d.Motion,{style:this._getFrameStyle()},function(i){return t!==!0&&"width"!==t||!i.maxWidth||(n.maxWidth=i.maxWidth),t!==!0&&"height"!==t||!i.height||(n.height=i.height),e._renderFrame(n)}):this._renderFrame(n)}}]),t}(c.Component);O.contextTypes={pager:p.default.instanceOf(y.default)},O.propTypes=S,O.defaultProps={tag:"div",autoSize:!1,accessibility:!0,springConfig:d.presets.noWobble},t.default=O,e.exports=t.default},function(e,t){e.exports=i},function(e,t){e.exports=r},function(e,t){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e){return e.touches&&e.touches[0]||e}Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return function(t,n,i){return n&&e(t.prototype,n),i&&e(t,i),t}}(),o=function(){function e(t){var r=this;n(this,e),this._onSwipeStart=function(e){var t=i(e),n=t.pageX,o=t.pageY;r.pager.isSwiping=!0,r._swipeStart={x:n,y:o},r._swipeDiff={x:0,y:0},r._isFlick=!0,setTimeout(function(){r._isFlick=!1},r.pager.options.flickTimeout),r.pager.emit("swipeStart")},this._onSwipeMove=function(e){if(r.pager.isSwiping){var t=r.pager.options,n=t.swipeThreshold,o=t.axis,a=i(e),s=a.pageX,u=a.pageY;if(r._trackStart||(r._trackStart=r.pager.currentTween),r._swipeDiff={x:r._swipeStart.x-s,y:r._swipeStart.y-u},r._isSwipe(n)){e.preventDefault(),e.stopPropagation();var c=r._swipeDiff[o],f=r._trackStart-c;r.pager.setPositionValue(f),r.pager.emit("swipeMove")}}},this._onSwipeEnd=function(){var e=r.pager.options,t=e.swipeThreshold,n=e.viewsToMove,i=e.axis,o=(e.infinite,r._isFlick?t:r.pager.currentView.getSize()*n*t);r.pager.isSwiping=!1,r._trackStart=!1,(r._swipeDiff.x||r._swipeDiff.y)&&(r._isSwipe(o)?r._swipeDiff[i]<0?r.pager.prev():r.pager.next():r.pager.setPositionValue()),r.pager.emit("swipeEnd")},this._onSwipePast=function(){r.pager.isSwiping&&r._onSwipeEnd()},this.pager=t,this._trackStart=!1,this._swipeStart=this._swipeDiff={x:0,y:0}}return r(e,[{key:"_isSwipe",value:function(e){var t=this._swipeDiff,n=t.x,i=t.y;return"x"===this.pager.options.axis?Math.abs(n)>Math.max(e,Math.abs(i)):Math.abs(n)<Math.max(e,Math.abs(i))}},{key:"getEvents",value:function(){var e=this.pager.options.swipe,t={};return e!==!0&&"mouse"!==e||(t.onMouseDown=this._onSwipeStart,t.onMouseMove=this._onSwipeMove,t.onMouseUp=this._onSwipeEnd,t.onMouseLeave=this._onSwipePast),e!==!0&&"touch"!==e||(t.onTouchStart=this._onSwipeStart,t.onTouchMove=this._onSwipeMove,t.onTouchEnd=this._onSwipeEnd),t}}]),e}();t.default=o,e.exports=t.default},function(e,t,n){"use strict";function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return function(t,n,i){return n&&e(t.prototype,n),i&&e(t,i),t}}(),o=n(11),a=function(){function e(t){var n=this;i(this,e),this._handleKeyDown=function(e){switch(e.key){case"ArrowUp":case"ArrowLeft":return void n.pager.prev();case"ArrowDown":case"ArrowRight":case" ":return void n.pager.next();case"Home":return void n.pager.setCurrentView({index:0});case"End":return void n.pager.setCurrentView({index:n.pager.views.length-1})}for(var t=(0,o.clamp)(n.pager.views.length,0,9),i=1;i<=t;i++)+e.key===i&&n.pager.setCurrentView({index:i-1})},this.pager=t}return r(e,[{key:"getEvents",value:function(){var e={};return this.pager.options.accessibility&&(e.onKeyDown=this._handleKeyDown),e}}]),e}();t.default=a,e.exports=t.default},function(e,t){"use strict";function n(e,t,n){for(var i in t)t.hasOwnProperty(i)&&!n[i]&&(e[i]=t[i]);return e}Object.defineProperty(t,"__esModule",{value:!0}),t.default=n,e.exports=t.default},function(e,t,n){"use strict";function i(e){return e&&e.__esModule?e:{default:e}}function r(e,t){var n={};for(var i in e)t.indexOf(i)>=0||Object.prototype.hasOwnProperty.call(e,i)&&(n[i]=e[i]);return n}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},f=function(){function e(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return function(t,n,i){return n&&e(t.prototype,n),i&&e(t,i),t}}(),l=n(2),p=i(l),h=n(!function(){var e=new Error('Cannot find module "prop-types"');throw e.code="MODULE_NOT_FOUND",e}()),d=i(h),v=n(14),y=n(15),g=n(3),w=i(g),b=n(20),m=i(b),_=n(18),x=i(_),S=function(){return null},O={tag:d.default.any,currentView:d.default.any,viewsToShow:d.default.oneOfType([d.default.number,d.default.oneOf(["auto"])]),viewsToMove:d.default.number,align:d.default.number,contain:d.default.bool,axis:d.default.oneOf(["x","y"]),animations:d.default.array,infinite:d.default.bool,instant:d.default.bool,swipe:d.default.oneOf([!0,!1,"mouse","touch"]),swipeThreshold:d.default.number,flickTimeout:d.default.number,springConfig:d.default.objectOf(d.default.number),onSwipeStart:d.default.func,onSwipeMove:d.default.func,onSwipeEnd:d.default.func,onScroll:d.default.func,onViewChange:d.default.func,onRest:d.default.func},k=function(e,t){return e.viewsToShow!==t.viewsToShow||e.viewsToMove!==t.viewsToMove||e.align!==t.align||e.axis!==t.axis||e.animations!==t.animations||e.infinite!==t.infinite||e.swipe!==t.swipe||e.swipeThreshold!==t.swipeThreshold||e.flickTimeout!==t.flickTimeout},T=function(e){function t(){var e,n,i,r;o(this,t);for(var s=arguments.length,u=Array(s),c=0;c<s;c++)u[c]=arguments[c];return n=i=a(this,(e=t.__proto__||Object.getPrototypeOf(t)).call.apply(e,[this].concat(u))),i.state={x:0,y:0},r=n,a(i,r)}return s(t,e),f(t,[{key:"componentWillReceiveProps",value:function(e){var t=this,n=e.trackPosition,i=this.context.pager;i.setViewStyles(n),this.props.trackPosition!==n&&requestAnimationFrame(function(){return t.props.onScroll(n/i.getTrackSize(!1)*-1,n)})}},{key:"_renderViews",value:function(){return l.Children.map(this.props.children,function(e){return e})}},{key:"render",value:function(){var e=this.context.pager,t=this.props,n=t.tag,i=t.trackPosition,o=(t.children,r(t,["tag","trackPosition","children"])),a=c({},o.style);return e.track&&(a=c({},a,e.track.getStyles(i))),(0,l.createElement)(n,c({},o,{style:a}),this._renderViews())}}]),t}(l.Component);T.propTypes=O,T.contextTypes={pager:d.default.instanceOf(w.default)};var P=function(e){function t(){var e,n,i,r;o(this,t);for(var s=arguments.length,u=Array(s),c=0;c<s;c++)u[c]=arguments[c];return n=i=a(this,(e=t.__proto__||Object.getPrototypeOf(t)).call.apply(e,[this].concat(u))),i.state={instant:!1},i._currentTween=0,i._hydrate=!1,i._handleOnRest=function(){i.props.infinite&&!i.state.instant&&(i.context.pager.resetViewIndex(),i._setValueInstantly(!0,!0)),i.props.onRest()},r=n,a(i,r)}return s(t,e),f(t,[{key:"componentWillMount",value:function(){this.context.pager.setOptions(this.props)}},{key:"componentDidMount",value:function(){var e=this,t=this.context.pager;t.addTrack((0,v.findDOMNode)(this)),this.scrollTo((0,m.default)(this.props.currentView,this.props.children)),t.on("hydrated",function(){return e._setValueInstantly(!0,!0)}),t.on("swipeMove",function(){return e._setValueInstantly(!0)}),t.on("swipeEnd",function(){return e._setValueInstantly(!1)}),t.on("swipeStart",this.props.onSwipeStart),t.on("swipeMove",this.props.onSwipeMove),t.on("swipeEnd",this.props.onSwipeEnd),t.on("viewChange",this.props.onViewChange)}},{key:"componentWillReceiveProps",value:function(e){var t=e.currentView,n=e.instant,i=e.children;this.props.instant!==n&&this._setValueInstantly(n),void 0!==("undefined"==typeof t?"undefined":u(t))&&this.props.currentView!==t&&this.scrollTo((0,m.default)(t,i)),k(this.props,e)&&(this.context.pager.setOptions(e),this._hydrate=!0)}},{key:"componentDidUpdate",value:function(e){this._hydrate&&(this.context.pager.hydrate(),this._hydrate=!1)}},{key:"prev",value:function(){this.context.pager.prev()}},{key:"next",value:function(){this.context.pager.next()}},{key:"scrollTo",value:function(e){this.context.pager.setCurrentView({index:e})}},{key:"_setValueInstantly",value:function(e,t){var n=this;this.setState({instant:e},function(){t&&n.setState({instant:!1})})}},{key:"_getTrackStyle",value:function(){var e=this.context.pager.trackPosition;return this.state.instant||(e=(0,y.spring)(e,this.props.springConfig)),{trackPosition:e}}},{key:"render",value:function(){var e=this.props,t=e.tag,n=e.onScroll,i=r(e,["tag","onScroll"]);return p.default.createElement(y.Motion,{style:this._getTrackStyle(),onRest:this._handleOnRest},function(e){var r=e.trackPosition;return(0,l.createElement)(T,(0,x.default)({trackPosition:r,tag:t,onScroll:n},i,O))})}}]),t}(l.Component);P.propTypes=O,P.defaultProps={tag:"div",currentView:0,viewsToShow:1,viewsToMove:1,align:0,contain:!1,axis:"x",infinite:!1,instant:!1,swipe:!0,swipeThreshold:.5,flickTimeout:300,springConfig:y.presets.noWobble,onSwipeStart:S,onSwipeMove:S,onSwipeEnd:S,onScroll:S,onViewChange:S,onRest:S},P.contextTypes={pager:d.default.instanceOf(w.default)},t.default=P,e.exports=t.default},function(e,t,n){"use strict";function i(e,t){var n=null;return r.Children.forEach(t,function(t,i){if(t.key===e||i===e)return void(n=i)}),n}Object.defineProperty(t,"__esModule",{value:!0}),t.default=i;var r=n(2);e.exports=t.default},function(e,t,n){"use strict";function i(e){return e&&e.__esModule?e:{default:e}}function r(e,t){var n={};for(var i in e)t.indexOf(i)>=0||Object.prototype.hasOwnProperty.call(e,i)&&(n[i]=e[i]);return n}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},c=function(){function e(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return function(t,n,i){return n&&e(t.prototype,n),i&&e(t,i),t}}(),f=n(2),l=(i(f),n(!function(){var e=new Error('Cannot find module "prop-types"');throw e.code="MODULE_NOT_FOUND",e}())),p=i(l),h=n(14),d=n(3),v=i(d),y=function(e){function t(){var e,n,i,r;o(this,t);for(var s=arguments.length,u=Array(s),c=0;c<s;c++)u[c]=arguments[c];return n=i=a(this,(e=t.__proto__||Object.getPrototypeOf(t)).call.apply(e,[this].concat(u))),i._viewAdded=!1,i._viewInstance=null,r=n,a(i,r)}return s(t,e),c(t,[{key:"getChildContext",value:function(){return{view:this._viewInstance}}},{key:"componentDidMount",value:function(){this._viewInstance=this.context.pager.addView((0,h.findDOMNode)(this)),this._viewAdded=!0,this.forceUpdate()}},{key:"componentWillUnmount",value:function(){this.context.pager.removeView(this._viewInstance)}},{key:"render",value:function(){var e=this.context.pager,t=e.options,n=(t.viewsToShow,t.axis,this.props),i=n.tag,o=(n.trackSize,r(n,["tag","trackSize"])),a=u({},o.style);return this._viewAdded||(a.visibility="hidden",a.pointerEvents="none"),this._viewInstance&&(a=u({},a,this._viewInstance.getStyles())),(0,f.createElement)(i,u({},o,{style:a}))}}]),t}(f.Component);y.contextTypes={pager:p.default.instanceOf(v.default)},y.childContextTypes={view:p.default.any},y.propTypes={tag:p.default.any},y.defaultProps={tag:"div"},t.default=y,e.exports=t.default},function(e,t,n){"use strict";function i(e){return e&&e.__esModule?e:{default:e}}function r(e,t){var n={};for(var i in e)t.indexOf(i)>=0||Object.prototype.hasOwnProperty.call(e,i)&&(n[i]=e[i]);return n}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},c=function(){function e(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return function(t,n,i){return n&&e(t.prototype,n),i&&e(t,i),t}}(),f=n(2),l=(i(f),n(!function(){var e=new Error('Cannot find module "prop-types"');throw e.code="MODULE_NOT_FOUND",e}())),p=i(l),h=n(6),d=i(h),v=n(3),y=i(v),g=n(18),w=i(g),b={tag:p.default.string,index:p.default.number,animations:p.default.array},m=function(e){function t(){return o(this,t),a(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return s(t,e),c(t,[{key:"componentWillMount",value:function(){var e=this.props.animations;e.length&&(this._animationBus=new d.default({animations:e,origin:function(e){return e.origin}}))}},{key:"render",value:function(){var e=this.props,t=e.tag,n=e.index,i=r(e,["tag","index"]),o=u({},i.style);if(this._animationBus){var a=this.context.view||this.context.pager.getView(n);a&&(o=u({},i.style,this._animationBus.getStyles(a)))}return(0,f.createElement)(t,(0,w.default)({style:o},this.props,b))}}]),t}(f.Component);m.contextTypes={pager:p.default.instanceOf(y.default),view:p.default.any},m.propTypes=b,m.defaultProps={tag:"div",animations:[]},t.default=m,e.exports=t.default}])});
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react"),require("resize-observer-polyfill"),require("get-prefix"),require("react-dom"),require("react-motion")):"function"==typeof define&&define.amd?define(["react","resize-observer-polyfill","get-prefix","react-dom","react-motion"],t):"object"==typeof exports?exports.ReactViewPager=t(require("react"),require("resize-observer-polyfill"),require("get-prefix"),require("react-dom"),require("react-motion")):e.ReactViewPager=t(e.React,e.ResizeObserver,e.getPrefix,e.ReactDOM,e.ReactMotion)}(this,function(e,t,n,r,i){return function(e){function t(r){if(n[r])return n[r].exports;var i=n[r]={exports:{},id:r,loaded:!1};return e[r].call(i.exports,i,i.exports,t),i.loaded=!0,i.exports}var n={};return t.m=e,t.c=n,t.p="dist/",t(0)}([function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.utils=t.AnimatedView=t.View=t.Track=t.Frame=t.ViewPager=void 0;var i=n(1),o=r(i),a=n(22),s=r(a),u=n(28),c=r(u),f=n(30),l=r(f),p=n(31),h=r(p),d=n(20),y=r(d);t.ViewPager=o.default,t.Frame=s.default,t.Track=c.default,t.View=l.default,t.AnimatedView=h.default,t.utils=y.default},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),c=n(2),f=(r(c),n(3)),l=r(f),p=n(12),h=r(p),d=function(e){function t(e){o(this,t);var n=a(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e)),r=new h.default,i=function(){return n.forceUpdate()};return r.on("viewChange",i),r.on("hydrated",i),n._pager=r,n}return s(t,e),u(t,[{key:"getChildContext",value:function(){return{pager:this._pager}}},{key:"componentDidMount",value:function(){var e=this;requestAnimationFrame(function(){e._pager.hydrate()})}},{key:"getInstance",value:function(){return this._pager}},{key:"render",value:function(){var e=this.props,t=e.tag,n=i(e,["tag"]);return(0,c.createElement)(t,n)}}]),t}(c.Component);d.childContextTypes={pager:l.default.instanceOf(h.default)},d.propTypes={tag:l.default.string},d.defaultProps={tag:"div"},t.default=d,e.exports=t.default},function(t,n){t.exports=e},function(e,t,n){(function(t){"use strict";var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};if("production"!==t.env.NODE_ENV){var i="function"==typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,o=function(e){return"object"===("undefined"==typeof e?"undefined":r(e))&&null!==e&&e.$$typeof===i},a=!0;e.exports=n(5)(o,a)}else e.exports=n(11)()}).call(t,n(4))},function(e,t){"use strict";function n(){throw new Error("setTimeout has not been defined")}function r(){throw new Error("clearTimeout has not been defined")}function i(e){if(f===setTimeout)return setTimeout(e,0);if((f===n||!f)&&setTimeout)return f=setTimeout,setTimeout(e,0);try{return f(e,0)}catch(t){try{return f.call(null,e,0)}catch(t){return f.call(this,e,0)}}}function o(e){if(l===clearTimeout)return clearTimeout(e);if((l===r||!l)&&clearTimeout)return l=clearTimeout,clearTimeout(e);try{return l(e)}catch(t){try{return l.call(null,e)}catch(t){return l.call(this,e)}}}function a(){y&&h&&(y=!1,h.length?d=h.concat(d):v=-1,d.length&&s())}function s(){if(!y){var e=i(a);y=!0;for(var t=d.length;t;){for(h=d,d=[];++v<t;)h&&h[v].run();v=-1,t=d.length}h=null,y=!1,o(e)}}function u(e,t){this.fun=e,this.array=t}function c(){}var f,l,p=e.exports={};!function(){try{f="function"==typeof setTimeout?setTimeout:n}catch(e){f=n}try{l="function"==typeof clearTimeout?clearTimeout:r}catch(e){l=r}}();var h,d=[],y=!1,v=-1;p.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];d.push(new u(e,t)),1!==d.length||y||i(s)},u.prototype.run=function(){this.fun.apply(null,this.array)},p.title="browser",p.browser=!0,p.env={},p.argv=[],p.version="",p.versions={},p.on=c,p.addListener=c,p.once=c,p.off=c,p.removeListener=c,p.removeAllListeners=c,p.emit=c,p.binding=function(e){throw new Error("process.binding is not supported")},p.cwd=function(){return"/"},p.chdir=function(e){throw new Error("process.chdir is not supported")},p.umask=function(){return 0}},function(e,t,n){(function(t){"use strict";var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i=n(6),o=n(7),a=n(8),s=n(9),u=n(10);e.exports=function(e,n){function c(e){var t=e&&(E&&e[E]||e[j]);if("function"==typeof t)return t}function f(e,t){return e===t?0!==e||1/e===1/t:e!==e&&t!==t}function l(e){this.message=e,this.stack=""}function p(e){function r(r,c,f,p,h,d,y){if(p=p||M,d=d||f,y!==s)if(n)o(!1,"Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");else if("production"!==t.env.NODE_ENV&&"undefined"!=typeof console){var v=p+":"+f;!i[v]&&u<3&&(a(!1,"You are manually calling a React.PropTypes validation function for the `%s` prop on `%s`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details.",d,p),i[v]=!0,u++)}return null==c[f]?r?new l(null===c[f]?"The "+h+" `"+d+"` is marked as required "+("in `"+p+"`, but its value is `null`."):"The "+h+" `"+d+"` is marked as required in "+("`"+p+"`, but its value is `undefined`.")):null:e(c,f,p,h,d)}if("production"!==t.env.NODE_ENV)var i={},u=0;var c=r.bind(null,!1);return c.isRequired=r.bind(null,!0),c}function h(e){function t(t,n,r,i,o,a){var s=t[n],u=k(s);if(u!==e){var c=T(s);return new l("Invalid "+i+" `"+o+"` of type "+("`"+c+"` supplied to `"+r+"`, expected ")+("`"+e+"`."))}return null}return p(t)}function d(){return p(i.thatReturnsNull)}function y(e){function t(t,n,r,i,o){if("function"!=typeof e)return new l("Property `"+o+"` of component `"+r+"` has invalid PropType notation inside arrayOf.");var a=t[n];if(!Array.isArray(a)){var u=k(a);return new l("Invalid "+i+" `"+o+"` of type "+("`"+u+"` supplied to `"+r+"`, expected an array."))}for(var c=0;c<a.length;c++){var f=e(a,c,r,i,o+"["+c+"]",s);if(f instanceof Error)return f}return null}return p(t)}function v(){function t(t,n,r,i,o){var a=t[n];if(!e(a)){var s=k(a);return new l("Invalid "+i+" `"+o+"` of type "+("`"+s+"` supplied to `"+r+"`, expected a single ReactElement."))}return null}return p(t)}function g(e){function t(t,n,r,i,o){if(!(t[n]instanceof e)){var a=e.name||M,s=P(t[n]);return new l("Invalid "+i+" `"+o+"` of type "+("`"+s+"` supplied to `"+r+"`, expected ")+("instance of `"+a+"`."))}return null}return p(t)}function w(e){function n(t,n,r,i,o){for(var a=t[n],s=0;s<e.length;s++)if(f(a,e[s]))return null;var u=JSON.stringify(e);return new l("Invalid "+i+" `"+o+"` of value `"+a+"` "+("supplied to `"+r+"`, expected one of "+u+"."))}return Array.isArray(e)?p(n):("production"!==t.env.NODE_ENV?a(!1,"Invalid argument supplied to oneOf, expected an instance of array."):void 0,i.thatReturnsNull)}function b(e){function t(t,n,r,i,o){if("function"!=typeof e)return new l("Property `"+o+"` of component `"+r+"` has invalid PropType notation inside objectOf.");var a=t[n],u=k(a);if("object"!==u)return new l("Invalid "+i+" `"+o+"` of type "+("`"+u+"` supplied to `"+r+"`, expected an object."));for(var c in a)if(a.hasOwnProperty(c)){var f=e(a,c,r,i,o+"."+c,s);if(f instanceof Error)return f}return null}return p(t)}function m(e){function n(t,n,r,i,o){for(var a=0;a<e.length;a++){var u=e[a];if(null==u(t,n,r,i,o,s))return null}return new l("Invalid "+i+" `"+o+"` supplied to "+("`"+r+"`."))}return Array.isArray(e)?p(n):("production"!==t.env.NODE_ENV?a(!1,"Invalid argument supplied to oneOfType, expected an instance of array."):void 0,i.thatReturnsNull)}function _(){function e(e,t,n,r,i){return S(e[t])?null:new l("Invalid "+r+" `"+i+"` supplied to "+("`"+n+"`, expected a ReactNode."))}return p(e)}function x(e){function t(t,n,r,i,o){var a=t[n],u=k(a);if("object"!==u)return new l("Invalid "+i+" `"+o+"` of type `"+u+"` "+("supplied to `"+r+"`, expected `object`."));for(var c in e){var f=e[c];if(f){var p=f(a,c,r,i,o+"."+c,s);if(p)return p}}return null}return p(t)}function S(t){switch("undefined"==typeof t?"undefined":r(t)){case"number":case"string":case"undefined":return!0;case"boolean":return!t;case"object":if(Array.isArray(t))return t.every(S);if(null===t||e(t))return!0;var n=c(t);if(!n)return!1;var i,o=n.call(t);if(n!==t.entries){for(;!(i=o.next()).done;)if(!S(i.value))return!1}else for(;!(i=o.next()).done;){var a=i.value;if(a&&!S(a[1]))return!1}return!0;default:return!1}}function O(e,t){return"symbol"===e||("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}function k(e){var t="undefined"==typeof e?"undefined":r(e);return Array.isArray(e)?"array":e instanceof RegExp?"object":O(t,e)?"symbol":t}function T(e){var t=k(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function P(e){return e.constructor&&e.constructor.name?e.constructor.name:M}var E="function"==typeof Symbol&&Symbol.iterator,j="@@iterator",M="<<anonymous>>",V={array:h("array"),bool:h("boolean"),func:h("function"),number:h("number"),object:h("object"),string:h("string"),symbol:h("symbol"),any:d(),arrayOf:y,element:v(),instanceOf:g,node:_(),objectOf:b,oneOf:w,oneOfType:m,shape:x};return l.prototype=Error.prototype,V.checkPropTypes=u,V.PropTypes=V,V}}).call(t,n(4))},function(e,t){"use strict";function n(e){return function(){return e}}var r=function(){};r.thatReturns=n,r.thatReturnsFalse=n(!1),r.thatReturnsTrue=n(!0),r.thatReturnsNull=n(null),r.thatReturnsThis=function(){return this},r.thatReturnsArgument=function(e){return e},e.exports=r},function(e,t,n){(function(t){"use strict";function n(e,t,n,i,o,a,s,u){if(r(t),!e){var c;if(void 0===t)c=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var f=[n,i,o,a,s,u],l=0;c=new Error(t.replace(/%s/g,function(){return f[l++]})),c.name="Invariant Violation"}throw c.framesToPop=1,c}}var r=function(e){};"production"!==t.env.NODE_ENV&&(r=function(e){if(void 0===e)throw new Error("invariant requires an error message argument")}),e.exports=n}).call(t,n(4))},function(e,t,n){(function(t){"use strict";var r=n(6),i=r;"production"!==t.env.NODE_ENV&&!function(){var e=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var i=0,o="Warning: "+e.replace(/%s/g,function(){return n[i++]});"undefined"!=typeof console&&console.error(o);try{throw new Error(o)}catch(e){}};i=function(t,n){if(void 0===n)throw new Error("`warning(condition, format, ...args)` requires a warning message argument");if(0!==n.indexOf("Failed Composite propType: ")&&!t){for(var r=arguments.length,i=Array(r>2?r-2:0),o=2;o<r;o++)i[o-2]=arguments[o];e.apply(void 0,[n].concat(i))}}}(),e.exports=i}).call(t,n(4))},function(e,t){"use strict";var n="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";e.exports=n},function(e,t,n){(function(t){"use strict";function r(e,n,r,c,f){if("production"!==t.env.NODE_ENV)for(var l in e)if(e.hasOwnProperty(l)){var p;try{o("function"==typeof e[l],"%s: %s type `%s` is invalid; it must be a function, usually from React.PropTypes.",c||"React class",r,l),p=e[l](n,l,c,r,null,s)}catch(e){p=e}if(a(!p||p instanceof Error,"%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",c||"React class",r,l,"undefined"==typeof p?"undefined":i(p)),p instanceof Error&&!(p.message in u)){u[p.message]=!0;var h=f?f():"";a(!1,"Failed %s type: %s%s",r,p.message,null!=h?h:"")}}}var i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};if("production"!==t.env.NODE_ENV)var o=n(7),a=n(8),s=n(9),u={};e.exports=r}).call(t,n(4))},function(e,t,n){"use strict";var r=n(6),i=n(7);e.exports=function(){function e(){i(!1,"Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types")}function t(){return e}e.isRequired=e;var n={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t};return n.checkPropTypes=r,n.PropTypes=n,n}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function u(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var c=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},f=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),l=n(13),p=r(l),h=n(14),d=r(h),y=n(15),v=r(y),g=n(18),w=r(g),b=n(19),m=r(b),_=n(20),x=n(21)("transform"),S="undefined"!=typeof window,O=function(e){function t(){return a(this,t),s(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return u(t,e),f(t,[{key:"getStyles",value:function(e){var t=this.pager.getPositionValue(e),n=t.x,r=t.y,i=this.pager.getTrackSize(),a=o({},x,"translate3d("+n+"px, "+r+"px, 0)");if(i){var s=this.pager.options,u=s.axis,c=s.viewsToShow,f="x"===u?"width":"height";a[f]="auto"===c?i:this.pager.views.length/c*100+"%"}return a}}]),t}(m.default),k=function(e){function t(e){var n=e.index,r=i(e,["index"]);a(this,t);var o=s(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,r));return o.index=n,o.inBounds=!0,o.tabbableChildren=[],o.setCurrent(!1),o.setVisible(!1),o.setTarget(),o.setOrigin(),setTimeout(function(){o.tabbableChildren=(0,d.default)(o.node),o.setTabbableChildren()}),o}return u(t,e),f(t,[{key:"setCurrent",value:function(e){this.isCurrent=e}},{key:"setVisible",value:function(e){this.isVisible=e,this.setTabbableChildren()}},{key:"setTabbableChildren",value:function(){for(var e=0;e<this.tabbableChildren.length;e++)this.tabbableChildren[e].tabIndex=this.isCurrent?0:-1}},{key:"setTarget",value:function(){var e=this.pager.options,t=e.align,n=(e.viewsToShow,this.pager.getStartCoords(this.index));t&&(n+=this.pager.getAlignOffset(this)),this.target=n}},{key:"setOrigin",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.pager.trackPosition;this.origin=this.target-e}},{key:"getStyles",value:function(){var e=this.pager.options,t=e.axis,n=e.viewsToShow,r=e.infinite,i={};return"x"===t&&(i.display="inline-block",i.verticalAlign="top"),"auto"!==n&&(i["x"===t?"width":"height"]=100/this.pager.views.length+"%"),r&&!this.inBounds&&(i.position="relative",i["y"===t?"top":"left"]=this.getPosition()),c({},i,this.pager.animationBus.getStyles(this))}}]),t}(m.default),T={viewsToShow:1,viewsToMove:1,align:0,contain:!1,axis:"x",autoSize:!1,animations:[],infinite:!1,instant:!1,swipe:!0,swipeThreshold:.5,flickTimeout:300,accessibility:!0},P=function(){function e(){var t=this,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};a(this,e),this.hydrate=function(){t.frame.setSize(),t.track.setSize(),t.views.forEach(function(e){e.setSize(),e.setTarget()}),t.setPositionValue(),t.setViewStyles(),t.emit("hydrated")};var r=(0,p.default)();this.on=r.on,this.emit=r.emit,this.off=r.off,this.views=[],this.currentIndex=0,this.currentView=null,this.currentTween=0,this.trackPosition=0,this.isSwiping=!1,this.options=c({},T,n),this.animationBus=new v.default({animations:this.options.animations,origin:function(e){return e.origin}}),S&&(this.resizeObserver=new w.default(function(){t.hydrate()}))}return f(e,[{key:"setOptions",value:function(e){var t=this.options;this.options=c({},this.options,e),this.animationBus.animations=this.options.animations,t.viewsToShow!==this.options.viewsToShow&&this.emit("viewChange",this.getCurrentIndicies())}},{key:"addFrame",value:function(e){this.frame=new m.default({node:e,pager:this})}},{key:"addTrack",value:function(e){this.track=new O({node:e,pager:this})}},{key:"addView",value:function(e){var t=this.views.length,n=new k({node:e,index:t,pager:this});return this.views.push(n),this.currentView||this.setCurrentView({index:t,suppressEvent:!0}),S&&this.resizeObserver.observe(e),this.emit("viewAdded"),n}},{key:"removeView",value:function(e){this.views=this.views.filter(function(t){return e!==t}),S&&this.resizeObserver.disconnect(e.node),this.emit("viewRemoved")}},{key:"prev",value:function(){this.setCurrentView({direction:-1})}},{key:"next",value:function(){this.setCurrentView({direction:1})}},{key:"setCurrentView",value:function(e){var t=e.direction,n=void 0===t?0:t,r=e.index,i=void 0===r?this.currentIndex:r,o=e.suppressEvent,a=void 0!==o&&o,s=this.options,u=s.viewsToMove,c=s.infinite,f=i+n*u,l=this.currentIndex,p=c?f:(0,_.clamp)(f,0,this.views.length-1),h=this.getView(l),d=this.getView(p);this.currentIndex=p,this.currentView=d,h.setCurrent(!1),d.setCurrent(!0);var y=p,v=p+u-1;(0,_.range)(y,v,this.views.length);this.views.forEach(function(e,t){e.setVisible(t===p)}),this.setPositionValue(),a||this.emit("viewChange",this.getCurrentIndicies())}},{key:"setPositionValue",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.currentView?this.currentView.target:0;if(!this.isSwiping){var t=this.options,n=t.viewsToShow,r=t.autoSize,i=t.infinite,o=t.contain,a=this.getTrackSize();if(i&&(e-=(Math.floor(this.currentIndex/this.views.length)||0)*a),o){var s="auto"===n&&r||n<=1?0:this.getFrameSize({autoSize:!1});e=(0,_.clamp)(e,s-a,0)}}this.trackPosition=e}},{key:"setViewStyles",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=this.options,n=t.infinite,r=t.align,i=(this.getFrameSize(),this.getTrackSize()),o=(0,_.modulo)(e,-i);this.views.reduce(function(t,a,s){var u=a.getSize(),c=t+u,f=t;return c+u*r<Math.abs(o)?(n&&(f+=i-t),a.inBounds=!1):a.inBounds=!0,a.setPosition(f),a.setOrigin(e),c},0)}},{key:"getNumericViewsToShow",value:function(){return isNaN(this.options.viewsToShow)?1:this.options.viewsToShow}},{key:"getMaxDimensions",value:function(e){var t=this,n=this.options.axis,r=[],i=[];return e.forEach(function(e){var n=isNaN(e)?e:t.getView(e);r.push(n.getSize("width")),i.push(n.getSize("height"))}),{width:"x"===n?(0,_.sum)(r):(0,_.max)(r),height:"y"===n?(0,_.sum)(i):(0,_.max)(i)}}},{key:"getCurrentIndicies",value:function(){var e=this.options,t=e.infinite,n=e.contain,r=[],i=isNaN(this.options.viewsToShow)?1:this.options.viewsToShow,o=this.currentIndex,a=this.currentIndex+(i-1);if(n){o=(0,_.clamp)(o,0,this.views.length-i),a=(0,_.clamp)(a,0,this.views.length-1);for(var s=o;s<=a;s++)r.push(s)}else for(var u=o;u<=a;u++)r.push(t?(0,_.modulo)(u,this.views.length):(0,_.clamp)(u,0,this.views.length-1));return r}},{key:"getFrameSize",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.autoSize,n=void 0===t?this.options.autoSize:t,r=e.fullSize,i=void 0!==r&&r,o={width:0,height:0};if(this.views.length)if(n){var a=this.getCurrentIndicies();o=this.getMaxDimensions(a)}else this.frame&&(o={width:this.frame.getSize("width"),height:this.frame.getSize("height")});return i?o:o["x"===this.options.axis?"width":"height"]}},{key:"getTrackSize",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=e?this.views.length:this.views.length-1,n=0;return this.views.slice(0,t).forEach(function(e){n+=e.getSize()}),n}},{key:"getView",value:function(e){return this.views[(0,_.modulo)(e,this.views.length)]}},{key:"getStartCoords",value:function(e){var t=0;return this.views.slice(0,e).forEach(function(e){t-=e.getSize()}),t}},{key:"getAlignOffset",value:function(e){var t=this.getFrameSize({autoSize:!1}),n=e.getSize();return(t-n)*this.options.align}},{key:"getPositionValue",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.trackPosition,t=this.options,n=t.infinite,r=(t.contain,{x:0,y:0});if(this.currentTween=e,n){var i=this.getTrackSize();e=(0,_.modulo)(e,-i)||0}return this.emit("scroll",{progress:e/this.getTrackSize(!1),position:e}),r[this.options.axis]=e,r}},{key:"resetViewIndex",value:function(){this.setCurrentView({index:(0,_.modulo)(this.currentIndex,this.views.length),suppressEvent:!0})}}]),e}();t.default=P,e.exports=t.default},function(e,t){"use strict";function n(e){function t(t){var n=t.toLowerCase();return e[n]||(e[n]=[])}return e=e||{},{on:function(e,n){t(e).push(n)},off:function(e,n){var r=t(e),i=r.indexOf(n);~i&&r.splice(i,1)},emit:function(e,n){t("*").concat(t(e)).forEach(function(e){e(n)})}}}e.exports=n},function(e,t){"use strict";function n(){function e(n,r){if(n===document.documentElement)return!1;for(var i=0,o=t.length;i<o;i++)if(t[i][0]===n)return t[i][1];r=r||window.getComputedStyle(n);var a=!1;return"none"===r.display?a=!0:n.parentNode&&(a=e(n.parentNode)),t.push([n,a]),a}var t=[];return function(t){if(t===document.documentElement)return!1;var n=window.getComputedStyle(t);return!!e(t,n)||"hidden"===n.visibility}}e.exports=function(e){for(var t,r,i=[],o=[],a=n(),s=["input","select","a[href]","textarea","button","[tabindex]"],u=e.querySelectorAll(s),c=0,f=u.length;c<f;c++)t=u[c],r=t.tabIndex,r<0||"INPUT"===t.tagName&&"hidden"===t.type||t.disabled||a(t)||(0===r?i.push(t):o.push({tabIndex:r,node:t}));var l=o.sort(function(e,t){return e.tabIndex-t.tabIndex}).map(function(e){return e.node});return Array.prototype.push.apply(l,i),l}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0});var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=n(16),s=r(a),u={perspective:"px",rotate:"deg",rotateX:"deg",rotateY:"deg",rotateZ:"deg",scale:"",scaleX:"",scaleY:"",scaleZ:"",skew:"deg",skewX:"deg",skewY:"deg",translateX:"px",translateY:"px",translateZ:"px"},c=Object.keys(u),f=function(){function e(t){var n=t.animations,r=t.element,o=t.origin;i(this,e),this.animations=n,this.element=r,this.origin=o}return o(e,[{key:"getStyles",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.element,t=this.origin(e),n=[],r={};return this.animations.forEach(function(e){var i=e.prop,o=e.unit||u[i]||"",a=(0,s.default)(e.stops)(t);c.indexOf(i)>-1?n.push(i+"("+a+o+")"):r[i]=""+a+o}),n.length&&(r.transform=n.join(" ")),r}},{key:"applyStyles",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.element,t=this.getStyles(e);Object.keys(t).forEach(function(n){return e.style[n]=t[n]})}}]),e}();t.default=f,e.exports=t.default},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e){var t=[],n=[],r=[],i=[];e.forEach(function(e){var o=s(e,2),a=o[0],u=o[1];t.push(a),isNaN(u)?(n.push(parseInt(u.substr(1,2),16)),r.push(parseInt(u.substr(3,2),16)),i.push(parseInt(u.substr(5,2),16))):n.push(u)});var o=(0,c.default)(t,n);if(!r.length||!i.length)return function(e){return o(e)};var u=function(){var e=(0,c.default)(t,r),n=(0,c.default)(t,i);return{v:function(t){return"rgb("+Math.round(o(t))+", "+Math.round(e(t))+", "+Math.round(n(t))+")"}}}();return"object"===("undefined"==typeof u?"undefined":a(u))?u.v:void 0}var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};Object.defineProperty(t,"__esModule",{value:!0});var a="function"==typeof Symbol&&"symbol"===o(Symbol.iterator)?function(e){return"undefined"==typeof e?"undefined":o(e)}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":"undefined"==typeof e?"undefined":o(e)},s=function(){function e(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();t.default=i;var u=n(17),c=r(u);e.exports=t.default},function(e,t){"use strict";function n(e,t){return function(n){if(n<=e[0])return t[0];if(n>=e[e.length-1])return t[e.length-1];for(var r=0,i=e.length-1;i-r>1;){var o=r+i>>1;n<e[o]?i=o:r=o}return t[r]+(t[i]-t[r])/(e[i]-e[r])*(n-e[r])}}Object.defineProperty(t,"__esModule",{value:!0}),t.default=n,e.exports=t.default},function(e,n){e.exports=t},function(e,t){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),i=function(){function e(t){var r=t.node,i=t.pager,o=t.width,a=t.height;n(this,e),this.node=r,this.pager=i,this.x=this.y=0,this.setSize(o,a)}return r(e,[{key:"setSize",value:function(e,t){this.width=e||this.node.offsetWidth,this.height=t||this.node.offsetHeight}},{key:"setPosition",value:function(e){this[this.pager.options.axis]=e}},{key:"getSize",value:function(e){if("width"===e||"height"===e)return this[e];var t=this.pager.options.axis;return this["x"===t?"width":"height"]}},{key:"getPosition",value:function(){return this[this.pager.options.axis]}}]),e}();t.default=i,e.exports=t.default},function(e,t){"use strict";function n(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}function r(e,t){return(e%t+t)%t}function i(e,t,n){return Math.min(Math.max(t,e),n)}function o(e){return e.reduce(function(e,t){return e+t},0)}function a(e){return Math.max.apply(null,e)}function s(e,t,i){return[].concat(n(Array(1+t-e))).map(function(t){return i?r(e+t,i):e+t})}Object.defineProperty(t,"__esModule",{value:!0}),t.modulo=r,t.clamp=i,t.sum=o,t.max=a,t.range=s},function(e,t){e.exports=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},u=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),c=n(2),f=r(c),l=n(3),p=r(l),h=n(23),d=n(24),y=n(12),v=r(y),g=n(25),w=r(g),b=n(26),m=r(b),_=n(27),x=r(_),S={tag:p.default.any,autoSize:p.default.oneOf([!0,!1,"width","height"]),accessibility:p.default.bool,springConfig:p.default.objectOf(p.default.number)},O=function(e){function t(e){i(this,t);var n=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n._setFrameSize=function(){var e=n.context.pager.getFrameSize({fullSize:!0});e.width&&e.height&&n.setState(e,function(){n.state.instant&&n.setState({instant:!1})})},n.state={width:0,height:0,instant:!0},n._hydrate=!1,n}return a(t,e),u(t,[{key:"componentWillMount",value:function(){var e=this.context.pager,t=this.props,n=t.autoSize,r=t.accessibility;e.setOptions({autoSize:n,accessibility:r}),this._swipe=new w.default(e),this._keyboard=new m.default(e)}},{key:"componentDidMount",value:function(){var e=this.context.pager;e.addFrame((0,h.findDOMNode)(this)),this._setFrameSize(),e.on("viewChange",this._setFrameSize),e.on("hydrated",this._setFrameSize)}},{key:"componentWillReceiveProps",value:function(e){var t=e.autoSize,n=e.accessibility;this.props.autoSize===t&&this.props.accessibility===n||(this.context.pager.setOptions({autoSize:t,accessibility:n}),this._hydrate=!0)}},{key:"componentDidUpdate",value:function(e){this._hydrate&&(this.context.pager.hydrate(),this._hydrate=!1)}},{key:"_getFrameStyle",value:function(){var e=this.props.springConfig,t=this.state,n=t.width,r=t.height,i=t.instant;return{maxWidth:i?n:(0,d.spring)(n,e),height:i?r:(0,d.spring)(r,e)}}},{key:"_renderFrame",value:function(e){var t=(this.context.pager,this.props),n=t.tag,r=t.accessibility,i=(0,x.default)(s({},this._swipe.getEvents(),this._keyboard.getEvents(),{tabIndex:r?0:null}),this.props,S);return(0,c.createElement)(n,s({},i,{style:s({},e,i.style)}))}},{key:"render",value:function(){var e=this,t=this.props.autoSize,n=(this.state.height,{position:"relative",overflow:"hidden"});return t?f.default.createElement(d.Motion,{style:this._getFrameStyle()},function(r){return t!==!0&&"width"!==t||!r.maxWidth||(n.maxWidth=r.maxWidth),t!==!0&&"height"!==t||!r.height||(n.height=r.height),e._renderFrame(n)}):this._renderFrame(n);
}}]),t}(c.Component);O.contextTypes={pager:p.default.instanceOf(v.default)},O.propTypes=S,O.defaultProps={tag:"div",autoSize:!1,accessibility:!0,springConfig:d.presets.noWobble},t.default=O,e.exports=t.default},function(e,t){e.exports=r},function(e,t){e.exports=i},function(e,t){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e){return e.touches&&e.touches[0]||e}Object.defineProperty(t,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function(){function e(t){var i=this;n(this,e),this._onSwipeStart=function(e){var t=r(e),n=t.pageX,o=t.pageY;i.pager.isSwiping=!0,i._swipeStart={x:n,y:o},i._swipeDiff={x:0,y:0},i._isFlick=!0,setTimeout(function(){i._isFlick=!1},i.pager.options.flickTimeout),i.pager.emit("swipeStart")},this._onSwipeMove=function(e){if(i.pager.isSwiping){var t=i.pager.options,n=t.swipeThreshold,o=t.axis,a=r(e),s=a.pageX,u=a.pageY;if(i._trackStart||(i._trackStart=i.pager.currentTween),i._swipeDiff={x:i._swipeStart.x-s,y:i._swipeStart.y-u},i._isSwipe(n)){e.preventDefault(),e.stopPropagation();var c=i._swipeDiff[o],f=i._trackStart-c;i.pager.setPositionValue(f),i.pager.emit("swipeMove")}}},this._onSwipeEnd=function(){var e=i.pager.options,t=e.swipeThreshold,n=e.viewsToMove,r=e.axis,o=(e.infinite,i._isFlick?t:i.pager.currentView.getSize()*n*t);i.pager.isSwiping=!1,i._trackStart=!1,(i._swipeDiff.x||i._swipeDiff.y)&&(i._isSwipe(o)?i._swipeDiff[r]<0?i.pager.prev():i.pager.next():i.pager.setPositionValue()),i.pager.emit("swipeEnd")},this._onSwipePast=function(){i.pager.isSwiping&&i._onSwipeEnd()},this.pager=t,this._trackStart=!1,this._swipeStart=this._swipeDiff={x:0,y:0}}return i(e,[{key:"_isSwipe",value:function(e){var t=this._swipeDiff,n=t.x,r=t.y;return"x"===this.pager.options.axis?Math.abs(n)>Math.max(e,Math.abs(r)):Math.abs(n)<Math.max(e,Math.abs(r))}},{key:"getEvents",value:function(){var e=this.pager.options.swipe,t={};return e!==!0&&"mouse"!==e||(t.onMouseDown=this._onSwipeStart,t.onMouseMove=this._onSwipeMove,t.onMouseUp=this._onSwipeEnd,t.onMouseLeave=this._onSwipePast),e!==!0&&"touch"!==e||(t.onTouchStart=this._onSwipeStart,t.onTouchMove=this._onSwipeMove,t.onTouchEnd=this._onSwipeEnd),t}}]),e}();t.default=o,e.exports=t.default},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0});var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=n(20),a=function(){function e(t){var n=this;r(this,e),this._handleKeyDown=function(e){switch(e.key){case"ArrowUp":case"ArrowLeft":return void n.pager.prev();case"ArrowDown":case"ArrowRight":case" ":return void n.pager.next();case"Home":return void n.pager.setCurrentView({index:0});case"End":return void n.pager.setCurrentView({index:n.pager.views.length-1})}for(var t=(0,o.clamp)(n.pager.views.length,0,9),r=1;r<=t;r++)+e.key===r&&n.pager.setCurrentView({index:r-1})},this.pager=t}return i(e,[{key:"getEvents",value:function(){var e={};return this.pager.options.accessibility&&(e.onKeyDown=this._handleKeyDown),e}}]),e}();t.default=a,e.exports=t.default},function(e,t){"use strict";function n(e,t,n){for(var r in t)t.hasOwnProperty(r)&&!n[r]&&(e[r]=t[r]);return e}Object.defineProperty(t,"__esModule",{value:!0}),t.default=n,e.exports=t.default},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},f=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),l=n(2),p=r(l),h=n(3),d=r(h),y=n(23),v=n(24),g=n(12),w=r(g),b=n(29),m=r(b),_=n(27),x=r(_),S=function(){return null},O={tag:d.default.any,currentView:d.default.any,viewsToShow:d.default.oneOfType([d.default.number,d.default.oneOf(["auto"])]),viewsToMove:d.default.number,align:d.default.number,contain:d.default.bool,axis:d.default.oneOf(["x","y"]),animations:d.default.array,infinite:d.default.bool,instant:d.default.bool,swipe:d.default.oneOf([!0,!1,"mouse","touch"]),swipeThreshold:d.default.number,flickTimeout:d.default.number,springConfig:d.default.objectOf(d.default.number),onSwipeStart:d.default.func,onSwipeMove:d.default.func,onSwipeEnd:d.default.func,onScroll:d.default.func,onViewChange:d.default.func,onRest:d.default.func},k=function(e,t){return e.viewsToShow!==t.viewsToShow||e.viewsToMove!==t.viewsToMove||e.align!==t.align||e.axis!==t.axis||e.animations!==t.animations||e.infinite!==t.infinite||e.swipe!==t.swipe||e.swipeThreshold!==t.swipeThreshold||e.flickTimeout!==t.flickTimeout},T=function(e){function t(){var e,n,r,i;o(this,t);for(var s=arguments.length,u=Array(s),c=0;c<s;c++)u[c]=arguments[c];return n=r=a(this,(e=t.__proto__||Object.getPrototypeOf(t)).call.apply(e,[this].concat(u))),r.state={x:0,y:0},i=n,a(r,i)}return s(t,e),f(t,[{key:"componentWillReceiveProps",value:function(e){var t=this,n=e.trackPosition,r=this.context.pager;r.setViewStyles(n),this.props.trackPosition!==n&&requestAnimationFrame(function(){return t.props.onScroll(n/r.getTrackSize(!1)*-1,n)})}},{key:"_renderViews",value:function(){return l.Children.map(this.props.children,function(e){return e})}},{key:"render",value:function(){var e=this.context.pager,t=this.props,n=t.tag,r=t.trackPosition,o=(t.children,i(t,["tag","trackPosition","children"])),a=c({},o.style);return e.track&&(a=c({},a,e.track.getStyles(r))),(0,l.createElement)(n,c({},o,{style:a}),this._renderViews())}}]),t}(l.Component);T.propTypes=O,T.contextTypes={pager:d.default.instanceOf(w.default)};var P=function(e){function t(){var e,n,r,i;o(this,t);for(var s=arguments.length,u=Array(s),c=0;c<s;c++)u[c]=arguments[c];return n=r=a(this,(e=t.__proto__||Object.getPrototypeOf(t)).call.apply(e,[this].concat(u))),r.state={instant:!1},r._currentTween=0,r._hydrate=!1,r._handleOnRest=function(){r.props.infinite&&!r.state.instant&&(r.context.pager.resetViewIndex(),r._setValueInstantly(!0,!0)),r.props.onRest()},i=n,a(r,i)}return s(t,e),f(t,[{key:"componentWillMount",value:function(){this.context.pager.setOptions(this.props)}},{key:"componentDidMount",value:function(){var e=this,t=this.context.pager;t.addTrack((0,y.findDOMNode)(this)),this.scrollTo((0,m.default)(this.props.currentView,this.props.children)),t.on("hydrated",function(){return e._setValueInstantly(!0,!0)}),t.on("swipeMove",function(){return e._setValueInstantly(!0)}),t.on("swipeEnd",function(){return e._setValueInstantly(!1)}),t.on("swipeStart",this.props.onSwipeStart),t.on("swipeMove",this.props.onSwipeMove),t.on("swipeEnd",this.props.onSwipeEnd),t.on("viewChange",this.props.onViewChange)}},{key:"componentWillReceiveProps",value:function(e){var t=e.currentView,n=e.instant,r=e.children;this.props.instant!==n&&this._setValueInstantly(n),void 0!==("undefined"==typeof t?"undefined":u(t))&&this.props.currentView!==t&&this.scrollTo((0,m.default)(t,r)),k(this.props,e)&&(this.context.pager.setOptions(e),this._hydrate=!0)}},{key:"componentDidUpdate",value:function(e){this._hydrate&&(this.context.pager.hydrate(),this._hydrate=!1)}},{key:"prev",value:function(){this.context.pager.prev()}},{key:"next",value:function(){this.context.pager.next()}},{key:"scrollTo",value:function(e){this.context.pager.setCurrentView({index:e})}},{key:"_setValueInstantly",value:function(e,t){var n=this;this.setState({instant:e},function(){t&&n.setState({instant:!1})})}},{key:"_getTrackStyle",value:function(){var e=this.context.pager.trackPosition;return this.state.instant||(e=(0,v.spring)(e,this.props.springConfig)),{trackPosition:e}}},{key:"render",value:function(){var e=this.props,t=e.tag,n=e.onScroll,r=i(e,["tag","onScroll"]);return p.default.createElement(v.Motion,{style:this._getTrackStyle(),onRest:this._handleOnRest},function(e){var i=e.trackPosition;return(0,l.createElement)(T,(0,x.default)({trackPosition:i,tag:t,onScroll:n},r,O))})}}]),t}(l.Component);P.propTypes=O,P.defaultProps={tag:"div",currentView:0,viewsToShow:1,viewsToMove:1,align:0,contain:!1,axis:"x",infinite:!1,instant:!1,swipe:!0,swipeThreshold:.5,flickTimeout:300,springConfig:v.presets.noWobble,onSwipeStart:S,onSwipeMove:S,onSwipeEnd:S,onScroll:S,onViewChange:S,onRest:S},P.contextTypes={pager:d.default.instanceOf(w.default)},t.default=P,e.exports=t.default},function(e,t,n){"use strict";function r(e,t){var n=null;return i.Children.forEach(t,function(t,r){if(t.key===e||r===e)return void(n=r)}),n}Object.defineProperty(t,"__esModule",{value:!0}),t.default=r;var i=n(2);e.exports=t.default},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},c=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),f=n(2),l=(r(f),n(3)),p=r(l),h=n(23),d=n(12),y=r(d),v=function(e){function t(){var e,n,r,i;o(this,t);for(var s=arguments.length,u=Array(s),c=0;c<s;c++)u[c]=arguments[c];return n=r=a(this,(e=t.__proto__||Object.getPrototypeOf(t)).call.apply(e,[this].concat(u))),r._viewAdded=!1,r._viewInstance=null,i=n,a(r,i)}return s(t,e),c(t,[{key:"getChildContext",value:function(){return{view:this._viewInstance}}},{key:"componentDidMount",value:function(){this._viewInstance=this.context.pager.addView((0,h.findDOMNode)(this)),this._viewAdded=!0,this.forceUpdate()}},{key:"componentWillUnmount",value:function(){this.context.pager.removeView(this._viewInstance)}},{key:"render",value:function(){var e=this.context.pager,t=e.options,n=(t.viewsToShow,t.axis,this.props),r=n.tag,o=(n.trackSize,i(n,["tag","trackSize"])),a=u({},o.style);return this._viewAdded||(a.visibility="hidden",a.pointerEvents="none"),this._viewInstance&&(a=u({},a,this._viewInstance.getStyles())),(0,f.createElement)(r,u({},o,{style:a}))}}]),t}(f.Component);v.contextTypes={pager:p.default.instanceOf(y.default)},v.childContextTypes={view:p.default.any},v.propTypes={tag:p.default.any},v.defaultProps={tag:"div"},t.default=v,e.exports=t.default},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function i(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},c=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),f=n(2),l=(r(f),n(3)),p=r(l),h=n(15),d=r(h),y=n(12),v=r(y),g=n(27),w=r(g),b={tag:p.default.string,index:p.default.number,animations:p.default.array},m=function(e){function t(){return o(this,t),a(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return s(t,e),c(t,[{key:"componentWillMount",value:function(){var e=this.props.animations;e.length&&(this._animationBus=new d.default({animations:e,origin:function(e){return e.origin}}))}},{key:"render",value:function(){var e=this.props,t=e.tag,n=e.index,r=i(e,["tag","index"]),o=u({},r.style);if(this._animationBus){var a=this.context.view||this.context.pager.getView(n);a&&(o=u({},r.style,this._animationBus.getStyles(a)))}return(0,f.createElement)(t,(0,w.default)({style:o},this.props,b))}}]),t}(f.Component);m.contextTypes={pager:p.default.instanceOf(v.default),view:p.default.any},m.propTypes=b,m.defaultProps={tag:"div",animations:[]},t.default=m,e.exports=t.default}])});
{
"name": "react-view-pager",
"version": "0.5.0",
"version": "0.5.1",
"description": "View-Pager/Slider/Carousel powered by React Motion.",

@@ -46,3 +46,3 @@ "main": "lib/react-view-pager.js",

"mitt": "^1.0.0",
"react-motion": "^0.4.8",
"react-motion": "^0.5.0",
"resize-observer-polyfill": "^1.4.2",

@@ -49,0 +49,0 @@ "tabbable": "^1.0.5"

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc