Skip to content

Releases: yahoo/react-stickynode

Support enableTransforms

25 Feb 18:22
Compare
Choose a tag to compare

We added enableTransforms prop in case you cannot add Modernizr, so that you can disable transform. The default is true, so Modernizr is required by default. But still, strongly recommend to use the default value for the performance.

Thank @codeheroics for the contribution.

256fb94

Better precision on height

25 Feb 01:09
Compare
Choose a tag to compare

Using getBoundingClientRect() instead of offsetHeight to get better precision.

More precise content width

25 Feb 00:56
Compare
Choose a tag to compare

Sticky keeps content width, and height to avoid collapse when its state is "fixed". Sticky got width from the offsetWidth of content, but the width is rounded. A better way is to get width from calling getBoundingClientRect(), thank @testerez. To support lower browser (IE8 and lower), we fallback like

var outerRect = outer.getBoundingClientRect();
var width = outerRect.width || outerRect.right - outerRect.left;

#17

Keep the height of content

25 Feb 00:00
Compare
Choose a tag to compare

Explicitly set sticky height as the content height to avoid document collapse when sticky is fixed state.
#16

React 14

24 Nov 09:33
Compare
Choose a tag to compare

Start from this ^1.0.0, we are moving to React 14.
Also switch to ES6 class.

Related code change
#1