GithubHelp home page GithubHelp logo

Comments (8)

slorber avatar slorber commented on June 3, 2024 1

Note once you play with the theme toggle, your choice becomes persisted in localstorage and we don't use the system color anymore: it is only used for the initial visit, so make sure to use an incognito session or clear localstorage before testing.

We also have a respectPrefersColorScheme option to use system color in priority.

from infima.

slorber avatar slorber commented on June 3, 2024 1

(oh didn't notice we are on the Infima repo, but anyway this is a Docusaurus-related topic, not really Infima, because Infima only adapt its CSS according to a HTML class name that the Infima user (ie Docusauurs) has to set.

from infima.

yangshun avatar yangshun commented on June 3, 2024 1

but wonder why do you care that much? 😅

Maybe cuz Hacktoberfest. Feel free to make a PR!

from infima.

AJAYK-01 avatar AJAYK-01 commented on June 3, 2024

(oh didn't notice we are on the Infima repo, but anyway this is a Docusaurus-related topic, not really Infima, because Infima only adapt its CSS according to a HTML class name that the Infima user (ie Docusauurs) has to set.

Cool, Docusauurs doesn't seem to have any such issue, my bad, thanks for pointing out.
I was just looking for beginner friendly stuff to contribute :)

from infima.

AJAYK-01 avatar AJAYK-01 commented on June 3, 2024

Note once you play with the theme toggle, your choice becomes persisted in localstorage and we don't use the system color anymore: it is only used for the initial visit, so make sure to use an incognito session or clear localstorage before testing.

We also have a respectPrefersColorScheme option to use system color in priority.

Heyya, looks like the docusaurus.config.js of the infima website doesn't have the property respectPrefersColorScheme set to true.
Upon trying locally the website seems to open with light/dark theme depending upon the system theme only when this property is set to true like you mentioned

Is this intentional or would you welcome an update making that true? 😄

from infima.

slorber avatar slorber commented on June 3, 2024

Hey

You can add that respectPrefersColorScheme: true config if you want, but wonder why do you care that much? 😅

from infima.

AJAYK-01 avatar AJAYK-01 commented on June 3, 2024

Hey

You can add that respectPrefersColorScheme: true config if you want, but wonder why do you care that much? 😅

Nothing much, I was just looking at the docs, and I tend to get most websites in dark mode since I set my system to dark mode. I understand it is not a big deal to have it by default, as there is the switch, but I just tend to notice things like this since light mode burns my eyes 😅. Never mind 😇

from infima.

AJAYK-01 avatar AJAYK-01 commented on June 3, 2024

but wonder why do you care that much? 😅

Maybe cuz Hacktoberfest. Feel free to make a PR!

Okay 😄

from infima.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.