hooch 0.15.24 → 0.15.25
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/javascripts/hooch.js +10 -0
- data/lib/hooch/hooch_helper.rb +12 -0
- data/lib/hooch/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d39e0f396af90cdca1b611435c7c525aec7c08c0
|
4
|
+
data.tar.gz: 307cad30ed8a53f872856456bb3558e679ee100b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 22d2a400b45c3bd4e4e99705517e7b65d50634914620fad0ef2ff7f676998e6437476f929433ae761c7aa53d89af73246990f762211bd4d21a085c619f630e0e
|
7
|
+
data.tar.gz: 253f6c2988188b354be26a9715c35041addb9bea3c9fbb583eda5c915807db3fb6b03e1c3b386c7c58a22fb25150d38025d94b2fd0231a722821745219b16033
|
@@ -945,6 +945,7 @@ var initHooch = function(){
|
|
945
945
|
this.$fake_checkbox = $fake_checkbox
|
946
946
|
this.$form = this.getForm()
|
947
947
|
this.prepDeselectors()
|
948
|
+
this.prepSelectors()
|
948
949
|
this.$field = this.getField()
|
949
950
|
var fake_checkbox = this
|
950
951
|
this.$fake_checkbox.click(function(){ fake_checkbox.change() })
|
@@ -1008,6 +1009,15 @@ var initHooch = function(){
|
|
1008
1009
|
}
|
1009
1010
|
})
|
1010
1011
|
},
|
1012
|
+
prepSelectors: function(){
|
1013
|
+
var $selector = $('body').find('[data-fake-selector]')
|
1014
|
+
var fake_checkbox = this
|
1015
|
+
$selector.on('click', function(){
|
1016
|
+
if(!(fake_checkbox.$fake_checkbox.hasClass('checked'))){
|
1017
|
+
fake_checkbox.select()
|
1018
|
+
}
|
1019
|
+
})
|
1020
|
+
},
|
1011
1021
|
addValue: function(){
|
1012
1022
|
this.$form.append(this.$field)
|
1013
1023
|
this.possiblyShowForm()
|
data/lib/hooch/hooch_helper.rb
CHANGED
@@ -195,6 +195,18 @@ module Hooch
|
|
195
195
|
end
|
196
196
|
end
|
197
197
|
|
198
|
+
def fake_select
|
199
|
+
{}.tap do |params|
|
200
|
+
params['data-fake-selector'] = true
|
201
|
+
end
|
202
|
+
end
|
203
|
+
|
204
|
+
def fake_select_attrs
|
205
|
+
''.tap do |attrs|
|
206
|
+
attrs.concat 'data-fake-selector=true'
|
207
|
+
end
|
208
|
+
end
|
209
|
+
|
198
210
|
def field_filler(target, value)
|
199
211
|
''.tap do |attrs|
|
200
212
|
attrs.concat 'data-field-filler=true'
|
data/lib/hooch/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: hooch
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.15.
|
4
|
+
version: 0.15.25
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Eric Draut
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-06-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -170,7 +170,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
170
170
|
version: '0'
|
171
171
|
requirements: []
|
172
172
|
rubyforge_project:
|
173
|
-
rubygems_version: 2.6.
|
173
|
+
rubygems_version: 2.6.13
|
174
174
|
signing_key:
|
175
175
|
specification_version: 4
|
176
176
|
summary: Tools for building a browser UI. Get the good stuff.
|