uniform-ui 1.0 → 2.2.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (139) hide show
  1. checksums.yaml +5 -5
  2. data/lib/assets/config/manifest.js +1 -0
  3. data/lib/assets/javascripts/uniform/checkbox.js +31 -0
  4. data/lib/assets/javascripts/uniform/component.js +42 -0
  5. data/lib/assets/javascripts/uniform/dom-helpers.js +136 -0
  6. data/lib/assets/javascripts/uniform/dropdown.js +149 -0
  7. data/lib/assets/javascripts/uniform/floating-label.js +54 -0
  8. data/lib/assets/javascripts/uniform/icons.js +16 -0
  9. data/lib/assets/javascripts/uniform/modal.js +103 -0
  10. data/lib/assets/javascripts/uniform/resizer.js +43 -0
  11. data/lib/assets/javascripts/uniform/select.js +235 -0
  12. data/lib/assets/javascripts/uniform/tooltip.js +120 -0
  13. data/lib/assets/javascripts/uniform-es5.js +1 -0
  14. data/lib/assets/javascripts/uniform-jquery.js +124 -0
  15. data/lib/assets/javascripts/uniform.js +17 -0
  16. data/lib/assets/stylesheets/uniform/base.scss +3 -0
  17. data/lib/assets/stylesheets/uniform/components/alert.scss +72 -0
  18. data/lib/assets/stylesheets/uniform/components/buttons.scss +219 -0
  19. data/{vendor → lib}/assets/stylesheets/uniform/components/card.scss +33 -25
  20. data/lib/assets/stylesheets/uniform/components/container.scss +19 -0
  21. data/{vendor → lib}/assets/stylesheets/uniform/components/dropdown.scss +8 -4
  22. data/lib/assets/stylesheets/uniform/components/form/checkbox-collection.scss +103 -0
  23. data/lib/assets/stylesheets/uniform/components/form/checkbox.scss +58 -0
  24. data/lib/assets/stylesheets/uniform/components/form/floating-label.scss +64 -0
  25. data/lib/assets/stylesheets/uniform/components/form/input-group.scss +56 -0
  26. data/lib/assets/stylesheets/uniform/components/form.scss +143 -0
  27. data/lib/assets/stylesheets/uniform/components/grid.scss +158 -0
  28. data/lib/assets/stylesheets/uniform/components/label.scss +26 -0
  29. data/lib/assets/stylesheets/uniform/components/loaders.scss +80 -0
  30. data/{vendor → lib}/assets/stylesheets/uniform/components/modal.scss +26 -4
  31. data/lib/assets/stylesheets/uniform/components/nav.scss +124 -0
  32. data/lib/assets/stylesheets/uniform/components/row.scss +69 -0
  33. data/lib/assets/stylesheets/uniform/components/select.scss +122 -0
  34. data/lib/assets/stylesheets/uniform/components/table.scss +127 -0
  35. data/lib/assets/stylesheets/uniform/components/thumb.scss +41 -0
  36. data/lib/assets/stylesheets/uniform/components/tooltip.scss +63 -0
  37. data/lib/assets/stylesheets/uniform/components.scss +11 -0
  38. data/{vendor → lib}/assets/stylesheets/uniform/defaults.scss +7 -4
  39. data/lib/assets/stylesheets/uniform/functions.scss +31 -0
  40. data/lib/assets/stylesheets/uniform/helpers/border.scss +19 -0
  41. data/lib/assets/stylesheets/uniform/helpers/colors.scss +23 -0
  42. data/lib/assets/stylesheets/uniform/helpers/margin.scss +27 -0
  43. data/lib/assets/stylesheets/uniform/helpers/padding.scss +9 -0
  44. data/lib/assets/stylesheets/uniform/helpers/position.scss +13 -0
  45. data/lib/assets/stylesheets/uniform/helpers/sizes.scss +38 -0
  46. data/{vendor → lib}/assets/stylesheets/uniform/helpers/text.scss +86 -73
  47. data/lib/assets/stylesheets/uniform/helpers.scss +127 -0
  48. data/lib/assets/stylesheets/uniform/mixins.scss +116 -0
  49. data/lib/assets/stylesheets/uniform/print/grid.scss +50 -0
  50. data/lib/assets/stylesheets/uniform/variables.scss +72 -0
  51. data/lib/assets/stylesheets/uniform-print.scss +1 -0
  52. data/lib/assets/stylesheets/uniform.scss +11 -0
  53. data/lib/uniform/version.rb +3 -0
  54. data/lib/uniform.rb +15 -0
  55. metadata +87 -95
  56. data/.gitignore +0 -2
  57. data/CHANGELOG.md +0 -27
  58. data/CNAME +0 -1
  59. data/Gemfile +0 -8
  60. data/Gemfile.lock +0 -40
  61. data/LICENSE +0 -22
  62. data/README.md +0 -35
  63. data/Rakefile +0 -74
  64. data/index.html +0 -251
  65. data/lib/uniform/rails/engine.rb +0 -8
  66. data/lib/uniform/rails.rb +0 -6
  67. data/lib/uniform/ui.rb +0 -1
  68. data/preview/alerts.html.erb +0 -1
  69. data/preview/buttons.html.erb +0 -62
  70. data/preview/cards.html.erb +0 -23
  71. data/preview/colors.html.erb +0 -22
  72. data/preview/dropdown.html.erb +0 -1
  73. data/preview/form.html.erb +0 -233
  74. data/preview/grid.html.erb +0 -304
  75. data/preview/helpers.html.erb +0 -225
  76. data/preview/index.html.erb +0 -77
  77. data/preview/labels.html.erb +0 -1
  78. data/preview/layout.html.erb +0 -63
  79. data/preview/loaders.html.erb +0 -83
  80. data/preview/modal.html.erb +0 -1
  81. data/preview/nav.html.erb +0 -77
  82. data/preview/preview.scss +0 -76
  83. data/preview/rows.html.erb +0 -36
  84. data/preview/select.html.erb +0 -1
  85. data/preview/tables.html.erb +0 -1
  86. data/preview/tabs.html.erb +0 -17
  87. data/preview/tiles.html.erb +0 -1
  88. data/preview/tooltip.erb +0 -1
  89. data/preview.css +0 -0
  90. data/site/alerts.html +0 -157
  91. data/site/alerts.html copy +0 -133
  92. data/site/buttons.html +0 -286
  93. data/site/cards.html +0 -177
  94. data/site/colors.html +0 -275
  95. data/site/dropdown.html +0 -157
  96. data/site/dropdown.html copy +0 -141
  97. data/site/form.html +0 -369
  98. data/site/grid.html +0 -716
  99. data/site/helpers.html +0 -1008
  100. data/site/index.html +0 -251
  101. data/site/labels.html +0 -157
  102. data/site/layout.html +0 -313
  103. data/site/loaders.html +0 -233
  104. data/site/logo.png +0 -0
  105. data/site/modal.html +0 -157
  106. data/site/nav.html +0 -229
  107. data/site/preview.css +0 -1
  108. data/site/preview.js +0 -59
  109. data/site/rows.html +0 -190
  110. data/site/select.html +0 -157
  111. data/site/tables.html +0 -157
  112. data/site/tabs.html +0 -171
  113. data/site/tiles.html +0 -157
  114. data/site/tiles.html copy +0 -109
  115. data/site/tooltip +0 -157
  116. data/site/uniform.css +0 -1
  117. data/uniform.gemspec +0 -22
  118. data/vendor/assets/stylesheets/uniform/base.scss +0 -2
  119. data/vendor/assets/stylesheets/uniform/components/alert.scss +0 -27
  120. data/vendor/assets/stylesheets/uniform/components/buttons.scss +0 -212
  121. data/vendor/assets/stylesheets/uniform/components/form.scss +0 -290
  122. data/vendor/assets/stylesheets/uniform/components/grid.scss +0 -225
  123. data/vendor/assets/stylesheets/uniform/components/label.scss +0 -63
  124. data/vendor/assets/stylesheets/uniform/components/loaders.scss +0 -82
  125. data/vendor/assets/stylesheets/uniform/components/nav.scss +0 -197
  126. data/vendor/assets/stylesheets/uniform/components/row.scss +0 -92
  127. data/vendor/assets/stylesheets/uniform/components/select.scss +0 -98
  128. data/vendor/assets/stylesheets/uniform/components/table.scss +0 -83
  129. data/vendor/assets/stylesheets/uniform/components/tabs.scss +0 -45
  130. data/vendor/assets/stylesheets/uniform/components/tile.scss +0 -20
  131. data/vendor/assets/stylesheets/uniform/components/tooltip.scss +0 -46
  132. data/vendor/assets/stylesheets/uniform/helpers/colors.scss +0 -37
  133. data/vendor/assets/stylesheets/uniform/helpers/margin.scss +0 -44
  134. data/vendor/assets/stylesheets/uniform/helpers/padding.scss +0 -74
  135. data/vendor/assets/stylesheets/uniform/helpers/sizes.scss +0 -31
  136. data/vendor/assets/stylesheets/uniform/helpers.scss +0 -124
  137. data/vendor/assets/stylesheets/uniform/mixins.scss +0 -77
  138. data/vendor/assets/stylesheets/uniform/variables.scss +0 -36
  139. data/vendor/assets/stylesheets/uniform.scss +0 -9
@@ -1,304 +0,0 @@
1
- <div class="section">
2
- <h1>Grid</h1>
3
- <p>Similar to Bootstrap 4 with some modifications. Uses flexbox with a host of helper options.</p>
4
- <h3>Breakpoints</h3>
5
- <p>
6
- Any helper can have <code>-sm</code>, <code>-md</code>, <code>-lg</code>,
7
- or <code>-xl</code> added to cause helper to only go into effect for that
8
- breakpoint.
9
- </p>
10
- <p><code>xs</code> = 480px</p>
11
- <p><code>sm</code> = 768px</p>
12
- <p><code>md</code> = 992px</p>
13
- <p><code>lg</code> = 1200px</p>
14
- <% html_block do %>
15
- <div class="grid">
16
- <div class="col">content</div>
17
- <div class="col">content</div>
18
- <div class="col">content</div>
19
- </div>
20
- <% end %>
21
- <h3>Grid Options</h3>
22
- <% [
23
- 'grid-center',
24
- 'grid-top',
25
- 'grid-bottom',
26
- 'grid-stretch',
27
- 'grid-h-left',
28
- 'grid-h-center',
29
- 'grid-h-right',
30
- 'grid-h-around',
31
- 'grid-h-between'
32
- ].each do |klass| %>
33
- <div class="margin-bottom bg-gray-light pad-bottom">
34
- .grid .<%= klass %>
35
- <div class="grid <%= klass %>">
36
- <div class="col bg-green-light">
37
- <div class="bg-red-light">col</div>
38
- </div>
39
- <div class="col bg-green-light">
40
- <div class="bg-red-light height-100-px">col height-100-px</div>
41
- </div>
42
- <div class="col bg-green-light">
43
- <div class="bg-red-light">col</div>
44
- </div>
45
- </div>
46
- </div>
47
- <% end %>
48
-
49
- <% [
50
- 'grid-v-top',
51
- 'grid-v-center',
52
- 'grid-v-bottom',
53
- 'grid-v-around',
54
- 'grid-v-between',
55
- 'grid-v-stretch'
56
- ].each do |klass| %>
57
- <div class="margin-bottom bg-gray-light pad-bottom">
58
- .grid .<%= klass %> .height-300-px
59
- <div class="grid <%= klass %> height-300-px">
60
- <div class="col-4 bg-green-light border">
61
- <div class="bg-red-light">col-4</div>
62
- </div>
63
- <div class="col-4 bg-green-light border">
64
- <div class="bg-red-light height-100-px">col-4 height-100-px</div>
65
- </div>
66
- <div class="col-4 bg-green-light border">
67
- <div class="bg-red-light">col-4</div>
68
- </div>
69
-
70
- <div class="col-4 bg-green-light border">
71
- <div class="bg-red-light">col-4</div>
72
- </div>
73
-
74
- <div class="col-4 bg-green-light border">
75
- <div class="bg-red-light">col-4</div>
76
- </div>
77
-
78
- <div class="col-4 bg-green-light border">
79
- <div class="bg-red-light">col-4</div>
80
- </div>
81
-
82
- <div class="col-4 bg-green-light border">
83
- <div class="bg-red-light">col-4</div>
84
- </div>
85
- </div>
86
- </div>
87
- <% end %>
88
-
89
-
90
- <div class="margin-bottom bg-gray-light pad-bottom">
91
- .grid .no-wrap .height-300-px
92
- <div class="grid no-wrap height-300-px">
93
- <div class="col-4 bg-green-light border">
94
- <div class="bg-red-light">col-4</div>
95
- </div>
96
- <div class="col-4 bg-green-light border">
97
- <div class="bg-red-light height-100-px">col-4 height-100-px</div>
98
- </div>
99
- <div class="col-4 bg-green-light border">
100
- <div class="bg-red-light">col-4</div>
101
- </div>
102
-
103
- <div class="col-4 bg-green-light border">
104
- <div class="bg-red-light">col-4</div>
105
- </div>
106
-
107
- <div class="col-4 bg-green-light border">
108
- <div class="bg-red-light">col-4</div>
109
- </div>
110
-
111
- <div class="col-4 bg-green-light border">
112
- <div class="bg-red-light">col-4</div>
113
- </div>
114
-
115
- <div class="col-4 bg-green-light border">
116
- <div class="bg-red-light">col-4</div>
117
- </div>
118
- </div>
119
- </div>
120
-
121
- <div class="margin-bottom bg-gray-light pad-bottom">
122
- .grid .grid-vertical
123
- <div class="grid grid-vertical">
124
- <div class="col bg-green-light">
125
- <div class="bg-red-light">col</div>
126
- </div>
127
- <div class="col bg-green-light">
128
- <div class="bg-red-light height-100-px">col height-100-px</div>
129
- </div>
130
- <div class="col bg-green-light">
131
- <div class="bg-red-light">col</div>
132
- </div>
133
- </div>
134
- </div>
135
-
136
- <div class="margin-bottom bg-gray-light pad-bottom">
137
- .grid .no-gutter
138
- <div class="grid no-gutter">
139
- <div class="col bg-green-light">
140
- <div class="bg-red-light">col</div>
141
- </div>
142
- <div class="col bg-green-light">
143
- <div class="bg-red-light height-100-px">col height-100-px</div>
144
- </div>
145
- <div class="col bg-green-light">
146
- <div class="bg-red-light">col</div>
147
- </div>
148
- </div>
149
- </div>
150
- <div class="margin-bottom bg-gray-light pad-bottom">
151
- .grid .nest
152
- <div class="grid nest">
153
- <div class="col bg-green-light">
154
- <div class="bg-red-light">col</div>
155
- </div>
156
- <div class="col bg-green-light">
157
- <div class="bg-red-light height-100-px">col height-100-px</div>
158
- </div>
159
- <div class="col bg-green-light">
160
- <div class="bg-red-light">col</div>
161
- </div>
162
- </div>
163
- </div>
164
-
165
-
166
-
167
-
168
-
169
- <h3>Col Options</h3>
170
- <div class="margin-bottom bg-gray-light pad-bottom">
171
- .grid
172
- <div class="grid">
173
- <div class="col">
174
- <div class="bg-green-light">col</div>
175
- </div>
176
- <div class="col">
177
- <div class="bg-green-light pad-v">
178
- <div class="width-200-px bg-red-light">
179
- col > width-200-px
180
- </div>
181
- </div>
182
- </div>
183
- <div class="col">
184
- <div class="bg-green-light">col</div>
185
- </div>
186
- </div>
187
- </div>
188
-
189
- <div class="margin-bottom bg-gray-light pad-bottom">
190
- .grid
191
- <div class="grid">
192
- <div class="col">
193
- <div class="bg-green-light">col</div>
194
- </div>
195
- <div class="col">
196
- <div class="bg-green-light pad-v">
197
- <div class="width-200-px bg-red-light">
198
- col > width-200-px
199
- </div>
200
- </div>
201
- </div>
202
- <div class="col-fill">
203
- <div class="bg-green-light">col-fill</div>
204
- </div>
205
- </div>
206
- </div>
207
-
208
- <div class="margin-bottom bg-gray-light pad-bottom">
209
- .grid
210
- <div class="grid">
211
- <div class="col-4">
212
- <div class="bg-green-light">col-4</div>
213
- </div>
214
- <div class="col-4">
215
- <div class="bg-green-light">col-4</div>
216
- </div>
217
- <div class="col-4">
218
- <div class="bg-green-light">col-4</div>
219
- </div>
220
- </div>
221
- </div>
222
-
223
- <div class="margin-bottom bg-gray-light pad-bottom">
224
- .grid
225
- <div class="grid">
226
- <div class="col-2">
227
- <div class="bg-green-light">col-2</div>
228
- </div>
229
- <div class="col-6">
230
- <div class="bg-green-light">col-6</div>
231
- </div>
232
- <div class="col-4">
233
- <div class="bg-green-light">col-4</div>
234
- </div>
235
- </div>
236
- </div>
237
-
238
- <div class="margin-bottom bg-gray-light pad-bottom">
239
- .grid
240
- <div class="grid">
241
- <div class="col-3 col-push-2">
242
- <div class="bg-green-light">.col-3 .col-push-2</div>
243
- </div>
244
- </div>
245
- </div>
246
-
247
-
248
- <div class="margin-bottom bg-gray-light pad-bottom">
249
- .grid
250
- <div class="grid">
251
- <div class="col-4">
252
- <div class="bg-green-light">col-4</div>
253
- </div>
254
- <div class="col-4">
255
- <div class="bg-green-light">col-4</div>
256
- </div>
257
- <div class="col-4">
258
- <div class="bg-green-light">col-4</div>
259
- </div>
260
- </div>
261
- </div>
262
-
263
-
264
- <div class="margin-bottom bg-gray-light pad-bottom">
265
- .grid
266
- <div class="grid">
267
- <div class="col col-center">
268
- <div class="bg-green-light">col col-center</div>
269
- </div>
270
- <div class="col">
271
- <div class="bg-green-light pad-v">
272
- <div class="width-200-px bg-red-light">
273
- col > width-200-px
274
- </div>
275
- </div>
276
- </div>
277
- <div class="col col-bottom">
278
- <div class="bg-green-light">col col-bottom</div>
279
- </div>
280
- <div class="col col-stretch bg-green-light">
281
- <div class="">col col-stretch</div>
282
- </div>
283
- </div>
284
- </div>
285
-
286
- <div class="margin-bottom bg-gray-light pad-bottom">
287
- .grid
288
- <div class="grid">
289
- <div class="col">
290
- <div class="bg-green-light">col</div>
291
- </div>
292
- <div class="col no-gutter bg-green-light pad-v">
293
- <div class="width-200-px bg-red-light">
294
- col no-gutter > width-200-px
295
- </div>
296
- </div>
297
- <div class="col">
298
- <div class="bg-green-light">col</div>
299
- </div>
300
- </div>
301
- </div>
302
-
303
-
304
- </div>
@@ -1,225 +0,0 @@
1
- <div class="section">
2
- <h1>Helpers</h1>
3
- <p>These classes are mostly used as modifieres to base elements or compontents</p>
4
-
5
- <h3>Breakpoints</h3>
6
- <p>
7
- Any helper can have <code>-sm</code>, <code>-md</code>, <code>-lg</code>,
8
- or <code>-xl</code> added to cause helper to only go into effect for that
9
- breakpoint.
10
- </p>
11
-
12
- <h3>Padding</h3>
13
- <table class="uniformTable top">
14
- <tr>
15
- <th></th>
16
- <th></th>
17
- </tr>
18
- <% [
19
- ['.pad-tiny', 'padding: 0.25em;'],
20
- ['.pad-less', 'padding: 0.5em;'],
21
- ['.pad', 'padding: 1em;'],
22
- ['.pad-more', 'padding: 2em;'],
23
- ['.pad-super', 'padding: 4em;'],
24
- ['.pad-h', 'padding-left: 1em; padding-right: 1em;'],
25
- ['.pad-h-less', 'padding-left: 0.5em; padding-right: 0.5em;'],
26
- ['.pad-v', 'padding-top: 1em; padding-bottom: 1em;'],
27
- ['.pad-v-less', 'padding-top: 0.5em; padding-bottom: 0.5em;'],
28
- ].each do |klass| %>
29
- <tr class="middle">
30
- <td>
31
- <code><%= klass[0] %></code>
32
- </td>
33
- <td>
34
- <% html_block class: "margin-none" do %>
35
- <%= klass[1] %>
36
- <% end %>
37
- </td>
38
- </tr>
39
- <% end %>
40
- </table>
41
-
42
- <h3>Margin</h3>
43
- <table class="uniformTable top">
44
- <tr>
45
- <th></th>
46
- <th></th>
47
- </tr>
48
- <% [
49
- ['.margin-tiny', 'margin-top: 0.25em; margin-bottom:0.25em'],
50
- ['.margin-less', 'margin-top: 0.5em; margin-bottom: 0.5em'],
51
- ['.margin', 'margin-top: 1em; margin-bottom: 1em;'],
52
- ['.margin-more', 'margin-top 2em; margin-bottom: 2em'],
53
- ['.margin-super', 'margin-top: 4em; margin-bottom: 2em'],
54
- ['.margin-h', 'margin-left: 1em; margin-right: 1em;'],
55
- ['.margin-none', 'margin: 0 !important;'],
56
- ].each do |klass| %>
57
- <tr class="middle">
58
- <td>
59
- <code><%= klass[0] %></code>
60
- </td>
61
- <td>
62
- <% html_block class: "margin-none" do %>
63
- <%= klass[1] %>
64
- <% end %>
65
- </td>
66
- </tr>
67
- <% end %>
68
- </table>
69
-
70
- <h3>Colors</h3>
71
- <table class="uniformTable top">
72
- <tr>
73
- <th></th>
74
- <th></th>
75
- </tr>
76
- <% [
77
- ['.text-green', 'color: $green'],
78
- ['.bg-green', 'background-color: $green'],
79
- ['.a-green', 'a{ color: $green}'],
80
- ['.a-hover-green', 'a:hover{ color: $green}'],
81
- ].each do |klass| %>
82
- <tr class="middle">
83
- <td>
84
- <code><%= klass[0] %></code>
85
- </td>
86
- <td>
87
- <% html_block class: "margin-none" do %>
88
- <%= klass[1] %>
89
- <% end %>
90
- </td>
91
- </tr>
92
- <% end %>
93
- </table>
94
-
95
- <h3>Sizes</h3>
96
- <table class="uniformTable top">
97
- <tr>
98
- <th></th>
99
- <th></th>
100
- </tr>
101
- <% [
102
- ['.width-50-p', 'width: 50%'],
103
- ['.width-50-px', 'width: 50px'],
104
- ['.width-50-vw', 'width: 50vw'],
105
- ['.max-width-50-p', 'max-width: 50%'],
106
- ['.max-width-50-px', 'max-width: 50px'],
107
- ['.height-50-p', 'height: 50%'],
108
- ['.height-50-px', 'height: 50px'],
109
- ['.height-50-vh', 'height: 50vh'],
110
- ['.max-height-50-px', 'max-height: 50px'],
111
- ['.min-height-50-vh', 'min-height: 50vh'],
112
- ].each do |klass| %>
113
- <tr class="middle">
114
- <td>
115
- <code><%= klass[0] %></code>
116
- </td>
117
- <td>
118
- <% html_block class: "margin-none" do %>
119
- <%= klass[1] %>
120
- <% end %>
121
- </td>
122
- </tr>
123
- <% end %>
124
- </table>
125
-
126
- <h3>Text</h3>
127
- <table class="uniformTable top">
128
- <tr>
129
- <th></th>
130
- <th></th>
131
- </tr>
132
- <% [
133
- ['.text-caps', 'text-transform: uppercase'],
134
- ['.text-small-less', 'font-size: 0.9em'],
135
- ['.text-small', 'font-size: 0.8em'],
136
- ['.text-large', 'font-size: 1.2em'],
137
- ['.text-1rem', 'font-size: 1rem'],
138
- ['.text-larger', 'font-size: 1.4em'],
139
- ['.text-super', 'font-size: 3em'],
140
- ['.text-subtle', 'font-size: 90%; opacity: 0.8'],
141
- ['.text-subtle-more', 'font-size: 80%; opacity: 0.6'],
142
- ['.text-muted', 'opacity: 0.8'],
143
- ['.text-muted-more', 'opacity: 0.6'],
144
- ['.text-left', 'text-align: left !important'],
145
- ['.text-right', 'text-align: right'],
146
- ['.text-center', 'text-align: center'],
147
- ['.text-justify', 'text-align: justify'],
148
- ['.text-overflow', '@include text-overflow'],
149
- ['.text-bold', 'font-weight: 700'],
150
- ['.text-light', 'font-weight: 300'],
151
- ['.text-lightest', 'font-weight: 100'],
152
- ['.text-normal', 'font-weight: normal !important'],
153
- ['.text-middle', 'vertical-align:middle'],
154
- ['.text-top', 'vertical-align:top'],
155
- ['.text-tight', 'line-height:1.3'],
156
- ['.required', 'color:$red'],
157
- ['.warn:hover', 'color:$red'],
158
- ['p.large', 'font-size:1.5em; font-weight:300'],
159
- ['.text-italic', 'font-style: italic'],
160
- ['.text-no-wrap', 'white-space: nowrap; overflow:hidden'],
161
- ['.text-no-decoration', 'text-decoration: none; a{text-decoration: none;}'],
162
- ['.text-height-1', 'line-height: 1'],
163
- ['.text-warn', '&:hover{color:$red !important;}']
164
- ].each do |klass| %>
165
- <tr class="middle">
166
- <td>
167
- <code><%= klass[0] %></code>
168
- </td>
169
- <td>
170
- <% html_block class: "margin-none" do %>
171
- <%= klass[1] %>
172
- <% end %>
173
- </td>
174
- </tr>
175
- <% end %>
176
- </table>
177
-
178
- <h3>Layout</h3>
179
- <table class="uniformTable top">
180
- <tr>
181
- <th></th>
182
- <th></th>
183
- </tr>
184
- <% [
185
- ['.hidden', 'display:none !important;'],
186
- ['.round', 'border-radius:50%;'],
187
- ['.rounded', 'border-radius: 0.25em;'],
188
- ['.pointer', 'cursor: pointer !important;'],
189
- ['.cursor-help', 'cursor: help;'],
190
- ['.handle', 'cursor: hand;'],
191
- ['.honeypot', "position:absolute !important;\nleft:-999999px !important;\nwidth:1px !important;\ndisplay:block !important;"],
192
- ['.border-#{$direction}', 'border-#{$direction}: 1px solid $gray-light;'],
193
- ['.border-dark-#{$direction}', 'border-#{$direction}: 1px solid darken($gray-light, 20);'],
194
- ['img.disabled', '@include grayscale(1, 0.3)'],
195
- ['table.fixed', 'table-layout: fixed;'],
196
- ['.float-right', 'float:right;'],
197
- ['.float-left', 'float: left;'],
198
- ['.bleed-fix', 'position:static; overflow:hidden;'],
199
- ['.clear', 'clear:both;'],
200
- ['.block ', 'display: block;'],
201
- ['.inline-block ', 'display:inline-block !important;'],
202
- ['.align-middle', '@include align-middle;'],
203
- ['.relative', 'position:relative;'],
204
- ['ul.raw', 'margin: 0; padding: 0; list-style:none;'],
205
- ['.text-col-2', 'column-count: 2; column-gap: 5em;'],
206
- ['button.raw', 'outline: none; appearance: none; border: none; background:none;'],
207
- ['.overflow-hidden', 'overflow:hidden;'],
208
- ['.overflow-y', 'overflow-y: auto;'],
209
- ['img.block', 'display:block; width: 100%;'],
210
- ['.height-auto', 'height: auto;'],
211
- ].each do |klass| %>
212
- <tr class="middle">
213
- <td>
214
- <code><%= klass[0] %></code>
215
- </td>
216
- <td>
217
- <% html_block class: "margin-none" do %>
218
- <%= klass[1] %>
219
- <% end %>
220
- </td>
221
- </tr>
222
- <% end %>
223
- </table>
224
-
225
- </div>
@@ -1,77 +0,0 @@
1
- <div class="text-center margin-top-more">
2
- <img src="site/logo.png" width="451" height="101">
3
- <p class="large">Sass components and helpers for building a UI.</p>
4
- </div>
5
- <div class="section">
6
- <h1>Installation</h1>
7
- <p>Add to your gem file<br/><code>gem 'uniform-ui'</code></p>
8
- <p>Execute:<br/><code>$ bundle</code></p>
9
- <p>Or install it yourself:<br/><code>$ gem install uniform-ui</code></p>
10
- <p>Include the css library in your asset pipeline.<br/><code>@import 'uniform';</code></p>
11
- <p>Include the javascript library in your asset pipeline.<br/><code>//= require uniform</code></p>
12
- <h3>Scope Components</h3>
13
- <p>Optionally, you can scope the components you want included in your assets.</p>
14
- <% html_block do %>
15
- // css
16
- @import 'uniform';
17
- // - OR -
18
- @import 'uniform/base';<% (Dir.foreach(File.join('vendor', 'assets', 'stylesheets', 'uniform')).reject{|x| %w(variables.scss mixins.scss base.scss).include?(x)}.to_a +
19
- Dir.foreach(File.join('vendor', 'assets', 'stylesheets', 'uniform', 'helpers')).map{|x| "helpers/#{x}"}.to_a +
20
- Dir.foreach(File.join('vendor', 'assets', 'stylesheets', 'uniform', 'components')).map{|x| "components/#{x}"}.to_a).select{|x| x.split('.').last == "scss"}.each do |x| %>
21
- @import 'uniform/<%= x.remove('.scss') %>';<% end %>
22
-
23
- // javascript
24
- //= require uniform
25
- // - OR -
26
- //= require uniform/base
27
- //= require uniform/select
28
- <% end %>
29
-
30
- </div>
31
- <div class="section">
32
- <h1>Philosophy</h1>
33
- <h3>Don't use ID's</h3>
34
- <p>Unless you have to, and even then, think twice. HTML Id's make things not
35
- reusable. There should only be one instance of an id in a document</p>
36
-
37
- <h3>Use Semanitc Classes Presentationaly :)</h3>
38
- <p>
39
- Here's a decent post on OOCSS (Object Oriented CSS) as it relates to
40
- semantic vs presentational classes:
41
- <a href="http://blackfalcon.roughdraft.io/5255648-oocss-v-ooscss-sasscast-show-notes">OOCSS v OOSCSS</a>
42
- <p>
43
- <strong>TL;DR:</strong> Semantic classes explain what that element is.
44
- Presentational classes explain what the shoud look like.
45
- </p>
46
- <p>
47
- <code>class="property-list"</code> vs <code>class="ul-list col-sm-4"</code>
48
- </p>
49
- <p>
50
- Some of us don't want to touch css files (preference: presentational),
51
- and some of us live there (preference: semantic). Honestly, the art of
52
- good ui development is balancing semantic and presentational classes.
53
- Each taken to their extreme is bad.
54
- </p>
55
- <p>
56
- Structure html so that the semantic class is first and presentational
57
- classes follow.
58
- </p>
59
- <p><code>class="property-list ul-list col-sm-4"</code></p>
60
-
61
- <h3>Save the Namespace, save the world</h3>
62
- <p>Don't make presentational classes that will clash with elements that could mean something else. I'm looking at you Bootsrap!</p>
63
- <p><code>class="label"</code> should be <code>class="text-label"</code></p>
64
-
65
- <h3>camelCase vs train-case</h3>
66
- <p>Use camelCase for class names for components, not train-case or snake_case.</p>
67
- <p>Use tran-case for class names for helpers or modifiers.</p>
68
-
69
- <h3>Wrappers and Containers</h3>
70
- <p>
71
- Both <code>wrapper</code> and <code>container</code> can be used as class names
72
- for an element that goes around a component. The difference is nuanced.
73
- <code>wrapper</code> should be used to wrap a <strong>single</strong> element for a formatting purpose.
74
- A <code>container</code> should be used to wrap <strong>multiple</strong> elements.
75
- </p>
76
-
77
- </div>
@@ -1 +0,0 @@
1
- TODO
@@ -1,63 +0,0 @@
1
- <!DOCTYPE html>
2
- <head>
3
- <meta http-equiv="Content-type" content="text/html; charset=utf-8">
4
- <title>Uniform</title>
5
- <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/4.2.0/normalize.css" type="text/css" media="screen">
6
- <link rel="stylesheet" href="/site/uniform.css" type="text/css" media="screen" title="no title" charset="utf-8">
7
- <link rel="stylesheet" href="/site/preview.css" type="text/css" media="screen" charset="utf-8">
8
- </head>
9
- <body>
10
- <div class="side-nav">
11
- <div class="pad">
12
- <a href="/">
13
- <img src="/site/logo.png" class="block">
14
- </a>
15
- </div>
16
- <div class="uniformNav vertical">
17
- <div class="nav">
18
- <% %>
19
- <% [
20
- :helpers,
21
- :colors,
22
- :grid,
23
- :buttons,
24
- [:tables],
25
- :cards,
26
- :rows,
27
- :form,
28
- :loaders,
29
- :nav,
30
- :tabs,
31
- [:tiles],
32
- [:labels],
33
- [:alerts],
34
- [:dropdown],
35
- [:modal],
36
- [:select],
37
- [:tooltip]
38
- ].each do |page| %>
39
- <% if page.is_a?(Array)
40
- page = page[0]
41
- todo = true
42
- end %>
43
- <a href="/site/<%= page %>.html">
44
- <%= page.to_s.titleize %>
45
- <% if todo %>
46
- <span class="uniformLabel yellow">todo</span>
47
- <% end %>
48
- </a>
49
- <% end %>
50
- </div>
51
- </div>
52
- </div>
53
- <div class="main-content overflow-hidden">
54
- <%= yield %>
55
- </div>
56
- <script>document.write('<script src="http://' + (location.host || 'localhost').split(':')[0] + ':35729/livereload.js?snipver=1"></' + 'script>')</script>
57
- <script src="https://cdnjs.cloudflare.com/ajax/libs/underscore.js/1.8.3/underscore-min.js"></script>
58
- <script
59
- src="https://code.jquery.com/jquery-1.11.3.min.js"
60
- integrity="sha256-7LkWEzqTdpEfELxcZZlS6wAx5Ff13zZ83lYO2/ujj7g="
61
- crossorigin="anonymous"></script>
62
- <script src="/site/preview.js"></script>
63
- </body>