Skip to content
  • Recent
  • Tags
  • Popular
  • Users
  • Search
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse

Lay Theme Forum

  1. Home
  2. General Discussion
  3. menu text color change when overlapping with images

menu text color change when overlapping with images

Scheduled Pinned Locked Moved General Discussion
7 Posts 2 Posters 125 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • P Offline
    P Offline
    piotr
    wrote on last edited by
    #1

    Hi there,

    I’m working on a minimalistic website. Here’s a link to the draft:

    https://lightpink-nightingale-503473.hostingersite.com/projects/

    While the website is quite simple, I’d like to add a special effect. Specifically, I want the menu text to turn white when it overlaps with images or project thumbnails while scrolling.

    I’ve searched through the forum for solutions and found similar entries—such as those explaining how to change menu text color based on the row background colors. I attempted to use the same principle, but instead of assigning the custom class to a row, I applied it to the project thumbnails or images. Unfortunately, it didn’t do anything.

    Ideally, I’d also like to extend this effect to the site title and potentially other normal text elements.

    Any advice or suggestions would be greatly appreciated!

    @arminunruh
    @Richard
    @mariusjopen

    1 Reply Last reply
    0
    • arminunruhA Online
      arminunruhA Online
      arminunruh
      Global Moderator
      wrote on last edited by arminunruh
      #2

      for menus:

      .laynav.desktop-nav{
      mix-blend-mode: difference;
      }
      

      Enter this css in "lay options" -> "custom css & html" -> "custom css for desktop"

      but you have to use a white color font for your menu items.
      in customize → menu style → primary menu → text color

      and possibly in
      in customize → menu style → menu point active → text color
      in customize → menu style → menu point mouseover → text color

      1 Reply Last reply
      0
      • arminunruhA Online
        arminunruhA Online
        arminunruh
        Global Moderator
        wrote on last edited by
        #3

        for site title:

        .sitetitle{
        mix-blend-mode: difference;
        }
        

        and you need to set the site title to white font too!

        I think if you had a black background website maybe you need to set the texts to black not sure about that!

        1 Reply Last reply
        0
        • P Offline
          P Offline
          piotr
          wrote on last edited by piotr
          #4

          Hi Armin, thanks for the reply!

          I get a message when I paste the code: "Unknown property: mix-blend-mode"

          Does it mean then that the menu text will automatically change to black while scrolling down when it overlaps with the background instead of the project thumbnail or an image? Or do I need to add some extra custom CSS and assign class to a row for instance?

          1 Reply Last reply
          0
          • arminunruhA Online
            arminunruhA Online
            arminunruh
            Global Moderator
            wrote on last edited by
            #5

            the code for the editor is just so old, it doesnt recognize that css as valid css

            no extra css is needed
            the color will always depend on whats beneath the text

            1 Reply Last reply
            0
            • P Offline
              P Offline
              piotr
              wrote on last edited by
              #6

              Hi @arminunruh

              Thanks a lot, it worked great! Quick question, as an option - will it be very complicated to make it changing to pure white text color when overlapping with an image? Screenshot 2025-01-24 at 23.07.16.png

              1 Reply Last reply
              0
              • arminunruhA Online
                arminunruhA Online
                arminunruh
                Global Moderator
                wrote on last edited by
                #7

                thats not possible i think

                1 Reply Last reply
                0
                • P piotr referenced this topic on
                Reply
                • Reply as topic
                Log in to reply
                • Oldest to Newest
                • Newest to Oldest
                • Most Votes


                I also code custom websites or custom Lay features.
                💿 Email me here: 💿
                info@laytheme.com

                Before you post:
                1. When using a WordPress Cache plugin, disable it or clear your cache.
                2. Update Lay Theme and all Lay Theme Addons
                3. Disable all Plugins
                4. Go to Lay Options → Custom CSS & HTML, click "Turn Off All Custom Code", click "Save Changes"

                This often solves issues you might run into

                When you post:
                1. Post a link to where the problem is
                2. Does the problem happen on Chrome, Firefox, Safari or iPhone or Android?
                3. If the problem is difficult to explain, post screenshots / link to a video to explain it
                Online Users
                arminunruhA
                arminunruh
                F
                francesco
                L
                lurchifon
                Forgot your key, lost your files, need a previous Lay Theme or Addon version? Go to www.laykeymanager.com
                laytheme.com
                • Login

                • Don't have an account? Register

                • Login or register to search.
                • First post
                  Last post
                0
                • Recent
                • Tags
                • Popular
                • Users
                • Search