javascript - Show nav dependant on mouse coordinates -
I've got this JS Bealal, what I really want. However, when I am moving the navigation in favor, I can not seem to understand this.
var hoverMenu = $ ('# HiddenMenu'), Hover Space = $ ('#HoverSpace'); HoverSpace.on ('mousemove', function) {if (35 - event.clientY & lt; 0) {hoverMenu.css ({top: 35 - event.clientY})}} and {hoverMenu.css ({top : 0});}}) ('Mouout', Function () {HoverMenu CSS ({Top: -35})}} & lt; - I'm working on this client X / Y event < / P>
I can not apply it using client X & amp; The navigation is moving to the right.
This is where I was able to get it too < /p>
Make this change Add the full position to the hidden menu:
# HideMenu {background color: # e00; Condition: Completed: Correct: -35px;} Make hover position position relative:
# hoverpace {status: relative; background color: # AIEEE ; Hidden spill; width: 45px; height: 500px;} Now you will be fine, you can check the result, it currently works by moving from right to right , Which is slightly different from your horizontal spec.
Comments
Post a Comment