- 让 容器中的内容
横向显示
display: flex;
- 让容器中的内容
垂直居中
align-content: center; //或者
align-items:center
- 让容器中的内容
水平居中
justify-content: center;
- 制作小
三角形
.ss::after{
content: '';
position:absolute;
border-top: 20px solid red;
border-right: 20px solid transparent;
border-bottom: 20px solid transparent;
border-left: 20px solid transparent;
}
效果:
image.png
网友评论