老师检查一下。
来源:3-10 编程练习
大师兄js
2020-05-13 22:52:40
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title></title>
<style>
/*在此处补充代码*/
header{
display:flex;
background: black;
justify-content: space-around;
}
.logo{
display:flex;
align-items: center;
}
.nav{
color: white;
list-style: none;
display: inline-flex;
align-items: center;
justify-content: space-between;
}
.nav li{
width: 100px;
text-align: center;
}
.login{
display: flex;
align-items: center;
}
.login input{
padding:3px 5px;
background: orange;
color: white;
margin: 0 10px;
justify-content: center;
border:none;
border-radius:5px;
}
</style>
</head>
<body>
<header>
<div class="logo">
<img src="http://img1.sycdn.imooc.com\/climg/59feb59700019dab01910057.png" alt="">
</div>
<ul class="nav">
<li>课程</li>
<li>路径</li>
<li>猿问</li>
<li>手记</li>
</ul>
<div class="login">
<input type="button" value="登录">
<input type="button" value="注册">
</div>
</header>
</body>
</html>
1回答
好帮手慕星星
2020-05-14
同学你好,代码布局以及实现效果很棒!
优化:body默认有8px外边距,导致盒子四周有空白间隙,看起来不美观
建议清除一下
祝学习愉快!
相似问题