• Resolved abel1011

    (@abel1011)


    Hi,

    I’m using the global variables system in GreenShift and would like to know the best way to implement a style change for dark mode using these variables. In the plugin documentation, I saw an example that shows how to change the button color depending on whether the page is in light or dark mode:

    body {
    --colorbtn: red;
    }

    body.darkmode {
    --colorbtn: white;
    }

    I would like to know if there is a way to handle these kinds of dynamic changes directly within GreenShift’s variable system, rather than doing it manually in the theme’s CSS file. What would be the best practice for working with variables and applying dark mode changes?

    Additionally, would it be possible to change the default class that is added for dark mode (e.g., darkmode in this case) to something custom?

    I appreciate any guidance or recommendations on this.

    Thank you for your attention.

    Best regards,

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.