Skip to content

Commit 5a1042a

Browse files
feat: add language-specific content for Japanese and English in the index layout
1 parent 93fbf3c commit 5a1042a

File tree

1 file changed

+17
-2
lines changed

1 file changed

+17
-2
lines changed

layouts/index.html

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ <h2 class="toppage-h">Information</h2>
3434
<h2 class="toppage-h">Research & Development</h2>
3535
<!-- External Documentation -->
3636

37+
{{ if eq .Site.Language.Lang "ja" }}
3738
<div class="info-card">
3839
{{ with resources.GetRemote "https://qiita.com/Lemon73/feed" | transform.Unmarshal }}
3940
{{ range ( first 3 .entry ) }}
@@ -43,11 +44,25 @@ <h2 class="toppage-h">Research & Development</h2>
4344
<p id="info-summary">{{ index .content "#text" | plainify }}</p>
4445
</a>
4546
{{ end }}
46-
</ul>
47-
{{ end }}
47+
{{ end }}
4848
</div>
4949

5050
<p><a href="https://qiita.com/Lemon73">See more...</a></p>
51+
{{ else if eq .Site.Language.Lang "en" }}
52+
<div class="info-card">
53+
{{ with resources.GetRemote "https://alicenovel.web.app/en/blog/index.xml" | transform.Unmarshal }}
54+
{{ range ( first 3 .channel.item ) }}
55+
<a href="https://alicenovel.web.app{{ .link }}" target="_blank">
56+
<p id="info-date">{{ .pubDate | time.Format "2006.01.02" }} (Alice Project)</p>
57+
<p id="info-title">{{ .title }}</p>
58+
<p id="info-summary">{{ index .description | plainify }}</p>
59+
</a>
60+
{{ end }}
61+
{{ end }}
62+
</div>
63+
64+
<p><a href="https://alicenovel.web.app/en/blog">See more...</a></p>
65+
{{ end }}
5166

5267
<h2 class="toppage-h">About</h2>
5368

0 commit comments

Comments
 (0)