设置子容器的高度,根据父容器的高度来决定
父容器设置
plaintext
1234
div.parent{
position:relative;
overflow:hidden;
}
子容器设置
plaintext
1234567
div.child{
position:absolute;
width:100%;
height:100%;
align-items:center;
justify-content:center;
}