1
0
mirror of https://github.com/kkapsner/CanvasBlocker synced 2024-11-11 07:38:58 +01:00

Improved browser action title

As mentioned in #233.
This commit is contained in:
kkapsner 2018-08-22 22:37:06 +02:00
parent 0d1738d328
commit 391deae6f1
4 changed files with 30 additions and 4 deletions

View File

@ -8,6 +8,19 @@
"description": ""
},
"browserAction_title_default": {
"message": "CanvasBlocker",
"description": ""
},
"browserAction_title_notified": {
"message": "CanvasBlocker\n\nSchutz erfolgreich für:",
"description": ""
},
"browserAction_title_protectedAPIs": {
"message": "\n \u00B7 {api}",
"description": ""
},
"more": {
"message": "mehr",
"description": ""

View File

@ -8,6 +8,19 @@
"description": ""
},
"browserAction_title_default": {
"message": "CanvasBlocker",
"description": ""
},
"browserAction_title_notified": {
"message": "CanvasBlocker\n\nprotection successful for:",
"description": ""
},
"browserAction_title_protectedAPIs": {
"message": "\n \u00B7 {api}",
"description": ""
},
"more": {
"message": "more",
"description": ""

View File

@ -67,11 +67,11 @@
let apiList = "";
apis.forEach(function(api){
apiList += "\n \u00B7 " + api;
apiList += browser.i18n.getMessage("browserAction_title_protectedAPIs").replace(/{api}/g, api);
});
browser.browserAction.setTitle({
tabId: tabId,
title: "CanvasBlocker" + apiList
title: browser.i18n.getMessage("browserAction_title_notified") + apiList
});
};
@ -93,7 +93,7 @@
});
browser.browserAction.setTitle({
tabId: tabId,
title: "CanvasBlocker"
title: browser.i18n.getMessage("browserAction_title_default")
});
};

View File

@ -57,7 +57,7 @@
"browser_action": {
"browser_style": false,
"default_icon": "icons/browserAction-notPrinted.svg",
"default_title": "CanvasBlocker",
"default_title": "__MSG_browserAction_title_default__",
"default_popup": "browserAction/browserAction.html"
},
"page_action": {