Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/AmazingRise/hugo-theme-diary.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README.md11
-rw-r--r--layouts/_default/baseof.html15
-rw-r--r--layouts/partials/copyright.html (renamed from layouts/partials/footer.html)0
-rw-r--r--layouts/partials/header.html2
-rw-r--r--layouts/partials/mobile-footer.html3
-rw-r--r--layouts/partials/mobile-header.html71
-rw-r--r--layouts/partials/sidebar.html8
7 files changed, 87 insertions, 23 deletions
diff --git a/README.md b/README.md
deleted file mode 100644
index c243337..0000000
--- a/README.md
+++ /dev/null
@@ -1,11 +0,0 @@
-# hugo-theme-diary
-Original Author: SumiMakito
-
-隻言片語・於此匯聚
-
-Moments piled up.
----
-
-A Hugo theme ported from [SumiMakito/hexo-theme-Journal](https://github.com/SumiMakito/hexo-theme-Journal/).
-
-This theme is under construction. \ No newline at end of file
diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html
index 72260a6..0bdeb7e 100644
--- a/layouts/_default/baseof.html
+++ b/layouts/_default/baseof.html
@@ -3,17 +3,18 @@
{{- partial "head.html" . -}}
<body>
<div id="app">
- {{- partial "header.html" . -}}
- {{- partial "sidebar.html" . -}}
- {{- partial "extrabar.html" . -}}
-
+ {{- partial "sidebar.html" . -}}
+ {{- partial "extrabar.html" . -}}
+ <!-- PC view -->
+
+ {{- partial "mobile-header.html" . -}}
+ <!-- mobile header -->
<div id="content">
{{- block "main" . }}{{- end }}
</div>
- <div id="single-column-footer">
- {{- partial "footer.html" . -}}
- </div>
+ {{- partial "mobile-footer.html" . -}}
+ <!-- mobile footer -->
</div>
<script src="/js/journal.js"></script>
</body>
diff --git a/layouts/partials/footer.html b/layouts/partials/copyright.html
index b3a8016..b3a8016 100644
--- a/layouts/partials/footer.html
+++ b/layouts/partials/copyright.html
diff --git a/layouts/partials/header.html b/layouts/partials/header.html
index d1819cd..3c96494 100644
--- a/layouts/partials/header.html
+++ b/layouts/partials/header.html
@@ -63,7 +63,7 @@
v-bind:style="{ transform: 'translateZ(0px) translateY('+.3*scrollY+'px)', opacity: 1-navOpacity }">
<a href="{{.Site.BaseURL}}">
<div class="single-column-header-title">{{.Site.Title}}</div>
- {{ with .Params.subtitle }}
+ {{ with .Site.Params.subtitle }}
<div class="single-column-header-subtitle">{{.}}</div>
{{ end }}
diff --git a/layouts/partials/mobile-footer.html b/layouts/partials/mobile-footer.html
new file mode 100644
index 0000000..2b5a4f6
--- /dev/null
+++ b/layouts/partials/mobile-footer.html
@@ -0,0 +1,3 @@
+<div id="single-column-footer">
+ {{- partial "copyright.html" . -}}
+</div> \ No newline at end of file
diff --git a/layouts/partials/mobile-header.html b/layouts/partials/mobile-header.html
new file mode 100644
index 0000000..3c96494
--- /dev/null
+++ b/layouts/partials/mobile-header.html
@@ -0,0 +1,71 @@
+<div class="single-column-drawer-container" ref="drawer"
+ v-bind:class="{ 'single-column-drawer-container-active': isDrawerOpen }">
+ <div class="drawer-content">
+ <div class="drawer-menu">
+ {{ $current := .Permalink}}
+ {{range $taxonomyname, $taxonomy := .Site.Taxonomies}}
+
+ {{ with $.Site.GetPage (printf "/%s" $taxonomyname) }}
+
+ {{$actived := "false"}}
+ {{if eq $current .Permalink}}
+ {{$actived = "active"}}
+
+ {{end}}
+ <a class="a-block drawer-menu-item {{$actived}}" href="{{.Permalink}}">
+ {{.Title}}
+ </a>
+ {{ end }}
+ {{ end }}
+ <!--
+ <a class="a-block drawer-menu-item <%= is_home() && 'active' %>" href="<%= config.url %>">
+ <%= __('Home') %>
+ </a>
+ <% if (theme.archives) { %>
+ <a class="a-block drawer-menu-item <%= is_current('archives') && 'active' %>" href="<%= config.root + "archives" %>">
+ <%= __('Archive') %>
+ </a>
+ <% } %>
+
+ <% if(site.pages){ %>
+ <% site.pages.each(function (page){ %>
+ <a class="a-block drawer-menu-item <%= is_current(page.path) && 'active' %>" href="<%= config.root + page.path %>">
+ <%= page.title %>
+ </a>
+ <% });} %>
+
+ <% if (theme.rss) { %>
+ <a class="a-block drawer-menu-item" href="<%= config.root + theme.rss %>">
+ <%= __('RSS') %>
+ </a>
+ <% } %>
+ -->
+ </div>
+ </div>
+</div>
+<transition name="fade">
+ <div v-bind:class="{ 'single-column-drawer-mask': mounted }" v-if="isDrawerOpen" v-on:click="toggleDrawer"></div>
+</transition>
+<nav ref="navBar" class="navbar sticky-top navbar-light single-column-nav-container">
+ <div ref="navBackground" class="nav-background"></div>
+ <div class="container container-narrow nav-content">
+ <button id="nav_dropdown_btn" class="nav-dropdown-toggle" type="button" v-on:click="toggleDrawer">
+ <i class="material-icons">
+ menu
+ </i>
+ </button>
+ <a ref="navTitle" class="navbar-brand" href="{{.Site.BaseURL}}">
+ {{.Site.Title}}
+ </a>
+ </div>
+</nav>
+<div class="single-column-header-container" ref="pageHead"
+ v-bind:style="{ transform: 'translateZ(0px) translateY('+.3*scrollY+'px)', opacity: 1-navOpacity }">
+ <a href="{{.Site.BaseURL}}">
+ <div class="single-column-header-title">{{.Site.Title}}</div>
+ {{ with .Site.Params.subtitle }}
+ <div class="single-column-header-subtitle">{{.}}</div>
+ {{ end }}
+
+ </a>
+</div> \ No newline at end of file
diff --git a/layouts/partials/sidebar.html b/layouts/partials/sidebar.html
index c4cd44b..f2e7445 100644
--- a/layouts/partials/sidebar.html
+++ b/layouts/partials/sidebar.html
@@ -7,11 +7,11 @@
<div class="nav-title">
{{.Site.Title}}
</div>
+ {{ with .Site.Params.subtitle }}
<div class="nav-subtitle">
- {{ with .Params.subtitle }}
- <span class="subtitle">{{.}}</span>
- {{ end }}
+ {{.}}
</div>
+ {{ end }}
</a>
<div class="nav-link-list">
@@ -34,7 +34,7 @@
<div class="nav-footer">
- {{partial "footer.html" .}}
+ {{partial "copyright.html" .}}
</div>
</div> \ No newline at end of file