要求使用flex布局中的align-self和order完善index.css中的代码,完成如下效果
align-self值:
flex-start flex-end center baseline stretch
order:<整数>
本题先用align-self:flex-end把菠萝放到底部,然后用order给所有水果排序,完整代码如下
.yellow{
align-self: flex-end;
}
#pond>:nth-chird(2){
order:1;
}
#pond>:nth-chird(4){
order:2;
}
#pond>:nth-chird(5){
order:3;
}
#pond>:nth-chird(1){
order:4;
}
#pond>:nth-chird(3){
order:5;
}