html第二次作业

骨架

html 复制代码
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <link rel="stylesheet" href="./小米.css">
</head>
<body>
    <div class="father">
        <div class="left"></div>

        <div class="right">
            <ul>
                <li></li>
                <li></li>
                <li></li>
                <li></li>
                <li></li>
                <li></li>
                <li></li>
                <li></li>
            </ul>

        </div>
    </div>
</body>
</html>

css

html 复制代码
* {
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}


.father{
    width: 1240px;
    height: 628px;
    background-color: blue;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    flex-flow:row;
}

.left{
    width: 247px;
    height: 614px;
    background-color: pink;
}

.right{
    width: 978px;
    height: 628px;
    background-color: aqua;
    border: 0px;
    display: flex;

}

.ul{
    width: 992px;
    height: 614px;
    padding-left: 14px;
    display: flex;
    justify-content: space-between;

}

li {
    list-style: none;
}
.father li {
    width: 234px;
    height: 300px;
    background-color:red ;
    margin: 0px 9px 9px 0px;
    display: inline-block;
}

.father li:nth-child(4n){
    margin-right: 0;
}

效果

相关推荐
一路向前的月光41 分钟前
react(9)-redux
前端·javascript·react.js
大数据追光猿1 小时前
Python中的Flask深入认知&搭建前端页面?
前端·css·python·前端框架·flask·html5
莫忘初心丶1 小时前
python flask 使用教程 快速搭建一个 Web 应用
前端·python·flask
xw52 小时前
Trae初体验
前端·trae
横冲直撞de2 小时前
前端接收后端19位数字参数,精度丢失的问题
前端
我是哈哈hh2 小时前
【JavaScript进阶】作用域&解构&箭头函数
开发语言·前端·javascript·html
摸鱼大侠想挣钱2 小时前
ActiveX控件
前端
谢尔登2 小时前
Vue 和 React 响应式的区别
前端·vue.js·react.js
后端小肥肠2 小时前
【AI编程】Java程序员如何用Cursor 3小时搞定CAS单点登录前端集成
前端·后端·cursor
酷酷的阿云2 小时前
Vue3性能优化必杀技:useDebounce+useThrottle+useLazyLoad深度剖析
前端·javascript·vue.js