Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

anchorPlacement option does not work correctly #798

Open
mcolominas opened this issue Nov 19, 2022 · 0 comments
Open

anchorPlacement option does not work correctly #798

mcolominas opened this issue Nov 19, 2022 · 0 comments

Comments

@mcolominas
Copy link

When you added the following script:

<script src="https://unpkg.com/aos@2.3.1/dist/aos.js" defer onload="AOS.init({anchorPlacement:'top-center'})"></script>

The anchorPlacement option is not set correctly, having the following html:

<section>
    <div style="width: 200px;height:200px;display:inline-block" data-aos="zoom-in">
        DIV 1
    </div>
    
    <div style="width: 200px;height:200px;display:inline-block" data-aos="zoom-in" data-aos-anchor-placement="top-center">
        DIV 2
    </div>
</section>

The expected behavior is for them to appear and disappear at the same time, but the behavior of DIV 1 is incorrect.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant