chapmanchri_quotemachine2 0.1.4 → 0.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/chapmanchri_quotemachine2/version.rb +1 -1
- data/lib/chapmanchri_quotemachine2.rb +8 -8
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 5340aae9e5f37d54619b4b213d617049f8f4ca75d11ba31184493606d604cae3
|
|
4
|
+
data.tar.gz: 311d91c96427b1cb0f69afa86e25db0be5a47672799e92b57ed29e9e44a52a19
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: e8db444e9e151a47b87bce7efa7118fd5283ec9c5f20627552ccd8a04a4429775dba4891c0290d98dfca657353d134525f43916ecbf367e07256b57f71d91d13
|
|
7
|
+
data.tar.gz: e31aa721122e90cbdf6662033b32561576fa9c78a9443360fb190030a4ccd08ef814aa0d46c5a2cce056720de3d7935a9be5a8a85e24bab9d4f8ab09dfcb95d9
|
data/Gemfile.lock
CHANGED
|
@@ -189,10 +189,10 @@ def build_display
|
|
|
189
189
|
if @phrase.length == 1
|
|
190
190
|
#the phrase if the first phrase of the stanza
|
|
191
191
|
if @phrase[0] == 1
|
|
192
|
-
result_text = show_current_section + "<form id='plus_next' action='/plus_next' method='post'><button class='form-submit' type='submit'
|
|
192
|
+
result_text = show_current_section + "<form id='plus_next' action='/plus_next' method='post'><button class='form-submit' type='submit'>more...</button></form>"
|
|
193
193
|
#the phrase is the second phrase of the stanza
|
|
194
194
|
elsif @phrase[0] == 2
|
|
195
|
-
result_text = "<div class='plus-button'
|
|
195
|
+
result_text = "<div class='plus-button'>more...</div>" + show_current_section
|
|
196
196
|
end
|
|
197
197
|
end
|
|
198
198
|
end
|
|
@@ -201,11 +201,11 @@ def build_display
|
|
|
201
201
|
if @poem[@stanza_current].length > 3
|
|
202
202
|
if @phrase.length == 1
|
|
203
203
|
if @phrase[0] == 1
|
|
204
|
-
result_text = show_current_section + "<form id='plus_next' action='/plus_next' method='post'><button class='form-submit' type='submit'
|
|
204
|
+
result_text = show_current_section + "<form id='plus_next' action='/plus_next' method='post'><button class='form-submit' type='submit'>more...</button></form>"
|
|
205
205
|
elsif (@phrase[0] >= 2) && @phrase[0] < @poem[@stanza_current].length - 1
|
|
206
|
-
result_text = "<div class='plus-button'
|
|
206
|
+
result_text = "<div class='plus-button'>more...</div>" + show_current_section + "<form id='plus_next' action='/plus_next' method='post'><button class='form-submit' type='submit'>more...</button></form>"
|
|
207
207
|
elsif @phrase[0] == @poem[@stanza_current].length - 1
|
|
208
|
-
result_text = "<div class='plus-button'
|
|
208
|
+
result_text = "<div class='plus-button'>more...</div>" + show_current_section
|
|
209
209
|
end
|
|
210
210
|
end
|
|
211
211
|
end
|
|
@@ -224,18 +224,18 @@ def build_display
|
|
|
224
224
|
# there are two phrases in array, current_phrase is not first or last stanza,
|
|
225
225
|
# and current_phrase > second phrase
|
|
226
226
|
if @phrase.length == 2 && @section_current != 1 && @section_current != @poem[@stanza_current].length - 1
|
|
227
|
-
result_text = "<div class='minus-button'>-</div><p>#{show_previous_section}</p><p>#{show_current_section}</p><form id='plus_next' action='/plus_next' method='post'><button class='form-submit' type='submit'
|
|
227
|
+
result_text = "<div class='minus-button'>-</div><p>#{show_previous_section}</p><p>#{show_current_section}</p><form id='plus_next' action='/plus_next' method='post'><button class='form-submit' type='submit'>more...</button></form>"
|
|
228
228
|
end
|
|
229
229
|
# there are two phrases in array, current_phrase is not first or last,
|
|
230
230
|
# and current_phrase < second phrase
|
|
231
231
|
if @phrase.length == 2 && @section_current != 1 \
|
|
232
232
|
&& @section_current != @poem[@stanza_current].length - 1 \
|
|
233
233
|
&& @phrase.last > @section_current
|
|
234
|
-
result_text = "<div class='plus-button'
|
|
234
|
+
result_text = "<div class='plus-button'>more...</div><p>#{show_current_section}</p><p>#{show_next_section}</p><div class='minus-button'>-</div>"
|
|
235
235
|
end
|
|
236
236
|
# three phrases in the phrase storage array
|
|
237
237
|
if @phrase.length == 3
|
|
238
|
-
result_text = "<div class='minus-button'
|
|
238
|
+
result_text = "<div class='minus-button'>-</div><p>#{show_previous_section}</p><p>#{show_current_section}</p><p>#{show_next_section}</p><div class='minus-button'>-</div>"
|
|
239
239
|
end
|
|
240
240
|
end
|
|
241
241
|
end
|