Page MenuHomePhabricator

[Cashtab] [notification permission 1 of 2] Ask for notification permission if peristent storage is not granted
ClosedPublic

Authored by bytesofman on Dec 16 2022, 18:08.

Details

Summary

T2882

Testing shows that persistent storage will be granted in Brave browser if the user approves the notification permission.

This diff asks for notification permission if the persistent storage permission is not granted and the user has not already granted notification permission.

Test Plan

npm run build
netlify deploy

Open the URL netlify has deployed to and check the dev console. You should see Persisted storage status: false. In this case, the app will load instantly with a pop-up asking you to enable notification permissions. Enable.

Refresh the page.
Create a wallet.
Refresh the page.

You should see Persisted storage status: true

Check in Brave, Chrome, and Safari

Diff Detail

Repository
rABC Bitcoin ABC
Branch
ask-for-notification-permission-on-load
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 21610
Build 42861: Build Diffcashtab-tests
Build 42860: arc lint + arc unit