zurb-foundation 3.2.5 → 4.0.0.rc1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (239) hide show
  1. data/.gitignore +6 -2
  2. data/CHANGELOG.md +1 -26
  3. data/CONTRIBUTING.md +18 -0
  4. data/Gemfile.lock +19 -0
  5. data/Gruntfile.js +27 -0
  6. data/README.md +5 -6
  7. data/{Capfile → docs/Capfile} +0 -1
  8. data/docs/Gemfile +8 -0
  9. data/docs/Gemfile.lock +43 -0
  10. data/docs/Procfile +2 -0
  11. data/docs/README.md +1 -0
  12. data/docs/_sidebar-components.html.erb +109 -0
  13. data/docs/_sidebar.html.erb +109 -0
  14. data/docs/_zurb-jobs.html.erb +5 -0
  15. data/docs/changelog.html.erb +185 -0
  16. data/docs/compile.rb +43 -0
  17. data/docs/components/alert-boxes.html.erb +202 -0
  18. data/docs/components/block-grid.html.erb +118 -0
  19. data/docs/components/breadcrumbs.html.erb +146 -0
  20. data/docs/components/button-groups.html.erb +174 -0
  21. data/docs/components/buttons.html.erb +220 -0
  22. data/docs/components/clearing.html.erb +152 -0
  23. data/docs/components/custom-forms.html.erb +306 -0
  24. data/docs/components/dropdown-buttons.html.erb +233 -0
  25. data/docs/components/dropdown.html.erb +186 -0
  26. data/docs/components/flex-video.html.erb +93 -0
  27. data/docs/components/forms.html.erb +468 -0
  28. data/docs/components/grid.html.erb +355 -0
  29. data/docs/components/inline-lists.html.erb +89 -0
  30. data/docs/components/joyride.html.erb +178 -0
  31. data/docs/components/keystrokes.html.erb +74 -0
  32. data/docs/components/labels.html.erb +98 -0
  33. data/docs/components/magellan.html.erb +84 -0
  34. data/docs/components/orbit.html.erb +262 -0
  35. data/docs/components/pagination.html.erb +181 -0
  36. data/docs/components/panels.html.erb +121 -0
  37. data/docs/components/pricing-tables.html.erb +154 -0
  38. data/docs/components/progress-bars.html.erb +120 -0
  39. data/docs/components/reveal.html.erb +147 -0
  40. data/docs/components/section.html.erb +156 -0
  41. data/docs/components/side-nav.html.erb +122 -0
  42. data/docs/components/split-buttons.html.erb +218 -0
  43. data/docs/components/sub-nav.html.erb +120 -0
  44. data/docs/components/switch.html.erb +288 -0
  45. data/docs/components/tables.html.erb +123 -0
  46. data/docs/components/thumbnails.html.erb +87 -0
  47. data/docs/components/tooltips.html.erb +73 -0
  48. data/docs/components/top-bar.html.erb +219 -0
  49. data/docs/components/type.html.erb +359 -0
  50. data/docs/components/visibility.html.erb +102 -0
  51. data/docs/config.ru +12 -0
  52. data/docs/config/deploy.rb +33 -0
  53. data/docs/controller.rb +43 -0
  54. data/docs/css/_coderay.scss +116 -0
  55. data/docs/css/_settings.scss +1 -0
  56. data/docs/css/docs.scss +174 -0
  57. data/docs/css/normalize.scss +396 -0
  58. data/docs/css/qunit-composite.css +13 -0
  59. data/docs/css/qunit.css +235 -0
  60. data/docs/faq.html.erb +61 -0
  61. data/docs/img/demos/demo1-th.png +0 -0
  62. data/docs/img/demos/demo1.png +0 -0
  63. data/docs/img/demos/demo2-th.png +0 -0
  64. data/docs/img/demos/demo2.png +0 -0
  65. data/docs/img/demos/demo3-th.png +0 -0
  66. data/docs/img/demos/demo3.png +0 -0
  67. data/docs/img/demos/demo4-th.png +0 -0
  68. data/docs/img/demos/demo4.png +0 -0
  69. data/docs/img/demos/demo5-th.png +0 -0
  70. data/docs/img/demos/demo5.png +0 -0
  71. data/docs/index.html.erb +299 -0
  72. data/docs/javascript.html.erb +133 -0
  73. data/docs/js/docs.js +3 -0
  74. data/docs/js/qunit-composite.js +105 -0
  75. data/docs/js/qunit.js +1977 -0
  76. data/docs/js/tests/tabs/simple_tabs.html +57 -0
  77. data/docs/js/tests/tabs/simple_tabs.js +54 -0
  78. data/docs/js/tests/tooltips/tooltips.html +39 -0
  79. data/docs/js/tests/tooltips/tooltips.js +11 -0
  80. data/docs/layout.html.erb +99 -0
  81. data/docs/rails.html.erb +66 -0
  82. data/docs/sass.html.erb +299 -0
  83. data/docs/support.html.erb +134 -0
  84. data/foundation.gemspec +2 -4
  85. data/index.html +3 -23
  86. data/js/foundation/foundation.alerts.js +50 -0
  87. data/js/foundation/foundation.clearing.js +478 -0
  88. data/{vendor/assets/javascripts/foundation/jquery.cookie.js → js/foundation/foundation.cookie.js} +3 -1
  89. data/js/foundation/foundation.dropdown.js +122 -0
  90. data/js/foundation/foundation.forms.js +403 -0
  91. data/js/foundation/foundation.joyride.js +613 -0
  92. data/js/foundation/foundation.js +331 -0
  93. data/js/foundation/foundation.magellan.js +130 -0
  94. data/js/foundation/foundation.orbit.js +355 -0
  95. data/{vendor/assets/javascripts/foundation/jquery.placeholder.js → js/foundation/foundation.placeholder.js} +4 -2
  96. data/js/foundation/foundation.reveal.js +264 -0
  97. data/js/foundation/foundation.section.js +180 -0
  98. data/js/foundation/foundation.tooltips.js +195 -0
  99. data/js/foundation/foundation.topbar.js +187 -0
  100. data/js/foundation/index.js +16 -0
  101. data/{vendor/assets/javascripts/foundation/modernizr.foundation.js → js/vendor/custom.modernizr.js} +0 -0
  102. data/js/vendor/jquery.js +9597 -0
  103. data/js/vendor/zepto.js +1782 -0
  104. data/lib/foundation/engine.rb +8 -1
  105. data/lib/foundation/generators/install_generator.rb +24 -1
  106. data/lib/foundation/generators/templates/application.html.erb +20 -6
  107. data/lib/foundation/generators/templates/application.html.haml +2 -6
  108. data/lib/foundation/generators/templates/application.html.slim +2 -5
  109. data/lib/foundation/version.rb +1 -1
  110. data/lib/zurb-foundation.rb +7 -9
  111. data/package.json +9 -0
  112. data/scss/foundation.scss +42 -15
  113. data/scss/foundation/_foundation-global.scss +226 -0
  114. data/scss/foundation/components/_alert-boxes.scss +106 -0
  115. data/scss/foundation/components/_block-grid.scss +63 -0
  116. data/scss/foundation/components/_breadcrumbs.scss +117 -0
  117. data/scss/foundation/components/_button-groups.scss +59 -0
  118. data/scss/foundation/components/_buttons.scss +217 -0
  119. data/scss/foundation/components/_clearing.scss +209 -0
  120. data/scss/foundation/components/_custom-forms.scss +232 -0
  121. data/scss/foundation/components/_dropdown-buttons.scss +114 -0
  122. data/scss/foundation/components/_dropdown.scss +137 -0
  123. data/scss/foundation/components/_flex-video.scss +45 -0
  124. data/scss/foundation/components/_forms.scss +309 -0
  125. data/scss/foundation/components/_grid.scss +149 -71
  126. data/scss/foundation/components/_inline-lists.scss +47 -0
  127. data/scss/foundation/components/_joyride.scss +193 -0
  128. data/scss/foundation/components/_keystrokes.scss +56 -0
  129. data/scss/foundation/components/_labels.scss +81 -0
  130. data/scss/foundation/components/_magellan.scss +15 -0
  131. data/scss/foundation/components/_orbit.scss +193 -0
  132. data/scss/foundation/components/_pagination.scss +99 -0
  133. data/scss/foundation/components/_panels.scss +76 -0
  134. data/scss/foundation/components/_pricing-tables.scss +130 -0
  135. data/scss/foundation/components/_progress-bars.scss +68 -0
  136. data/scss/foundation/components/_reveal.scss +131 -0
  137. data/scss/foundation/components/_section.scss +194 -0
  138. data/scss/foundation/components/_side-nav.scss +68 -0
  139. data/scss/foundation/components/_split-buttons.scss +159 -0
  140. data/scss/foundation/components/_sub-nav.scss +67 -0
  141. data/scss/foundation/components/_switch.scss +242 -0
  142. data/scss/foundation/components/_tables.scss +80 -0
  143. data/scss/foundation/components/_thumbs.scss +45 -0
  144. data/scss/foundation/components/_tooltips.scss +113 -0
  145. data/scss/foundation/components/_top-bar.scss +443 -0
  146. data/scss/foundation/components/_type.scss +411 -0
  147. data/scss/foundation/components/_visibility.scss +117 -0
  148. data/scss/normalize.scss +396 -0
  149. data/templates/project/config.rb +26 -0
  150. data/templates/project/index.html +28 -43
  151. data/templates/project/manifest.rb +21 -28
  152. data/templates/project/scss/_settings.scss +4 -243
  153. data/templates/project/scss/app.scss +37 -44
  154. data/templates/project/scss/normalize.scss +396 -0
  155. data/test/stylesheets/styles.css +955 -0
  156. metadata +144 -153
  157. data/config/deploy.rb +0 -42
  158. data/lib/foundation/generators/layout_generator.rb +0 -28
  159. data/scss/foundation/_settings.scss +0 -281
  160. data/scss/foundation/common/_base.scss +0 -4
  161. data/scss/foundation/common/_forms.scss +0 -117
  162. data/scss/foundation/common/_globals.scss +0 -35
  163. data/scss/foundation/common/_ratios.scss +0 -19
  164. data/scss/foundation/common/_typography.scss +0 -104
  165. data/scss/foundation/components/modules/_all.scss +0 -10
  166. data/scss/foundation/components/modules/_buttons.scss +0 -178
  167. data/scss/foundation/components/modules/_clearing.scss +0 -61
  168. data/scss/foundation/components/modules/_joyride.scss +0 -33
  169. data/scss/foundation/components/modules/_mqueries.scss +0 -458
  170. data/scss/foundation/components/modules/_navbar.scss +0 -74
  171. data/scss/foundation/components/modules/_offcanvas.scss +0 -55
  172. data/scss/foundation/components/modules/_orbit.scss +0 -90
  173. data/scss/foundation/components/modules/_reveal.scss +0 -34
  174. data/scss/foundation/components/modules/_tabs.scss +0 -67
  175. data/scss/foundation/components/modules/_topbar.scss +0 -167
  176. data/scss/foundation/components/modules/_ui.scss +0 -292
  177. data/scss/foundation/functions/_all.scss +0 -2
  178. data/scss/foundation/functions/_convert-number-to-word.scss +0 -10
  179. data/scss/foundation/functions/_grid-calc.scss +0 -5
  180. data/scss/foundation/functions/modular-scale.scss +0 -3
  181. data/scss/foundation/mixins/_all.scss +0 -5
  182. data/scss/foundation/mixins/_clearfix.scss +0 -13
  183. data/scss/foundation/mixins/_css-triangle.scss +0 -22
  184. data/scss/foundation/mixins/_font-size.scss +0 -13
  185. data/scss/foundation/mixins/_respond-to.scss +0 -11
  186. data/scss/foundation/mixins/_semantic-grid.scss +0 -66
  187. data/test/buttons.html +0 -189
  188. data/test/clearing.html +0 -85
  189. data/test/config.rb +0 -11
  190. data/test/elements.html +0 -490
  191. data/test/forms.html +0 -371
  192. data/test/grid.html +0 -543
  193. data/test/images/orbit-demo/demo1.jpeg +0 -0
  194. data/test/images/orbit-demo/demo2.jpeg +0 -0
  195. data/test/images/orbit-demo/demo3.jpeg +0 -0
  196. data/test/images/orbit-demo/slider-background.jpeg +0 -0
  197. data/test/index.html +0 -83
  198. data/test/joyride.html +0 -127
  199. data/test/magellan.html +0 -112
  200. data/test/navigation.html +0 -269
  201. data/test/orbit.html +0 -112
  202. data/test/reveal.html +0 -91
  203. data/test/scss/_settings.scss +0 -245
  204. data/test/scss/styles.scss +0 -50
  205. data/test/tabs.html +0 -197
  206. data/test/template.html +0 -52
  207. data/test/topbar-login.html +0 -194
  208. data/test/topbar.html +0 -139
  209. data/test/type.html +0 -188
  210. data/vendor/assets/images/foundation/orbit/bullets.jpg +0 -0
  211. data/vendor/assets/images/foundation/orbit/left-arrow-small.png +0 -0
  212. data/vendor/assets/images/foundation/orbit/left-arrow.png +0 -0
  213. data/vendor/assets/images/foundation/orbit/loading.gif +0 -0
  214. data/vendor/assets/images/foundation/orbit/mask-black.png +0 -0
  215. data/vendor/assets/images/foundation/orbit/pause-black.png +0 -0
  216. data/vendor/assets/images/foundation/orbit/right-arrow-small.png +0 -0
  217. data/vendor/assets/images/foundation/orbit/right-arrow.png +0 -0
  218. data/vendor/assets/images/foundation/orbit/rotator-black.png +0 -0
  219. data/vendor/assets/images/foundation/orbit/timer-black.png +0 -0
  220. data/vendor/assets/javascripts/foundation/app.js +0 -41
  221. data/vendor/assets/javascripts/foundation/index.js +0 -19
  222. data/vendor/assets/javascripts/foundation/jquery.event.move.js +0 -580
  223. data/vendor/assets/javascripts/foundation/jquery.event.swipe.js +0 -130
  224. data/vendor/assets/javascripts/foundation/jquery.foundation.accordion.js +0 -47
  225. data/vendor/assets/javascripts/foundation/jquery.foundation.alerts.js +0 -20
  226. data/vendor/assets/javascripts/foundation/jquery.foundation.buttons.js +0 -83
  227. data/vendor/assets/javascripts/foundation/jquery.foundation.clearing.js +0 -413
  228. data/vendor/assets/javascripts/foundation/jquery.foundation.forms.js +0 -502
  229. data/vendor/assets/javascripts/foundation/jquery.foundation.joyride.js +0 -639
  230. data/vendor/assets/javascripts/foundation/jquery.foundation.magellan.js +0 -96
  231. data/vendor/assets/javascripts/foundation/jquery.foundation.mediaQueryToggle.js +0 -27
  232. data/vendor/assets/javascripts/foundation/jquery.foundation.navigation.js +0 -55
  233. data/vendor/assets/javascripts/foundation/jquery.foundation.orbit.js +0 -919
  234. data/vendor/assets/javascripts/foundation/jquery.foundation.reveal.js +0 -794
  235. data/vendor/assets/javascripts/foundation/jquery.foundation.tabs.js +0 -66
  236. data/vendor/assets/javascripts/foundation/jquery.foundation.tooltips.js +0 -211
  237. data/vendor/assets/javascripts/foundation/jquery.foundation.topbar.js +0 -174
  238. data/vendor/assets/javascripts/foundation/jquery.js +0 -9555
  239. data/vendor/assets/javascripts/foundation/jquery.offcanvas.js +0 -50
@@ -0,0 +1,106 @@
1
+ //
2
+ // Alert Variables
3
+ //
4
+
5
+ // We use this to control alert padding.
6
+ $alert-padding-top: emCalc(11px) !default;
7
+ $alert-padding-left: $alert-padding-top !default;
8
+ $alert-padding-right: $alert-padding-top + emCalc(10px) !default;
9
+ $alert-padding-bottom: $alert-padding-top + emCalc(1px) !default;
10
+
11
+ // We use these to control text style.
12
+ $alert-font-weight: bold !default;
13
+ $alert-font-size: emCalc(14px) !default;
14
+ $alert-font-color: #fff !default;
15
+ $alert-font-color-alt: darken($secondary-color, 60%) !default;
16
+
17
+ // We use this for close hover effect.
18
+ $alert-function-factor: 10% !default;
19
+
20
+ // We use these to control border styles.
21
+ $alert-border-style: solid !default;
22
+ $alert-border-width: 1px !default;
23
+ $alert-border-color: darken($primary-color, $alert-function-factor) !default;
24
+ $alert-bottom-margin: emCalc(20px) !default;
25
+
26
+ // We use these to style the close buttons
27
+ $alert-close-color: #333 !default;
28
+ $alert-close-position: emCalc(5px) !default;
29
+ $alert-close-font-size: emCalc(22px) !default;
30
+ $alert-close-opacity: 0.3 !default;
31
+ $alert-close-opacity-hover: 0.5 !default;
32
+ $alert-close-padding: 5px 4px 4px !default;
33
+
34
+ // We use this to control border radius
35
+ $alert-radius: $global-radius !default;
36
+
37
+ //
38
+ // Alert Mixins
39
+ //
40
+
41
+ // We use this mixin to create a default alert base.
42
+ @mixin alert-base {
43
+ border-style: $alert-border-style;
44
+ border-width: $alert-border-width;
45
+ display: block;
46
+ font-weight: $alert-font-weight;
47
+ margin-bottom: $alert-bottom-margin;
48
+ position: relative;
49
+ padding: $alert-padding-top $alert-padding-right $alert-padding-bottom $alert-padding-left;
50
+ font-size: $alert-font-size;
51
+ }
52
+
53
+ // We use this mixin to add alert styles
54
+ @mixin alert-style($bg:$primary-color) {
55
+
56
+ // This find the lightness percentage of the background color.
57
+ $bg-lightness: lightness($bg);
58
+
59
+ // We control which background color and border come through.
60
+ background-color: $bg;
61
+ border-color: darken($bg, $alert-function-factor);
62
+
63
+ // We control the text color for you based on the background color.
64
+ @if $bg-lightness > 70% { color: $alert-font-color-alt; }
65
+ @else { color: $alert-font-color; }
66
+
67
+ }
68
+
69
+ // We use this to create the close button.
70
+ @mixin alert-close {
71
+ font-size: $alert-close-font-size;
72
+ padding: $alert-close-padding;
73
+ line-height: 0;
74
+ position: absolute;
75
+ top: $alert-close-position + emCalc(2px);
76
+ #{$default-opposite}: $alert-close-position;
77
+ color: $alert-close-color;
78
+ opacity: $alert-close-opacity;
79
+ &:hover,
80
+ &:focus { opacity: $alert-close-opacity-hover; }
81
+ }
82
+
83
+ // We use this to quickly create alerts with a single mixin.
84
+ @mixin alert($bg:$primary-color, $radius:false) {
85
+ @include alert-base;
86
+ @include alert-style($bg);
87
+ @include radius($radius);
88
+ }
89
+
90
+ @if $include-html-classes {
91
+
92
+ /* Foundation Alerts */
93
+ .alert-box {
94
+ @include alert;
95
+
96
+ .close { @include alert-close; }
97
+
98
+ &.radius { @include radius($alert-radius); }
99
+ &.round { @include radius($global-rounded); }
100
+
101
+ &.success { @include alert-style($success-color); }
102
+ &.alert { @include alert-style($alert-color); }
103
+ &.secondary { @include alert-style($secondary-color); }
104
+ }
105
+
106
+ }
@@ -0,0 +1,63 @@
1
+ //
2
+ // Block Grid Variables
3
+ //
4
+
5
+ // We use this to control the maximum number of block grid elements per row
6
+ $block-grid-elements: 12 !default;
7
+ $block-grid-default-spacing: 10px !default;
8
+
9
+
10
+ //
11
+ // Block Grid Mixins
12
+ //
13
+
14
+ // We use this mixin to create different block-grids. You can apply per-row and spacing options.
15
+ // Setting $base-style to false will ommit default styles.
16
+ @mixin block-grid($per-row:false, $spacing:$block-grid-default-spacing, $base-style:true) {
17
+
18
+ @if $base-style {
19
+ display: block;
20
+ overflow: hidden;
21
+ padding: 0;
22
+ margin: 0 (-$spacing);
23
+
24
+ &>li {
25
+ display: block;
26
+ height: auto;
27
+ float: $default-float;
28
+ padding: 0 $spacing $spacing;
29
+ }
30
+ }
31
+
32
+ @if $per-row {
33
+ &>li {
34
+ width: 100%/$per-row;
35
+ padding: 0 $spacing $spacing;
36
+ }
37
+ &:nth-of-type(#{$per-row}n+1) { clear: both; }
38
+ }
39
+
40
+ }
41
+
42
+
43
+ /* Foundation Block Grids for below small breakpoint */
44
+ @media only screen {
45
+ [class*="block-grid-"] { @include block-grid; }
46
+
47
+ @for $i from 2 through $block-grid-elements {
48
+ .small-block-grid-#{($i)} {
49
+ @include block-grid($i,$block-grid-default-spacing,false);
50
+ }
51
+ }
52
+ }
53
+
54
+ /* Foundation Block Grids for above small breakpoint */
55
+ @media #{$small} {
56
+ @for $i from 2 through $block-grid-elements {
57
+ .large-block-grid-#{($i)} {
58
+ @if $i == 2 { @include block-grid(2,15px,false); }
59
+ @else if $i == 3 { @include block-grid(3,12px,false); }
60
+ @else { @include block-grid($i,$block-grid-default-spacing,false); }
61
+ }
62
+ }
63
+ }
@@ -0,0 +1,117 @@
1
+ //
2
+ // Breadcrumb Variables
3
+ //
4
+
5
+ // We use this to set the background color for the breadcrumb container.
6
+ $crumb-bg: lighten($secondary-color, 5%) !default;
7
+
8
+ // We use these to set the padding around the breadcrumbs.
9
+ $crumb-padding: emCalc(6px) emCalc(14px) emCalc(9px) !default;
10
+ $crumb-side-padding: emCalc(12px) !default;
11
+
12
+ // We use these to control border styles.
13
+ $crumb-function-factor: 10% !default;
14
+ $crumb-border-size: 1px !default;
15
+ $crumb-border-style: solid !default;
16
+ $crumb-border-color: darken($crumb-bg, $crumb-function-factor) !default;
17
+ $crumb-radius: $button-radius !default;
18
+
19
+ // We use these to set various text styles for breadcrumbs.
20
+ $crumb-font-size: emCalc(11px) !default;
21
+ $crumb-font-color: $primary-color !default;
22
+ $crumb-font-color-current: #333 !default;
23
+ $crumb-font-color-unavailable: #999 !default;
24
+ $crumb-font-transform: uppercase !default;
25
+ $crumb-link-decor: underline !default;
26
+
27
+ // We use these to control the slash between breadcrumbs
28
+ $crumb-slash-color: #aaa !default;
29
+ $crumb-slash: "/" !default;
30
+
31
+ //
32
+ // Breakcrumb Mixins
33
+ //
34
+
35
+ // We use this mixin to create a container around our breadcrumbs
36
+ @mixin crumb-container {
37
+ display: block;
38
+ padding: $crumb-padding;
39
+ overflow: hidden;
40
+ margin-#{$default-float}: 0;
41
+ list-style: none;
42
+ border-style: $crumb-border-style;
43
+ border-width: $crumb-border-size;
44
+
45
+ // We control which background color and border come through.
46
+ background-color: $crumb-bg;
47
+ border-color: $crumb-border-color;
48
+ }
49
+
50
+ // We use this mixin to create breadcrumb styles from list items.
51
+ @mixin crumbs {
52
+
53
+ // A normal state will make the links look and act like clickable breadcrumbs.
54
+ margin: 0;
55
+ padding: 0 $crumb-side-padding 0 0;
56
+ float: $default-float;
57
+
58
+ &:hover a,
59
+ &:focus a { text-decoration: $crumb-link-decor; }
60
+
61
+ a,
62
+ span {
63
+ font-size: $crumb-font-size;
64
+ padding-#{$default-float}: $crumb-side-padding;
65
+ text-transform: $crumb-font-transform;
66
+ color: $crumb-font-color;
67
+ }
68
+
69
+ // Current is for the link of the current page
70
+ &.current {
71
+ a {
72
+ cursor: default;
73
+ color: $crumb-font-color-current;
74
+ }
75
+
76
+ &:hover a,
77
+ &:focus a { text-decoration: none; }
78
+ }
79
+
80
+ // Unavailable removed color and link styles so it looks inactive.
81
+ &.unavailable {
82
+ a { color: $crumb-font-color-unavailable; }
83
+
84
+ &:hover a,
85
+ a:focus {
86
+ text-decoration: none;
87
+ color: $crumb-font-color-unavailable;
88
+ cursor: default;
89
+ }
90
+ }
91
+
92
+ &:before {
93
+ content: "#{$crumb-slash}";
94
+ color: $crumb-slash-color;
95
+ position: relative;
96
+ top: 1px;
97
+ }
98
+ &:first-child a,
99
+ &:first-child span { padding-#{$default-float}: 0; }
100
+ &:first-child:before { content: ""; }
101
+
102
+ }
103
+
104
+
105
+ @if $include-html-classes {
106
+
107
+ /* Breadcrumbs */
108
+ .breadcrumbs {
109
+ @include crumb-container;
110
+ @include radius($crumb-radius);
111
+
112
+ li {
113
+ @include crumbs;
114
+ }
115
+ }
116
+
117
+ }
@@ -0,0 +1,59 @@
1
+ //
2
+ // Button Group Mixins
3
+ //
4
+
5
+ // We use this to add styles for a button group container
6
+ @mixin button-group-container($styles:true) {
7
+ @if $styles {
8
+ list-style: none;
9
+ margin: 0 0 $button-margin-bottom;
10
+ @include clearfix();
11
+ }
12
+ }
13
+
14
+ // We use this to control styles for button groups
15
+ @mixin button-group-style($radius:false, $even:false, $float:$default-float) {
16
+
17
+ // We use this to control the flow, or remove those styles completely.
18
+ @if $float {
19
+ margin: 0 0 0 -1px;
20
+ float: $float;
21
+ // Make sure the first child doesn't get the negative margin.
22
+ &:first-child { margin-#{$default-float}: 0; }
23
+ }
24
+
25
+ // We use these to control left and right radius on first/last buttons in the group.
26
+ @if $radius == true {
27
+ &:first-child > a { @include side-radius($default-float, $button-radius); }
28
+ &:last-child > a { @include side-radius($default-opposite, $button-radius); }
29
+ }
30
+ @else if $radius {
31
+ &:first-child > a { @include side-radius($default-float, $radius); }
32
+ &:last-child > a { @include side-radius($default-opposite, $radius); }
33
+ }
34
+
35
+ // We use this to make the buttons even width across their container
36
+ @if $even {
37
+ width: percentage((100/$even) / 100);
38
+ .button { width: 100%; }
39
+ }
40
+
41
+ }
42
+
43
+ // Only include these CSS classes if $include-html-classes: true
44
+ @if $include-html-classes {
45
+
46
+ /* Button Groups */
47
+ .button-group { @include button-group-container;
48
+
49
+ li { @include button-group-style(); }
50
+
51
+ &.radius li { @include button-group-style($radius:$button-radius, $float:null); }
52
+ &.round li { @include button-group-style($radius:1000px, $float:null); }
53
+
54
+ @for $i from 2 through 8 {
55
+ &.even#{-$i} li { @include button-group-style($even:3, $float:null); }
56
+ }
57
+ }
58
+
59
+ }
@@ -0,0 +1,217 @@
1
+ //
2
+ // Button Variables
3
+ //
4
+
5
+ // We use these to build padding for buttons.
6
+ $button-med: emCalc(12px) !default;
7
+ $button-tny: emCalc(7px) !default;
8
+ $button-sml: emCalc(9px) !default;
9
+ $button-lrg: emCalc(16px) !default;
10
+
11
+ // We use this to control the display property.
12
+ $button-display: inline-block !default;
13
+ $button-margin-bottom: emCalc(20px) !default;
14
+
15
+ // We use these to control button text styles.
16
+ $button-font-color: #fff !default;
17
+ $button-font-color-alt: #333 !default;
18
+ $button-font-med: emCalc(16px) !default;
19
+ $button-font-tny: emCalc(11px) !default;
20
+ $button-font-sml: emCalc(13px) !default;
21
+ $button-font-lrg: emCalc(20px) !default;
22
+ $button-font-weight: bold !default;
23
+ $button-font-align: center !default;
24
+
25
+ // We use these to control various hover effects.
26
+ $button-function-factor: 10% !default;
27
+
28
+ // We use these to control button border styles.
29
+ $button-border-width: 1px !default;
30
+ $button-border-style: solid !default;
31
+ $button-border-color: darken($primary-color, $button-function-factor) !default;
32
+
33
+ // We use this to set the default radius used throughout the core.
34
+ $button-radius: $global-radius !default;
35
+
36
+ // We use this to set default opacity for disabled buttons.
37
+ $button-disabled-opacity: 0.6 !default;
38
+
39
+
40
+ //
41
+ // Button Mixins
42
+ //
43
+
44
+ // We use this mixin to create a default button base.
45
+ @mixin button-base($style:true, $display:$button-display) {
46
+ @if $style {
47
+ border-style: $button-border-style;
48
+ border-width: $button-border-width;
49
+ cursor: pointer;
50
+ font-family: inherit;
51
+ font-weight: $button-font-weight;
52
+ line-height: 1;
53
+ margin: 0 0 $button-margin-bottom;
54
+ position: relative;
55
+ text-decoration: none;
56
+ text-align: $button-font-align;
57
+ }
58
+ @if $display { display: $display; }
59
+ }
60
+
61
+ // We use this mixin to add button size styles
62
+ @mixin button-size($padding:$button-med, $full-width:false, $is-input:false) {
63
+
64
+ // We control which padding styles come through,
65
+ // these can be turned off by setting $padding:false
66
+ @if $padding {
67
+ padding-top: $padding;
68
+ padding-right: $padding * 2;
69
+ padding-bottom: $padding + emCalc(1px);
70
+ padding-left: $padding * 2;
71
+
72
+ // We control the font-size based on mixin input.
73
+ @if $padding == $button-med { font-size: $button-font-med; }
74
+ @else if $padding == $button-tny { font-size: $button-font-tny; }
75
+ @else if $padding == $button-sml { font-size: $button-font-sml; }
76
+ @else if $padding == $button-lrg { font-size: $button-font-lrg; }
77
+ @else { font-size: $padding - emCalc(2px); }
78
+ }
79
+
80
+ // We can set $full-width:true to remove side padding extend width.
81
+ @if $full-width {
82
+ padding-top: $padding;
83
+ padding-right: 0px;
84
+ padding-bottom: $padding + emCalc(1px);
85
+ padding-left: 0px;
86
+ width: 100%;
87
+ }
88
+
89
+ // <input>'s and <button>'s take on strange padding. We added this to help fix that.
90
+ @if $is-input == $button-lrg {
91
+ padding-top: $is-input + emCalc(.5px);
92
+ padding-bottom: $is-input + emCalc(.5px);
93
+ }
94
+ @else if $is-input {
95
+ padding-top: $is-input + emCalc(1px);
96
+ padding-bottom: $is-input;
97
+ }
98
+ }
99
+
100
+ // We use this mixin to add button color styles
101
+ @mixin button-style($bg:$primary-color, $radius:false, $disabled:false) {
102
+
103
+ // We control which background styles are used,
104
+ // these can be removed by setting $bg:false
105
+ @if $bg {
106
+ // This find the lightness percentage of the background color.
107
+ $bg-lightness: lightness($bg);
108
+
109
+ background-color: $bg;
110
+ border-color: darken($bg, $button-function-factor);
111
+ &:hover,
112
+ &:focus { background-color: darken($bg, $button-function-factor); }
113
+
114
+ // We control the text color for you based on the background color.
115
+ @if $bg-lightness > 70% {
116
+ color: $button-font-color-alt;
117
+ &:hover,
118
+ &:focus { color: $button-font-color-alt; }
119
+ }
120
+ @else {
121
+ color: $button-font-color;
122
+ &:hover,
123
+ &:focus { color: $button-font-color; }
124
+ }
125
+ }
126
+
127
+ // We can set $disabled:true to create a disabled transparent button.
128
+ @if $disabled {
129
+ cursor: default;
130
+ opacity: $button-disabled-opacity;
131
+ -webkit-box-shadow: none;
132
+ box-shadow: none;
133
+ &:hover,
134
+ &:focus { background-color: $bg; }
135
+ }
136
+
137
+ // We can control how much button radius us used.
138
+ @if $radius == true { @include radius($button-radius); }
139
+ @else if $radius { @include radius($radius); }
140
+
141
+ }
142
+
143
+ // We use this to quickly create buttons with a single mixin. As @jaredhardy puts it, "the kitchen sink mixin"
144
+ @mixin button($padding:$button-med, $bg:$primary-color, $radius:false, $full-width:false, $disabled:false, $is-input:false, $is-prefix:false) {
145
+ @include button-base;
146
+ @include button-size($padding, $full-width, $is-input);
147
+ @include button-style($bg, $radius, $disabled);
148
+ }
149
+
150
+
151
+ //
152
+ // Button Classes
153
+ //
154
+
155
+ // Only include these classes if the variable is true, otherwise they'll be left out.
156
+ @if $include-html-classes {
157
+
158
+ // Default styles applied outside of media query
159
+ .button {
160
+ @include button-base($display:block);
161
+ @include button-size;
162
+ @include button-style;
163
+
164
+ &.secondary { @include button-style($bg:$secondary-color); }
165
+ &.success { @include button-style($bg:$success-color); }
166
+ &.alert { @include button-style($bg:$alert-color); }
167
+
168
+ &.large { @include button-size($padding:$button-lrg); }
169
+ &.small { @include button-size($padding:$button-sml); }
170
+ &.tiny { @include button-size($padding:$button-tny); }
171
+ &.expand { @include button-size($padding:false, $full-width:true); }
172
+
173
+ &.left-align { text-align: left; text-indent: emCalc(12px); }
174
+ &.right-align { text-align: right; padding-right: emCalc(12px); }
175
+
176
+ &.disabled, &[disabled] { @include button-style($bg:$primary-color, $disabled:true);
177
+ &.secondary { @include button-style($bg:$secondary-color, $disabled:true); }
178
+ &.success { @include button-style($bg:$success-color, $disabled:true); }
179
+ &.alert { @include button-style($bg:$alert-color, $disabled:true); }
180
+ }
181
+
182
+ }
183
+
184
+ input.button,
185
+ button.button {
186
+ @include button-size($padding:false, $is-input:$button-med);
187
+ &.tiny { @include button-size($padding:false, $is-input:$button-tny); }
188
+ &.small { @include button-size($padding:false, $is-input:$button-sml); }
189
+ &.large { @include button-size($padding:false, $is-input:$button-lrg); }
190
+ }
191
+
192
+ // Styles for any browser or device that support media queries
193
+ @media only screen {
194
+
195
+ .button {
196
+ @include inset-shadow();
197
+ @include single-transition(background-color);
198
+
199
+ &.large { @include button-size($padding:false, $full-width:false); }
200
+ &.small { @include button-size($padding:false, $full-width:false); }
201
+ &.tiny { @include button-size($padding:false, $full-width:false); }
202
+
203
+ &.radius { @include button-style($bg:false, $radius:true); }
204
+ &.round { @include button-style($bg:false, $radius:1000px); }
205
+ }
206
+
207
+ }
208
+
209
+ // Additional styles for screens larger than 768px
210
+ @media #{$small} {
211
+ .button {
212
+ @include button-base($style:false, $display:inline-block);
213
+ @include button-size($padding:false, $full-width:false);
214
+ }
215
+ }
216
+
217
+ }