Home  >  Article  >  Web Front-end  >  How to implement the nine-square grid style in Flex layout in css (code)

How to implement the nine-square grid style in Flex layout in css (code)

不言
不言Original
2018-08-10 09:50:107124browse

The content of this article is about how to implement the nine-square grid style (code) in Flex layout in CSS. It has certain reference value. Friends in need can refer to it. I hope it will be helpful to you.

How to implement the nine-square grid style in Flex layout in css (code)

nbsp;html>

<style>
.block {
    padding-top: 30%;
    margin-top: 3%;
    border-radius: 10%;
    background-color: orange;
    width: 30%;
}
.container-flex2  {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
}
</style>

   <div>
        <div></div>
        <div></div>
        <div></div>
        <div></div>
        <div></div>
        <div></div>
        <div></div>
        <div></div>
        <div></div>
    </div>

Recommended related articles:

A brief introduction to the Flex layout of the display attribute in CSS3

Several techniques that can be used when implementing layout with css (code)

The above is the detailed content of How to implement the nine-square grid style in Flex layout in css (code). For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn