css - Shaping the Navbar's Bottom Border -


i trying shape nav wrapper's bottom border triangle pops out in center (ex. image below).

is there way create shape editing/transforming nav wrapper's css regarding bottom border?

the triangle has same uninterrupted background pattern , bottom border drop shadow nav wrapper, thinking should done via css transform rather adding css/image shape on border.

ie:

exmaple nav

thanks!

you can use css pseudo elements :before & :after this. please have @ snippet below:

.nav-bar {    display: flex;    justify-content: center;    align-items: center;    height: 100px;    background: #33b5e5;    color: #fff;    font-size: 50px;    font-weight: 700;    border-bottom: 6px solid #8acee9;    position: relative;  }    .nav-bar:after {    content: '';    position: absolute;    bottom: -30px;    left: 50%;    transform: translatex(-50%);    border-left: 30px solid transparent;    border-right: 30px solid transparent;    border-top: 30px solid #33b5e5;  }    .nav-bar:before {    content: '';    position: absolute;    bottom: -40px;    left: 50%;    transform: translatex(-50%);    border-left: 40px solid transparent;    border-right: 40px solid transparent;    border-top: 40px solid #8acee9;  }
<div class="nav-bar">    navbar  </div>

hope helps!


Comments

Popular posts from this blog

php - trouble displaying mysqli database results in correct order -

depending on nth recurrence of job in control M -

sql server - Cannot query correctly (MSSQL - PHP - JSON) -