Skip to content

Commit 1c10cea

Browse files
committed
add main module
2 parents adcfc33 + 5ea8f07 commit 1c10cea

23 files changed

Lines changed: 574 additions & 177 deletions

File tree

‎README.md‎

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,14 @@
22

33
[百度前端技术学院](http://ife.baidu.com) 热身训练作品
44

5-
点击[这里](http://hashcoding.github.io)进入
5+
点击[这里](http://hashcoding.github.io)进入
6+
7+
## 约定
8+
9+
* 各自完成组件,并且在组件下的 `example` 文件夹下完成测试
10+
* 组件完成后在填充到 `index.html` 完成测试
11+
* 大家一起 `review`
12+
13+
## ToDo
14+
15+
* 打包构建
Lines changed: 205 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,205 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8">
5+
<meta name="author" content="summer">
6+
<link rel="stylesheet" href="../../reset/reset.css">
7+
<link rel="stylesheet" href="../firstscreen.css">
8+
<script src="../../onload/onload.js"></script>
9+
<script src="../../EventUtil/EventUtil.js"></script>
10+
<script src="../firstscreen.js"></script>
11+
<title>HashCoding--百度IFE</title>
12+
</head>
13+
<body>
14+
<div class="container">
15+
<section class="section firstscreen">
16+
<div class="main-team-ife">
17+
<img src="../../logo/ife-logo.png" alt="">
18+
</div>
19+
<div class="main-team-name">
20+
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:a="http://ns.adobe.com/AdobeSVGViewerExtensions/3.0/" x="0px" y="0px" width="100%" height="400px" viewBox="-82.188 -95.86 800 400" enable-background="new -82.188 -95.86 800 300" xml:space="preserve">
21+
<path fill="none" stroke="#FFFFFF" stroke-width="4" stroke-miterlimit="10" d="M10.174,75.437c0.36-0.12,0.6-0.48,0.72-0.721
22+
l9.84-56.157l-6.479-0.36c0.6-3.479,1.2-6.84,1.8-10.199c4.8,0,11.879,0,17.159,0c5.76,0,12.12,0,16.799,0
23+
c-0.48,3.359-1.2,6.72-1.92,10.199l-7.2,0.36c-0.36,0-0.48,0.24-0.48,0.6l-3.6,20.879c-0.12,0.36,0.24,0.48,0.48,0.48l25.199,0.12
24+
l3.72-22.079l-7.439-0.36c0.6-3.479,1.32-6.84,1.92-10.199c5.04,0,12,0,17.999,0c4.92,0,11.04,0,15.6,0
25+
c-0.6,3.359-1.2,6.839-1.92,10.199l-5.88,0.36c-0.24,0-0.48,0.24-0.48,0.479l-10.2,56.278l6.48,0.479
26+
c-0.6,3.36-1.08,6.84-1.68,10.32c-4.56,0-11.16-0.12-16.079-0.12c-6.24,0-13.08,0.12-18.599,0.12c0.6-3.48,1.32-6.96,1.92-10.32
27+
l8.159-0.359c0.36,0,0.48-0.24,0.6-0.721l3.84-22.798c0-0.48,0-0.6-0.36-0.6l-25.439,0.24l-4.32,23.759l7.8,0.479
28+
c-0.6,3.36-1.2,6.84-1.92,10.32c-4.68,0-11.399-0.12-17.04-0.12c-5.28,0-11.759,0.12-16.799,0.12c0.6-3.48,1.2-6.96,1.8-10.32
29+
L10.174,75.437z"/>
30+
<path fill="none" stroke="#FFFFFF" stroke-width="4" stroke-miterlimit="10" d="M125.854,74.597
31+
c-9.84,9.959-16.919,12.719-21.599,12.84c-2.88-0.48-8.64-3.721-10.56-7.92c-0.96-1.92-1.44-3.84-1.44-6.24
32+
c0-3.359,1.08-9.959,3.12-15.719c3.24-9.24,12.6-25.559,25.919-25.559c4.8,0,9,1.56,12.72,4.8h0.6l3.12-6.12
33+
c4.8,1.32,9.479,2.64,14.04,4.2c-3.12,11.399-7.56,30.119-9.72,40.078c-0.12,0.48,0.24,0.721,0.72,0.721
34+
c0.72,0,3.24-0.36,6.239-1.08c0.6,3.119,0.96,6.24,1.2,9.479c-5.52,1.8-13.199,3-19.679,3c-0.6,0-3.6-1.92-4.44-3.601
35+
c0.12-1.799,0.48-5.279,0.96-8.52L125.854,74.597z M115.174,53.838c-2.64,6.12-4.32,12.839-4.32,16.439
36+
c0,2.28,0.96,3.961,2.52,3.961c3.48,0,12.719-9.48,14.159-14.16c0.6-1.92,2.28-8.879,3.36-13.799c-0.96-1.68-3.36-3-6-3
37+
C120.574,43.278,117.094,49.278,115.174,53.838z"/>
38+
<path fill="none" stroke="#FFFFFF" stroke-width="4" stroke-miterlimit="10" d="M191.97,44.718c-0.12-0.6-0.24-1.08-0.72-1.44
39+
c-1.08-0.72-3.24-1.32-5.04-1.32s-4.08,0.24-5.52,1.08c-1.56,0.96-2.4,2.28-2.4,4.08c0,3,4.44,4.2,9.24,6
40+
c7.919,3,13.08,6.839,13.08,14.159c0,7.561-3.84,12.721-9.479,16.08c-3.24,1.92-9.12,3.84-17.879,3.84
41+
c-6.24,0-12.479-0.84-15.959-2.28c0.36-5.999,0.84-11.999,1.08-17.399c3-0.359,6.12-0.48,9.12-0.6l1.2,7.32
42+
c0.12,0.479,0.24,1.079,0.6,1.319c1.68,0.96,4.2,1.68,6.6,1.68c2.28,0,4.2-0.239,5.52-0.96c0.96-0.6,1.92-1.8,1.92-3.84
43+
c0-3-2.52-4.439-7.8-6.359c-7.8-3-14.759-6.6-14.759-15.24c0-8.279,6.959-13.799,11.52-15.839c4.92-2.16,10.439-3,16.799-3
44+
c5.64,0,11.52,1.08,14.159,2.399c-0.359,5.28-0.72,11.16-1.08,16.08c-2.52,0.36-6.119,0.48-9.239,0.6L191.97,44.718z"/>
45+
<path fill="none" stroke="#FFFFFF" stroke-width="4" stroke-miterlimit="10" d="M213.09,15.199c-0.12-3.24-0.12-6.479,0-9.719
46+
C224.73,4.16,236.009,2,236.969,2c0.84,0,4.439,3,5.52,5.04c-1.319,5.16-7.079,28.918-9.359,38.878l0.84,0.36
47+
c9.6-11.16,18.119-14.16,22.799-14.279c3.24,0.479,7.56,3.479,9.24,6.839c0.84,1.44,1.08,3,1.08,4.68
48+
c0,4.319-2.641,16.918-7.56,31.678c-0.12,0.48,0,0.961,0.479,0.961c1.44,0,3.72-0.361,6.6-0.961c0.36,3,0.601,6.24,0.72,9.359
49+
c-4.92,1.44-13.919,2.521-22.199,2.521c-0.84,0-4.439-2.88-5.039-5.28c1.8-6.119,4.68-16.439,5.52-19.919
50+
c0.72-2.64,2.76-10.08,2.76-12c0-1.08-0.96-2.28-2.16-2.28c-5.64,0-14.879,12.6-16.679,19.919c-1.08,4.439-3.36,13.8-4.44,18.479
51+
c-5.999,0.12-11.759,0.12-17.639,0.12c2.52-11.279,11.999-56.518,15.119-71.397L213.09,15.199z"/>
52+
<path fill="none" stroke="#FFFFFF" stroke-width="4" stroke-miterlimit="10" d="M329.968,22.519c0-0.6-0.121-1.32-0.6-1.68
53+
c-1.682-1.2-4.08-1.8-6.602-1.8c-3.6,0-7.918,1.08-11.519,4.32c-7.199,6.479-11.639,17.879-11.639,29.878
54+
c0,6.119,0.479,11.039,4.199,15.6c2.521,3.24,7.439,5.16,13.08,5.16c5.039,0,14.279-2.041,18-3.48c0.24,3.6,0.119,8.039,0,11.52
55+
c-7.92,3-18.36,5.16-23.879,5.16c-10.56,0-17.64-3.359-23.399-8.16c-6.479-5.399-9.239-14.398-9.239-23.759
56+
c0-17.04,9.479-31.918,20.759-39.958c8.76-6.359,18.72-8.52,29.398-8.52c7.561,0,13.201,1.2,15.6,2.52
57+
c-0.719,8.16-1.68,16.679-2.639,24.959c-3.721,0.24-7.561,0.36-11.16,0.36L329.968,22.519z"/>
58+
<path fill="none" stroke="#FFFFFF" stroke-width="4" stroke-miterlimit="10" d="M386.126,81.677c-4.68,3.719-10.68,5.52-19.561,5.52
59+
c-9.838,0-14.998-4.2-17.518-7.32c-1.441-1.799-3.721-6.719-3.721-11.639c0-12.96,5.279-22.799,12-28.439
60+
c5.879-4.919,12.479-7.799,21.838-7.799c9.121,0,13.801,3.24,17.041,7.56c1.318,1.92,3.84,6.72,3.84,13.199
61+
C400.046,65.478,393.565,75.796,386.126,81.677z M375.446,74.957c2.16-3.719,5.4-16.679,5.4-27.479c0-1.56-0.24-3.6-0.842-4.8
62+
c-0.719-1.2-1.92-2.04-3.479-2.04c-1.92,0-3.48,0.479-5.279,2.64c-3.121,3.72-6.721,15.479-6.721,25.678
63+
c0,2.521,0.24,4.92,0.961,6.721c0.479,1.199,2.039,2.879,4.199,2.879C371.726,78.556,373.886,77.597,375.446,74.957z"/>
64+
<path fill="none" stroke="#FFFFFF" stroke-width="4" stroke-miterlimit="10" d="M439.886,74.477c-9,9.12-16.439,12.839-21.6,12.96
65+
c-2.879-0.36-8.279-3.36-10.799-7.801c-1.08-1.799-1.439-4.079-1.439-5.999c0-3.601,1.199-11.159,3.479-17.399
66+
c3.361-9.24,12-24.239,25.32-24.239c5.039,0,8.879,1.439,11.279,3.359h0.84c1.199-6.12,3-15.119,3.959-20.519l-10.08-0.12
67+
c-0.119-3.36-0.119-6.48,0-9.72c15.961-1.56,22.561-3,24-3c0.959,0,4.561,2.88,5.641,5.04c-1.32,6.6-11.881,58.077-13.92,67.917
68+
c-0.121,0.48,0.24,0.721,0.719,0.721c0.721,0,3-0.24,6.361-1.08c0.6,3.119,1.08,6.359,1.318,9.6
69+
c-6.479,1.92-13.559,2.88-20.279,2.88c-0.84,0-3.6-1.92-4.559-3.601c0-1.68,0.48-5.159,0.84-8.76L439.886,74.477z M441.806,59.837
70+
c0.6-2.039,1.92-9,2.879-13.919c-1.559-1.68-3.719-2.64-5.998-2.64c-4.201,0-7.68,5.16-9.84,10.439
71+
c-2.16,5.04-4.201,12.479-4.201,16.44c0,2.279,0.84,4.08,2.521,4.08C430.886,74.238,439.886,64.638,441.806,59.837z"/>
72+
<path fill="none" stroke="#FFFFFF" stroke-width="4" stroke-miterlimit="10" d="M471.325,45.078c0-3.36,0-6.6,0.121-9.839
73+
c9.119-1.08,21.238-3.24,23.398-3.24c0.961,0,4.561,3,5.641,4.8c-2.16,10.199-7.441,34.199-8.4,38.638
74+
c-0.24,0.48-0.119,0.84,0.359,0.84c1.201,0,4.32-0.359,7.68-1.199c0.24,3.119,0.6,6.359,0.84,9.479
75+
c-5.398,1.44-11.998,2.521-22.318,2.521c-0.961,0-4.801-3.36-5.641-5.399c2.521-11.76,5.76-27.359,7.561-36.479L471.325,45.078z
76+
M505.405,14.12c0,6.839-5.041,10.799-10.561,10.799c-6.359,0-10.08-4.92-10.08-9.72c0-5.399,4.561-9.959,10.801-9.959
77+
C502.884,5.24,505.405,10.04,505.405,14.12z"/>
78+
<path fill="none" stroke="#FFFFFF" stroke-width="4" stroke-miterlimit="10" d="M509.005,45.558c-0.121-3.36-0.121-6.6,0-9.839
79+
c9.119-1.32,19.559-3.72,20.998-3.72c0.961,0,4.561,2.52,5.641,4.56c-0.359,2.4-1.08,6-1.801,9.72l1.441,0.36
80+
c8.76-10.799,17.639-14.52,22.438-14.639c3.361,0.36,7.441,3,9.84,7.08c0.721,1.32,0.961,3.24,0.961,4.56
81+
c0,4.68-2.52,16.199-7.561,31.799c-0.119,0.48-0.119,0.96,0.361,0.96c1.199,0,4.318-0.479,6.959-1.08c0.359,3,0.6,6.239,0.721,9.36
82+
c-5.16,1.439-11.641,2.399-22.199,2.399c-0.961,0-4.08-2.521-5.281-4.8c1.801-6.48,4.68-17.279,5.521-20.52
83+
c0.719-2.52,2.639-9.359,2.639-11.879c0-1.2-0.84-2.4-2.16-2.4c-5.398,0-14.52,12-16.439,19.799
84+
c-1.199,4.68-3.479,14.04-4.439,18.72c-6,0.12-11.76,0.12-17.76,0.12c2.4-10.8,6.961-31.799,8.641-40.918L509.005,45.558z"/>
85+
<path fill="none" stroke="#FFFFFF" stroke-width="4" stroke-miterlimit="10" d="M608.001,31.999c4.201,0,7.68,0.36,9.84,0.96
86+
c0.48,0.24,1.439,0.24,2.16,0.24c2.039,0,14.639-0.12,18.24-0.24c0,3.359,0,6.6-0.121,10.319c-3.6,0.24-7.559,0.6-10.199,0.72v0.72
87+
c0.6,1.2,1.199,3.96,1.199,6.959c0,6-2.279,10.56-5.16,14.519c-3.238,4.201-11.998,10.92-27.117,9.6
88+
c-1.801,1.201-3.24,2.521-3.24,3.961c0,2.52,6.479,2.52,17.039,3.239c7.32,0.601,10.439,1.2,13.559,3.12
89+
c2.76,1.561,5.881,5.4,5.881,10.799c0,9-11.881,20.16-36.719,20.16c-16.799,0-25.68-3.84-25.68-12.24c0-2.4,0.6-4.799,2.52-5.879
90+
c4.441-2.28,6.602-3.24,12-6.36v-0.72c-4.559-2.4-5.879-5.16-5.879-9.72c0-2.04,1.08-2.521,11.039-8.64v-0.84
91+
c-4.199-2.76-8.639-7.199-8.639-14.52C578.724,46.398,587.962,31.999,608.001,31.999z M604.282,96.676
92+
c-2.4-0.36-10.92-1.2-12.721-1.44c-3.359,2.4-5.398,5.041-5.398,7.801c0,3.719,4.68,5.279,10.318,5.279
93+
c8.041,0,15.359-2.4,15.359-7.32C611.841,97.636,608.601,97.156,604.282,96.676z M602.001,67.877c5.041,0,8.76-10.68,8.76-20.879
94+
c0-1.8-0.24-3.36-0.6-4.439c-0.6-1.68-1.92-2.52-3.959-2.52c-4.801,0-9,9.6-9,22.079C597.202,65.478,599.001,67.877,602.001,67.877z
95+
"/>
96+
</svg>
97+
</div>
98+
<p class="main-team-word">
99+
<i>Established By 5 Front-End Web Developers</i>
100+
</p>
101+
<div id="arow_down">
102+
<i class="down">&#xe682;</i>
103+
</div>
104+
</section>
105+
<section class="section intro">
106+
<h3 class="section-title">团队成员</h3>
107+
<div class="intro-main">
108+
<ul class="member-header-list">
109+
<li class="mhl-item"><a href="#"></a></li>
110+
<li class="mhl-item"><a href="#"></a></li>
111+
<li class="mhl-item"><a href="#"></a></li>
112+
<li class="mhl-item"><a href="#"></a></li>
113+
<li class="mhl-item"><a href="#"></a></li>
114+
</ul>
115+
<ul class="member-content-list">
116+
<li class="mcl-item">
117+
</li>
118+
<li class="mcl-item"></li>
119+
<li class="mcl-item"></li>
120+
<li class="mcl-item"></li>
121+
<li class="mcl-item"></li>
122+
</ul>
123+
</div>
124+
</section>
125+
<div class="other">
126+
<p>2</p>
127+
<p>3</p>
128+
<p>1</p>
129+
<p>1</p>
130+
<p>1</p>
131+
<p>1</p>
132+
<p>1</p>
133+
<p>1</p>
134+
<p>1</p>
135+
<p>1</p>
136+
<p>1</p>
137+
<p>1</p>
138+
<p>1</p>
139+
<p>1</p>
140+
<p>1</p>
141+
<p>1</p>
142+
<p>1</p>
143+
<p>1</p>
144+
<p>1</p>
145+
<p>1</p>
146+
<p>1</p>
147+
<p>1</p><p>1</p>
148+
<p>1</p>
149+
<p>1</p>
150+
<p>1</p>
151+
<p>1</p>
152+
<p>1</p>
153+
<p>1</p>
154+
<p>1</p>
155+
<p>1</p>
156+
<p>1</p>
157+
<p>1</p><p>1</p>
158+
<p>1</p>
159+
<p>1</p>
160+
<p>1</p>
161+
<p>1</p>
162+
<p>1</p>
163+
<p>1</p>
164+
<p>1</p>
165+
<p>1</p>
166+
<p>1</p>
167+
<p>1</p>
168+
<p>1</p>
169+
<p>1</p>
170+
<p>1</p>
171+
<p>1</p>
172+
<p>1</p>
173+
<p>1</p>
174+
<p>1</p>
175+
<p>1</p>
176+
<p>1</p>
177+
<p>1</p>
178+
<p>1</p>
179+
<p>1</p>
180+
<p>1</p>
181+
<p>1</p>
182+
<p>1</p>
183+
<p>1</p>
184+
<p>1</p>
185+
<p>1</p>
186+
<p>1</p>
187+
<p>1</p>
188+
<p>1</p>
189+
<p>1</p>
190+
<p>1</p>
191+
<p>1</p>
192+
<p>1</p>
193+
<p>1</p>
194+
<p>1</p>
195+
<p>1</p>
196+
<p>1</p>
197+
<p>1</p>
198+
<p>1</p>
199+
<p>1</p>
200+
<p>1</p>
201+
</div>
202+
>>>>>>> 5ea8f07430b19ccc397d259926ce84033dd89f12:components/firstscreen/example/example.html
203+
</div>
204+
</body>
205+
</html>
Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,92 @@
1+
@font-face {font-family: 'iconfont';
2+
src: url('iconfont/iconfont.eot'); /* IE9*/
3+
src: url('iconfont/iconfont.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */
4+
url('iconfont/iconfont.woff') format('woff'), /* chrome、firefox */
5+
url('iconfont/iconfont.ttf') format('truetype'), /* chrome、firefox、opera、Safari, Android, iOS 4.2+*/
6+
url('iconfont/iconfont.svg#iconfont') format('svg'); /* iOS 4.1- */
7+
}
8+
.container {
9+
position: relative;;
10+
height: 100%;
11+
}
12+
section.firstscreen {
13+
height: 100%;
14+
background-color: rgb(27, 188, 155);
15+
overflow: hidden;
16+
position: relative;
17+
padding: 0 10px;
18+
}
19+
.firstscreen path {
20+
stroke-dasharray: 2000;
21+
stroke-dashoffset: 2100;
22+
-webkit-animation: dash 4.3s linear forwards;
23+
-moz-animation: dash 4.3s linear forwards;
24+
animation: dash 4.3s linear forwards;
25+
}
26+
.firstscreen .main-team-ife {
27+
position: absolute;
28+
top: 8%;
29+
left: 10%;
30+
}
31+
.firstscreen .main-team-name {
32+
height: 400px;
33+
position: relative;
34+
top: 44%;
35+
margin-top: -200px;
36+
37+
}
38+
.firstscreen .main-team-word {
39+
font-size: 25px;
40+
line-height: 1.5;
41+
color: #FFFFFF;
42+
text-align: center;
43+
position: relative;
44+
top:40%;
45+
46+
}
47+
48+
.firstscreen #arow_down {
49+
width:100px;
50+
text-align: center;
51+
/*以下代码实现.arow_down的绝对定位下的水平居中*/
52+
margin: 0 auto;
53+
position:absolute;
54+
bottom: 30px;
55+
left: 0;
56+
right: 0;
57+
}
58+
59+
.firstscreen #arow_down a {
60+
text-decoration: none;
61+
}
62+
63+
.firstscreen .down{
64+
font-family:"iconfont" !important;
65+
font-size:25px;
66+
font-style:normal;
67+
color: black;
68+
-webkit-font-smoothing: antialiased;
69+
-webkit-text-stroke-width: 0.2px;
70+
-moz-osx-font-smoothing: grayscale;
71+
}
72+
.firstscreen .down:hover {
73+
cursor: pointer;
74+
}
75+
76+
/* animation hhere */
77+
78+
@keyframes dash {
79+
to {
80+
stroke-dashoffset: 0;
81+
}
82+
}
83+
@-webkit-keyframes dash {
84+
to {
85+
stroke-dashoffset: 0;
86+
}
87+
}
88+
@-moz-keyframes dash {
89+
to {
90+
stroke-dashoffset: 0;
91+
}
92+
}
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
(function(et) {
2+
addLoadListener(_firstscreen);
3+
4+
function _firstscreen() {
5+
var arow = document.getElementById("arow_down"),
6+
h = document.documentElement.clientHeight;
7+
8+
et.addHandler(arow,"click",function(){
9+
console.log(111)
10+
var timerId = setInterval(function() {
11+
window.scrollBy(0,20);
12+
if (document.body.scrollTop > h) {
13+
clearInterval(timerId);
14+
};
15+
},5)
16+
});
17+
};
18+
19+
})(EventUtil);
20+
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
2+
@font-face {font-family: "iconfont";
3+
src: url('iconfont.eot'); /* IE9*/
4+
src: url('iconfont.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */
5+
url('iconfont.woff') format('woff'), /* chrome, firefox */
6+
url('iconfont.ttf') format('truetype'), /* chrome, firefox, opera, Safari, Android, iOS 4.2+*/
7+
url('iconfont.svg#iconfont') format('svg'); /* iOS 4.1- */
8+
}
9+
10+
.iconfont {
11+
font-family:"iconfont" !important;
12+
font-size:16px;
13+
font-style:normal;
14+
-webkit-font-smoothing: antialiased;
15+
-webkit-text-stroke-width: 0.2px;
16+
-moz-osx-font-smoothing: grayscale;
17+
}
18+
.icon-xiangxia:before { content: "\e682"; }
5.05 KB
Binary file not shown.
Lines changed: 39 additions & 0 deletions
Loading
4.77 KB
Binary file not shown.
2.99 KB
Binary file not shown.

0 commit comments

Comments
 (0)