mirror of
https://github.com/schlagmichdoch/PairDrop.git
synced 2025-04-22 07:46:17 -04:00
Add notifications-permissions-error to translations
This commit is contained in:
parent
ca8a5de47e
commit
4e00e5b358
4 changed files with 6 additions and 16 deletions
|
@ -2073,11 +2073,11 @@ class Notifications {
|
|||
_requestPermission() {
|
||||
Notification.requestPermission(permission => {
|
||||
if (permission !== 'granted') {
|
||||
Events.fire('notify-user', Notifications.PERMISSION_ERROR || 'Error');
|
||||
Events.fire('notify-user', Localization.getTranslation("notifications.notifications-permissions-error"));
|
||||
return;
|
||||
}
|
||||
Events.fire('notify-user', Localization.getTranslation("notifications.notifications-enabled"));
|
||||
this.$button.setAttribute('hidden', 1);
|
||||
this.$button.setAttribute('hidden', "");
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -2784,9 +2784,3 @@ window.addEventListener("keydown", (e) => {
|
|||
window.location.hash = '#';
|
||||
}
|
||||
});
|
||||
|
||||
Notifications.PERMISSION_ERROR = `
|
||||
Notifications permission has been blocked
|
||||
as the user has dismissed the permission prompt several times.
|
||||
This can be reset in Page Info
|
||||
which can be accessed by clicking the lock icon next to the URL.`;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue