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

CHAL-4 #done #3

Merged
merged 9 commits into from
Apr 2, 2024
Merged

CHAL-4 #done #3

merged 9 commits into from
Apr 2, 2024

Conversation

JyyHuang
Copy link
Contributor

@JyyHuang JyyHuang commented Apr 2, 2024

Checklist

Please ensure you have followed all of the steps below before submitting a pull request:

  • Include the corresponding Jira issue key and #done in the PR title, like so: "JRA-123 #done Migrate Election Reminders"
  • Verify that the code compiles
  • Verify that all tests pass
  • Verify that unit tests cover 100% of the code
  • Create Storybook stories for visual components
  • Verify that any visual components match the Figma
  • Test with a screen reader (if applicable)
  • Document your code with TSDoc comments
  • Format your code with Prettier

Overview

This PR migrates the existing Why8by8 page to Next.js. It updates old image paths to new ones, replaces and tags to Next.js components and , and replaces background styling to use partials. Additionally, I added a border around the svg image, which was causing a thin teal line on some browsers, and also added styling to the page-container component to fix image overlapping the header. There were some issues with storybook which were worked around. The first in .storybook/main.ts was '..\\public' didn't work as expected in a Linux environment. The second in tsconfig.json storybook couldn't locate alias paths, e.g. @/app/why8by8/page

Test Plan

I created a storybook story in src/stories/pages and a jest snapshot test in src/__tests__/pages/why8by8 to ensure my component rendered and worked.

Follow ups

The black background was replaced by $color-black-8by8 partial, but the vote bubble image background wasn't changed, causing a difference in colors.

@JyyHuang JyyHuang requested a review from dvorakjt April 2, 2024 01:49
@JyyHuang JyyHuang marked this pull request as draft April 2, 2024 02:13
@JyyHuang JyyHuang marked this pull request as ready for review April 2, 2024 02:13
Copy link
Contributor

@dvorakjt dvorakjt left a comment

Choose a reason for hiding this comment

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

Hi Joey,

Looks great. Good job naming things clearly, using semantically appropriate html elements and calling attention to follow-ups. Thank you for fixing the z-index issue with the PageContainer component.

I have created an issue in Jira as a reminder for us to get that speech bubble image updated. I'll get a designer to do that this week.

In terms of this PR, there are a few minor changes I'd like to request:

  • Please replace any apostrophes in text within a JSX element with the appropriate escape character '. Please see the following ESLint rule for more information: https://github.com/jsx-eslint/eslint-plugin-react/blob/master/docs/rules/no-unescaped-entities.md
  • Please ensure that the code is formatted with Prettier. The indentation size should be 2 spaces if the Prettier has successfully formatted the code.
  • For consistency, please use snake_case for SCSS class names. This casing pairs well with both SCSS module syntax and short utility class names like mt_lg

Finally, I noticed this class name:

custom_shape_divider_top_1659139317

I'm not sure what the number at the end means. If it doesn't have any value to the reader, perhaps it could be shortened to "custom_shape_divider_top" ?

Excellent first contribution, thank you! Please make the above changes and we'll be able to merge it!

@JyyHuang JyyHuang requested a review from dvorakjt April 2, 2024 16:46
@JyyHuang
Copy link
Contributor Author

JyyHuang commented Apr 2, 2024

Hi Joseph,

Thank you for the review and suggestions. I went ahead and made the appropriate changes.

Copy link
Contributor

@dvorakjt dvorakjt left a comment

Choose a reason for hiding this comment

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

Looks great, thanks for making the requested changes.

@dvorakjt dvorakjt merged commit ce70ce3 into 8by8-org:development Apr 2, 2024
1 check passed
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.

2 participants