Today Spring Brother Technology blog and everyone to share under the development of the front-end, or the imitation of the station, sometimes it is easy to encounter the Product List page display dislocation, such as the original 4 line display, the result has become 3 lines display, it is difficult to see.
It turns out that your CSS doesn't control well.
A netizen asks: How CSS controls ul li each line displays several and wraps like the table effect.
Today, Brother Chun to tell you: we look at the following code, what found:
. column. col-4-1 {
width:22.75%;
margin-right:3%;
}
. column. col-4-1 {
width:22%;
margin-right:3%;
}
Obviously the second one is possible, and we have to set the ratio within the 100% range.
This article from the Spring Brother Technology blog Official website, reproduced please indicate the source, thank you!
How CSS makes Li 4-line display