
Design comparison
Solution retrospective
I'm proud of the fact that I used the online dev tools to test out my changes before I hard-coded them into the website.
Differently, I would plan my design better so my website can look closer to the real assignment.
What challenges did you encounter, and how did you overcome them?My challenge was getting the elements in the proper alignment using flexbox. I had to go over how aligning is different from justifying content and remembering which one affects moving horizontally as to vertically. That's when it worked properly.
What specific areas of your project would you like help with?I still need to understand the essential point of flexbox and how to use it in a simpler way.
Community feedback
- @gqtpePosted 3 months ago
Feedback on the Solution
- Semantic HTML The HTML structure is generally semantic and well-organized. Elements such as <h1> and <h2> are used appropriately for the title and subtitle, which is great for accessibility and SEO. Improvement: Consider replacing the <div class="qr__description"> with a <section> or <article> if the content represents a standalone block of information. This would add more semantic meaning. The <img> element includes an alt attribute, which is essential for accessibility. However, the alt text could be more descriptive to explain the purpose of the QR code, e.g., "QR code linking to Frontend Mentor projects".
- Accessibility Good points: The text is readable with appropriate font sizes and line heights (line-height: 120% and 140%). The use of CSS variables enhances maintainability and readability. Suggestions for improvement: Add role="img" and aria-label to the <img> element to enhance screen reader support, especially for users who rely on assistive technologies. Test color contrast ratios (e.g., between the text and the background) to ensure compliance with WCAG 2.1 standards. Tools like Contrast Checker can help verify accessibility. Include focus styles for interactive elements like links (if any are added later) to ensure accessibility for keyboard users.
- Responsiveness The layout looks good on a range of screen sizes, thanks to the use of percentages and max-width. The flexibility of the image (width: 50%; max-width: 288px) ensures it adapts nicely without hardcoding dimensions. Suggestions: Test the design on very small screen sizes (<320px wide). The gap and padding values might cause the content to feel cramped on such devices. Add padding to the .wrapper to prevent the card from touching the edges on very narrow screens.
- Code Structure, Readability, and Reusability The CSS is modular and uses variables for colors and spacing, making it easy to maintain and reuse. The reset.css is thorough and helps ensure consistency across browsers. Suggestions: Consider grouping related styles together (e.g., .qr and its child elements) to improve readability and make debugging easier. Use a more descriptive name for the .qr class, such as .qr-card or .qr-container, to clarify its purpose.
- Adherence to Design The solution aligns well with the design in terms of spacing, typography, and layout. Suggestions: Confirm the exact font weights and sizes match the design. For example, ensure the font-weight: bold for .title aligns with the specified weight in the design guidelines (e.g., font-weight: 700 or font-weight: 800).
- Additional Suggestions Add transitions for hover effects or interactions, such as scaling the QR code slightly when hovered over, to enhance interactivity and user experience: css Copy code .qr__image { transition: transform 0.2s ease-in-out; } .qr__image:hover { transform: scale(1.05); } Optimize the image file size (e.g., use WebP format) to improve performance. Summary Overall, this solution is well-executed, with thoughtful design and responsive techniques. The layout is visually appealing and accessible, but minor enhancements could make it even better, such as improving semantic HTML, testing for color contrast, and adding interaction effects. Great work!
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