coursegen 0.1.2 → 0.1.3

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: b38a30d902730db279c9dad902e23d6cb328c739
4
- data.tar.gz: 242bd746b11d92eed61f99960e6d5f10b4bc4087
3
+ metadata.gz: 7767efe0f0922d4233f551ebb90445600cd83657
4
+ data.tar.gz: 9696951cb26d33b6b0e2e4b28d920a61791470f9
5
5
  SHA512:
6
- metadata.gz: 570b4211e1af47d2032817e779df06f7feac193fc69645d0feef11330c029d24b792d47df5b6900b3a6107294f49b3200c914682d5f44bdd66db553f6590ef86
7
- data.tar.gz: 9b1a7f6fca6e9c43a1d18f7c1686c7b4595442dfbab6b853a9f6d8c71bbb0d92d1a89185077bed19055ef855fc57cacc757ca07023438667488e6b2c64516e2b
6
+ metadata.gz: a59dd38377282f5891a3cd2d26aec4e4a634946441d7d1638d5fc8361b55a04bd8145e4aafc1428dfabe2d06620ea57eae45b1c6763370565fb0da5eb4438914
7
+ data.tar.gz: 67a52800d30c4864082aad2d7574c382e506dcfdf2cc19f704586915be3eb8684ef1e0272663f3eee1de59b9d47d4976ec64e10dd3d9d47820e8d8b6804c4779
@@ -109,6 +109,33 @@ HTMLSTRING
109
109
  body
110
110
  end
111
111
 
112
+ def carousel_new(filenames)
113
+ carousel_work(filenames.map {|filename| "/content/topics/images/"+filename })
114
+ end
115
+
116
+ def carousel_work(filenames)
117
+ body = %~<div id="myCarousel" class="carousel slide" style="width: 500px; margin: 0 auto;">
118
+ <div class="carousel-inner" style="margin: 20px; ">~
119
+ counter = 0
120
+ filenames.each do
121
+ |nam|
122
+ if counter == 0
123
+ body << %~<div class="item active">~
124
+ else
125
+ body << %~<div class="item">~
126
+ end
127
+ body << %~<img src="~
128
+ body << nam
129
+ body << %~" class="img-polaroid" alt=""></div>~
130
+ counter += 1
131
+ end
132
+ body << %~</div> <a class="left carousel-control" href="#myCarousel" data-slide="prev">‹</a>
133
+ <a class="right carousel-control" href="#myCarousel" data-slide="next">›</a>
134
+ </div>~
135
+ body
136
+ end
137
+
138
+
112
139
  def ruby_begin
113
140
  "\n~~~~~~"
114
141
  end
@@ -1,3 +1,3 @@
1
1
  module Coursegen
2
- VERSION = "0.1.2"
2
+ VERSION = "0.1.3"
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.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pito Salas
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-12-23 00:00:00.000000000 Z
11
+ date: 2015-03-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler