Skip to content

Commit

Permalink
version 1
Browse files Browse the repository at this point in the history
  • Loading branch information
zzsqwq committed Apr 20, 2022
1 parent fc44786 commit ffe4be9
Show file tree
Hide file tree
Showing 14 changed files with 1,751 additions and 0 deletions.
66 changes: 66 additions & 0 deletions config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
# Change to your profile picture
# if author sets in hexo_config, this string doesn't work

# Top Menu 顶部菜单
# #title 为页内跳转,单页模式
# 可以选择外链或其他页面

params:
author: "zs"
menu:
Publications: /#Publications
About: /
Blog: https://phower.me

# flink picture will load if avator link calls on error
loading_bg:
flink: /img/profile.png

# Social Links; 社交链接,不需要的链接直接注释掉
# 可以调整显示顺序
# 图标调用 font-awesome 4.7
social:
enable: true
social_links:
fab fa-twitter: /
fab fa-facebook-square: /
fab fa-github: /
fab fa-stack-overflow: /
fab fa-linkedin: /
fab fa-weibo: /
fab fa-weixin: /
fab fa-qq: /
fas fa-envelope: / #E-mail
fas fa-rss: / #rss

# Additional social_links,额外添加自定义链接,可显示链接名称
# name: url || icon_name
e_social:
enable: true
e_social_links:
Google Scholar: / || fas fa-graduation-cap
ORCID: / || fab fa-orcid

# CV download link
cv_dl:
enable: true
dir: /attaches/CV.pdf
description: My Detail CV.

# Box-shadow
# display box-shadow on page or not
box_shadow:
enable: false

# CDN
# 根据需要自行添加js/css
# 自定义css可以直接写在user.styl中
CDN_USE:
css:
- /css/index.css
# - https://cdn.jsdelivr.net/npm/font-awesome@latest/css/font-awesome.min.css
- https://cdn.jsdelivr.net/npm/@fortawesome/fontawesome-free@5.13.0/css/all.min.css # fontawesome 5
js:
- https://cdn.jsdelivr.net/npm/jquery@latest/dist/jquery.min.js #/js/third-party/jquery.min.js
- https://cdn.jsdelivr.net/npm/jquery-pjax@latest/jquery.pjax.min.js
- /js/main.js
23 changes: 23 additions & 0 deletions layouts/_default/baseof.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<!doctype html>
<html>
{{ partial "head" .}}
<body>
<header id="page_header">
{{partial "header" .}}
</header>

<main id="page_main">
{{partial "side-bar" .}}
{{block "content" .}}{{end}}
</main>

{{partial "mobile-nav" .}}
<footer id="page_footer">
{{partial "footer" .}}
</footer>

{{range .Site.Params.CDN_USE.js}}
<script src="{{.}}"></script>
{{end}}
</body>
</html>
18 changes: 18 additions & 0 deletions layouts/_default/list.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{{define "main" }}
{{ partial "header" (dict "Kind" .Kind "Template" "List") }}
{{.Content}}
{{ range .Pages }}
<div style="border: 1px solid black; margin:10px; padding:10px; ">
<div style="font-size:20px;">
<a href="{{.Permalink}}">{{.Title}}</a>
</div>
<div style="color:grey; font-size:16px;">{{ dateFormat "Monday, Jan 2, 2006" .Date }}</div>
<div style="color:grey; font-size:16px;">{{ if .Params.tags }}<strong>Tags:</strong> {{range .Params.tags}}<a href="{{ "/tags/" | relLangURL }}{{ . | urlize }}">{{ . }}</a> {{end}}{{end}}</div>
<div style="color:grey; font-size:16px;">{{ if .Params.categories }}<strong>Categories:</strong> {{range .Params.categories}}<a href="{{ "/categories/" | relLangURL }}{{ . | urlize }}">{{ . }}</a> {{end}}{{end}}</div>
<div style="color:grey; font-size:16px;">{{ if .Params.moods }}<strong>Moods:</strong> {{range .Params.moods}}<a href="{{ "/moods/" | relLangURL }}{{ . | urlize }}">{{ . }}</a> {{end}}{{end}}</div>

<p style="font-size:18px;">{{.Summary}}</p>
</div>
{{ end }}
{{ partial "footer" . }}
{{end}}
6 changes: 6 additions & 0 deletions layouts/_default/single.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{{define "content"}}
<div class="page" itemscope="itemscope" itemtype="http://schema.org/CreativeWork">
<h2 class="page-title">{{.Title}}</h2>
<article>{{.Content}}</article>
</div>
{{end}}
7 changes: 7 additions & 0 deletions layouts/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{{define "content"}}
<div class="page" itemscope="itemscope" itemtype="http://schema.org/CreativeWork">
{{range .Site.Pages }}
<a href="{{.Permalink}}">{{.Content}}</a>
{{end}}
</div>
{{end}}
12 changes: 12 additions & 0 deletions layouts/partials/footer.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<div class="footer_wrap">
{{with .Site.Params.since}}
{{if not (eq $.Site.Params.since $.Date.Year) }}
<div class="copyright"> {{$.Site.Params.since}}-{{$.Date.Year}} by {{$.Site.Params.author}}</div>
{{else}}
<div class="copyright"> {{$.Date.Year}} by ${{.Site.Params.author}}</div>
{{end}}
{{end}}
<div class="theme-info">
Powered by <a href="https://gohugo.io/" rel="nofollow">Hugo</a> & <a href="https://github.com/zzsqwq/Hugo-Academia-Theme" rel="nofollow">Hugo Academia Theme</a>
</div>
</div>
10 changes: 10 additions & 0 deletions layouts/partials/head.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=5">
<title>{{ .Title }} </title>
<meta name="author" content="{{ .Site.Params.author }}">
{{ range .Site.Params.CDN_USE.css }}
<link rel="stylesheet" href="{{.}}">
{{end}}
</head>
8 changes: 8 additions & 0 deletions layouts/partials/header.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<div class="header_wrap">
<div id="blog_name"><a class="blog_title" id="site-name" href="{{.Site.BaseURL}}">{{ .Site.Title }}</a>
</div>
<button class="menus_icon">
<div class="navicon"></div>
</button>

</div>
15 changes: 15 additions & 0 deletions layouts/partials/mobile-nav.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<div class="nav-wrap">
<div class="nav">
<button class="site-nav">
<div class="navicon"></div>
</button>
<ul class="nav_items">
{{range $key, $value := .Site.Params.menu}}
<li class="nav_item">
<a class="nav-page" href="{{$value}}">{{$key}}</a>
</li>
{{end}}
</ul>
</div>
<div class="cd-top"><i class="fa fa-arrow-up" aria-hidden="true"></i></div>
</div>
46 changes: 46 additions & 0 deletions layouts/partials/side-bar.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
<div class="side-card sticky">
<div class="card-wrap" itemscope="itemscope" itemtype="http://schema.org/Person">
<div class="author-avatar">
<img class="avatar-img" src="{{.Site.Params.avatar}}" alt="avatar"/>
</div>
<div class="author-discrip">
<h3>{{.Site.Params.author}}</h3>
<p class="author-bio">{{.Site.Params.author_bio}}</p>
</div>
<div class="author-links">
<button class="btn m-social-links">Links</button>
{{with .Site.Params.social.enable }}
<!-- todo: add if-->
<ul class="social-icons">
{{range $icon, $url := $.Site.Params.social_links}}
<!-- {{$url}} : {{$icon}}-->
<li>
<a class="social-icon" href="{{$url}}" target="_blank"></a>
<i class="{{$icon}}" aria-hidden="true"></i>
</li>
{{end}}
</ul>
{{end}}
{{with .Site.Params.e_social.enable }}
<ul class="social-icons">
{{range $value, $name := $.Site.Params.e_social_links}}
<li>
<a class="e-social-link" href="#" target="_blank" >
<i class="{{$name}}" aria-hidden="true"></i>
<span>{{$value}}</span>
</a>
</li>
{{end}}
</ul>
{{end}}
{{with .Site.Params.cv_dl.enable}}
<a class="cv-links" href="{{$.Site.Params.cv_dl.dir}}" target="_blank">
<i class="fas fa-file-pdf" aria-hidden="true">
<span>{{$.Site.Params.cv_dl.description}}</span>
</i>
</a>
{{end}}
</div>

</div>
</div>
Loading

0 comments on commit ffe4be9

Please sign in to comment.