Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found

Submitted

Intro component with sign-up form with HTML, CSS, Flexbox, Grid, JS

Purboβ€’ 330

@Targitay2012

Desktop design screenshot for the Intro component with sign-up form coding challenge

This is a solution for...

  • HTML
  • CSS
  • JS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


I will be glad to any feedback!

Community feedback

P
Graceβ€’ 27,890

@grace-snow

Posted

A few important html tips

  • you shouldn't have empty divs for any reason. If you need to put a background image on the whole page put it on the body
  • every input must have a label
  • the error icons are decorative so alt must be empty if placed in html. Or you could make them background images on invalid inputs if preferred
  • the error messages should be wrapped in an element that has an aria live attribute on it and a unique ID for each one
  • the inputs need aria describedby pointing to the id of its error container

All of these things are important habits to get into as soon as possible so you write accessible forms.

Marked as helpful

2

P
Graceβ€’ 27,890

@grace-snow

Posted

Just checked this on mobile and it's completely unusable as most of the content is cut off screen..

The cause is the height 100vh on sign up div; and the absolutely positioned background

Definitely move background color / image to the body and change that height 100vh to min-height. That will let it grow as needed, not limit everything to the height of a users screen

Marked as helpful

2
Purboβ€’ 330

@Targitay2012

Posted

@grace-snow hello!

Thanks for the hints! Newbies like me need to get this kind of advice.

I entered an empty div out of desperation: for some reason, the background of the page placed in the pseudo-element overlapped the form itself, so it was impossible to enter data or press the button. I tried both z index and transform translate z, but nothing worked. Today I did it again and everything worked as it should, I don’t understand anything.

0
P
Graceβ€’ 27,890

@grace-snow

Posted

@Targitay2012 I don't know why you would try to use a pseudo element either. The background can go straight onto the body in this challenge

0
Purboβ€’ 330

@Targitay2012

Posted

@grace-snow, I proceeded from the fact that other blocks of the page with a different background can go further. So I tried to do everything in one block. And yes, you are right, in this task, you can give a background to the body.

0
Vanza Setiaβ€’ 27,855

@vanzasetia

Posted

Hi, Purbo! πŸ‘‹

I totally agree with @grace-snow regarding the form validation. By following Grace's suggestions, it will make the errors get announced to the screen reader users.

I wrote an article about creating accessible form validation. It will tell you how to create it step-by-step to create accessible form validation by using aria-live and aria-describedby.

About the input's label, it needs to have text content. Wrapping the input with label doesn't make the input has an accessible name. I recommend having a span with visually hidden styling or using aria-label on the input element instead.

For your information, @ is an at sign. You may need to rename the variable on JavaScript.

By default, the body element has 16px. I would think if the style-guide is telling that the body font size is 16px that means it follows the users' browser's default font size. So, there's no need to specify font-size: 16px.

Also, code your font size in rem, not pixels. This means the text size will be responsive if people want to adjust the size.

I hope this helps! Happy coding!

Marked as helpful

1

Purboβ€’ 330

@Targitay2012

Posted

@vanzasetia hello!

Thanks for the feedback!

The article is very cool, I read it once, but I think I will have to re-read it several times). A regular expression for checking email addresses is a brain blast!

0
Vanza Setiaβ€’ 27,855

@vanzasetia

Posted

@Targitay2012

You are welcome!

Don't worry about right away understanding the Regular expression. For me, regular expression is hard to learn. But, it is powerful to validate strings. In this case, it is the user's email address. So, take your time to understand it. πŸ™‚

0

Please log in to post a comment

Log in with GitHub
Discord logo

Join our Discord community

Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!

Join our Discord