Open Victor239 opened 4 years ago
Hmm, so I have been converting the extension to Firefox, and while everything is compatible, there's an issue with getDisplayMedia, where I cannot run it from the extension background as it requires a "user gesture", meaning it can only be triggered directly from a DOM event (e.g. button click). This is a problem because in this case the code would have to be in the popup or a content script, and neither of those options are viable. The popup wouldn't work whatsoever because the moment it's been closed, the recording would be stopped. The content script might work to an extent, but it would require the tab to be opened at all times (a separate tab?), as if the user closed it the recording would also stop.
I have looked at other extensions available for Firefox and indeed, it seems everyone has run into this problem, I can barely find options, and the few there are use the second approach I mentioned, when you want to start recording a new tab opens and you need to click a "start recording" button while leaving that tab open. It's very unintuitive for sure, so I am honestly not sure what to do about it - is it worth rewriting the code and releasing a confusing version of Screenity for Firefox? I'm really not sure.
Hi @alyssaxuu ! Can you provide the rewritten code for the firefox-addon? Will be very interesting how you handled some things.. Would be great, thanks!
For the recording problem: Have you considered opening the code for capturing in a sidebar? Would this even help?
Hi @alyssaxuu ! Can you provide the rewritten code for the firefox-addon? Will be very interesting how you handled some things.. Would be great, thanks!
For the recording problem: Have you considered opening the code for capturing in a sidebar? Would this even help?
I really didn't have to make that many changes, mostly changing chrome to browser, disabling tab capture (since it's not available in Firefox), and some manifest settings. I don't know if the current code would work since I got stuck on the desktop recording thing.
I considered having it be a content script VS in the popup like Loom does, but again, if the tab is closed at any point during the recording, it will stop. So if you start recording and you click a link, it will stop, while Screenity in Chrome will continue the recording, even if you switch tabs or close them (in desktop recordings). So not really sure what to do.
Hi @alyssaxuu , you may be able to get some support for this from the addons team in the Mozilla Matrix #addon room.
A Firefox version would be great!
Hey,
Just joining to show my excitement for a FF version :+1: haha
Would be awesome if it would end up being possible!
Cheers!
Hmm, so I have been converting the extension to Firefox, and while everything is compatible, there's an issue with getDisplayMedia, where I cannot run it from the extension background as it requires a "user gesture", meaning it can only be triggered directly from a DOM event (e.g. button click). This is a problem because in this case the code would have to be in the popup or a content script, and neither of those options are viable. The popup wouldn't work whatsoever because the moment it's been closed, the recording would be stopped. The content script might work to an extent, but it would require the tab to be opened at all times (a separate tab?), as if the user closed it the recording would also stop.
@alyssaxuu screenity uses chrome manifest v2 but the same issue mentioned above will occur when you have to switch to chrome manifest v3 meaning the background "script" (called service worker in v3) doesn't have access to tabCapture
API. You may want to look into it as manifest v2 will be slowly phased out starting January 2022.
Blog post announcing timeline: https://developer.chrome.com/blog/mv2-transition/
Thank you for such great extension
@alyssaxuu Did you manage to use chrome.tabCapture.capture
in Firefox? I read that this should be possible (in this issue and here), but I get the following error to invoke this API in Firefox:
Error: chrome.tabCapture is undefined
Maybe do you need any other permission in the manifest?
any updates here?
Any alternatives?
I considered having it be a content script VS in the popup like Loom does, but again, if the tab is closed at any point during the recording, it will stop. So if you start recording and you click a link, it will stop, while Screenity in Chrome will continue the recording, even if you switch tabs or close them (in desktop recordings).
I think that this is reasonable for sake of security — especially recording after closing seems to be a thing that malicious codes would do. Also, it is better to have a single code base in order to make maintenance easier.
As Firefox appears to be supporting MV3 extensions now, I think I should be able to port Screenity there with the new version I've been working on :)
I've just released the new MV3 version of Screenity for Chrome. I will now look into making any required changes to have it work for Firefox. You can register interest for Firefox in this form.
Hi @alyssaxuu,
I am a big fan of the screenity app. Thanks for your work. Is there any news when we can expect a Firefox extension?
Extension looks great, would love to see this ported to Firefox as well.