-
Notifications
You must be signed in to change notification settings - Fork 499
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 #4451: Add domain level functionality for spotlights #4498
Fix #4451: Add domain level functionality for spotlights #4498
Conversation
Please take an initial pass at this |
Hi @JishnuGoyal, 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. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @JishnuGoyal! Took a first pass review--PTAL.
domain/src/main/java/org/oppia/android/domain/spotlight/SpotlightStateController.kt
Outdated
Show resolved
Hide resolved
domain/src/main/java/org/oppia/android/domain/spotlight/SpotlightStateController.kt
Outdated
Show resolved
Hide resolved
domain/src/main/java/org/oppia/android/domain/spotlight/SpotlightStateController.kt
Outdated
Show resolved
Hide resolved
domain/src/main/java/org/oppia/android/domain/spotlight/SpotlightStateController.kt
Outdated
Show resolved
Hide resolved
domain/src/main/java/org/oppia/android/domain/spotlight/SpotlightStateController.kt
Outdated
Show resolved
Hide resolved
Hi @JishnuGoyal, 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. |
@BenHenning Please check if this is on the right track; ill be adding tests in my upcoming commit. PTAL |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @JishnuGoyal! I think this is much clearer now! There's one comment you didn't respond to earlier, but otherwise I only had a few more follow-ups. Please go ahead and finish up this PR and send it back when you're ready.
Note also that it appears there are some CI checks failing, as well. I noticed the lint checks are failing in particular--have you run setup.sh locally for your repository? It adds a pre-push hook to check for common lint errors before pushing and helps reviewers avoid needing to look at various nits.
domain/src/main/java/org/oppia/android/domain/spotlight/BUILD.bazel
Outdated
Show resolved
Hide resolved
domain/src/main/java/org/oppia/android/domain/spotlight/SpotlightStateController.kt
Outdated
Show resolved
Hide resolved
domain/src/main/java/org/oppia/android/domain/spotlight/SpotlightStateController.kt
Outdated
Show resolved
Hide resolved
domain/src/main/java/org/oppia/android/domain/spotlight/BUILD.bazel
Outdated
Show resolved
Hide resolved
PTAL @BenHenning , thanks! |
Unassigning @JishnuGoyal since a re-review was requested. @JishnuGoyal, please make sure you have addressed all review comments. Thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @JishnuGoyal. Took another pass--PTAL.
domain/src/main/java/org/oppia/android/domain/spotlight/SpotlightStateController.kt
Outdated
Show resolved
Hide resolved
domain/src/test/java/org/oppia/android/domain/spotlight/SpotlightStateControllerTest.kt
Outdated
Show resolved
Hide resolved
domain/src/test/java/org/oppia/android/domain/spotlight/SpotlightStateControllerTest.kt
Outdated
Show resolved
Hide resolved
domain/src/test/java/org/oppia/android/domain/spotlight/SpotlightStateControllerTest.kt
Outdated
Show resolved
Hide resolved
domain/src/test/java/org/oppia/android/domain/spotlight/SpotlightStateControllerTest.kt
Outdated
Show resolved
Hide resolved
domain/src/main/java/org/oppia/android/domain/spotlight/SpotlightStateController.kt
Outdated
Show resolved
Hide resolved
@BenHenning PTAL please take another pass at this, thanks. |
Unassigning @JishnuGoyal since a re-review was requested. @JishnuGoyal, please make sure you have addressed all review comments. Thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @JishnuGoyal. Other than the CI failures, the PR LGTM. Please assign back once they're fixed.
… into 1.7_domain_layer_for_spotlights # Conflicts: # domain/src/test/java/org/oppia/android/domain/spotlight/SpotlightStateControllerTest.kt
PTAL @BenHenning |
Unassigning @JishnuGoyal since a re-review was requested. @JishnuGoyal, please make sure you have addressed all review comments. Thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @JishnuGoyal. Everything LGTM here.
Explanation
Fixes #4451
This PR lays the domain-level foundation for "Spotlights". These are a part of the Interactive On-boarding Flow (GSoC) project which focuses on making the initial user experience easier and interactive, and aims to make the user start learning effectively as soon as possible.
spotlight.proto
is a model class that holds the information about which spotlights have/have not been seen yet by the user.SpotlightStateController
is an injectable class which controls the domain level functionality needed to make changes to the above model class. Essentially, this class can mark spotlights "seen" and retrieve the spotlight states (where states determine whether they are seen/unseen).The entire Spotlight experience can be turned on or off just by setting the platform parameter flag called
EnableSpotlightUi
to true or false.This PR is backed by necessary tests to check if the domain layer for spotlights works correctly or not.
Essential Checklist