Skip to content

Latest commit

 

History

History
92 lines (50 loc) · 3.24 KB

CHANGELOG.md

File metadata and controls

92 lines (50 loc) · 3.24 KB

Changelog

3.11.0

  • add react 16 as a peer dep (#94)

3.10.1

  • prevent unnecessary rerendering (#85)

3.10.0

  • allow passing a children function that takes state and chooses what to render from it (#76)

3.9.0

  • Migrated deprecated React.PropTypes and React.createClass (#73)

3.8.0

  • Improving offset and adding resize listener (#69)

3.7.0

  • added offset prop (#64)

3.6.2

  • fixed a problem where .debounceCheck is not cleared properly (#62)

3.6.1

  • fixed typo from delay to scrollDelay (#59)

3.6.0

  • added support for "scrollCheck" as well as the default "intervalCheck" (#54)

3.5.0

  • simpler logic for partialVisible (#41)

3.4.0

  • partialVisibility prop can now either be a boolean (any edge can be visible) or a string of top|right|bottom|left to indicate which edge determines visibility (#42)

3.3.0

  • Mark partially visible when center is visible (#40)

3.2.1

  • Fixed error case where component can be null (#38)

3.2.0

  • Added minTopValue and delayedCall props (#30)

3.1.1

  • Removed dist file from git (as suggested in #18)
  • Added npm run build, which is also run on prepublish
  • updated the build script so browserify produces a standalone umd script
  • added example-umd to show how to use it with plain <script> tags

3.0.1

  • return the new state from .check method

3.0.0

  • upgraded to react 0.14
  • removed the package.browserify field, which is no longer needed and was causing some conflicts (#11)

2.1.0

  • new optional prop partialVisibility changes the behaviour of the sensor, so that it considers an element to be visible if it is at least partially visible (#15)

2.0.0

  • sensor DOM node is passed in as children rather than the component always rendering its own <div> (#13)
  • this also means the component also no longer accepts className or style props.

Migrating from v1.x:

If you're not setting a className or style, no change is required.

Otherwise add your own element as a child and move the className or style there. Eg:

  • before: <VisibilitySensor className='something' />
  • after: <VisibilitySensor><div className='something' /></VisibilitySensor>