simple_lightbox 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- data/.idea/workspace.xml +24 -8
- data/lib/simple_lightbox.rb +1 -7
- data/lib/simple_lightbox/railtie.rb +13 -0
- data/lib/simple_lightbox/simple_lightbox_helper.rb +16 -12
- data/lib/simple_lightbox/version.rb +1 -1
- metadata +2 -1
data/.idea/workspace.xml
CHANGED
@@ -37,7 +37,7 @@
|
|
37
37
|
<file leaf-file-name="simple_lightbox.rb" pinned="false" current="false" current-in-tab="false">
|
38
38
|
<entry file="file://$PROJECT_DIR$/lib/simple_lightbox.rb">
|
39
39
|
<provider selected="true" editor-type-id="text-editor">
|
40
|
-
<state line="
|
40
|
+
<state line="1" column="0" selection-start="53" selection-end="53" vertical-scroll-proportion="0.0">
|
41
41
|
<folding />
|
42
42
|
</state>
|
43
43
|
</provider>
|
@@ -46,7 +46,16 @@
|
|
46
46
|
<file leaf-file-name="simple_lightbox_helper.rb" pinned="false" current="false" current-in-tab="false">
|
47
47
|
<entry file="file://$PROJECT_DIR$/lib/simple_lightbox/simple_lightbox_helper.rb">
|
48
48
|
<provider selected="true" editor-type-id="text-editor">
|
49
|
-
<state line="
|
49
|
+
<state line="11" column="7" selection-start="333" selection-end="333" vertical-scroll-proportion="0.0">
|
50
|
+
<folding />
|
51
|
+
</state>
|
52
|
+
</provider>
|
53
|
+
</entry>
|
54
|
+
</file>
|
55
|
+
<file leaf-file-name="railtie.rb" pinned="false" current="false" current-in-tab="false">
|
56
|
+
<entry file="file://$PROJECT_DIR$/lib/simple_lightbox/railtie.rb">
|
57
|
+
<provider selected="true" editor-type-id="text-editor">
|
58
|
+
<state line="4" column="32" selection-start="105" selection-end="105" vertical-scroll-proportion="0.0">
|
50
59
|
<folding />
|
51
60
|
</state>
|
52
61
|
</provider>
|
@@ -101,10 +110,10 @@
|
|
101
110
|
<option value="$PROJECT_DIR$/Rakefile" />
|
102
111
|
<option value="$PROJECT_DIR$/lib/app/helpers/simple_lightbox/simple_lightbox_helper.rb" />
|
103
112
|
<option value="$PROJECT_DIR$/.gitignore" />
|
104
|
-
<option value="$PROJECT_DIR$/lib/simple_lightbox/railtie.rb" />
|
105
113
|
<option value="$PROJECT_DIR$/lib/simple_lightbox/simple_lightbox.rb" />
|
106
|
-
<option value="$PROJECT_DIR$/lib/simple_lightbox/simple_lightbox_helper.rb" />
|
107
114
|
<option value="$PROJECT_DIR$/simple_lightbox.gemspec" />
|
115
|
+
<option value="$PROJECT_DIR$/lib/simple_lightbox/simple_lightbox_helper.rb" />
|
116
|
+
<option value="$PROJECT_DIR$/lib/simple_lightbox/railtie.rb" />
|
108
117
|
<option value="$PROJECT_DIR$/lib/simple_lightbox.rb" />
|
109
118
|
<option value="$PROJECT_DIR$/lib/simple_lightbox/version.rb" />
|
110
119
|
</list>
|
@@ -286,23 +295,30 @@
|
|
286
295
|
</state>
|
287
296
|
</provider>
|
288
297
|
</entry>
|
298
|
+
<entry file="file://$PROJECT_DIR$/simple_lightbox.gemspec">
|
299
|
+
<provider selected="true" editor-type-id="text-editor">
|
300
|
+
<state line="21" column="0" selection-start="807" selection-end="807" vertical-scroll-proportion="0.0">
|
301
|
+
<folding />
|
302
|
+
</state>
|
303
|
+
</provider>
|
304
|
+
</entry>
|
289
305
|
<entry file="file://$PROJECT_DIR$/lib/simple_lightbox/simple_lightbox_helper.rb">
|
290
306
|
<provider selected="true" editor-type-id="text-editor">
|
291
|
-
<state line="
|
307
|
+
<state line="11" column="7" selection-start="333" selection-end="333" vertical-scroll-proportion="0.0">
|
292
308
|
<folding />
|
293
309
|
</state>
|
294
310
|
</provider>
|
295
311
|
</entry>
|
296
|
-
<entry file="file://$PROJECT_DIR$/simple_lightbox.
|
312
|
+
<entry file="file://$PROJECT_DIR$/lib/simple_lightbox/railtie.rb">
|
297
313
|
<provider selected="true" editor-type-id="text-editor">
|
298
|
-
<state line="
|
314
|
+
<state line="4" column="32" selection-start="105" selection-end="105" vertical-scroll-proportion="0.0">
|
299
315
|
<folding />
|
300
316
|
</state>
|
301
317
|
</provider>
|
302
318
|
</entry>
|
303
319
|
<entry file="file://$PROJECT_DIR$/lib/simple_lightbox.rb">
|
304
320
|
<provider selected="true" editor-type-id="text-editor">
|
305
|
-
<state line="
|
321
|
+
<state line="1" column="0" selection-start="53" selection-end="53" vertical-scroll-proportion="0.0">
|
306
322
|
<folding />
|
307
323
|
</state>
|
308
324
|
</provider>
|
data/lib/simple_lightbox.rb
CHANGED
@@ -1,17 +1,21 @@
|
|
1
|
-
module
|
1
|
+
module SimpleLightbox
|
2
2
|
|
3
|
-
|
4
|
-
contents = render :partial=>partial
|
5
|
-
page << "lightboxContainer.add(new Lightbox(#{contents.to_json}, #{title.to_json}, #{opts.to_json}))"
|
6
|
-
end
|
3
|
+
module SimpleLightboxHelper
|
7
4
|
|
8
|
-
|
9
|
-
|
10
|
-
|
5
|
+
def display_lightbox(partial, title, opts={})
|
6
|
+
contents = render :partial=>partial
|
7
|
+
page << "lightboxContainer.add(new Lightbox(#{contents.to_json}, #{title.to_json}, #{opts.to_json}))"
|
8
|
+
end
|
11
9
|
|
12
|
-
|
13
|
-
|
14
|
-
|
10
|
+
def close_lightbox
|
11
|
+
page << "lightboxContainer.pop()"
|
12
|
+
end
|
15
13
|
|
14
|
+
def lightbox_error_container
|
15
|
+
"<div class=\"lightbox-error\"></div>".html_safe
|
16
|
+
end
|
17
|
+
|
18
|
+
|
19
|
+
end
|
16
20
|
|
17
|
-
end
|
21
|
+
end
|
metadata
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
name: simple_lightbox
|
3
3
|
version: !ruby/object:Gem::Version
|
4
4
|
prerelease:
|
5
|
-
version: 0.1.
|
5
|
+
version: 0.1.2
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- Edward Taupier
|
@@ -28,6 +28,7 @@ files:
|
|
28
28
|
- Gemfile
|
29
29
|
- Rakefile
|
30
30
|
- lib/simple_lightbox.rb
|
31
|
+
- lib/simple_lightbox/railtie.rb
|
31
32
|
- lib/simple_lightbox/simple_lightbox_helper.rb
|
32
33
|
- lib/simple_lightbox/version.rb
|
33
34
|
- simple_lightbox.gemspec
|