In GitBook, the title shows up while mousing over them by default.
I wanna show up the title. I inspect the elements,
<div role="navigation">
<!-- Title -->
<h1>
<i ></i>
<a href=".." >Preface</a>
</h1>
</div>
and related CSS is,
.book-header h1 a, .book-header h1 a:hover {
color: inherit;
text-decoration: none;
}
I add the following CSS,
.book-header h1 a {
display: block !important;
}
but it doesn't work.
CodePudding user response:
Because .book-header h1 opacity is 0.
Try add this to your css.
.book-header h1 {
opacity:1!important;
}
CodePudding user response:
Try this! More about color: inherit
here. You can use other property like z-index
, opacity
and position
if it doesn't work too. Thanks :)
.book-header h1 a, .book-header h1 a:hover {
display: block !important;
color: #000 !important;
text-decoration: none;
}
<div role="navigation">
<!-- Title -->
<h1>
<i ></i>
<a href=".." >Preface</a>
</h1>
</div>