Skip to content

ITP_LONDON | PRISCILLA_EMEBO |Module-Data-Groups | Reading list app #509

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Priscilla-EM
Copy link

@Priscilla-EM Priscilla-EM commented Apr 21, 2025

Learners, PR Template

Self checklist

  • I have committed my files one by one, on purpose, and for a reason
  • I have titled my PR with COHORT_NAME | FIRST_NAME LAST_NAME | REPO_NAME | WEEK
  • I have tested my changes
  • My changes follow the style guide
  • My changes meet the requirements of this task

Changelist

Briefly explain your PR.

Questions

Ask any questions you have for your reviewer.

@Priscilla-EM Priscilla-EM added the Needs Review Participant to add when requesting review label Apr 21, 2025
@jenny-alexander jenny-alexander self-requested a review April 23, 2025 11:49
@jenny-alexander jenny-alexander added Review in progress This review is currently being reviewed. This label will be replaced by "Reviewed" soon. and removed Needs Review Participant to add when requesting review labels Apr 23, 2025
cjyuan

This comment was marked as duplicate.

@cjyuan cjyuan removed the Review in progress This review is currently being reviewed. This label will be replaced by "Reviewed" soon. label Apr 23, 2025
@cjyuan
Copy link
Contributor

cjyuan commented Apr 23, 2025

@jenny-alexander Sorry. I didn't play by the rule and changed the label. I didn't thought anyone would still be giving review at this stage.

I just hid my review.

@cjyuan cjyuan added the Review in progress This review is currently being reviewed. This label will be replaced by "Reviewed" soon. label Apr 23, 2025
@jenny-alexander
Copy link

jenny-alexander commented Apr 23, 2025

@jenny-alexander Sorry. I didn't play by the rule to change the label. I didn't thought anyone would still be giving review at this stage.

No worries @cjyuan, glad for the help as I was trying to do a few reviews before the work day starts. 🙂
I'll finish up this review now!

books.forEach((book) => {
const listItem = document.createElement("li");
listItem.className = "book-item";
listItem.style.backgroundColor = book.alreadyRead ? "#c8f7c5" : "#f7c5c5";

Choose a reason for hiding this comment

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

I like the way you used a ternary operator here to determine the background color. 👍
However, it's generally preferred to keep CSS styling within your CSS styling files. This will make it easier to maintain styling as your application grows. Can you make this change?

https://www.w3schools.com/html/html_classes.asp -> look at the Multiple Classes section

@jenny-alexander jenny-alexander added Reviewed Volunteer to add when completing a review and removed Review in progress This review is currently being reviewed. This label will be replaced by "Reviewed" soon. labels Apr 23, 2025
const image = document.createElement("img");
image.src = book.bookCoverImage;
image.alt = `${book.title} cover`;
image.style.width = "100px";

Choose a reason for hiding this comment

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

Here is another place where using a class name (for styling) is preferred to styling the image within the javascript code.

@Priscilla-EM
Copy link
Author

Thank you for the review. I'll make the necessary changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Reviewed Volunteer to add when completing a review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants