UNPKG

react-apollo

Version:
1 lines 37.5 kB
!function e(t,n,r){function o(u,a){if(!n[u]){if(!t[u]){var s="function"==typeof require&&require;if(!a&&s)return s(u,!0);if(i)return i(u,!0);var c=new Error("Cannot find module '"+u+"'");throw c.code="MODULE_NOT_FOUND",c}var l=n[u]={exports:{}};t[u][0].call(l.exports,function(e){var n=t[u][1][e];return o(n||e)},l,l.exports,e,t,n,r)}return n[u].exports}for(var i="function"==typeof require&&require,u=0;u<r.length;u++)o(r[u]);return o}({1:[function(e,t,n){!function(r,o){"object"==typeof n&&void 0!==t?o(n,e("react"),e("prop-types"),e("redux"),e("apollo-client"),e("graphql-tag")):"function"==typeof define&&define.amd?define(["exports","react","prop-types","redux","apollo-client","graphql-tag"],o):o(r["react-apollo"]=r["react-apollo"]||{},r.React,r.PropTypes,r.redux,r.apolloClient,r.graphqlTag)}(this,function(t,n,r,o,i,u){"use strict";function a(e,t){if(!e||!t)return!0;if(e===t)return!0;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(var o=Object.prototype.hasOwnProperty,i=0;i<n.length;i++)if(!o.call(t,n[i])||e[n[i]]!==t[n[i]])return!1;return!0}function s(e){var t,n,r;m(!!e&&!!e.kind,"Argument of "+e+" passed to parser was not a valid GraphQL DocumentNode. You may need to use 'graphql-tag' or another method to convert your operation into a document");var o=e.definitions.filter(function(e){return"FragmentDefinition"===e.kind}),i=e.definitions.filter(function(e){return"OperationDefinition"===e.kind&&"query"===e.operation}),u=e.definitions.filter(function(e){return"OperationDefinition"===e.kind&&"mutation"===e.operation}),a=e.definitions.filter(function(e){return"OperationDefinition"===e.kind&&"subscription"===e.operation});m(!o.length||i.length||u.length||a.length,"Passing only a fragment to 'graphql' is not yet supported. You must include a query, subscription or mutation as well"),m(i.length+u.length+a.length<=1,"react-apollo only supports a query, subscription, or a mutation per HOC. "+e+" had "+i.length+" queries, "+a.length+" subscriptions and "+u.length+" mutations. You can use 'compose' to join multiple operation types to a component"),n=i.length?v.Query:v.Mutation,i.length||u.length||(n=v.Subscription);var s=i.length?i:u.length?u:a;m(1===s.length,"react-apollo only supports one defintion per HOC. "+e+" had "+s.length+" definitions. You can use 'compose' to join multiple operation types to a component");var c=s[0];return t=c.variableDefinitions||[],r=c.name&&"Name"===c.name.kind?c.name.value:"data",{name:r,type:n,variables:t}}function c(e){var t=O(e,"variables","refetch","fetchMore","updateQuery","startPolling","stopPolling","subscribeToMore");return Object.keys(t).forEach(function(n){"function"==typeof t[n]&&(t[n]=t[n].bind(e))}),t}function l(e){return e.displayName||e.name||"Component"}function p(e,t){function o(o){var i=y+"("+l(o)+")",u=new R,s=function(r){function s(e,t){var n=r.call(this,e,t)||this;return n.previousData={},n.version=k,n.client=t.client,j(!!n.client,'Could not find "client" in the context of "'+i+'". Wrap the root component in an <ApolloProvider>'),n.store=n.client.store,n.type=O.type,n}return g(s,r),s.prototype.componentWillMount=function(){this.shouldSkip(this.props)||this.setInitialProps()},s.prototype.componentDidMount=function(){this.hasMounted=!0,this.type!==v.Mutation&&(this.shouldSkip(this.props)||this.subscribeToQuery())},s.prototype.componentWillReceiveProps=function(e,n){if(!a(this.props,e)||this.client!==n.client){if(this.shouldRerender=!0,this.client!==n.client)return this.client=n.client,this.unsubscribeFromQuery(),this.queryObservable=null,this.previousData={},this.updateQuery(e),void(this.shouldSkip(e)||this.subscribeToQuery());if(this.type!==v.Mutation)return this.type===v.Subscription&&t.shouldResubscribe&&t.shouldResubscribe(this.props,e)?(this.unsubscribeFromQuery(),delete this.queryObservable,this.updateQuery(e),void this.subscribeToQuery()):void(this.shouldSkip(e)?this.shouldSkip(this.props)||this.unsubscribeFromQuery():(this.updateQuery(e),this.subscribeToQuery()))}},s.prototype.componentWillUnmount=function(){this.type===v.Query&&(this.queryObservable&&(u.recycle(this.queryObservable),delete this.queryObservable),this.unsubscribeFromQuery()),this.type===v.Subscription&&this.unsubscribeFromQuery(),this.hasMounted=!1},s.prototype.calculateOptions=function(e,t){void 0===e&&(e=this.props);var n=h(e);if(t&&t.variables&&(t.variables=_({},n.variables,t.variables)),t&&(n=_({},n,t)),n.variables||!O.variables.length)return n;for(var r={},u=0,a=O.variables;u<a.length;u++){var s=a[u],c=s.variable,p=s.type;c.name&&c.name.value&&(void 0===e[c.name.value]?"NonNullType"===p.kind?j(void 0!==e[c.name.value],"The operation '"+O.name+"' wrapping '"+l(o)+"' is expecting a variable: '"+c.name.value+"' but it was not found in the props passed to '"+i+"'"):r[c.name.value]=null:r[c.name.value]=e[c.name.value])}return n=w({},n,{variables:r})},s.prototype.calculateResultProps=function(e){var n=this.type===v.Mutation?"mutate":"data";t.name&&(n=t.name);var r=(o={},o[n]=e,o.ownProps=this.props,o);return m?m(r):(i={},i[n]=x(e),i);var o,i},s.prototype.setInitialProps=function(){if(this.type!==v.Mutation){var e=this.calculateOptions(this.props);this.createQuery(e)}},s.prototype.createQuery=function(t){if(this.type===v.Subscription)this.queryObservable=this.client.subscribe(_({query:e},t));else{var n=u.reuse(t);this.queryObservable=null===n?this.client.watchQuery(_({query:e,metadata:{reactComponent:{displayName:i}}},t)):n}},s.prototype.updateQuery=function(e){var t=this.calculateOptions(e);this.queryObservable||this.createQuery(t),this.queryObservable._setOptionsNoResult?this.queryObservable._setOptionsNoResult(t):this.queryObservable.setOptions&&this.queryObservable.setOptions(t).catch(function(e){return null})},s.prototype.fetchData=function(){if(this.shouldSkip())return!1;if(O.type===v.Mutation||O.type===v.Subscription)return!1;var t=this.calculateOptions();if(!1===t.ssr)return!1;"network-only"!==t.fetchPolicy&&"cache-and-network"!==t.fetchPolicy||(t.fetchPolicy="cache-first");var n=this.client.watchQuery(_({query:e},t));return!!n.currentResult().loading&&n.result()},s.prototype.subscribeToQuery=function(){var e=this;if(!this.querySubscription){var t=function(t){e.type===v.Subscription&&(e.lastSubscriptionData=t,t={data:t});var n=Object.keys(c(t.data));j(0===n.length,"the result of the '"+i+"' operation contains keys that conflict with the return object."+n.map(function(e){return"'"+e+"'"}).join(", ")+" not allowed."),e.forceRenderChildren()},n=function(e){if(e.hasOwnProperty("graphQLErrors"))return t({error:e});throw e};this.querySubscription=this.queryObservable.subscribe({next:t,error:n})}},s.prototype.unsubscribeFromQuery=function(){this.querySubscription&&(this.querySubscription.unsubscribe(),delete this.querySubscription)},s.prototype.shouldSkip=function(e){return void 0===e&&(e=this.props),b(e)||h(e).skip},s.prototype.forceRenderChildren=function(){this.shouldRerender=!0,this.hasMounted&&this.setState({})},s.prototype.getWrappedInstance=function(){return j(t.withRef,"To access the wrapped instance, you need to specify { withRef: true } in the options"),this.refs.wrappedInstance},s.prototype.dataForChild=function(){var t=this;if(this.type===v.Mutation)return function(n){var r=t.calculateOptions(t.props,n);return void 0===r.variables&&delete r.variables,r.mutation=e,t.client.mutate(r)};var n=this.calculateOptions(this.props),r={};if(_(r,c(this.queryObservable)),this.type===v.Subscription)_(r,{loading:!this.lastSubscriptionData,variables:n.variables},this.lastSubscriptionData);else{var o=this.queryObservable.currentResult(),i=o.loading,u=o.error,a=o.networkStatus;_(r,{loading:i,networkStatus:a});var s=setTimeout(function(){u&&console.error("Unhandled (in react-apollo)",u.stack||u)},10);Object.defineProperty(r,"error",{configurable:!0,enumerable:!0,get:function(){return clearTimeout(s),u}}),i?_(r,this.previousData,o.data):u?_(r,(this.queryObservable.getLastResult()||{}).data):(_(r,o.data),this.previousData=o.data)}return r},s.prototype.render=function(){if(this.shouldSkip())return n.createElement(o,this.props);var e=this,r=e.shouldRerender,i=e.renderedElement,u=e.props;if(this.shouldRerender=!1,!r&&i&&i.type===o)return i;var a=this.dataForChild(),s=this.calculateResultProps(a),c=_({},u,s);return t.withRef&&(c.ref="wrappedInstance"),this.renderedElement=n.createElement(o,c),this.renderedElement},s}(n.Component);return s.displayName=i,s.WrappedComponent=o,s.contextTypes={client:r.object.isRequired},T(s,o,{})}void 0===t&&(t={});var i=t.options,u=void 0===i?E:i,p=t.skip,f=void 0===p?S:p,d=t.alias,y=void 0===d?"Apollo":d,h=u;"function"!=typeof h&&(h=function(){return u});var b=f;"function"!=typeof b&&(b=function(){return f});var m=t.props,O=s(e),k=P++;return o}function f(e){return e.displayName||e.name||"Component"}function d(e,t){void 0===t&&(t={});var o="withApollo("+f(e)+")",i=function(r){function i(e,t){var n=r.call(this,e,t)||this;return n.client=t.client,N(!!n.client,'Could not find "client" in the context of "'+o+'". Wrap the root component in an <ApolloProvider>'),n}return k(i,r),i.prototype.getWrappedInstance=function(){return N(t.withRef,"To access the wrapped instance, you need to specify { withRef: true } in the options"),this.refs.wrappedInstance},i.prototype.render=function(){var r=q({},this.props);return r.client=this.client,t.withRef&&(r.ref="wrappedInstance"),n.createElement(e,r)},i}(n.Component);return i.displayName=o,i.WrappedComponent=e,i.contextTypes={client:r.object.isRequired},A(i,e,{})}u="default"in u?u.default:u;var y=function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),h=e("invariant"),b=function(e){function t(t,n){var r=e.call(this,t,n)||this;return h(t.client,'ApolloClient was not passed a client instance. Make sure you pass in your client via the "client" prop.'),t.store||t.client.initStore(),r}return y(t,e),t.prototype.componentWillReceiveProps=function(e){e.client===this.props.client||e.store||e.client.initStore()},t.prototype.getChildContext=function(){return{store:this.props.store||this.context.store,client:this.props.client}},t.prototype.render=function(){return n.Children.only(this.props.children)},t}(n.Component);b.propTypes={store:r.shape({subscribe:r.func.isRequired,dispatch:r.func.isRequired,getState:r.func.isRequired}),client:r.object.isRequired,children:r.element.isRequired},b.childContextTypes={store:r.object,client:r.object.isRequired},b.contextTypes={store:r.object};var v,m=e("invariant");!function(e){e[e.Query=0]="Query",e[e.Mutation=1]="Mutation",e[e.Subscription=2]="Subscription"}(v||(v={}));var g=function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),w=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++){t=arguments[n];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},O=e("lodash.pick"),j=e("invariant"),_=e("object-assign"),T=e("hoist-non-react-statics"),E=function(e){return{}},x=function(e){return e},S=function(e){return!1},P=0,R=function(){function e(){this.observableQueries=[]}return e.prototype.recycle=function(e){e.setOptions({fetchPolicy:"standby",pollInterval:0,fetchResults:!1}),this.observableQueries.push({observableQuery:e,subscription:e.subscribe({})})},e.prototype.reuse=function(e){if(this.observableQueries.length<=0)return null;var t=this.observableQueries.pop(),n=t.observableQuery;return t.subscription.unsubscribe(),n.setOptions(w({},e,{pollInterval:e.pollInterval,fetchPolicy:e.fetchPolicy})),n},e}(),k=function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])};return function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),N=e("invariant"),q=e("object-assign"),A=e("hoist-non-react-statics");t.ApolloProvider=b,t.graphql=p,t.withApollo=d,t.compose=o.compose,t.gql=u,Object.keys(i).forEach(function(e){t[e]=i[e]}),Object.defineProperty(t,"__esModule",{value:!0})})},{"apollo-client":2,"graphql-tag":2,"hoist-non-react-statics":7,invariant:8,"lodash.pick":9,"object-assign":20,"prop-types":24,react:2,redux:31}],2:[function(e,t,n){},{}],3:[function(e,t,n){function r(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function i(e){if(p===setTimeout)return setTimeout(e,0);if((p===r||!p)&&setTimeout)return p=setTimeout,setTimeout(e,0);try{return p(e,0)}catch(t){try{return p.call(null,e,0)}catch(t){return p.call(this,e,0)}}}function u(e){if(f===clearTimeout)return clearTimeout(e);if((f===o||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){b&&y&&(b=!1,y.length?h=y.concat(h):v=-1,h.length&&s())}function s(){if(!b){var e=i(a);b=!0;for(var t=h.length;t;){for(y=h,h=[];++v<t;)y&&y[v].run();v=-1,t=h.length}y=null,b=!1,u(e)}}function c(e,t){this.fun=e,this.array=t}function l(){}var p,f,d=t.exports={};!function(){try{p="function"==typeof setTimeout?setTimeout:r}catch(e){p=r}try{f="function"==typeof clearTimeout?clearTimeout:o}catch(e){f=o}}();var y,h=[],b=!1,v=-1;d.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];h.push(new c(e,t)),1!==h.length||b||i(s)},c.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=l,d.addListener=l,d.once=l,d.off=l,d.removeListener=l,d.removeAllListeners=l,d.emit=l,d.prependListener=l,d.prependOnceListener=l,d.listeners=function(e){return[]},d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},{}],4:[function(e,t,n){"use strict";function r(e){return function(){return e}}var o=function(){};o.thatReturns=r,o.thatReturnsFalse=r(!1),o.thatReturnsTrue=r(!0),o.thatReturnsNull=r(null),o.thatReturnsThis=function(){return this},o.thatReturnsArgument=function(e){return e},t.exports=o},{}],5:[function(e,t,n){(function(e){"use strict";function n(e,t,n,o,i,u,a,s){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 l=[n,o,i,u,a,s],p=0;(c=new Error(t.replace(/%s/g,function(){return l[p++]}))).name="Invariant Violation"}throw c.framesToPop=1,c}}var r=function(e){};"production"!==e.env.NODE_ENV&&(r=function(e){if(void 0===e)throw new Error("invariant requires an error message argument")}),t.exports=n}).call(this,e("_process"))},{_process:3}],6:[function(e,t,n){(function(n){"use strict";var r=e("./emptyFunction");"production"!==n.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 o=0,i="Warning: "+e.replace(/%s/g,function(){return n[o++]});"undefined"!=typeof console&&console.error(i);try{throw new Error(i)}catch(e){}};r=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,o=Array(r>2?r-2:0),i=2;i<r;i++)o[i-2]=arguments[i];e.apply(void 0,[n].concat(o))}}}(),t.exports=r}).call(this,e("_process"))},{"./emptyFunction":4,_process:3}],7:[function(e,t,n){"use strict";var r={childContextTypes:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,mixins:!0,propTypes:!0,type:!0},o={name:!0,length:!0,prototype:!0,caller:!0,arguments:!0,arity:!0},i="function"==typeof Object.getOwnPropertySymbols;t.exports=function(e,t,n){if("string"!=typeof t){var u=Object.getOwnPropertyNames(t);i&&(u=u.concat(Object.getOwnPropertySymbols(t)));for(var a=0;a<u.length;++a)if(!(r[u[a]]||o[u[a]]||n&&n[u[a]]))try{e[u[a]]=t[u[a]]}catch(e){}}return e}},{}],8:[function(e,t,n){(function(e){"use strict";var n=function(t,n,r,o,i,u,a,s){if("production"!==e.env.NODE_ENV&&void 0===n)throw new Error("invariant requires an error message argument");if(!t){var c;if(void 0===n)c=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var l=[r,o,i,u,a,s],p=0;(c=new Error(n.replace(/%s/g,function(){return l[p++]}))).name="Invariant Violation"}throw c.framesToPop=1,c}};t.exports=n}).call(this,e("_process"))},{_process:3}],9:[function(e,t,n){(function(e){function n(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function r(e,t){for(var n=-1,r=e?e.length:0,o=Array(r);++n<r;)o[n]=t(e[n],n,e);return o}function o(e,t){for(var n=-1,r=t.length,o=e.length;++n<r;)e[o+n]=t[n];return e}function i(e,t,n,r,u){var a=-1,c=e.length;for(n||(n=s),u||(u=[]);++a<c;){var l=e[a];t>0&&n(l)?t>1?i(l,t-1,n,r,u):o(u,l):r||(u[u.length]=l)}return u}function u(e,t){return e=Object(e),a(e,t,function(t,n){return n in e})}function a(e,t,n){for(var r=-1,o=t.length,i={};++r<o;){var u=t[r],a=e[u];n(a,u)&&(i[u]=a)}return i}function s(e){return I(e)||l(e)||!!(q&&e&&e[q])}function c(e){if("string"==typeof e||v(e))return e;var t=e+"";return"0"==t&&1/e==-m?"-0":t}function l(e){return f(e)&&P.call(e,"callee")&&(!N.call(e,"callee")||R.call(e)==w)}function p(e){return null!=e&&y(e.length)&&!d(e)}function f(e){return b(e)&&p(e)}function d(e){var t=h(e)?R.call(e):"";return t==O||t==j}function y(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=g}function h(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function b(e){return!!e&&"object"==typeof e}function v(e){return"symbol"==typeof e||b(e)&&R.call(e)==_}var m=1/0,g=9007199254740991,w="[object Arguments]",O="[object Function]",j="[object GeneratorFunction]",_="[object Symbol]",T="object"==typeof e&&e&&e.Object===Object&&e,E="object"==typeof self&&self&&self.Object===Object&&self,x=T||E||Function("return this")(),S=Object.prototype,P=S.hasOwnProperty,R=S.toString,k=x.Symbol,N=S.propertyIsEnumerable,q=k?k.isConcatSpreadable:void 0,A=Math.max,I=Array.isArray,C=function(e,t){return t=A(void 0===t?e.length-1:t,0),function(){for(var r=arguments,o=-1,i=A(r.length-t,0),u=Array(i);++o<i;)u[o]=r[t+o];o=-1;for(var a=Array(t+1);++o<t;)a[o]=r[o];return a[t]=u,n(e,this,a)}}(function(e,t){return null==e?{}:u(e,r(i(t,1),c))});t.exports=C}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],10:[function(e,t,n){var r=e("./_root").Symbol;t.exports=r},{"./_root":17}],11:[function(e,t,n){function r(e){return null==e?void 0===e?s:a:c&&c in Object(e)?i(e):u(e)}var o=e("./_Symbol"),i=e("./_getRawTag"),u=e("./_objectToString"),a="[object Null]",s="[object Undefined]",c=o?o.toStringTag:void 0;t.exports=r},{"./_Symbol":10,"./_getRawTag":14,"./_objectToString":15}],12:[function(e,t,n){(function(e){var n="object"==typeof e&&e&&e.Object===Object&&e;t.exports=n}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],13:[function(e,t,n){var r=e("./_overArg")(Object.getPrototypeOf,Object);t.exports=r},{"./_overArg":16}],14:[function(e,t,n){function r(e){var t=u.call(e,s),n=e[s];try{e[s]=void 0;var r=!0}catch(e){}var o=a.call(e);return r&&(t?e[s]=n:delete e[s]),o}var o=e("./_Symbol"),i=Object.prototype,u=i.hasOwnProperty,a=i.toString,s=o?o.toStringTag:void 0;t.exports=r},{"./_Symbol":10}],15:[function(e,t,n){function r(e){return o.call(e)}var o=Object.prototype.toString;t.exports=r},{}],16:[function(e,t,n){function r(e,t){return function(n){return e(t(n))}}t.exports=r},{}],17:[function(e,t,n){var r=e("./_freeGlobal"),o="object"==typeof self&&self&&self.Object===Object&&self,i=r||o||Function("return this")();t.exports=i},{"./_freeGlobal":12}],18:[function(e,t,n){function r(e){return null!=e&&"object"==typeof e}t.exports=r},{}],19:[function(e,t,n){function r(e){if(!u(e)||o(e)!=a)return!1;var t=i(e);if(null===t)return!0;var n=p.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&l.call(n)==f}var o=e("./_baseGetTag"),i=e("./_getPrototype"),u=e("./isObjectLike"),a="[object Object]",s=Function.prototype,c=Object.prototype,l=s.toString,p=c.hasOwnProperty,f=l.call(Object);t.exports=r},{"./_baseGetTag":11,"./_getPrototype":13,"./isObjectLike":18}],20:[function(e,t,n){"use strict";function r(e){if(null===e||void 0===e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}var o=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,u=Object.prototype.propertyIsEnumerable;t.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map(function(e){return t[e]}).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach(function(e){r[e]=e}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var n,a,s=r(e),c=1;c<arguments.length;c++){n=Object(arguments[c]);for(var l in n)i.call(n,l)&&(s[l]=n[l]);if(o){a=o(n);for(var p=0;p<a.length;p++)u.call(n,a[p])&&(s[a[p]]=n[a[p]])}}return s}},{}],21:[function(e,t,n){(function(n){"use strict";function r(e,t,r,s,c){if("production"!==n.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.",s||"React class",r,l),p=e[l](t,l,s,r,null,u)}catch(e){p=e}if(i(!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).",s||"React class",r,l,typeof p),p instanceof Error&&!(p.message in a)){a[p.message]=!0;var f=c?c():"";i(!1,"Failed %s type: %s%s",r,p.message,null!=f?f:"")}}}if("production"!==n.env.NODE_ENV)var o=e("fbjs/lib/invariant"),i=e("fbjs/lib/warning"),u=e("./lib/ReactPropTypesSecret"),a={};t.exports=r}).call(this,e("_process"))},{"./lib/ReactPropTypesSecret":25,_process:3,"fbjs/lib/invariant":5,"fbjs/lib/warning":6}],22:[function(e,t,n){"use strict";var r=e("fbjs/lib/emptyFunction"),o=e("fbjs/lib/invariant");t.exports=function(){function e(){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")}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}},{"fbjs/lib/emptyFunction":4,"fbjs/lib/invariant":5}],23:[function(e,t,n){(function(n){"use strict";var r=e("fbjs/lib/emptyFunction"),o=e("fbjs/lib/invariant"),i=e("fbjs/lib/warning"),u=e("./lib/ReactPropTypesSecret"),a=e("./checkPropTypes");t.exports=function(e,t){function s(e){var t=e&&(T&&e[T]||e[E]);if("function"==typeof t)return t}function c(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,p,f,d,y,h){if(f=f||x,y=y||p,h!==u)if(t)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"!==n.env.NODE_ENV&&"undefined"!=typeof console){var b=f+":"+p;!a[b]&&s<3&&(i(!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.",y,f),a[b]=!0,s++)}return null==c[p]?r?new l(null===c[p]?"The "+d+" `"+y+"` is marked as required in `"+f+"`, but its value is `null`.":"The "+d+" `"+y+"` is marked as required in `"+f+"`, but its value is `undefined`."):null:e(c,p,f,d,y)}if("production"!==n.env.NODE_ENV)var a={},s=0;var c=r.bind(null,!1);return c.isRequired=r.bind(null,!0),c}function f(e){function t(t,n,r,o,i,u){var a=t[n];return O(a)!==e?new l("Invalid "+o+" `"+i+"` of type `"+j(a)+"` supplied to `"+r+"`, expected `"+e+"`."):null}return p(t)}function d(e){function t(t,n,r,o,i){if("function"!=typeof e)return new l("Property `"+i+"` of component `"+r+"` has invalid PropType notation inside arrayOf.");var a=t[n];if(!Array.isArray(a))return new l("Invalid "+o+" `"+i+"` of type `"+O(a)+"` supplied to `"+r+"`, expected an array.");for(var s=0;s<a.length;s++){var c=e(a,s,r,o,i+"["+s+"]",u);if(c instanceof Error)return c}return null}return p(t)}function y(e){function t(t,n,r,o,i){if(!(t[n]instanceof e)){var u=e.name||x;return new l("Invalid "+o+" `"+i+"` of type `"+_(t[n])+"` supplied to `"+r+"`, expected instance of `"+u+"`.")}return null}return p(t)}function h(e){function t(t,n,r,o,i){for(var u=t[n],a=0;a<e.length;a++)if(c(u,e[a]))return null;return new l("Invalid "+o+" `"+i+"` of value `"+u+"` supplied to `"+r+"`, expected one of "+JSON.stringify(e)+".")}return Array.isArray(e)?p(t):("production"!==n.env.NODE_ENV&&i(!1,"Invalid argument supplied to oneOf, expected an instance of array."),r.thatReturnsNull)}function b(e){function t(t,n,r,o,i){if("function"!=typeof e)return new l("Property `"+i+"` of component `"+r+"` has invalid PropType notation inside objectOf.");var a=t[n],s=O(a);if("object"!==s)return new l("Invalid "+o+" `"+i+"` of type `"+s+"` supplied to `"+r+"`, expected an object.");for(var c in a)if(a.hasOwnProperty(c)){var p=e(a,c,r,o,i+"."+c,u);if(p instanceof Error)return p}return null}return p(t)}function v(e){function t(t,n,r,o,i){for(var a=0;a<e.length;a++)if(null==(0,e[a])(t,n,r,o,i,u))return null;return new l("Invalid "+o+" `"+i+"` supplied to `"+r+"`.")}return Array.isArray(e)?p(t):("production"!==n.env.NODE_ENV&&i(!1,"Invalid argument supplied to oneOfType, expected an instance of array."),r.thatReturnsNull)}function m(e){function t(t,n,r,o,i){var a=t[n],s=O(a);if("object"!==s)return new l("Invalid "+o+" `"+i+"` of type `"+s+"` supplied to `"+r+"`, expected `object`.");for(var c in e){var p=e[c];if(p){var f=p(a,c,r,o,i+"."+c,u);if(f)return f}}return null}return p(t)}function g(t){switch(typeof t){case"number":case"string":case"undefined":return!0;case"boolean":return!t;case"object":if(Array.isArray(t))return t.every(g);if(null===t||e(t))return!0;var n=s(t);if(!n)return!1;var r,o=n.call(t);if(n!==t.entries){for(;!(r=o.next()).done;)if(!g(r.value))return!1}else for(;!(r=o.next()).done;){var i=r.value;if(i&&!g(i[1]))return!1}return!0;default:return!1}}function w(e,t){return"symbol"===e||("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}function O(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":w(t,e)?"symbol":t}function j(e){var t=O(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function _(e){return e.constructor&&e.constructor.name?e.constructor.name:x}var T="function"==typeof Symbol&&Symbol.iterator,E="@@iterator",x="<<anonymous>>",S={array:f("array"),bool:f("boolean"),func:f("function"),number:f("number"),object:f("object"),string:f("string"),symbol:f("symbol"),any:function(){return p(r.thatReturnsNull)}(),arrayOf:d,element:function(){function t(t,n,r,o,i){var u=t[n];return e(u)?null:new l("Invalid "+o+" `"+i+"` of type `"+O(u)+"` supplied to `"+r+"`, expected a single ReactElement.")}return p(t)}(),instanceOf:y,node:function(){function e(e,t,n,r,o){return g(e[t])?null:new l("Invalid "+r+" `"+o+"` supplied to `"+n+"`, expected a ReactNode.")}return p(e)}(),objectOf:b,oneOf:h,oneOfType:v,shape:m};return l.prototype=Error.prototype,S.checkPropTypes=a,S.PropTypes=S,S}}).call(this,e("_process"))},{"./checkPropTypes":21,"./lib/ReactPropTypesSecret":25,_process:3,"fbjs/lib/emptyFunction":4,"fbjs/lib/invariant":5,"fbjs/lib/warning":6}],24:[function(e,t,n){(function(n){if("production"!==n.env.NODE_ENV){var r="function"==typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,o=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===r};t.exports=e("./factoryWithTypeCheckers")(o,!0)}else t.exports=e("./factoryWithThrowingShims")()}).call(this,e("_process"))},{"./factoryWithThrowingShims":22,"./factoryWithTypeCheckers":23,_process:3}],25:[function(e,t,n){"use strict";t.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},{}],26:[function(e,t,n){"use strict";function r(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){return function(n,r,u){var a=e(n,r,u),s=a.dispatch,c=[],l={getState:a.getState,dispatch:function(e){return s(e)}};return c=t.map(function(e){return e(l)}),s=i.default.apply(void 0,c)(a.dispatch),o({},a,{dispatch:s})}}}n.__esModule=!0;var o=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};n.default=r;var i=function(e){return e&&e.__esModule?e:{default:e}}(e("./compose"))},{"./compose":29}],27:[function(e,t,n){"use strict";function r(e,t){return function(){return t(e.apply(void 0,arguments))}}function o(e,t){if("function"==typeof e)return r(e,t);if("object"!=typeof e||null===e)throw new Error("bindActionCreators expected an object or a function, instead received "+(null===e?"null":typeof e)+'. Did you write "import ActionCreators from" instead of "import * as ActionCreators from"?');for(var n=Object.keys(e),o={},i=0;i<n.length;i++){var u=n[i],a=e[u];"function"==typeof a&&(o[u]=r(a,t))}return o}n.__esModule=!0,n.default=o},{}],28:[function(e,t,n){(function(t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){var n=t&&t.type;return"Given action "+(n&&'"'+n.toString()+'"'||"an action")+', reducer "'+e+'" returned undefined. To ignore an action, you must explicitly return the previous state.'}function i(e,t,n,r){var o=Object.keys(t),i=n&&n.type===s.ActionTypes.INIT?"preloadedState argument passed to createStore":"previous state received by the reducer";if(0===o.length)return"Store does not have a valid reducer. Make sure the argument passed to combineReducers is an object whose values are reducers.";if(!(0,c.default)(e))return"The "+i+' has unexpected type of "'+{}.toString.call(e).match(/\s([a-z|A-Z]+)/)[1]+'". Expected argument to be an object with the following keys: "'+o.join('", "')+'"';var u=Object.keys(e).filter(function(e){return!t.hasOwnProperty(e)&&!r[e]});return u.forEach(function(e){r[e]=!0}),u.length>0?"Unexpected "+(u.length>1?"keys":"key")+' "'+u.join('", "')+'" found in '+i+'. Expected to find one of the known reducer keys instead: "'+o.join('", "')+'". Unexpected keys will be ignored.':void 0}function u(e){Object.keys(e).forEach(function(t){var n=e[t];if(void 0===n(void 0,{type:s.ActionTypes.INIT}))throw new Error('Reducer "'+t+'" returned undefined during initialization. If the state passed to the reducer is undefined, you must explicitly return the initial state. The initial state may not be undefined.');if(void 0===n(void 0,{type:"@@redux/PROBE_UNKNOWN_ACTION_"+Math.random().toString(36).substring(7).split("").join(".")}))throw new Error('Reducer "'+t+"\" returned undefined when probed with a random type. Don't try to handle "+s.ActionTypes.INIT+' or other actions in "redux/*" namespace. They are considered private. Instead, you must return the current state for any unknown actions, unless it is undefined, in which case you must return the initial state, regardless of the action type. The initial state may not be undefined.')})}function a(e){for(var n=Object.keys(e),r={},a=0;a<n.length;a++){var s=n[a];"production"!==t.env.NODE_ENV&&void 0===e[s]&&(0,l.default)('No reducer provided for key "'+s+'"'),"function"==typeof e[s]&&(r[s]=e[s])}var c=Object.keys(r);if("production"!==t.env.NODE_ENV)var p={};var f;try{u(r)}catch(e){f=e}return function(){var e=arguments.length<=0||void 0===arguments[0]?{}:arguments[0],n=arguments[1];if(f)throw f;if("production"!==t.env.NODE_ENV){var u=i(e,r,n,p);u&&(0,l.default)(u)}for(var a=!1,s={},d=0;d<c.length;d++){var y=c[d],h=r[y],b=e[y],v=h(b,n);if(void 0===v){var m=o(y,n);throw new Error(m)}s[y]=v,a=a||v!==b}return a?s:e}}n.__esModule=!0,n.default=a;var s=e("./createStore"),c=r(e("lodash/isPlainObject")),l=r(e("./utils/warning"))}).call(this,e("_process"))},{"./createStore":30,"./utils/warning":32,_process:3,"lodash/isPlainObject":19}],29:[function(e,t,n){"use strict";function r(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];if(0===t.length)return function(e){return e};if(1===t.length)return t[0];var r=t[t.length-1],o=t.slice(0,-1);return function(){return o.reduceRight(function(e,t){return t(e)},r.apply(void 0,arguments))}}n.__esModule=!0,n.default=r},{}],30:[function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t,n){function r(){v===b&&(v=b.slice())}function s(){return h}function c(e){if("function"!=typeof e)throw new Error("Expected listener to be a function.");var t=!0;return r(),v.push(e),function(){if(t){t=!1,r();var n=v.indexOf(e);v.splice(n,1)}}}function l(e){if(!(0,i.default)(e))throw new Error("Actions must be plain objects. Use custom middleware for async actions.");if(void 0===e.type)throw new Error('Actions may not have an undefined "type" property. Have you misspelled a constant?');if(m)throw new Error("Reducers may not dispatch actions.");try{m=!0,h=y(h,e)}finally{m=!1}for(var t=b=v,n=0;n<t.length;n++)t[n]();return e}function p(e){if("function"!=typeof e)throw new Error("Expected the nextReducer to be a function.");y=e,l({type:a.INIT})}function f(){var e,t=c;return e={subscribe:function(e){function n(){e.next&&e.next(s())}if("object"!=typeof e)throw new TypeError("Expected the observer to be an object.");return n(),{unsubscribe:t(n)}}},e[u.default]=function(){return this},e}var d;if("function"==typeof t&&void 0===n&&(n=t,t=void 0),void 0!==n){if("function"!=typeof n)throw new Error("Expected the enhancer to be a function.");return n(o)(e,t)}if("function"!=typeof e)throw new Error("Expected the reducer to be a function.");var y=e,h=t,b=[],v=b,m=!1;return l({type:a.INIT}),d={dispatch:l,subscribe:c,getState:s,replaceReducer:p},d[u.default]=f,d}n.__esModule=!0,n.ActionTypes=void 0,n.default=o;var i=r(e("lodash/isPlainObject")),u=r(e("symbol-observable")),a=n.ActionTypes={INIT:"@@redux/INIT"}},{"lodash/isPlainObject":19,"symbol-observable":33}],31:[function(e,t,n){(function(t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(){}n.__esModule=!0,n.compose=n.applyMiddleware=n.bindActionCreators=n.combineReducers=n.createStore=void 0;var i=r(e("./createStore")),u=r(e("./combineReducers")),a=r(e("./bindActionCreators")),s=r(e("./applyMiddleware")),c=r(e("./compose")),l=r(e("./utils/warning"));"production"!==t.env.NODE_ENV&&"string"==typeof o.name&&"isCrushed"!==o.name&&(0,l.default)("You are currently using minified code outside of NODE_ENV === 'production'. This means that you are running a slower development build of Redux. You can use loose-envify (https://github.com/zertosh/loose-envify) for browserify or DefinePlugin for webpack (http://stackoverflow.com/questions/30030031) to ensure you have the correct code for your production build."),n.createStore=i.default,n.combineReducers=u.default,n.bindActionCreators=a.default,n.applyMiddleware=s.default,n.compose=c.default}).call(this,e("_process"))},{"./applyMiddleware":26,"./bindActionCreators":27,"./combineReducers":28,"./compose":29,"./createStore":30,"./utils/warning":32,_process:3}],32:[function(e,t,n){"use strict";function r(e){"undefined"!=typeof console&&"function"==typeof console.error&&console.error(e);try{throw new Error(e)}catch(e){}}n.__esModule=!0,n.default=r},{}],33:[function(e,t,n){t.exports=e("./lib/index")},{"./lib/index":34}],34:[function(e,t,n){(function(r){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i=function(e){return e&&e.__esModule?e:{default:e}}(e("./ponyfill"));o="undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==r?r:void 0!==t?t:Function("return this")();var u=(0,i.default)(o);n.default=u}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./ponyfill":35}],35:[function(e,t,n){"use strict";function r(e){var t,n=e.Symbol;return"function"==typeof n?n.observable?t=n.observable:(t=n("observable"),n.observable=t):t="@@observable",t}Object.defineProperty(n,"__esModule",{value:!0}),n.default=r},{}]},{},[1]);