underoos 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (133) hide show
  1. data/.gitignore +8 -0
  2. data/.rvmrc +1 -0
  3. data/Gemfile +5 -0
  4. data/Gemfile.lock +143 -0
  5. data/LICENSE +26 -0
  6. data/Procfile +1 -0
  7. data/README.md +13 -0
  8. data/Rakefile +12 -0
  9. data/app/assets/javascripts/styleguide.js +132 -0
  10. data/app/assets/javascripts/underoos.js +18 -0
  11. data/app/assets/stylesheets/base/_button-btn-mixin.sass +72 -0
  12. data/app/assets/stylesheets/base/_elements.sass +61 -0
  13. data/app/assets/stylesheets/base/_forms.sass +362 -0
  14. data/app/assets/stylesheets/base/_helpers.sass +54 -0
  15. data/app/assets/stylesheets/base/_normalize.sass +114 -0
  16. data/app/assets/stylesheets/base/_scaffold.sass +51 -0
  17. data/app/assets/stylesheets/base/_tables.sass +99 -0
  18. data/app/assets/stylesheets/base/_transitions.sass +17 -0
  19. data/app/assets/stylesheets/base/_typography.sass +185 -0
  20. data/app/assets/stylesheets/components/_accordions.sass +17 -0
  21. data/app/assets/stylesheets/components/_breadcrumbs.sass +22 -0
  22. data/app/assets/stylesheets/components/_button-groups.sass +46 -0
  23. data/app/assets/stylesheets/components/_carets.sass +24 -0
  24. data/app/assets/stylesheets/components/_carousels.sass +18 -0
  25. data/app/assets/stylesheets/components/_close.sass +25 -0
  26. data/app/assets/stylesheets/components/_decals.sass +27 -0
  27. data/app/assets/stylesheets/components/_dropdowns.sass +85 -0
  28. data/app/assets/stylesheets/components/_media.sass +33 -0
  29. data/app/assets/stylesheets/components/_modals.sass +28 -0
  30. data/app/assets/stylesheets/components/_nav-lists.sass +22 -0
  31. data/app/assets/stylesheets/components/_navbars.sass +105 -0
  32. data/app/assets/stylesheets/components/_notifications.sass +108 -0
  33. data/app/assets/stylesheets/components/_paddles.sass +34 -0
  34. data/app/assets/stylesheets/components/_pagination.sass +41 -0
  35. data/app/assets/stylesheets/components/_pills.sass +64 -0
  36. data/app/assets/stylesheets/components/_popovers.sass +55 -0
  37. data/app/assets/stylesheets/components/_progress-bars.sass +29 -0
  38. data/app/assets/stylesheets/components/_tabs.sass +93 -0
  39. data/app/assets/stylesheets/components/_tooltips.sass +46 -0
  40. data/app/assets/stylesheets/components/_wells.sass +16 -0
  41. data/app/assets/stylesheets/layouts/_containers.sass +15 -0
  42. data/app/assets/stylesheets/layouts/_print.sass +48 -0
  43. data/app/assets/stylesheets/layouts/_queries.sass +121 -0
  44. data/app/assets/stylesheets/layouts/_upgrades.sass +64 -0
  45. data/app/assets/stylesheets/mixins/_arrows.sass +40 -0
  46. data/app/assets/stylesheets/mixins/_clearfixins.sass +15 -0
  47. data/app/assets/stylesheets/mixins/_coloring.sass +6 -0
  48. data/app/assets/stylesheets/mixins/_columns.sass +19 -0
  49. data/app/assets/stylesheets/mixins/_conversions.sass +25 -0
  50. data/app/assets/stylesheets/mixins/_font-size.sass +6 -0
  51. data/app/assets/stylesheets/mixins/_image-tools.sass +13 -0
  52. data/app/assets/stylesheets/mixins/_ir.sass +9 -0
  53. data/app/assets/stylesheets/mixins/_mixins.sass +14 -0
  54. data/app/assets/stylesheets/mixins/_tab-focus.sass +7 -0
  55. data/app/assets/stylesheets/mixins/_timing-equations.sass +29 -0
  56. data/app/assets/stylesheets/mixins/_visibility.sass +43 -0
  57. data/app/assets/stylesheets/polyfills/_box-shadow.sass +7 -0
  58. data/app/assets/stylesheets/polyfills/_box-sizing.sass +8 -0
  59. data/app/assets/stylesheets/polyfills/_functions.sass +22 -0
  60. data/app/assets/stylesheets/polyfills/_inline-block.sass +8 -0
  61. data/app/assets/stylesheets/polyfills/_opacity.sass +6 -0
  62. data/app/assets/stylesheets/polyfills/_polyfills.sass +10 -0
  63. data/app/assets/stylesheets/polyfills/_transition.sass +9 -0
  64. data/app/assets/stylesheets/polyfills/_user-select.sass +8 -0
  65. data/app/assets/stylesheets/styleguide.sass +199 -0
  66. data/app/assets/stylesheets/themes/_default.sass +119 -0
  67. data/app/assets/stylesheets/underoos.sass +52 -0
  68. data/app/controllers/underoos/styleguides_controller.rb +79 -0
  69. data/app/views/shared/_upgrades.html.haml +12 -0
  70. data/app/views/underoos/styleguides/_assets.haml +42 -0
  71. data/app/views/underoos/styleguides/_components.haml +42 -0
  72. data/app/views/underoos/styleguides/_elements.haml +242 -0
  73. data/app/views/underoos/styleguides/_forms.haml +305 -0
  74. data/app/views/underoos/styleguides/_layouts.haml +76 -0
  75. data/app/views/underoos/styleguides/_palettes.haml +18 -0
  76. data/app/views/underoos/styleguides/_resources.haml +27 -0
  77. data/app/views/underoos/styleguides/_tables.haml +124 -0
  78. data/app/views/underoos/styleguides/_typography.haml +284 -0
  79. data/app/views/underoos/styleguides/_utilities.haml +270 -0
  80. data/app/views/underoos/styleguides/components/_accordions.haml +83 -0
  81. data/app/views/underoos/styleguides/components/_breadcrumbs.haml +42 -0
  82. data/app/views/underoos/styleguides/components/_button-groups.haml +162 -0
  83. data/app/views/underoos/styleguides/components/_carets.haml +28 -0
  84. data/app/views/underoos/styleguides/components/_close.haml +20 -0
  85. data/app/views/underoos/styleguides/components/_decals.haml +40 -0
  86. data/app/views/underoos/styleguides/components/_dropdowns.haml +189 -0
  87. data/app/views/underoos/styleguides/components/_media.haml +78 -0
  88. data/app/views/underoos/styleguides/components/_modals.haml +42 -0
  89. data/app/views/underoos/styleguides/components/_nav-lists.haml +52 -0
  90. data/app/views/underoos/styleguides/components/_navbars.haml +144 -0
  91. data/app/views/underoos/styleguides/components/_navs-showcase.haml +27 -0
  92. data/app/views/underoos/styleguides/components/_notifications.haml +169 -0
  93. data/app/views/underoos/styleguides/components/_paddles.haml +68 -0
  94. data/app/views/underoos/styleguides/components/_pagination.haml +64 -0
  95. data/app/views/underoos/styleguides/components/_popovers.haml +33 -0
  96. data/app/views/underoos/styleguides/components/_progress-bars.haml +72 -0
  97. data/app/views/underoos/styleguides/components/_tabs-pills.haml +241 -0
  98. data/app/views/underoos/styleguides/components/_tooltips.haml +37 -0
  99. data/app/views/underoos/styleguides/components/_wells.haml +29 -0
  100. data/app/views/underoos/styleguides/index.html.haml +259 -0
  101. data/app/views/underoos/styleguides/partials/_form-template.haml +171 -0
  102. data/app/views/underoos/styleguides/partials/_table-data.haml +33 -0
  103. data/app/views/underoos/styleguides/partials/_transitions.haml +136 -0
  104. data/config.ru +38 -0
  105. data/config/routes.rb +3 -0
  106. data/features/generator.feature +78 -0
  107. data/features/step_definitions/underoos_steps.rb +3 -0
  108. data/features/support/env.rb +9 -0
  109. data/lib/generators/underoos/assets_generator.rb +33 -0
  110. data/lib/underoos.rb +5 -0
  111. data/lib/underoos/engine.rb +8 -0
  112. data/lib/underoos/version.rb +3 -0
  113. data/public/apple-touch-icon-114x114-precomposed.png +0 -0
  114. data/public/apple-touch-icon-57x57-precomposed.png +0 -0
  115. data/public/apple-touch-icon-72x72-precomposed.png +0 -0
  116. data/public/apple-touch-icon-precomposed.png +0 -0
  117. data/public/apple-touch-icon.png +0 -0
  118. data/public/favicon.ico +0 -0
  119. data/script/javascripts +15 -0
  120. data/underoos.gemspec +29 -0
  121. data/vendor/assets/javascripts/bootstrap-alert.js +94 -0
  122. data/vendor/assets/javascripts/bootstrap-button.js +100 -0
  123. data/vendor/assets/javascripts/bootstrap-collapse.js +138 -0
  124. data/vendor/assets/javascripts/bootstrap-dropdown.js +92 -0
  125. data/vendor/assets/javascripts/bootstrap-modal.js +210 -0
  126. data/vendor/assets/javascripts/bootstrap-popover.js +95 -0
  127. data/vendor/assets/javascripts/bootstrap-scrollspy.js +125 -0
  128. data/vendor/assets/javascripts/bootstrap-tab.js +130 -0
  129. data/vendor/assets/javascripts/bootstrap-tooltip.js +270 -0
  130. data/vendor/assets/javascripts/bootstrap-transition.js +51 -0
  131. data/vendor/assets/javascripts/bootstrap-typeahead.js +271 -0
  132. data/vendor/assets/javascripts/prettify.js +28 -0
  133. metadata +246 -0
@@ -0,0 +1,61 @@
1
+
2
+ // Allow images to be fluid
3
+ img
4
+ max-width: 100%
5
+
6
+ // Base Navs, used by tabs, pills, breadcrumbs, pagination, and navigation lists
7
+ .nav
8
+ +clearfixer
9
+ list-style: none
10
+
11
+ .nav > li > a
12
+ display: block
13
+
14
+ .nav.inline > li
15
+ float: left
16
+
17
+ .nav.inline > li > a
18
+ padding-left: 0.5em
19
+ padding-right: 0.5em
20
+
21
+ // Active states for navs get a default cursor
22
+ .nav > .active > a,
23
+ .nav > .active > a:hover
24
+ cursor: default
25
+ .nav > .dropdown.active > a:hover
26
+ cursor: pointer
27
+
28
+ // Headers within a Nav
29
+ .nav .nav-header
30
+ display: block
31
+ color: $component_normal
32
+ font-size: 0.75em
33
+ font-weight: bold
34
+ text-transform: uppercase
35
+ text-shadow: $text_drop_lite
36
+ padding: 0.4em 1em
37
+
38
+ .nav li + .nav-header
39
+ margin-top: 1em
40
+
41
+
42
+ // Buttons
43
+ .btn
44
+ +btn-button($standard, $grey6)
45
+ &.info
46
+ +btn-override($info, $white)
47
+ &.important
48
+ +btn-override($important, $white)
49
+ &.success
50
+ +btn-override($success, $white)
51
+ &.warning
52
+ +btn-override($warning, $white)
53
+ &.danger
54
+ +btn-override($danger, $white)
55
+ &.primary
56
+ +btn-override($primary, $white)
57
+
58
+ // Fix standard links to closer resemble `button` elements
59
+ a.btn
60
+ font-weight: bold
61
+
@@ -0,0 +1,362 @@
1
+
2
+ // ## Form containers and base settings
3
+ form
4
+ margin: 0
5
+
6
+ fieldset
7
+ border: 0
8
+
9
+ form ol, form ul, form li
10
+ margin: 0
11
+ padding: 0
12
+
13
+ form ol, form ul
14
+ +clearfixer
15
+ list-style-image: none
16
+ list-style-type: none
17
+
18
+ form li
19
+ display: block
20
+ margin-bottom: 1em
21
+ &:last-child
22
+ margin-bottom: 0
23
+
24
+ @mixin form-placeholder
25
+ color: $placeholder
26
+
27
+ \:-moz-placeholder
28
+ +form-placeholder
29
+
30
+ \::-webkit-input-placeholder
31
+ +form-placeholder
32
+
33
+
34
+ // ## Description elements
35
+ form abbr[title]
36
+ border: none
37
+ margin-left: 0.25em
38
+
39
+ legend + ol,
40
+ legend + ul
41
+ margin-top: 1.5em
42
+ -webkit-margin-top-collapse: separate
43
+
44
+ legend
45
+ display: block
46
+ border-bottom: 1px solid $component_border
47
+ color: $header_color
48
+ font-size: 1.25em
49
+ padding-bottom: 0.25em
50
+ width: 100%
51
+
52
+ label
53
+ display: block
54
+ font-size: 0.85em
55
+ margin-bottom: 0.3em
56
+
57
+ .hint
58
+ display: block
59
+ color: lighten($body_color, 20%)
60
+ font-size: 0.92em
61
+ margin-top: 0.25em
62
+
63
+
64
+ // ## Form controls
65
+ input,
66
+ textarea,
67
+ select,
68
+ .uneditable
69
+ +box-sizing(border-box)
70
+ +font-size($base_font_size)
71
+ +inline-block
72
+ border: 1px solid $component_border
73
+ border-radius: $radii
74
+ color: $body_color
75
+ padding: 0.4em
76
+ vertical-align: middle
77
+
78
+ input,
79
+ textarea,
80
+ .uneditable
81
+ +box-shadow($input_inset_shadow)
82
+ +transition(border $speed, box-shadow $speed, background-color $speed)
83
+
84
+ select
85
+ background-color: $white
86
+ line-height: 28px
87
+ height: 28px
88
+
89
+ label input,
90
+ label textarea,
91
+ label select
92
+ display: block
93
+
94
+ // Specific styles for special input types
95
+ .search-query
96
+ border-radius: 1em
97
+ margin-bottom: 0
98
+ padding-left: 1em
99
+ padding-right: 1em
100
+
101
+ .uneditable
102
+ background-color: $off_white
103
+ cursor: not-allowed
104
+
105
+ // ## Perform resets on odd controls before defining again
106
+ select[multiple],
107
+ select[size]
108
+ height: auto
109
+
110
+ input[type="file"]
111
+ +box-shadow(none)
112
+ background-color: $white
113
+ background-color: initial
114
+ border: initial
115
+ line-height: initial
116
+ margin-top: 0.3em
117
+ padding: initial
118
+
119
+ input[type="image"]
120
+ border-color: transparent
121
+ border-radius: 0
122
+ margin: 0
123
+ padding: 0
124
+
125
+
126
+ // ## Radio and Checkboxes
127
+ input[type="checkbox"],
128
+ input[type="radio"]
129
+ +inline-block
130
+ border: 0
131
+ border-radius: 0
132
+ margin: -0.3em 0.3em 0 0
133
+ padding: 0
134
+ vertical-align: middle
135
+
136
+ form .choices-group
137
+ margin: 1em 0
138
+ form .choices-group li
139
+ margin: 0
140
+
141
+ form .boolean,
142
+ form .choice
143
+ margin-bottom: 0.3em
144
+
145
+ form .boolean > label,
146
+ form .choice > label
147
+ +font-size($base_font_size)
148
+
149
+ form .boolean.inline,
150
+ form .choice.inline
151
+ +inline-block
152
+ margin-right: 1em
153
+ vertical-align: middle
154
+
155
+
156
+ // ## Focus states
157
+ input:focus,
158
+ textarea:focus
159
+ +box-shadow($input_inset_shadow, $focus_glow)
160
+ background-color: $off_white
161
+ border-color: $focus_border
162
+ outline: 0
163
+ outline: thin dotted \9
164
+
165
+ input[type="file"]:focus,
166
+ input[type="radio"]:focus,
167
+ input[type="checkbox"]:focus,
168
+ select:focus
169
+ +box-shadow(none)
170
+ +tab-focus
171
+
172
+ // ## Disabled states
173
+ input,
174
+ textarea,
175
+ select,
176
+ .uneditable
177
+ &.disabled, &[disabled], &[readonly]
178
+ +box-shadow(none)
179
+ background-color: $disabled_bg
180
+ border-color: $disabled_border
181
+ color: $disabled_color
182
+ cursor: not-allowed
183
+
184
+ input[type="button"],
185
+ input[type="submit"],
186
+ input[type="reset"]
187
+ &.disabled:hover,
188
+ &[disabled]:hover,
189
+ &[readonly]:hover
190
+ color: $disabled_color
191
+
192
+ input[type="file"][disabled],
193
+ input[type="file"][readonly]
194
+ background-color: $white
195
+ background-color: initial
196
+ border: initial
197
+
198
+ input[type="image"][disabled],
199
+ input[type="image"][readonly]
200
+ +opacity(0.5)
201
+
202
+ form .disabled label,
203
+ form .disabled .hint
204
+ color: $disabled_color
205
+
206
+ // ## Error, Warning Success states
207
+ @mixin form-states($highlight)
208
+ label, .hint
209
+ color: $highlight
210
+
211
+ input, select, textarea
212
+ color: $highlight
213
+ border-color: $highlight
214
+ &:focus
215
+ +box-shadow(0 0 6px lighten($highlight, 20%))
216
+ border-color: darken($highlight, 10%)
217
+ color: $highlight
218
+
219
+ .uneditable
220
+ border-color: $highlight
221
+ color: $highlight
222
+
223
+ input[type="button"]:hover,
224
+ input[type="submit"]:hover,
225
+ input[type="reset"]:hover
226
+ border-color: darken($highlight, 10%)
227
+ color: $highlight
228
+
229
+ form .error
230
+ +form-states($error)
231
+ form .success
232
+ +form-states($success)
233
+ form .warning
234
+ +form-states(darken($warning, 10%))
235
+
236
+ // HTML5 invalid states
237
+ input:focus:required:invalid,
238
+ textarea:focus:required:invalid,
239
+ select:focus:required:invalid
240
+ border-color: $error
241
+ color: $error
242
+ &:focus
243
+ +box-shadow(0 0 6px lighten($error, 20%))
244
+ border-color: darken($error, 10%)
245
+
246
+
247
+ // Button group containers
248
+ .form-actions,
249
+ form .buttons
250
+ background-color: $off_white
251
+ border-top: 1px solid $component_border
252
+ margin-top: 1em
253
+ margin-bottom: 1em
254
+ padding: 1.5em
255
+ &.dark
256
+ background-color: darken($off_grey, 3%)
257
+
258
+ .form-actions li,
259
+ form .buttons li
260
+ +inline-block
261
+ margin: 0
262
+ vertical-align: middle
263
+
264
+
265
+ // ## Form layouts
266
+ .form-search,
267
+ .form-inline,
268
+ .form-horizontal,
269
+ .default-manage-form
270
+ input,
271
+ textarea,
272
+ select,
273
+ .uneditable
274
+ +inline-block
275
+ margin-bottom: 0
276
+
277
+ .form-inline label,
278
+ .form-search label
279
+ +inline-block
280
+ margin-bottom: 0
281
+
282
+
283
+ // ## Horizontal specific overrides
284
+ .form-horizontal,
285
+ .default-manage-form
286
+ li
287
+ +clearfixer
288
+ li > input,
289
+ li > textarea,
290
+ li > select,
291
+ li > .uneditable
292
+ margin-left: 1em
293
+
294
+ li > label
295
+ float: left
296
+ padding-top: 0.5em
297
+ width: $horiz_offset
298
+ text-align: right
299
+
300
+ .boolean > label,
301
+ .choice > label
302
+ float: none
303
+ margin-left: 1em
304
+ padding-top: 0
305
+ padding-left: $horiz_offset
306
+ width: auto
307
+ text-align: left
308
+
309
+ .boolean.inline + .boolean.inline > label,
310
+ .choice.inline + .choice.inline > label
311
+ margin-left: 0
312
+ padding-left: 0
313
+
314
+ .form-actions,
315
+ form .buttons
316
+ padding-left: $horiz_offset
317
+
318
+ .hint
319
+ margin-left: 1.2em
320
+ padding-left: $horiz_offset
321
+
322
+
323
+ // ## Convenience classes for sizing
324
+ .input-xsmall
325
+ width: 12.5%
326
+ .input-small
327
+ width: 25%
328
+ .input-medium
329
+ width: 50%
330
+ .input-large
331
+ width: 75%
332
+ .input-xlarge
333
+ width: 100%
334
+
335
+ // ## Content Editable states
336
+ [contenteditable="true"]
337
+ border: 1px dotted transparent
338
+
339
+ [contenteditable="true"]:hover
340
+ border-color: $primary
341
+
342
+ [contenteditable="true"]:focus
343
+ +box-shadow($input_inset_shadow, $focus_glow)
344
+ background-color: $off_white
345
+ border-style: solid
346
+ border-color: $focus_border
347
+ outline: 0
348
+ outline: thin dotted \9
349
+
350
+ // Specific settings for formtastic
351
+ .default-manage-form .well
352
+ background-color: $off_white
353
+
354
+ form .buttons input[type="button"],
355
+ form .buttons input[type="submit"]
356
+ +btn-button($standard, $grey6)
357
+ +btn-override($primary, $white)
358
+
359
+ form .buttons input[type="reset"]
360
+ +btn-button($standard, $grey6)
361
+ +btn-override($danger, $white)
362
+
@@ -0,0 +1,54 @@
1
+
2
+ // Utility classes for use with @extension, or just common items found in every project!
3
+ // All helpers are also available as mixins, following the same name
4
+
5
+ // Utilizes the `micro clearfix` on pseudo elements for clearing floats
6
+ .clearfixer
7
+ +clearfixer
8
+
9
+ // Uses the standard clearfix of `overflow:hidden` found in Compass
10
+ .clearfix
11
+ +clearfix
12
+
13
+ // Image replacement
14
+ .ir
15
+ +ir
16
+
17
+ // Totally hidden from screen readers and browsers
18
+ .hidden
19
+ +hidden
20
+
21
+ // Reverse the effects of hidden
22
+ .shown
23
+ +shown
24
+
25
+ // Only visually hidden, still available to screen readers
26
+ .visuallyhidden
27
+ +visuallyhidden
28
+
29
+ // Reverse the settings applied by `.visuallyhidden`
30
+ .visuallyshown
31
+ +visuallyshown
32
+
33
+ // Hide visually and from screenreaders, but maintain layout
34
+ .invisible
35
+ +invisible
36
+
37
+ // The base `column` settings, should be extended by all columns
38
+ .base-column
39
+ +base-column
40
+
41
+ // An alternate base `column` which floats elements to the right
42
+ .base-column-right
43
+ +base-column-right
44
+
45
+ // The base `row` settings, should be extended by all rows
46
+ .base-row
47
+ +base-row
48
+
49
+ // Gabe, your welcome.
50
+ .pull-left
51
+ float: left
52
+ .pull-right
53
+ float: right
54
+