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

Four card feature section (Using Flexbox and Grid)

@jlmunozfdev

Desktop design screenshot for the Four card feature section coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


I don't know if I have handled well the part of the margins and the padding and the theme of the Css grid. And I think I use a lot of classes when I can summarize when applying the styles.

Community feedback

Denis 1,060

@Mod8124

Posted

Hola buen trabajo!

El margin y el padding no te preocupes es pura practica práctica, puedes usar los figma s pero ya q no cuentas con estos puedes usar pixel perfect y puedes practicar de manera directa en css battle es mas facil por q ves los resultados de una xd

Usaste muchas clases pero no te preocupes hay una metodología(escribir de manera eficiente el css) de css que hace lo mismo llamada bem pudiste haber ahorrado un montón de código usándola ya que usaste mucha clases que solo cambian una cosa por ejemplo

Tu css


.card__supervisor {
    display: flex;
    flex-direction: column;
    border-top: 4px solid var(--cyan);
    border-radius: 7px;
    box-shadow: 0px 10px 24px -4px rgba(0,0,0,0.5);
}

. card__team {
    display: flex;
    flex-direction: column;
    border-top: 4px solid var(--red);
    border-radius: 7px;
    box-shadow: 0px 10px 24px -4px rgba(0,0,0,0.5);
}

.card__karma {
    display: flex;
    flex-direction: column;
    border-top: 4px solid var(--orange);
    border-radius: 7px;
    box-shadow: 0px 10px 24px -4px rgba(0,0,0,0.5);
}

Con bem

.card {
display: flex;
    flex-direction: column;
    border-top: 4px solid var(--orange);
    border-radius: 7px;
} 
.card--supervisor {
box-shadow: 0px 10px 24px -4px rgba(0,0,0,0.5);
} 
.card--team {
box-shadow: 0px 10px 24px -4px rgba(0,0,0,0.5);
} 
.card--karma {
box-shadow: 0px 10px 24px -4px rgba(0,0,0,0.5);
} 

ves es mas fácil de aplicar y ahorras un montón de código css, solo crea una clase con los valores por defecto y otra con modificaciones. En el html:

<div class="card card--supervisor" ></div>
<div class="card card--team" ></div>
<div class="card card--karma" ></div>

Ahora cada div tiene los mismo estilos pero cambia el shadow

Espero te sirva, good coding 👌

Marked as helpful

0
David 8,000

@DavidMorgade

Posted

Muy buenas Jorge, excelente trabajo, se va notando todo lo que estás mejorando respecto a tus anterior proyectos, sigue así!

Si no te importa me gustaría darte algo de feedback:

  • Lo primero y más importante, deberías de subir el valor de tus media queries, ya que si usas @media(min-width: 375px), tus estilos para mobile solo se estarían aplicando de 0 a 375px (y así no englobas apenas tamaños de telefonos), además si te fijas bien el layout se rompe desde los 375px hasta lost 700~, prueba subiendo tus media queries hasta al menos @media(min-width: 768px) que es el tamaño máximo para telefonos.

Por lo demás muy bien, buen trabajo con el Grid, y muy buen trabajo usando align-self para alinear cada elemento por separado!

Espero que mi feedback te sea de ayuda, si tienes alguna pregunta no dudes en preguntar! Un saludo

Marked as helpful

0
Lucas 👾 104,420

@correlucas

Posted

👾Hello Jorge, congratulations for your new solution!

Your solution seems pretty good, you've done a good work building the html structure. The first thing I saw when opened your solution was the cards box shadows. To improve your box-shadow, you’ve to have in mind two things that make a good shadow, blur and low opacity for smooth shadows. To improve your current shadow, decrease the opacity and increase the blur, try this value instead: box-shadow: 12px 7px 20px 6px rgb(57 75 84 / 8%);

If you’re not familiar to box-shadow you can use this site to create the shadow design and then just drop the code into the CSS: https://html-css-js.com/css/generator/box-shadow/

✌️ I hope this helps you and happy coding!

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