HEX
Server: nginx/1.24.0
System: Linux nowruzgan 6.8.0-57-generic #59-Ubuntu SMP PREEMPT_DYNAMIC Sat Mar 15 17:40:59 UTC 2025 x86_64
User: babak (1000)
PHP: 8.3.6
Disabled: NONE
Upload Files
File: //usr/share/opensearch-dashboards/node_modules/react-window/dist/index-dev.umd.js
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("react")):"function"==typeof define&&define.amd?define(["exports","react"],t):t((e=e||self).ReactWindow={},e.React)}(this,(function(e,t){"use strict";function r(){return(r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(e[o]=r[o])}return e}).apply(this,arguments)}function o(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function n(e,t){return(n=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function i(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,n(e,t)}var a=Number.isNaN||function(e){return"number"==typeof e&&e!=e};function l(e,t){if(e.length!==t.length)return!1;for(var r=0;r<e.length;r++)if(o=e[r],n=t[r],!(o===n||a(o)&&a(n)))return!1;var o,n;return!0}function s(e,t){var r;void 0===t&&(t=l);var o,n=[],i=!1;return function(){for(var a=[],l=0;l<arguments.length;l++)a[l]=arguments[l];return i&&r===this&&t(a,n)||(o=e.apply(this,a),i=!0,r=this,n=a),o}}var c="object"==typeof performance&&"function"==typeof performance.now?function(){return performance.now()}:function(){return Date.now()};function u(e){cancelAnimationFrame(e.id)}function d(e,t){var r=c();var o={id:requestAnimationFrame((function n(){c()-r>=t?e.call(null):o.id=requestAnimationFrame(n)}))};return o}var f=-1;function h(e){if(void 0===e&&(e=!1),-1===f||e){var t=document.createElement("div"),r=t.style;r.width="50px",r.height="50px",r.overflow="scroll",document.body.appendChild(t),f=t.offsetWidth-t.clientWidth,document.body.removeChild(t)}return f}var p=null;function m(e){if(void 0===e&&(e=!1),null===p||e){var t=document.createElement("div"),r=t.style;r.width="50px",r.height="50px",r.overflow="scroll",r.direction="rtl";var o=document.createElement("div"),n=o.style;return n.width="100px",n.height="100px",t.appendChild(o),document.body.appendChild(t),t.scrollLeft>0?p="positive-descending":(t.scrollLeft=1,p=0===t.scrollLeft?"negative":"positive-ascending"),document.body.removeChild(t),p}return p}var v=function(e){var t=e.columnIndex;e.data;return e.rowIndex+":"+t},g=null,w=null,S=null;function I(e){var n,a=e.getColumnOffset,l=e.getColumnStartIndexForOffset,c=e.getColumnStopIndexForStartIndex,f=e.getColumnWidth,p=e.getEstimatedTotalHeight,g=e.getEstimatedTotalWidth,w=e.getOffsetForColumnAndAlignment,S=e.getOffsetForRowAndAlignment,I=e.getRowHeight,y=e.getRowOffset,x=e.getRowStartIndexForOffset,C=e.getRowStopIndexForStartIndex,_=e.initInstanceProps,b=e.shouldResetStyleCacheOnItemSizeChange,R=e.validateProps;return(n=function(e){function n(t){var r;return(r=e.call(this,t)||this)._instanceProps=_(r.props,o(r)),r._resetIsScrollingTimeoutId=null,r._outerRef=void 0,r.state={instance:o(r),isScrolling:!1,horizontalScrollDirection:"forward",scrollLeft:"number"==typeof r.props.initialScrollLeft?r.props.initialScrollLeft:0,scrollTop:"number"==typeof r.props.initialScrollTop?r.props.initialScrollTop:0,scrollUpdateWasRequested:!1,verticalScrollDirection:"forward"},r._callOnItemsRendered=void 0,r._callOnItemsRendered=s((function(e,t,o,n,i,a,l,s){return r.props.onItemsRendered({overscanColumnStartIndex:e,overscanColumnStopIndex:t,overscanRowStartIndex:o,overscanRowStopIndex:n,visibleColumnStartIndex:i,visibleColumnStopIndex:a,visibleRowStartIndex:l,visibleRowStopIndex:s})})),r._callOnScroll=void 0,r._callOnScroll=s((function(e,t,o,n,i){return r.props.onScroll({horizontalScrollDirection:o,scrollLeft:e,scrollTop:t,verticalScrollDirection:n,scrollUpdateWasRequested:i})})),r._getItemStyle=void 0,r._getItemStyle=function(e,t){var o,n=r.props,i=n.columnWidth,l=n.direction,s=n.rowHeight,c=r._getItemStyleCache(b&&i,b&&l,b&&s),u=e+":"+t;if(c.hasOwnProperty(u))o=c[u];else{var d=a(r.props,t,r._instanceProps),h="rtl"===l;c[u]=o={position:"absolute",left:h?void 0:d,right:h?d:void 0,top:y(r.props,e,r._instanceProps),height:I(r.props,e,r._instanceProps),width:f(r.props,t,r._instanceProps)}}return o},r._getItemStyleCache=void 0,r._getItemStyleCache=s((function(e,t,r){return{}})),r._onScroll=function(e){var t=e.currentTarget,o=t.clientHeight,n=t.clientWidth,i=t.scrollLeft,a=t.scrollTop,l=t.scrollHeight,s=t.scrollWidth;r.setState((function(e){if(e.scrollLeft===i&&e.scrollTop===a)return null;var t=r.props.direction,c=i;if("rtl"===t)switch(m()){case"negative":c=-i;break;case"positive-descending":c=s-n-i}c=Math.max(0,Math.min(c,s-n));var u=Math.max(0,Math.min(a,l-o));return{isScrolling:!0,horizontalScrollDirection:e.scrollLeft<i?"forward":"backward",scrollLeft:c,scrollTop:u,verticalScrollDirection:e.scrollTop<a?"forward":"backward",scrollUpdateWasRequested:!1}}),r._resetIsScrollingDebounced)},r._outerRefSetter=function(e){var t=r.props.outerRef;r._outerRef=e,"function"==typeof t?t(e):null!=t&&"object"==typeof t&&t.hasOwnProperty("current")&&(t.current=e)},r._resetIsScrollingDebounced=function(){null!==r._resetIsScrollingTimeoutId&&u(r._resetIsScrollingTimeoutId),r._resetIsScrollingTimeoutId=d(r._resetIsScrolling,150)},r._resetIsScrolling=function(){r._resetIsScrollingTimeoutId=null,r.setState({isScrolling:!1},(function(){r._getItemStyleCache(-1)}))},r}i(n,e),n.getDerivedStateFromProps=function(e,t){return M(e,t),R(e),null};var T=n.prototype;return T.scrollTo=function(e){var t=e.scrollLeft,r=e.scrollTop;void 0!==t&&(t=Math.max(0,t)),void 0!==r&&(r=Math.max(0,r)),this.setState((function(e){return void 0===t&&(t=e.scrollLeft),void 0===r&&(r=e.scrollTop),e.scrollLeft===t&&e.scrollTop===r?null:{horizontalScrollDirection:e.scrollLeft<t?"forward":"backward",scrollLeft:t,scrollTop:r,scrollUpdateWasRequested:!0,verticalScrollDirection:e.scrollTop<r?"forward":"backward"}}),this._resetIsScrollingDebounced)},T.scrollToItem=function(e){var t=e.align,r=void 0===t?"auto":t,o=e.columnIndex,n=e.rowIndex,i=this.props,a=i.columnCount,l=i.height,s=i.rowCount,c=i.width,u=this.state,d=u.scrollLeft,f=u.scrollTop,m=h();void 0!==o&&(o=Math.max(0,Math.min(o,a-1))),void 0!==n&&(n=Math.max(0,Math.min(n,s-1)));var v=p(this.props,this._instanceProps),I=g(this.props,this._instanceProps)>c?m:0,M=v>l?m:0;this.scrollTo({scrollLeft:void 0!==o?w(this.props,o,r,d,this._instanceProps,M):d,scrollTop:void 0!==n?S(this.props,n,r,f,this._instanceProps,I):f})},T.componentDidMount=function(){var e=this.props,t=e.initialScrollLeft,r=e.initialScrollTop;if(null!=this._outerRef){var o=this._outerRef;"number"==typeof t&&(o.scrollLeft=t),"number"==typeof r&&(o.scrollTop=r)}this._callPropsCallbacks()},T.componentDidUpdate=function(){var e=this.props.direction,t=this.state,r=t.scrollLeft,o=t.scrollTop;if(t.scrollUpdateWasRequested&&null!=this._outerRef){var n=this._outerRef;if("rtl"===e)switch(m()){case"negative":n.scrollLeft=-r;break;case"positive-ascending":n.scrollLeft=r;break;default:var i=n.clientWidth,a=n.scrollWidth;n.scrollLeft=a-i-r}else n.scrollLeft=Math.max(0,r);n.scrollTop=Math.max(0,o)}this._callPropsCallbacks()},T.componentWillUnmount=function(){null!==this._resetIsScrollingTimeoutId&&u(this._resetIsScrollingTimeoutId)},T.render=function(){var e=this.props,o=e.children,n=e.className,i=e.columnCount,a=e.direction,l=e.height,s=e.innerRef,c=e.innerElementType,u=e.innerTagName,d=e.itemData,f=e.itemKey,h=void 0===f?v:f,m=e.outerElementType,w=e.outerTagName,S=e.rowCount,I=e.style,M=e.useIsScrolling,y=e.width,x=this.state.isScrolling,C=this._getHorizontalRangeToRender(),_=C[0],b=C[1],R=this._getVerticalRangeToRender(),T=R[0],z=R[1],O=[];if(i>0&&S)for(var P=T;P<=z;P++)for(var W=_;W<=b;W++)O.push(t.createElement(o,{columnIndex:W,data:d,isScrolling:M?x:void 0,key:h({columnIndex:W,data:d,rowIndex:P}),rowIndex:P,style:this._getItemStyle(P,W)}));var E=p(this.props,this._instanceProps),A=g(this.props,this._instanceProps);return t.createElement(m||w||"div",{className:n,onScroll:this._onScroll,ref:this._outerRefSetter,style:r({position:"relative",height:l,width:y,overflow:"auto",WebkitOverflowScrolling:"touch",willChange:"transform",direction:a},I)},t.createElement(c||u||"div",{children:O,ref:s,style:{height:E,pointerEvents:x?"none":void 0,width:A}}))},T._callPropsCallbacks=function(){var e=this.props,t=e.columnCount,r=e.onItemsRendered,o=e.onScroll,n=e.rowCount;if("function"==typeof r&&t>0&&n>0){var i=this._getHorizontalRangeToRender(),a=i[0],l=i[1],s=i[2],c=i[3],u=this._getVerticalRangeToRender(),d=u[0],f=u[1],h=u[2],p=u[3];this._callOnItemsRendered(a,l,d,f,s,c,h,p)}if("function"==typeof o){var m=this.state,v=m.horizontalScrollDirection,g=m.scrollLeft,w=m.scrollTop,S=m.scrollUpdateWasRequested,I=m.verticalScrollDirection;this._callOnScroll(g,w,v,I,S)}},T._getHorizontalRangeToRender=function(){var e=this.props,t=e.columnCount,r=e.overscanColumnCount,o=e.overscanColumnsCount,n=e.overscanCount,i=e.rowCount,a=this.state,s=a.horizontalScrollDirection,u=a.isScrolling,d=a.scrollLeft,f=r||o||n||1;if(0===t||0===i)return[0,0,0,0];var h=l(this.props,d,this._instanceProps),p=c(this.props,h,d,this._instanceProps),m=u&&"backward"!==s?1:Math.max(1,f),v=u&&"forward"!==s?1:Math.max(1,f);return[Math.max(0,h-m),Math.max(0,Math.min(t-1,p+v)),h,p]},T._getVerticalRangeToRender=function(){var e=this.props,t=e.columnCount,r=e.overscanCount,o=e.overscanRowCount,n=e.overscanRowsCount,i=e.rowCount,a=this.state,l=a.isScrolling,s=a.verticalScrollDirection,c=a.scrollTop,u=o||n||r||1;if(0===t||0===i)return[0,0,0,0];var d=x(this.props,c,this._instanceProps),f=C(this.props,d,c,this._instanceProps),h=l&&"backward"!==s?1:Math.max(1,u),p=l&&"forward"!==s?1:Math.max(1,u);return[Math.max(0,d-h),Math.max(0,Math.min(i-1,f+p)),d,f]},n}(t.PureComponent)).defaultProps={direction:"ltr",itemData:void 0,useIsScrolling:!1},n}"undefined"!=typeof window&&void 0!==window.WeakSet&&(g=new WeakSet,w=new WeakSet,S=new WeakSet);var M=function(e,t){var r=e.children,o=e.direction,n=e.height,i=e.innerTagName,a=e.outerTagName,l=e.overscanColumnsCount,s=e.overscanCount,c=e.overscanRowsCount,u=e.width,d=t.instance;if("number"==typeof s&&g&&!g.has(d)&&(g.add(d),console.warn("The overscanCount prop has been deprecated. Please use the overscanColumnCount and overscanRowCount props instead.")),"number"!=typeof l&&"number"!=typeof c||w&&!w.has(d)&&(w.add(d),console.warn("The overscanColumnsCount and overscanRowsCount props have been deprecated. Please use the overscanColumnCount and overscanRowCount props instead.")),null==i&&null==a||S&&!S.has(d)&&(S.add(d),console.warn("The innerTagName and outerTagName props have been deprecated. Please use the innerElementType and outerElementType props instead.")),null==r)throw Error('An invalid "children" prop has been specified. Value should be a React component. "'+(null===r?"null":typeof r)+'" was specified.');switch(o){case"ltr":case"rtl":break;default:throw Error('An invalid "direction" prop has been specified. Value should be either "ltr" or "rtl". "'+o+'" was specified.')}if("number"!=typeof u)throw Error('An invalid "width" prop has been specified. Grids must specify a number for width. "'+(null===u?"null":typeof u)+'" was specified.');if("number"!=typeof n)throw Error('An invalid "height" prop has been specified. Grids must specify a number for height. "'+(null===n?"null":typeof n)+'" was specified.')},y=function(e,t){var r=e.rowCount,o=t.rowMetadataMap,n=t.estimatedRowHeight,i=t.lastMeasuredRowIndex,a=0;if(i>=r&&(i=r-1),i>=0){var l=o[i];a=l.offset+l.size}return a+(r-i-1)*n},x=function(e,t){var r=e.columnCount,o=t.columnMetadataMap,n=t.estimatedColumnWidth,i=t.lastMeasuredColumnIndex,a=0;if(i>=r&&(i=r-1),i>=0){var l=o[i];a=l.offset+l.size}return a+(r-i-1)*n},C=function(e,t,r,o){var n,i,a;if("column"===e?(n=o.columnMetadataMap,i=t.columnWidth,a=o.lastMeasuredColumnIndex):(n=o.rowMetadataMap,i=t.rowHeight,a=o.lastMeasuredRowIndex),r>a){var l=0;if(a>=0){var s=n[a];l=s.offset+s.size}for(var c=a+1;c<=r;c++){var u=i(c);n[c]={offset:l,size:u},l+=u}"column"===e?o.lastMeasuredColumnIndex=r:o.lastMeasuredRowIndex=r}return n[r]},_=function(e,t,r,o){var n,i;return"column"===e?(n=r.columnMetadataMap,i=r.lastMeasuredColumnIndex):(n=r.rowMetadataMap,i=r.lastMeasuredRowIndex),(i>0?n[i].offset:0)>=o?b(e,t,r,i,0,o):R(e,t,r,Math.max(0,i),o)},b=function(e,t,r,o,n,i){for(;n<=o;){var a=n+Math.floor((o-n)/2),l=C(e,t,a,r).offset;if(l===i)return a;l<i?n=a+1:l>i&&(o=a-1)}return n>0?n-1:0},R=function(e,t,r,o,n){for(var i="column"===e?t.columnCount:t.rowCount,a=1;o<i&&C(e,t,o,r).offset<n;)o+=a,a*=2;return b(e,t,r,Math.min(o,i-1),Math.floor(o/2),n)},T=function(e,t,r,o,n,i,a){var l="column"===e?t.width:t.height,s=C(e,t,r,i),c="column"===e?x(t,i):y(t,i),u=Math.max(0,Math.min(c-l,s.offset)),d=Math.max(0,s.offset-l+a+s.size);switch("smart"===o&&(o=n>=d-l&&n<=u+l?"auto":"center"),o){case"start":return u;case"end":return d;case"center":return Math.round(d+(u-d)/2);case"auto":default:return n>=d&&n<=u?n:d>u||n<d?d:u}},z=I({getColumnOffset:function(e,t,r){return C("column",e,t,r).offset},getColumnStartIndexForOffset:function(e,t,r){return _("column",e,r,t)},getColumnStopIndexForStartIndex:function(e,t,r,o){for(var n=e.columnCount,i=e.width,a=C("column",e,t,o),l=r+i,s=a.offset+a.size,c=t;c<n-1&&s<l;)c++,s+=C("column",e,c,o).size;return c},getColumnWidth:function(e,t,r){return r.columnMetadataMap[t].size},getEstimatedTotalHeight:y,getEstimatedTotalWidth:x,getOffsetForColumnAndAlignment:function(e,t,r,o,n,i){return T("column",e,t,r,o,n,i)},getOffsetForRowAndAlignment:function(e,t,r,o,n,i){return T("row",e,t,r,o,n,i)},getRowOffset:function(e,t,r){return C("row",e,t,r).offset},getRowHeight:function(e,t,r){return r.rowMetadataMap[t].size},getRowStartIndexForOffset:function(e,t,r){return _("row",e,r,t)},getRowStopIndexForStartIndex:function(e,t,r,o){for(var n=e.rowCount,i=e.height,a=C("row",e,t,o),l=r+i,s=a.offset+a.size,c=t;c<n-1&&s<l;)c++,s+=C("row",e,c,o).size;return c},initInstanceProps:function(e,t){var r=e,o={columnMetadataMap:{},estimatedColumnWidth:r.estimatedColumnWidth||50,estimatedRowHeight:r.estimatedRowHeight||50,lastMeasuredColumnIndex:-1,lastMeasuredRowIndex:-1,rowMetadataMap:{}};return t.resetAfterColumnIndex=function(e,r){void 0===r&&(r=!0),t.resetAfterIndices({columnIndex:e,shouldForceUpdate:r})},t.resetAfterRowIndex=function(e,r){void 0===r&&(r=!0),t.resetAfterIndices({rowIndex:e,shouldForceUpdate:r})},t.resetAfterIndices=function(e){var r=e.columnIndex,n=e.rowIndex,i=e.shouldForceUpdate,a=void 0===i||i;"number"==typeof r&&(o.lastMeasuredColumnIndex=Math.min(o.lastMeasuredColumnIndex,r-1)),"number"==typeof n&&(o.lastMeasuredRowIndex=Math.min(o.lastMeasuredRowIndex,n-1)),t._getItemStyleCache(-1),a&&t.forceUpdate()},o},shouldResetStyleCacheOnItemSizeChange:!1,validateProps:function(e){var t=e.columnWidth,r=e.rowHeight;if("function"!=typeof t)throw Error('An invalid "columnWidth" prop has been specified. Value should be a function. "'+(null===t?"null":typeof t)+'" was specified.');if("function"!=typeof r)throw Error('An invalid "rowHeight" prop has been specified. Value should be a function. "'+(null===r?"null":typeof r)+'" was specified.')}}),O=function(e,t){return e},P=null,W=null;function E(e){var n,a=e.getItemOffset,l=e.getEstimatedTotalSize,c=e.getItemSize,f=e.getOffsetForIndexAndAlignment,p=e.getStartIndexForOffset,v=e.getStopIndexForStartIndex,g=e.initInstanceProps,w=e.shouldResetStyleCacheOnItemSizeChange,S=e.validateProps;return(n=function(e){function n(t){var r;return(r=e.call(this,t)||this)._instanceProps=g(r.props,o(r)),r._outerRef=void 0,r._resetIsScrollingTimeoutId=null,r.state={instance:o(r),isScrolling:!1,scrollDirection:"forward",scrollOffset:"number"==typeof r.props.initialScrollOffset?r.props.initialScrollOffset:0,scrollUpdateWasRequested:!1},r._callOnItemsRendered=void 0,r._callOnItemsRendered=s((function(e,t,o,n){return r.props.onItemsRendered({overscanStartIndex:e,overscanStopIndex:t,visibleStartIndex:o,visibleStopIndex:n})})),r._callOnScroll=void 0,r._callOnScroll=s((function(e,t,o){return r.props.onScroll({scrollDirection:e,scrollOffset:t,scrollUpdateWasRequested:o})})),r._getItemStyle=void 0,r._getItemStyle=function(e){var t,o=r.props,n=o.direction,i=o.itemSize,l=o.layout,s=r._getItemStyleCache(w&&i,w&&l,w&&n);if(s.hasOwnProperty(e))t=s[e];else{var u=a(r.props,e,r._instanceProps),d=c(r.props,e,r._instanceProps),f="horizontal"===n||"horizontal"===l,h="rtl"===n,p=f?u:0;s[e]=t={position:"absolute",left:h?void 0:p,right:h?p:void 0,top:f?0:u,height:f?"100%":d,width:f?d:"100%"}}return t},r._getItemStyleCache=void 0,r._getItemStyleCache=s((function(e,t,r){return{}})),r._onScrollHorizontal=function(e){var t=e.currentTarget,o=t.clientWidth,n=t.scrollLeft,i=t.scrollWidth;r.setState((function(e){if(e.scrollOffset===n)return null;var t=r.props.direction,a=n;if("rtl"===t)switch(m()){case"negative":a=-n;break;case"positive-descending":a=i-o-n}return a=Math.max(0,Math.min(a,i-o)),{isScrolling:!0,scrollDirection:e.scrollOffset<n?"forward":"backward",scrollOffset:a,scrollUpdateWasRequested:!1}}),r._resetIsScrollingDebounced)},r._onScrollVertical=function(e){var t=e.currentTarget,o=t.clientHeight,n=t.scrollHeight,i=t.scrollTop;r.setState((function(e){if(e.scrollOffset===i)return null;var t=Math.max(0,Math.min(i,n-o));return{isScrolling:!0,scrollDirection:e.scrollOffset<t?"forward":"backward",scrollOffset:t,scrollUpdateWasRequested:!1}}),r._resetIsScrollingDebounced)},r._outerRefSetter=function(e){var t=r.props.outerRef;r._outerRef=e,"function"==typeof t?t(e):null!=t&&"object"==typeof t&&t.hasOwnProperty("current")&&(t.current=e)},r._resetIsScrollingDebounced=function(){null!==r._resetIsScrollingTimeoutId&&u(r._resetIsScrollingTimeoutId),r._resetIsScrollingTimeoutId=d(r._resetIsScrolling,150)},r._resetIsScrolling=function(){r._resetIsScrollingTimeoutId=null,r.setState({isScrolling:!1},(function(){r._getItemStyleCache(-1,null)}))},r}i(n,e),n.getDerivedStateFromProps=function(e,t){return A(e,t),S(e),null};var I=n.prototype;return I.scrollTo=function(e){e=Math.max(0,e),this.setState((function(t){return t.scrollOffset===e?null:{scrollDirection:t.scrollOffset<e?"forward":"backward",scrollOffset:e,scrollUpdateWasRequested:!0}}),this._resetIsScrollingDebounced)},I.scrollToItem=function(e,t){void 0===t&&(t="auto");var r=this.props,o=r.itemCount,n=r.layout,i=this.state.scrollOffset;e=Math.max(0,Math.min(e,o-1));var a=0;if(this._outerRef){var l=this._outerRef;a="vertical"===n?l.scrollWidth>l.clientWidth?h():0:l.scrollHeight>l.clientHeight?h():0}this.scrollTo(f(this.props,e,t,i,this._instanceProps,a))},I.componentDidMount=function(){var e=this.props,t=e.direction,r=e.initialScrollOffset,o=e.layout;if("number"==typeof r&&null!=this._outerRef){var n=this._outerRef;"horizontal"===t||"horizontal"===o?n.scrollLeft=r:n.scrollTop=r}this._callPropsCallbacks()},I.componentDidUpdate=function(){var e=this.props,t=e.direction,r=e.layout,o=this.state,n=o.scrollOffset;if(o.scrollUpdateWasRequested&&null!=this._outerRef){var i=this._outerRef;if("horizontal"===t||"horizontal"===r)if("rtl"===t)switch(m()){case"negative":i.scrollLeft=-n;break;case"positive-ascending":i.scrollLeft=n;break;default:var a=i.clientWidth,l=i.scrollWidth;i.scrollLeft=l-a-n}else i.scrollLeft=n;else i.scrollTop=n}this._callPropsCallbacks()},I.componentWillUnmount=function(){null!==this._resetIsScrollingTimeoutId&&u(this._resetIsScrollingTimeoutId)},I.render=function(){var e=this.props,o=e.children,n=e.className,i=e.direction,a=e.height,s=e.innerRef,c=e.innerElementType,u=e.innerTagName,d=e.itemCount,f=e.itemData,h=e.itemKey,p=void 0===h?O:h,m=e.layout,v=e.outerElementType,g=e.outerTagName,w=e.style,S=e.useIsScrolling,I=e.width,M=this.state.isScrolling,y="horizontal"===i||"horizontal"===m,x=y?this._onScrollHorizontal:this._onScrollVertical,C=this._getRangeToRender(),_=C[0],b=C[1],R=[];if(d>0)for(var T=_;T<=b;T++)R.push(t.createElement(o,{data:f,key:p(T,f),index:T,isScrolling:S?M:void 0,style:this._getItemStyle(T)}));var z=l(this.props,this._instanceProps);return t.createElement(v||g||"div",{className:n,onScroll:x,ref:this._outerRefSetter,style:r({position:"relative",height:a,width:I,overflow:"auto",WebkitOverflowScrolling:"touch",willChange:"transform",direction:i},w)},t.createElement(c||u||"div",{children:R,ref:s,style:{height:y?"100%":z,pointerEvents:M?"none":void 0,width:y?z:"100%"}}))},I._callPropsCallbacks=function(){if("function"==typeof this.props.onItemsRendered&&this.props.itemCount>0){var e=this._getRangeToRender(),t=e[0],r=e[1],o=e[2],n=e[3];this._callOnItemsRendered(t,r,o,n)}if("function"==typeof this.props.onScroll){var i=this.state,a=i.scrollDirection,l=i.scrollOffset,s=i.scrollUpdateWasRequested;this._callOnScroll(a,l,s)}},I._getRangeToRender=function(){var e=this.props,t=e.itemCount,r=e.overscanCount,o=this.state,n=o.isScrolling,i=o.scrollDirection,a=o.scrollOffset;if(0===t)return[0,0,0,0];var l=p(this.props,a,this._instanceProps),s=v(this.props,l,a,this._instanceProps),c=n&&"backward"!==i?1:Math.max(1,r),u=n&&"forward"!==i?1:Math.max(1,r);return[Math.max(0,l-c),Math.max(0,Math.min(t-1,s+u)),l,s]},n}(t.PureComponent)).defaultProps={direction:"ltr",itemData:void 0,layout:"vertical",overscanCount:2,useIsScrolling:!1},n}"undefined"!=typeof window&&void 0!==window.WeakSet&&(P=new WeakSet,W=new WeakSet);var A=function(e,t){var r=e.children,o=e.direction,n=e.height,i=e.layout,a=e.innerTagName,l=e.outerTagName,s=e.width,c=t.instance;null==a&&null==l||W&&!W.has(c)&&(W.add(c),console.warn("The innerTagName and outerTagName props have been deprecated. Please use the innerElementType and outerElementType props instead."));var u="horizontal"===o||"horizontal"===i;switch(o){case"horizontal":case"vertical":P&&!P.has(c)&&(P.add(c),console.warn('The direction prop should be either "ltr" (default) or "rtl". Please use the layout prop to specify "vertical" (default) or "horizontal" orientation.'));break;case"ltr":case"rtl":break;default:throw Error('An invalid "direction" prop has been specified. Value should be either "ltr" or "rtl". "'+o+'" was specified.')}switch(i){case"horizontal":case"vertical":break;default:throw Error('An invalid "layout" prop has been specified. Value should be either "horizontal" or "vertical". "'+i+'" was specified.')}if(null==r)throw Error('An invalid "children" prop has been specified. Value should be a React component. "'+(null===r?"null":typeof r)+'" was specified.');if(u&&"number"!=typeof s)throw Error('An invalid "width" prop has been specified. Horizontal lists must specify a number for width. "'+(null===s?"null":typeof s)+'" was specified.');if(!u&&"number"!=typeof n)throw Error('An invalid "height" prop has been specified. Vertical lists must specify a number for height. "'+(null===n?"null":typeof n)+'" was specified.')},k=function(e,t,r){var o=e.itemSize,n=r.itemMetadataMap,i=r.lastMeasuredIndex;if(t>i){var a=0;if(i>=0){var l=n[i];a=l.offset+l.size}for(var s=i+1;s<=t;s++){var c=o(s);n[s]={offset:a,size:c},a+=c}r.lastMeasuredIndex=t}return n[t]},D=function(e,t,r,o,n){for(;o<=r;){var i=o+Math.floor((r-o)/2),a=k(e,i,t).offset;if(a===n)return i;a<n?o=i+1:a>n&&(r=i-1)}return o>0?o-1:0},F=function(e,t,r,o){for(var n=e.itemCount,i=1;r<n&&k(e,r,t).offset<o;)r+=i,i*=2;return D(e,t,Math.min(r,n-1),Math.floor(r/2),o)},L=function(e,t){var r=e.itemCount,o=t.itemMetadataMap,n=t.estimatedItemSize,i=t.lastMeasuredIndex,a=0;if(i>=r&&(i=r-1),i>=0){var l=o[i];a=l.offset+l.size}return a+(r-i-1)*n},H=E({getItemOffset:function(e,t,r){return k(e,t,r).offset},getItemSize:function(e,t,r){return r.itemMetadataMap[t].size},getEstimatedTotalSize:L,getOffsetForIndexAndAlignment:function(e,t,r,o,n,i){var a=e.direction,l=e.height,s=e.layout,c=e.width,u="horizontal"===a||"horizontal"===s?c:l,d=k(e,t,n),f=L(e,n),h=Math.max(0,Math.min(f-u,d.offset)),p=Math.max(0,d.offset-u+d.size+i);switch("smart"===r&&(r=o>=p-u&&o<=h+u?"auto":"center"),r){case"start":return h;case"end":return p;case"center":return Math.round(p+(h-p)/2);case"auto":default:return o>=p&&o<=h?o:o<p?p:h}},getStartIndexForOffset:function(e,t,r){return function(e,t,r){var o=t.itemMetadataMap,n=t.lastMeasuredIndex;return(n>0?o[n].offset:0)>=r?D(e,t,n,0,r):F(e,t,Math.max(0,n),r)}(e,r,t)},getStopIndexForStartIndex:function(e,t,r,o){for(var n=e.direction,i=e.height,a=e.itemCount,l=e.layout,s=e.width,c="horizontal"===n||"horizontal"===l?s:i,u=k(e,t,o),d=r+c,f=u.offset+u.size,h=t;h<a-1&&f<d;)h++,f+=k(e,h,o).size;return h},initInstanceProps:function(e,t){var r={itemMetadataMap:{},estimatedItemSize:e.estimatedItemSize||50,lastMeasuredIndex:-1};return t.resetAfterIndex=function(e,o){void 0===o&&(o=!0),r.lastMeasuredIndex=Math.min(r.lastMeasuredIndex,e-1),t._getItemStyleCache(-1),o&&t.forceUpdate()},r},shouldResetStyleCacheOnItemSizeChange:!1,validateProps:function(e){var t=e.itemSize;if("function"!=typeof t)throw Error('An invalid "itemSize" prop has been specified. Value should be a function. "'+(null===t?"null":typeof t)+'" was specified.')}}),U=I({getColumnOffset:function(e,t){return t*e.columnWidth},getColumnWidth:function(e,t){return e.columnWidth},getRowOffset:function(e,t){return t*e.rowHeight},getRowHeight:function(e,t){return e.rowHeight},getEstimatedTotalHeight:function(e){var t=e.rowCount;return e.rowHeight*t},getEstimatedTotalWidth:function(e){var t=e.columnCount;return e.columnWidth*t},getOffsetForColumnAndAlignment:function(e,t,r,o,n,i){var a=e.columnCount,l=e.columnWidth,s=e.width,c=Math.max(0,a*l-s),u=Math.min(c,t*l),d=Math.max(0,t*l-s+i+l);switch("smart"===r&&(r=o>=d-s&&o<=u+s?"auto":"center"),r){case"start":return u;case"end":return d;case"center":var f=Math.round(d+(u-d)/2);return f<Math.ceil(s/2)?0:f>c+Math.floor(s/2)?c:f;case"auto":default:return o>=d&&o<=u?o:d>u||o<d?d:u}},getOffsetForRowAndAlignment:function(e,t,r,o,n,i){var a=e.rowHeight,l=e.height,s=e.rowCount,c=Math.max(0,s*a-l),u=Math.min(c,t*a),d=Math.max(0,t*a-l+i+a);switch("smart"===r&&(r=o>=d-l&&o<=u+l?"auto":"center"),r){case"start":return u;case"end":return d;case"center":var f=Math.round(d+(u-d)/2);return f<Math.ceil(l/2)?0:f>c+Math.floor(l/2)?c:f;case"auto":default:return o>=d&&o<=u?o:d>u||o<d?d:u}},getColumnStartIndexForOffset:function(e,t){var r=e.columnWidth,o=e.columnCount;return Math.max(0,Math.min(o-1,Math.floor(t/r)))},getColumnStopIndexForStartIndex:function(e,t,r){var o=e.columnWidth,n=e.columnCount,i=e.width,a=t*o,l=Math.ceil((i+r-a)/o);return Math.max(0,Math.min(n-1,t+l-1))},getRowStartIndexForOffset:function(e,t){var r=e.rowHeight,o=e.rowCount;return Math.max(0,Math.min(o-1,Math.floor(t/r)))},getRowStopIndexForStartIndex:function(e,t,r){var o=e.rowHeight,n=e.rowCount,i=e.height,a=t*o,l=Math.ceil((i+r-a)/o);return Math.max(0,Math.min(n-1,t+l-1))},initInstanceProps:function(e){},shouldResetStyleCacheOnItemSizeChange:!0,validateProps:function(e){var t=e.columnWidth,r=e.rowHeight;if("number"!=typeof t)throw Error('An invalid "columnWidth" prop has been specified. Value should be a number. "'+(null===t?"null":typeof t)+'" was specified.');if("number"!=typeof r)throw Error('An invalid "rowHeight" prop has been specified. Value should be a number. "'+(null===r?"null":typeof r)+'" was specified.')}}),N=E({getItemOffset:function(e,t){return t*e.itemSize},getItemSize:function(e,t){return e.itemSize},getEstimatedTotalSize:function(e){var t=e.itemCount;return e.itemSize*t},getOffsetForIndexAndAlignment:function(e,t,r,o,n,i){var a=e.direction,l=e.height,s=e.itemCount,c=e.itemSize,u=e.layout,d=e.width,f="horizontal"===a||"horizontal"===u?d:l,h=Math.max(0,s*c-f),p=Math.min(h,t*c),m=Math.max(0,t*c-f+c+i);switch("smart"===r&&(r=o>=m-f&&o<=p+f?"auto":"center"),r){case"start":return p;case"end":return m;case"center":var v=Math.round(m+(p-m)/2);return v<Math.ceil(f/2)?0:v>h+Math.floor(f/2)?h:v;case"auto":default:return o>=m&&o<=p?o:o<m?m:p}},getStartIndexForOffset:function(e,t){var r=e.itemCount,o=e.itemSize;return Math.max(0,Math.min(r-1,Math.floor(t/o)))},getStopIndexForStartIndex:function(e,t,r){var o=e.direction,n=e.height,i=e.itemCount,a=e.itemSize,l=e.layout,s=e.width,c=t*a,u="horizontal"===o||"horizontal"===l?s:n,d=Math.ceil((u+r-c)/a);return Math.max(0,Math.min(i-1,t+d-1))},initInstanceProps:function(e){},shouldResetStyleCacheOnItemSizeChange:!0,validateProps:function(e){var t=e.itemSize;if("number"!=typeof t)throw Error('An invalid "itemSize" prop has been specified. Value should be a number. "'+(null===t?"null":typeof t)+'" was specified.')}});function V(e,t){if(null==e)return{};var r,o,n={},i=Object.keys(e);for(o=0;o<i.length;o++)r=i[o],t.indexOf(r)>=0||(n[r]=e[r]);return n}function q(e,t){for(var r in e)if(!(r in t))return!0;for(var o in t)if(e[o]!==t[o])return!0;return!1}var j=["style"],G=["style"];function K(e,t){var r=e.style,o=V(e,j),n=t.style,i=V(t,G);return!q(r,n)&&!q(o,i)}e.FixedSizeGrid=U,e.FixedSizeList=N,e.VariableSizeGrid=z,e.VariableSizeList=H,e.areEqual=K,e.shouldComponentUpdate=function(e,t){return!K(this.props,e)||q(this.state,t)},Object.defineProperty(e,"__esModule",{value:!0})}));
//# sourceMappingURL=index-dev.umd.js.map