jekyll-attendease 0.6.11.pre → 0.6.11
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/jekyll/attendease_plugin/helpers.rb +12 -0
- data/lib/jekyll/attendease_plugin/home_page.rb +5 -10
- data/lib/jekyll/attendease_plugin/presenter_page.rb +8 -1
- data/lib/jekyll/attendease_plugin/presenters_index_page.rb +8 -1
- data/lib/jekyll/attendease_plugin/schedule_day_page.rb +8 -1
- data/lib/jekyll/attendease_plugin/schedule_index_page.rb +8 -1
- data/lib/jekyll/attendease_plugin/schedule_session_page.rb +8 -1
- data/lib/jekyll/attendease_plugin/schedule_sessions_page.rb +8 -1
- data/lib/jekyll/attendease_plugin/sponsors_index_page.rb +8 -1
- data/lib/jekyll/attendease_plugin/venue_page.rb +8 -1
- data/lib/jekyll/attendease_plugin/venues_index_page.rb +8 -1
- data/lib/jekyll/attendease_plugin/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ee99d06f8c1a20786499ad241dd543f9f7721b8d
|
4
|
+
data.tar.gz: fd1258e81bd31ebbecd27c11e1ec3d78ba3aebd4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 63711df01ce343ab2a2caecf19a6ba81ce837a500c51d5dfc4dcea7c7f1750afbd7d1b754a80e50b9acb8007baee8b909df86919c97f1e10571b2212ec114486
|
7
|
+
data.tar.gz: dc94248e7026860ac525a099591fe25f56240a0a6fb99de6eec498f071d37c51ba1558fddd5b4aa236eb44c4561a439da0c4b1500518b8dcb4e98f59a7bae131
|
@@ -37,6 +37,18 @@ module Jekyll
|
|
37
37
|
s.encode('ASCII',
|
38
38
|
fallback: lambda { |c| fallback.key?(c) ? fallback[c] : undefined })
|
39
39
|
end
|
40
|
+
|
41
|
+
def self.get_template(site, template_string)
|
42
|
+
template = nil
|
43
|
+
|
44
|
+
if site.config['attendease'] && templates = site.config['attendease']['templates']
|
45
|
+
if t = templates.detect{|t| t['page'] == template_string}
|
46
|
+
template = t['data']
|
47
|
+
end
|
48
|
+
end
|
49
|
+
|
50
|
+
template
|
51
|
+
end
|
40
52
|
end
|
41
53
|
end
|
42
54
|
end
|
@@ -15,18 +15,13 @@ module Jekyll
|
|
15
15
|
|
16
16
|
self.data['title'] = site.config['homepage_title'] || 'Welcome'
|
17
17
|
|
18
|
-
if
|
19
|
-
|
20
|
-
template = t['data']
|
21
|
-
end
|
22
|
-
end
|
23
|
-
|
24
|
-
if template.nil?
|
25
|
-
# use the included template in the gem
|
26
|
-
self.content = File.read(File.join(base, '_attendease', 'templates', 'index.html'))
|
27
|
-
else
|
18
|
+
# Check if Attendease API has a template for this page
|
19
|
+
if template = Helpers.get_template(site, 'index')
|
28
20
|
# use the template file from the attendease api
|
29
21
|
self.content = template
|
22
|
+
else
|
23
|
+
# use the included template in the gem
|
24
|
+
self.content = File.read(File.join(base, '_attendease', 'templates', 'index.html'))
|
30
25
|
end
|
31
26
|
end
|
32
27
|
end
|
@@ -24,7 +24,14 @@ module Jekyll
|
|
24
24
|
|
25
25
|
self.data['presenter'] = presenter
|
26
26
|
|
27
|
-
|
27
|
+
# Check if Attendease API has a template for this page
|
28
|
+
if template = Helpers.get_template(site, 'presenters/presenter')
|
29
|
+
# use the template file from the attendease api
|
30
|
+
self.content = template
|
31
|
+
else
|
32
|
+
# use the included template in the gem
|
33
|
+
self.content = File.read(File.join(base, '_attendease', 'templates', 'presenters', 'presenter.html'))
|
34
|
+
end
|
28
35
|
end
|
29
36
|
end
|
30
37
|
end
|
@@ -15,7 +15,14 @@ module Jekyll
|
|
15
15
|
|
16
16
|
self.data['presenters'] = presenters
|
17
17
|
|
18
|
-
|
18
|
+
# Check if Attendease API has a template for this page
|
19
|
+
if template = Helpers.get_template(site, 'presenters/index')
|
20
|
+
# use the template file from the attendease api
|
21
|
+
self.content = template
|
22
|
+
else
|
23
|
+
# use the included template in the gem
|
24
|
+
self.content = File.read(File.join(base, '_attendease', 'templates', 'presenters', 'index.html'))
|
25
|
+
end
|
19
26
|
end
|
20
27
|
end
|
21
28
|
end
|
@@ -30,7 +30,14 @@ module Jekyll
|
|
30
30
|
|
31
31
|
self.data['instances'] = instances.sort{|x,y| [x['time'], x['session']['name']] <=> [y['time'], y['session']['name']]}
|
32
32
|
|
33
|
-
|
33
|
+
# Check if Attendease API has a template for this page
|
34
|
+
if template = Helpers.get_template(site, 'schedule/day')
|
35
|
+
# use the template file from the attendease api
|
36
|
+
self.content = template
|
37
|
+
else
|
38
|
+
# use the included template in the gem
|
39
|
+
self.content = File.read(File.join(base, '_attendease', 'templates', 'schedule', 'day.html'))
|
40
|
+
end
|
34
41
|
end
|
35
42
|
end
|
36
43
|
end
|
@@ -15,7 +15,14 @@ module Jekyll
|
|
15
15
|
|
16
16
|
self.data['dates'] = dates
|
17
17
|
|
18
|
-
|
18
|
+
# Check if Attendease API has a template for this page
|
19
|
+
if template = Helpers.get_template(site, 'schedule/index')
|
20
|
+
# use the template file from the attendease api
|
21
|
+
self.content = template
|
22
|
+
else
|
23
|
+
# use the included template in the gem
|
24
|
+
self.content = File.read(File.join(base, '_attendease', 'templates', 'schedule', 'index.html'))
|
25
|
+
end
|
19
26
|
end
|
20
27
|
end
|
21
28
|
end
|
@@ -16,7 +16,14 @@ module Jekyll
|
|
16
16
|
|
17
17
|
self.data['session'] = session
|
18
18
|
|
19
|
-
|
19
|
+
# Check if Attendease API has a template for this page
|
20
|
+
if template = Helpers.get_template(site, 'schedule/session')
|
21
|
+
# use the template file from the attendease api
|
22
|
+
self.content = template
|
23
|
+
else
|
24
|
+
# use the included template in the gem
|
25
|
+
self.content = File.read(File.join(base, '_attendease', 'templates', 'schedule', 'session.html'))
|
26
|
+
end
|
20
27
|
end
|
21
28
|
end
|
22
29
|
end
|
@@ -18,7 +18,14 @@ module Jekyll
|
|
18
18
|
self.data['sessions'] = sessions
|
19
19
|
self.data['dates'] = dates
|
20
20
|
|
21
|
-
|
21
|
+
# Check if Attendease API has a template for this page
|
22
|
+
if template = Helpers.get_template(site, 'schedule/sessions')
|
23
|
+
# use the template file from the attendease api
|
24
|
+
self.content = template
|
25
|
+
else
|
26
|
+
# use the included template in the gem
|
27
|
+
self.content = File.read(File.join(base, '_attendease', 'templates', 'schedule', 'sessions.html'))
|
28
|
+
end
|
22
29
|
end
|
23
30
|
end
|
24
31
|
end
|
@@ -15,7 +15,14 @@ module Jekyll
|
|
15
15
|
|
16
16
|
self.data['sponsor_levels'] = sponsor_levels
|
17
17
|
|
18
|
-
|
18
|
+
# Check if Attendease API has a template for this page
|
19
|
+
if template = Helpers.get_template(site, 'sponsors/index')
|
20
|
+
# use the template file from the attendease api
|
21
|
+
self.content = template
|
22
|
+
else
|
23
|
+
# use the included template in the gem
|
24
|
+
self.content = File.read(File.join(base, '_attendease', 'templates', 'sponsors', 'index.html'))
|
25
|
+
end
|
19
26
|
end
|
20
27
|
end
|
21
28
|
end
|
@@ -16,7 +16,14 @@ module Jekyll
|
|
16
16
|
|
17
17
|
self.data['venue'] = venue
|
18
18
|
|
19
|
-
|
19
|
+
# Check if Attendease API has a template for this page
|
20
|
+
if template = Helpers.get_template(site, 'venues/venue')
|
21
|
+
# use the template file from the attendease api
|
22
|
+
self.content = template
|
23
|
+
else
|
24
|
+
# use the included template in the gem
|
25
|
+
self.content = File.read(File.join(base, '_attendease', 'templates', 'venues', 'venue.html'))
|
26
|
+
end
|
20
27
|
end
|
21
28
|
end
|
22
29
|
end
|
@@ -15,7 +15,14 @@ module Jekyll
|
|
15
15
|
|
16
16
|
self.data['venues'] = venues
|
17
17
|
|
18
|
-
|
18
|
+
# Check if Attendease API has a template for this page
|
19
|
+
if template = Helpers.get_template(site, 'venues/index')
|
20
|
+
# use the template file from the attendease api
|
21
|
+
self.content = template
|
22
|
+
else
|
23
|
+
# use the included template in the gem
|
24
|
+
self.content = File.read(File.join(base, '_attendease', 'templates', 'venues', 'index.html'))
|
25
|
+
end
|
19
26
|
end
|
20
27
|
end
|
21
28
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jekyll-attendease
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.11
|
4
|
+
version: 0.6.11
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Michael Wood
|
@@ -194,9 +194,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
194
194
|
version: '0'
|
195
195
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
196
196
|
requirements:
|
197
|
-
- - "
|
197
|
+
- - ">="
|
198
198
|
- !ruby/object:Gem::Version
|
199
|
-
version:
|
199
|
+
version: '0'
|
200
200
|
requirements: []
|
201
201
|
rubyforge_project:
|
202
202
|
rubygems_version: 2.2.2
|