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

Fixes #4185: Added Dark Mode for HelpActivity , FaqListActivity , FaqSingleActivity #4245

Merged
merged 10 commits into from
May 27, 2022

Conversation

bhaktideshmukh
Copy link
Contributor

@bhaktideshmukh bhaktideshmukh commented Mar 13, 2022

Explanation

Fixes #4185
Added dark mode for HelpActivity , FaqListActivity , FaqSingleActivity.

Mocks Link

ScreenShots

Default mode After dark mode
Default mode After dark mode
Default mode After dark mode

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

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

@bhaktideshmukh bhaktideshmukh changed the title added dark_mode to help and faq Fixes #4185: Added Dark Mode for HelpActivity , FaqListActivity , FaqSingleActivity Mar 13, 2022
@ayush0402
Copy link
Contributor

@bhaktideshmukh Haven't looked at the changes yet but also update the color for ActionBar to the correct color. You might want to look at the theme in the manifest that this screen is using and refer to OppiaActionBarTheme we are currently using for another theme for this.

@bhaktideshmukh
Copy link
Contributor Author

@bhaktideshmukh Haven't looked at the changes yet but also update the color for ActionBar to the correct color. You might want to look at the theme in the manifest that this screen is using and refer to OppiaActionBarTheme we are currently using for another theme for this.

Do you mean to update 'android:theme="@style/Widget.AppCompat.ActionBar" ' to 'android:theme="@style/OppiaThemeWithoutActionBar" in the toolbar section.

@rt4914 rt4914 removed their assignment Mar 14, 2022
@rt4914
Copy link
Contributor

rt4914 commented Mar 14, 2022

Un-assigning until approved / re-assigned by @ayush0402

@ayush0402
Copy link
Contributor

@bhaktideshmukh We are not supposed to change anything directly in the manifest file. If you look at the current declaration of OppiaTheme it will have something like <item name="actionBarTheme">@style/OppiaActionBarTheme</item> to set the ActionBar color.
But I guess FAQ Activity is not actually using ActionBar but instead using a custom Toolbar in its layout file. So we just might need to change that.

@bhaktideshmukh
Copy link
Contributor Author

@bhaktideshmukh We are not supposed to change anything directly in the manifest file. If you look at the current declaration of OppiaTheme it will have something like <item name="actionBarTheme">@style/OppiaActionBarTheme</item> to set the ActionBar color. But I guess FAQ Activity is not actually using ActionBar but instead using a custom Toolbar in its layout file. So we just might need to change that.

I have updated the theme in Faq_list_activity.xml -- is this what you suggested?

current view:--
||

@bhaktideshmukh bhaktideshmukh removed their assignment Mar 14, 2022
@bhaktideshmukh
Copy link
Contributor Author

PTAL @ayush0402
Thanks

@oppiabot
Copy link

oppiabot bot commented Mar 23, 2022

Hi @bhaktideshmukh, I'm going to mark this PR as stale because it hasn't had any updates for 7 days. If no further activity occurs within 7 days, it will be automatically closed so that others can take up the issue.
If you are still working on this PR, please make a follow-up commit within 3 days (and submit it for review, if applicable). Please also let us know if you are stuck so we can help you!

@oppiabot oppiabot bot added the stale Corresponds to items that haven't seen a recent update and may be automatically closed. label Mar 23, 2022
Copy link
Contributor

@ayush0402 ayush0402 left a comment

Choose a reason for hiding this comment

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

@bhaktideshmukh Thanks, overall this looks good. Just had a few suggestions.
Also, I think the content of the FAQ and other list items in FAQ questions list should be using sub_text color (which is defined in color_defs as color_def_oppia_silver.) and not the Body Header color, you might need to confirm this from the mocks and let me know if It is actually mentioned otherwise in the mocks.

android:background="?attr/colorPrimary"
android:background="@color/color_def_oppia_green"
Copy link
Contributor

Choose a reason for hiding this comment

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

This should be a component_color.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

android:background="@color/oppia_primary"
android:background="@color/color_def_oppia_green"
Copy link
Contributor

Choose a reason for hiding this comment

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

ditto.

android:background="?attr/colorPrimary"
android:background="@color/color_def_oppia_green"
Copy link
Contributor

Choose a reason for hiding this comment

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

ditto.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@bhaktideshmukh Thanks, overall this looks good. Just had a few suggestions. Also, I think the content of the FAQ and other list items in FAQ questions list should be using sub_text color (which is defined in color_defs as color_def_oppia_silver.) and not the Body Header color, you might need to confirm this from the mocks and let me know if It is actually mentioned otherwise in the mocks.

Content of FAQ in mocks is mentioned as 'oppia_primary_text'.

@oppiabot oppiabot bot removed the stale Corresponds to items that haven't seen a recent update and may be automatically closed. label Mar 23, 2022
@oppiabot
Copy link

oppiabot bot commented Mar 23, 2022

Unassigning @ayush0402 since the review is done.

@oppiabot
Copy link

oppiabot bot commented Mar 23, 2022

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

@bhaktideshmukh
Copy link
Contributor Author

@bhaktideshmukh In screenshots dividers are not visible. Mostly because you have removed the drawable. Mostly @Akshatkamboj14 's PRs should help how he fixed the divider issue and once his PRs gets merged I think you won't need to fix it specifically.

This divider issue is still pending.

@oppiabot
Copy link

oppiabot bot commented May 18, 2022

Unassigning @Akshatkamboj14 since the review is done.

@oppiabot
Copy link

oppiabot bot commented May 18, 2022

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

Copy link
Contributor

@rt4914 rt4914 left a comment

Choose a reason for hiding this comment

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

@bhaktideshmukh Please separate FAQListActivity colors from FAQSingleActivity colors correctly.

app/src/main/res/layout/faq_content.xml Outdated Show resolved Hide resolved
@rt4914 rt4914 assigned bhaktideshmukh and unassigned rt4914 May 24, 2022
Copy link
Contributor

@rt4914 rt4914 left a comment

Choose a reason for hiding this comment

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

LGTM, Thanks.

@rt4914 rt4914 merged commit 09b3ba1 into oppia:develop May 27, 2022
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.

Add dark mode support to HelpActivity, FaqListActivity and FaqSingleActivity
6 participants