urb 0.1.3 → 0.1.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- ODhlY2UyZjIxNzQ3MzQ3M2JhMjBmOWVmZTUxMTAyNmIxNDJkOWQ1Mg==
4
+ ZTUyZDNjOTExNzdlMzljOGQyZmNmMzIzMjZlNmZlNjY3YmJiMzE2OA==
5
5
  data.tar.gz: !binary |-
6
- YTg4ODA1YmRlNzFhMDJlMzIwZWRhMzgwYzc1YTY4OWZjYWJkOGJiYg==
6
+ NjM4ZDhmMjhmYzIwZThlOGM4OGY4MTk1NGVkNzJkNmExODgwMGFkYQ==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- OWRiOWY0MTY3NzEyMjQ1MzlhYWEyMGVhOTEyNmE0ODdiZTE2OTRhZjk4MDYz
10
- YTJjZDE1MzQyNWM1OTRiNmI3NzUxZWU3MTI2ODMxYmMzNzhjMGYwYjVmMzdk
11
- YjExN2YwZjMxNGRjYjBkY2VjODQzMGJiYmEyMjNkZDczYWY4ZDA=
9
+ NjYxMmI5ZDNhNTgyYmE4NjNiYWY3MDI2ZWZkNDViNzZlYTY4YThlNWUzMTEw
10
+ MWRjNWQ1ZDczNDY2MzY5Y2U2ZGEyYTUwMzZiNDUxMWFjOTcwYjY2NDdjNWY4
11
+ ZjBhNzY4Zjc4MjQ3YTcyMmQxNmIwNTEzMzUxMGY4OTQ0ZGZlZGE=
12
12
  data.tar.gz: !binary |-
13
- NWI4YTU5NmY3NDcwMWEzYjdjZWZjM2I1ZDBiODExYWZmOTA1YmI4NTljYjBl
14
- ZjBiMzIyNDY3NTY0MjFjYTZhMDQ5NzY2MDcyYzJjNDRiNTc0MzU4MjFiNDg0
15
- Mjk0NzQ3N2NiZTIxN2ZlNTZjYzM1OGQ5ZmYyZDJhMjhmNzg4ZmQ=
13
+ Zjk3NjU2MDA5ZjE0MTBlZWMyNGM3YzUzNzM4YmUyZTA0ZWEyNDNmODgwNDI2
14
+ NzViNDU5NWU2MzhjYTRhNjlkYzFiZjM5YTBiZGVkZjQ3N2ViYWRhODM3YzA1
15
+ ODU4YzFiY2VhZWYwZjJiNmNlZGM3M2QyMGU3M2YxZDViYTEyOTM=
data/CHANGELOG.rdoc CHANGED
@@ -1,5 +1,9 @@
1
1
  = URB CHANGELOG
2
2
 
3
+ == Version 0.1.4 (October 22, 2014)
4
+
5
+ * Ignoring links with hash tags
6
+
3
7
  == Version 0.1.3 (September 30, 2014)
4
8
 
5
9
  * Added urb.js to assets pipeline using the initializer
data/Gemfile CHANGED
@@ -12,4 +12,4 @@ group :test do
12
12
  gem "mocha"
13
13
  gem "rack"
14
14
  gem "rack-minitest", :require => "rack-minitest/test", git: "git://github.com/brandonweiss/rack-minitest.git"
15
- end
15
+ end
data/MIT-LICENSE CHANGED
@@ -17,4 +17,4 @@ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
17
  NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
18
  LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
19
  OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
- WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.rdoc CHANGED
@@ -102,4 +102,4 @@ Permission is hereby granted, free of charge, to any person obtaining a copy of
102
102
 
103
103
  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
104
104
 
105
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
105
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/Rakefile CHANGED
@@ -7,4 +7,4 @@ task :default => :test
7
7
 
8
8
  Rake::TestTask.new do |test|
9
9
  test.pattern = "test/**/test_*.rb"
10
- end
10
+ end
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.3
1
+ 0.1.4
@@ -7,7 +7,7 @@ if (typeof(URB) == 'undefined') {
7
7
  // * Except otherwise noted, URB is licensed under
8
8
  // * http://creativecommons.org/licenses/by/3.0
9
9
  // *
10
- // * $Date: 2014-07-08 10:56:53 $
10
+ // * $Date: 2014-10-22 17:22:12 $
11
11
  // *
12
12
 
13
13
  URB = (function() {
@@ -23,8 +23,8 @@ URB = (function() {
23
23
 
24
24
  init = function() {
25
25
  $.on(document, 'click', function(event) {
26
- var target = event.target || event.srcElement || window.event.target || window.event.srcElement, css = URB.css || '', leftClick = (event.which || event.button) == 1;
27
- if (leftClick) {
26
+ var target = event.target || event.srcElement || window.event.target || window.event.srcElement, css = URB.css || '', leftClick = (event.which || event.button) == 1, href = target.getAttribute('href');
27
+ if (leftClick && !href.match(/#/)) {
28
28
  if (target.tagName.toLowerCase() == 'a' && ((css == '') || $.hasClass(target, css))) {
29
29
  event.preventDefault();
30
30
  open(target.getAttribute('href'), ((event.ctrlKey || event.metaKey) ? '_blank' : undefined));
@@ -55,4 +55,4 @@ URB = (function() {
55
55
  };
56
56
  }());
57
57
 
58
- }
58
+ }
@@ -4,4 +4,4 @@ module UrbHelper
4
4
  render :partial => "urb/include"
5
5
  end
6
6
 
7
- end
7
+ end
@@ -1 +1 @@
1
- <%= javascript_include_tag :urb %>
1
+ <%= javascript_include_tag :urb %>
@@ -28,4 +28,4 @@ module URB
28
28
  end
29
29
 
30
30
  end
31
- end
31
+ end
data/lib/urb/version.rb CHANGED
@@ -1,7 +1,7 @@
1
1
  module URB
2
2
  MAJOR = 0
3
3
  MINOR = 1
4
- TINY = 3
4
+ TINY = 4
5
5
 
6
6
  VERSION = [MAJOR, MINOR, TINY].join(".")
7
- end
7
+ end
data/lib/urb.rb CHANGED
@@ -45,4 +45,4 @@ end
45
45
 
46
46
  def URB(*args)
47
47
  URB.config *args
48
- end
48
+ end
data/script/console CHANGED
@@ -4,4 +4,4 @@ require "bundler"
4
4
  Bundler.require :default, :development
5
5
 
6
6
  puts "Loading URB development environment (#{URB::VERSION})"
7
- Pry.start
7
+ Pry.start
@@ -5,4 +5,4 @@ if Dir.pwd == File.expand_path("../../..", __FILE__)
5
5
  add_group "URB", "lib"
6
6
  add_group "Test suite", "test"
7
7
  end
8
- end
8
+ end
data/test/test_helper.rb CHANGED
@@ -4,4 +4,4 @@ require "minitest/autorun"
4
4
  require "mocha/setup"
5
5
 
6
6
  require "bundler"
7
- Bundler.require :default, :development, :test
7
+ Bundler.require :default, :development, :test
@@ -11,7 +11,7 @@ module Unit
11
11
 
12
12
  describe "URB::VERSION" do
13
13
  it "has the current version" do
14
- version = File.read File.expand_path("../../../VERSION", __FILE__)
14
+ version = File.read(File.expand_path("../../../VERSION", __FILE__)).strip
15
15
  assert_equal version, URB::VERSION
16
16
  assert File.read(File.expand_path("../../../CHANGELOG.rdoc", __FILE__)).include?("Version #{version}")
17
17
  end
@@ -111,4 +111,4 @@ module Unit
111
111
  end
112
112
 
113
113
  end
114
- end
114
+ end
@@ -67,4 +67,4 @@ def app
67
67
  [200, {"Content-Type" => "text/plain"}, [params.inspect]]
68
68
  }
69
69
  end
70
- end
70
+ end
data/urb.gemspec CHANGED
@@ -18,4 +18,4 @@ Gem::Specification.new do |gem|
18
18
  gem.add_dependency "moneta"
19
19
  gem.add_development_dependency "rake"
20
20
  gem.add_development_dependency "pry"
21
- end
21
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: urb
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Paul Engel
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-09-30 00:00:00.000000000 Z
11
+ date: 2014-10-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: moneta