yepkeynav-rails 0.0.1 → 0.0.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
- N2UwZGRhOTU0YThhYjAyMWRkMDRmYjYxZDUwZTlhMWQ4NDQyZDMxMA==
4
+ OGUxODY1YmViNmRhNGJhM2JhNjAzZTBjMjNlNjQxODMwOTVlNjg3YQ==
5
5
  data.tar.gz: !binary |-
6
- YWM1OTA0MTYxOWYzZmM3YjBiZGJkZDEyNzk5YjExMDIwYjYwOWEzZQ==
6
+ NDY0N2IyZTk2ZjQxMGU1YWIwMTUwNjJkYzg0NGQwNTNjNWZmMzZhNg==
7
7
  !binary "U0hBNTEy":
8
8
  metadata.gz: !binary |-
9
- NjA4ZDg3YjYzMTc0ZGFkZmIzMmIyMGMxZGVjMGM2ZjZkMGYxY2ExOWRmZTkw
10
- MTBlNmY3MzlmNzFmNDQwMjI5OWI1YjA5ZWYxOWI1ZmU1NDQyY2ZhZDgxNWZl
11
- MzFlMDk1YjhkY2QzZjUxN2YzODgxMGZhZDZjNWUzYTI3YWYxZTA=
9
+ MTAwNTBkOTNkYjhiZGE4NzBlMmMxMzFiNTIyNjMyNjcxMDg3YzBmZDc5NTM1
10
+ YjZjNDA2M2UwMWVmZTA3NjdmM2ExMTE5YjcyYzQ1ODgwMzg4ZGMwZGEzYjFh
11
+ OGY5OWFmYjZiNjkzODhlYjE3OTI4MmVkYzVkZjgwZDM2NzVmYjE=
12
12
  data.tar.gz: !binary |-
13
- Nzg4NzYxZDM5NTI1OTI2NzUyMzc2MDZkNGEyMmM5YWEzMTUwZmRjZDUwMjMz
14
- ZWVjM2UwMjU3MTdjMjM0ZGM5MzgxZmUwMWYwZTc5OGIyMmNhN2FjNjQ4NjNj
15
- MWFiNTljMjJhYzRjMTMyM2E1ZGQ1MTAxMGExZTMwOTMxYjdiYzI=
13
+ ZmEwNWEyMWZhMTlhMmNhYWU2OTUyYjI4YzlhODVhNGRmZDRjODQ1MWQ2ODJi
14
+ NDMzZTE1NDE5YTMzZTQ5MGZhZTI4YTlmMzUwMzM4OGUwYWM5NDVhODU2ODlj
15
+ N2E2MjM1YmU2ZjQ4ODNlOGIyZjYzNTc3NGViZmRlZTA4MTU0ZTQ=
data/README.rdoc CHANGED
@@ -4,3 +4,26 @@ This project rocks and uses MIT-LICENSE.
4
4
 
5
5
  == Usage
6
6
 
7
+ Add to your application.js
8
+
9
+ //= require yepKeyNav
10
+
11
+ == More Info
12
+
13
+ https://github.com/josecoelho/yepKeyNav
14
+
15
+
16
+ == Development
17
+
18
+ Code from https://github.com/josecoelho/yepKeyNav should be updated after checkout
19
+
20
+ git submodule init
21
+ git submodule update
22
+
23
+ == Publishing a new version
24
+
25
+
26
+
27
+ == TODO
28
+
29
+ Tests on dummy application
@@ -51,7 +51,8 @@ Example:
51
51
  next: "j",
52
52
  prev: "k",
53
53
  toggleSelect: "x"
54
- }
54
+ },
55
+ disableInInput: true //by default, keyboard shortcuts are disabled on input items
55
56
 
56
57
 
57
58
  # Default Shortcuts
@@ -25,17 +25,22 @@
25
25
  next: "j",
26
26
  prev: "k",
27
27
  toggleSelect: "x"
28
- }
28
+ },
29
+ disableInInput: true //by default, keyboard shortcuts are disabled on input items
29
30
  },
30
31
 
31
32
  _create: function () {
32
33
  console.debug("yepKeyNav: init for "+$(this.element).attr('class'))
33
34
  var self = this; //used to maintain class context on events
34
35
 
36
+ var shortcutOptions = {
37
+ disable_in_input: self.options.disableInInput
38
+ }
39
+
35
40
 
36
- shortcut.add(self.options.shortcuts.toggleSelect, $.proxy(self.toggleSelectByEvent,self));
37
- shortcut.add(self.options.shortcuts.next, $.proxy(self.next,self));
38
- shortcut.add(self.options.shortcuts.prev, $.proxy(self.prev,self));
41
+ shortcut.add(self.options.shortcuts.toggleSelect, $.proxy(self.toggleSelectByEvent,self),shortcutOptions);
42
+ shortcut.add(self.options.shortcuts.next, $.proxy(self.next,self),shortcutOptions);
43
+ shortcut.add(self.options.shortcuts.prev, $.proxy(self.prev,self),shortcutOptions);
39
44
 
40
45
  $($(this.element)).on('click',"."+self.options.classes.navigable, $.proxy(self.currentByEvent,self));
41
46
  $($(this.element)).on('click',"."+self.options.classes.itemSelector,$.proxy(self.toggleSelectByEvent,self));
@@ -1,3 +1,3 @@
1
1
  module YepkeynavRails
2
- VERSION = "0.0.1"
2
+ VERSION = "0.0.2"
3
3
  end
@@ -12,4 +12,5 @@
12
12
  //
13
13
  //= require jquery
14
14
  //= require jquery_ujs
15
+ //= require yepKeyNav
15
16
  //= require_tree .
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: yepkeynav-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - José Coelho
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-06-26 00:00:00.000000000 Z
11
+ date: 2013-07-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails