diff --git a/background.js b/background.js new file mode 100644 index 0000000..9419e80 --- /dev/null +++ b/background.js @@ -0,0 +1,3 @@ +browser.browserAction.onClicked.addListener((tab) => { + console.log(tab.url); +}); diff --git a/dashboard.js b/dashboard.js index ef9fe95..efc7131 100644 --- a/dashboard.js +++ b/dashboard.js @@ -1,5 +1,6 @@ var buttonsize = 250; -document.addEventListener("keyup", (event) =>{ + +document.addEventListener("keyup", (event) => { if (event.ctrlKey && event.code == "Enter") { console.log("pressed"); var dashboard = document.querySelector('#lit-dashboard'); @@ -18,6 +19,7 @@ document.addEventListener("keyup", (event) =>{ function onError(error) { console.log(`Error: ${error}`); } + function deleteButtons(dashboard) { document.getElementById("dashboard-nextcloud-button").remove(); @@ -98,4 +100,4 @@ function onGot(item) { } let getting = browser.storage.sync.get("baseUrl"); -getting.then(onGot, onError); \ No newline at end of file +getting.then(onGot, onError); diff --git a/manifest.json b/manifest.json index 182f6f6..5aa1699 100644 --- a/manifest.json +++ b/manifest.json @@ -29,6 +29,16 @@ "gecko": { "id": "addon@example.com" } + }, + "background": { + "scripts": ["background.js"] + }, + "browser_action": { + "default_icon": { + "19": "button/geo-19.png", + "38": "button/geo-38.png" + }, + "default_title": "Holsteincloud 3.0" } -} \ No newline at end of file +}