urb 0.1.1 → 0.1.2

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
- NGY2ZWJiMDJhNGI0ZGU5MDA5OGM1NmJkNjg0NjAxNTk0YjZjZmUwMA==
4
+ YWRlY2NkMzNhNTYxMGU4Y2QwMWJkZDI5NTViYmQ2MmZkMTY3MTAwOA==
5
5
  data.tar.gz: !binary |-
6
- YmVkMzNjMjcxOTZmZGFmNWU1NWE4ZjRlNWNlMDYwMTVmNDkwMDViOQ==
6
+ OGU5ZGM4NDNkZmI0YWQ0NjllY2MwNDQ1ZWQwMGU5NWUxZmE2ZWIyZg==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- NTE1ZGYxM2Q3YjU2YWY5YTJmZjFkMjRhNGVkYmQ3OTY5NjA4YWM5MjNjOTIy
10
- MTBmYzRmMTgzZWQ4ZWE2OTFjNzM0NWU4Y2FjZTdiM2IwNGM3NjZjMjhlM2Ni
11
- MzM1OGQ3MGY5MjExMjZkMjk3MWU0ODRjYjU1MmQ5NWU4YzJlMWQ=
9
+ NjE5NzhjNmY3OTU4OWNjMzY0N2JlNDAyYzA0Zjc4NzNlMzgxY2RiZGI5YmE0
10
+ NDg4ZThhMDE3OTA0ZTgwODU1ZjA2MmM0ZjdiNDk3ZjI1YzY4MWEwM2JkN2Jm
11
+ NjkwNjA5Y2Y3NTc5ZTcxZjMwNzZmYzkxY2I2YmVhOGIwNzA1Nzc=
12
12
  data.tar.gz: !binary |-
13
- YmFhMTZlOWY1NTg1YzUzNzI4MmM1NWE4ZmI0OThmNTJmMjYwODZmNTIwODEy
14
- OWEwNjEzYmJlNmJlNzk4ZjJiOWIxMjNhMGQ0MjBkYTJjZTYzYzg3ZTU4NTc0
15
- YzRjMGE0YzA5NWYwYjA1N2Q4MTE2MGU3ODIxZWYzOGJjZWRhZjM=
13
+ MmU0NWVlMzk2OTUzYWFmMGZlMTVhZTdmODNhZWY2MDYwOWMwNmFmMDE2ZTUw
14
+ MGQyZmY0YjMxNDMwNTcyNDEyMDExZjZmNjMwOGY5M2Q1MmI2YmJiNTgzZTA2
15
+ NTdiOTFiMzlhODA4ZjliZTAyNWIwNGRkZDc4Y2UwODFmNTRmOGE=
@@ -1,5 +1,9 @@
1
1
  = URB CHANGELOG
2
2
 
3
+ == Version 0.1.2 (July 8, 2014)
4
+
5
+ * Using target ‘_self’ when not having passed a target
6
+
3
7
  == Version 0.1.1 (July 8, 2014)
4
8
 
5
9
  * Only opening link when having used the left click button. Opening in new tab when also having pressed CTRL or Meta (Windows / Command) key
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.1
1
+ 0.1.2
@@ -27,13 +27,14 @@ URB = (function() {
27
27
  if (leftClick) {
28
28
  if (target.tagName.toLowerCase() == 'a' && ((css == '') || $.hasClass(target, css))) {
29
29
  event.preventDefault();
30
- open(target.getAttribute('href'), ((event.ctrlKey || event.metaKey) ? '_blank' : '_self'));
30
+ open(target.getAttribute('href'), ((event.ctrlKey || event.metaKey) ? '_blank' : undefined));
31
31
  }
32
32
  }
33
33
  });
34
34
  },
35
35
 
36
36
  open = function(url, target) {
37
+ target || (target = '_self');
37
38
  var location = document.createElement('a'), path;
38
39
  location.href = url;
39
40
  if (location.host == '') {
@@ -1,7 +1,7 @@
1
1
  module URB
2
2
  MAJOR = 0
3
3
  MINOR = 1
4
- TINY = 1
4
+ TINY = 2
5
5
 
6
6
  VERSION = [MAJOR, MINOR, TINY].join(".")
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: urb
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Paul Engel