Skip to content

Commit 90c9946

Browse files
authored
Merge branch 'master' into Upgrade_to_rails5.2
2 parents be6ed2a + ee9c3ac commit 90c9946

30 files changed

+575
-344
lines changed

.github/FUNDING.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# These are supported funding model platforms
2+
3+
github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
4+
patreon: # Replace with a single Patreon username
5+
open_collective: # Replace with a single Open Collective username
6+
ko_fi: # Replace with a single Ko-fi username
7+
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
8+
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
9+
liberapay: # Replace with a single Liberapay username
10+
issuehunt: # Replace with a single IssueHunt username
11+
otechie: # Replace with a single Otechie username
12+
custom: ['https://coderdojo.jp/partnership']

Gemfile.lock

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ GEM
4747
arel (9.0.0)
4848
autoprefixer-rails (9.7.4)
4949
execjs
50-
backports (3.15.0)
50+
backports (3.16.0)
5151
bindex (0.8.1)
5252
binding_of_caller (0.8.0)
5353
debug_inspector (>= 0.0.1)
@@ -57,8 +57,8 @@ GEM
5757
autoprefixer-rails (>= 5.2.1)
5858
sassc (>= 2.0.0)
5959
builder (3.2.4)
60-
byebug (11.0.1)
61-
capybara (3.30.0)
60+
byebug (11.1.1)
61+
capybara (3.31.0)
6262
addressable
6363
mini_mime (>= 0.1.3)
6464
nokogiri (~> 1.8)
@@ -102,9 +102,9 @@ GEM
102102
railties (>= 4.2.0)
103103
faraday (0.17.3)
104104
multipart-post (>= 1.2, < 3)
105-
faraday_middleware (0.13.1)
105+
faraday_middleware (0.14.0)
106106
faraday (>= 0.7.4, < 1.0)
107-
ffi (1.11.3)
107+
ffi (1.12.2)
108108
flamegraph (0.9.5)
109109
font-awesome-rails (4.7.0.5)
110110
railties (>= 3.2, < 6.1)
@@ -119,25 +119,25 @@ GEM
119119
net-http-pipeline
120120
globalid (0.4.2)
121121
activesupport (>= 4.2.0)
122-
google-api-client (0.30.10)
122+
google-api-client (0.36.4)
123123
addressable (~> 2.5, >= 2.5.1)
124-
googleauth (>= 0.5, < 0.10.0)
124+
googleauth (~> 0.9)
125125
httpclient (>= 2.8.1, < 3.0)
126126
mini_mime (~> 1.0)
127127
representable (~> 3.0)
128128
retriable (>= 2.0, < 4.0)
129-
signet (~> 0.10)
130-
google_drive (3.0.3)
131-
google-api-client (>= 0.11.0, < 0.31.0)
129+
signet (~> 0.12)
130+
google_drive (3.0.4)
131+
google-api-client (>= 0.11.0, < 0.37.0)
132132
googleauth (>= 0.5.0, < 1.0.0)
133133
nokogiri (>= 1.5.3, < 2.0.0)
134-
googleauth (0.9.0)
134+
googleauth (0.10.0)
135135
faraday (~> 0.12)
136136
jwt (>= 1.4, < 3.0)
137137
memoist (~> 0.16)
138138
multi_json (~> 1.11)
139139
os (>= 0.9, < 2.0)
140-
signet (~> 0.7)
140+
signet (~> 0.12)
141141
haml (5.1.2)
142142
temple (>= 0.8.0)
143143
tilt
@@ -148,7 +148,7 @@ GEM
148148
html2haml (>= 1.0.1)
149149
railties (>= 5.1)
150150
hash-deep-merge (0.1.1)
151-
hashie (4.0.0)
151+
hashie (4.1.0)
152152
highline (1.7.10)
153153
html2haml (2.2.0)
154154
erubis (~> 2.7.0)
@@ -205,11 +205,11 @@ GEM
205205
mime-types (3.3.1)
206206
mime-types-data (~> 3.2015)
207207
mime-types-data (3.2019.1009)
208-
mimemagic (0.3.3)
208+
mimemagic (0.3.4)
209209
mini_mime (1.0.2)
210210
mini_portile2 (2.4.0)
211211
minitest (5.14.0)
212-
minitest-retry (0.1.9)
212+
minitest-retry (0.2.0)
213213
minitest (>= 5.0)
214214
msgpack (1.3.1)
215215
multi_json (1.14.1)
@@ -227,7 +227,7 @@ GEM
227227
pry (0.12.2)
228228
coderay (~> 1.1.0)
229229
method_source (~> 0.9.0)
230-
pry-byebug (3.7.0)
230+
pry-byebug (3.8.0)
231231
byebug (~> 11.0)
232232
pry (~> 0.10)
233233
pry-doc (1.0.0)
@@ -247,12 +247,12 @@ GEM
247247
pusher-client (0.6.2)
248248
json
249249
websocket (~> 1.0)
250-
rack (2.1.1)
250+
rack (2.1.2)
251251
rack-attack (6.2.2)
252252
rack (>= 1.0, < 3)
253253
rack-host-redirect (1.3.0)
254254
rack
255-
rack-mini-profiler (1.1.4)
255+
rack-mini-profiler (1.1.6)
256256
rack (>= 1.2.0)
257257
rack-test (1.1.0)
258258
rack (>= 1.0, < 3)
@@ -317,9 +317,9 @@ GEM
317317
rspec-core (> 3.3)
318318
rspec-support (3.9.2)
319319
ruby-mp3info (0.8.10)
320-
ruby_parser (3.14.1)
320+
ruby_parser (3.14.2)
321321
sexp_processor (~> 4.9)
322-
rubyzip (2.0.0)
322+
rubyzip (2.2.0)
323323
sass (3.7.4)
324324
sass-listen (~> 4.0.0)
325325
sass-listen (4.0.0)
@@ -366,11 +366,11 @@ GEM
366366
scrivito
367367
scrivito_ui (1.16.0)
368368
railties
369-
secure_headers (6.1.2)
369+
secure_headers (6.3.0)
370370
selenium-webdriver (3.142.7)
371371
childprocess (>= 0.5, < 4.0)
372372
rubyzip (>= 1.2.2)
373-
sexp_processor (4.13.0)
373+
sexp_processor (4.14.0)
374374
signet (0.12.0)
375375
addressable (~> 2.3)
376376
faraday (~> 0.9)

README.md

Lines changed: 23 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -10,17 +10,18 @@
1010

1111
coderdojo.jp の開発には以下のいずれかの方法で参加できます。Dojo 情報の修正やドキュメントの追加・執筆であれば、ブラウザだけで参加できます。
1212

13-
1. Dojo 情報やドキュメントなどの修正
13+
1. Dojo 情報やドキュメントなどの修正 ([» 詳細](#1-dojo-情報の更新))
1414
- 必要なもの: ブラウザ + GitHub アカウント
15-
2. [CoderDojo Kata](https://coderdojo.jp/kata) の執筆・編集
16-
- 必要なもの: ブラウザ + coderdojo.jp アカウント
17-
3. 新機能の開発やデザインの改善
15+
2. [CoderDojo Kata](https://coderdojo.jp/kata) の執筆・編集 ([» 詳細](#2-coderdojo-kata-の執筆編集))
16+
- 必要なもの: ブラウザ + coderdojo.jp アカウント
17+
3. 新機能の開発やデザインの改善 ([» 詳細](#3-新機能の開発やデザインの改善))
1818
- 必要なもの: 各種開発環境のセットアップ (開発者向け)
1919

2020
新機能の開発やデザインの改善には開発環境が必要ですが、ちょっとした文言の追記・修正であればブラウザだけで参加できるようになっているのが特徴です ✨📝💨
21+
2122
それぞれの参加方法は次のとおりです。
2223

23-
### 1. Dojo 情報の更新
24+
## 1. Dojo 情報の更新
2425

2526
Dojo 情報は次の手順で簡単に更新できます。
2627

@@ -33,22 +34,25 @@ Dojo 情報は次の手順で簡単に更新できます。
3334

3435
https://coderdojo.jp/docs にあるドキュメントの編集方法も同様です。[db/docs](https://github.com/coderdojo-japan/coderdojo.jp/tree/master/db/docs)ディレクトリをブラウザで開き、修正したいファイルをクリックして、修正内容を提案してください。同ディレクトページの右上にある `Create new file` ボタンをクリックすると、新しいドキュメントの追記を提案することもできます。
3536

36-
### 2. CoderDojo Kata の執筆・編集
37+
## 2. CoderDojo Kata の執筆・編集
3738

38-
[Kata](https://coderdojo.jp/kata)[Sotechsha](https://coderdojo.jp/sotechsha) などのいくつかのページは、[Scrivito](https://scrivito.com/) と呼ばれる CMS (コンテンツ管理サービス) で運営しています。背景や使用例については次のスライドをご参照ください。
39+
[Kata](https://coderdojo.jp/kata)[Sotechsha](https://coderdojo.jp/sotechsha) などのいくつかのページは、[Scrivito](https://scrivito.com/) と呼ばれる CMS (コンテンツ管理サービス) で運営しています。
3940

40-
CoderDojo を支える Rails CMS の活用事例 - Speaker Deck
41-
https://speakerdeck.com/yasulab/case-study-rails-cms-for-coderdojo
41+
編集方法は下記の手順書をご参照してください。
42+
43+
:scroll: Kata の編集方法 - esa
44+
https://esa-pages.io/p/sharing/7542/posts/213/bc0e68f705b7298ae5e0.html
4245

43-
編集方法については下記の手順書をご参考にしてください
46+
Kata の編集には CoderDojo Japan のアカウントが必要です。アカウントを発行したい場合は [@yasulab](https://twitter.com/yasulab) までご連絡ください
4447

45-
記事の編集手順書 - Google Drive
46-
http://bit.ly/coderdojo-kata-edit
48+
CMS を利用している背景や技術仕様などについては次のスライド資料にまとめています。もし興味あればお気軽にご参照ください :wink:
49+
50+
:scroll: CoderDojo を支える Rails CMS の活用事例 - Speaker Deck
51+
https://speakerdeck.com/yasulab/case-study-rails-cms-for-coderdojo
4752

4853

49-
編集用のユーザーアカウントを発行したい場合は [@yasulab](https://twitter.com/yasulab) までお問い合わせください。
5054

51-
### 3. 新機能の開発やデザインの改善
55+
## 3. 新機能の開発やデザインの改善
5256

5357
本サイトでは以下の技術が使われているので、それぞれのツールをセットアップします。
5458

@@ -57,15 +61,15 @@ http://bit.ly/coderdojo-kata-edit
5761
- [PostgreSQL](https://www.postgresql.jp/)
5862
- [Scrivito](https://scrivito.com/) (Kataページ開発時に必要)
5963

60-
#### セットアップ方法
64+
### セットアップ方法
6165

6266
1. 本リポジトリを fork 後、clone します
6367
1. ターミナルから `$ bin/setup` を実行します
6468
1. `$ rails server` でローカルサーバーを立ち上げます
6569
1. ブラウザから [localhost:3000](http://localhost:3000) にアクセスします
6670
1. [coderdojo.jp](https://coderdojo.jp/) と同様のサイトが表示できれば完了です
6771

68-
#### Dockerを利用したセットアップ方法
72+
### Dockerを利用したセットアップ方法
6973

7074
Dockerを利用する場合は上記ツールをインストールする必要はありません。
7175

@@ -80,12 +84,12 @@ Dockerを利用する場合は上記ツールをインストールする必要
8084
1. ブラウザから [localhost:3000](http://localhost:3000) にアクセスします
8185
1. [coderdojo.jp](https://coderdojo.jp/) と同様のサイトが表示できれば完了です
8286

83-
#### Development with Scrivito
87+
### Development with Scrivito
8488

8589
Some pages require [Scrivito](https://scrivito.com/), Professional Cloud-Based Rails CMS, such as:
8690

8791
- `/kata`
88-
- `/news/*`
92+
- ~~/news/*~~ (Outdated)
8993
- `/sotechsha/*`
9094

9195
CMS enables wider people to contribute to editing contents,
@@ -95,7 +99,7 @@ engineers to join developing Scrivito-used pages like above.
9599
If interested in developing them, contact [@yasulab](https://github.com/yasulab) to
96100
get production keys (`SCRIVITO_TENANT` and `SCRIVITO_API_KEY`).
97101

98-
### 他、開発に関する資料
102+
## 他、開発に関する資料
99103

100104
開発に関する資料は [/docs](https://github.com/coderdojo-japan/coderdojo.jp/tree/master/docs) や下記サイトにまとめてあります (最新順)。必要に応じて適宜ご参照ください。
101105

app/assets/stylesheets/custom.scss

Lines changed: 21 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -521,23 +521,32 @@ body>footer a:hover {
521521
padding-top: 1em;
522522
margin: .4em
523523
}
524+
.dojo-flex{
525+
display: flex !important;
526+
flex-wrap: wrap;
527+
justify-content: center;
528+
margin: auto;
529+
}
524530

525531
.dojo {
526-
display: inline-block;
527-
height: 300px;
528532
width: 45%;
529533
margin: 5px;
530534
padding: 15px 0;
531535
background: #fff;
532536
position: relative;
533-
text-align: center
534-
}
535-
536-
.dojo>p {
537-
font-size: 90%;
538-
padding: 5px 10px;
539537
text-align: center;
540-
margin: 5px 0
538+
height: auto;
539+
540+
//display: block;
541+
display: flex;
542+
flex-direction: column;
543+
p {
544+
font-size: 70%;
545+
padding: 10px 10px 5px;
546+
text-align: center;
547+
margin: 5px 0;
548+
margin-top: auto;
549+
}
541550
}
542551

543552
.dojo-picture {
@@ -546,7 +555,7 @@ body>footer a:hover {
546555
width: 96px;
547556
background-position: center center; // border-radius: 48px;
548557
background-size: cover;
549-
margin: 0 auto
558+
margin: 0 auto;
550559
}
551560

552561
.dojo-name {
@@ -565,7 +574,7 @@ body>footer a:hover {
565574
}
566575

567576
.dojo-private:hover {
568-
text-decoration: none
577+
text-decoration: none;
569578
}
570579

571580
.event-region {
@@ -622,8 +631,7 @@ body>footer a:hover {
622631

623632
@media only screen and (min-width:560px) {
624633
.dojo {
625-
width: 220px;
626-
height: 275px;
634+
width: calc(220px - 10px);
627635
margin: 10px;
628636
}
629637
.event {

app/helpers/application_helper.rb

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,15 @@ def full_title(page_title)
1010
end
1111

1212
def full_url(page_url)
13-
page_url = @obj.permalink if page_url.empty? && @obj && !@obj.permalink.nil?
13+
# When URL is composed by Scrivito
14+
return @obj.permalink if @obj && !@obj.permalink.nil?
15+
16+
# When URL is composed by Rails
1417
if page_url.empty?
15-
# URLs rendered via Rails
18+
# Set og:url with request param
1619
request.url
1720
else
18-
# URLs rendered via Scrivito
21+
# Set og:url with given param
1922
page_url
2023
end
2124
end
@@ -30,7 +33,7 @@ def full_description(description)
3033
end
3134

3235
def kata_description
33-
"CoderDojo で活用されている資料や教材、子ども向けのプログラミングキャンプ・プログラミングコンテスト情報、CoderDojo の立ち上げ方・関わり方など、CoderDojo を中心にして色々なトピックまとめています。"
36+
"道場で役立つ資料やコンテスト情報、立ち上げ方や各種支援をまとめています。"
3437
end
3538

3639
def using_scrivito?

0 commit comments

Comments
 (0)