foundation-rails 5.0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +17 -0
- data/Gemfile +4 -0
- data/LICENSE.txt +22 -0
- data/README.md +29 -0
- data/Rakefile +1 -0
- data/app/controllers/foundation/rails/styleguide_controller.rb +10 -0
- data/app/views/foundation/rails/styleguide/show.html.erb +134 -0
- data/config/routes.rb +3 -0
- data/foundation-rails.gemspec +25 -0
- data/lib/foundation-rails.rb +1 -0
- data/lib/foundation/rails.rb +3 -0
- data/lib/foundation/rails/engine.rb +7 -0
- data/lib/foundation/rails/generators/install_generator.rb +56 -0
- data/lib/foundation/rails/templates/application.html.erb +19 -0
- data/lib/foundation/rails/templates/application.html.haml +18 -0
- data/lib/foundation/rails/templates/application.html.slim +17 -0
- data/lib/foundation/rails/version.rb +5 -0
- data/test/dummy/.gitignore +16 -0
- data/test/dummy/Gemfile +47 -0
- data/test/dummy/README.rdoc +28 -0
- data/test/dummy/Rakefile +6 -0
- data/test/dummy/app/assets/images/.keep +0 -0
- data/test/dummy/app/assets/javascripts/application.js +8 -0
- data/test/dummy/app/assets/stylesheets/application.css +4 -0
- data/test/dummy/app/assets/stylesheets/foundation_and_overrides.scss +4 -0
- data/test/dummy/app/controllers/application_controller.rb +5 -0
- data/test/dummy/app/controllers/concerns/.keep +0 -0
- data/test/dummy/app/controllers/styleguide_controller.rb +4 -0
- data/test/dummy/app/helpers/application_helper.rb +2 -0
- data/test/dummy/app/helpers/styleguide_helper.rb +2 -0
- data/test/dummy/app/mailers/.keep +0 -0
- data/test/dummy/app/models/.keep +0 -0
- data/test/dummy/app/models/concerns/.keep +0 -0
- data/test/dummy/app/views/layouts/application.html.erb +19 -0
- data/test/dummy/app/views/styleguide/show.html.erb +109 -0
- data/test/dummy/bin/bundle +3 -0
- data/test/dummy/bin/rails +4 -0
- data/test/dummy/bin/rake +4 -0
- data/test/dummy/config.ru +4 -0
- data/test/dummy/config/application.rb +23 -0
- data/test/dummy/config/boot.rb +4 -0
- data/test/dummy/config/database.yml +25 -0
- data/test/dummy/config/environment.rb +5 -0
- data/test/dummy/config/environments/development.rb +29 -0
- data/test/dummy/config/environments/production.rb +80 -0
- data/test/dummy/config/environments/test.rb +36 -0
- data/test/dummy/config/initializers/backtrace_silencers.rb +7 -0
- data/test/dummy/config/initializers/filter_parameter_logging.rb +4 -0
- data/test/dummy/config/initializers/inflections.rb +16 -0
- data/test/dummy/config/initializers/mime_types.rb +5 -0
- data/test/dummy/config/initializers/secret_token.rb +12 -0
- data/test/dummy/config/initializers/session_store.rb +3 -0
- data/test/dummy/config/initializers/wrap_parameters.rb +14 -0
- data/test/dummy/config/locales/en.yml +23 -0
- data/test/dummy/config/routes.rb +3 -0
- data/test/dummy/db/seeds.rb +7 -0
- data/test/dummy/lib/assets/.keep +0 -0
- data/test/dummy/lib/tasks/.keep +0 -0
- data/test/dummy/log/.keep +0 -0
- data/test/dummy/public/404.html +58 -0
- data/test/dummy/public/422.html +58 -0
- data/test/dummy/public/500.html +57 -0
- data/test/dummy/public/favicon.ico +0 -0
- data/test/dummy/public/robots.txt +5 -0
- data/test/dummy/test/controllers/.keep +0 -0
- data/test/dummy/test/controllers/styleguide_controller_test.rb +9 -0
- data/test/dummy/test/fixtures/.keep +0 -0
- data/test/dummy/test/helpers/.keep +0 -0
- data/test/dummy/test/helpers/styleguide_helper_test.rb +4 -0
- data/test/dummy/test/integration/.keep +0 -0
- data/test/dummy/test/mailers/.keep +0 -0
- data/test/dummy/test/models/.keep +0 -0
- data/test/dummy/test/test_helper.rb +15 -0
- data/test/dummy/vendor/assets/javascripts/.keep +0 -0
- data/test/dummy/vendor/assets/stylesheets/.keep +0 -0
- data/vendor/_settings.scss +992 -0
- data/vendor/assets/javascripts/foundation.js +15 -0
- data/vendor/assets/javascripts/foundation/foundation.abide.js +201 -0
- data/vendor/assets/javascripts/foundation/foundation.accordion.js +41 -0
- data/vendor/assets/javascripts/foundation/foundation.alert.js +34 -0
- data/vendor/assets/javascripts/foundation/foundation.clearing.js +450 -0
- data/vendor/assets/javascripts/foundation/foundation.dropdown.js +184 -0
- data/vendor/assets/javascripts/foundation/foundation.interchange.js +304 -0
- data/vendor/assets/javascripts/foundation/foundation.joyride.js +839 -0
- data/vendor/assets/javascripts/foundation/foundation.js +416 -0
- data/vendor/assets/javascripts/foundation/foundation.magellan.js +118 -0
- data/vendor/assets/javascripts/foundation/foundation.offcanvas.js +37 -0
- data/vendor/assets/javascripts/foundation/foundation.orbit.js +434 -0
- data/vendor/assets/javascripts/foundation/foundation.reveal.js +347 -0
- data/vendor/assets/javascripts/foundation/foundation.tab.js +37 -0
- data/vendor/assets/javascripts/foundation/foundation.tooltip.js +202 -0
- data/vendor/assets/javascripts/foundation/foundation.topbar.js +380 -0
- data/vendor/assets/javascripts/vendor/modernizr.js +4 -0
- data/vendor/assets/stylesheets/foundation.scss +38 -0
- data/vendor/assets/stylesheets/foundation/_functions.scss +75 -0
- data/vendor/assets/stylesheets/foundation/_settings.scss +992 -0
- data/vendor/assets/stylesheets/foundation/components/_accordion.scss +49 -0
- data/vendor/assets/stylesheets/foundation/components/_alert-boxes.scss +113 -0
- data/vendor/assets/stylesheets/foundation/components/_block-grid.scss +83 -0
- data/vendor/assets/stylesheets/foundation/components/_breadcrumbs.scss +123 -0
- data/vendor/assets/stylesheets/foundation/components/_button-groups.scss +97 -0
- data/vendor/assets/stylesheets/foundation/components/_buttons.scss +234 -0
- data/vendor/assets/stylesheets/foundation/components/_clearing.scss +233 -0
- data/vendor/assets/stylesheets/foundation/components/_dropdown-buttons.scss +125 -0
- data/vendor/assets/stylesheets/foundation/components/_dropdown.scss +159 -0
- data/vendor/assets/stylesheets/foundation/components/_flex-video.scss +47 -0
- data/vendor/assets/stylesheets/foundation/components/_forms.scss +472 -0
- data/vendor/assets/stylesheets/foundation/components/_functions.scss +70 -0
- data/vendor/assets/stylesheets/foundation/components/_global.scss +387 -0
- data/vendor/assets/stylesheets/foundation/components/_grid.scss +234 -0
- data/vendor/assets/stylesheets/foundation/components/_inline-lists.scss +52 -0
- data/vendor/assets/stylesheets/foundation/components/_joyride.scss +220 -0
- data/vendor/assets/stylesheets/foundation/components/_keystrokes.scss +57 -0
- data/vendor/assets/stylesheets/foundation/components/_labels.scss +100 -0
- data/vendor/assets/stylesheets/foundation/components/_magellan.scss +30 -0
- data/vendor/assets/stylesheets/foundation/components/_offcanvas.scss +360 -0
- data/vendor/assets/stylesheets/foundation/components/_orbit.scss +353 -0
- data/vendor/assets/stylesheets/foundation/components/_pagination.scss +145 -0
- data/vendor/assets/stylesheets/foundation/components/_panels.scss +87 -0
- data/vendor/assets/stylesheets/foundation/components/_pricing-tables.scss +146 -0
- data/vendor/assets/stylesheets/foundation/components/_progress-bars.scss +75 -0
- data/vendor/assets/stylesheets/foundation/components/_reveal.scss +165 -0
- data/vendor/assets/stylesheets/foundation/components/_side-nav.scss +83 -0
- data/vendor/assets/stylesheets/foundation/components/_split-buttons.scss +187 -0
- data/vendor/assets/stylesheets/foundation/components/_sub-nav.scss +118 -0
- data/vendor/assets/stylesheets/foundation/components/_switch.scss +314 -0
- data/vendor/assets/stylesheets/foundation/components/_tables.scss +93 -0
- data/vendor/assets/stylesheets/foundation/components/_tabs.scss +95 -0
- data/vendor/assets/stylesheets/foundation/components/_thumbs.scss +71 -0
- data/vendor/assets/stylesheets/foundation/components/_tooltips.scss +121 -0
- data/vendor/assets/stylesheets/foundation/components/_top-bar.scss +590 -0
- data/vendor/assets/stylesheets/foundation/components/_type.scss +447 -0
- data/vendor/assets/stylesheets/foundation/components/_visibility.scss +661 -0
- data/vendor/assets/stylesheets/normalize.scss +410 -0
- metadata +292 -0
@@ -0,0 +1,49 @@
|
|
1
|
+
@import "global";
|
2
|
+
@import "grid";
|
3
|
+
|
4
|
+
//
|
5
|
+
// @variables
|
6
|
+
//
|
7
|
+
|
8
|
+
$include-html-accordion-classes: $include-html-classes !default;
|
9
|
+
|
10
|
+
$accordion-navigation-padding: rem-calc(16) !default;
|
11
|
+
$accordion-navigation-bg-color: #efefef !default;
|
12
|
+
$accordion-navigation-hover-bg-color: darken($accordion-navigation-bg-color, 5%) !default;
|
13
|
+
$accordion-navigation-active-bg-color: darken($accordion-navigation-bg-color, 3%) !default;
|
14
|
+
$accordion-navigation-font-color: #222 !default;
|
15
|
+
$accordion-navigation-font-size: rem-calc(16) !default;
|
16
|
+
$accordion-navigation-font-family: $body-font-family !default;
|
17
|
+
|
18
|
+
$accordion-content-padding: $column-gutter/2 !default;
|
19
|
+
$accordion-content-active-bg-color: #fff !default;
|
20
|
+
|
21
|
+
@include exports("accordion") {
|
22
|
+
@if $include-html-accordion-classes {
|
23
|
+
.accordion {
|
24
|
+
@include clearfix; margin-bottom: 0;
|
25
|
+
dd {
|
26
|
+
display: block;
|
27
|
+
margin-bottom: 0 !important;
|
28
|
+
&.active a { background: $accordion-navigation-active-bg-color; }
|
29
|
+
> a {
|
30
|
+
background: $accordion-navigation-bg-color;
|
31
|
+
color: $accordion-navigation-font-color;
|
32
|
+
padding: $accordion-navigation-padding;
|
33
|
+
display: block;
|
34
|
+
font-family: $body-font-family;
|
35
|
+
font-size: $accordion-navigation-font-size;
|
36
|
+
&:hover { background: $accordion-navigation-hover-bg-color; }
|
37
|
+
}
|
38
|
+
}
|
39
|
+
.content {
|
40
|
+
display: none;
|
41
|
+
padding: $accordion-content-padding;
|
42
|
+
&.active {
|
43
|
+
display: block;
|
44
|
+
background: $accordion-content-active-bg-color;
|
45
|
+
}
|
46
|
+
}
|
47
|
+
}
|
48
|
+
}
|
49
|
+
}
|
@@ -0,0 +1,113 @@
|
|
1
|
+
@import "global";
|
2
|
+
|
3
|
+
//
|
4
|
+
// Alert Box Variables
|
5
|
+
//
|
6
|
+
$include-html-alert-classes: $include-html-classes !default;
|
7
|
+
|
8
|
+
// We use this to control alert padding.
|
9
|
+
$alert-padding-top: rem-calc(14) !default;
|
10
|
+
$alert-padding-default-float: $alert-padding-top !default;
|
11
|
+
$alert-padding-opposite-direction: $alert-padding-top + rem-calc(10) !default;
|
12
|
+
$alert-padding-bottom: $alert-padding-top !default;
|
13
|
+
|
14
|
+
// We use these to control text style.
|
15
|
+
$alert-font-weight: normal !default;
|
16
|
+
$alert-font-size: rem-calc(13) !default;
|
17
|
+
$alert-font-color: #fff !default;
|
18
|
+
$alert-font-color-alt: darken($secondary-color, 60%) !default;
|
19
|
+
|
20
|
+
// We use this for close hover effect.
|
21
|
+
$alert-function-factor: 5% !default;
|
22
|
+
|
23
|
+
// We use these to control border styles.
|
24
|
+
$alert-border-style: solid !default;
|
25
|
+
$alert-border-width: 1px !default;
|
26
|
+
$alert-border-color: darken($primary-color, $alert-function-factor) !default;
|
27
|
+
$alert-bottom-margin: rem-calc(20) !default;
|
28
|
+
|
29
|
+
// We use these to style the close buttons
|
30
|
+
$alert-close-color: #333 !default;
|
31
|
+
$alert-close-position: rem-calc(5) !default;
|
32
|
+
$alert-close-font-size: rem-calc(22) !default;
|
33
|
+
$alert-close-opacity: 0.3 !default;
|
34
|
+
$alert-close-opacity-hover: 0.5 !default;
|
35
|
+
$alert-close-padding: 9px 6px 4px !default;
|
36
|
+
|
37
|
+
// We use this to control border radius
|
38
|
+
$alert-radius: $global-radius !default;
|
39
|
+
|
40
|
+
//
|
41
|
+
// Alert Mixins
|
42
|
+
//
|
43
|
+
|
44
|
+
// We use this mixin to create a default alert base.
|
45
|
+
@mixin alert-base {
|
46
|
+
border-style: $alert-border-style;
|
47
|
+
border-width: $alert-border-width;
|
48
|
+
display: block;
|
49
|
+
font-weight: $alert-font-weight;
|
50
|
+
margin-bottom: $alert-bottom-margin;
|
51
|
+
position: relative;
|
52
|
+
padding: $alert-padding-top $alert-padding-opposite-direction $alert-padding-bottom $alert-padding-default-float;
|
53
|
+
font-size: $alert-font-size;
|
54
|
+
}
|
55
|
+
|
56
|
+
// We use this mixin to add alert styles
|
57
|
+
//
|
58
|
+
// $bg - The background of the alert. Default: $primary-color.
|
59
|
+
@mixin alert-style($bg:$primary-color) {
|
60
|
+
|
61
|
+
// This find the lightness percentage of the background color.
|
62
|
+
$bg-lightness: lightness($bg);
|
63
|
+
|
64
|
+
// We control which background color and border come through.
|
65
|
+
background-color: $bg;
|
66
|
+
border-color: darken($bg, $alert-function-factor);
|
67
|
+
|
68
|
+
// We control the text color for you based on the background color.
|
69
|
+
@if $bg-lightness > 70% { color: $alert-font-color-alt; }
|
70
|
+
@else { color: $alert-font-color; }
|
71
|
+
|
72
|
+
}
|
73
|
+
|
74
|
+
// We use this to create the close button.
|
75
|
+
@mixin alert-close {
|
76
|
+
font-size: $alert-close-font-size;
|
77
|
+
padding: $alert-close-padding;
|
78
|
+
line-height: 0;
|
79
|
+
position: absolute;
|
80
|
+
top: $alert-close-position + rem-calc(2);
|
81
|
+
#{$opposite-direction}: $alert-close-position;
|
82
|
+
color: $alert-close-color;
|
83
|
+
opacity: $alert-close-opacity;
|
84
|
+
&:hover,
|
85
|
+
&:focus { opacity: $alert-close-opacity-hover; }
|
86
|
+
}
|
87
|
+
|
88
|
+
// We use this to quickly create alerts with a single mixin.
|
89
|
+
//
|
90
|
+
// $bg - Background of alert. Default: $primary-color.
|
91
|
+
// $radius - Radius of alert box. Default: false.
|
92
|
+
@mixin alert($bg:$primary-color, $radius:false) {
|
93
|
+
@include alert-base;
|
94
|
+
@include alert-style($bg);
|
95
|
+
@include radius($radius);
|
96
|
+
}
|
97
|
+
|
98
|
+
@include exports("alert-box") {
|
99
|
+
@if $include-html-alert-classes {
|
100
|
+
.alert-box {
|
101
|
+
@include alert;
|
102
|
+
|
103
|
+
.close { @include alert-close; }
|
104
|
+
|
105
|
+
&.radius { @include radius($alert-radius); }
|
106
|
+
&.round { @include radius($global-rounded); }
|
107
|
+
|
108
|
+
&.success { @include alert-style($success-color); }
|
109
|
+
&.alert { @include alert-style($alert-color); }
|
110
|
+
&.secondary { @include alert-style($secondary-color); }
|
111
|
+
}
|
112
|
+
}
|
113
|
+
}
|
@@ -0,0 +1,83 @@
|
|
1
|
+
@import "global";
|
2
|
+
|
3
|
+
//
|
4
|
+
// Block Grid Variables
|
5
|
+
//
|
6
|
+
$include-html-grid-classes: $include-html-classes !default;
|
7
|
+
|
8
|
+
// We use this to control the maximum number of block grid elements per row
|
9
|
+
$block-grid-elements: 12 !default;
|
10
|
+
$block-grid-default-spacing: rem-calc(20) !default;
|
11
|
+
|
12
|
+
// Enables media queries for block-grid classes. Set to false if writing semantic HTML.
|
13
|
+
$block-grid-media-queries: true !default;
|
14
|
+
|
15
|
+
//
|
16
|
+
// Block Grid Mixins
|
17
|
+
//
|
18
|
+
|
19
|
+
// Create a custom block grid
|
20
|
+
//
|
21
|
+
// $per-row - # of items to display per row. Default: false.
|
22
|
+
// $spacing - # of ems to use as padding on each block item. Default: rem-calc(20).
|
23
|
+
// $base-style - Apply a base style to block grid. Default: true.
|
24
|
+
@mixin block-grid(
|
25
|
+
$per-row:false,
|
26
|
+
$spacing:$block-grid-default-spacing,
|
27
|
+
$base-style:true) {
|
28
|
+
|
29
|
+
@if $base-style {
|
30
|
+
display: block;
|
31
|
+
padding: 0;
|
32
|
+
margin: 0 (-$spacing/2);
|
33
|
+
@include clearfix;
|
34
|
+
|
35
|
+
&>li {
|
36
|
+
display: inline;
|
37
|
+
height: auto;
|
38
|
+
float: $default-float;
|
39
|
+
padding: 0 ($spacing/2) $spacing;
|
40
|
+
}
|
41
|
+
}
|
42
|
+
|
43
|
+
@if $per-row {
|
44
|
+
&>li {
|
45
|
+
width: 100%/$per-row;
|
46
|
+
padding: 0 ($spacing/2) $spacing;
|
47
|
+
|
48
|
+
&:nth-of-type(n) { clear: none; }
|
49
|
+
&:nth-of-type(#{$per-row}n+1) { clear: both; }
|
50
|
+
}
|
51
|
+
}
|
52
|
+
|
53
|
+
}
|
54
|
+
|
55
|
+
// Generate presentational markup for block grid.
|
56
|
+
//
|
57
|
+
// $size - Name of class to use, i.e. "large" will generate .large-block-grid-1, .large-block-grid-2, etc.
|
58
|
+
@mixin block-grid-html-classes($size) {
|
59
|
+
@for $i from 1 through $block-grid-elements {
|
60
|
+
.#{$size}-block-grid-#{($i)} {
|
61
|
+
@include block-grid($i,$block-grid-default-spacing,false);
|
62
|
+
}
|
63
|
+
}
|
64
|
+
}
|
65
|
+
|
66
|
+
@include exports("block-grid") {
|
67
|
+
@if $include-html-grid-classes {
|
68
|
+
|
69
|
+
[class*="block-grid-"] { @include block-grid; }
|
70
|
+
|
71
|
+
@media #{$small-up} {
|
72
|
+
@include block-grid-html-classes($size:small);
|
73
|
+
}
|
74
|
+
|
75
|
+
@media #{$medium-up} {
|
76
|
+
@include block-grid-html-classes($size:medium);
|
77
|
+
}
|
78
|
+
|
79
|
+
@media #{$large-up} {
|
80
|
+
@include block-grid-html-classes($size:large);
|
81
|
+
}
|
82
|
+
}
|
83
|
+
}
|
@@ -0,0 +1,123 @@
|
|
1
|
+
@import "global";
|
2
|
+
|
3
|
+
//
|
4
|
+
// Breadcrumb Variables
|
5
|
+
//
|
6
|
+
$include-html-nav-classes: $include-html-classes !default;
|
7
|
+
|
8
|
+
// We use this to set the background color for the breadcrumb container.
|
9
|
+
$crumb-bg: lighten($secondary-color, 5%) !default;
|
10
|
+
|
11
|
+
// We use these to set the padding around the breadcrumbs.
|
12
|
+
$crumb-padding: rem-calc(9 14 9) !default;
|
13
|
+
$crumb-side-padding: rem-calc(12) !default;
|
14
|
+
|
15
|
+
// We use these to control border styles.
|
16
|
+
$crumb-function-factor: 10% !default;
|
17
|
+
$crumb-border-size: 1px !default;
|
18
|
+
$crumb-border-style: solid !default;
|
19
|
+
$crumb-border-color: darken($crumb-bg, $crumb-function-factor) !default;
|
20
|
+
$crumb-radius: $global-radius !default;
|
21
|
+
|
22
|
+
// We use these to set various text styles for breadcrumbs.
|
23
|
+
$crumb-font-size: rem-calc(11) !default;
|
24
|
+
$crumb-font-color: $primary-color !default;
|
25
|
+
$crumb-font-color-current: #333 !default;
|
26
|
+
$crumb-font-color-unavailable: #999 !default;
|
27
|
+
$crumb-font-transform: uppercase !default;
|
28
|
+
$crumb-link-decor: underline !default;
|
29
|
+
|
30
|
+
// We use these to control the slash between breadcrumbs
|
31
|
+
$crumb-slash-color: #aaa !default;
|
32
|
+
$crumb-slash: "/" !default;
|
33
|
+
|
34
|
+
//
|
35
|
+
// Breakcrumb Mixins
|
36
|
+
//
|
37
|
+
|
38
|
+
// We use this mixin to create a container around our breadcrumbs
|
39
|
+
@mixin crumb-container {
|
40
|
+
display: block;
|
41
|
+
padding: $crumb-padding;
|
42
|
+
overflow: hidden;
|
43
|
+
margin-#{$default-float}: 0;
|
44
|
+
list-style: none;
|
45
|
+
border-style: $crumb-border-style;
|
46
|
+
border-width: $crumb-border-size;
|
47
|
+
|
48
|
+
// We control which background color and border come through.
|
49
|
+
background-color: $crumb-bg;
|
50
|
+
border-color: $crumb-border-color;
|
51
|
+
}
|
52
|
+
|
53
|
+
// We use this mixin to create breadcrumb styles from list items.
|
54
|
+
@mixin crumbs {
|
55
|
+
|
56
|
+
// A normal state will make the links look and act like clickable breadcrumbs.
|
57
|
+
margin: 0;
|
58
|
+
float: $default-float;
|
59
|
+
font-size: $crumb-font-size;
|
60
|
+
text-transform: $crumb-font-transform;
|
61
|
+
|
62
|
+
&:hover a, &:focus a { text-decoration: $crumb-link-decor; }
|
63
|
+
|
64
|
+
a,
|
65
|
+
span {
|
66
|
+
text-transform: $crumb-font-transform;
|
67
|
+
color: $crumb-font-color;
|
68
|
+
}
|
69
|
+
|
70
|
+
// Current is for the link of the current page
|
71
|
+
&.current {
|
72
|
+
cursor: $cursor-default-value;
|
73
|
+
color: $crumb-font-color-current;
|
74
|
+
a {
|
75
|
+
cursor: $cursor-default-value;
|
76
|
+
color: $crumb-font-color-current;
|
77
|
+
}
|
78
|
+
|
79
|
+
&:hover, &:hover a,
|
80
|
+
&:focus, &:focus a { text-decoration: none; }
|
81
|
+
}
|
82
|
+
|
83
|
+
// Unavailable removed color and link styles so it looks inactive.
|
84
|
+
&.unavailable {
|
85
|
+
color: $crumb-font-color-unavailable;
|
86
|
+
a { color: $crumb-font-color-unavailable; }
|
87
|
+
|
88
|
+
&:hover,
|
89
|
+
&:hover a,
|
90
|
+
&:focus,
|
91
|
+
a:focus {
|
92
|
+
text-decoration: none;
|
93
|
+
color: $crumb-font-color-unavailable;
|
94
|
+
cursor: $cursor-default-value;
|
95
|
+
}
|
96
|
+
}
|
97
|
+
|
98
|
+
&:before {
|
99
|
+
content: "#{$crumb-slash}";
|
100
|
+
color: $crumb-slash-color;
|
101
|
+
margin: 0 $crumb-side-padding;
|
102
|
+
position: relative;
|
103
|
+
top: 1px;
|
104
|
+
}
|
105
|
+
|
106
|
+
&:first-child:before {
|
107
|
+
content: " ";
|
108
|
+
margin: 0;
|
109
|
+
}
|
110
|
+
}
|
111
|
+
|
112
|
+
@include exports("breadcrumbs") {
|
113
|
+
@if $include-html-nav-classes {
|
114
|
+
.breadcrumbs {
|
115
|
+
@include crumb-container;
|
116
|
+
@include radius($crumb-radius);
|
117
|
+
|
118
|
+
&>* {
|
119
|
+
@include crumbs;
|
120
|
+
}
|
121
|
+
}
|
122
|
+
}
|
123
|
+
}
|
@@ -0,0 +1,97 @@
|
|
1
|
+
@import "global";
|
2
|
+
@import "buttons";
|
3
|
+
|
4
|
+
|
5
|
+
//
|
6
|
+
// Button Group Variables
|
7
|
+
//
|
8
|
+
$include-html-button-classes: $include-html-classes !default;
|
9
|
+
|
10
|
+
// Sets the margin for the right side by default, and the left margin if right-to-left direction is used
|
11
|
+
$button-bar-margin-opposite: rem-calc(10) !default;
|
12
|
+
$button-group-border-width: 1px !default;
|
13
|
+
|
14
|
+
//
|
15
|
+
// Button Group Mixins
|
16
|
+
//
|
17
|
+
|
18
|
+
// We use this to add styles for a button group container
|
19
|
+
@mixin button-group-container($styles:true, $float:false) {
|
20
|
+
@if $styles {
|
21
|
+
list-style: none;
|
22
|
+
margin: 0;
|
23
|
+
@include clearfix();
|
24
|
+
}
|
25
|
+
@if $float {
|
26
|
+
float: #{$default-float};
|
27
|
+
margin-#{$opposite-direction}: $button-bar-margin-opposite;
|
28
|
+
& div { overflow: hidden; }
|
29
|
+
}
|
30
|
+
}
|
31
|
+
|
32
|
+
// We use this to control styles for button groups
|
33
|
+
@mixin button-group-style($radius:false, $even:false, $float:$default-float) {
|
34
|
+
|
35
|
+
> button, .button {
|
36
|
+
border-#{$opposite-direction}: $button-group-border-width solid;
|
37
|
+
border-color: rgba(255, 255, 255, 0.5);
|
38
|
+
}
|
39
|
+
|
40
|
+
// We use this to control the flow, or remove those styles completely.
|
41
|
+
@if $float {
|
42
|
+
margin: 0;
|
43
|
+
float: $float;
|
44
|
+
// Make sure the first child doesn't get the negative margin.
|
45
|
+
&:first-child { margin-#{$default-float}: 0; }
|
46
|
+
}
|
47
|
+
|
48
|
+
// We use these to control left and right radius on first/last buttons in the group.
|
49
|
+
@if $radius == true {
|
50
|
+
&:first-child,
|
51
|
+
&:first-child > a,
|
52
|
+
&:first-child > button,
|
53
|
+
&:first-child > .button { @include side-radius($default-float, $button-radius); }
|
54
|
+
&:last-child,
|
55
|
+
&:last-child > a,
|
56
|
+
&:last-child > button,
|
57
|
+
&:last-child > .button { @include side-radius($opposite-direction, $button-radius); }
|
58
|
+
}
|
59
|
+
@else if $radius {
|
60
|
+
&:first-child,
|
61
|
+
&:first-child > a,
|
62
|
+
&:first-child > button,
|
63
|
+
&:first-child > .button { @include side-radius($default-float, $radius); }
|
64
|
+
&:last-child,
|
65
|
+
&:last-child > a,
|
66
|
+
&:last-child > button,
|
67
|
+
&:last-child > .button { @include side-radius($opposite-direction, $radius); }
|
68
|
+
}
|
69
|
+
|
70
|
+
// We use this to make the buttons even width across their container
|
71
|
+
@if $even {
|
72
|
+
width: percentage((100/$even) / 100);
|
73
|
+
button, .button { width: 100%; }
|
74
|
+
}
|
75
|
+
|
76
|
+
}
|
77
|
+
|
78
|
+
@include exports("button-group") {
|
79
|
+
@if $include-html-button-classes {
|
80
|
+
.button-group { @include button-group-container;
|
81
|
+
|
82
|
+
&> * { @include button-group-style(); }
|
83
|
+
|
84
|
+
&.radius > * { @include button-group-style($radius:$button-radius, $float:null); }
|
85
|
+
&.round > * { @include button-group-style($radius:$button-round, $float:null); }
|
86
|
+
|
87
|
+
@for $i from 2 through 8 {
|
88
|
+
&.even#{-$i} li { @include button-group-style($even:$i, $float:null); }
|
89
|
+
}
|
90
|
+
}
|
91
|
+
|
92
|
+
.button-bar {
|
93
|
+
@include clearfix;
|
94
|
+
.button-group { @include button-group-container($styles:false,$float:true); }
|
95
|
+
}
|
96
|
+
}
|
97
|
+
}
|