!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("maka"),require("react"),require("prop-types")):"function"==typeof define&&define.amd?define(["maka","react","prop-types"],t):"object"==typeof exports?exports["MakaApp-react-media"]=t(require("maka"),require("react"),require("prop-types")):e["MakaApp-react-media"]=t(e.maka,e.react,e["prop-types"])}(window,function(n,r,i){return function(n){var r={};function i(e){if(r[e])return r[e].exports;var t=r[e]={i:e,l:!1,exports:{}};return n[e].call(t.exports,t,t.exports,i),t.l=!0,t.exports}return i.m=n,i.c=r,i.d=function(e,t,n){i.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(t,e){if(1&e&&(t=i(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(i.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)i.d(n,r,function(e){return t[e]}.bind(null,r));return n},i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,"a",t),t},i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},i.p="",i(i.s=6)}([function(e,t){e.exports=n},function(e,t){e.exports=r},function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}},function(e){e.exports={isMakaApp:!0,name:"react-media",description:"react-media",version:"1.0.0",license:"MIT",author:"",repository:{type:"git",url:"https://github.com/makajs/react-media.git"},bugs:{url:"https://github.com/makajs/react-media/issues"},homepage:"https://github.com/makajs/react-media#readme",scripts:{start:"maka start",dev:"maka start --dev",build:"maka build",pkg:"maka pkg"},dependencies:{},server:{proxy:null,port:8e3},subAppDir:"./apps",devDependencies:{"react-media":"^1.9.2"}}},function(e,t,n){"use strict";e.exports=function(e,t,n,r,i,a,o,c){if(!e){var s;if(void 0===t)s=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var u=[n,r,i,a,o,c],p=0;(s=new Error(t.replace(/%s/g,function(){return u[p++]}))).name="Invariant Violation"}throw s.framesToPop=1,s}}},function(e,t,n){var o=n(9),i=function(r){var i="",a=Object.keys(r);return a.forEach(function(e,t){var n=r[e];e=o(e),/[height|width]$/.test(e)&&"number"==typeof n&&(n+="px"),i+=!0===n?e:!1===n?"not "+e:"("+e+": "+n+")",t<a.length-1&&(i+=" and ")}),i};e.exports=function(n){var r="";return"string"==typeof n?n:n instanceof Array?(n.forEach(function(e,t){r+=i(e),t<n.length-1&&(r+=", ")}),r):i(n)}},function(e,t,n){e.exports=n(10)},function(e,t,n){},function(e,t){e.exports=i},function(e,t){e.exports=function(e){return e.replace(/[A-Z]/g,function(e){return"-"+e.toLowerCase()}).toLowerCase()}},function(e,t,n){"use strict";n.r(t);var r=n(2),i=n.n(r),a=n(3),o=n(0);n(7);function c(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var u=n(1),p=n.n(u),f=(n(8),n(4)),d=n.n(f),l=n(5),h=n.n(l),m=function(){function e(e,t,n){var r=this;this.nativeMediaQueryList=e.matchMedia(t),this.active=!0,this.cancellableListener=function(){r.matches=r.nativeMediaQueryList.matches,r.active&&n.apply(void 0,arguments)},this.nativeMediaQueryList.addListener(this.cancellableListener),this.matches=this.nativeMediaQueryList.matches}return e.prototype.cancel=function(){this.active=!1,this.nativeMediaQueryList.removeListener(this.cancellableListener)},e}(),y=function(i){var e,t;function n(){for(var n,e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return s(c(c(n=i.call.apply(i,[this].concat(t))||this)),"state",{matches:n.props.defaultMatches}),s(c(c(n)),"updateMatches",function(){var e=n.mediaQueryList.matches;n.setState({matches:e});var t=n.props.onChange;t&&t(e)}),n}t=i,(e=n).prototype=Object.create(t.prototype),(e.prototype.constructor=e).__proto__=t;var r=n.prototype;return r.componentWillMount=function(){if("object"==typeof window){var e=this.props.targetWindow||window;"function"!=typeof e.matchMedia&&d()(!1);var t=this.props.query;"string"!=typeof t&&(t=h()(t)),this.mediaQueryList=new m(e,t,this.updateMatches),this.updateMatches()}},r.componentWillUnmount=function(){this.mediaQueryList.cancel()},r.render=function(){var e=this.props,t=e.children,n=e.render,r=this.state.matches;return n?r?n():null:t?"function"==typeof t?t(r):(!Array.isArray(t)||t.length)&&r?p.a.Children.only(t):null:null},n}(p.a.Component);s(y,"defaultProps",{defaultMatches:!0});var v,b=y;n.d(t,"name",function(){return g}),n.d(t,"state",function(){return x}),n.d(t,"action",function(){return w}),n.d(t,"view",function(){return M});var g=a.name;Object(o.registerComponent)("Media",b);var x={data:{}},w=Object(o.actionMixin)("base")(v=function e(t){i()(this,e),Object.assign(this,t.mixins)})||v,M={component:"div",className:"react-media",children:[{component:"Media",query:"(max-width: 599px)",children:{_function:"(matches)",component:"p",children:"{{matches?'The document is less than 600px wide.': 'The document is at least 600px wide.'}}"}}]}}])});