XTranslate
XTranslate copied to clipboard
Port to firefox / manifest@v3
TODO
- [ ] manifest@v3
content_scripts
not injected automatically (only after opening translator's window via toolbar icon), maybe extra chrome.scripting-api required. Otherwise it works automatically only when user allows it manually per domain/site: Right click at XTranslate icon and Select Extension can access site data: Always - [ ] manifest@v3 doesn't support
background.service_worker
- [ ]
chrome.runtime.sendMessage
and related methods doesn't supportPromise<Response>
- [x]
chrome.tts
doesn't work, could be handled by #58
PREREQUISITES
- Go to
about:config
system page - Set
extensions.manifestV3.enabled
totrue
- Set
xpinstall.signatures.required
tofalse
- You can now install MV3 extensions from
about:debugging
system browser page
Availability in firefox extensions store: (manifest@v2) https://addons.mozilla.org/en-GB/firefox/addon/xtranslate-chrome/
Status: won't be ported while it's not become good browser :)
Problems:
- Shadow-dom api not supported (only with enabled flag in
about:config
) - Lacks of chrome extensions api:
-
chrome.storage.sync
- not supported (thoughchrome.storage.local
can be used as fallback) -
chrome.runtime.onConnect(port => ...)
- whereport.sender.id
is id of window(?), instead of extension, but it has anyway (not-documented?)port.sender.extensionId
- not possible to create custom-scrollbar styles with css-only
and some more minor problems...
Reopened to investigate new changes since then..
Reopened to investigate new changes since then..
Installed your extension in Firefox Developer today and everything seems to be working fine. It seems to me that you could upload the extension to the Firefox store. =)
Is it relevant?
What is relevant? Yes it's still in long non-priority todo-list if you want know ;) If firefox-extensions store is fully compatible with chome-store apis (like edge-store), then (re)solution for the issue would be quite fast & trivial.