Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

YouTube

A Deceptively Complex Form - HTML and CSS Frontend Mentor

Kevin Powell via YouTube

Overview

Coursera Flash Sale
40% Off Coursera Plus for 3 Months!
Grab it
Learn to build a sophisticated contact form by tackling a Frontend Mentor challenge that demonstrates advanced HTML structure and CSS styling techniques. Start by constructing semantic HTML markup, exploring the debate between form-group containers versus wrapping elements inside labels, and implementing proper fieldset usage for radio button groups. Master form accessibility by adding checkboxes with appropriate labeling and creating a solid foundation for styling. Dive into CSS implementation by establishing the overall form layout, styling various input types, and adding visual indicators like stars for required fields. Discover techniques for styling radio buttons with custom borders and backgrounds, creating effective fieldset layouts, and setting textarea heights without relying on magic numbers. Complete the form by styling submit buttons and implementing clickable areas for radio button groups. Conclude by adding error states to provide user feedback and enhance the overall user experience. Throughout the tutorial, explore modern CSS features including cascade layers (@layer) and container queries while learning best practices for self-hosting fonts and working with variable fonts.

Syllabus

✅ 20:20 - Cascade layers @layer: https://youtu.be/NDNRGW-_1EE
✅ 27:30 Container queries: https://youtu.be/2rlWBZ17Wes
✅ 19:52 More on self-hosting fonts: https://youtu.be/zK-yy6C2Nck
00:00 - Introduction
01:00 - The HTML
04:00 - form-group vs. wrapping inside a label
06:25 - Continuing the HTML
09:40 - Using a fieldset for the radio buttons
15:30 - Adding the checkbox
18:00 - Starting the CSS
24:20 - Creating the layout for the form
31:20 - Styling the inputs
35:45 - Adding the star to the required labels
39:20 - Fixing the star for the fieldset and radio labels
44:00 - Adding the border and background to the radio selectors
49:00 - The fieldset layout
51:20 - The height of the text area without magic numbers
54:50 - Styling the button
56:60 - Making the entire radio button area clickable
1:00:00 - Error states

Taught by

Kevin Powell

Reviews

Start your review of A Deceptively Complex Form - HTML and CSS Frontend Mentor

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.