Custom animations
Describe the forward move. in is for the opening level, out is for the level that leaves. Going back plays both reversed.
new LayerMenu('.menu', {
animation: {
in: [{ opacity: 0, transform: 'translateY(40px)' }, { opacity: 1, transform: 'none' }],
out: [{ opacity: 1, transform: 'none' }, { opacity: 0, transform: 'translateY(-40px)' }],
},
});
// or register it once and use it by name
LayerMenu.animations.rise = { in: […], out: […] };
Was this article helpful?
Thanks for your feedback!