Siderite / lichessTools

Browser extension that turbocharges the lichess.org site with extra functionalities
MIT License
29 stars 6 forks source link

Add Firefox support #815

Closed Karmox closed 2 months ago

Karmox commented 2 months ago

Extensions are standardized between Firefox and Chrome except for a few things such as the way service_workers are defined in the manifest.json. Firefox wants them in a scripts tag as an array and Chrome in the "service_worker" tag. Luckily they each ignore the other tag (only showing a warning). I tested the extension on Firefox with this change and it works great! This change thus adds Firefox support to the extension, without any further work. You previously stated that "Firefox is small and stupid", but its importance lies not in its market share, but rather in it being open source. Furthermore, it is the only thing holding back a complete Chrome monopoly on non Apple devices. Such a monopoly would be devastating for the entire web. Moreover, Firefox has some features that Chrome doesn't have. This would bring lichessTools to mobile devices, seeing as Firefox, unlike Chrome, does support extensions for mobile. Also as a Firefox user I would be very happy using this great extension :) I would appreciate it if you could just merge this (one line change!) and upload the extension to the Firefox store. As far as I know, an account doesn't cost anything. If that's too much hassle for you I would also be fine with doing that, but I don't know if you trust a random guy from the internet with this and I wanted to first hear your feedback before forking the whole project over this little change.

Siderite commented 2 months ago

But, @Karmox , Firefox support has been added already. What is this about?

Siderite commented 2 months ago

I think you forked master, but you are trying to merge to main, which is a few steps behind. So the PR becomes unreadable. Try creating the PR again.

From what I understand, you propose the Manifest v3 format will work for FF now with just that change. I will experiment with this. Thank you!

Siderite commented 2 months ago

Funnily enough, everything works except OBS integration because this: https://discourse.mozilla.org/t/how-to-prevent-upgrading-insecure-request-to-use-wss/126797/4

I have to check if I can somehow make OBS use wss.

Siderite commented 2 months ago

Ugh! https://obsproject.com/forum/threads/websocker-obs-connect-wss-not-working-with-chrome-opera.171191/#post-630825

Siderite commented 2 months ago

And I could specify the content security policy in the extension, but only in V2 :) https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/manifest.json/content_security_policy

Anyway, thanks!

Karmox commented 2 months ago

But, @Karmox , Firefox support has been added already. What is this about?

Ohh I completely missed that, I really don't know how that happened. I am sorry for this unnecessary PR then. Thanks for the swift reply and have a nice weekend!

Siderite commented 2 months ago

Nah, thank you! Join https://lichess.org/team/l1chess-tools-users-team for updates. Mods remove them from Feedback.

olivertzeng commented 1 month ago

But, @Karmox , Firefox support has been added already. What is this about?

Ohh I completely missed that, I really don't know how that happened. I am sorry for this unnecessary PR then. Thanks for the swift reply and have a nice weekend!

It was me! You seem to be a firefox user as well?(in specific i use librewolf