javascript - Jquery dlmenu animation is not smooth -
i have created multilevel navigation menu using jquery dlmenu plugin v1.0.2 demo2.
everything works fine, except css3 menu navigation not smooth jquery left/right slide functionality is.
is there solution resolve issue without changing plugin?
/* animation classes moving out , in */ .dl-menu.dl-animate-out-2 { -webkit-animation: menuanimout2 0.3s ease-in-out forwards; -moz-animation: menuanimout2 0.3s ease-in-out forwards; animation: menuanimout2 0.3s ease-in-out forwards; } @-webkit-keyframes menuanimout2 { 100% { -webkit-transform: translatex(-100%); opacity: 0; } } @-moz-keyframes menuanimout2 { 100% { -moz-transform: translatex(-100%); opacity: 0; } } @keyframes menuanimout2 { 100% { transform: translatex(-100%); opacity: 0; } } .dl-menu.dl-animate-in-2 { -webkit-animation: menuanimin2 0.3s ease-in-out forwards; -moz-animation: menuanimin2 0.3s ease-in-out forwards; animation: menuanimin2 0.3s ease-in-out forwards; } @-webkit-keyframes menuanimin2 { 0% { -webkit-transform: translatex(-100%); opacity: 0; } 100% { -webkit-transform: translatex(0px); opacity: 1; } } @-moz-keyframes menuanimin2 { 0% { -moz-transform: translatex(-100%); opacity: 0; } 100% { -moz-transform: translatex(0px); opacity: 1; } } @keyframes menuanimin2 { 0% { transform: translatex(-100%); opacity: 0; } 100% { transform: translatex(0px); opacity: 1; } }
you have use plugin : animationclasses "in" , "out" not "classin" , "classout"
$(function() { $( '#dl-menu' ).dlmenu({ animationclasses : { in : 'dl-animate-in-2', out : 'dl-animate-out-2' } }); });
Comments
Post a Comment