html5仿谷歌Material Design侧边导航点击切换选项代码



93 370 124



特效描述:html5仿谷歌 Material Design 侧边导航 切换选项代码,html5侧边导航,点击切换选项,谷歌Material Design

代码结构

1. 引入CSS

<link rel="stylesheet" type="text/css" href="css/normalize.css" />
<link rel="stylesheet" type="text/css" href="css/default.css">
<link href='http://fonts.useso.com/css?family=Lato:300,400' rel='stylesheet' type='text/css'>
<link rel="stylesheet" type="text/css" href="css/styles.css">

2. 引入JS

<script src="http://libs.useso.com/js/html5shiv/3.7/html5shiv.min.js"></script>
<script type="text/javascript" src="js/jquery-2.1.1.min.js"></script>

3. HTML代码

<div class="com">
	<div class="com__content">
		<section class="com__section com__section--text">
			<p class="animate slideInLeft delay-3">适用浏览器:360、FireFox、Chrome、Safari、Opera、傲游、搜狗、世界之窗. 不支持IE8及以下浏览器。</p>
			<p>来源:<a href="http://www.51qianduan.com/" target="_blank"</a></p>
		</section>
		<section class="com__section com__section--text com__section--text-img">
			<div class="com__section-half">
				<h1 class="animate slideInLeft">Communication Design</h1>
				<p class="animate slideInLeft delay-2">Communication design is a mixed discipline between design and information-development which is concerned with how media intermission such as printed, crafted, electronic media or presentations communicate with people.</p>
			</div>
			<div class="com__section-half">
				<img class="animate slideInRight delay-3" src="world.svg" alt="" />
			</div>
		</section>
		<section class="com__section com__section--text centered">
			<h1 class="animate scaleIn"></h1>
			<img class="animate scaleIn delay-3" src="world.svg" alt="" />
		</section>
		<section class="com__section com__section--text">
			<h1 class="animate slideInLeft ">Communication Design</h1>
			<p class="animate slideInLeft delay-3">Communication design is a mixed discipline between design and information-development which is concerned with how media intermission such as printed, crafted, electronic media or presentations communicate with people.</p>
		</section>
		<section class="com__section com__section--text com__section--text-img">
			<div class="com__section-half">
				<h1 class="animate slideInLeft">Communication Design</h1>
				<p class="animate slideInLeft delay-2">Communication design is a mixed discipline between design and information-development which is concerned with how media intermission such as printed, crafted, electronic media or presentations communicate with people.</p>
			</div>
			<div class="com__section-half">
				<img class="animate slideInRight delay-3" src="world.svg" alt="" />
			</div>
		</section>
		<section class="com__section com__section--text centered">
			<h1 class="animate scaleIn">Communication Design</h1>
			<img class="animate scaleIn delay-3" src="world.svg" alt="" />
		</section>
		<section class="com__section com__section--text">
			<h1 class="animate slideInLeft ">Communication Design</h1>
			<p class="animate slideInLeft delay-3">Communication design is a mixed discipline between design and information-development which is concerned with how media intermission such as printed, crafted, electronic media or presentations communicate with people.</p>
		</section>
	</div>
	<nav class="com__nav">
		<ul class="com__nav-list">
			<li class="com__nav-item">
				<a href="" class="com__nav-link">
					<span class="blue-line animate scaleInLeft delay-2"></span>
					<span class="white-line animate scaleInLeft delay-4"></span>
					<span class="white-line animate scaleInLeft delay-5"></span>
				</a>
			</li>
			<li class="com__nav-item">
				<a href="" class="com__nav-link flex-row">
					<div class="com__section-half">
						<span class="blue-line animate scaleInLeft delay-3"></span>
						<span class="white-line animate scaleInLeft delay-4"></span>
					</div>
					<div class="com__section-half">
						<span class="white-circle animate slideInRight delay-5"></span>
					</div>
				</a>
			</li>
			<li class="com__nav-item">
				<a href="" class="com__nav-link centered">
					<span class="blue-line animate scaleIn delay-3"></span>
					<span class="white-circle animate scaleIn delay-5"></span>
				</a>
			</li>
			<li class="com__nav-item">
				<a href="" class="com__nav-link">
					<span class="blue-line animate scaleInLeft delay-2"></span>
					<span class="white-line animate scaleInLeft delay-4"></span>
					<span class="white-line animate scaleInLeft delay-5"></span>
				</a>
			</li>
			<li class="com__nav-item">
				<a href="" class="com__nav-link flex-row">
					<div class="com__section-half">
						<span class="blue-line animate scaleInLeft delay-3"></span>
						<span class="white-line animate scaleInLeft delay-4"></span>
					</div>
					<div class="com__section-half">
						<span class="white-circle animate slideInRight delay-5"></span>
					</div>
				</a>
			</li>
			<li class="com__nav-item">
				<a href="" class="com__nav-link centered">
					<span class="blue-line animate scaleIn delay-3"></span>
					<span class="white-circle animate scaleIn delay-5"></span>
				</a>
			</li>
			<li class="com__nav-item">
				<a href="" class="com__nav-link">
					<span class="blue-line animate scaleInLeft delay-2"></span>
					<span class="white-line animate scaleInLeft delay-4"></span>
					<span class="white-line animate scaleInLeft delay-5"></span>
				</a>
			</li>
		</ul>
	</nav>
</div>
<script type="text/javascript">
var link = $('.com__nav-link');
var linkParent = link.parent('li');
var section = $('.com__section');
var sectionContent = section.find('*');
var switchTab = function () {
	var p = $(this).parent('li');
	var i = p.index();
	var s = section.eq(i);
	var c = s.find('*');
	section.removeClass('active');
	sectionContent.removeAttr('style');
	s.addClass('active');
	c.css({
		transform: 'none',
		opacity: 1
	});
	linkParent.removeClass('active');
	p.addClass('active');
	return false;
};
link.on('click', switchTab);
function activeFirst() {
	section.first().addClass('active');
	section.first().find('*').css({
		transform: 'none',
		opacity: 1
	});
	linkParent.first().addClass('active');
}
activeFirst();
</script>



用户评论
大牛,别默默的看了,快登录帮我点评一下吧!:)      登录 | 注册


热门标签: flash导航菜单 flash导航条 flash导航 flash菜单 flash下拉菜单 flash下拉导航菜单 h5动画导航 h5动画菜单 html5动画导航 html5动画菜单 收缩菜单 收缩导航 滚动导航菜单 滚动菜单 滚动导航 右键菜单 滑动导航菜单 滑动导航 滑动菜单 导航切换 菜单切换 浮动菜单 浮动导航 滑动 滑块 滑动门 触屏滑动 滑动插件 滑块插件 滑动选项卡 滑动切换 滚动切换 滚动条切换 选项卡切换 选项卡 切换 tab切换 页面切换 选项卡插件 切换插件 滑动手风琴 导航菜单 导航条 菜单栏 导航栏 分类导航 响应式导航条 响应式导航 滑动选项卡 滑动切换 侧边菜单 侧边导航 选项卡自动切换 导航菜单插件 导航插件 菜单插件

×
×

注册

官方QQ群

扫描上面二维码加微信群

官方QQ群

jQuery/js讨论群
群号:642649996
Css3+Html5讨论群
群号:322131262

加群请备注:从官网了解到