GitHub Download

Rotating 3D cube hover effect

3D
Welcome
Cubes
To
Hover
The
Effect
Other
Try
Side
Different
:)
Sides
Hooray

Documentation

What is this?

Rotating cube hover effect. There are two divs which are changed every time you hover. Depending of the direction you hovered the cube, it will rotate in that direction.

Minimum setup:

var cube = new Cube();

Aditional options:

var cube = new Cube({
    cubeWrapperSelector: '.CubeWrapper',
    cubeSelector: '.Cube',
    frontSideClass: 'Cube-side--front',
    secondSideClass: 'Cube-side--second',
    transitionTime: 300
});

Tested on Safari, Chrome, Firefox. Both mobile and desktop. Internet Explorer is not supported, but it falls back to fading between states.