• Resolved messingschlager

    (@messingschlager)


    First: the plugin works like a charm, thank you a lot. I just would like to use plain text links instead of the toggle button to switch the dark mode on and off.

    Example:

    My awesome website on bright background

    clicking ?bright? would switch the dark mode on and change the text to

    My awesome website on dark background

    clicking ?dark? would switch the dark mode off and reset the text.

    Could you help me with that? Thanks a lot in advance!

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author markoarula

    (@markoarula)

    Hello,

    after you have added wp-night-mode class on your ‘bright’ text, make this changes inside plugin:

    1.) Open /wp-content/plugins/wp-night-mode/public/js/wp-night-mode-public.js file

    2.) Replace file with this one: wp-night-mode-public.js

    Keep in mind that this file will be overwritten if you update plugin and that you will have to make this changes every time after you update the plugin.

    Best regards

    Thread Starter messingschlager

    (@messingschlager)

    Works great, thank you so much for your help!

    Plugin Author markoarula

    (@markoarula)

    No problem, glad that I could help ??

    Would be great if the file was still available, or the function to be build-in.
    I want to have an text-link also instead of the nice toggle switch ??

    EDIT: I now named an simple div: wpnm-button
    It works like this <div class=”wpnm-button”>Any word you wish</div>

    Probably works work with span or own button to.

    • This reply was modified 4 years, 11 months ago by wpbeveiligen.
    • This reply was modified 4 years, 11 months ago by wpbeveiligen.
    • This reply was modified 4 years, 11 months ago by wpbeveiligen.

    up

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Text links instead of toggle button’ is closed to new replies.