coursegen 0.4.2 → 0.5.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 4aa75e9754a6ce6c2062f4c37aab0846397a9412
4
- data.tar.gz: 634163b939293459d18e57444f41919b3317d277
3
+ metadata.gz: 95d19a204722d46d2b449d337e27120f1a5695c7
4
+ data.tar.gz: e01e950e3f56726062f896af924837cdc8785636
5
5
  SHA512:
6
- metadata.gz: 10a00235c1a6e719df5ddf44006d46c1df8f2979151a3b0cf8a48ef97c0e726db41b62a4e1ea619133db69854f2a55c94189aa9dec2bfd4e1aa0429d6dabc639
7
- data.tar.gz: b7eb6b5220879501cc8996d40c7ac960d1e5d9a41734090fe90831409090d90b51424ea141a4b537e2ac023a43c4c50dd322184f2d80313d82b6178bfbbe519d
6
+ metadata.gz: '089b8cc554d0cf6ddb255d62611de872aba7a4d39958ac9b906c9892a2c619c1ed84595e634cb0e8f3fd88683f527eaadd1c09b6197204663793de485e1ef901'
7
+ data.tar.gz: 8d743322068f0fc4349627c009dbae91249266cf03c1274435bfaaaa26afb301ed1cb8805343c3c3bb049ef5489fa5eaa3fb02e646fe5132fabf19f5a563acd7
@@ -88,18 +88,19 @@ HTMLSTRING
88
88
  iconbadge("time", "Must be submitted first thing on day of class")
89
89
  end
90
90
 
91
- def include_image_old string, extra_class: nil
91
+ def include_image_old filename_string, extra_class: nil
92
92
  css_class = "img-responsive"
93
93
  css_class += " img-" + extra_class unless extra_class.nil?
94
-
95
- "<img src=\"/content/images/#{string}\" class=\"%s\" />" % css_class
94
+ <<-HTMLSTRING
95
+ <img src="#{filename_string}" class=\"%s\" />" % css_class
96
+ HTMLSTRING
96
97
  end
97
98
 
98
- def include_image filename_string, width: 8
99
+ def include_image filename_string, extra: ""
99
100
  <<-HTMLSTRING
100
101
  <div class="row">
101
- <div class="col-md-offset-2 col-md-#{width}">
102
- <img src="#{filename_string}" class="img-responsive img-thumbnail" />
102
+ <div class="col-md-offset-2 col-md-8">
103
+ <img src="#{filename_string}" class="img-responsive img-thumbnail" #{extra}/>
103
104
  </div>
104
105
  </div>
105
106
  HTMLSTRING
@@ -137,6 +138,10 @@ HTMLSTRING
137
138
  "*Discussion:*{: style=\"color: blue\"} *#{string}*"
138
139
  end
139
140
 
141
+ def discussion_box string
142
+ %(<div class="alert alert-info"><strong>Discussion:</strong> #{string}</div>)
143
+ end
144
+
140
145
  def homework_hdr
141
146
  "#### Homework due for today"
142
147
  end
@@ -167,17 +172,22 @@ HTMLSTRING
167
172
  <div class="carousel-inner" role="listbox" style="margin: 20px; ">)
168
173
  counter = 0
169
174
  filenames.each do |nam|
170
- ci = counter == 0 ? %(<div class="carousel-item active">) : %(<div class="carousel-item">)
171
- puts "****** #{ci}"
175
+ ci = counter == 0 ? %(<div class="item active">) : %(<div class="item">)
172
176
  body << ci
173
177
  body << %(<img src=")
174
178
  body << nam
175
- body << %(" class="d-block img-fluid"></div>)
179
+ body << %("/>"></div>)
176
180
  counter += 1
177
181
  end
178
- body << %(</div> <a class="carousel-control-prev" role="button" href="#myCarousel" data-slide="prev">‹</a>
179
- <a class="carousel-control-next" role="button" href="#myCarousel" data-slide="next">›</a>
180
- </div>)
182
+ body << %(</div> <a class="left carousel-control" role="button" href="#myCarousel" data-slide="prev">
183
+ <span class="glyphicon glyphicon-chevron-left"></span>
184
+ <span class="sr-only">Previous</span>
185
+ </a>
186
+ <a class="right carousel-control" role="button" href="#myCarousel" data-slide="next">
187
+ <span class="glyphicon glyphicon-chevron-right"></span>
188
+ <span class="sr-only">Next</span>
189
+ </a>
190
+ </div>)
181
191
  body
182
192
  end
183
193
 
@@ -1,3 +1,3 @@
1
1
  module Coursegen
2
- VERSION = "0.4.2"
2
+ VERSION = "0.5.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: coursegen
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.2
4
+ version: 0.5.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pito Salas
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-08-25 00:00:00.000000000 Z
11
+ date: 2017-10-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler