Skip to content

Tracked Position on Page load #26

@mikegallay

Description

@mikegallay

A few of the items I am tracking appear slightly above the bottom of the page on load. These items are appearing with a translate3d y-position of -33% (see code below). Once I scroll they jump to the calculated position based on my tween. Is there any way to have the tween calculate and apply while their position on load (without seeing a jump)?

I have already tried applying a scroll using js, but you can still see they items jump once the calculated tween takes hold. Thanks!

<DIV
	className='tile-wrapper-scroll'
	style={ tween(scrollY, [
		[posTopBottom, { transform: translate3d(0, percent(0), 0) }],
		[posBottomTop, { transform: translate3d(0, percent(-33), 0) }]
	])}
	>
	<div className='tile-wrapper' style={tileStyle}></div>
</DIV>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions