uber_select_rails 0.4.0 → 0.4.1
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8c03ef32585a000f449ad3851d5a90da08a0ec646c3bae0fddb335c67522062d
|
4
|
+
data.tar.gz: 36c973de206ac86363ceed385a516b2f0cc3ba396e3723501d23e984b666910c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7701b85c337519d3694ddde32fe59bf779ca762bbd874b6cb34363d9ab8194bae46e922c866928eced917179eadfc524485337609e6be19d2d9e40e1af7ff464
|
7
|
+
data.tar.gz: 6edaa218f7e0e43bcf72959fd24bd0577c890704e156b61e6618cca6ed4b4121b5b272490d1ce147e4a12bd540c80b77efce8d6f1e8546950bb965cdd1c5d7f5
|
@@ -21,6 +21,10 @@ you can use UberSelect to gussy up forms, without changing any of the underlying
|
|
21
21
|
$('.my_selects').uberSelect(options);
|
22
22
|
```
|
23
23
|
|
24
|
+
#### Attributes <a name="UberSearch attributes"></a>
|
25
|
+
Attribtes on the outermost element can be specified by setting the `data-uber-attributes` attribute on the `<select>` element. Values should be passed
|
26
|
+
as a JSON string of key/value pairs where the key is the attribute name and the value is the attribute value.
|
27
|
+
|
24
28
|
#### Options
|
25
29
|
Options can be specified by setting the `data-uber-options` attribute on the `<select>` element. Values should be passed
|
26
30
|
as a JSON string. All options on the are passed to the underlying UberSearch, see [UberSearch options](#UberSearchOptions).
|
@@ -20,7 +20,7 @@
|
|
20
20
|
optionFromDatum: optionFromDatum, // A function to create select options
|
21
21
|
value: $(select).val() // Initialize the UberSearch with this selected value
|
22
22
|
}, opts, $(select).data('uber-options'))
|
23
|
-
|
23
|
+
var uberAttributes = $(select).data('uber-attributes'); // Attributes defined as data-uber-attributes on the original select element. These will be added as attributes on the uberSelect element.
|
24
24
|
var uberSearch = this.uberSearch = new UberSearch(dataFromSelect(select), options)
|
25
25
|
|
26
26
|
|
@@ -53,6 +53,10 @@
|
|
53
53
|
|
54
54
|
// INITIALIZATION
|
55
55
|
|
56
|
+
if (uberAttributes) {
|
57
|
+
uberSearch.view.attr(uberAttributes)
|
58
|
+
}
|
59
|
+
|
56
60
|
uberSearch.view.insertBefore(select).append(select)
|
57
61
|
hideSelect()
|
58
62
|
if (options.dataUrl) {
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: uber_select_rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nicholas Jakobsen
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-09-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -52,7 +52,7 @@ dependencies:
|
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '10.0'
|
55
|
-
description:
|
55
|
+
description:
|
56
56
|
email:
|
57
57
|
- nicholas.jakobsen@gmail.com
|
58
58
|
executables: []
|
@@ -84,7 +84,7 @@ files:
|
|
84
84
|
homepage: https://github.com/culturecode/uber_select_rails
|
85
85
|
licenses: []
|
86
86
|
metadata: {}
|
87
|
-
post_install_message:
|
87
|
+
post_install_message:
|
88
88
|
rdoc_options: []
|
89
89
|
require_paths:
|
90
90
|
- lib
|
@@ -99,8 +99,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
99
99
|
- !ruby/object:Gem::Version
|
100
100
|
version: '0'
|
101
101
|
requirements: []
|
102
|
-
rubygems_version: 3.0.
|
103
|
-
signing_key:
|
102
|
+
rubygems_version: 3.0.8
|
103
|
+
signing_key:
|
104
104
|
specification_version: 4
|
105
105
|
summary: A Rails gem containing a javascript plugin that adds a layer of UI goodness
|
106
106
|
overtop of basic HTML select elements
|