mirror of
https://github.com/alex-shpak/hugo-book.git
synced 2025-07-16 11:41:27 +00:00
add external-link
This commit is contained in:
parent
2ea21ad89e
commit
73e3917c88
@ -546,6 +546,17 @@ body[dir="rtl"] .book-menu {
|
|||||||
|
|
||||||
@import "syntax.scss";
|
@import "syntax.scss";
|
||||||
|
|
||||||
|
.book-menu .external-link {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
font-weight: 600 !important;
|
||||||
|
color: #0d0d17;
|
||||||
|
img {
|
||||||
|
width: 12px;
|
||||||
|
margin-left: 6px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.code {
|
.code {
|
||||||
font-family: 'monospace' !important;
|
font-family: 'monospace' !important;
|
||||||
}
|
}
|
||||||
|
@ -36,11 +36,12 @@
|
|||||||
</a>
|
</a>
|
||||||
</label>
|
</label>
|
||||||
{{ else if .Page.Params.BookHref }}
|
{{ else if .Page.Params.BookHref }}
|
||||||
<a href="{{ .Page.Params.BookHref }}" class="{{ if $current }}active{{ end }}" target="_blank" rel="noopener">
|
<a href="{{ .Page.Params.BookHref }}" class="external-link {{ if $current }}active{{ end }}" target="_blank" rel="noopener">
|
||||||
{{- partial "docs/title" .Page -}}
|
{{- partial "docs/title" .Page -}}
|
||||||
|
<img src="{{ "svg/external-link.svg" | relURL }}" class="book-icon" alt="external-link" />
|
||||||
</a>
|
</a>
|
||||||
{{ else if .Page.Content }}
|
{{ else if .Page.Content }}
|
||||||
<a href="{{ .Page.RelPermalink }}" class="{{ if $current }}active{{ end }}" id="{{ .Page.Kind }}">
|
<a href="{{ .Page.RelPermalink }}" class="{{ if $current }}active{{ end }}" >
|
||||||
{{- partial "docs/sidebar-title" .Page -}}
|
{{- partial "docs/sidebar-title" .Page -}}
|
||||||
</a>
|
</a>
|
||||||
{{ else }}
|
{{ else }}
|
||||||
|
Loading…
Reference in New Issue
Block a user