Skip to content

Commit 779cfec

Browse files
authored
Merge pull request #29 from coderdojo-japan/session-dynamic
セッションの一覧を動的表示に変更
2 parents 82ba520 + 50ec0b6 commit 779cfec

File tree

6 files changed

+54
-10
lines changed

6 files changed

+54
-10
lines changed

_config.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,6 @@
77
jailed: false
88
theme: jekyll-theme-primer
99
gfm_quirks: paragraph_end
10+
collections:
11+
session:
12+
output: true

_includes/header.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ <h3 class="gnav__title text-center">DojoCon Japan 2018</h3>
6666
<li><a class="gnav_item" href="/#about">ABOUT</a></li>
6767
<li><a class="gnav_item" href="/#news">NEWS</a></li>
6868
<li><a class="gnav_item" href="/#access">ACCESS</a></li>
69-
<li><a class="gnav_item" href="/#session">SESSION</a></li>
69+
<li><a class="gnav_item" href="/session/">SESSION</a></li>
7070
<li><a class="gnav_item" href="/#sponsor">SPONSOR</a></li>
7171
</ul>
7272
<ul class="gnav__sns list-inline text-center text-md-right mb-0">

_layouts/archive.html

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{% include header.html %}
2+
<div class="mt-5">
3+
{{content}}
4+
</div>
5+
{% include footer.html %}

_session/index.html

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
---
2+
title: Session
3+
j-title : DojoCon Japan 2018セッションの一覧
4+
description: DojoCon Japan 2018におけるセッションの一覧
5+
layout: archive
6+
---
7+
8+
<section id="session">
9+
<div class="container">
10+
<div class="row post-list">
11+
{% for session in site.session %}
12+
{% if session.layout == "archive" %}
13+
{% else %}
14+
<div class="col-6 col-md-3">
15+
<article class="post-list__item">
16+
<div class="post-list__thumbnail"><a href="{{ site.url }}{{ session.url }}"><img
17+
src="/img/{{ session.thumbnail }}" alt="{{session.speaker-name}}の顔写真"></a></div>
18+
<div class="post-list__content">
19+
<h3 class="post-list__title">{{ session.j-title }}</h3>
20+
<!--p.post-list__time-->
21+
<p class="post-list__speaker">{{ session.speaker-name }}</p>
22+
</div>
23+
<div class="post-list__more"><a class="btn btn__green btn__xl" href="{{ site.url }}{{ session.url }}"
24+
role="button">more</a></div>
25+
</article>
26+
</div>
27+
{% endif %}
28+
{% endfor %}
29+
</div>
30+
</div>
31+
</section>
File renamed without changes.

index.html

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -110,16 +110,21 @@ <h2 class="heading__01 bgwh">ACCESS</h2>
110110
</div>
111111
<h2 class="heading__01">SESSION</h2>
112112
<div class="row post-list">
113-
<div class="col-6 col-md-3">
114-
<article class="post-list__item"><a href="/session/takashi-hosoya.html">
115-
<div class="post-list__thumbnail"><img src="img/hosoya.jpg" alt="細谷 崇のキリッとした画像"></div>
116-
<div class="post-list__content">
117-
<h3 class="post-list__title">基調講演</h3>
118-
<!--p.post-list__time-->
119-
<p class="post-list__speaker">細谷 崇</p>
113+
{% for session in site.session %}
114+
{% if session.layout == "archive" %}
115+
{% else %}
116+
<div class="col-6 col-md-3">
117+
<article class="post-list__item">
118+
<div class="post-list__thumbnail"><a href="{{ site.url }}{{ session.url }}"><img src="img/{{ session.thumbnail }}" alt="{{session.speaker-name}}の顔写真"></a></div>
119+
<div class="post-list__content">
120+
<h3 class="post-list__title">{{ session.j-title }}</h3>
121+
<!--p.post-list__time-->
122+
<p class="post-list__speaker">{{ session.speaker-name }}</p>
123+
</div>
124+
<div class="post-list__more"><a class="btn btn__white btn__xl" href="{{ site.url }}{{ session.url }}" role="button">more</a></div></article>
120125
</div>
121-
<div class="post-list__more"><a class="btn btn__white btn__xl" href="/session/takashi-hosoya.html" role="button">more</a></div></a></article>
122-
</div>
126+
{% endif %}
127+
{% endfor %}
123128
</div>
124129
</div>
125130
</section>

0 commit comments

Comments
 (0)