ecency / ecency-vision

Immutable, decentralized, uncensored, rewarding communities built, owned and operated by its users
https://ecency.com
MIT License
57 stars 55 forks source link

Suggestion: Honor `prefers-color-scheme` and change theme cookie lifespan #603

Closed mciszczon closed 2 years ago

mciszczon commented 3 years ago

I have a suggestion to enhance the Ecency browser app by either (or both) making it honor the prefers-color-scheme CSS media to automatically turn on the night mode, even when a cookie for that is not set.

Another proposition from me is to extend the lifespan of theme cookie. Currently it's a session cookie only, so once I restart the browser (or restart the PC, or reboot into a different OS) I have to go and change the theme again. Very frustrating. IMHO the expires value could be set to something arbitrarily high, like half a year or one year maybe.

I could theoretically do a PR with these, as these two changes should be no-brainers, but:

  1. I am not sure whether these changes would be a gladly welcomed additions.
  2. At this time I lack the free time to get to this.

So I am leaving it here for consideration, hoping for a feedback :)

feruzm commented 3 years ago

@mciszczon looks like a great additions, feel free to do a PR, of course we will consider and happy to see you contribute, in same PR please add your username in contributors.json so you will be listed in https://ecency.com/contributors. If any questions, issues, feel free let us know.

mciszczon commented 3 years ago

@feruzm Okay, I'll try to make a PR next week, thanks for the feedback!