diff --git a/background.js b/background.js deleted file mode 100644 index 6dea0da..0000000 --- a/background.js +++ /dev/null @@ -1,19 +0,0 @@ -chrome.runtime.onInstalled.addListener(() => { - chrome.contextMenus.create({ - id: 'openInMantis', - title: 'Open in Mantis', - contexts: ['selection'] - }); -}); - -chrome.contextMenus.onClicked.addListener((info) => { - if (info.menuItemId === 'openInMantis') { - let selectedText = info.selectionText; - if (selectedText.startsWith('#')) { - selectedText = selectedText.substring(1); - } - const fixedUrl = 'https://ot.syncore.at/view.php?id='; - const completeUrl = `${fixedUrl}${selectedText}`; - chrome.tabs.create({ url: completeUrl }); - } -});