backgridjs-rails 0.2.6 → 0.3.5

Sign up to get free protection for your applications and to get access to all the features.
@@ -6,14 +6,188 @@
6
6
  Licensed under the MIT @license.
7
7
  */
8
8
 
9
- .backgrid-filter .close {
10
- display: inline-block;
11
- float: none;
12
- width: 20px;
9
+ /*
10
+ Search Icon CSS derived from:
11
+
12
+ PURE CSS GUI ICONS
13
+ by Nicolas Gallagher
14
+ - http://nicolasgallagher.com/pure-css-gui-icons/
15
+
16
+ http://nicolasgallagher.com
17
+ http://twitter.com/necolas
18
+
19
+ Created: 29 July 2010
20
+ Version: 1.0.1
21
+
22
+ Dual licensed under MIT and GNU GPLv2 (c) Nicolas Gallagher
23
+ */
24
+
25
+ .backgrid-filter.form-search {
26
+ position: relative;
27
+ width: 248px;
28
+ height: 30px;
29
+ margin: 20px;
30
+ }
31
+
32
+ /*
33
+ Search Icon
34
+ */
35
+
36
+ .backgrid-filter .search {
37
+ position: absolute;
38
+ top: 50%;
39
+ left: 6px;
40
+ z-index: 1000;
41
+ width: 10px;
13
42
  height: 20px;
14
- margin-top: -4px;
43
+ margin-top: -10px;
44
+ -webkit-box-sizing: content-box;
45
+ -moz-box-sizing: content-box;
46
+ box-sizing: content-box;
47
+ }
48
+
49
+ .backgrid-filter .search:before {
50
+ position: absolute;
51
+ top: 50%;
52
+ left: 0;
53
+ width: 6px;
54
+ height: 6px;
55
+ margin-top: -6px;
56
+ background: transparent;
57
+ border: 3px solid gray;
58
+ -webkit-border-radius: 12px;
59
+ -moz-border-radius: 12px;
60
+ border-radius: 12px;
61
+ content: "";
62
+ -webkit-box-sizing: content-box;
63
+ -moz-box-sizing: content-box;
64
+ box-sizing: content-box;
65
+ }
66
+
67
+ .backgrid-filter .search:after {
68
+ position: absolute;
69
+ top: 50%;
70
+ left: 10px;
71
+ width: 3px;
72
+ height: 7px;
73
+ margin-top: 2px;
74
+ background-color: gray;
75
+ content: "";
76
+ -webkit-transform: rotate(-45deg);
77
+ -moz-transform: rotate(-45deg);
78
+ -ms-transform: rotate(-45deg);
79
+ -o-transform: rotate(-45deg);
80
+ transform: rotate(-45deg);
81
+ -webkit-box-sizing: content-box;
82
+ -moz-box-sizing: content-box;
83
+ box-sizing: content-box;
84
+ }
85
+
86
+ /*
87
+ Clear button
88
+ */
89
+
90
+ .backgrid-filter .clear {
91
+ position: absolute;
92
+ top: 50%;
93
+ right: 8px;
94
+ z-index: 1000;
95
+ width: 10px;
96
+ height: 20px;
97
+ margin-top: -10px;
98
+ font-family: sans-serif;
15
99
  font-size: 20px;
100
+ font-weight: bold;
16
101
  line-height: 20px;
17
- text-align: center;
18
- vertical-align: text-top;
102
+ color: gray;
103
+ text-decoration: none;
104
+ }
105
+
106
+ .backgrid-filter input[type="search"] {
107
+ position: absolute;
108
+ display: inline-block;
109
+ width: 206px;
110
+ height: 20px;
111
+ padding: 4px 6px;
112
+ font-weight: normal;
113
+ color: #555;
114
+ vertical-align: middle;
115
+ background-color: #fff;
116
+ border: 1px solid #ccc;
117
+ -webkit-border-radius: 4px;
118
+ -moz-border-radius: 4px;
119
+ border-radius: 4px;
120
+ -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
121
+ -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
122
+ box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
123
+ -webkit-transition: border linear 0.2s, box-shadow linear 0.2s;
124
+ -moz-transition: border linear 0.2s, box-shadow linear 0.2s;
125
+ -o-transition: border linear 0.2s, box-shadow linear 0.2s;
126
+ transition: border linear 0.2s, box-shadow linear 0.2s;
19
127
  }
128
+
129
+ /*
130
+ Normalize the search input box, with code borrowed from normalize.css.
131
+
132
+ https://github.com/necolas/normalize.css/
133
+
134
+ Copyright (c) Nicolas Gallagher and Jonathan Neal, MIT @license.
135
+ */
136
+
137
+ /*
138
+ * 1. Correct font family not being inherited in all browsers.
139
+ * 2. Correct font size not being inherited in all browsers.
140
+ * 3. Address margins set differently in Firefox 4+, Safari 5, and Chrome.
141
+ * 4. Address Firefox 4+ setting `line-height` on `input` using `!important` in the UA stylesheet.
142
+ */
143
+
144
+ .backgrid-filter input {
145
+ margin: 0;
146
+ font-family: inherit;
147
+ font-size: 100%;
148
+ line-height: normal;
149
+ }
150
+
151
+ /*
152
+ * Re-set default cursor for disabled elements.
153
+ */
154
+
155
+ .backgrid-filter input[disabled] {
156
+ cursor: default;
157
+ }
158
+
159
+ /*
160
+ * 1. Address `appearance` set to `searchfield` in Safari 5 and Chrome.
161
+ * 2. Address `box-sizing` set to `border-box` in Safari 5 and Chrome
162
+ * (include `-moz` to future-proof).
163
+ */
164
+
165
+ .backgrid-filter input[type="search"] {
166
+ outline: none;
167
+ -webkit-box-sizing: content-box;
168
+ -moz-box-sizing: content-box;
169
+ box-sizing: content-box;
170
+ -webkit-appearance: none;
171
+ }
172
+
173
+ /*
174
+ * Remove the default clear button on IE
175
+ */
176
+
177
+ .backgrid-filter input[type="search"]::-ms-clear {
178
+ display: none;
179
+ }
180
+
181
+ /*
182
+ * Remove inner padding and border in Firefox 4+.
183
+ */
184
+
185
+ .backgrid-filter input::-moz-focus-inner {
186
+ padding: 0;
187
+ border: 0;
188
+ }
189
+
190
+ .backgrid-filter input[type="search"] {
191
+ padding-right: 18px;
192
+ padding-left: 22px;
193
+ }
@@ -5,10 +5,11 @@
5
5
  Copyright (c) 2013 Jimmy Yuen Ho Wong and contributors
6
6
  Licensed under the MIT @license.
7
7
  */
8
+
8
9
  .backgrid .moment-cell {
9
10
  text-align: right;
10
11
  }
11
12
 
12
13
  .backgrid .moment-cell.editor input[type=text] {
13
14
  text-align: right;
14
- }
15
+ }
@@ -3,18 +3,18 @@
3
3
  http://github.com/wyuenho/backgrid
4
4
 
5
5
  Copyright (c) 2013 Jimmy Yuen Ho Wong and contributors
6
- Licensed under the MIT @license.
6
+ Licensed under the MIT license.
7
7
  */
8
8
 
9
9
  .backgrid-paginator {
10
10
  text-align: center;
11
- -webkit-box-sizing: border-box;
12
- -moz-box-sizing: border-box;
13
- box-sizing: border-box;
14
11
  border-top: none;
15
12
  -webkit-border-radius: 0 0 4px 4px;
16
13
  -moz-border-radius: 0 0 4px 4px;
17
14
  border-radius: 0 0 4px 4px;
15
+ -webkit-box-sizing: border-box;
16
+ -moz-box-sizing: border-box;
17
+ box-sizing: border-box;
18
18
  }
19
19
 
20
20
  .backgrid-paginator ul {
@@ -55,4 +55,4 @@
55
55
  .backgrid-paginator ul > .disabled > a:hover {
56
56
  color: #999999;
57
57
  cursor: default;
58
- }
58
+ }
@@ -5,7 +5,8 @@
5
5
  Copyright (c) 2013 Jimmy Yuen Ho Wong and contributors
6
6
  Licensed under the MIT @license.
7
7
  */
8
+
8
9
  .backgrid .select-row-cell,
9
10
  .backgrid .select-all-header-cell {
10
11
  text-align: center;
11
- }
12
+ }
@@ -16,4 +16,4 @@
16
16
 
17
17
  .backgrid .select2-cell.editor .select2-container {
18
18
  width: 100%;
19
- }
19
+ }
@@ -3,7 +3,7 @@
3
3
  http://github.com/wyuenho/backgrid
4
4
 
5
5
  Copyright (c) 2013 Jimmy Yuen Ho Wong and contributors
6
- Licensed under the MIT @license.
6
+ Licensed under the MIT license.
7
7
  */
8
8
 
9
9
  .backgrid .text-cell {
@@ -16,8 +16,8 @@
16
16
  }
17
17
 
18
18
  .backgrid .text-cell.editor {
19
- max-width: 100%;
20
19
  height: 28px;
20
+ max-width: 100%;
21
21
  }
22
22
 
23
23
  .backgrid .text-cell.editor * {
@@ -28,4 +28,4 @@
28
28
 
29
29
  .backgrid .text-cell.editor textarea {
30
30
  width: 100%;
31
- }
31
+ }
@@ -3,7 +3,7 @@
3
3
  http://github.com/wyuenho/backgrid
4
4
 
5
5
  Copyright (c) 2013 Jimmy Yuen Ho Wong and contributors
6
- Licensed under the MIT @license.
6
+ Licensed under the MIT license.
7
7
  */
8
8
 
9
9
  .backgrid-container {
@@ -20,7 +20,6 @@
20
20
  width: 100%;
21
21
  max-width: 100%;
22
22
  background-color: transparent;
23
- border: 1px solid #DDD;
24
23
  border-collapse: collapse;
25
24
  -webkit-border-radius: 4px;
26
25
  -moz-border-radius: 4px;
@@ -29,6 +28,7 @@
29
28
 
30
29
  .backgrid th,
31
30
  .backgrid td {
31
+ display: none;
32
32
  height: 20px;
33
33
  max-width: 250px;
34
34
  padding: 4px 5px;
@@ -38,16 +38,23 @@
38
38
  text-overflow: ellipsis;
39
39
  white-space: nowrap;
40
40
  vertical-align: middle;
41
- border: 1px solid #DDD;
41
+ border-bottom: 1px solid #DDD;
42
+ }
43
+
44
+ .backgrid th.renderable,
45
+ .backgrid td.renderable {
46
+ display: table-cell;
42
47
  }
43
48
 
44
49
  .backgrid th {
45
50
  font-weight: bold;
46
- cursor: pointer;
51
+ text-align: center;
47
52
  }
48
53
 
49
- .backgrid th a {
54
+ .backgrid th.sortable a {
55
+ text-decoration: none;
50
56
  white-space: nowrap;
57
+ cursor: pointer;
51
58
  }
52
59
 
53
60
  .backgrid thead th {
@@ -55,8 +62,11 @@
55
62
  background-color: #f9f9f9;
56
63
  }
57
64
 
58
- .backgrid.backgrid-striped tbody tr:nth-child(odd) td,
59
- .backgrid.backgrid-striped tbody tr:nth-child(odd) th {
65
+ .backgrid thead th a {
66
+ display: block;
67
+ }
68
+
69
+ .backgrid.backgrid-striped tbody tr:nth-child(even) {
60
70
  background-color: #f9f9f9;
61
71
  }
62
72
 
@@ -66,9 +76,14 @@
66
76
  }
67
77
 
68
78
  .backgrid tbody tr.empty td {
79
+ display: table-cell;
69
80
  text-align: center;
70
81
  }
71
82
 
83
+ .backgrid td.editor {
84
+ padding: 0;
85
+ }
86
+
72
87
  .backgrid td.editor,
73
88
  .backgrid tbody tr:nth-child(odd) td.editor {
74
89
  background-color: rgba(82, 168, 236, 0.1);
@@ -95,7 +110,7 @@
95
110
  display: block;
96
111
  width: 100%;
97
112
  height: 100%;
98
- padding: 0;
113
+ padding: 0 5px;
99
114
  margin: 0;
100
115
  background-color: transparent;
101
116
  border: 0;
@@ -110,6 +125,10 @@
110
125
  -moz-appearance: none;
111
126
  }
112
127
 
128
+ .backgrid td.editor input[type=text]::-ms-clear {
129
+ display: none;
130
+ }
131
+
113
132
  .backgrid td.error,
114
133
  .backgrid tbody tr:nth-child(odd) td.error {
115
134
  background-color: rgba(255, 210, 77, 0.1);
@@ -160,11 +179,13 @@
160
179
  .backgrid .datetime-cell,
161
180
  .backgrid .number-cell,
162
181
  .backgrid .integer-cell,
182
+ .backgrid .percent-cell,
163
183
  .backgrid .date-cell.editor input[type=text],
164
184
  .backgrid .time-cell.editor input[type=text],
165
185
  .backgrid .datetime-cell.editor input[type=text],
166
186
  .backgrid .number-cell.editor input[type=text],
167
- .backgrid .integer-cell.editor input[type=text] {
187
+ .backgrid .integer-cell.editor input[type=text],
188
+ .backgrid .percent-cell.editor input[type=text] {
168
189
  text-align: right;
169
190
  }
170
191
 
@@ -200,6 +221,10 @@
200
221
  box-sizing: border-box;
201
222
  }
202
223
 
224
+ .backgrid .select-cell.editor select[multiple] {
225
+ height: auto;
226
+ }
227
+
203
228
  .backgrid .select-cell.editor :focus {
204
229
  border: 0;
205
230
  outline: 0;
@@ -212,4 +237,4 @@
212
237
  .backgrid .select-cell.editor optgroup::-o-focus-inner,
213
238
  .backgrid .select-cell.editor option::-o-focus-inner {
214
239
  border: 0;
215
- }
240
+ }
metadata CHANGED
@@ -1,29 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: backgridjs-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.6
4
+ version: 0.3.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Beau Trepp
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-07-10 00:00:00.000000000 Z
11
+ date: 2014-06-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ~>
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: 3.2.13
19
+ version: 3.2.11
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - ~>
24
+ - - ">="
25
25
  - !ruby/object:Gem::Version
26
- version: 3.2.13
26
+ version: 3.2.11
27
27
  description: Vendors backgridjs into asset pipeline
28
28
  email:
29
29
  - beautrepp@gmail.com
@@ -31,6 +31,13 @@ executables: []
31
31
  extensions: []
32
32
  extra_rdoc_files: []
33
33
  files:
34
+ - MIT-LICENSE
35
+ - README.rdoc
36
+ - Rakefile
37
+ - lib/backgridjs-rails.rb
38
+ - lib/backgridjs-rails/engine.rb
39
+ - lib/backgridjs-rails/version.rb
40
+ - lib/tasks/backgridjs-rails_tasks.rake
34
41
  - vendor/assets/javascripts/backgrid-extensions/backgrid-filter.js
35
42
  - vendor/assets/javascripts/backgrid-extensions/backgrid-moment-cell.js
36
43
  - vendor/assets/javascripts/backgrid-extensions/backgrid-paginator.js
@@ -45,18 +52,9 @@ files:
45
52
  - vendor/assets/stylesheets/backgrid-extensions/backgrid-select2-cell.css
46
53
  - vendor/assets/stylesheets/backgrid-extensions/backgrid-text-cell.css
47
54
  - vendor/assets/stylesheets/backgrid.css
48
- - lib/backgridjs-rails/engine.rb
49
- - lib/backgridjs-rails/engine.rb~
50
- - lib/backgridjs-rails/version.rb
51
- - lib/backgridjs-rails/version.rb~
52
- - lib/backgridjs-rails.rb
53
- - lib/backgridjs-rails.rb~
54
- - lib/tasks/backgridjs-rails_tasks.rake
55
- - MIT-LICENSE
56
- - Rakefile
57
- - README.rdoc
58
55
  homepage: https://github.com/btrepp/backgridjs-rails
59
- licenses: []
56
+ licenses:
57
+ - MIT
60
58
  metadata: {}
61
59
  post_install_message:
62
60
  rdoc_options: []
@@ -64,19 +62,18 @@ require_paths:
64
62
  - lib
65
63
  required_ruby_version: !ruby/object:Gem::Requirement
66
64
  requirements:
67
- - - ! '>='
65
+ - - ">="
68
66
  - !ruby/object:Gem::Version
69
67
  version: '0'
70
68
  required_rubygems_version: !ruby/object:Gem::Requirement
71
69
  requirements:
72
- - - ! '>='
70
+ - - ">="
73
71
  - !ruby/object:Gem::Version
74
72
  version: '0'
75
73
  requirements: []
76
74
  rubyforge_project:
77
- rubygems_version: 2.0.3
75
+ rubygems_version: 2.2.2
78
76
  signing_key:
79
77
  specification_version: 4
80
78
  summary: Vendors backgridjs into asset pipeline
81
79
  test_files: []
82
- has_rdoc: