jquery_tag 0.1.0 → 0.1.1
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.
- data/Gemfile.lock +8 -8
- data/README.markdown +1 -1
- data/lib/jquery_tag/version.rb +1 -1
- data/lib/jquery_tag/view_helpers.rb +4 -3
- data/spec/jquery_tag_spec.rb +3 -3
- metadata +4 -4
data/Gemfile.lock
CHANGED
@@ -1,20 +1,20 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
jquery_tag (0.0
|
4
|
+
jquery_tag (0.1.0)
|
5
5
|
|
6
6
|
GEM
|
7
7
|
remote: http://rubygems.org/
|
8
8
|
specs:
|
9
9
|
diff-lcs (1.1.2)
|
10
|
-
rspec (2.
|
11
|
-
rspec-core (~> 2.
|
12
|
-
rspec-expectations (~> 2.
|
13
|
-
rspec-mocks (~> 2.
|
14
|
-
rspec-core (2.1
|
15
|
-
rspec-expectations (2.
|
10
|
+
rspec (2.2.0)
|
11
|
+
rspec-core (~> 2.2)
|
12
|
+
rspec-expectations (~> 2.2)
|
13
|
+
rspec-mocks (~> 2.2)
|
14
|
+
rspec-core (2.2.1)
|
15
|
+
rspec-expectations (2.2.0)
|
16
16
|
diff-lcs (~> 1.1.2)
|
17
|
-
rspec-mocks (2.
|
17
|
+
rspec-mocks (2.2.0)
|
18
18
|
|
19
19
|
PLATFORMS
|
20
20
|
ruby
|
data/README.markdown
CHANGED
@@ -12,7 +12,7 @@ Inside your views
|
|
12
12
|
|
13
13
|
Accepted options:
|
14
14
|
|
15
|
-
:version # Overrides the script version on the CDN URL. Defaults do '1.4'
|
15
|
+
:version # Overrides the script version on the CDN URL. Defaults do '1.4.4'
|
16
16
|
:file # Path for the local script. Defaults do 'jquery.js'
|
17
17
|
:ui # Loads the jquery-ui file. Accepts a true value for loading a 'jquery-ui.js' file or a String for the local path.
|
18
18
|
|
data/lib/jquery_tag/version.rb
CHANGED
@@ -13,13 +13,14 @@ module JqueryTag
|
|
13
13
|
private
|
14
14
|
def jquery_file(path, version)
|
15
15
|
path ||= 'jquery.js'
|
16
|
-
version ||= '1.4'
|
17
|
-
Rails.env.production? ? "
|
16
|
+
version ||= '1.4.4'
|
17
|
+
Rails.env.production? ? "//ajax.googleapis.com/ajax/libs/jquery/#{version}/jquery.min.js" : path
|
18
18
|
end
|
19
19
|
|
20
20
|
def jquery_ui_file(path)
|
21
21
|
path = path.is_a?(String) ? path : "jquery-ui.js"
|
22
|
-
|
22
|
+
version = '1.8.6'
|
23
|
+
Rails.env.production? ? "//ajax.googleapis.com/ajax/libs/jqueryui/#{version}/jquery-ui.min.js" : path
|
23
24
|
end
|
24
25
|
end
|
25
26
|
end
|
data/spec/jquery_tag_spec.rb
CHANGED
@@ -36,17 +36,17 @@ describe JqueryTag::ViewHelpers do
|
|
36
36
|
before { production! }
|
37
37
|
|
38
38
|
it "uses the google CDN path" do
|
39
|
-
expects_include_with ['
|
39
|
+
expects_include_with ['//ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js']
|
40
40
|
jquery_tag
|
41
41
|
end
|
42
42
|
|
43
43
|
it "accepts a different version for the jquery script" do
|
44
|
-
expects_include_with ['
|
44
|
+
expects_include_with ['//ajax.googleapis.com/ajax/libs/jquery/1.0.0/jquery.min.js']
|
45
45
|
jquery_tag :version => '1.0.0'
|
46
46
|
end
|
47
47
|
|
48
48
|
it "uses the google CDN path for the jquery ui script" do
|
49
|
-
expects_include_with ['
|
49
|
+
expects_include_with ['//ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js', '//ajax.googleapis.com/ajax/libs/jqueryui/1.8.6/jquery-ui.min.js']
|
50
50
|
jquery_tag :ui => true
|
51
51
|
end
|
52
52
|
end
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jquery_tag
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 25
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 1
|
9
|
-
-
|
10
|
-
version: 0.1.
|
9
|
+
- 1
|
10
|
+
version: 0.1.1
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Lucas Mazza
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2010-
|
18
|
+
date: 2010-12-07 00:00:00 -02:00
|
19
19
|
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|