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

Results summary component

Danilo•110
@daaaan12
A solution to the Results summary component challenge
View live sitePreview (opens in new tab)View codeCode (opens in new tab)

Solution retrospective


Este é um trecho de código HTML que inclui um resumo de um resultado de teste em um formato de cartão. O cartão contém um título, uma pontuação e uma seção de resumo com quatro componentes: reação, memória, verbal e visual. Cada componente possui um ícone, um título e uma pontuação. Na parte inferior do cartão, há um botão para continuar.

Em termos de estrutura, o código começa com a declaração do documento HTML e a seção head. A seção head contém o título do documento, a codificação de caracteres e a viewport. Além disso, a seção head inclui um link para um arquivo CSS que estiliza os elementos HTML.

A seção body inclui a estrutura do cartão com dois contêineres principais, card-resultado e card-sumario, que contêm os componentes do resultado e do resumo, respectivamente. Cada componente possui sua própria estrutura HTML e classes CSS, que definem o layout e os estilos para os elementos. Por fim, há um contêiner para o texto de atribuição.


This is a piece of HTML code that includes a summary of a test result in a card format. The card contains a title, a score, and a summary section with four components: reaction, memory, verbal, and visual. Each component has an icon, a title, and a score. At the bottom of the card, there is a button to continue.

In terms of the structure, the code starts with the HTML document declaration and the head section. The head section contains the title of the document, the character encoding, and the viewport. Additionally, the head section includes a link to a CSS file that styles the HTML elements.

The body section includes the card structure with two main containers, card-resultado and card-sumario, that hold the result and the summary components, respectively. Each component has its own HTML structure and CSS classes, which defines the layout and styles for the elements. Finally, there is a container for the attribution text.

Code
Couldn’t fetch repository

Please log in to post a comment

Log in with GitHub

Community feedback

  • Martin Richter•160
    @Karag2006
    Posted over 2 years ago

    Hi, First off: i like your Solution, espacially the additional hover on the Summary Categories.

    Now for some small suggestions: You don't use Semantic HTML. Which is an easy thing to make the Solution a little better still:

    • Include a <main> tag fro the majority of your html. For Example your card-container : <main class="card-container"> ..... </main>
    • Also The provided attribution could be a footer instead of a div : <footer class="attribution"> ..... </footer>
    • You are missing an h1 Headline. Idealy that would be the main Thing telling people what the site is about. In this case that would be <h1 class="txt-resultado">Your Result</h1>

    And the last thing: you do have a very slight visual effekt on the <button> for focus. This could be more obvious so people prefering the keyboard have a better visual clue as to what Element has currently the Focus. What i usually do for that is :

    .btn-continue:hover, .btn-continue:focus { background: linear-gradient(to bottom, var(--color-light-royal-blue), var(--color-light-slate-blue)); }

    This just gives the button the same effect for hover and focus states.

    I hope the Feedback is Helpful for you.

    Marked as helpful

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

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