add external-link

This commit is contained in:
gonpombo8 2022-10-13 14:21:55 -03:00
parent 2ea21ad89e
commit 73e3917c88
No known key found for this signature in database
GPG Key ID: 6BE1C3CD0908CE48
2 changed files with 14 additions and 2 deletions

View File

@ -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;
} }

View File

@ -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 }}