flat-ui-sass 2.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +18 -0
- data/.gitmodules +3 -0
- data/Gemfile +4 -0
- data/LICENSE.txt +22 -0
- data/README.md +256 -0
- data/Rakefile +14 -0
- data/app/helpers/flat_ui/rails/icon_helper.rb +60 -0
- data/bin/fui_convert +9 -0
- data/flat-ui-sass.gemspec +28 -0
- data/lib/flat-ui-sass.rb +98 -0
- data/lib/flat-ui-sass/cli.rb +56 -0
- data/lib/flat-ui-sass/engine.rb +13 -0
- data/lib/flat-ui-sass/sass_functions.rb +56 -0
- data/lib/flat-ui-sass/version.rb +4 -0
- data/lib/tasks/converter.rb +99 -0
- data/lib/tasks/converter/filesystem.rb +16 -0
- data/lib/tasks/converter/flat_ui_fonts_conversion.rb +19 -0
- data/lib/tasks/converter/flat_ui_images_conversion.rb +19 -0
- data/lib/tasks/converter/flat_ui_js_conversion.rb +28 -0
- data/lib/tasks/converter/flat_ui_less_conversion.rb +328 -0
- data/lib/tasks/converter/logger.rb +61 -0
- data/lib/tasks/flat-ui-sass.rake +8 -0
- data/templates/project/_variables.scss.erb +5 -0
- data/templates/project/manifest.rb +57 -0
- data/templates/project/styles.scss +4 -0
- data/vendor/assets/fonts/flat-ui/flat-ui-icons-regular.eot +0 -0
- data/vendor/assets/fonts/flat-ui/flat-ui-icons-regular.svg +140 -0
- data/vendor/assets/fonts/flat-ui/flat-ui-icons-regular.ttf +0 -0
- data/vendor/assets/fonts/flat-ui/flat-ui-icons-regular.woff +0 -0
- data/vendor/assets/images/flat-ui/icons/png/Book.png +0 -0
- data/vendor/assets/images/flat-ui/icons/png/Calendar.png +0 -0
- data/vendor/assets/images/flat-ui/icons/png/Chat.png +0 -0
- data/vendor/assets/images/flat-ui/icons/png/Clipboard.png +0 -0
- data/vendor/assets/images/flat-ui/icons/png/Compas.png +0 -0
- data/vendor/assets/images/flat-ui/icons/png/Gift-Box.png +0 -0
- data/vendor/assets/images/flat-ui/icons/png/Infinity-Loop.png +0 -0
- data/vendor/assets/images/flat-ui/icons/png/Mail.png +0 -0
- data/vendor/assets/images/flat-ui/icons/png/Map.png +0 -0
- data/vendor/assets/images/flat-ui/icons/png/Pensils.png +0 -0
- data/vendor/assets/images/flat-ui/icons/png/Pocket.png +0 -0
- data/vendor/assets/images/flat-ui/icons/png/Retina-Ready.png +0 -0
- data/vendor/assets/images/flat-ui/icons/png/Toilet-Paper.png +0 -0
- data/vendor/assets/images/flat-ui/icons/png/Watches.png +0 -0
- data/vendor/assets/images/flat-ui/icons/svg/book.svg +1 -0
- data/vendor/assets/images/flat-ui/icons/svg/calendar.svg +1 -0
- data/vendor/assets/images/flat-ui/icons/svg/chat.svg +1 -0
- data/vendor/assets/images/flat-ui/icons/svg/clipboard.svg +1 -0
- data/vendor/assets/images/flat-ui/icons/svg/clocks.svg +9 -0
- data/vendor/assets/images/flat-ui/icons/svg/compas.svg +1 -0
- data/vendor/assets/images/flat-ui/icons/svg/gift-box.svg +1 -0
- data/vendor/assets/images/flat-ui/icons/svg/loop.svg +5 -0
- data/vendor/assets/images/flat-ui/icons/svg/mail.svg +1 -0
- data/vendor/assets/images/flat-ui/icons/svg/map.svg +1 -0
- data/vendor/assets/images/flat-ui/icons/svg/paper-bag.svg +1 -0
- data/vendor/assets/images/flat-ui/icons/svg/pencils.svg +1 -0
- data/vendor/assets/images/flat-ui/icons/svg/retina.svg +1 -0
- data/vendor/assets/images/flat-ui/icons/svg/toilet-paper.svg +1 -0
- data/vendor/assets/images/flat-ui/login/icon.png +0 -0
- data/vendor/assets/images/flat-ui/login/imac-2x.png +0 -0
- data/vendor/assets/images/flat-ui/login/imac.png +0 -0
- data/vendor/assets/images/flat-ui/switch/mask-square.png +0 -0
- data/vendor/assets/images/flat-ui/switch/mask.png +0 -0
- data/vendor/assets/images/flat-ui/tile/ribbon-2x.png +0 -0
- data/vendor/assets/images/flat-ui/tile/ribbon.png +0 -0
- data/vendor/assets/images/flat-ui/todo/done-2x.png +0 -0
- data/vendor/assets/images/flat-ui/todo/done.png +0 -0
- data/vendor/assets/images/flat-ui/todo/search-2x.png +0 -0
- data/vendor/assets/images/flat-ui/todo/search.png +0 -0
- data/vendor/assets/images/flat-ui/todo/todo-2x.png +0 -0
- data/vendor/assets/images/flat-ui/todo/todo.png +0 -0
- data/vendor/assets/images/flat-ui/video/fullscreen-2x.png +0 -0
- data/vendor/assets/images/flat-ui/video/fullscreen.png +0 -0
- data/vendor/assets/images/flat-ui/video/pause-2x.png +0 -0
- data/vendor/assets/images/flat-ui/video/pause.png +0 -0
- data/vendor/assets/images/flat-ui/video/play-2x.png +0 -0
- data/vendor/assets/images/flat-ui/video/play.png +0 -0
- data/vendor/assets/images/flat-ui/video/poster.jpg +0 -0
- data/vendor/assets/images/flat-ui/video/volume-full-2x.png +0 -0
- data/vendor/assets/images/flat-ui/video/volume-full.png +0 -0
- data/vendor/assets/images/flat-ui/video/volume-off-2x.png +0 -0
- data/vendor/assets/images/flat-ui/video/volume-off.png +0 -0
- data/vendor/assets/javascripts/flat-ui.js +2 -0
- data/vendor/assets/javascripts/flat-ui/flatui-checkbox.js +112 -0
- data/vendor/assets/javascripts/flat-ui/flatui-radio.js +139 -0
- data/vendor/assets/stylesheets/flat-ui.scss +1 -0
- data/vendor/assets/stylesheets/flat-ui/_mixins.scss +878 -0
- data/vendor/assets/stylesheets/flat-ui/_spaces.scss +172 -0
- data/vendor/assets/stylesheets/flat-ui/_variables.scss +509 -0
- data/vendor/assets/stylesheets/flat-ui/flat-ui.scss +45 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_button-groups.scss +110 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_buttons.scss +151 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_caret.scss +30 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_checkbox-and-radio.scss +143 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_code.scss +49 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_dropdown.scss +223 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_footer.scss +76 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_forms.scss +188 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_glyphicons.scss +135 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_input-groups.scss +153 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_input-icons.scss +72 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_local-fonts.scss +69 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_login.scss +111 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_navbar.scss +876 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_pager.scss +51 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_pagination.scss +166 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_palette.scss +71 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_progress-bars.scss +34 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_scaffolding.scss +64 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_select.scss +145 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_share.scss +44 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_slider.scss +105 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_switch.scss +150 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_tagsinput.scss +121 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_thumbnails.scss +38 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_tile.scss +54 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_todo.scss +110 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_tooltip.scss +56 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_type.scss +208 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_typeahead.scss +41 -0
- data/vendor/assets/stylesheets/flat-ui/modules/_video.scss +458 -0
- metadata +251 -0
@@ -0,0 +1,51 @@
|
|
1
|
+
//
|
2
|
+
// Pager
|
3
|
+
// --------------------------------------------------
|
4
|
+
|
5
|
+
.pager {
|
6
|
+
background-color: $brand-primary;
|
7
|
+
border-radius: $border-radius-large;
|
8
|
+
color: $inverse;
|
9
|
+
font-size: 16px;
|
10
|
+
font-weight: 700;
|
11
|
+
display: inline-block;
|
12
|
+
|
13
|
+
li {
|
14
|
+
&:first-child {
|
15
|
+
> a,
|
16
|
+
> span {
|
17
|
+
border-left: none;
|
18
|
+
border-radius: $border-radius-large 0 0 $border-radius-large;
|
19
|
+
}
|
20
|
+
}
|
21
|
+
|
22
|
+
> a,
|
23
|
+
> span {
|
24
|
+
background: none;
|
25
|
+
border: none;
|
26
|
+
border-left: 2px solid mix($brand-primary, black, 85%);
|
27
|
+
color: $inverse;
|
28
|
+
padding: $pager-padding;
|
29
|
+
text-decoration: none;
|
30
|
+
white-space: nowrap;
|
31
|
+
border-radius: 0 $border-radius-large $border-radius-large 0;
|
32
|
+
line-height: 1.313;
|
33
|
+
|
34
|
+
&:hover,
|
35
|
+
&:focus {
|
36
|
+
background-color: mix($brand-primary, black, 85%);
|
37
|
+
}
|
38
|
+
&:active {
|
39
|
+
background-color: mix($brand-primary, black, 85%);
|
40
|
+
}
|
41
|
+
|
42
|
+
// Add some spacing between the icon and text
|
43
|
+
[class*="fui-"] + span {
|
44
|
+
margin-left: 8px;
|
45
|
+
}
|
46
|
+
span + [class*="fui-"] {
|
47
|
+
margin-left: 8px;
|
48
|
+
}
|
49
|
+
}
|
50
|
+
}
|
51
|
+
}
|
@@ -0,0 +1,166 @@
|
|
1
|
+
//
|
2
|
+
// Pagination
|
3
|
+
// --------------------------------------------------
|
4
|
+
|
5
|
+
.pagination {
|
6
|
+
position: relative;
|
7
|
+
|
8
|
+
ul {
|
9
|
+
background: $pagination-color;
|
10
|
+
color: $inverse;
|
11
|
+
padding: 0;
|
12
|
+
margin: 0;
|
13
|
+
display: inline-block;
|
14
|
+
border-radius: $border-radius-large;
|
15
|
+
|
16
|
+
li {
|
17
|
+
display: inline-block;
|
18
|
+
margin-right: -3px;
|
19
|
+
vertical-align: middle;
|
20
|
+
|
21
|
+
// Pseudos and states
|
22
|
+
&:first-child {
|
23
|
+
border-radius: $border-radius-large 0 0 $border-radius-large;
|
24
|
+
|
25
|
+
&.previous + li {
|
26
|
+
> a,
|
27
|
+
> span {
|
28
|
+
border-left-width: 5px;
|
29
|
+
}
|
30
|
+
}
|
31
|
+
}
|
32
|
+
&:last-child {
|
33
|
+
border-radius: 0 $border-radius-large $border-radius-large 0;
|
34
|
+
margin-right: 0;
|
35
|
+
}
|
36
|
+
&.previous,
|
37
|
+
&.next {
|
38
|
+
> a,
|
39
|
+
> span {
|
40
|
+
background: transparent;
|
41
|
+
border: none;
|
42
|
+
border-right: 2px solid mix($pagination-color, white, 66%);
|
43
|
+
font-size: floor($component-font-size-base * 1.067); // ~16px
|
44
|
+
margin: 0 9px 0 0;
|
45
|
+
padding: 12px 17px;
|
46
|
+
border-radius: $border-radius-large 0 0 $border-radius-large;
|
47
|
+
|
48
|
+
&,
|
49
|
+
&:hover,
|
50
|
+
&:focus {
|
51
|
+
border-color: mix($pagination-color, white, 66%) !important;
|
52
|
+
}
|
53
|
+
|
54
|
+
@media (max-width: 480px) {
|
55
|
+
& {
|
56
|
+
margin-right: 0;
|
57
|
+
}
|
58
|
+
}
|
59
|
+
}
|
60
|
+
}
|
61
|
+
&.next {
|
62
|
+
margin-left: 9px;
|
63
|
+
|
64
|
+
> a,
|
65
|
+
> span {
|
66
|
+
border-left: 2px solid mix($pagination-color, white, 66%);
|
67
|
+
border-right: none;
|
68
|
+
margin: 0;
|
69
|
+
border-radius: 0 $border-radius-large $border-radius-large 0;
|
70
|
+
}
|
71
|
+
}
|
72
|
+
&.active {
|
73
|
+
> a,
|
74
|
+
> span {
|
75
|
+
background-color: $inverse;
|
76
|
+
border-color: $inverse;
|
77
|
+
border-width: 2px !important;
|
78
|
+
color: $pagination-color;
|
79
|
+
margin: 10px 5px 9px;
|
80
|
+
|
81
|
+
&:hover,
|
82
|
+
&:focus {
|
83
|
+
background-color: $inverse;
|
84
|
+
border-color: $inverse;
|
85
|
+
color: $pagination-color;
|
86
|
+
}
|
87
|
+
}
|
88
|
+
&.previous,
|
89
|
+
&.next {
|
90
|
+
border-color: mix($pagination-color, white, 66%);
|
91
|
+
|
92
|
+
> a, > span {
|
93
|
+
margin: 0;
|
94
|
+
|
95
|
+
&,
|
96
|
+
&:hover,
|
97
|
+
&:focus {
|
98
|
+
background-color: $brand-secondary;
|
99
|
+
color: $inverse;
|
100
|
+
}
|
101
|
+
}
|
102
|
+
}
|
103
|
+
&.previous {
|
104
|
+
margin-right: 6px;
|
105
|
+
}
|
106
|
+
}
|
107
|
+
|
108
|
+
// Link
|
109
|
+
> a,
|
110
|
+
> span {
|
111
|
+
display: inline-block;
|
112
|
+
background: $inverse;
|
113
|
+
border: 5px solid $pagination-color;
|
114
|
+
color: $inverse;
|
115
|
+
font-size: ceil($component-font-size-base * 0.889);
|
116
|
+
line-height: 16px;
|
117
|
+
margin: 7px 2px 6px;
|
118
|
+
min-width: 0;
|
119
|
+
min-height: 16px;
|
120
|
+
padding: 0 4px;
|
121
|
+
border-radius: 50px;
|
122
|
+
@include transition(background .2s ease-out, border-color 0s ease-out, color .2s ease-out);
|
123
|
+
|
124
|
+
&:hover,
|
125
|
+
&:focus {
|
126
|
+
background-color: $brand-secondary;
|
127
|
+
border-color: $brand-secondary;
|
128
|
+
color: $inverse;
|
129
|
+
@include transition(background .2s ease-out, border-color .2s ease-out, color .2s ease-out);
|
130
|
+
}
|
131
|
+
&:active {
|
132
|
+
background-color: mix($brand-secondary, black, 85%);
|
133
|
+
border-color: mix($brand-secondary, black, 85%);
|
134
|
+
}
|
135
|
+
}
|
136
|
+
}
|
137
|
+
}
|
138
|
+
|
139
|
+
// Navigation buttons
|
140
|
+
> .btn {
|
141
|
+
&.previous,
|
142
|
+
&.next {
|
143
|
+
margin-right: 8px;
|
144
|
+
font-size: ceil($component-font-size-base * 0.933); // ~14px
|
145
|
+
line-height: 1.429; // ~20px
|
146
|
+
padding-left: 23px;
|
147
|
+
padding-right: 23px;
|
148
|
+
|
149
|
+
[class*="fui-"] {
|
150
|
+
font-size: $icon-normal;
|
151
|
+
margin-left: -2px;
|
152
|
+
margin-top: -2px;
|
153
|
+
}
|
154
|
+
}
|
155
|
+
|
156
|
+
&.next {
|
157
|
+
margin-left: 8px;
|
158
|
+
margin-right: 0;
|
159
|
+
|
160
|
+
[class*="fui-"] {
|
161
|
+
margin-right: -2px;
|
162
|
+
margin-left: 4px;
|
163
|
+
}
|
164
|
+
}
|
165
|
+
}
|
166
|
+
}
|
@@ -0,0 +1,71 @@
|
|
1
|
+
//
|
2
|
+
// Palette
|
3
|
+
// --------------------------------------------------
|
4
|
+
|
5
|
+
.pallete-item {
|
6
|
+
width: 140px;
|
7
|
+
float: left;
|
8
|
+
margin: 0 0 20px 20px;
|
9
|
+
}
|
10
|
+
.palette {
|
11
|
+
font-size: ceil($component-font-size-base * 0.933); // ~14px
|
12
|
+
line-height: 1.214; // ~17px
|
13
|
+
color: $inverse;
|
14
|
+
margin: 0;
|
15
|
+
padding: 15px;
|
16
|
+
text-transform: uppercase;
|
17
|
+
|
18
|
+
dt,
|
19
|
+
dd {
|
20
|
+
line-height: 1.429;
|
21
|
+
}
|
22
|
+
dt {
|
23
|
+
display: block;
|
24
|
+
font-weight: bold;
|
25
|
+
@include opacity(.8);
|
26
|
+
}
|
27
|
+
dd {
|
28
|
+
font-weight: 300;
|
29
|
+
margin-left: 0;
|
30
|
+
@include opacity(.8);
|
31
|
+
-webkit-font-smoothing: subpixel-antialiased;
|
32
|
+
}
|
33
|
+
}
|
34
|
+
|
35
|
+
//
|
36
|
+
// Pallet grid
|
37
|
+
// --------------------------------------------------
|
38
|
+
@include calc-color("turquoise", "green-sea");
|
39
|
+
@include calc-color("emerald", "nephritis");
|
40
|
+
@include calc-color("peter-river", "belize-hole");
|
41
|
+
@include calc-color("amethyst", "wisteria");
|
42
|
+
@include calc-color("wet-asphalt", "midnight-blue");
|
43
|
+
|
44
|
+
@include calc-color("sun-flower", "orange");
|
45
|
+
@include calc-color("carrot", "pumpkin");
|
46
|
+
@include calc-color("alizarin", "pomegranate");
|
47
|
+
@include calc-color("clouds", "silver");
|
48
|
+
@include calc-color("concrete", "asbestos");
|
49
|
+
|
50
|
+
.palette-clouds {
|
51
|
+
color: #bdc3c7;
|
52
|
+
}
|
53
|
+
|
54
|
+
// Palette paragraph
|
55
|
+
.palette-paragraph {
|
56
|
+
color: #7f8c8d;
|
57
|
+
font-size: 12px;
|
58
|
+
line-height: 17px;
|
59
|
+
|
60
|
+
span {
|
61
|
+
color: #bdc3c7;
|
62
|
+
}
|
63
|
+
}
|
64
|
+
|
65
|
+
// Headline
|
66
|
+
.palette-headline {
|
67
|
+
color: #7f8c8d;
|
68
|
+
font-size: 13px;
|
69
|
+
font-weight: 700;
|
70
|
+
margin-top: -3px;
|
71
|
+
}
|
@@ -0,0 +1,34 @@
|
|
1
|
+
//
|
2
|
+
// Progress bars
|
3
|
+
// --------------------------------------------------
|
4
|
+
|
5
|
+
// Outer container
|
6
|
+
.progress {
|
7
|
+
background: mix($brand-primary, white, 10%);
|
8
|
+
border-radius: 32px;
|
9
|
+
height: $progress-height;
|
10
|
+
@include box-shadow(none);
|
11
|
+
}
|
12
|
+
|
13
|
+
// Bar of progress
|
14
|
+
.progress-bar {
|
15
|
+
background: $brand-secondary;
|
16
|
+
line-height: $progress-height;
|
17
|
+
@include box-shadow(none);
|
18
|
+
}
|
19
|
+
|
20
|
+
// Variations
|
21
|
+
// -------------------------
|
22
|
+
|
23
|
+
.progress-bar-success {
|
24
|
+
background-color: $brand-success;
|
25
|
+
}
|
26
|
+
.progress-bar-warning {
|
27
|
+
background-color: $brand-warning;
|
28
|
+
}
|
29
|
+
.progress-bar-danger {
|
30
|
+
background-color: $brand-danger;
|
31
|
+
}
|
32
|
+
.progress-bar-info {
|
33
|
+
background-color: $brand-info;
|
34
|
+
}
|
@@ -0,0 +1,64 @@
|
|
1
|
+
//
|
2
|
+
// Scaffolding
|
3
|
+
// --------------------------------------------------
|
4
|
+
|
5
|
+
|
6
|
+
// Body reset
|
7
|
+
// -------------------------
|
8
|
+
|
9
|
+
body {
|
10
|
+
font-family: $font-family-base;
|
11
|
+
font-size: $font-size-base;
|
12
|
+
line-height: $line-height-base;
|
13
|
+
color: $text-color;
|
14
|
+
background-color: $body-bg;
|
15
|
+
}
|
16
|
+
|
17
|
+
// Links
|
18
|
+
// -------------------------
|
19
|
+
|
20
|
+
a {
|
21
|
+
color: $link-color;
|
22
|
+
text-decoration: none;
|
23
|
+
@include transition(.25s);
|
24
|
+
|
25
|
+
&:hover,
|
26
|
+
&:focus {
|
27
|
+
color: $link-hover-color;
|
28
|
+
text-decoration: none;
|
29
|
+
}
|
30
|
+
&:focus {
|
31
|
+
outline: none;
|
32
|
+
}
|
33
|
+
}
|
34
|
+
|
35
|
+
// Images
|
36
|
+
// -------------------------
|
37
|
+
|
38
|
+
// Rounded corners
|
39
|
+
.img-rounded {
|
40
|
+
border-radius: $border-radius-large;
|
41
|
+
}
|
42
|
+
|
43
|
+
// Image thumbnails
|
44
|
+
//
|
45
|
+
// Heads up! This is mixin-ed into thumbnails.less for `.thumbnail`.
|
46
|
+
.img-thumbnail {
|
47
|
+
padding: $thumbnail-padding;
|
48
|
+
line-height: $line-height-base;
|
49
|
+
background-color: $thumbnail-bg;
|
50
|
+
border: 2px solid $thumbnail-border;
|
51
|
+
border-radius: $thumbnail-border-radius;
|
52
|
+
@include transition(all .25s ease-in-out);
|
53
|
+
|
54
|
+
// Keep them at most 100% wide
|
55
|
+
@include img-responsive(inline-block);
|
56
|
+
}
|
57
|
+
|
58
|
+
// Description text under image
|
59
|
+
.img-comment {
|
60
|
+
font-size: ceil($font-size-base * 0.8333); // ~15px
|
61
|
+
line-height: 1.2;
|
62
|
+
font-style: italic;
|
63
|
+
margin: 24px 0;
|
64
|
+
}
|
@@ -0,0 +1,145 @@
|
|
1
|
+
//
|
2
|
+
// Bootstrap Select
|
3
|
+
// --------------------------------------------------
|
4
|
+
// Credits: Silvio Moreto
|
5
|
+
// http://github.com/silviomoreto/bootstrap-select
|
6
|
+
|
7
|
+
.select {
|
8
|
+
display: inline-block;
|
9
|
+
margin-bottom: 10px;
|
10
|
+
|
11
|
+
// Select grid
|
12
|
+
&[class*="span"] {
|
13
|
+
[class*="span"] > & {
|
14
|
+
margin-left: 0; // No margin if select is a closest child of the grid
|
15
|
+
}
|
16
|
+
.btn {
|
17
|
+
width: 100%; // Button should take all available space of its parent
|
18
|
+
}
|
19
|
+
}
|
20
|
+
|
21
|
+
// Fluid width. Takes all available space and behaves like a block
|
22
|
+
&.select-block {
|
23
|
+
display: block;
|
24
|
+
float: none;
|
25
|
+
margin-left: 0;
|
26
|
+
width: auto;
|
27
|
+
@include clearfix();
|
28
|
+
|
29
|
+
.btn {
|
30
|
+
width: 100%;
|
31
|
+
}
|
32
|
+
.dropdown-menu {
|
33
|
+
width: 100%;
|
34
|
+
}
|
35
|
+
}
|
36
|
+
|
37
|
+
|
38
|
+
// Button Sizes
|
39
|
+
// --------------------------------------------------
|
40
|
+
.btn {
|
41
|
+
width: 220px; // Default select width until .span* is applied
|
42
|
+
|
43
|
+
// Huge
|
44
|
+
&.btn-hg {
|
45
|
+
.filter-option {
|
46
|
+
left: 20px;
|
47
|
+
right: 40px;
|
48
|
+
top: 13px;
|
49
|
+
}
|
50
|
+
.caret {
|
51
|
+
right: 20px;
|
52
|
+
}
|
53
|
+
}
|
54
|
+
|
55
|
+
// Large
|
56
|
+
&.btn-lg {
|
57
|
+
.filter-option {
|
58
|
+
left: 18px;
|
59
|
+
right: 38px;
|
60
|
+
}
|
61
|
+
}
|
62
|
+
|
63
|
+
// Small
|
64
|
+
&.btn-sm {
|
65
|
+
.filter-option {
|
66
|
+
left: 13px;
|
67
|
+
right: 33px;
|
68
|
+
}
|
69
|
+
.caret {
|
70
|
+
right: 13px;
|
71
|
+
}
|
72
|
+
}
|
73
|
+
|
74
|
+
// Exstra small
|
75
|
+
&.btn-xs {
|
76
|
+
.filter-option {
|
77
|
+
left: 13px;
|
78
|
+
right: 33px;
|
79
|
+
top: 5px;
|
80
|
+
}
|
81
|
+
.caret {
|
82
|
+
right: 13px;
|
83
|
+
}
|
84
|
+
}
|
85
|
+
|
86
|
+
.filter-option {
|
87
|
+
height: 26px;
|
88
|
+
left: 13px;
|
89
|
+
overflow: hidden;
|
90
|
+
position: absolute;
|
91
|
+
right: 33px;
|
92
|
+
text-align: left;
|
93
|
+
top: 10px;
|
94
|
+
}
|
95
|
+
.caret {
|
96
|
+
position: absolute;
|
97
|
+
right: 16px;
|
98
|
+
top: 50%;
|
99
|
+
margin-top: -3px;
|
100
|
+
}
|
101
|
+
.dropdown-toggle {
|
102
|
+
border-radius: $border-radius-large;
|
103
|
+
}
|
104
|
+
|
105
|
+
// Dropdown menu
|
106
|
+
.dropdown-menu {
|
107
|
+
min-width: 100%;
|
108
|
+
|
109
|
+
dt {
|
110
|
+
cursor: default;
|
111
|
+
display: block;
|
112
|
+
padding: 3px 20px;
|
113
|
+
}
|
114
|
+
li {
|
115
|
+
&:not(.disabled) > a:hover small {
|
116
|
+
color: fade($inverse, .4);
|
117
|
+
}
|
118
|
+
> a {
|
119
|
+
min-height: 20px;
|
120
|
+
|
121
|
+
&.opt {
|
122
|
+
padding-left: 35px;
|
123
|
+
}
|
124
|
+
}
|
125
|
+
small {
|
126
|
+
padding-left: .5em;
|
127
|
+
}
|
128
|
+
> dt small {
|
129
|
+
font-weight: normal;
|
130
|
+
}
|
131
|
+
}
|
132
|
+
}
|
133
|
+
|
134
|
+
// Disabled state
|
135
|
+
> .disabled,
|
136
|
+
.dropdown-menu li.disabled > a {
|
137
|
+
cursor: default;
|
138
|
+
}
|
139
|
+
}
|
140
|
+
|
141
|
+
// Caret
|
142
|
+
.caret {
|
143
|
+
@include caret($inverse);
|
144
|
+
}
|
145
|
+
}
|