-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
323 lines (311 loc) · 12.6 KB
/
index.html
File metadata and controls
323 lines (311 loc) · 12.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<!--SEO-->
<title>Multi-Step Form | Frontend Mentor Challenge by Zdravko93</title>
<meta name="description" content="A responsive, accessible multi-step form built by Zdravko93 for a Frontend Mentor challenge. Includes validation, plan selection, add-ons, and smooth UX." />
<meta name="author" content="Zdravko93" />
<meta name="robots" content="index, follow" />
<!-- Canonical URL -->
<link rel="canonical" href="https://zdravko93.github.io/multi-step-form-validation-project/">
<!-- Open Graph -->
<meta property="og:type" content="website" />
<meta property="og:url" content="https://zdravko93.github.io/multi-step-form-validation-project/" />
<meta property="og:title" content="Multi-Step Form | Frontend Mentor Challenge by Zdravko93" />
<meta property="og:description" content="A multi-step validation form with responsive design, accessibility, and smooth user experience." />
<meta property="og:image" content="https://zdravko93.github.io/multi-step-form-validation-project/multi-step-form.png" />
<!-- Twitter Card -->
<meta name="twitter:card" content="summary_large_image" />
<meta name="twitter:title" content="Multi-Step Form | Frontend Mentor Project" />
<meta name="twitter:description" content="A responsive and accessible multi-step form built as a challenge project." />
<meta name="twitter:image" content="https://zdravko93.github.io/multi-step-form-validation-project/multi-step-form.png" />
<!--FONTS & STYLES-->
<link
rel="icon"
type="image/png"
sizes="32x32"
href="./assets/images/favicon-32x32.png"
/>
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link
href="https://fonts.googleapis.com/css2?family=Ubuntu:ital,wght@0,300;0,400;0,500;0,700;1,300;1,400;1,500;1,700&display=swap"
rel="stylesheet"
/>
<link rel="stylesheet" href="styles.css" />
<!--JAVASCRIPT-->
<script type="module" src="js/app.js" defer></script>
<!-- JSON-LD Sructured Data -->
<script type="application/ld+json">
{
"@context": "https://schema.org/",
"@type": "SoftwareSourceCode",
"name": "Multi-Step Form",
"author": {
"@type": "Person",
"name": "Zdravko93"
},
"description": "Responsive and accessible multi-step form built as a Frontend Mentor challenge.",
"programmingLanguage": "JavaScript",
"codeRepository": "https://github.com/Zdravko93/multi-step-form-validation-project",
"keywords": [
"multi-step form",
"form validation",
"frontend mentor",
"vanilla js",
"responsive form ui"
]
}
</script>
</head>
<body>
<main class="container">
<!-- Sidebar start -->
<nav class="progress-track">
<ul class="progress-track__list">
<li class="progress-track__list__item">
<div class="circle active">1</div>
<div class="step-description">
<span>Step 1</span>
<b>Your info</b>
</div>
</li>
<li class="progress-track__list__item">
<div class="circle">2</div>
<div class="step-description">
<span>Step 2</span>
<b>Select Plan</b>
</div>
</li>
<li class="progress-track__list__item">
<div class="circle">3</div>
<div class="step-description">
<span>Step 3</span>
<b>Add-ons</b>
</div>
</li>
<li class="progress-track__list__item">
<div class="circle">4</div>
<div class="step-description">
<span>Step 4</span>
<b>Summary</b>
</div>
</li>
</ul>
</nav>
<!-- Sidebar end -->
<!-- FORM CONTAINER -->
<section class="form-container">
<!-- STEP 1 START -->
<section class="step step-1" aria-labelledby="step-1-heading">
<div class="headers">
<h1 class="title">Personal info</h1>
<p>
Please provide your name, email <span class="line-break"></span>address, and phone number.
</p>
</div>
<form>
<div class="input-control">
<div class="label">
<label for="name">Name <span aria-hidden="true">*</span></label>
<p id="name-error" class="error" aria-live="polite">This field is required</p>
</div>
<input type="text" id="name" placeholder="e.g. Stephen King" required
aria-describedby="name-error"
/>
</div>
<div class="input-control">
<div class="label">
<label for="email">Email Address <span aria-hidden="true">*</span></label>
<p id="email-error" class="error" aria-live="polite">This field is required</p>
</div>
<input
type="text"
id="email"
placeholder="e.g. stephenking@lorem.com"
required
aria-describedby="email-error"
/>
</div>
<div class="input-control">
<div class="label">
<label for="phone">Phone Number <span aria-hidden="true">*</span></label>
<p id="phone-error" class="error">This field is required</p>
</div>
<input type="tel" id="phone" placeholder="e.g. +1 234 567 890" required
aria-describedby="phone-error"
/>
</div>
</form>
<div class="form-buttons">
<button type="submit" class="next-step-button">Next Step</button>
</div>
</section>
<!-- STEP 1 END -->
<!-- STEP 2 START -->
<section class="step step-2" aria-labelledby="step-2-heading">
<div class="headers">
<h2 class="title">Select your plan</h2>
<p>You have the option of monthly or yearly billing.</p>
</div>
<div class="billing-options">
<div class="option" tabindex="0">
<img src="assets/images/icon-arcade.svg" alt="Arcade subscription plan" />
<div class="option__price">
<b>Arcade</b>
<span>$9/mo</span>
<span class="yearly-price hidden">$90/yr</span>
</div>
</div>
<div class="option" tabindex="0">
<img src="assets/images/icon-advanced.svg" alt="Advanced subscription plan" />
<div class="option__price">
<b>Advanced</b>
<span>$12/mo</span>
<span class="yearly-price hidden">$120/yr</span>
</div>
</div>
<div class="option" tabindex="0">
<img src="assets/images/icon-pro.svg" alt="Pro subscription plan" />
<div class="option__price">
<b>Pro</b>
<span>$15/mo</span>
<span class="yearly-price hidden">$150/yr</span>
</div>
</div>
</div>
<div class="option__selected">
<div class="option__selected__switch__group">
<span class="option__selected__element__monthly active"
>Monthly</span
>
<label class="switch" for="toggle">
<input type="checkbox" id="toggle" />
<span class="slider round"></span>
</label>
<span class="option__selected__element__yearly">Yearly</span>
</div>
</div>
<div class="billing-error">Please select a billing option</div>
<div class="form-buttons">
<button type="button" class="previous-step-button previous-button-helper-class">Go Back</button>
<button type="submit" class="next-step-button next-button-helper-class">Next Step</button>
</div>
</section>
<!--STEP 2 END-->
<!-- STEP 3 START-->
<section class="step step-3" aria-labelledby="step-3-heading">
<div class="headers">
<h2 class="title">Pick add-ons</h2>
<p>Add-ons help enhance your gaming experience.</p>
</div>
<div class="services-options">
<div class="services-option">
<label for="option-1">
<input type="checkbox" id="option-1" />
<span class="checkmark"></span>
</label>
<div class="services-details">
<b>Online service</b>
<p>Access to multiplayer games</p>
</div>
<div class="service-price-wrap">
<span class="service-price">+$3/mo</span>
<span class="price-toggle hidden">+10$/yr</span>
</div>
</div>
<div class="services-option">
<label for="option-2">
<input type="checkbox" id="option-2" />
<span class="checkmark"></span>
</label>
<div class="services-details">
<b>Larger Storage</b>
<p>Extra 1TB of cloud save</p>
</div>
<div class="service-price-wrap">
<span class="service-price">+$2/mo</span>
<span class="price-toggle hidden">+20$/yr</span>
</div>
</div>
<div class="services-option">
<label for="option-3">
<input type="checkbox" id="option-3" />
<span class="checkmark"></span>
</label>
<div class="services-details">
<b>Customizable profile</b>
<p>Custom theme on your profile</p>
</div>
<div class="service-price-wrap">
<span class="service-price">+$2/mo</span>
<span class="price-toggle hidden">+14$/yr</span>
</div>
</div>
</div>
<div class="form-buttons">
<button type="button" class="previous-step-button previous-button-helper-class">Go Back</button>
<button type="submit" class="next-step-button next-button-helper-class">Next Step</button>
</div>
</section>
<!-- STEP 3 END-->
<!-- STEP 4 START -->
<section class="step step-4" aria-labelledby="step-4-heading">
<div class="headers">
<h2 class="title">Finishing up</h2>
<p>Double-check everything looks OK before confirming.</p>
</div>
<div class="options-final">
<div class="options-final__helper__background">
<div class="options-final__payment__plan">
<!-- HERE GOES JAVASCRIPT -->
<!-- <div>
<p class="charge"></p>
<p class="charge-price"></p>
</div> -->
<hr>
</div>
<div class="options-final__list">
<!-- HERE GOES JAVASCRIPT -->
<!-- <div class="options-final__item">
<p class="item"></p>
<p class="price"></p>
</div> -->
</div>
</div>
<div class="pricing-total">
<!-- HERE GOES JAVASCRIPT -->
<!-- <div>
<p>Total</p>
<b>+$12/mo</b>
</div> -->
</div>
<div class="form-buttons">
<button type="button" class="previous-step-button previous-button-helper-class">Go Back</button>
<button type="submit" class="next-button-helper-class confirm-button">Confirm</button>
</div>
</section>
<!-- STEP 5 START-->
<section class="step step-5">
<img src="assets/images/icon-thank-you.svg" alt="Thank you illustration" />
<div class="headers" aria-live="polite">
<h2 class="title">Thank you!</h2>
<p>
Thanks for confirming your subscription! We hope you have fun
using our platform. If you ever need support, please feel free to
email us at support@loremgaming.com.
</p>
</div>
</section>
</section>
</main>
<div class="attribution">
Challenge by
<a href="https://www.frontendmentor.io?ref=challenge" target="_blank" rel="noopener noreferrer"
>Frontend Mentor</a
>. Coded by <a href="https://github.com/Zdravko93" target="_blank">Zdravko</a>.
</div>
</body>
</html>