bitcrowd / tickety-tick

A browser extension that helps you name branches and write better commit messages
MIT License
57 stars 10 forks source link

[#176] Support dark themes in Firefox #227

Closed klappradla closed 4 years ago

klappradla commented 4 years ago

This addresses a point @bitboxer mentioned in #176: the dark icon may be "too dark" when using a dark theme or macOS' dark mode.

This is a suggestion on how we could support this (at least for Firefox) 🦊 using the theme_icons property in browser_action.
By configuring this, we can show a light menu icon when users use the dark Firefox theme (or macOS "dark mode").

I also - this is only an experiment ⚠️ - changed the colors to match the ones recommended in Firefox' styleguide on iconography πŸ–ŒοΈ

The two colors are:

This would look like this:

dark 🏴

Screenshot 2020-04-16 at 18 28 30

light 🏳️

Screenshot 2020-04-16 at 18 28 39

The icon changes automatically without adding additional scripts: firefox

NOTE It would also be possible to support this behavior in Chrome. I could only reproduce this via JS and having additional events in the background.js... I personally find the price too high for just the color of the icon for now.

I could - if people are interested - play around with the Chrome approach in a separate PR though. Happy to do that πŸ€“

klappradla commented 4 years ago

PS: the adaption of the build-icons script was only blindly throwing things in with only half my brain on... We can probably revert most of it πŸ˜‰

klappradla commented 4 years ago

Done now @pmeinhardt πŸ§‘β€πŸ­ Had lots of interruptions, sorry πŸ™‡

Million thanks for the review by the way! Really neat points, love the outcome of this πŸ–€