stylix icon indicating copy to clipboard operation
stylix copied to clipboard

firefox: add darkReader option

Open 0xda157 opened this issue 9 months ago • 10 comments

~~Haven't tested locally yet~~ Currently not working because dark reader doesn't have support for config via hm.

resolves #495 cc: @brckd

0xda157 avatar Mar 03 '25 04:03 0xda157

Good idea! Last time I looked though, dark reader couldn't be configured using extension storage or policies, but please correct me if I'm wrong. In that case, we could check out darkreader/darkreader#12920 which aims to add support for policies. I think @voronind-com made a Nix config that uses that. darkreader/darkreader#2168 seems to offer a solution for syncing colors during runtime alongside this nix config.

brckd avatar Mar 03 '25 08:03 brckd

I think @voronind-com made a Nix config that uses that.

Yes, I do indeed patch the Dark Reader with that PR and use colors from the Stylix. No issues apart from the fact that I need to allow the installation of unsigned ff extensions.

I don't update the colors on a running ff instance as the browser itself requires a restart to apply new colors.

Would be happy to help.

voronind-com avatar Mar 03 '25 10:03 voronind-com

No issues apart from the fact that I need to allow the installation of unsigned ff extensions.

That is indeed a problem because AFAIK this cannot be automated and is a security regression. The DarkReader README also mentions that signing keys for Firefox are available, but I wasn't able to successfully deploy these.

I don't update the colors on a running ff instance as the browser itself requires a restart to apply new colors.

Shouldn't be a problem since that's how most apps behave.

Would be happy to help.

I appreciate it!

brckd avatar Mar 03 '25 12:03 brckd

I wasn't able to successfully deploy these.

Me neither, so here we are. The best solution would be to ask the dev to merge the pull request, maybe from the Stylix team. He should be aware about that PR as he left some comments there before.

I appreciate it!

I said that in a hope you could point me to the stuff I could do :p

voronind-com avatar Mar 03 '25 13:03 voronind-com

I think it's not worth it to create a solution just now. I'd rather wait for the darkreader PR to be merged and assist there. But hey, this isn't my PR!

brckd avatar Mar 03 '25 14:03 brckd

Bummer that dark reader can't be configured with hm, I'll just leave this pr as a draft until dark reader adds support.

0xda157 avatar Mar 04 '25 05:03 0xda157

This PR would be able to resolve https://github.com/danth/stylix/issues/253 and https://github.com/danth/stylix/issues/495, right?

trueNAHO avatar Mar 06 '25 13:03 trueNAHO

This PR would be able to resolve #253 and #495, right?

It's won't resolve #253 because it's overriding the website's styling instead of suggesting a polarity.

0xda157 avatar Mar 07 '25 02:03 0xda157

What is the state of this PR?

trueNAHO avatar Apr 29 '25 09:04 trueNAHO

What is the state of this PR?

waiting for https://github.com/darkreader/darkreader/pull/12920 to be merged

0xda157 avatar Apr 29 '25 15:04 0xda157