-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Runtime notifications permission #18239
Runtime notifications permission #18239
Conversation
NotificationsPermissionBottomSheetFragment is a bottom sheet to navigate user to the App Settings.
📲 You can test the changes from this Pull Request in WordPress by scanning the QR code below to install the corresponding build.
|
📲 You can test the changes from this Pull Request in Jetpack by scanning the QR code below to install the corresponding build.
|
@irfano - Great work!
|
<string name="notifications_permission_dismiss_content_description">Dismiss notification permission warning.</string> | ||
<string name="notifications_permission_off_desc">Push notifications are turned off.</string> | ||
<string name="notifications_permission_bottom_sheet_title">Push notifications are turned off</string> | ||
<string name="notifications_permission_bottom_sheet_description_1">You’ll need to open the app to see notifications.</string> |
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.
Missing escape \ character before ' in You'll. Also, same below L:4071
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.
I've learned that ’
and '
are different. 😄 I copied strings from Figma, which uses ’
, that's why the IDEA didn't show an error. But I've changed ’
to '
. They both are okay but standard '
is more popular in our strings.
Done: 6ee77da
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.
Finally, it's done! 🚀
That makes sense 👍🏻
Some users may be aware that notifications are turned off and just want to close the banner. But as a side effect, other users who are unaware of it may tap "X" by mistake and lose the benefit of the banner. |
Found 1 violations: The PR caused the following dependency changes:-\--- org.wordpress:utils:{strictly 3.5.0} -> 3.5.0
+\--- org.wordpress:utils:{strictly trunk-3c3d298621fda50b5cbf6b981b78920b80fa82b4} -> trunk-3c3d298621fda50b5cbf6b981b78920b80fa82b4
Please review and act accordingly
|
…13)' into issue/17714-notification-runtime-permission
I think it changes that how many times you can deny the system's native permission dialog until we can't show it anymore. Because I can see and deny the system's native permission dialog twice after the clean install. |
…13)' into issue/17714-notification-runtime-permission
Generated by 🚫 dangerJS |
e1ff390
into
Parent-PR-for-updating-targetSdkVersion-to-33-(Android-13)
Fixes #17714
This PR adds runtime notifications permission support.
Notifications screen
This adds a yellow warning box to the notifications screen. It's visible when the notification permission is not allowed.
Blogging reminders
This adds a notification permission step to the blogging reminders flow. If the permission is denied and the app can't show the system's native permission dialog, the "Go to Settings → Notifications → App Settings, and turn WordPress on to be notified immediately." message will be displayed. Otherwise, it will be invisible.
Design: YSbDG4YKoDDkjEZSfBrIlN-fi-1300_13590
To test:
Test both on the API 33 device and a lower version device. The behavior shouldn't change on older devices.
Notifications screen - Allow
Notifications screen - Deny
Blogging reminders screen - Allow
Blogging reminders screen - Deny
Regression Notes
Potential unintended areas of impact
Setting blogging Reminders.
What I did to test those areas of impact (or what existing automated tests I relied on)
Tested manually.
What automated tests I added (or what prevented me from doing so)
Updated current tests.
PR submission checklist:
RELEASE-NOTES.txt
if necessary.