Skip to content

Commit 01f160f

Browse files
committed
add input box for name
1 parent ff7b9d0 commit 01f160f

2 files changed

Lines changed: 20 additions & 5 deletions

File tree

Form-Controls/index.html

Lines changed: 20 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,22 +6,37 @@
66
<title>My form exercise</title>
77
<meta name="description" content="" />
88
<meta name="viewport" content="width=device-width, initial-scale=1" />
9+
<link rel="stylesheet" href="styles.css">
910
</head>
1011
<body>
1112
<header>
1213
<h1>Product Pick</h1>
1314
</header>
1415
<main>
1516
<form>
16-
<!-- write your html here-->
17+
<div>
18+
<label for="name">Name: </label>
19+
<input id="name" type="text" pattern="[^\s]\s?[^\s]+"/>
20+
</div>
1721
<!--
18-
try writing out the requirements first as comments
19-
this will also help you fill in your PR message later-->
22+
What is the customer's name? I must collect this data and ensure it contains at least two non-space characters.
23+
What is the customer's email? I must make sure the email is valid. Email addresses follow a consistent pattern.
24+
What colour should this T-shirt be? I must provide 3 options. How will I ensure they do not choose other colours?
25+
What size does the customer want? I must provide the following 6 options: XS, S, M, L, XL, XXL
26+
---
27+
HTML
28+
My form is semantic HTML.
29+
All inputs have associated labels.
30+
My Lighthouse Accessibility score is 100.
31+
I require a valid name.
32+
I require a valid email.
33+
I require one colour from a defined set of 3 colours.
34+
I require one size from a defined set of 6 sizes.
35+
-->
2036
</form>
2137
</main>
2238
<footer>
23-
<!-- change to your name-->
24-
<p>By HOMEWORK SOLUTION</p>
39+
<p>By Liam Greenfield</p>
2540
</footer>
2641
</body>
2742
</html>

Form-Controls/styles.css

Whitespace-only changes.

0 commit comments

Comments
 (0)