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

Qr Code Card Component - My very fist step in frontend mentor

Keiner Mendozaā€¢ 200

@keinermendoza

Desktop design screenshot for the QR code component coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


What are you most proud of, and what would you do differently next time?

I'm most proud of how I managed to keep the html structure simple.

What challenges did you encounter, and how did you overcome them?

maybe the box-shadow part.

What specific areas of your project would you like help with?

I would appreciate feedback on how others choose names for their CSS classes. I'm interested in improving the readability and maintainability of my code. In general, any kind of suggestions are welcome.

Community feedback

MikDra1ā€¢ 5,990

@MikDra1

Posted

Limited Browser Support for :root Variables:

  • The :root variables might not work correctly in older browsers. Providing fallbacks could improve compatibility. Here is a quick VIDEO about how you can create a fallback to the variable

Font Sizing and Scaling:

  • If the font size is defined in pixels (px), it could create scaling issues on different devices. Using em or rem would be more flexible. And here is how we use rems:
html {
font-size: 62.5% // It means that 1rem = 10px. From this it is easier to use rem
}

p {
font-size: 1.6rem; // Here this paragraph font-size will be 16px;
}

If you don't understand it already here is a VIDEO

Hope you found this comment helpful šŸ’—

Good job and keep going šŸ˜šŸ˜ŠšŸ˜‰

Marked as helpful

1

Keiner Mendozaā€¢ 200

@keinermendoza

Posted

@MikDra1 Thanks for taking the time to read the code and share your knowledge.

I watched the two videos I will use a fallback for the css vars, thanks for the suggestion and I finally understand why some people use em for margins and padding. šŸ˜…

I am wondering if there is a side effect to setting the font-size in html other than affecting rem units.

0
MikDra1ā€¢ 5,990

@MikDra1

Posted

@keinermendoza

It can affect browser default styles which are set in rem's. But beyond that if you understand REM well enough there won't by any obstacles for you.

Like if you set 1rem = 10px then all of the sudden your paragraphs will get smaller because theirs font-size is set to one rem. An easy fix for this is to set the font-size on body to 1.6rem;

Hope you found this response useful šŸ’—šŸ’—šŸ’—

0
Borisā€¢ 2,870

@mkboris

Posted

Your class naming is clear and quite descriptive, which is great. If you are looking for a better alternative, you can adopt the BEM naming pattern.

1

Keiner Mendozaā€¢ 200

@keinermendoza

Posted

@mkboris Thanks for taking the time to read the code; I appreciate it. And thanks for sharing the article. I like the idea of using that standard. Iā€™m not completely sure if I understand it yet, but I will keep trying to use 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