Skip to content
/ website Public
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

<title>{{ .Title }} | {{ .Site.Title }}</title>
<link rel="canonical" href="{{ .Permalink }}">
{{ partial "header.includes.html" . }}
{{ partial "header_includes.html" . }}
{{ if (.OutputFormats.Get "RSS") }}<link href="{{ with .OutputFormats.Get "RSS" }}{{ .Permalink }}{{ end }}" rel="alternate" type="application/rss+xml" title="{{ .Site.Title }}" />{{ end }}
</head>
<body>
21 changes: 21 additions & 0 deletions themes/shijin4/layouts/blog_index/_index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<div class="node teaser">
<h2 class="title"><a href="{{ .Permalink }}">{{ .Title }}</a></h2>
<div class="meta">
{{ if (isset .Params "author") }}
Blog post by <a target="_blank" href="https://discuss.haiku-os.org/u/{{ lower .Params.author }}/">{{ .Params.author }}</a> on {{ .Date.Format "Mon, 2006-01-02 15:04" }}
{{ else }}
News posted on {{ .Date.Format "Mon, 2006-01-02 15:04" }}
{{ end }}
<div class="terms">
{{ range $i, $e := .Params.tags }}{{if $i}}, {{end}}
<a href="/tags/{{ $e | urlize }}" rel="tag">{{ . }}</a>{{ end }}
</div>
</div>
<p>{{ .Summary }}</p>
<div class="links">
{{ if (isset .Params "author") }}
<a class="blog-item" href="{{ .Parent.RelPermalink }}">{{ .Parent.Params.title }}</a>
{{ end }}
<a class="readmore-item" href="{{ .Permalink }}">Read More</a>
</div>
</div>
4 changes: 4 additions & 0 deletions themes/shijin4/layouts/blog_index/li.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<li>
<h5><a href="{{ .Permalink }}">{{ .Title}}</a><br>
<small>posted on {{ .Date.Format "Mon, 2006-01-02 15:04" }}</small></h5>
</li>
30 changes: 30 additions & 0 deletions themes/shijin4/layouts/blog_index/list.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{{ partial "header.html" . }}
<div id="page">
{{ partial "navbar.html" . }}
<div class="row" id="main-front">
<!-- Sidebar -->
<div class="col-md-3">
{{ partial "sidebar_blogosphere.html" . }}
</div>

<div class="col-md-9">
{{- if (isset .Params "author") -}}
{{ $paginator := .Paginate .RegularPages }}

{{- range $paginator.Pages -}}
{{ .Render "summary" }}
{{- end -}}
{{ partial "pagination.html" . }}
{{ else }}
{{ $paginator := .Paginate (where (where .Site.RegularPages.ByDate.Reverse "Type" "blog") ".Params.date" "!=" nil) }}

{{- range $paginator.Pages -}}
{{ .Render "summary" }}
{{- end -}}
{{ partial "pagination.html" . }}
{{- end -}}
</div>
</div>
{{ partial "footer.copyright.html" . }}
</div>
{{ partial "footer.html" . }}
13 changes: 13 additions & 0 deletions themes/shijin4/layouts/blog_index/rss.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<rss version="2.0" xmlns:atom="https://www.w3.org/2005/Atom">
<channel>
<title>Recent blog posts on {{ .Site.Title }}</title>
<link>{{ .Permalink }}</link>
<language>en-US</language>
<author>Haiku, Inc.</author>
<rights>(C) 2001-{{ now.Format "2006" }} Haiku, Inc. All rights reserved.</rights>
<updated>{{ .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" }}</updated>
{{- range first 15 (where (where .Site.RegularPages.ByDate.Reverse "Type" "blog") ".Params.date" "!=" nil) -}}
{{ partial "item.xml" . }}
{{- end -}}
</channel>
</rss>
30 changes: 30 additions & 0 deletions themes/shijin4/layouts/blog_index/single.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{{ partial "header.html" . }}
<div id="page">
{{ partial "navbar.html" . }}
<div class="row" id="main-front">
<div class="col-md-9 order-2">
<div class="node">
<h1 class="title">{{ .Title }}</h1>
<div class="meta">
Blog post by <a target="_blank" href="https://discuss.haiku-os.org/u/{{ lower .Params.author }}/">{{ .Params.author }}</a> on {{ .Date.Format "Mon, 2006-01-02 15:04" }}
{{ if .Params.tags }}
<div class="terms">
{{ range $i, $e := .Params.tags }}{{if $i}}, {{end}}
<a href="/tags/{{ $e | urlize }}" rel="tag">{{ . }}</a>{{ end }}
</div>
{{ end }}
</div>
<p>{{ .Content }}</p>
</div>
<br>
{{ partial "discourse.html" . }}
</div>

<!-- Sidebar -->
<div class="col-md-3 order-1">
{{ partial "sidebar_blog.html" . }}
</div>
</div>
{{ partial "footer.copyright.html" . }}
</div>
{{ partial "footer.html" . }}
21 changes: 21 additions & 0 deletions themes/shijin4/layouts/blog_index/summary.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<div class="node teaser">
<h2 class="title"><a href="{{ .Permalink }}">{{ .Title }}</a></h2>
<div class="meta">
{{ if (isset .Params "author") }}
Blog post by <a target="_blank" href="https://discuss.haiku-os.org/u/{{ lower .Params.author }}/">{{ .Params.author }}</a> on {{ .Date.Format "Mon, 2006-01-02 15:04" }}
{{ else }}
News posted on {{ .Date.Format "Mon, 2006-01-02 15:04" }}
{{ end }}
<div class="terms">
{{ range $i, $e := .Params.tags }}{{if $i}}, {{end}}
<a href="/tags/{{ $e | urlize }}" rel="tag">{{ . }}</a>{{ end }}
</div>
</div>
<p>{{ .Summary }}</p>
<div class="links">
{{ if (isset .Params "author") }}
<a class="blog-item" href="{{ .Parent.RelPermalink }}">{{ .Parent.Params.title }}</a>
{{ end }}
<a class="readmore-item" href="{{ .Permalink }}">Read More</a>
</div>
</div>
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

<title>Home | {{ .Site.Title }}</title>
<link rel="canonical" href="{{ .Permalink }}">
{{ partial "header.includes.html" . }}
{{ partial "header_includes.html" . }}
{{ if (.OutputFormats.Get "RSS") }}<link href="{{ with .OutputFormats.Get "RSS" }}{{ .Permalink }}{{ end }}" rel="alternate" type="application/rss+xml" title="{{ .Site.Title }}" />{{ end }}
</head>
<body>
Expand Down