Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Book cover #4

Merged
merged 11 commits into from
Jun 10, 2019
Merged

Book cover #4

merged 11 commits into from
Jun 10, 2019

Conversation

bhflm
Copy link
Contributor

@bhflm bhflm commented Jun 5, 2019

Summary

Added book cover picture

Screenshots

image

Trello Card

https://trello.com/c/o6flXrfb/32-detalle-de-libro-ii-imagen

@bhflm bhflm changed the title add book picture and css style Book cover Jun 6, 2019
display: flex;
flex-direction: column;
width: 400px;
margin-left: 100px;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

margin-right in the image. Also, I think it's too big, it looks smaller in the design, don't you think?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, at least the values that are @ invision match with these. It did look big but due to the fact that the text was kinda small.

.column {
display: flex;
flex-direction: column;
width: 400px;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wouldn't fix this width. You can set flex-grow: 1 so it grows all it can grow inside the "row"

Also, if you are going to make this column class, it might be better to make it more "generic" in case you eventually want to have another "column". I would remove this and leave only the display and flex-direction, and I'd make another class called book-information-container or something that has the specific properties this div needs, then add both this classes to the div.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The same applies to classes like .book-container, you can use row or column in the html instead of setting display: flex inside it. For that type of things it's better to use more generic classes and leave these for more specific things like font-size, position, etc.

.row {
display: flex;
flex-direction: row;
align-items: baseline;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As the column class, I'd remove the align-items from here as it's specific to this row in particular.

<h3 class="book-detail-value height">Año de publicación</h3>
<img src="./assets/book-cover.png" class="book-cover">
<div class="column book-info-container">
<div class="row book-row-info-container">
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would change this name into something more semantic like book-title-container

@@ -4,19 +4,19 @@

.book-container {
display: flex;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can use row class instead and use this for other css properties. It's a good idea to re use css layout classes, because that way you can know how it is supposed to look by just checking the html tags and their classes

@Dorian30 Dorian30 assigned bhflm and unassigned Dorian30 Jun 7, 2019
Copy link

@Dorian30 Dorian30 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remember to add the screenshot to the PR

@bhflm
Copy link
Contributor Author

bhflm commented Jun 7, 2019

Remember to add the screenshot to the PR

done

margin-bottom: 20px;
.row {
display: flex;
flex-direction: row;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not necessary. By default the flex-direction is set to row.

@bhflm bhflm assigned Dorian30 and unassigned bhflm Jun 10, 2019
@Dorian30 Dorian30 assigned bhflm and unassigned Dorian30 Jun 10, 2019
<h3 class="book-detail-name bold height">Año de publicación:</h3>
<h3 class="book-detail-value height">Año de publicación</h3>
<div class="book-container row">
<img src="./assets/book-cover.png" class="book-cover">

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this img tag doesn't self-close

Suggested change
<img src="./assets/book-cover.png" class="book-cover">
<img src="./assets/book-cover.png" class="book-cover" />

<h3 class="book-detail-value height">Año de publicación</h3>
<div class="book-container row">
<img src="./assets/book-cover.png" class="book-cover">
<div class="column book-info-container">

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove a level of indentation, it looks like these divs that follow are children of the img

@bhflm bhflm merged commit 90a2cc5 into book-detail Jun 10, 2019
@bhflm bhflm mentioned this pull request Jun 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants