Create Bounce out Vertical menu with jQuery
So here will create a simple bounce out vertical menu with the help of little bit css3 and jquery framework. Beautiful navigation menu can stand out your website from the crowd of creative navigations. That’s why we tried to create vertical menu which on mouse hover give a nice bounce out sliding effect. Lets begin..
Demo Download
Files Needed Before Starting
jQuery Framework – Download
jQuery Easing Plugin – Download
Here we will use jQuery easing plugin to get easeoutbounce effect directly. Therefore we don’t need to code much. We can get the desired effect in simple steps.
Step 1 : HTML
Will create li elements for our navigation menu with description in paragraph tag. Check out the below document for more clarification.
Step 2 : CSS Style
Here we will use some css3 properties to get some cool UI effect like box-shadow and text-shadow.
Box-Shadow – Box shadow will give some drop down effect to the whole box element ( li here ).
Box shadow takes 3 lengths and a color as attributes. ( Horizontal offset, Vertical offset, Blur radius and color).
Text-Shadow – Same as box-shadow x offset, y offset, blur and color.
Check the below codes for more clarification.
Note : Make li overflow to hidden so that paragraph text will be hidden and later will use jQuery to show paragraph text.
Step 3 : Link Jquery And Easing Plugin
Now we got jquery framework and easing plugin with us so its the time to link it with html document. Along with Empty custom.js so we can write codes in there later.
Step 4 : JQuery
Here will use mouseover and mouseout properties of jQuery to get the final Effect. Using animate function will change the height of li element so that it can show the paragraph text. And on mouseout will change its height back to normal pixel.
沒有留言:
張貼留言