flex for desktop, pseudo-element for background
Design comparison
Solution retrospective
Unsure if: fixed position was right for logo on desktop view as logo was under header which is on the right side of the screen. Tablet view should be the same as the mobile view. The Tiny hr should be the dot on desktop between login and every other link. Was the image was done correctly responsive wise/does it scale well? Should text align center should be used for under 360 width buttons were styled right width wise and font size wise?
Community feedback
- @argelomnesPosted about 5 years ago
Hi Jhabari,
Nice job! I like your take on using
hr
in the nav.-fixed position logo: The content for this challenge isn't long enough so you won't notice it, but if it was, the logo will scroll along with the page. This might cover some of the texts so I prefer not using this approach unless needed. Consider using flexbox.
-you can check if the image resizes well by resizing your browser window
-text-alignment: I would refer to the design provided. @375px it's aligned left. For lesser code, I suggest using that as the starting point for smaller sizes.
2@J-GuidryPosted about 5 years agoThank you for the feedback. I had problems with text width with content below 375, while it does meet the design at 375, which is why I went with center alignment but it will be corrected with more work.
The logo was under the header tag in the html, which made using flex-direction row reverse to make the desktop design made the logo go to the right side. This can be corrected by moving the logo in the html to a different place.
0 - @mattstuddertPosted about 5 years ago
Hey Jhabari, great work on this challenge! Argel has got you covered re: your questions. The image resizes nicely, so well done.
Another solution for the dot would be to keep the Login link in the same list as the other navigation items and then use a pseudo-element (like
::before
) and a combination ofposition: absolute;
to create the dot in your CSS. This would be nice because it would keep the HTML structure consistent and only use CSS to add the design detail.Let me know if you have any questions 👍
0
Please log in to post a comment
Log in with GitHubJoin 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