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. Navbar blur + box-shadow?

Navbar blur + box-shadow?

Scheduled Pinned Locked Moved General Discussion
blurbox-shadownavbar
4 Posts 2 Posters 334 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.
  • N Offline
    N Offline
    nm
    wrote on May 7, 2022, 8:56 PM last edited by nm May 7, 2022, 4:57 PM
    #1

    I would like to use the blur function of the navbar, but have it fade in opacity instead of having a hard edge. Not sure if this is possible?

    I have figured out how to do the following with a solid navbar background using the following code:

    navbar {
        box-shadow: 0px -15px 30px 20px #000000;
    }
    

    ie:
    solid_navbar.jpg

    Is it possible to acheive a similar result with the blurred navbar, like this mockup?

    ie:
    mockup.png

    vs the default blur with hard edge:
    blur navbar.jpg

    1 Reply Last reply
    0
    • R Offline
      R Offline
      Richard
      Global Moderator
      wrote on May 10, 2022, 9:21 PM last edited by
      #2

      Dear @nm

      Are you able to post a link to your website with Navbar? 🌝 🔍


      Best
      Richard
      1 Reply Last reply
      0
      • N Offline
        N Offline
        nm
        wrote on May 11, 2022, 9:49 PM last edited by
        #3

        Hey Richard,

        Absolutely! It's not public yet, but the staging URL is:

        https://nathanmartell.dreamhosters.com/

        pw: almostdone

        1 Reply Last reply
        0
        • R Offline
          R Offline
          Richard
          Global Moderator
          wrote on May 23, 2022, 12:23 AM last edited by
          #4

          Dear Nathan

          @nm

          Yes this will be a bit tricky but you can get there, you can apply a nice blur using back-drop-filter:blur :

          https://www.w3schools.com/cssref/css3_pr_backdrop-filter.asp

          Result:

          Screen Shot 2022-05-23 at 11.57.29 AM.png

          This is good when the Navbar is not interacting with another element behind it to blur off, i noticed this when using the standard 'filter:blur'.

          The tricky part is the box-shadow but this thread outlines a possible solution:

          https://stackoverflow.com/questions/52140378/using-a-shadow-together-with-backdrop-filter-blur

          Even better would be to use the Blur function and Drop shadow in the same, for example with the backdrop filter you can apply multiple settings:

          .element {
            backdrop-filter: grayscale(0.5) opacity(0.8) /* ...and on and on... */;
          }
          

          Outlined here:

          https://css-tricks.com/almanac/properties/b/backdrop-filter/

          So you could have blur and drop shadow together within the backdrop filter.

          Best wishes and good luck! ⭐️


          Richard
          1 Reply Last reply
          0
          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
          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