Drag element so it will change position and trigger waypoint?

@nick, @gasspence

I just wrote some code for a floating button. Very simple. While doing it I was thinking it could have some play in this thread.

The JS is run on scene load. and the actioNButton is placed up top

var actioNButton = hypeDocument.getElementById('actioNButton');
	
	$(document).ready(function(){
 
  window.addEventListener("scroll", function() {
    
    
    hypeDocument.setElementProperty(tButton, 'top', $(window).scrollTop() +50, 1.0, 'easeinout')
});

});  

Example here

2 Likes