-
Notifications
You must be signed in to change notification settings - Fork 27
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FR][Extension Options Panel] Add Pin "addon button" to Toolbar #79
Comments
Extensions Options Panel doesn't have a context menu, so where would that be added? And unfortunately it's not a replacement for the Unified Extensions Panel. The ability to notify you when an addon needs permission to do something on the tab, and allow you to say yes/no for that page only, is not something I can replicate easily for Extensions Options Panel :/ I wouldn't advise removing it. |
I guess this panel because we have plenty of space, being able to pin addon buttons is great because that means I don't have to care a lot about the unified button. Most of my addons don't ask about permissions so I didn't know about that but thanks. |
Hmm... so, the panel doesn't have any items from the context menu or Unified Extensions panel, because the panel and the context menu operate on different subjects. The subject of the context menu is the "browser action," in other words, the toolbar button. Conversely, the subject of the panel is the extension itself. Now it's theoretically possible to put browser action options in the panel, because an extension can have only one or zero browser actions. So we wouldn't run into issues like, the extension has 2 browser actions, so which one are the options for? But it still isn't really what the script was designed for. I'm not against the feature in principle, I just don't feel a strong obligation to do that because the panel was never intended as a replacement for the browser action context menu or the UE panel. Its purpose is to take the options from about:addons and put them in a panel, so that you don't have to open a new tab to access the lower-level extension options from about:addons. Adding more functions couldn't hurt, but I just don't have as much free time these days as when I wrote the script originally (I didn't work for mozilla then so this was all just a fun hobby 😂). And I definitely can't commit to the goal (and maintenance) of making this a complete replacement for the UE panel, so I wouldn't want to give the impression that it's safe to hide that completely. I'll admit, the release of the UE panel basically obviated this script. It was kinda frustrating since that came out so soon after I released this script. If I had started working on this project after the UE panel came out, then I would have gone about it completely differently. I probably would have added these options to the UE panel, rather than adding them to a brand new panel. I think it doesn't make sense for us to try maintaining parity with the UE panel, so we can replace it, when we could just extend the UE panel and fill in whatever's missing from it. It would be cool if, instead of a gear button, there was an ➡ arrow button which opened the subview I created for my EO panel (the subview in your screenshot). Then, all the options from the UE panel's gear menu could be displayed in that subview, along with all the options I added for the EO panel subviews. Then it would really be a "unified" extensions panel, with all options for both the browser action and the extension itself. But that's basically redoing the script from the ground up and I don't know when I'll have time to do that. I'll leave this open though. There are a lot of requests in the backlog here but I do get around to them from time to time. In the meantime, you could probably add this feature yourself if you really need it. It should be pretty straightforward to add a new checkbox and do something like this when it's toggled const extension = this.extensionForAddonId(id);
const browserAction = extension.apiManager.global.browserActionFor(extension);
const checkbox = event.target;
if (browserAction) {
gUnifiedExtensions.pinToToolbar(
browserAction.widget?.id,
checkbox.getAttribute("checked") == "true"
);
} There are a lot of examples of similar code using the same relevant modules in extensionOptionsPanel.uc.js and debugExtensionInToolbarContextMenu.uc.js. |
I kinda understand, but I think the unified button is still not matured enough, it doesn't offer ways to disable/enable addons which is a killer feature (maybe in the future). Extension Options Panel is still useful for me in this case, but it's kinda wierd to have 2 similar buttons which I usually click the wrong one when I need the other. I can wait for the unified button to add more features tho, no big problem. I guess the feature request can now be closed, thanks for replying, very appreciate your time and your work! |
Yeah UE panel is missing some conspicuous general options obviously, but it has MV3 capabilities that would be very hard for me to recreate. Actually the amount of code for the UE panel dwarfs the amount of code for my EO panel. Because those features are just so complicated to implement. But I'm sure it will continue to be developed over time. Anyway, I would leave this open. There isn't really any reason to close it, since I will certainly find time to work on scripts again. And if the issue isn't open then I won't remember about this one, and end up working on some other issue instead. |
Is your feature request related to a problem? Please describe.
Firefox's Unified Button can Pin "addon button" to Toolbar but currently Extension Options Panel can't
Describe the solution you'd like
So if Extension Options Panel can Pin "addon button" to Toolbar we can just get rid of the Firefox's Unified Button
Describe alternatives you've considered
We should add a menu to pin addon to toolbar
Additional context
Nothing
The text was updated successfully, but these errors were encountered: