mirror of
https://github.com/McShelby/hugo-theme-relearn.git
synced 2024-11-23 15:57:57 +00:00
92 lines
No EOL
4 KiB
HTML
92 lines
No EOL
4 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="{{ .Page.Language | default "en" }}" class="js csstransforms3d">
|
|
<head>
|
|
{{- partial "meta.html" . }}
|
|
<title>{{ .Title }} {{ default "::" .Site.Params.titleSeparator }} {{ .Site.Title }}</title>
|
|
|
|
{{- if not (and .Title (or (ne (.Scratch.Get "relearnIsHiddenStem") true) (ne .Site.Params.disableSeoHiddenPages true) ) ) }}
|
|
{{- else }}
|
|
{{- range .AlternativeOutputFormats }}
|
|
{{- if ne .Name "JSON" }}
|
|
<link rel="{{ .Rel }}" type="{{ .MediaType.Type }}" href="{{ .Permalink | relURL }}" title="{{ $.Site.Title | safeHTML }}" />
|
|
{{- end }}
|
|
{{- end }}
|
|
{{- end }}
|
|
{{- if and (ne .Site.Params.disableSeoHiddenPages true) (ne .Site.Params.disableSearchHiddenPages true) }}
|
|
{{- range .AlternativeOutputFormats }}
|
|
{{- if eq .Name "JSON" }}
|
|
<link rel="{{ .Rel }}" type="{{ .MediaType.Type }}" href="{{ .Permalink | relURL }}" title="{{ $.Site.Title | safeHTML }}" />
|
|
{{- end }}
|
|
{{- end }}
|
|
{{- end }}
|
|
|
|
{{- partial "favicon.html" . }}
|
|
{{- partial "stylesheet.html" . }}
|
|
{{- partial "custom-header.html" . }}
|
|
</head>
|
|
<body class="default-animation" data-url="{{ .RelPermalink }}">
|
|
{{- partial "menu.html" . }}
|
|
<div id="body" class="default-animation">
|
|
<div id="overlay"></div>
|
|
<div class="padding highlightable">
|
|
{{- if not .IsHome }}
|
|
<div id="top-bar"><div>
|
|
{{- if and (or .IsPage .IsSection) .Site.Params.editURL }}
|
|
{{- $File := .File }}
|
|
{{- $Site := .Site }}
|
|
{{- with $File.Path }}
|
|
<div id="top-github-link">
|
|
<a class="github-link" title='{{ T "Edit-this-page" }}' href="{{ $Site.Params.editURL }}{{ replace $File.Dir "\\" "/" }}{{ $File.LogicalName }}" target="blank">
|
|
<i class="fas fa-pencil"></i>
|
|
</a>
|
|
</div>
|
|
{{- end }}
|
|
{{- end }}
|
|
{{- $defaultDisableToc := .Site.Params.disableToc | default false }}
|
|
{{- $currentDisableToc := .Params.disableToc | default $defaultDisableToc }}
|
|
{{- $toc := (and (not $currentDisableToc) (not .Params.chapter)) }}
|
|
<div id="breadcrumbs">
|
|
<span id="sidebar-toggle-span">
|
|
<a href="#" id="sidebar-toggle" title='{{ T "Navigation-toggle" }}' data-sidebar-toggle="">
|
|
<i class="fas fa-bars"></i>
|
|
</a>
|
|
</span>
|
|
{{- if $toc }}
|
|
<span id="toc-menu"><i class="fas fa-list-alt"></i></span>
|
|
{{- end }}
|
|
{{- $showBreadcrumb := (and (not .Params.disableBreadcrumb) (not .Site.Params.disableBreadcrumb)) }}
|
|
{{- if $showBreadcrumb }}
|
|
<ol class="links" itemscope itemtype="http://schema.org/BreadcrumbList">
|
|
<meta itemprop="itemListOrder" content="Descending" />
|
|
{{- template "breadcrumb" dict "page" . "depth" 0 }}
|
|
</ol>
|
|
{{- else }}
|
|
<span class="links">
|
|
{{ .Title }}
|
|
</span>
|
|
{{- end }}
|
|
</div>
|
|
{{- if $toc }}
|
|
{{- partial "toc.html" . }}
|
|
{{- end }}
|
|
</div></div>
|
|
{{- end }}
|
|
<div id="head-tags">
|
|
{{- partial "tags.html" . }}
|
|
</div>
|
|
{{- if .Params.chapter }}
|
|
<div id="chapter">
|
|
{{- end }}
|
|
<main id="body-inner">
|
|
{{- if and (not .IsHome) (not .Params.chapter) }}
|
|
<h1>{{ if eq .Kind "term" }}{{ .Data.Singular }} :: {{ end }}{{ .Title }}</h1>
|
|
{{- end }}
|
|
|
|
{{- define "breadcrumb" }}
|
|
{{- $parent := .page.Parent }}
|
|
{{- $depth := add .depth 1 }}
|
|
{{- if $parent }}
|
|
{{- template "breadcrumb" dict "page" $parent "depth" $depth }}
|
|
{{- end }}
|
|
<li itemscope itemtype="https://schema.org/ListItem" itemprop="itemListElement"><meta itemprop="position" content="{{ $depth }}" /><a itemprop="item" href="{{ .page.RelPermalink }}"{{if not .depth}} aria-disabled="true"{{end}}><span itemprop="name">{{ .page.Title }}</span></a>{{ if .depth }} > {{ end }}</li>
|
|
{{- end }} |