super_tools 0.0.11 → 0.0.12
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/super_interaction/command.rb +6 -1
- data/lib/super_tools/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e7d4fdaf5916965c3585fd595a0f190fbfc64f14
|
4
|
+
data.tar.gz: a0d01581b71688501b8375f775c92c3b3d8a3fc5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 300cb71a4965abc27138b60b780b4f8a79b9b4d47f2f23f0c660957c3f4cde451175eafcddd0f358910d17672476ed1f80b852e4ecdc749593739882a5429a56
|
7
|
+
data.tar.gz: c4902c4a0468b72fb20c4e3d7020ea95bf9ca5a946bbf3bd1ae1ff69102c26d3e2276b93819cdb22309665e736da3279c4d28cadefda3ed07b4267f36728bdf0
|
@@ -32,7 +32,12 @@ module SuperInteraction
|
|
32
32
|
# 注意:不要包 respond_to :js 會有問題
|
33
33
|
def modal(partial: nil, size: 'md', title: '', desc: '')
|
34
34
|
partial ||= context.action_name
|
35
|
-
|
35
|
+
case Rails.version[0]
|
36
|
+
when "4"
|
37
|
+
modal_html = context.render_to_string(partial, layout: 'modal.html.haml', locals: { bs_modal_size: size, title: title, desc: desc })
|
38
|
+
when "5", "6"
|
39
|
+
modal_html = context.render_to_string(partial, layout: 'modal.html.haml', assigns: { bs_modal_size: size, title: title, desc: desc })
|
40
|
+
end
|
36
41
|
cmd("$(function() { $.modal.show('#{helpers.j(modal_html)}'); });")
|
37
42
|
end
|
38
43
|
|
data/lib/super_tools/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: super_tools
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.12
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- eddie
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-01-
|
11
|
+
date: 2020-01-31 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|