css - Nav Tab active moment image not change -
im added tab image icon , im try when click button (active button) after image icon change book_hover.png
font color change image icon not change ,how replace image after navtab active moment
.footer-tab .tooter-nav-tab { padding: 2rem; height: 10vh; width: 100%; margin-left: 0rem; background: white; border-top: 1px solid #c9cfd9; display: inline; text-align: center; } p.tab-txt { font-size: 0.7rem; } .footer-tab ul { list-style-type: none; margin: 0; padding: 0; border-top: 1px solid #c9cfd9; overflow: hidden; background-color: #ffffff; } .footer-tab li { float: left; } .footer-tab .nav-tabs .nav-link.active { color: white; background-color: #8bb6f3; border-color: #ddd #ddd #fff; } .footer-tab li { display: block; color: #3f5370; text-align: center; padding: 18px 16px; text-decoration: none; } .footer-tab li a:hover { background-color: #8bb6f3; color: white; } .footer-tab-img :active { background:url'https://image.ibb.co/ffsy9f/book_hover.png')no-repeat; color: white; } /*footernavtab*/
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/css/bootstrap.min.css" rel="stylesheet"/> <div class="footer-tab"> <ul class="nav nav-tabs" role="tablist"> <li class="img-01 w-25"><a href="" class="nav-link"}} <span class="footer-tab-img active"> <a href="#"><img src="https://image.ibb.co/mohjbv/book.png" alt="book" border="0"></a> </span> <p class="tab-txt">book</p> </a> </li> </ul> </div>
finally fixed issue, im used class footer-tab-img-01
, added separate color image , code crete
`span.footer-tab-img-01 { background: url('/image/users.png') no-repeat; width: 32px; height: 32px; display: block; margin-left:1.2rem; } .nav-link.active span.footer-tab-img-01 { background: url('/image/users-hover.png') no-repeat; width: 32px; height: 32px; display: block; margin-left:1.2rem; }`
<div class="footer-tab"> <ul class="nav nav-tabs" role="tablist"> <li class="img-01 w-25"><a href="" class="nav-link"}} <span class="footer-tab-img-01"> </span> <p class="tab-txt">book</p> </a> </li> </ul> </div>
Comments
Post a Comment