2018-10-10 22:03:03 +00:00
|
|
|
|
---
|
|
|
|
|
id: 587d78af367417b2b2512b04
|
|
|
|
|
challengeType: 3
|
2019-12-22 20:24:13 +00:00
|
|
|
|
forumTopicId: 301144
|
2020-10-01 15:54:21 +00:00
|
|
|
|
title: 制作一个产品登录页
|
2018-10-10 22:03:03 +00:00
|
|
|
|
---
|
|
|
|
|
|
|
|
|
|
## Description
|
2019-12-22 20:24:13 +00:00
|
|
|
|
<section id='description'>
|
|
|
|
|
<strong>目标:</strong>使用 <a href='https://codepen.io' target='_blank'>CodePen.io</a> 搭建一个与这个功能上相似的 app:<a href='https://codepen.io/freeCodeCamp/full/RKRbwL' target='_blank'>https://codepen.io/freeCodeCamp/full/RKRbwL</a>。
|
|
|
|
|
在满足以下<a href='https://en.wikipedia.org/wiki/User_story' target='_blank'>需求</a>并通过所有测试的前提下,你可以根据自己的喜好来美化你的 app。
|
|
|
|
|
你可以使用 HTML、JavaScript 以及 CSS 来完成项目。由于目前你只学到了 CSS 课程,所以我们建议你只使用 CSS 来完成这个项目,同时巩固一下你之前所学的内容。你也可以使用 Bootstrap 或者 SASS。我们不推荐你在这个项目中使用其他技术(比如 jQurey、React、Angular 或 Vue),否则,如果在编码中出现问题,你需要自行解决。在后续的其他项目中,你将有机会使用各种技术栈(比如 React)。如果你在使用上述推荐的技术栈编码的过程中发现问题,请提交给我们来处理。祝你编码愉快!
|
|
|
|
|
<strong>需求 1:</strong>我的产品主页应该有<code>id="header"</code>的<code>header</code>元素。
|
|
|
|
|
<strong>需求 2:</strong>在<code>header</code>元素内应该有个<code>id="header-img"</code>的图像,这里通常用来放置一个公司的 logo。
|
|
|
|
|
<strong>需求 3:</strong>在<code>#header</code>元素内,我需要能看见对应带有<code>id="nav-bar"</code>的<code>nav</code>元素。
|
|
|
|
|
<strong>需求 4:</strong>我可以在<code>nav</code>元素中看见至少三个能点击的元素,每个都有类名<code>nav-link</code>
|
|
|
|
|
<strong>需求 5:</strong>当我在<code>nav</code>元素内点击<code>.nav-link</code>按钮,会跳转到产品主页的相应部分。
|
|
|
|
|
<strong>需求 6:</strong>我可以看到一个<code>id="video"</code>的嵌入式视频。
|
|
|
|
|
<strong>需求 7:</strong>我的产品主页有一个<code>id="form"</code>的<code>form</code>元素。
|
|
|
|
|
<strong>需求 8:</strong>我可以在对应<code>id="email"</code>的<code>input</code>区域内填写我的邮箱。
|
|
|
|
|
<strong>需求 9:</strong>在<code>#email</code>输入框内应有描述该区域用途的占位符文字。
|
|
|
|
|
<strong>需求 10:</strong><code>#email</code>输入框应该用 HTML5 验证来确认输入的内容是否为邮箱。
|
|
|
|
|
<strong>需求 11:</strong>在表单中,有一个对应<code>id="submit"</code>的<code>input</code>提交按钮。
|
2020-03-03 13:41:15 +00:00
|
|
|
|
<strong>需求 12:</strong>当我点击<code>#submit</code>元素,邮箱会被提交到一个静态页面 (使用这个模拟 URL: <a href='https://www.freecodecamp.com/email-submit' target='_blank'>https://www.freecodecamp.com/email-submit</a>)。
|
2019-12-22 20:24:13 +00:00
|
|
|
|
<strong>需求 13:</strong>导航栏应保持在视窗的顶部。
|
|
|
|
|
<strong>需求 14:</strong>我的产品主页应至少有一个媒体查询。
|
|
|
|
|
<strong>需求 15:</strong>至少使用一次 flexbox 布局。
|
|
|
|
|
你可以通过 fork 这个项目 <a href='http://codepen.io/freeCodeCamp/pen/MJjpwO' target='_blank'>CodePen</a> 来构建你的项目,也可以使用此 CDN 链接在任何你喜欢的环境中运行测试:<code>https://gitcdn.link/repo/freeCodeCamp/testable-projects-fcc/master/build/bundle.js</code>。
|
2020-03-03 13:41:15 +00:00
|
|
|
|
完成之后,将你的 URL 提交到相应的项目,并测试通过。
|
2019-12-22 20:24:13 +00:00
|
|
|
|
</section>
|
2018-10-10 22:03:03 +00:00
|
|
|
|
|
|
|
|
|
## Instructions
|
2019-12-22 20:24:13 +00:00
|
|
|
|
<section id='instructions'>
|
|
|
|
|
|
2018-10-10 22:03:03 +00:00
|
|
|
|
</section>
|
|
|
|
|
|
|
|
|
|
## Tests
|
|
|
|
|
<section id='tests'>
|
|
|
|
|
|
|
|
|
|
```yml
|
|
|
|
|
tests: []
|
|
|
|
|
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
</section>
|
|
|
|
|
|
|
|
|
|
## Challenge Seed
|
|
|
|
|
<section id='challengeSeed'>
|
|
|
|
|
|
|
|
|
|
</section>
|
|
|
|
|
|
|
|
|
|
## Solution
|
|
|
|
|
<section id='solution'>
|
|
|
|
|
|
|
|
|
|
```js
|
|
|
|
|
// solution required
|
|
|
|
|
```
|
2019-12-22 20:24:13 +00:00
|
|
|
|
|
2018-10-10 22:03:03 +00:00
|
|
|
|
</section>
|
2019-12-22 20:24:13 +00:00
|
|
|
|
|