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

Fix #5086 : Implement Dark Mode support for NPS Survey #5104

Merged
merged 12 commits into from
Aug 1, 2023

Conversation

MohitGupta121
Copy link
Member

@MohitGupta121 MohitGupta121 commented Jul 25, 2023

Explanation

Fix #5086 : Implement full Dark Mode support for NPS Survey

Essential Checklist

  • The PR title and explanation each start with "Fix #bugnum: " (If this PR fixes part of an issue, prefix the title with "Fix part of #bugnum: ...".)
  • Any changes to scripts/assets files have their rationale included in the PR explanation.
  • The PR follows the style guide.
  • The PR does not contain any unnecessary code changes from Android Studio (reference).
  • The PR is made from a branch that's not called "develop" and is up-to-date with "develop".
  • The PR is assigned to the appropriate reviewers (reference).

For UI-specific PRs only

NPS Survey Welcome Screen

Light Mode Dark Mode

NPS Survey Question screen (Button Disabled)

Light Mode Dark Mode

NPS Survey Question screen (Button Enabled)

Light Mode Dark Mode

NPS Survey Score Screen

Light Mode Dark Mode

NPS Survey Final comment screen (Button Enabled)

Light Mode Dark Mode

NPS Survey Final comment screen (Button Disabled)

Light Mode Dark Mode

NPS Survey Thanks You screen

Light Mode Dark Mode

NPS Survey Exit Dialog

Light Mode Dark Mode

If your PR includes UI-related changes, then:

  • Add screenshots for portrait/landscape for both a tablet & phone of the before & after UI changes
  • For the screenshots above, include both English and pseudo-localized (RTL) screenshots (see RTL guide)
  • Add a video showing the full UX flow with a screen reader enabled (see accessibility guide)
  • Add a screenshot demonstrating that you ran affected Espresso tests locally & that they're passing

Copy link
Member Author

@MohitGupta121 MohitGupta121 left a comment

Choose a reason for hiding this comment

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

@adhiamboperes PTAL, Thanks!

Copy link
Collaborator

@adhiamboperes adhiamboperes left a comment

Choose a reason for hiding this comment

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

Thanks a lot @MohitGupta121! I just had two minor comments:

  • Can I see how the 'NPS Survey Final comment screen' looks without text and the submit button disabled?
  • Is there a way to make the progress bar look like the one in light mode (I don't mind too much, but let's give it a try).

Otherwise this looks really great!

@oppiabot
Copy link

oppiabot bot commented Jul 25, 2023

Unassigning @adhiamboperes since the review is done.

@oppiabot
Copy link

oppiabot bot commented Jul 25, 2023

Hi @MohitGupta121, it looks like some changes were requested on this pull request by @adhiamboperes. PTAL. Thanks!

@MohitGupta121
Copy link
Member Author

MohitGupta121 commented Jul 25, 2023

@adhiamboperes PTAL Thanks, I updated the PR description with button disabled final comment screen.

  1. Regarding progress bar I don't think there is need to change the theme/ color of that because we using the same progress bar in Exploration Fragments also. So I think that already suggested by designer in past. If we change then it's look in-consistence in both places. Actually now in question fragment we not showing progress bar so here is the figma design by designer for Dark-Mode and Light-Mode

Also I think we need to introduce NPS Survey layout for landscape version because you can see the output, screen is not scrollable like welcome screen is incomplete and cutting from bottom:

Screenshot_1690294206
Screenshot_1690294222

@adhiamboperes
Copy link
Collaborator

@adhiamboperes PTAL Thanks, I updated the PR description with button disabled final comment screen.

  1. Regarding progress bar I don't think there is need to change the theme/ color of that because we using the same progress bar in Exploration Fragments also. So I think that already suggested by designer in past. If we change then it's look in-consistence in both places. Actually now in question fragment we not showing progress bar so here is the figma design by designer for Dark-Mode and Light-Mode

I created a custom toolbar for the survey, please check the layout file. The progressbar drawable in this toolbar is also customized, per the survey mocks. See how it looks in the light mode screenshots with the white outline.

Also I think we need to introduce NPS Survey layout for landscape version because you can see the output, screen is not scrollable like welcome screen is incomplete and cutting from bottom:

Yes, that is correct.

Copy link
Member Author

@MohitGupta121 MohitGupta121 left a comment

Choose a reason for hiding this comment

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

@adhiamboperes PTAL, here are the screenshots of the progress bar in both light and dark-mode. Thanks!

Light Mode Dark Mode

@adhiamboperes
Copy link
Collaborator

@adhiamboperes PTAL, here are the screenshots of the progress bar in both light and dark-mode. Thanks!

Light Mode Dark Mode

Thank you, this LGTM

@MohitGupta121
Copy link
Member Author

Thank you so much @adhiamboperes anything else I need to update in this PR?

@adhiamboperes
Copy link
Collaborator

Thank you so much @adhiamboperes anything else I need to update in this PR?

Hey @MohitGupta121, I have opened a PR for the landscape layouts here and assigned it to you and @kkmurerwa for review. If you are happy with it, we will merge it into this branch before merging to develop.

@oppiabot
Copy link

oppiabot bot commented Jul 31, 2023

Assigning @seanlip for code owner reviews. Thanks!

Copy link
Collaborator

@adhiamboperes adhiamboperes left a comment

Choose a reason for hiding this comment

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

Left a couple of minor follow up comments

@MohitGupta121
Copy link
Member Author

MohitGupta121 commented Jul 31, 2023

@adhiamboperes done that separate dimensions changes for survey. Thanks!

@seanlip
Copy link
Member

seanlip commented Aug 1, 2023

@MohitGupta121 I think this looks great. Just one question: do we use dark green text on black anywhere else in the app (e.g. "Previous" on the black background)? I find that hard to read, but it's probably fine to leave as-is if it's an existing design pattern for dark mode (i.e. we've used it in other places too).

Thanks!

@seanlip seanlip assigned MohitGupta121 and unassigned seanlip Aug 1, 2023
@MohitGupta121
Copy link
Member Author

MohitGupta121 commented Aug 1, 2023

@seanlip PTAL, Thanks.
Here are some comparison:

Current Green Oppia Primary Green Dark Green

@seanlip
Copy link
Member

seanlip commented Aug 1, 2023

@MohitGupta121 For me, the leftmost one is the most visible, but it is still a little dark against the background.

What is the colour contrast ratio and does it meet accessibility standards? That's one way to test.

@seanlip seanlip assigned MohitGupta121 and unassigned seanlip Aug 1, 2023
@MohitGupta121
Copy link
Member Author

@seanlip Sorry, yes you are right. This does not match accessibility standards. Here is the output:

@MohitGupta121
Copy link
Member Author

@seanlip After changing the color to oppia_bright_green here is the output screenshot and accessibility result:

Screenshot:

Accessibility Result

new.record.webm

Copy link
Member

@seanlip seanlip left a comment

Choose a reason for hiding this comment

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

Thanks @MohitGupta121 ! No further concenrs.

@seanlip seanlip assigned MohitGupta121 and unassigned seanlip Aug 1, 2023
@oppiabot oppiabot bot added the PR: LGTM label Aug 1, 2023
@oppiabot
Copy link

oppiabot bot commented Aug 1, 2023

Hi @MohitGupta121, this PR is ready to be merged. Please address any remaining comments prior to merging, and feel free to merge this PR once the CI checks pass and you're happy with it. Thanks!

@adhiamboperes
Copy link
Collaborator

Thanks @MohitGupta121, @seanlip, @kaiyuxu.

I'm merging this now.

@adhiamboperes adhiamboperes merged commit a888729 into develop Aug 1, 2023
36 checks passed
@adhiamboperes adhiamboperes deleted the nps_survey_dark_mode branch August 1, 2023 19:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feature Request]: Fast-Follow Item - Enable Full Dark Mode Support for NPS Survey
4 participants