svg+css+js模仿手机底部滑动导航条效果代码

代码语言:html

所属分类:菜单导航

代码描述:svg+css+js模仿手机底部滑动导航条效果代码

代码标签: svg css js 模仿 手机 底部 滑动 导航条

下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开

<!DOCTYPE html>
<html lang="en" >
<head>
  <meta charset="UTF-8">

<style>
    @import url("https://fonts.googleapis.com/css?family=Roboto:400,400i,700");
body,
html {
  height: 100%;
}
body {
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e9ecff;
  font-family: "Roboto";
}
nav {
  position: relative;
}
ul {
  list-style-type: none;
  padding: 0;
  background: #432fbf;
  border-bottom-left-radius: 40px;
  border-bottom-right-radius: 40px;
  box-shadow: 2px 10px 20px rgba(67, 47, 191, 0.5);
}
li {
  display: inline-block;
  margin: 40px 20px;
}
li:first-child {
  margin-left: 30px;
}
li:last-child {
  margin-right: 30px;
}
a {
  cursor: pointer;
  display: flex;
  align-items: center;
  padding: 10px 25px;
}
svg {
  stroke: #9386ea;
  width: 44px;
  height: 44px;
  transform: translateX(35px);
  transition: 0.4s ease all;
}
a.active {
  color: white;
}
a.active svg {
  stroke: white;
  transform: translateX(0px);
}
.link-text {
  color: white;
  margin-left: 16px;
  op.........完整代码请登录后点击上方下载按钮下载查看

网友评论1

  1. # 106
    666666666666666
    12312312 2023-02-26回复