Ensure scroll bar state is updated on content change

This commit is contained in:
David Chouinard 2016-03-10 18:37:45 -08:00
parent 3396f4a46e
commit d0baf878f5

View file

@ -198,6 +198,10 @@ class ScrollRegion extends React.Component
attributeFilter: ['style']
})
componentDidUpdate: (prevProps, prevState) =>
if (@props.children != prevProps.children)
@recomputeDimensions()
componentWillReceiveProps: (props) =>
if @shouldInvalidateScrollbarComponent(props)
@_scrollbarComponent = null