This article introduces the sample code of CSS3 column to realize the card waterfall layout, which is shared with you as follows: Achieve results Today I encountered the problem of implementing a waterfall layout of cards, and the heights of the cards were different. Finally, I used the column attribute in CSS3 to implement this layout, and it was very simple (I vaguely remember that the last time I wrote the waterfall flow, I used JS to implement it... naive) The effect is as follows: Related properties
Problems encountered
Code .videoCards { padding-top: 4rpx; column-count: 2; column-gap: 18rpx; .card { display: inline-block; margin-top: 20rpx; width: 326rpx; background: #FFFFFF; box-shadow: 0 0 10rpx 0 rgba(0,0,0,0.10); border-radius: 14rpx; break-inside: avoid; padding-bottom: 20rpx; overflow:auto; } } The above is the full content of this article. I hope it will be helpful for everyone’s study. I also hope that everyone will support 123WORDPRESS.COM. |
<<: How to use domestic image warehouse for Docker
In Linux, everything is a file (directories are a...
1. Function: xargs can convert the data separated...
Table of contents Preface NULL in MySQL 2 NULL oc...
1.1 Data Type Overview The data type is a field c...
What is load balancing? When a domain name points...
When deploying uwsgi+nginx proxy Django, access u...
This article example shares the specific code of ...
Here is a single-line layout using ul>li for l...
answer from stackflow: Simply <br> is suffic...
I have recently been developing a visual operatio...
To display the JSON data in a beautiful indented ...
1. Uninstalling MySQL 5.7 1.1查看yum是否安裝過mysql cd y...
For a website, usability refers to whether users c...
To use Nginx under Windows, we need to master som...
What is pip pip is a Python package management to...