Home >Web Front-end >JS Tutorial >Example of Jquery implementing bottom-up expansion effect_jquery
The common downward expansion effect is very simple, just use slideUp and slideDown.
If the div to be expanded is positioned absolutely through position:absolute, and through relative and bottom positioning, such as bottom:0px, calling slideDown at this time will expand it upward.
(Because slideDown, to put it bluntly, dynamically changes the height of the element, the bottom positioning is fixed, and it expands upward when the height becomes higher)