wagerfield / parallax

Parallax Engine that reacts to the orientation of a smart device
http://wagerfield.github.io/parallax/
Other
16.5k stars 2.14k forks source link

After using parallax 'a' tag in html doesn't work #295

Closed MahediHasanBijoy closed 7 months ago

MahediHasanBijoy commented 4 years ago
    </section>
    <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
    <script src="scripts/parallax.min.js"></script>
    <script src="scripts/main.js"></script>
    <script>
        var scene = document.getElementById('scene');
        var parallax = new Parallax(scene);
    </script>

//In this code the a tags aren't working properly like they don't seems clickable and the css hover property doesn't work.

endrits079 commented 4 years ago

By default pointer events are disabled which means you can't click on elements, see the guide below how to fix it and beware that just setting pointerEvents:true might not work, it tells you what you need to do pointerEvents Property: pointerEvents Attribute: data-pointer-events

Value: boolean Default: false

Set to true to enable interactions with the scene and layer elements. When set to the default of false, the CSS attribute pointer-events: none will be applied for performance reasons. Setting this to true alone will not be enough to fully interact with all layers, since they will be overlapping. You have to either set position: absolute on all layer child elements, or keep pointerEvents at false and set pointer-events: all for the interactable elements only.

MahediHasanBijoy commented 4 years ago

Thanks for your reply. I didn't know this at that moment because of my low knowledge. Anyways appreciate your work .

On Thu, 17 Sep 2020, 17:52 Endrit, notifications@github.com wrote:

By default pointer events are disabled which means you can't click on elements, see the guide below how to fix it and beware that just setting pointerEvents:true might not work, it tells you what you need to do pointerEvents Property: pointerEvents Attribute: data-pointer-events

Value: boolean Default: false

Set to true to enable interactions with the scene and layer elements. When set to the default of false, the CSS attribute pointer-events: none will be applied for performance reasons. Setting this to true alone will not be enough to fully interact with all layers, since they will be overlapping. You have to either set position: absolute on all layer child elements, or keep pointerEvents at false and set pointer-events: all for the interactable elements only.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/wagerfield/parallax/issues/295#issuecomment-694180530, or unsubscribe https://github.com/notifications/unsubscribe-auth/AGB7V6LHDNHVYT7FSK2D6RTSGH2BTANCNFSM4PV546VA .

tkohlmannhuber commented 3 years ago

Hi endrits.

Where to define the Propertie + Attribute and where to set the Value to true ?