Skip to content

Simple and powerful parallax for DOM elements. No scroll, only mouse movement.

License

Notifications You must be signed in to change notification settings

iJos/jquery.iParallax.js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 

Repository files navigation

iParallax

Simple and powerful parallax for DOM elements. No scroll, only mouse movement.

Dependencies

This plugin uses the following dependences

Last jQuery Version

Use

Add jquery.iparallax.js, after jQuery to the head of your HTML document. Then call iParallax on document ready.

$(document).ready(function () {

    $('body').iParallax({
        parallax_binder         : document, 
        parallax_element        : ".element",
        velocity_ratio_x        : 150,
        velocity_ratio_y        : 150,
        offset_x                : 10,
        offset_y                : 0
	});
	
});

PARAMETERS

parallax_binder

This is the element where you are going to bind the mouse movemente. Default document. You can use any element you want. parallax_binder : "#myDiv"

parallax_element

This is the element affected by our parallax. There is no default parallax_element : ".element"

velocity_ratio_

This is the velocity ratio (multiplier) the lower number, more aggresive parallax effect. Defaults 100 (X and Y)

velocity_ratio_x : 150, velocity_ratio_y : 150

offset_

Do you want to adjust your container perfectly? Use the offset. Defaults 0 (X and Y)

offset_x : 10, offset_y : 0

Copyright

Copyright (c) 2014 Jose Luis Jimenez | @iJos.

About

Simple and powerful parallax for DOM elements. No scroll, only mouse movement.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages