javascript – JS effect slide div and appear another

Question:

Next I have a home where the user will come across a field for login or a button to register. By clicking on the register button I would like this current content to disappear from the screen by swiping to the left and the next registered card (step) to appear by swiping from the right and stopping in the middle.

Does anyone have any links with examples preferably with GSAP or some other plugin. I just need some reference to adapt to my project.

Thanks.

Answer:

Hi, I think it's something like this…

<script>
$(document).ready(function() {
    $("#btn-cadastrar").click(function() {
        $('#div-login').hide('slide', {direction: 'left'}, 1000);
        $('#div-cadastro').show('slide', {direction: 'right'}, 1000);
    });
});
</script>
Scroll to Top
AllEscort