Skip to content
  • Unlock Pro
  • Log in with GitHub
Solution
Submitted over 3 years ago

Order summary component challenge - HTML and CSS

Will Gordon•20
@wcgordon1
A solution to the Order summary component challenge
View live sitePreview (opens in new tab)View codeCode (opens in new tab)

Solution retrospective


The css was a little tricky for the music icon / Annual Plan / $59.99/year.

Initially, I was going to use CSS grid but quickly found this to not be a good solution. placed the elements in a div and used Flex instead. doh!

Overall, not very difficult. Nice to code without a tutorial and figure it out on my own. I start General Assembly Code bootcamp on 11/29/21.

Code
Select a file

Please log in to post a comment

Log in with GitHub

Community feedback

  • Nick•760
    @Nick331102
    Posted over 3 years ago

    Nice work. Good luck in your bootcamp

    Marked as helpful
  • Grace•32,130
    @grace-snow
    Posted over 3 years ago

    Hello

    Here is some ideas for improvements on this, most are really common beginner mistakes so don’t get discouraged. It’s good to pick these things up early 😊

    • headings must go in order. They are essential for giving structure to the document, nothing to do with styling. So annual plan needs to be a h2 here
    • no reason to have background image on an absolutely positioned div in the html. Just place the background image on the body, then swap that image in a media query for the desktop/mobile one
    • the grey box is definitely not an article. Div is fine, it has a heading and that’s all the structure you need semantically
    • what is it you expect proceed and cancel to do? Buttons are for actions, anchor tags for navigation. If these would take you to a next/previous page/step in a process they should be anchor tags
    • make sure all interactive elements have obvious focus-visible states to help keyboard users know where they are in the page. Usually this is not supplied by a designer and set globally for a site like a bold orange/blue outline
    • overall try to get a little closer to the design in terms of heading size, padding and the subtlety of the box shadow. You could do this challenge with no media queries (except the body background image), but I think the padding is slightly larger on desktop in the original designs.
    • never have font sizes in pixels. That’s important. Use rem most of the time, or em if you need to scale with the size of a parent (I can’t remember the last time that was necessary on a project though and only use em occasionally for padding)

    That’s all I can remember from looking quickly at code before, but hope it’s a helpful start. Good luck

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
Frontend Mentor logo

Stay up to datewith new challenges, featured solutions, selected articles, and our latest news

Frontend Mentor

  • Unlock Pro
  • Contact us
  • FAQs
  • Become a partner

Explore

  • Learning paths
  • Challenges
  • Solutions
  • Articles

Community

  • Discord
  • Guidelines

For companies

  • Hire developers
  • Train developers
© Frontend Mentor 2019 - 2025
  • Terms
  • Cookie Policy
  • Privacy Policy
  • License

Oops! 😬

You need to be logged in before you can do that.

Log in with GitHub

Oops! 😬

You need to be logged in before you can do that.

Log in with GitHub

How does the accessibility report work?

When a solution is submitted, we use axe-core to run an automated audit of your code.

This picks out common accessibility issues like not using semantic HTML and not having proper heading hierarchies, among others.

This automated audit is fairly surface level, so we encourage to you review the project and code in more detail with accessibility best practices in mind.

How does the CSS report work?

When a solution is submitted, we use stylelint to run an automated check on the CSS code.

We've added some of our own linting rules based on recommended best practices. These rules are prefixed with frontend-mentor/ which you'll see at the top of each issue in the report.

The report will audit all CSS, SCSS and Less files in your repository.

How does the HTML validation report work?

When a solution is submitted, we use html-validate to run an automated check on the HTML code.

The report picks out common HTML issues such as not using headings within section elements and incorrect nesting of elements, among others.

Note that the report can pick up “invalid” attributes, which some frameworks automatically add to the HTML. These attributes are crucial for how the frameworks function, although they’re technically not valid HTML. As such, some projects can show up with many HTML validation errors, which are benign and are a necessary part of the framework.

How does the JavaScript validation report work?

When a solution is submitted, we use eslint to run an automated check on the JavaScript code.

The report picks out common JavaScript issues such as not using semicolons and using var instead of let or const, among others.

The report will audit all JS and JSX files in your repository. We currently do not support Typescript or other frontend frameworks.

Oops! 😬

You need to be logged in before you can do that.

Log in with GitHub

Frontend Mentor for Teams

Frontend Mentor for Teams helps companies and schools onboard and train developers through project-based learning. Our industry-standard projects give developers hands-on experience tackling real coding problems, helping them master their craft.

If you work in a company or are a student in a coding school, feel free to share Frontend Mentor for Teams with your manager or instructor, as they may use it to help with your coding education.

Learn more

Oops! 😬

You need to be logged in before you can do that.

Log in with GitHub