Hard code local notification links
Background
In #34 (closed) we added support for arbitrary links in notifications, the purpose was to allow notifications to link to extension files e.g. "/day1.html"
. Unfortunately, "abp:day1"
was already hard coded in the adblockplusui code so it would be preferable to allow that link to work instead. Furthermore, it would be nice to avoid displaying notifications if any of the linked local pages don't exist.
What to change
- Alter the notificationHelper.js logic to point notification links to
"abp:day1"
to"/day1.html"
. - Further alter the logic to avoid displaying notifications with any other
"abp:"
prefixed link.
Hints for testers
- Test that a notification which links to
"abp:day1
" correctly opens day1.html, on both browsers which support notification buttons and browsers which don't. - Test that a notification which links to
"abp:day1"
and two other pages successfully opens all three pages when the "Open all links" button is clicked. On browsers which don't support buttons test that all three pages are opened when the notification is clicked. - Test that notifications which link to
"abp:day2"
(or anything else with theabp:
prefix except"abp:day1"
) aren't displayed at all. - Test that these notification and notification buttons all behave consistently in the popup window too.
Edited by Dave Vandyke