diff --git a/name.go b/name.go index ac52a86..9d0bf08 100644 --- a/name.go +++ b/name.go @@ -23,17 +23,22 @@ func CanonicalName(name string) string { func naviTitle(canonicalName string) string { var ( html = fmt.Sprintf(`

- %s`, util.HomePage, util.SiteTitle) + %s`, util.HomePage, util.SiteTitle) prevAcc = `/page/` parts = strings.Split(canonicalName, "/") + rel = "up" ) for i, part := range parts { if i > 0 { html += `` } + if i == len(parts)-1 { + rel = "bookmark" + } html += fmt.Sprintf( - `%s`, + `%s`, prevAcc+part, + rel, util.BeautifulName(part), ) prevAcc += part + "/" diff --git a/templates/asset.qtpl.go b/templates/asset.qtpl.go index f8e5ae7..ce8b514 100644 --- a/templates/asset.qtpl.go +++ b/templates/asset.qtpl.go @@ -66,8 +66,12 @@ article pre.codeblock {background-color:#eee; padding:.5rem; white-space: pre-wr .binary-container_with-img img, .binary-container_with-video video, .binary-container_with-audio audio {width: 100%} -.navi-title a {text-decoration:none;} + +.navi-title { border-bottom: #eee 1px solid; padding-bottom: .5rem; margin-bottom: .25rem; } +.navi-title a {text-decoration:none; } .navi-title__separator { margin: 0 .25rem; } +.navi-title__colon { margin-right: .5rem; } + .img-gallery { text-align: center; margin-top: .25rem; margin-bottom: .25rem; } .img-gallery_many-images { background-color: #eee; border-radius: .25rem; padding: .5rem; } .img-gallery img { max-width: 100%; max-height: 50vh; } diff --git a/templates/default.css b/templates/default.css index 1a24275..44030bf 100644 --- a/templates/default.css +++ b/templates/default.css @@ -41,8 +41,12 @@ article pre.codeblock {background-color:#eee; padding:.5rem; white-space: pre-wr .binary-container_with-img img, .binary-container_with-video video, .binary-container_with-audio audio {width: 100%} -.navi-title a {text-decoration:none;} + +.navi-title { border-bottom: #eee 1px solid; padding-bottom: .5rem; margin-bottom: .25rem; } +.navi-title a {text-decoration:none; } .navi-title__separator { margin: 0 .25rem; } +.navi-title__colon { margin-right: .5rem; } + .img-gallery { text-align: center; margin-top: .25rem; margin-bottom: .25rem; } .img-gallery_many-images { background-color: #eee; border-radius: .25rem; padding: .5rem; } .img-gallery img { max-width: 100%; max-height: 50vh; }