react-virtualized-auto-sizer
Advanced tools
Comparing version 1.0.19 to 1.0.20
@@ -21,2 +21,3 @@ import { Component, ReactElement } from "react"; | ||
_resizeObserver: ResizeObserver | null; | ||
_timeoutId: number | null; | ||
componentDidMount(): void; | ||
@@ -23,0 +24,0 @@ componentWillUnmount(): void; |
@@ -235,3 +235,5 @@ 'use strict'; | ||
this._resizeObserver = null; | ||
this._timeoutId = null; | ||
this._onResize = () => { | ||
this._timeoutId = null; | ||
const { | ||
@@ -298,3 +300,3 @@ disableHeight, | ||
// See https://github.com/bvaughn/react-virtualized-auto-sizer/issues/55 | ||
setTimeout(this._onResize, 0); | ||
this._timeoutId = setTimeout(this._onResize, 0); | ||
}); | ||
@@ -315,2 +317,5 @@ this._resizeObserver.observe(this._parentNode); | ||
} | ||
if (this._timeoutId !== null) { | ||
clearTimeout(this._timeoutId); | ||
} | ||
if (this._resizeObserver) { | ||
@@ -317,0 +322,0 @@ this._resizeObserver.observe(this._parentNode); |
@@ -231,3 +231,5 @@ import { Component, createElement } from 'react'; | ||
this._resizeObserver = null; | ||
this._timeoutId = null; | ||
this._onResize = () => { | ||
this._timeoutId = null; | ||
const { | ||
@@ -294,3 +296,3 @@ disableHeight, | ||
// See https://github.com/bvaughn/react-virtualized-auto-sizer/issues/55 | ||
setTimeout(this._onResize, 0); | ||
this._timeoutId = setTimeout(this._onResize, 0); | ||
}); | ||
@@ -311,2 +313,5 @@ this._resizeObserver.observe(this._parentNode); | ||
} | ||
if (this._timeoutId !== null) { | ||
clearTimeout(this._timeoutId); | ||
} | ||
if (this._resizeObserver) { | ||
@@ -313,0 +318,0 @@ this._resizeObserver.observe(this._parentNode); |
{ | ||
"name": "react-virtualized-auto-sizer", | ||
"version": "1.0.19", | ||
"version": "1.0.20", | ||
"description": "Standalone version of the AutoSizer component from react-virtualized", | ||
@@ -5,0 +5,0 @@ "author": "Brian Vaughn <brian.david.vaughn@gmail.com> (https://github.com/bvaughn/)", |
@@ -18,3 +18,3 @@ # react-virtualized-auto-sizer | ||
| :------------ | :------- | :-------: | :-------------------------------------------------------------------------------------------------------------------------------------------------------------- | | ||
| children | Function | ✓ | Function responsible for rendering children. This function should implement the following signature: `({ height?: number | undefined, width?: number | undefined }) => PropTypes.element` | | ||
| children | Function | ✓ | Function responsible for rendering children. This function should implement the following signature: `({ height?: number \| undefined, width?: number \| undefined }) => PropTypes.element` | | ||
| className | String | | Optional custom CSS class name to attach to root `AutoSizer` element. This is an advanced property and is not typically necessary. | | ||
@@ -21,0 +21,0 @@ | defaultHeight | Number | | Height passed to child for initial render; useful for server-side rendering. This value will be overridden with an accurate height after mounting. | |
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
45262
849
0