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 #5171: Fixes all warnings in "Accessibility" category #5173

Merged
merged 7 commits into from
Oct 5, 2023

Conversation

theMr17
Copy link
Collaborator

@theMr17 theMr17 commented Oct 2, 2023

Explanation

Fixes #5171

Under this category, the warnings are mainly of 3 types:

  1. Warning: Image without contentDescription.
    Fix: Add a contentDescription to each of those ImageView, or mark as not important for accessibility.

  2. Warning: 'onTouch' lambda should call 'View#performClick' when a click is detected
    Fix: Call customView.performClick( ).

  3. Warning: 'clickable' attribute found, please also add 'focusable'.
    Fix: Set android:focusable="true" as its necessary if android:clickable="true".

image

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

@theMr17 theMr17 requested a review from a team as a code owner October 2, 2023 12:10
@theMr17 theMr17 requested a review from adhiamboperes October 2, 2023 12:10
@theMr17 theMr17 changed the title Fix #5171: All warnings in "Accessibility" category Fix #5171: Fixes all warnings in "Accessibility" category Oct 2, 2023
@adhiamboperes adhiamboperes self-assigned this Oct 3, 2023
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 @theMr17! I have left some suggestions, and once done please attach a screenshot that shows running ./gradlew :app:lint does not raise any of these 3 warnings.

app/src/main/res/layout/app_version_fragment.xml Outdated Show resolved Hide resolved
app/src/main/res/layout/profile_picture_activity.xml Outdated Show resolved Hide resolved
app/src/main/res/layout/walkthrough_final_fragment.xml Outdated Show resolved Hide resolved
app/src/main/res/layout/walkthrough_welcome_fragment.xml Outdated Show resolved Hide resolved
app/src/main/res/values/strings.xml Outdated Show resolved Hide resolved
app/src/main/res/values/strings.xml Outdated Show resolved Hide resolved
app/src/main/res/values/strings.xml Outdated Show resolved Hide resolved
@oppiabot
Copy link

oppiabot bot commented Oct 5, 2023

Unassigning @adhiamboperes since the review is done.

@oppiabot
Copy link

oppiabot bot commented Oct 5, 2023

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

@theMr17
Copy link
Collaborator Author

theMr17 commented Oct 5, 2023

@adhiamboperes PTAL, I have done the changes you suggested. Also, here is the screenshot that shows those 3 warnings are not present anymore.

image

@theMr17 theMr17 requested a review from adhiamboperes October 5, 2023 13:04
@oppiabot oppiabot bot assigned adhiamboperes and unassigned theMr17 Oct 5, 2023
@oppiabot
Copy link

oppiabot bot commented Oct 5, 2023

Unassigning @theMr17 since a re-review was requested. @theMr17, please make sure you have addressed all review comments. 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 @theMr17, this LGTM!

@oppiabot
Copy link

oppiabot bot commented Oct 5, 2023

Unassigning @adhiamboperes since they have already approved the PR.

@oppiabot oppiabot bot added the PR: LGTM label Oct 5, 2023
@oppiabot
Copy link

oppiabot bot commented Oct 5, 2023

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

@adhiamboperes adhiamboperes enabled auto-merge (squash) October 5, 2023 19:02
@adhiamboperes adhiamboperes merged commit 8aefb05 into oppia:develop Oct 5, 2023
36 checks passed
@adhiamboperes adhiamboperes added the Hacktoberfest This is a suggested Hacktoberfest issue. label Oct 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Hacktoberfest This is a suggested Hacktoberfest issue. PR: LGTM
Projects
None yet
Development

Successfully merging this pull request may close these issues.

BUG: Fix All warnings in "Accessibility" category
2 participants