Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

react-reflex

Package Overview
Dependencies
Maintainers
1
Versions
102
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-reflex - npm Package Compare versions

Comparing version 3.0.9 to 3.0.10

12

dist/commonjs/ReflexContainer.js

@@ -234,6 +234,5 @@ "use strict";

var children = this.getValidChildren(props);
var childCountHasChanged = children.length !== this.state.flexData.length;
if (childCountHasChanged || this.flexHasChanged(props)) {
var flexData = this.computeFlexData(children);
if (children.length !== this.state.flexData.length || props.orientation !== this.props.orientation || this.flexHasChanged(props)) {
var flexData = this.computeFlexData(children, props);
this.setState({

@@ -445,5 +444,7 @@ flexData: flexData

value: function computePixelFlex() {
var orientation = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : this.props.orientation;
var domElement = _reactDom.default.findDOMNode(this);
switch (this.props.orientation) {
switch (orientation) {
case 'horizontal':

@@ -583,3 +584,4 @@ if (domElement.offsetHeight === 0.0) {

var children = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : this.getValidChildren();
var pixelFlex = this.computePixelFlex();
var props = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : this.props;
var pixelFlex = this.computePixelFlex(props.orientation);

@@ -586,0 +588,0 @@ var computeFreeFlex = function computeFreeFlex(flexData) {

@@ -183,6 +183,5 @@ import _objectSpread from "@babel/runtime/helpers/objectSpread";

const children = this.getValidChildren(props);
const childCountHasChanged = children.length !== this.state.flexData.length;
if (childCountHasChanged || this.flexHasChanged(props)) {
const flexData = this.computeFlexData(children);
if (children.length !== this.state.flexData.length || props.orientation !== this.props.orientation || this.flexHasChanged(props)) {
const flexData = this.computeFlexData(children, props);
this.setState({

@@ -377,6 +376,6 @@ flexData

computePixelFlex() {
computePixelFlex(orientation = this.props.orientation) {
const domElement = ReactDOM.findDOMNode(this);
switch (this.props.orientation) {
switch (orientation) {
case 'horizontal':

@@ -502,4 +501,4 @@ if (domElement.offsetHeight === 0.0) {

computeFlexData(children = this.getValidChildren()) {
const pixelFlex = this.computePixelFlex();
computeFlexData(children = this.getValidChildren(), props = this.props) {
const pixelFlex = this.computePixelFlex(props.orientation);

@@ -506,0 +505,0 @@ const computeFreeFlex = flexData => {

!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react"),require("react-dom")):"function"==typeof define&&define.amd?define(["react","react-dom"],t):"object"==typeof exports?exports["react-reflex"]=t(require("react"),require("react-dom")):e["react-reflex"]=t(e.React,e.ReactDOM)}(window,function(e,t){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,function(t){return e[t]}.bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=18)}([function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}},function(e,t,n){e.exports=n(24)()},function(t,n){t.exports=e},function(e,t){e.exports=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}},function(e,t){function n(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)}}e.exports=function(e,t,r){return t&&n(e.prototype,t),r&&n(e,r),e}},function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}},function(e,t,n){var r=n(19),i=n(20),o=n(21);e.exports=function(e){return r(e)||i(e)||o()}},function(e,n){e.exports=t},function(e,t,n){var r=n(22),i=n(0);e.exports=function(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?i(e):t}},function(e,t){function n(t){return e.exports=n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},n(t)}e.exports=n},function(e,t,n){var r=n(23);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&r(e,t)}},function(e,t,n){var r=n(3);e.exports=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),i.forEach(function(t){r(e,t,n[t])})}return e}},function(e,t,n){e.exports=n(27)},function(e,t){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=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},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(2),s=(f(o),f(n(1))),a=f(n(30)),u=f(n(31)),c=f(n(32));function f(e){return e&&e.__esModule?e:{default:e}}function l(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}t.default=function(e){return function(t){var n,f;return f=n=function(n){function s(){var t,n,r;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s);for(var i=arguments.length,o=Array(i),a=0;a<i;a++)o[a]=arguments[a];return n=r=l(this,(t=s.__proto__||Object.getPrototypeOf(s)).call.apply(t,[this].concat(o))),r.state={contentRect:{entry:{},client:{},offset:{},scroll:{},bounds:{},margin:{}}},r.measure=function(t){var n=(0,c.default)(r._node,e||(0,u.default)(r.props));t&&(n.entry=t[0].contentRect),r.setState({contentRect:n}),"function"==typeof r.props.onResize&&r.props.onResize(n)},r._handleRef=function(e){r._resizeObserver&&(e?r._resizeObserver.observe(e):r._resizeObserver.disconnect(r._node)),r._node=e,"function"==typeof r.props.innerRef&&r.props.innerRef(e)},l(r,n)}return function(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)}(s,o.Component),i(s,[{key:"componentWillMount",value:function(){this._resizeObserver=new a.default(this.measure)}},{key:"componentWillUnmount",value:function(){this._resizeObserver&&this._node&&this._resizeObserver.disconnect(this._node),this._resizeObserver=null}},{key:"render",value:function(){var e=this.props,n=(e.innerRef,e.onResize,function(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}(e,["innerRef","onResize"]));return(0,o.createElement)(t,r({},n,{measureRef:this._handleRef,measure:this.measure,contentRect:this.state.contentRect}))}}]),s}(),n.propTypes={client:s.default.bool,offset:s.default.bool,scroll:s.default.bool,bounds:s.default.bool,margin:s.default.bool,innerRef:s.default.func,onResize:s.default.func},f}}},function(e,t){function n(e,t,n,r,i,o,s){try{var a=e[o](s),u=a.value}catch(e){return void n(e)}a.done?t(u):Promise.resolve(u).then(r,i)}e.exports=function(e){return function(){var t=this,r=arguments;return new Promise(function(i,o){var s=e.apply(t,r);function a(e){n(s,i,o,a,u,"next",e)}function u(e){n(s,i,o,a,u,"throw",e)}a(void 0)})}}},function(e,t,n){(function(t){var n="Expected a function",r=NaN,i="[object Symbol]",o=/^\s+|\s+$/g,s=/^[-+]0x[0-9a-f]+$/i,a=/^0b[01]+$/i,u=/^0o[0-7]+$/i,c=parseInt,f="object"==typeof t&&t&&t.Object===Object&&t,l="object"==typeof self&&self&&self.Object===Object&&self,h=f||l||Function("return this")(),p=Object.prototype.toString,d=Math.max,v=Math.min,m=function(){return h.Date.now()};function y(e,t,r){var i,o,s,a,u,c,f=0,l=!1,h=!1,p=!0;if("function"!=typeof e)throw new TypeError(n);function y(t){var n=i,r=o;return i=o=void 0,f=t,a=e.apply(r,n)}function w(e){var n=e-c;return void 0===c||n>=t||n<0||h&&e-f>=s}function x(){var e=m();if(w(e))return _(e);u=setTimeout(x,function(e){var n=t-(e-c);return h?v(n,s-(e-f)):n}(e))}function _(e){return u=void 0,p&&i?y(e):(i=o=void 0,a)}function O(){var e=m(),n=w(e);if(i=arguments,o=this,c=e,n){if(void 0===u)return function(e){return f=e,u=setTimeout(x,t),l?y(e):a}(c);if(h)return u=setTimeout(x,t),y(c)}return void 0===u&&(u=setTimeout(x,t)),a}return t=b(t)||0,g(r)&&(l=!!r.leading,s=(h="maxWait"in r)?d(b(r.maxWait)||0,t):s,p="trailing"in r?!!r.trailing:p),O.cancel=function(){void 0!==u&&clearTimeout(u),f=0,i=c=o=u=void 0},O.flush=function(){return void 0===u?a:_(m())},O}function g(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function b(e){if("number"==typeof e)return e;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&p.call(e)==i}(e))return r;if(g(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=g(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(o,"");var n=a.test(e);return n||u.test(e)?c(e.slice(2),n?2:8):s.test(e)?r:+e}e.exports=function(e,t,r){var i=!0,o=!0;if("function"!=typeof e)throw new TypeError(n);return g(r)&&(i="leading"in r?!!r.leading:i,o="trailing"in r?!!r.trailing:o),y(e,t,{leading:i,maxWait:t,trailing:o})}}).call(this,n(13))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.withContentRect=t.default=void 0;var r=o(n(29)),i=o(n(14));function o(e){return e&&e.__esModule?e:{default:e}}t.default=r.default,t.withContentRect=i.default},function(e,t,n){e.exports=n(33)},function(e,t){e.exports=function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t<e.length;t++)n[t]=e[t];return n}}},function(e,t){e.exports=function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}},function(e,t){e.exports=function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}},function(e,t){function n(e){return(n="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})(e)}function r(t){return"function"==typeof Symbol&&"symbol"===n(Symbol.iterator)?e.exports=r=function(e){return n(e)}:e.exports=r=function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":n(e)},r(t)}e.exports=r},function(e,t){function n(t,r){return e.exports=n=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},n(t,r)}e.exports=n},function(e,t,n){"use strict";var r=n(25);function i(){}e.exports=function(){function e(e,t,n,i,o,s){if(s!==r){var a=new Error("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");throw a.name="Invariant Violation",a}}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,exact:t};return n.checkPropTypes=i,n.PropTypes=n,n}},function(e,t,n){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},function(e,t){Array.prototype.includes||Object.defineProperty(Array.prototype,"includes",{value:function(e,t){if(null==this)throw new TypeError('"this" is null or not defined');var n=Object(this),r=n.length>>>0;if(0===r)return!1;var i=0|t,o=Math.max(i>=0?i:r-Math.abs(i),0);function s(e,t){return e===t||"number"==typeof e&&"number"==typeof t&&isNaN(e)&&isNaN(t)}for(;o<r;){if(s(n[o],e))return!0;o++}return!1}}),Math.sign||(Math.sign=function(e){return(e>0)-(e<0)||+e})},function(e,t,n){var r=function(){return this||"object"==typeof self&&self}()||Function("return this")(),i=r.regeneratorRuntime&&Object.getOwnPropertyNames(r).indexOf("regeneratorRuntime")>=0,o=i&&r.regeneratorRuntime;if(r.regeneratorRuntime=void 0,e.exports=n(28),i)r.regeneratorRuntime=o;else try{delete r.regeneratorRuntime}catch(e){r.regeneratorRuntime=void 0}},function(e,t){!function(t){"use strict";var n,r=Object.prototype,i=r.hasOwnProperty,o="function"==typeof Symbol?Symbol:{},s=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",u=o.toStringTag||"@@toStringTag",c="object"==typeof e,f=t.regeneratorRuntime;if(f)c&&(e.exports=f);else{(f=t.regeneratorRuntime=c?e.exports:{}).wrap=w;var l="suspendedStart",h="suspendedYield",p="executing",d="completed",v={},m={};m[s]=function(){return this};var y=Object.getPrototypeOf,g=y&&y(y(j([])));g&&g!==r&&i.call(g,s)&&(m=g);var b=z.prototype=_.prototype=Object.create(m);O.prototype=b.constructor=z,z.constructor=O,z[u]=O.displayName="GeneratorFunction",f.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===O||"GeneratorFunction"===(t.displayName||t.name))},f.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,z):(e.__proto__=z,u in e||(e[u]="GeneratorFunction")),e.prototype=Object.create(b),e},f.awrap=function(e){return{__await:e}},E(M.prototype),M.prototype[a]=function(){return this},f.AsyncIterator=M,f.async=function(e,t,n,r){var i=new M(w(e,t,n,r));return f.isGeneratorFunction(t)?i:i.next().then(function(e){return e.done?e.value:i.next()})},E(b),b[u]="Generator",b[s]=function(){return this},b.toString=function(){return"[object Generator]"},f.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){for(;t.length;){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},f.values=j,A.prototype={constructor:A,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=n,this.done=!1,this.delegate=null,this.method="next",this.arg=n,this.tryEntries.forEach(k),!e)for(var t in this)"t"===t.charAt(0)&&i.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=n)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(r,i){return a.type="throw",a.arg=e,t.next=r,i&&(t.method="next",t.arg=n),!!i}for(var o=this.tryEntries.length-1;o>=0;--o){var s=this.tryEntries[o],a=s.completion;if("root"===s.tryLoc)return r("end");if(s.tryLoc<=this.prev){var u=i.call(s,"catchLoc"),c=i.call(s,"finallyLoc");if(u&&c){if(this.prev<s.catchLoc)return r(s.catchLoc,!0);if(this.prev<s.finallyLoc)return r(s.finallyLoc)}else if(u){if(this.prev<s.catchLoc)return r(s.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<s.finallyLoc)return r(s.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&i.call(r,"finallyLoc")&&this.prev<r.finallyLoc){var o=r;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var s=o?o.completion:{};return s.type=e,s.arg=t,o?(this.method="next",this.next=o.finallyLoc,v):this.complete(s)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),v},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),k(n),v}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;k(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,r){return this.delegate={iterator:j(e),resultName:t,nextLoc:r},"next"===this.method&&(this.arg=n),v}}}function w(e,t,n,r){var i=t&&t.prototype instanceof _?t:_,o=Object.create(i.prototype),s=new A(r||[]);return o._invoke=function(e,t,n){var r=l;return function(i,o){if(r===p)throw new Error("Generator is already running");if(r===d){if("throw"===i)throw o;return P()}for(n.method=i,n.arg=o;;){var s=n.delegate;if(s){var a=R(s,n);if(a){if(a===v)continue;return a}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(r===l)throw r=d,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r=p;var u=x(e,t,n);if("normal"===u.type){if(r=n.done?d:h,u.arg===v)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(r=d,n.method="throw",n.arg=u.arg)}}}(e,n,s),o}function x(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}function _(){}function O(){}function z(){}function E(e){["next","throw","return"].forEach(function(t){e[t]=function(e){return this._invoke(t,e)}})}function M(e){var t;this._invoke=function(n,r){function o(){return new Promise(function(t,o){!function t(n,r,o,s){var a=x(e[n],e,r);if("throw"!==a.type){var u=a.arg,c=u.value;return c&&"object"==typeof c&&i.call(c,"__await")?Promise.resolve(c.__await).then(function(e){t("next",e,o,s)},function(e){t("throw",e,o,s)}):Promise.resolve(c).then(function(e){u.value=e,o(u)},function(e){return t("throw",e,o,s)})}s(a.arg)}(n,r,t,o)})}return t=t?t.then(o,o):o()}}function R(e,t){var r=e.iterator[t.method];if(r===n){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=n,R(e,t),"throw"===t.method))return v;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return v}var i=x(r,e.iterator,t.arg);if("throw"===i.type)return t.method="throw",t.arg=i.arg,t.delegate=null,v;var o=i.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=n),t.delegate=null,v):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,v)}function S(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function k(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function A(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(S,this),this.reset(!0)}function j(e){if(e){var t=e[s];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,o=function t(){for(;++r<e.length;)if(i.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=n,t.done=!0,t};return o.next=o}}return{next:P}}function P(){return{value:n,done:!0}}}(function(){return this||"object"==typeof self&&self}()||Function("return this")())},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});i(n(2));var r=i(n(1));function i(e){return e&&e.__esModule?e:{default:e}}var o=(0,i(n(14)).default)()(function(e){var t=e.measure,n=e.measureRef,r=e.contentRect;return(0,e.children)({measure:t,measureRef:n,contentRect:r})});o.displayName="Measure",o.propTypes.children=r.default.func,t.default=o},function(e,t,n){"use strict";n.r(t),function(e){var n=function(){if("undefined"!=typeof Map)return Map;function e(e,t){var n=-1;return e.some(function(e,r){return e[0]===t&&(n=r,!0)}),n}return function(){function t(){this.__entries__=[]}var n={size:{configurable:!0}};return n.size.get=function(){return this.__entries__.length},t.prototype.get=function(t){var n=e(this.__entries__,t),r=this.__entries__[n];return r&&r[1]},t.prototype.set=function(t,n){var r=e(this.__entries__,t);~r?this.__entries__[r][1]=n:this.__entries__.push([t,n])},t.prototype.delete=function(t){var n=this.__entries__,r=e(n,t);~r&&n.splice(r,1)},t.prototype.has=function(t){return!!~e(this.__entries__,t)},t.prototype.clear=function(){this.__entries__.splice(0)},t.prototype.forEach=function(e,t){void 0===t&&(t=null);for(var n=0,r=this.__entries__;n<r.length;n+=1){var i=r[n];e.call(t,i[1],i[0])}},Object.defineProperties(t.prototype,n),t}()}(),r="undefined"!=typeof window&&"undefined"!=typeof document&&window.document===document,i=void 0!==e&&e.Math===Math?e:"undefined"!=typeof self&&self.Math===Math?self:"undefined"!=typeof window&&window.Math===Math?window:Function("return this")(),o="function"==typeof requestAnimationFrame?requestAnimationFrame.bind(i):function(e){return setTimeout(function(){return e(Date.now())},1e3/60)},s=2,a=["top","right","bottom","left","width","height","size","weight"],u="undefined"!=typeof MutationObserver,c=function(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=function(e,t){var n=!1,r=!1,i=0;function a(){n&&(n=!1,e()),r&&c()}function u(){o(a)}function c(){var e=Date.now();if(n){if(e-i<s)return;r=!0}else n=!0,r=!1,setTimeout(u,t);i=e}return c}(this.refresh.bind(this),20)};c.prototype.addObserver=function(e){~this.observers_.indexOf(e)||this.observers_.push(e),this.connected_||this.connect_()},c.prototype.removeObserver=function(e){var t=this.observers_,n=t.indexOf(e);~n&&t.splice(n,1),!t.length&&this.connected_&&this.disconnect_()},c.prototype.refresh=function(){this.updateObservers_()&&this.refresh()},c.prototype.updateObservers_=function(){var e=this.observers_.filter(function(e){return e.gatherActive(),e.hasActive()});return e.forEach(function(e){return e.broadcastActive()}),e.length>0},c.prototype.connect_=function(){r&&!this.connected_&&(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),u?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},c.prototype.disconnect_=function(){r&&this.connected_&&(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},c.prototype.onTransitionEnd_=function(e){var t=e.propertyName;void 0===t&&(t=""),a.some(function(e){return!!~t.indexOf(e)})&&this.refresh()},c.getInstance=function(){return this.instance_||(this.instance_=new c),this.instance_},c.instance_=null;var f=function(e,t){for(var n=0,r=Object.keys(t);n<r.length;n+=1){var i=r[n];Object.defineProperty(e,i,{value:t[i],enumerable:!1,writable:!1,configurable:!0})}return e},l=function(e){return e&&e.ownerDocument&&e.ownerDocument.defaultView||i},h=g(0,0,0,0);function p(e){return parseFloat(e)||0}function d(e){for(var t=[],n=arguments.length-1;n-- >0;)t[n]=arguments[n+1];return t.reduce(function(t,n){return t+p(e["border-"+n+"-width"])},0)}function v(e){var t=e.clientWidth,n=e.clientHeight;if(!t&&!n)return h;var r=l(e).getComputedStyle(e),i=function(e){for(var t={},n=0,r=["top","right","bottom","left"];n<r.length;n+=1){var i=r[n],o=e["padding-"+i];t[i]=p(o)}return t}(r),o=i.left+i.right,s=i.top+i.bottom,a=p(r.width),u=p(r.height);if("border-box"===r.boxSizing&&(Math.round(a+o)!==t&&(a-=d(r,"left","right")+o),Math.round(u+s)!==n&&(u-=d(r,"top","bottom")+s)),!function(e){return e===l(e).document.documentElement}(e)){var c=Math.round(a+o)-t,f=Math.round(u+s)-n;1!==Math.abs(c)&&(a-=c),1!==Math.abs(f)&&(u-=f)}return g(i.left,i.top,a,u)}var m="undefined"!=typeof SVGGraphicsElement?function(e){return e instanceof l(e).SVGGraphicsElement}:function(e){return e instanceof l(e).SVGElement&&"function"==typeof e.getBBox};function y(e){return r?m(e)?function(e){var t=e.getBBox();return g(0,0,t.width,t.height)}(e):v(e):h}function g(e,t,n,r){return{x:e,y:t,width:n,height:r}}var b=function(e){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=g(0,0,0,0),this.target=e};b.prototype.isActive=function(){var e=y(this.target);return this.contentRect_=e,e.width!==this.broadcastWidth||e.height!==this.broadcastHeight},b.prototype.broadcastRect=function(){var e=this.contentRect_;return this.broadcastWidth=e.width,this.broadcastHeight=e.height,e};var w=function(e,t){var n=function(e){var t=e.x,n=e.y,r=e.width,i=e.height,o="undefined"!=typeof DOMRectReadOnly?DOMRectReadOnly:Object,s=Object.create(o.prototype);return f(s,{x:t,y:n,width:r,height:i,top:n,right:t+r,bottom:i+n,left:t}),s}(t);f(this,{target:e,contentRect:n})},x=function(e,t,r){if(this.activeObservations_=[],this.observations_=new n,"function"!=typeof e)throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=e,this.controller_=t,this.callbackCtx_=r};x.prototype.observe=function(e){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!=typeof Element&&Element instanceof Object){if(!(e instanceof l(e).Element))throw new TypeError('parameter 1 is not of type "Element".');var t=this.observations_;t.has(e)||(t.set(e,new b(e)),this.controller_.addObserver(this),this.controller_.refresh())}},x.prototype.unobserve=function(e){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!=typeof Element&&Element instanceof Object){if(!(e instanceof l(e).Element))throw new TypeError('parameter 1 is not of type "Element".');var t=this.observations_;t.has(e)&&(t.delete(e),t.size||this.controller_.removeObserver(this))}},x.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},x.prototype.gatherActive=function(){var e=this;this.clearActive(),this.observations_.forEach(function(t){t.isActive()&&e.activeObservations_.push(t)})},x.prototype.broadcastActive=function(){if(this.hasActive()){var e=this.callbackCtx_,t=this.activeObservations_.map(function(e){return new w(e.target,e.broadcastRect())});this.callback_.call(e,t,e),this.clearActive()}},x.prototype.clearActive=function(){this.activeObservations_.splice(0)},x.prototype.hasActive=function(){return this.activeObservations_.length>0};var _="undefined"!=typeof WeakMap?new WeakMap:new n,O=function(e){if(!(this instanceof O))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var t=c.getInstance(),n=new x(e,t,this);_.set(this,n)};["observe","unobserve","disconnect"].forEach(function(e){O.prototype[e]=function(){return(t=_.get(this))[e].apply(t,arguments);var t}});var z=void 0!==i.ResizeObserver?i.ResizeObserver:O;t.default=z}.call(this,n(13))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=[];return r.forEach(function(n){e[n]&&t.push(n)}),t};var r=["client","offset","scroll","bounds","margin"]},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var n={};if(t.indexOf("client")>-1&&(n.client={top:e.clientTop,left:e.clientLeft,width:e.clientWidth,height:e.clientHeight}),t.indexOf("offset")>-1&&(n.offset={top:e.offsetTop,left:e.offsetLeft,width:e.offsetWidth,height:e.offsetHeight}),t.indexOf("scroll")>-1&&(n.scroll={top:e.scrollTop,left:e.scrollLeft,width:e.scrollWidth,height:e.scrollHeight}),t.indexOf("bounds")>-1){var r=e.getBoundingClientRect();n.bounds={top:r.top,right:r.right,bottom:r.bottom,left:r.left,width:r.width,height:r.height}}if(t.indexOf("margin")>-1){var i=getComputedStyle(e);n.margin={top:parseInt(i.marginTop),right:parseInt(i.marginRight),bottom:parseInt(i.marginBottom),left:parseInt(i.marginLeft)}}return n}},function(e,t,n){"use strict";n.r(t);var r=n(11),i=n.n(r),o=n(6),s=n.n(o),a=n(5),u=n.n(a),c=n(4),f=n.n(c),l=n(8),h=n.n(l),p=n(9),d=n.n(p),v=n(10),m=n.n(v),y=n(0),g=n.n(y),b=n(3),w=n.n(b),x=n(1),_=n.n(x),O=n(7),z=n.n(O),E=function(){function e(){u()(this,e)}return f()(e,null,[{key:"isBrowser",value:function(){return"undefined"!=typeof window}},{key:"isOpera",value:function(){return e.isBrowser()&&(!!window.opera||navigator.userAgent.indexOf(" OPR/")>=0)}},{key:"isFirefox",value:function(){return e.isBrowser()&&"undefined"!=typeof InstallTrigger}},{key:"isSafari",value:function(){return!!e.isBrowser()&&/^((?!chrome|android).)*safari/i.test(navigator.userAgent)}},{key:"isIE",value:function(){
/*@cc_on!@*/
return e.isBrowser()&&!!document.documentMode}},{key:"isEdge",value:function(){return e.isBrowser()&&!e.isIE()&&!!window.StyleMedia}},{key:"isChrome",value:function(){return e.isBrowser()&&!!window.chrome&&!!window.chrome.webstore}},{key:"isBlink",value:function(){return e.isBrowser()&&(e.isChrome()||e.isOpera())&&!!window.CSS}},{key:"getUserAgent",value:function(){return"undefined"==typeof navigator?"":navigator.userAgent}},{key:"isAndroid",value:function(){return e.isBrowser()&&e.getUserAgent().match(/Android/i)}},{key:"isBlackBerry",value:function(){return e.isBrowser()&&e.getUserAgent().match(/BlackBerry/i)}},{key:"isIOS",value:function(){return e.isBrowser()&&e.getUserAgent().match(/iPhone|iPad|iPod/i)}},{key:"isOpera",value:function(){return e.isBrowser()&&e.getUserAgent().match(/Opera Mini/i)}},{key:"isWindows",value:function(){return e.isBrowser()&&e.isWindowsDesktop()||e.isWindowsMobile()}},{key:"isWindowsMobile",value:function(){return e.isBrowser()&&e.getUserAgent().match(/IEMobile/i)}},{key:"isWindowsDesktop",value:function(){return e.isBrowser()&&e.getUserAgent().match(/WPDesktop/i)}},{key:"isMobile",value:function(){return e.isBrowser()&&(e.isWindowsMobile()||e.isBlackBerry()||e.isAndroid()||e.isIOS())}}]),e}(),M=n(2),R=n.n(M),S=function(e){function t(e){var n;return u()(this,t),n=h()(this,d()(t).call(this,e)),w()(g()(g()(n)),"onMouseMove",function(e){n.state.active&&(n.props.events.emit("resize",{index:n.props.index,event:e}),n.props.onResize&&n.props.onResize({domElement:z.a.findDOMNode(g()(g()(n))),component:g()(g()(n))}),e.stopPropagation(),e.preventDefault())}),w()(g()(g()(n)),"onMouseDown",function(e){n.setState({active:!0}),n.props.onStartResize&&n.props.onStartResize({domElement:z.a.findDOMNode(g()(g()(n))),component:g()(g()(n))})||n.props.events.emit("startResize",{index:n.props.index,event:e})}),w()(g()(g()(n)),"onMouseUp",function(e){n.state.active&&(n.setState({active:!1}),n.props.onStopResize&&n.props.onStopResize({domElement:z.a.findDOMNode(g()(g()(n))),component:g()(g()(n))}),n.props.events.emit("stopResize",{index:n.props.index,event:e}))}),n.state={active:!1},n.document=e.document,n}return m()(t,e),f()(t,null,[{key:"isA",value:function(e){return!!e&&e.type===t}}]),f()(t,[{key:"componentDidMount",value:function(){this.document&&(this.document.addEventListener("touchend",this.onMouseUp),this.document.addEventListener("mouseup",this.onMouseUp),this.document.addEventListener("mousemove",this.onMouseMove,{passive:!1}),this.document.addEventListener("touchmove",this.onMouseMove,{passive:!1}))}},{key:"componentWillUnmount",value:function(){this.document&&(this.document.removeEventListener("mouseup",this.onMouseUp),this.document.removeEventListener("touchend",this.onMouseUp),this.document.removeEventListener("mousemove",this.onMouseMove),this.document.removeEventListener("touchmove",this.onMouseMove),this.state.active&&this.props.events.emit("stopResize",{index:this.props.index,event:null}))}},{key:"render",value:function(){var e=[E.isMobile()?"reflex-thin":""].concat(s()(this.props.className.split(" ")),[this.state.active?"active":"","reflex-splitter"]).join(" ");return R.a.createElement("div",{onTouchStart:this.onMouseDown,onMouseDown:this.onMouseDown,style:this.props.style,className:e,id:this.props.id},this.props.children)}}]),t}(R.a.Component);w()(S,"propTypes",{children:_.a.oneOfType([_.a.arrayOf(_.a.node),_.a.node]),onStartResize:_.a.func,onStopResize:_.a.func,className:_.a.string,propagate:_.a.bool,onResize:_.a.func,style:_.a.object}),w()(S,"defaultProps",{document:"undefined"!=typeof document?document:null,onStartResize:null,onStopResize:null,propagate:!1,onResize:null,className:"",style:{}});var k=function(){function e(){u()(this,e),this._events={}}return f()(e,[{key:"on",value:function(e,t){var n=this;return e.split(" ").forEach(function(e){n._events[e]=n._events[e]||[],n._events[e].push(t)}),this}},{key:"off",value:function(e,t){var n=this;if(void 0!=e)return e.split(" ").forEach(function(e){e in n._events!=!1&&(t?n._events[e].splice(n._events[e].indexOf(t),1):n._events[e]=[])}),this;this._events={}}},{key:"emit",value:function(e){if(void 0!==this._events[e])for(var t=this._events[e].slice(),n=0;n<t.length;++n){var r=t[n].apply(this,Array.prototype.slice.call(arguments,1));if(void 0!==r)return r}}}]),e}(),A=(n(26),function(e){function t(e){var n;return u()(this,t),n=h()(this,d()(t).call(this,e)),w()(g()(g()(n)),"onWindowResize",function(){n.setState({flexData:n.computeFlexData()})}),w()(g()(g()(n)),"onStartResize",function(e){var t=e.event.changedTouches?e.event.changedTouches[0]:e.event;switch(n.props.orientation){case"horizontal":document.body.classList.add("row-resize"),n.previousPos=t.pageY;break;case"vertical":default:document.body.classList.add("col-resize"),n.previousPos=t.pageX}n.elements=[n.children[e.index-1],n.children[e.index+1]],n.emitElementsEvent(n.elements,"onStartResize")}),w()(g()(g()(n)),"onResize",function(e){var t=n.getOffset(e.event),r=n.computeAvailableOffset(e.index,t);if(r){var i=e.event.changedTouches?e.event.changedTouches[0]:e.event;switch(n.props.orientation){case"horizontal":n.previousPos=i.pageY;break;case"vertical":default:n.previousPos=i.pageX}n.elements=n.dispatchOffset(e.index,r),n.adjustFlex(n.elements),n.setState({resizing:!0},function(){n.emitElementsEvent(n.elements,"onResize")})}}),w()(g()(g()(n)),"onStopResize",function(e){document.body.classList.remove("row-resize"),document.body.classList.remove("col-resize");var t=n.elements.map(function(e){return e.ref}),r=n.children.filter(function(e){return!S.isA(e)&&t.includes(e.ref)});n.emitElementsEvent(r,"onStopResize"),n.setState({resizing:!1})}),w()(g()(g()(n)),"onElementSize",function(e){return new Promise(function(t){try{var r=e.index,i=n.getSize(n.children[r]),o=e.size-i,s=e.direction,a=r+s,u=n.computeAvailableOffset(a,s*o);n.elements=null,u&&(n.elements=n.dispatchOffset(a,u),n.adjustFlex(n.elements)),n.setState(n.state,function(){n.emitElementsEvent(n.elements,"onResize"),t()})}catch(e){console.log(e)}})}),n.state={flexData:[]},n.events=new k,n.children=[],n}return m()(t,e),f()(t,[{key:"componentDidMount",value:function(){var e=this.computeFlexData(),t=this.props.windowResizeAware;t&&window.addEventListener("resize",this.onWindowResize),this.setState({windowResizeAware:t,flexData:e}),this.events.on("element.size",this.onElementSize),this.events.on("startResize",this.onStartResize),this.events.on("stopResize",this.onStopResize),this.events.on("resize",this.onResize)}},{key:"componentWillUnmount",value:function(){this.events.off(),this.state.windowResizeAware&&window.removeEventListener("resize",this.onWindowResize)}},{key:"getValidChildren",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.props;return this.toArray(e.children).filter(function(e){return!!e})}},{key:"componentWillReceiveProps",value:function(e){var t=this.getValidChildren(e);if(t.length!==this.state.flexData.length||this.flexHasChanged(e)){var n=this.computeFlexData(t);this.setState({flexData:n})}e.windowResizeAware!==this.state.windowResizeAware&&(e.windowResizeAware?window.addEventListener("resize",this.onWindowResize):window.removeEventListener("resize",this.onWindowResize),this.setState({windowResizeAware:e.windowResizeAware}))}},{key:"flexHasChanged",value:function(e){var t=this.getValidChildren(e).map(function(e){return e.props.flex||0});return!this.getValidChildren().map(function(e){return e.props.flex||0}).every(function(e,n){return e===t[n]})}},{key:"getSize",value:function(e){var t=e.ref?this.refs[e.ref]:e,n=z.a.findDOMNode(t);switch(this.props.orientation){case"horizontal":return n.offsetHeight;case"vertical":default:return n.offsetWidth}}},{key:"getOffset",value:function(e){var t=e.changedTouches?e.changedTouches[0]:e;switch(this.props.orientation){case"horizontal":return t.pageY-this.previousPos;case"vertical":default:return t.pageX-this.previousPos}}},{key:"adjustFlex",value:function(e){var t=this,n=e.reduce(function(n,r){var i=r.props.index;return n+(r.props.flex-t.state.flexData[i].flex)/e.length},0);e.forEach(function(e){t.state.flexData[e.props.index].flex+=n})}},{key:"computeAvailableOffset",value:function(e,t){var n=this.computeAvailableStretch(e,t),r=this.computeAvailableShrink(e,t);return Math.min(n,r)*Math.sign(t)}},{key:"checkPropagate",value:function(e,t){if(t>0){if(e<this.children.length-2){var n=this.children[e+2];return S.isA(n)&&n.props.propagate}}else if(e>2){var r=this.children[e-2];return S.isA(r)&&r.props.propagate}return!1}},{key:"computeAvailableStretch",value:function(e,t){var n=t<0?e+1:e-1,r=this.children[n],i=this.getSize(r),o=r.props.maxSize-i;if(o<Math.abs(t)&&this.checkPropagate(e,-1*t)){var s=Math.sign(t)*(Math.abs(t)-o);return o+this.computeAvailableStretch(t<0?e+2:e-2,s)}return Math.min(o,Math.abs(t))}},{key:"computeAvailableShrink",value:function(e,t){var n=t>0?e+1:e-1,r=this.children[n],i=this.getSize(r)-Math.max(r.props.minSize,0);if(i<Math.abs(t)&&this.checkPropagate(e,t)){var o=Math.sign(t)*(Math.abs(t)-i);return i+this.computeAvailableShrink(t>0?e+2:e-2,o)}return Math.min(i,Math.abs(t))}},{key:"computePixelFlex",value:function(){var e=z.a.findDOMNode(this);switch(this.props.orientation){case"horizontal":return 0===e.offsetHeight?(console.warn("Found ReflexContainer with height=0, this will cause invalid behavior..."),console.warn(e),0):1/e.offsetHeight;case"vertical":default:return 0===e.offsetWidth?(console.warn("Found ReflexContainer with width=0, this will cause invalid behavior..."),console.warn(e),0):1/e.offsetWidth}}},{key:"addOffset",value:function(e,t){var n=this.getSize(e),r=e.props.index,i=Math.max(n+t,0),o=this.state.flexData[r].flex,s=o>0?o*i/n:this.computePixelFlex()*i;this.state.flexData[r].flex=!isFinite(s)||isNaN(s)?0:s}},{key:"dispatchStretch",value:function(e,t){var n=t<0?e+1:e-1;if(n<0||n>this.children.length-1)return[];var r=this.children[n],i=this.getSize(r),o=Math.min(r.props.maxSize,i+Math.abs(t))-i;if(this.addOffset(r,o),o<Math.abs(t)){var a=e-2*Math.sign(t),u=Math.sign(t)*(Math.abs(t)-o);return[r].concat(s()(this.dispatchStretch(a,u)))}return[r]}},{key:"dispatchShrink",value:function(e,t){var n=t>0?e+1:e-1;if(n<0||n>this.children.length-1)return[];var r=this.children[n],i=this.getSize(r),o=Math.max(r.props.minSize,i-Math.abs(t))-i;if(this.addOffset(r,o),Math.abs(o)<Math.abs(t)){var a=e+2*Math.sign(t),u=Math.sign(t)*(Math.abs(t)+o);return[r].concat(s()(this.dispatchShrink(a,u)))}return[r]}},{key:"dispatchOffset",value:function(e,t){return s()(this.dispatchStretch(e,t)).concat(s()(this.dispatchShrink(e,t)))}},{key:"emitElementsEvent",value:function(e,t){var n=this;this.toArray(e).forEach(function(e){if(e.props[t]){var r=n.refs[e.ref],i=z.a.findDOMNode(r);e.props[t]({domElement:i,component:e})}})}},{key:"computeFlexData",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.getValidChildren(),n=this.computePixelFlex();return function t(n){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,o=!1,s=function(e){return e.reduce(function(e,t){return S.isA(t)||t.constrained?e:e+1},0)}(n),a=function(e){return e.reduce(function(e,t){return!S.isA(t)&&t.constrained?e-t.flex:e},1)}(n),u=n.map(function(e,t){if(S.isA(e))return e;var n=e.constrained?e.flex:a/s,r=Math.min(e.sizeFlex,Math.min(e.maxFlex,Math.max(e.minFlex,n))),u=r!==n;return o=o||u,i()({},e,{flex:r,constrained:u})});return o&&r<e.props.maxRecDepth?t(u,r+1):u}(t.map(function(t){var r=t.props;return{maxFlex:(r.maxSize||Number.MAX_VALUE)*n,sizeFlex:(r.size||Number.MAX_VALUE)*n,minFlex:(r.minSize||1)*n,constrained:void 0!==r.flex,guid:r.ref||e.guid(),flex:r.flex||0,type:t.type}})).map(function(e){return{flex:S.isA(e)?0:e.flex,guid:e.guid}})}},{key:"guid",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"xxxx-xxxx",t=(new Date).getTime();return e.replace(/[xy]/g,function(e){var n=(t+16*Math.random())%16|0;return t=Math.floor(t/16),("x"==e?n:7&n|8).toString(16)})}},{key:"toArray",value:function(e){return e?Array.isArray(e)?e:[e]:[]}},{key:"render",value:function(){var e=this,t=[this.state.resizing?"reflex-resizing":""].concat(s()(this.props.className.split(" ")),[this.props.orientation,"reflex-container"]).join(" ");return this.children=R.a.Children.map(this.getValidChildren(),function(t,n){if(n>e.state.flexData.length-1)return R.a.createElement("div",null);var r=e.state.flexData[n],o=i()({},t.props,{maxSize:t.props.maxSize||Number.MAX_VALUE,orientation:e.props.orientation,minSize:t.props.minSize||1,events:e.events,flex:r.flex,ref:r.guid,index:n});return R.a.cloneElement(t,o)}),R.a.createElement("div",{className:t,style:this.props.style},this.children)}}]),t}(R.a.Component));w()(A,"propTypes",{windowResizeAware:_.a.bool,orientation:_.a.oneOf(["horizontal","vertical"]),maxRecDepth:_.a.number,className:_.a.string,style:_.a.object}),w()(A,"defaultProps",{orientation:"horizontal",windowResizeAware:!1,maxRecDepth:100,className:"",style:{}});var j=n(12),P=n.n(j),L=n(15),D=n.n(L),T=function(e){function t(e){var n;return u()(this,t),n=h()(this,d()(t).call(this,e)),w()(g()(g()(n)),"onMouseMove",function(e){n.state.active&&(n.props.events.emit("resize",{index:n.props.index,event:e}),n.props.onResize&&n.props.onResize({domElement:z.a.findDOMNode(g()(g()(n))),component:g()(g()(n))}),e.stopPropagation(),e.preventDefault())}),w()(g()(g()(n)),"onMouseDown",function(e){n.setState({active:!0}),n.props.onStartResize&&n.props.onStartResize({domElement:z.a.findDOMNode(g()(g()(n))),component:g()(g()(n))})||n.props.events.emit("startResize",{index:n.props.index,event:e})}),w()(g()(g()(n)),"onMouseUp",function(e){n.state.active&&(n.setState({active:!1}),n.props.onStopResize&&n.props.onStopResize({domElement:z.a.findDOMNode(g()(g()(n))),component:g()(g()(n))}),n.props.events.emit("stopResize",{index:n.props.index,event:e}))}),n.state={active:!1},n.document=e.document,n}return m()(t,e),f()(t,null,[{key:"isA",value:function(e){return!!e&&e.type===t}}]),f()(t,[{key:"componentDidMount",value:function(){this.document&&(this.document.addEventListener("touchend",this.onMouseUp),this.document.addEventListener("mouseup",this.onMouseUp),this.document.addEventListener("mousemove",this.onMouseMove,{passive:!1}),this.document.addEventListener("touchmove",this.onMouseMove,{passive:!1}))}},{key:"componentWillUnmount",value:function(){this.document&&(this.document.removeEventListener("mouseup",this.onMouseUp),this.document.removeEventListener("touchend",this.onMouseUp),this.document.removeEventListener("mousemove",this.onMouseMove),this.document.removeEventListener("touchmove",this.onMouseMove),this.state.active&&this.props.events.emit("stopResize",{index:this.props.index,event:null}))}},{key:"render",value:function(){var e=s()(this.props.className.split(" ")).concat([this.state.active?"active":"","reflex-handle"]).join(" ");return R.a.createElement("div",{onTouchStart:this.onMouseDown,onMouseDown:this.onMouseDown,style:this.props.style,className:e,id:this.props.id},this.props.children)}}]),t}(R.a.Component);w()(T,"propTypes",{children:_.a.oneOfType([_.a.arrayOf(_.a.node),_.a.node]),onStartResize:_.a.func,onStopResize:_.a.func,className:_.a.string,propagate:_.a.bool,onResize:_.a.func,style:_.a.object}),w()(T,"defaultProps",{document:"undefined"==typeof document?null:document,onStartResize:null,onStopResize:null,propagate:!1,onResize:null,className:"",style:{}});var N=n(16),C=n.n(N),W=n(17),F=n.n(W),B=function(e){function t(e){var n;return u()(this,t),n=h()(this,d()(t).call(this,e)),w()(g()(g()(n)),"onResize",function(e){var t=n.props,r=t.resizeHeight,o=t.resizeWidth,s=Math.floor(e.bounds.height),a=Math.floor(e.bounds.width);n.setDimensions(i()({},r&&{height:s},o&&{width:a}))}),n.setDimensions=C()(function(e){n.setState(e)},n.props.propagateDimensionsRate/1e3),n.state={height:"100%",width:"100%"},n}return m()(t,e),f()(t,[{key:"renderChildren",value:function(){var e=this,t=this.props.propagateDimensions;return R.a.Children.map(this.props.children,function(n){return e.props.withHandle||T.isA(n)?R.a.cloneElement(n,i()({dimensions:t&&e.state},n.props,{index:e.props.index-1,events:e.props.events})):t?R.a.cloneElement(n,i()({},n.props,{dimensions:e.state})):n})}},{key:"render",value:function(){var e=this;return R.a.createElement(F.a,{bounds:!0,onResize:this.onResize},function(t){var n=t.measureRef;return R.a.createElement("div",{ref:n,className:"reflex-size-aware"},R.a.createElement("div",{style:e.state},e.renderChildren()))})}}]),t}(R.a.Component),U=function(e){function t(e){var n;return u()(this,t),(n=h()(this,d()(t).call(this,e))).state={events:e.events,size:e.size},n}return m()(t,e),f()(t,[{key:"setStateAsync",value:function(e){var t=this;return new Promise(function(n){t.setState(e,function(){return n()})})}},{key:"componentWillReceiveProps",value:function(){var e=D()(P.a.mark(function e(t){var n,r,i,o,s,a,u;return P.a.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(t.size===this.state.size){e.next=30;break}return e.next=3,this.setStateAsync({size:t.size});case 3:n=this.toArray(t.direction),r=!0,i=!1,o=void 0,e.prev=7,s=n[Symbol.iterator]();case 9:if(r=(a=s.next()).done){e.next=16;break}return u=a.value,e.next=13,this.state.events.emit("element.size",{index:t.index,size:t.size,direction:u});case 13:r=!0,e.next=9;break;case 16:e.next=22;break;case 18:e.prev=18,e.t0=e.catch(7),i=!0,o=e.t0;case 22:e.prev=22,e.prev=23,r||null==s.return||s.return();case 25:if(e.prev=25,!i){e.next=28;break}throw o;case 28:return e.finish(25);case 29:return e.finish(22);case 30:case"end":return e.stop()}},e,this,[[7,18,22,30],[23,,25,29]])}));return function(t){return e.apply(this,arguments)}}()},{key:"toArray",value:function(e){return e?Array.isArray(e)?e:[e]:[]}},{key:"renderChildren",value:function(){var e=this;return R.a.Children.map(this.props.children,function(t){return e.props.withHandle||T.isA(t)?R.a.cloneElement(t,i()({},t.props,{index:e.props.index-1,events:e.state.events})):t})}},{key:"render",value:function(){var e=s()(this.props.className.split(" ")).concat([this.props.orientation,"reflex-element"]).join(" "),t=i()({},this.props.style,{flex:this.props.flex});return R.a.createElement("div",{className:e,style:t},this.props.propagateDimensions?R.a.createElement(B,this.props):this.renderChildren())}}]),t}(R.a.Component);w()(U,"propTypes",{renderOnResizeRate:_.a.number,propagateDimensions:_.a.bool,resizeHeight:_.a.bool,resizeWidth:_.a.bool,className:_.a.string,size:_.a.number}),w()(U,"defaultProps",{propagateDimensionsRate:100,propagateDimensions:!1,resizeHeight:!0,resizeWidth:!0,direction:[1],className:""}),n.d(t,"ReflexContainer",function(){return A}),n.d(t,"ReflexSplitter",function(){return S}),n.d(t,"ReflexElement",function(){return U}),n.d(t,"ReflexHandle",function(){return T})}])});
return e.isBrowser()&&!!document.documentMode}},{key:"isEdge",value:function(){return e.isBrowser()&&!e.isIE()&&!!window.StyleMedia}},{key:"isChrome",value:function(){return e.isBrowser()&&!!window.chrome&&!!window.chrome.webstore}},{key:"isBlink",value:function(){return e.isBrowser()&&(e.isChrome()||e.isOpera())&&!!window.CSS}},{key:"getUserAgent",value:function(){return"undefined"==typeof navigator?"":navigator.userAgent}},{key:"isAndroid",value:function(){return e.isBrowser()&&e.getUserAgent().match(/Android/i)}},{key:"isBlackBerry",value:function(){return e.isBrowser()&&e.getUserAgent().match(/BlackBerry/i)}},{key:"isIOS",value:function(){return e.isBrowser()&&e.getUserAgent().match(/iPhone|iPad|iPod/i)}},{key:"isOpera",value:function(){return e.isBrowser()&&e.getUserAgent().match(/Opera Mini/i)}},{key:"isWindows",value:function(){return e.isBrowser()&&e.isWindowsDesktop()||e.isWindowsMobile()}},{key:"isWindowsMobile",value:function(){return e.isBrowser()&&e.getUserAgent().match(/IEMobile/i)}},{key:"isWindowsDesktop",value:function(){return e.isBrowser()&&e.getUserAgent().match(/WPDesktop/i)}},{key:"isMobile",value:function(){return e.isBrowser()&&(e.isWindowsMobile()||e.isBlackBerry()||e.isAndroid()||e.isIOS())}}]),e}(),M=n(2),R=n.n(M),S=function(e){function t(e){var n;return u()(this,t),n=h()(this,d()(t).call(this,e)),w()(g()(g()(n)),"onMouseMove",function(e){n.state.active&&(n.props.events.emit("resize",{index:n.props.index,event:e}),n.props.onResize&&n.props.onResize({domElement:z.a.findDOMNode(g()(g()(n))),component:g()(g()(n))}),e.stopPropagation(),e.preventDefault())}),w()(g()(g()(n)),"onMouseDown",function(e){n.setState({active:!0}),n.props.onStartResize&&n.props.onStartResize({domElement:z.a.findDOMNode(g()(g()(n))),component:g()(g()(n))})||n.props.events.emit("startResize",{index:n.props.index,event:e})}),w()(g()(g()(n)),"onMouseUp",function(e){n.state.active&&(n.setState({active:!1}),n.props.onStopResize&&n.props.onStopResize({domElement:z.a.findDOMNode(g()(g()(n))),component:g()(g()(n))}),n.props.events.emit("stopResize",{index:n.props.index,event:e}))}),n.state={active:!1},n.document=e.document,n}return m()(t,e),f()(t,null,[{key:"isA",value:function(e){return!!e&&e.type===t}}]),f()(t,[{key:"componentDidMount",value:function(){this.document&&(this.document.addEventListener("touchend",this.onMouseUp),this.document.addEventListener("mouseup",this.onMouseUp),this.document.addEventListener("mousemove",this.onMouseMove,{passive:!1}),this.document.addEventListener("touchmove",this.onMouseMove,{passive:!1}))}},{key:"componentWillUnmount",value:function(){this.document&&(this.document.removeEventListener("mouseup",this.onMouseUp),this.document.removeEventListener("touchend",this.onMouseUp),this.document.removeEventListener("mousemove",this.onMouseMove),this.document.removeEventListener("touchmove",this.onMouseMove),this.state.active&&this.props.events.emit("stopResize",{index:this.props.index,event:null}))}},{key:"render",value:function(){var e=[E.isMobile()?"reflex-thin":""].concat(s()(this.props.className.split(" ")),[this.state.active?"active":"","reflex-splitter"]).join(" ");return R.a.createElement("div",{onTouchStart:this.onMouseDown,onMouseDown:this.onMouseDown,style:this.props.style,className:e,id:this.props.id},this.props.children)}}]),t}(R.a.Component);w()(S,"propTypes",{children:_.a.oneOfType([_.a.arrayOf(_.a.node),_.a.node]),onStartResize:_.a.func,onStopResize:_.a.func,className:_.a.string,propagate:_.a.bool,onResize:_.a.func,style:_.a.object}),w()(S,"defaultProps",{document:"undefined"!=typeof document?document:null,onStartResize:null,onStopResize:null,propagate:!1,onResize:null,className:"",style:{}});var k=function(){function e(){u()(this,e),this._events={}}return f()(e,[{key:"on",value:function(e,t){var n=this;return e.split(" ").forEach(function(e){n._events[e]=n._events[e]||[],n._events[e].push(t)}),this}},{key:"off",value:function(e,t){var n=this;if(void 0!=e)return e.split(" ").forEach(function(e){e in n._events!=!1&&(t?n._events[e].splice(n._events[e].indexOf(t),1):n._events[e]=[])}),this;this._events={}}},{key:"emit",value:function(e){if(void 0!==this._events[e])for(var t=this._events[e].slice(),n=0;n<t.length;++n){var r=t[n].apply(this,Array.prototype.slice.call(arguments,1));if(void 0!==r)return r}}}]),e}(),A=(n(26),function(e){function t(e){var n;return u()(this,t),n=h()(this,d()(t).call(this,e)),w()(g()(g()(n)),"onWindowResize",function(){n.setState({flexData:n.computeFlexData()})}),w()(g()(g()(n)),"onStartResize",function(e){var t=e.event.changedTouches?e.event.changedTouches[0]:e.event;switch(n.props.orientation){case"horizontal":document.body.classList.add("row-resize"),n.previousPos=t.pageY;break;case"vertical":default:document.body.classList.add("col-resize"),n.previousPos=t.pageX}n.elements=[n.children[e.index-1],n.children[e.index+1]],n.emitElementsEvent(n.elements,"onStartResize")}),w()(g()(g()(n)),"onResize",function(e){var t=n.getOffset(e.event),r=n.computeAvailableOffset(e.index,t);if(r){var i=e.event.changedTouches?e.event.changedTouches[0]:e.event;switch(n.props.orientation){case"horizontal":n.previousPos=i.pageY;break;case"vertical":default:n.previousPos=i.pageX}n.elements=n.dispatchOffset(e.index,r),n.adjustFlex(n.elements),n.setState({resizing:!0},function(){n.emitElementsEvent(n.elements,"onResize")})}}),w()(g()(g()(n)),"onStopResize",function(e){document.body.classList.remove("row-resize"),document.body.classList.remove("col-resize");var t=n.elements.map(function(e){return e.ref}),r=n.children.filter(function(e){return!S.isA(e)&&t.includes(e.ref)});n.emitElementsEvent(r,"onStopResize"),n.setState({resizing:!1})}),w()(g()(g()(n)),"onElementSize",function(e){return new Promise(function(t){try{var r=e.index,i=n.getSize(n.children[r]),o=e.size-i,s=e.direction,a=r+s,u=n.computeAvailableOffset(a,s*o);n.elements=null,u&&(n.elements=n.dispatchOffset(a,u),n.adjustFlex(n.elements)),n.setState(n.state,function(){n.emitElementsEvent(n.elements,"onResize"),t()})}catch(e){console.log(e)}})}),n.state={flexData:[]},n.events=new k,n.children=[],n}return m()(t,e),f()(t,[{key:"componentDidMount",value:function(){var e=this.computeFlexData(),t=this.props.windowResizeAware;t&&window.addEventListener("resize",this.onWindowResize),this.setState({windowResizeAware:t,flexData:e}),this.events.on("element.size",this.onElementSize),this.events.on("startResize",this.onStartResize),this.events.on("stopResize",this.onStopResize),this.events.on("resize",this.onResize)}},{key:"componentWillUnmount",value:function(){this.events.off(),this.state.windowResizeAware&&window.removeEventListener("resize",this.onWindowResize)}},{key:"getValidChildren",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.props;return this.toArray(e.children).filter(function(e){return!!e})}},{key:"componentWillReceiveProps",value:function(e){var t=this.getValidChildren(e);if(t.length!==this.state.flexData.length||e.orientation!==this.props.orientation||this.flexHasChanged(e)){var n=this.computeFlexData(t,e);this.setState({flexData:n})}e.windowResizeAware!==this.state.windowResizeAware&&(e.windowResizeAware?window.addEventListener("resize",this.onWindowResize):window.removeEventListener("resize",this.onWindowResize),this.setState({windowResizeAware:e.windowResizeAware}))}},{key:"flexHasChanged",value:function(e){var t=this.getValidChildren(e).map(function(e){return e.props.flex||0});return!this.getValidChildren().map(function(e){return e.props.flex||0}).every(function(e,n){return e===t[n]})}},{key:"getSize",value:function(e){var t=e.ref?this.refs[e.ref]:e,n=z.a.findDOMNode(t);switch(this.props.orientation){case"horizontal":return n.offsetHeight;case"vertical":default:return n.offsetWidth}}},{key:"getOffset",value:function(e){var t=e.changedTouches?e.changedTouches[0]:e;switch(this.props.orientation){case"horizontal":return t.pageY-this.previousPos;case"vertical":default:return t.pageX-this.previousPos}}},{key:"adjustFlex",value:function(e){var t=this,n=e.reduce(function(n,r){var i=r.props.index;return n+(r.props.flex-t.state.flexData[i].flex)/e.length},0);e.forEach(function(e){t.state.flexData[e.props.index].flex+=n})}},{key:"computeAvailableOffset",value:function(e,t){var n=this.computeAvailableStretch(e,t),r=this.computeAvailableShrink(e,t);return Math.min(n,r)*Math.sign(t)}},{key:"checkPropagate",value:function(e,t){if(t>0){if(e<this.children.length-2){var n=this.children[e+2];return S.isA(n)&&n.props.propagate}}else if(e>2){var r=this.children[e-2];return S.isA(r)&&r.props.propagate}return!1}},{key:"computeAvailableStretch",value:function(e,t){var n=t<0?e+1:e-1,r=this.children[n],i=this.getSize(r),o=r.props.maxSize-i;if(o<Math.abs(t)&&this.checkPropagate(e,-1*t)){var s=Math.sign(t)*(Math.abs(t)-o);return o+this.computeAvailableStretch(t<0?e+2:e-2,s)}return Math.min(o,Math.abs(t))}},{key:"computeAvailableShrink",value:function(e,t){var n=t>0?e+1:e-1,r=this.children[n],i=this.getSize(r)-Math.max(r.props.minSize,0);if(i<Math.abs(t)&&this.checkPropagate(e,t)){var o=Math.sign(t)*(Math.abs(t)-i);return i+this.computeAvailableShrink(t>0?e+2:e-2,o)}return Math.min(i,Math.abs(t))}},{key:"computePixelFlex",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.props.orientation,t=z.a.findDOMNode(this);switch(e){case"horizontal":return 0===t.offsetHeight?(console.warn("Found ReflexContainer with height=0, this will cause invalid behavior..."),console.warn(t),0):1/t.offsetHeight;case"vertical":default:return 0===t.offsetWidth?(console.warn("Found ReflexContainer with width=0, this will cause invalid behavior..."),console.warn(t),0):1/t.offsetWidth}}},{key:"addOffset",value:function(e,t){var n=this.getSize(e),r=e.props.index,i=Math.max(n+t,0),o=this.state.flexData[r].flex,s=o>0?o*i/n:this.computePixelFlex()*i;this.state.flexData[r].flex=!isFinite(s)||isNaN(s)?0:s}},{key:"dispatchStretch",value:function(e,t){var n=t<0?e+1:e-1;if(n<0||n>this.children.length-1)return[];var r=this.children[n],i=this.getSize(r),o=Math.min(r.props.maxSize,i+Math.abs(t))-i;if(this.addOffset(r,o),o<Math.abs(t)){var a=e-2*Math.sign(t),u=Math.sign(t)*(Math.abs(t)-o);return[r].concat(s()(this.dispatchStretch(a,u)))}return[r]}},{key:"dispatchShrink",value:function(e,t){var n=t>0?e+1:e-1;if(n<0||n>this.children.length-1)return[];var r=this.children[n],i=this.getSize(r),o=Math.max(r.props.minSize,i-Math.abs(t))-i;if(this.addOffset(r,o),Math.abs(o)<Math.abs(t)){var a=e+2*Math.sign(t),u=Math.sign(t)*(Math.abs(t)+o);return[r].concat(s()(this.dispatchShrink(a,u)))}return[r]}},{key:"dispatchOffset",value:function(e,t){return s()(this.dispatchStretch(e,t)).concat(s()(this.dispatchShrink(e,t)))}},{key:"emitElementsEvent",value:function(e,t){var n=this;this.toArray(e).forEach(function(e){if(e.props[t]){var r=n.refs[e.ref],i=z.a.findDOMNode(r);e.props[t]({domElement:i,component:e})}})}},{key:"computeFlexData",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.getValidChildren(),n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.props,r=this.computePixelFlex(n.orientation);return function t(n){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,o=!1,s=function(e){return e.reduce(function(e,t){return S.isA(t)||t.constrained?e:e+1},0)}(n),a=function(e){return e.reduce(function(e,t){return!S.isA(t)&&t.constrained?e-t.flex:e},1)}(n),u=n.map(function(e,t){if(S.isA(e))return e;var n=e.constrained?e.flex:a/s,r=Math.min(e.sizeFlex,Math.min(e.maxFlex,Math.max(e.minFlex,n))),u=r!==n;return o=o||u,i()({},e,{flex:r,constrained:u})});return o&&r<e.props.maxRecDepth?t(u,r+1):u}(t.map(function(t){var n=t.props;return{maxFlex:(n.maxSize||Number.MAX_VALUE)*r,sizeFlex:(n.size||Number.MAX_VALUE)*r,minFlex:(n.minSize||1)*r,constrained:void 0!==n.flex,guid:n.ref||e.guid(),flex:n.flex||0,type:t.type}})).map(function(e){return{flex:S.isA(e)?0:e.flex,guid:e.guid}})}},{key:"guid",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"xxxx-xxxx",t=(new Date).getTime();return e.replace(/[xy]/g,function(e){var n=(t+16*Math.random())%16|0;return t=Math.floor(t/16),("x"==e?n:7&n|8).toString(16)})}},{key:"toArray",value:function(e){return e?Array.isArray(e)?e:[e]:[]}},{key:"render",value:function(){var e=this,t=[this.state.resizing?"reflex-resizing":""].concat(s()(this.props.className.split(" ")),[this.props.orientation,"reflex-container"]).join(" ");return this.children=R.a.Children.map(this.getValidChildren(),function(t,n){if(n>e.state.flexData.length-1)return R.a.createElement("div",null);var r=e.state.flexData[n],o=i()({},t.props,{maxSize:t.props.maxSize||Number.MAX_VALUE,orientation:e.props.orientation,minSize:t.props.minSize||1,events:e.events,flex:r.flex,ref:r.guid,index:n});return R.a.cloneElement(t,o)}),R.a.createElement("div",{className:t,style:this.props.style},this.children)}}]),t}(R.a.Component));w()(A,"propTypes",{windowResizeAware:_.a.bool,orientation:_.a.oneOf(["horizontal","vertical"]),maxRecDepth:_.a.number,className:_.a.string,style:_.a.object}),w()(A,"defaultProps",{orientation:"horizontal",windowResizeAware:!1,maxRecDepth:100,className:"",style:{}});var j=n(12),P=n.n(j),L=n(15),D=n.n(L),T=function(e){function t(e){var n;return u()(this,t),n=h()(this,d()(t).call(this,e)),w()(g()(g()(n)),"onMouseMove",function(e){n.state.active&&(n.props.events.emit("resize",{index:n.props.index,event:e}),n.props.onResize&&n.props.onResize({domElement:z.a.findDOMNode(g()(g()(n))),component:g()(g()(n))}),e.stopPropagation(),e.preventDefault())}),w()(g()(g()(n)),"onMouseDown",function(e){n.setState({active:!0}),n.props.onStartResize&&n.props.onStartResize({domElement:z.a.findDOMNode(g()(g()(n))),component:g()(g()(n))})||n.props.events.emit("startResize",{index:n.props.index,event:e})}),w()(g()(g()(n)),"onMouseUp",function(e){n.state.active&&(n.setState({active:!1}),n.props.onStopResize&&n.props.onStopResize({domElement:z.a.findDOMNode(g()(g()(n))),component:g()(g()(n))}),n.props.events.emit("stopResize",{index:n.props.index,event:e}))}),n.state={active:!1},n.document=e.document,n}return m()(t,e),f()(t,null,[{key:"isA",value:function(e){return!!e&&e.type===t}}]),f()(t,[{key:"componentDidMount",value:function(){this.document&&(this.document.addEventListener("touchend",this.onMouseUp),this.document.addEventListener("mouseup",this.onMouseUp),this.document.addEventListener("mousemove",this.onMouseMove,{passive:!1}),this.document.addEventListener("touchmove",this.onMouseMove,{passive:!1}))}},{key:"componentWillUnmount",value:function(){this.document&&(this.document.removeEventListener("mouseup",this.onMouseUp),this.document.removeEventListener("touchend",this.onMouseUp),this.document.removeEventListener("mousemove",this.onMouseMove),this.document.removeEventListener("touchmove",this.onMouseMove),this.state.active&&this.props.events.emit("stopResize",{index:this.props.index,event:null}))}},{key:"render",value:function(){var e=s()(this.props.className.split(" ")).concat([this.state.active?"active":"","reflex-handle"]).join(" ");return R.a.createElement("div",{onTouchStart:this.onMouseDown,onMouseDown:this.onMouseDown,style:this.props.style,className:e,id:this.props.id},this.props.children)}}]),t}(R.a.Component);w()(T,"propTypes",{children:_.a.oneOfType([_.a.arrayOf(_.a.node),_.a.node]),onStartResize:_.a.func,onStopResize:_.a.func,className:_.a.string,propagate:_.a.bool,onResize:_.a.func,style:_.a.object}),w()(T,"defaultProps",{document:"undefined"==typeof document?null:document,onStartResize:null,onStopResize:null,propagate:!1,onResize:null,className:"",style:{}});var N=n(16),C=n.n(N),W=n(17),F=n.n(W),B=function(e){function t(e){var n;return u()(this,t),n=h()(this,d()(t).call(this,e)),w()(g()(g()(n)),"onResize",function(e){var t=n.props,r=t.resizeHeight,o=t.resizeWidth,s=Math.floor(e.bounds.height),a=Math.floor(e.bounds.width);n.setDimensions(i()({},r&&{height:s},o&&{width:a}))}),n.setDimensions=C()(function(e){n.setState(e)},n.props.propagateDimensionsRate/1e3),n.state={height:"100%",width:"100%"},n}return m()(t,e),f()(t,[{key:"renderChildren",value:function(){var e=this,t=this.props.propagateDimensions;return R.a.Children.map(this.props.children,function(n){return e.props.withHandle||T.isA(n)?R.a.cloneElement(n,i()({dimensions:t&&e.state},n.props,{index:e.props.index-1,events:e.props.events})):t?R.a.cloneElement(n,i()({},n.props,{dimensions:e.state})):n})}},{key:"render",value:function(){var e=this;return R.a.createElement(F.a,{bounds:!0,onResize:this.onResize},function(t){var n=t.measureRef;return R.a.createElement("div",{ref:n,className:"reflex-size-aware"},R.a.createElement("div",{style:e.state},e.renderChildren()))})}}]),t}(R.a.Component),U=function(e){function t(e){var n;return u()(this,t),(n=h()(this,d()(t).call(this,e))).state={events:e.events,size:e.size},n}return m()(t,e),f()(t,[{key:"setStateAsync",value:function(e){var t=this;return new Promise(function(n){t.setState(e,function(){return n()})})}},{key:"componentWillReceiveProps",value:function(){var e=D()(P.a.mark(function e(t){var n,r,i,o,s,a,u;return P.a.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(t.size===this.state.size){e.next=30;break}return e.next=3,this.setStateAsync({size:t.size});case 3:n=this.toArray(t.direction),r=!0,i=!1,o=void 0,e.prev=7,s=n[Symbol.iterator]();case 9:if(r=(a=s.next()).done){e.next=16;break}return u=a.value,e.next=13,this.state.events.emit("element.size",{index:t.index,size:t.size,direction:u});case 13:r=!0,e.next=9;break;case 16:e.next=22;break;case 18:e.prev=18,e.t0=e.catch(7),i=!0,o=e.t0;case 22:e.prev=22,e.prev=23,r||null==s.return||s.return();case 25:if(e.prev=25,!i){e.next=28;break}throw o;case 28:return e.finish(25);case 29:return e.finish(22);case 30:case"end":return e.stop()}},e,this,[[7,18,22,30],[23,,25,29]])}));return function(t){return e.apply(this,arguments)}}()},{key:"toArray",value:function(e){return e?Array.isArray(e)?e:[e]:[]}},{key:"renderChildren",value:function(){var e=this;return R.a.Children.map(this.props.children,function(t){return e.props.withHandle||T.isA(t)?R.a.cloneElement(t,i()({},t.props,{index:e.props.index-1,events:e.state.events})):t})}},{key:"render",value:function(){var e=s()(this.props.className.split(" ")).concat([this.props.orientation,"reflex-element"]).join(" "),t=i()({},this.props.style,{flex:this.props.flex});return R.a.createElement("div",{className:e,style:t},this.props.propagateDimensions?R.a.createElement(B,this.props):this.renderChildren())}}]),t}(R.a.Component);w()(U,"propTypes",{renderOnResizeRate:_.a.number,propagateDimensions:_.a.bool,resizeHeight:_.a.bool,resizeWidth:_.a.bool,className:_.a.string,size:_.a.number}),w()(U,"defaultProps",{propagateDimensionsRate:100,propagateDimensions:!1,resizeHeight:!0,resizeWidth:!0,direction:[1],className:""}),n.d(t,"ReflexContainer",function(){return A}),n.d(t,"ReflexSplitter",function(){return S}),n.d(t,"ReflexElement",function(){return U}),n.d(t,"ReflexHandle",function(){return T})}])});
{
"name": "react-reflex",
"version": "3.0.9",
"version": "3.0.10",
"description": "Flex layout component for advanced React web applications",

@@ -5,0 +5,0 @@ "main": "dist/commonjs/index.js",

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

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

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc