breadcrumb update
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
|
||||
<head>
|
||||
{{- partial "head.html" . -}}
|
||||
<meta name="description" content="{{ .Params.description }}" />
|
||||
{{- block "head" . -}}{{- end }}
|
||||
|
||||
<!-- stylesheets -->
|
||||
<link rel="stylesheet" href="/css/bootstrap.min.css">
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
{{ define "head"}}
|
||||
<meta name="description" content="blog of {{ .Site.Title}}" />
|
||||
<title>blog</title>
|
||||
{{ end }}
|
||||
|
||||
|
||||
{{ define "main" }}
|
||||
<section class="bg-light">
|
||||
<div class="container-fluid">
|
||||
|
||||
@@ -1,4 +1,11 @@
|
||||
{{ define "head"}}
|
||||
<meta name="description" content="{{ .Params.description }}" />
|
||||
<title>{{ .Title }}</title>
|
||||
{{ end }}
|
||||
|
||||
|
||||
{{ define "main" }}
|
||||
|
||||
<section class="bg-light">
|
||||
<div class="container">
|
||||
<div class="row justify-content-md-center">
|
||||
@@ -42,6 +49,25 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{ $url := replace .Permalink ( printf "%s" .Site.BaseURL) "" }}
|
||||
{{ $.Scratch.Add "path" .Site.BaseURL }}
|
||||
<nav aria-label="breadcrumb">
|
||||
<ol class="breadcrumb">
|
||||
<li class="breadcrumb-item" aria-current="page">
|
||||
<a href="/">home</a>
|
||||
</li>
|
||||
{{ range $index, $element := split $url "/" }}
|
||||
{{ $.Scratch.Add "path" $element }}
|
||||
{{ if ne $element "" }}
|
||||
<li class="breadcrumb-item" aria-current="page">
|
||||
<a href='{{ $.Scratch.Get "path" }}'>{{ . }}</a>
|
||||
</li>
|
||||
{{ $.Scratch.Add "path" "/" }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
</ol>
|
||||
</nav>
|
||||
|
||||
<!-- image -->
|
||||
<div class="py-2">
|
||||
{{ with .Params.bg_image }}
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
|
||||
<head>
|
||||
{{- partial "head.html" . -}}
|
||||
|
||||
<title>{{ .Title }}</title>
|
||||
<meta name="description" content="{{ .Site.Params.description }}" />
|
||||
|
||||
<!-- Global site tag (gtag.js) - Google Analytics -->
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
<h5 class="text-uppercase pb-2 font-weight-bold"><a href="{{ .Site.BaseURL }}">{{ .Site.Title }}</a></h5>
|
||||
|
||||
© {{ .Site.LastChange.Format "2006" }} All Rights Reserved<br>
|
||||
© {{ .Site.Params.copyright }} All Rights Reserved<br>
|
||||
|
||||
<a href="{{ .Site.BaseURL }}">{{ .Site.Title }}</a> made with
|
||||
<svg width="1em" height="1em" viewBox="0 0 16 16" class="bi bi-heart" fill="currentColor"
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<meta http-equiv="X-UA-Compatible" content="ie=edge">
|
||||
<title>{{ .Title }}</title>
|
||||
|
||||
<link rel="icon" href="{{ .Site.Params.favicon | default "/images/favicon.png"}}" type="image/gif">
|
||||
|
||||
|
||||
Reference in New Issue
Block a user