Merge pull request #14 from koirand/icon

Change navi link to icon
Close #13
This commit is contained in:
Kazuki Koide 2019-03-23 18:12:54 +09:00 committed by GitHub
commit 6fcaa6cbe4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 98 additions and 89 deletions

View file

@ -26,16 +26,24 @@ pygmentsUseClasses = false
[[menu.main]] [[menu.main]]
name = "Blog" name = "Blog"
pre = "<i class='fa fa-book-open fa-lg'></i>"
url = "/blog/" url = "/blog/"
weight = 10
[[menu.main]] [[menu.main]]
name = "Twitter" name = "Twitter"
pre = "<i class='fab fa-twitter fa-lg'></i>"
url = "https://twitter.com/username" url = "https://twitter.com/username"
weight = 20
[[menu.main]] [[menu.main]]
name = "GitHub" name = "GitHub"
pre = "<i class='fab fa-github fa-lg'></i>"
url = "https://github.com/username" url = "https://github.com/username"
weight = 30
[[menu.main]] [[menu.main]]
name = "Email" name = "Email"
pre = "<i class='fa fa-envelope fa-lg'></i>"
url = "mailto:username@example.com" url = "mailto:username@example.com"
weight = 40

View file

@ -21,7 +21,7 @@
<nav> <nav>
<ul> <ul>
{{ range .Site.Menus.main }} {{ range .Site.Menus.main }}
<li><a href="{{ .URL }}">{{ .Name }}</a></li> <li><a href="{{ .URL }}">{{ .Pre }}</a></li>
{{ end }} {{ end }}
</ul> </ul>
</nav> </nav>

View file

@ -16,6 +16,7 @@
<link rel="stylesheet" href="/css/style.css"> <link rel="stylesheet" href="/css/style.css">
<link rel="stylesheet" href="/css/markdown.css"> <link rel="stylesheet" href="/css/markdown.css">
<link rel="stylesheet" href="/css/syntax-highlight.css"> <link rel="stylesheet" href="/css/syntax-highlight.css">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.8.1/css/all.css" integrity="sha384-50oBUHEmvpQ+1lW4y57PTFmhCaXp0ML5d60M1M7uH2+nqUivzIebhndOJK28anvf" crossorigin="anonymous">
<!-- custom css --> <!-- custom css -->
{{ range .Site.Params.custom_css }} {{ range .Site.Params.custom_css }}

View file

@ -1,148 +1,148 @@
/* General */ /* General */
body { body {
min-height:100vh; min-height:100vh;
margin: 0; margin: 0;
padding: 20px; padding: 20px;
box-sizing:border-box; box-sizing:border-box;
background-color: #EFEFEF; background-color: #EFEFEF;
color: #707070; color: #707070;
text-align: center; text-align: center;
font-family:-apple-system, BlinkMacSystemFont, "Helvetica Neue", "Segoe UI","Noto Sans Japanese","ヒラギノ角ゴ ProN W3", Meiryo, sans-serif; font-family:-apple-system, BlinkMacSystemFont, "Helvetica Neue", "Segoe UI","Noto Sans Japanese","ヒラギノ角ゴ ProN W3", Meiryo, sans-serif;
line-height: 1.5; line-height: 1.5;
} }
a:link { a:link {
color: #707070; color: #707070;
} }
a:visited { a:visited {
color: #707070; color: #707070;
} }
a:hover { a:hover {
color: #707070; color: #707070;
} }
a:active { a:active {
color: #707070; color: #707070;
} }
/* Header */ /* Header */
header .avatar { header .avatar {
position: relative; position: relative;
height: 100px; height: 100px;
} }
header .avatar img { header .avatar img {
position: absolute; position: absolute;
width: 100px; width: 100px;
margin: 0 auto; margin: 0 auto;
left: 0; left: 0;
right: 0; right: 0;
} }
header .avatarMask { header .avatarMask {
clip-path: circle(48px at center); clip-path: circle(48px at center);
-webkit-clip-path: circle(48px at center); -webkit-clip-path: circle(48px at center);
} }
/* Footer */ /* Footer */
footer { footer {
font-size: 12px; font-size: 12px;
box-sizing:border-box; box-sizing:border-box;
} }
/* Top page */ /* Top page */
#profileContainer { #profileContainer {
min-height: calc(100vh - 100px); min-height: calc(100vh - 100px);
display: flex; display: flex;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
} }
#profile { #profile {
max-width: 600px; max-width: 600px;
min-width: 300px; min-width: 300px;
} }
nav ul { nav ul {
display: flex; display: flex;
justify-content: space-evenly; justify-content: space-evenly;
width: 300px; width: 300px;
margin: 20px auto; margin: 20px auto;
padding: 0; padding: 0;
list-style: none; list-style: none;
} }
/* Contents List */ /* Contents List */
#searchBox { #searchBox {
position: relative; position: relative;
width: 300px; width: 300px;
height: 30px; height: 30px;
margin: 20px auto; margin: 20px auto;
} }
#searchBox #searchBoxInput { #searchBox #searchBoxInput {
position: absolute; position: absolute;
width: 100%; width: 100%;
padding: 0 35px 0 15px; padding: 0 35px 0 15px;
top: 0; top: 0;
left: 0; left: 0;
right: 0; right: 0;
bottom: 0; bottom: 0;
border-radius: 15px; border-radius: 15px;
outline: 0; outline: 0;
font-size: 15px; font-size: 15px;
color: #707070; color: #707070;
background-color:#f6f6f6; background-color:#f6f6f6;
border: solid 1px #c9c9c9; border: solid 1px #c9c9c9;
box-sizing: border-box; box-sizing: border-box;
} }
#searchBox #searchBoxInput::placeholder { #searchBox #searchBoxInput::placeholder {
color: #c9c9c9; color: #c9c9c9;
} }
#searchBox #searchBoxIcon { #searchBox #searchBoxIcon {
position: absolute; position: absolute;
height: 20px; height: 20px;
width: 20px; width: 20px;
top: 5px; top: 5px;
right: 10px; right: 10px;
} }
#searchResults { #searchResults {
display: none; display: none;
position: absolute; position: absolute;
max-width: 600px; max-width: 600px;
min-width: 300px; min-width: 300px;
margin: 0 auto; margin: 0 auto;
top: 240px; top: 240px;
left: 0; left: 0;
right: 0; right: 0;
padding: 5px; padding: 5px;
background-color:#f6f6f6; background-color:#f6f6f6;
border: solid 1px #c9c9c9; border: solid 1px #c9c9c9;
border-radius: 5px; border-radius: 5px;
text-align: left; text-align: left;
box-sizing: border-box; box-sizing: border-box;
} }
#searchResults .searchResultPage { #searchResults .searchResultPage {
padding: 20px padding: 20px
} }
#searchResults .searchResultTitle { #searchResults .searchResultTitle {
font-weight: bold; font-weight: bold;
margin: 5px 0; margin: 5px 0;
} }
#searchResults .searchResultBody { #searchResults .searchResultBody {
font-size: 14px; font-size: 14px;
} }
#searchResults mark { #searchResults mark {
background-color: #dddfdf; background-color: #dddfdf;
} }
#contentsList { #contentsList {
@ -150,17 +150,17 @@ nav ul {
} }
#contentsList hr.separator { #contentsList hr.separator {
width: 10px; width: 10px;
margin: 30px auto; margin: 30px auto;
border: solid 1px #C9C9C9; border: solid 1px #C9C9C9;
} }
/* Page */ /* Page */
div.markdown-body { div.markdown-body {
width: 90vw; width: 90vw;
max-width: 800px; max-width: 800px;
min-width: 300px; min-width: 300px;
margin: 0 auto; margin: 0 auto;
padding: 20px; padding: 20px;
text-align: left; text-align: left;
} }