feat: add bilibili diagram echarts and improve style
This commit is contained in:
@@ -22,33 +22,39 @@
|
||||
{{ range . }}
|
||||
{{- $name := . -}}
|
||||
{{- with $.Site.GetPage "taxonomy" (printf "categories/%s" $name) | default ($.Site.GetPage "taxonomy" (printf "categories/%s" ($name | urlize))) -}}
|
||||
<i class="far fa-folder"></i>
|
||||
<a href="{{ .Permalink }}">{{ $name }}</a>
|
||||
<i class="far fa-folder"></i> <a href="{{ .Permalink }}">{{ $name }}</a>
|
||||
{{ end -}}
|
||||
{{ end }}
|
||||
</span>
|
||||
{{- end }}
|
||||
</div>
|
||||
|
||||
<div class="post-meta-other">
|
||||
<i class="far fa-calendar-alt"></i>
|
||||
<span class="post-time"><time datetime={{ $publish_date }}>{{ $publish_date }}</time></span>
|
||||
<i class="fas fa-pencil-alt"></i>
|
||||
{{ T "wordCount" .WordCount }}
|
||||
<i class="far fa-clock"></i>
|
||||
{{ T "readingTime" .ReadingTime }}
|
||||
{{ if and .Site.Params.valine.enable .Site.Params.valine.visitor }}
|
||||
<span id="{{ .RelPermalink | relURL }}" class="leancloud_visitors" data-flag-title="{{ .Title }}">
|
||||
<i class="far fa-eye"></i>
|
||||
{{ T "pageviews" | safeHTML }}
|
||||
</span>
|
||||
{{ end }}
|
||||
<span class="post-time"><i class="far fa-calendar-alt"></i> <time datetime={{ $publish_date }}>{{ $publish_date }}</time> </span>
|
||||
<i class="fas fa-pencil-alt"></i> {{ T "wordCount" .WordCount }}
|
||||
<i class="far fa-clock"></i> {{ T "readingTime" .ReadingTime }}
|
||||
{{- if eq (getenv "HUGO_ENV") "production" | and .Site.Params.valine.enable | and .Site.Params.valine.visitor -}}
|
||||
<span id="{{ .RelPermalink | relURL }}" class="leancloud_visitors" data-flag-title="{{ .Title }}">
|
||||
<i class="far fa-eye"></i> {{ T "pageviews" | safeHTML }}
|
||||
</span>
|
||||
{{- end -}}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{ if or .Params.toc (and .Site.Params.toc (ne .Params.toc false)) -}}
|
||||
<div class="post-toc" id="post-toc">
|
||||
<h2 class="post-toc-title">{{ T "toc" }}</h2>
|
||||
{{- $globalAutoCollapseToc := .Site.Params.autoCollapseToc | default true }}
|
||||
<div class="post-toc-content{{ if not (or .Params.autoCollapseToc (and $globalAutoCollapseToc (ne .Params.autoCollapseToc false))) }} always-active{{ end }}">
|
||||
{{.TableOfContents}}
|
||||
</div>
|
||||
</div>
|
||||
{{- end }}
|
||||
|
||||
<div class="post-content">
|
||||
<!--featured_image-->
|
||||
{{ with .Params.featured_image }}
|
||||
<img src="{{ . }}" class="featured_image">
|
||||
<img src=/images/loading.svg data-sizes=auto data-src={{ . }} alt="featured image" class="featured_image lazyload">
|
||||
{{ end }}
|
||||
<!-- end featured_image-->
|
||||
|
||||
@@ -60,45 +66,39 @@
|
||||
{{ $finalContent := $altContent | replaceRE $reAltTitleIn $reAltTitleOut | safeHTML }}
|
||||
{{ $finalContent }}
|
||||
</div>
|
||||
|
||||
<div class="post-info">
|
||||
<p class="post-info-item">
|
||||
<span>{{ T "lastMod" }}:</span>
|
||||
<span>{{ $modify_date }}</span>
|
||||
</p>
|
||||
|
||||
<p class="post-info-item">
|
||||
{{ if and ( $.Param "socialShare" ) (gt (len ($.Param "share")) 0) }}
|
||||
<span>{{ T "share" }}:</span>
|
||||
<span>{{ partial "post/share-links.html" . }}</span>
|
||||
{{ end }}
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="post-tags">
|
||||
<section>
|
||||
{{ with .Params.tags }}
|
||||
{{ range . }}
|
||||
<span class="tag">
|
||||
<i class="fas fa-tag"></i><a href="{{ "tags/" | absURL }}{{ . | urlize }}/"> {{.}} </a>
|
||||
</span>
|
||||
<div class="post-footer">
|
||||
<div class="post-info">
|
||||
<div class="post-info-mod"><span>{{ printf (T "lastMod") $modify_date }}</span></div>
|
||||
<div class="post-info-share">
|
||||
{{ if and ( $.Param "socialShare" ) (gt (len ($.Param "share")) 0) }}
|
||||
<span>{{ partial "post/share-links.html" . }}</span>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
</section>
|
||||
<section>
|
||||
<span><a href="javascript:window.history.back();">{{ T "back" }}</a></span>
|
||||
|
|
||||
<span><a href="{{ .Site.BaseURL }}">{{ T "home" }}</a></span>
|
||||
</section>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="post-nav">
|
||||
{{ if .PrevInSection }}
|
||||
<a href="{{.PrevInSection.Permalink}}" class="prev" rel="prev" title="{{ .PrevInSection.Title}}"><i class="fas fa-angle-left"></i> {{ .PrevInSection.Title}}</a>
|
||||
{{ end }}
|
||||
{{ if .NextInSection }}
|
||||
<a href="{{.NextInSection.Permalink}}" class="next" rel="next" title="{{.NextInSection.Title}}">{{.NextInSection.Title}} <i class="fas fa-angle-right"></i></a>
|
||||
{{ end }}
|
||||
<div class="post-tags">
|
||||
<section>
|
||||
{{ with .Params.tags }}
|
||||
{{ range . }}
|
||||
<span class="tag">
|
||||
<i class="fas fa-tag"></i><a href="{{ "tags/" | absURL }}{{ . | urlize }}/"> {{.}} </a>
|
||||
</span>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
</section>
|
||||
<section>
|
||||
<span><a href="javascript:window.history.back();">{{ T "back" }}</a></span> | <span><a href="{{ .Site.BaseURL }}">{{ T "home" }}</a></span>
|
||||
</section>
|
||||
</div>
|
||||
|
||||
<div class="post-nav">
|
||||
{{ if .PrevInSection }}
|
||||
<a href="{{.PrevInSection.Permalink}}" class="prev" rel="prev" title="{{ .PrevInSection.Title}}"><i class="fas fa-angle-left"></i> {{ .PrevInSection.Title}}</a>
|
||||
{{ end }}
|
||||
{{ if .NextInSection }}
|
||||
<a href="{{.NextInSection.Permalink}}" class="next" rel="next" title="{{.NextInSection.Title}}">{{.NextInSection.Title}} <i class="fas fa-angle-right"></i></a>
|
||||
{{ end }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="post-comment">
|
||||
|
||||
Reference in New Issue
Block a user