@FluffyKas
Posted
Hey there,
It looks good, well done!
-
Your background looks fine! You can add both the image and the colour as a background like this:
background: url(images/pattern-background-mobile.svg), #E0E8FF
. But the way you did it works just as well. ^^ -
I'd say it's okay to have a section inside a section, although I see no reason to do this, unless it helps you reading your own code easier. By default, section isn't more semantic than a simple div. I usually use sections to separate bigger chunks of content belonging together because it makes it easier for me to find things in my own code ^^ But yeah, if you're interested in knowing more, I suggest reading this article.
There are some other small issues here and there with your solution that you may wanna take a look at:
-
You should swap your
height
tomin-height: 100vh
on thebody
. You don't want to lock it strictly at 100vh, that could cause problems. -
Apart from setting a
min-height
on your body (which is there for your flexbox to vertically align your component) it's usually the best to avoid setting heights on your elements. If you feel like you need to add some height, try adding some padding or margin instead! That together with the default height of elements is all you need in 99% of cases. -
Try not to set your font-size in pixels, you could use rem instead so it would scale if a user was to change their browser's font-size settings.
-
Don't use strong tag for styling purposes, it has a semantic meaning. Add font-weight to the element if you want to make it bolder.
-
You need to set a font-family for your buttons, otherwise the browser's default styles apply
-
No reason to set type="button" on buttons.
-
Margins, paddings are also best to be set in relative units, like em, rem, etc.
I hope this helped ^^ Good luck!
Marked as helpful
@sukyungdev
Posted
@FluffyKas Hi, FluffyKas
Thank you so much for your helpful comment!
I saw your comment and fixed a lot of things (more than I thought!) especially, article about section tag was useful.
Also, I usually used pixel about size, but from now on, em, rem, etc I'll try.
Thank you for your useful opinion. Have a nice day!😊