port to firefox
This commit is contained in:
parent
daa7f81c7a
commit
f39b89efcb
1
_locales/en/messages.json
Normal file
1
_locales/en/messages.json
Normal file
@ -0,0 +1 @@
|
||||
{}
|
@ -1,15 +1,17 @@
|
||||
{
|
||||
"name": "redirect",
|
||||
"version": "0.1.0",
|
||||
"description": "create a redirect directly",
|
||||
"permissions": ["storage", "tabs"],
|
||||
"background": {
|
||||
"service_worker": "background.js"
|
||||
},
|
||||
"action": {
|
||||
"default_icon": "assets/my-icon.png",
|
||||
"browser_action": {
|
||||
"default_title": "redirect",
|
||||
"default_popup": "popup.html"
|
||||
},
|
||||
"manifest_version": 3
|
||||
"content_security_policy": "script-src 'self' https://example.com; object-src 'self'",
|
||||
"default_locale": "en",
|
||||
"description": "create a redirect directly",
|
||||
"manifest_version": 2,
|
||||
"name": "redirect",
|
||||
"page_action": {
|
||||
"default_title": "redirect",
|
||||
"default_popup": "popup.html"
|
||||
},
|
||||
"permissions": ["webNavigation", "tabs"],
|
||||
"version": "0.1"
|
||||
}
|
@ -1,5 +1,5 @@
|
||||
function newRedirect () {
|
||||
chrome.tabs.query({active: true, lastFocusedWindow: true}, tabs => {
|
||||
browser.tabs.query({currentWindow: true, active: true}, tabs => {
|
||||
let currentUrl = tabs[0].url;
|
||||
const url = `${config.shlinkUrl}/rest/v3/short-urls`;
|
||||
let sendData = {
|
||||
|
Reference in New Issue
Block a user