📌  相关文章
📜  在按钮上单击显示折叠 div jquery - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:02:26.880000             🧑  作者: Mango

代码示例3
#wrapper {
  background: #ccc;
  overflow: hidden;
  transition: max-height 300ms;
  max-height: 0; /* <---hide by default */
}
#wrapper.open {
  max-height: 100px; /* <---when open, allow content to expand to take up as much height as it needs, up to e.g. 100px */
}