twitter-bootstrap-rails 2.1.7 → 2.2.8

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of twitter-bootstrap-rails might be problematic. Click here for more details.

Files changed (117) hide show
  1. data/README.md +428 -21
  2. data/Rakefile +15 -3
  3. data/app/assets/fonts/fontawesome-webfont.eot +0 -0
  4. data/app/assets/fonts/fontawesome-webfont.svg +399 -0
  5. data/app/assets/fonts/fontawesome-webfont.ttf +0 -0
  6. data/app/assets/fonts/fontawesome-webfont.woff +0 -0
  7. data/{vendor → app}/assets/javascripts/twitter/bootstrap/bootstrap-affix.js +12 -1
  8. data/{vendor → app}/assets/javascripts/twitter/bootstrap/bootstrap-alert.js +12 -1
  9. data/{vendor → app}/assets/javascripts/twitter/bootstrap/bootstrap-button.js +12 -1
  10. data/{vendor → app}/assets/javascripts/twitter/bootstrap/bootstrap-carousel.js +42 -11
  11. data/{vendor → app}/assets/javascripts/twitter/bootstrap/bootstrap-collapse.js +18 -7
  12. data/{vendor → app}/assets/javascripts/twitter/bootstrap/bootstrap-dropdown.js +32 -11
  13. data/{vendor → app}/assets/javascripts/twitter/bootstrap/bootstrap-modal.js +25 -12
  14. data/{vendor → app}/assets/javascripts/twitter/bootstrap/bootstrap-popover.js +17 -6
  15. data/{vendor → app}/assets/javascripts/twitter/bootstrap/bootstrap-scrollspy.js +13 -2
  16. data/{vendor → app}/assets/javascripts/twitter/bootstrap/bootstrap-tab.js +12 -1
  17. data/{vendor → app}/assets/javascripts/twitter/bootstrap/bootstrap-tooltip.js +115 -30
  18. data/{vendor → app}/assets/javascripts/twitter/bootstrap/bootstrap-transition.js +1 -1
  19. data/{vendor → app}/assets/javascripts/twitter/bootstrap/bootstrap-typeahead.js +38 -13
  20. data/app/assets/stylesheets/twitter-bootstrap-static/bootstrap.css.erb +890 -0
  21. data/app/assets/stylesheets/twitter-bootstrap-static/fontawesome.css.erb +787 -0
  22. data/{vendor → app}/assets/stylesheets/twitter-bootstrap-static/sprites.css.erb +2 -2
  23. data/app/helpers/badge_label_helper.rb +16 -0
  24. data/app/helpers/bootstrap_flash_helper.rb +22 -16
  25. data/app/helpers/glyph_helper.rb +7 -2
  26. data/app/helpers/modal_helper.rb +29 -16
  27. data/app/helpers/navbar_helper.rb +194 -0
  28. data/app/helpers/twitter_breadcrumbs_helper.rb +7 -2
  29. data/app/views/twitter-bootstrap/_breadcrumbs.html.erb +2 -2
  30. data/lib/generators/bootstrap/install/install_generator.rb +19 -6
  31. data/lib/generators/bootstrap/install/templates/bootstrap.coffee +2 -3
  32. data/lib/generators/bootstrap/install/templates/bootstrap.js +2 -3
  33. data/lib/generators/bootstrap/install/templates/bootstrap_and_overrides.less +8 -10
  34. data/lib/generators/bootstrap/install/templates/en.bootstrap.yml +18 -0
  35. data/lib/generators/bootstrap/layout/templates/layout.html.erb +10 -12
  36. data/lib/generators/bootstrap/layout/templates/layout.html.haml +8 -11
  37. data/lib/generators/bootstrap/layout/templates/layout.html.slim +10 -11
  38. data/lib/generators/bootstrap/themed/templates/edit.html.erb +1 -2
  39. data/lib/generators/bootstrap/themed/templates/edit.html.haml +1 -1
  40. data/lib/generators/bootstrap/themed/templates/edit.html.slim +1 -1
  41. data/lib/generators/bootstrap/themed/templates/index.html.erb +1 -1
  42. data/lib/generators/bootstrap/themed/templates/index.html.haml +1 -1
  43. data/lib/generators/bootstrap/themed/templates/index.html.slim +1 -1
  44. data/lib/generators/bootstrap/themed/templates/new.html.erb +1 -2
  45. data/lib/generators/bootstrap/themed/templates/new.html.haml +1 -1
  46. data/lib/generators/bootstrap/themed/templates/new.html.slim +1 -1
  47. data/lib/generators/bootstrap/themed/templates/show.html.erb +1 -1
  48. data/lib/generators/bootstrap/themed/templates/show.html.haml +1 -1
  49. data/lib/generators/bootstrap/themed/templates/show.html.slim +1 -1
  50. data/lib/generators/bootstrap/themed/themed_generator.rb +2 -2
  51. data/lib/twitter/bootstrap/rails/engine.rb +3 -0
  52. data/lib/twitter/bootstrap/rails/twitter-bootstrap-breadcrumbs.rb +14 -2
  53. data/lib/twitter/bootstrap/rails/version.rb +2 -2
  54. data/lib/twitter-bootstrap-rails.rb +4 -4
  55. data/spec/lib/twitter_bootstrap_rails/badge_label_helper_spec.rb +22 -0
  56. data/spec/lib/twitter_bootstrap_rails/modal_helper_spec.rb +62 -0
  57. data/spec/lib/twitter_bootstrap_rails/navbar_helper_spec.rb +362 -0
  58. data/spec/lib/twitter_bootstrap_rails/uri_state_spec.rb +47 -0
  59. data/spec/spec_helper.rb +11 -0
  60. data/test/lib/breadcrumbs_test.rb +75 -0
  61. data/test/test_helper.rb +11 -0
  62. data/vendor/assets/stylesheets/twitter-bootstrap-static/bootstrap.css.erb +316 -294
  63. data/vendor/static-source/fontawesome.less +8 -6
  64. data/vendor/static-source/sprites.less +3 -2
  65. data/vendor/toolkit/fontawesome/bootstrap.less +84 -0
  66. data/vendor/toolkit/fontawesome/core.less +129 -0
  67. data/vendor/toolkit/fontawesome/extras.less +93 -0
  68. data/vendor/toolkit/fontawesome/font-awesome-ie7.less +1953 -0
  69. data/vendor/toolkit/fontawesome/font-awesome.less +33 -0
  70. data/vendor/toolkit/fontawesome/icons.less +381 -0
  71. data/vendor/toolkit/fontawesome/mixins.less +48 -0
  72. data/vendor/toolkit/fontawesome/path.less +14 -0
  73. data/vendor/toolkit/fontawesome/variables.less +735 -0
  74. data/vendor/toolkit/twitter/bootstrap/alerts.less +14 -0
  75. data/vendor/toolkit/twitter/bootstrap/bootstrap.less +4 -4
  76. data/vendor/toolkit/twitter/bootstrap/breadcrumbs.less +6 -6
  77. data/vendor/toolkit/twitter/bootstrap/button-groups.less +31 -44
  78. data/vendor/toolkit/twitter/bootstrap/buttons.less +13 -17
  79. data/vendor/toolkit/twitter/bootstrap/carousel.less +48 -21
  80. data/vendor/toolkit/twitter/bootstrap/close.less +2 -1
  81. data/vendor/toolkit/twitter/bootstrap/code.less +3 -0
  82. data/vendor/toolkit/twitter/bootstrap/dropdowns.less +32 -21
  83. data/vendor/toolkit/twitter/bootstrap/forms.less +17 -10
  84. data/vendor/toolkit/twitter/bootstrap/labels-badges.less +12 -2
  85. data/vendor/toolkit/twitter/bootstrap/media.less +2 -2
  86. data/vendor/toolkit/twitter/bootstrap/mixins.less +25 -9
  87. data/vendor/toolkit/twitter/bootstrap/modals.less +4 -3
  88. data/vendor/toolkit/twitter/bootstrap/navbar.less +35 -13
  89. data/vendor/toolkit/twitter/bootstrap/navs.less +45 -21
  90. data/vendor/toolkit/twitter/bootstrap/pager.less +3 -1
  91. data/vendor/toolkit/twitter/bootstrap/pagination.less +3 -1
  92. data/vendor/toolkit/twitter/bootstrap/popovers.less +55 -39
  93. data/vendor/toolkit/twitter/bootstrap/reset.less +82 -4
  94. data/vendor/toolkit/twitter/bootstrap/responsive-767px-max.less +2 -2
  95. data/vendor/toolkit/twitter/bootstrap/responsive-navbar.less +6 -2
  96. data/vendor/toolkit/twitter/bootstrap/responsive-utilities.less +16 -0
  97. data/vendor/toolkit/twitter/bootstrap/responsive.less +1 -1
  98. data/vendor/toolkit/twitter/bootstrap/scaffolding.less +2 -1
  99. data/vendor/toolkit/twitter/bootstrap/sprites.less +9 -5
  100. data/vendor/toolkit/twitter/bootstrap/tables.less +54 -46
  101. data/vendor/toolkit/twitter/bootstrap/thumbnails.less +3 -2
  102. data/vendor/toolkit/twitter/bootstrap/tooltip.less +6 -6
  103. data/vendor/toolkit/twitter/bootstrap/type.less +44 -24
  104. data/vendor/toolkit/twitter/bootstrap/variables.less +3 -3
  105. metadata +130 -44
  106. data/lib/generators/bootstrap/partial/templates/_navbar.html.erb +0 -13
  107. data/vendor/assets/fonts/fontawesome-webfont.eot +0 -0
  108. data/vendor/assets/fonts/fontawesome-webfont.svg +0 -255
  109. data/vendor/assets/fonts/fontawesome-webfont.ttf +0 -0
  110. data/vendor/assets/fonts/fontawesome-webfont.woff +0 -0
  111. data/vendor/assets/stylesheets/twitter-bootstrap-static/fontawesome.css.erb +0 -218
  112. data/vendor/toolkit/font-awesome-ie7.less +0 -245
  113. data/vendor/toolkit/fontawesome.less +0 -327
  114. /data/{vendor → app}/assets/images/twitter/bootstrap/glyphicons-halflings-white.png +0 -0
  115. /data/{vendor → app}/assets/images/twitter/bootstrap/glyphicons-halflings.png +0 -0
  116. /data/{vendor → app}/assets/javascripts/twitter/bootstrap.js +0 -0
  117. /data/{vendor → app}/assets/javascripts/twitter/bootstrap_ujs.js +0 -0
@@ -13,6 +13,10 @@
13
13
  background-color: @warningBackground;
14
14
  border: 1px solid @warningBorder;
15
15
  .border-radius(@baseBorderRadius);
16
+ }
17
+ .alert,
18
+ .alert h4 {
19
+ // Specified for the h4 to prevent conflicts of changing @headingsColor
16
20
  color: @warningText;
17
21
  }
18
22
  .alert h4 {
@@ -36,17 +40,27 @@
36
40
  border-color: @successBorder;
37
41
  color: @successText;
38
42
  }
43
+ .alert-success h4 {
44
+ color: @successText;
45
+ }
39
46
  .alert-danger,
40
47
  .alert-error {
41
48
  background-color: @errorBackground;
42
49
  border-color: @errorBorder;
43
50
  color: @errorText;
44
51
  }
52
+ .alert-danger h4,
53
+ .alert-error h4 {
54
+ color: @errorText;
55
+ }
45
56
  .alert-info {
46
57
  background-color: @infoBackground;
47
58
  border-color: @infoBorder;
48
59
  color: @infoText;
49
60
  }
61
+ .alert-info h4 {
62
+ color: @infoText;
63
+ }
50
64
 
51
65
 
52
66
  // Block alerts
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * Bootstrap v2.2.1
2
+ * Bootstrap v2.3.2
3
3
  *
4
4
  * Copyright 2012 Twitter, Inc
5
5
  * Licensed under the Apache License v2.0
@@ -8,13 +8,13 @@
8
8
  * Designed and built with all the love in the world @twitter by @mdo and @fat.
9
9
  */
10
10
 
11
- // CSS Reset
12
- @import "reset.less";
13
-
14
11
  // Core variables and mixins
15
12
  @import "variables.less"; // Modify this for custom colors, font-sizes, etc
16
13
  @import "mixins.less";
17
14
 
15
+ // CSS Reset
16
+ @import "reset.less";
17
+
18
18
  // Grid system and page structure
19
19
  @import "scaffolding.less";
20
20
  @import "grid.less";
@@ -9,16 +9,16 @@
9
9
  list-style: none;
10
10
  background-color: #f5f5f5;
11
11
  .border-radius(@baseBorderRadius);
12
- li {
12
+ > li {
13
13
  display: inline-block;
14
14
  .ie7-inline-block();
15
15
  text-shadow: 0 1px 0 @white;
16
+ > .divider {
17
+ padding: 0 5px;
18
+ color: #ccc;
19
+ }
16
20
  }
17
- .divider {
18
- padding: 0 5px;
19
- color: #ccc;
20
- }
21
- .active {
21
+ > .active {
22
22
  color: @grayLight;
23
23
  }
24
24
  }
@@ -24,9 +24,9 @@
24
24
  font-size: 0; // Hack to remove whitespace that results from using inline-block
25
25
  margin-top: @baseLineHeight / 2;
26
26
  margin-bottom: @baseLineHeight / 2;
27
- .btn + .btn,
28
- .btn-group + .btn,
29
- .btn + .btn-group {
27
+ > .btn + .btn,
28
+ > .btn-group + .btn,
29
+ > .btn + .btn-group {
30
30
  margin-left: 5px;
31
31
  }
32
32
  }
@@ -40,59 +40,44 @@
40
40
  margin-left: -1px;
41
41
  }
42
42
  .btn-group > .btn,
43
- .btn-group > .dropdown-menu {
43
+ .btn-group > .dropdown-menu,
44
+ .btn-group > .popover {
44
45
  font-size: @baseFontSize; // redeclare as part 2 of font-size inline-block hack
45
46
  }
46
47
 
47
48
  // Reset fonts for other sizes
48
49
  .btn-group > .btn-mini {
49
- font-size: 11px;
50
+ font-size: @fontSizeMini;
50
51
  }
51
52
  .btn-group > .btn-small {
52
- font-size: 12px;
53
+ font-size: @fontSizeSmall;
53
54
  }
54
55
  .btn-group > .btn-large {
55
- font-size: 16px;
56
+ font-size: @fontSizeLarge;
56
57
  }
57
58
 
58
59
  // Set corners individual because sometimes a single button can be in a .btn-group and we need :first-child and :last-child to both match
59
60
  .btn-group > .btn:first-child {
60
61
  margin-left: 0;
61
- -webkit-border-top-left-radius: 4px;
62
- -moz-border-radius-topleft: 4px;
63
- border-top-left-radius: 4px;
64
- -webkit-border-bottom-left-radius: 4px;
65
- -moz-border-radius-bottomleft: 4px;
66
- border-bottom-left-radius: 4px;
62
+ .border-top-left-radius(@baseBorderRadius);
63
+ .border-bottom-left-radius(@baseBorderRadius);
67
64
  }
68
65
  // Need .dropdown-toggle since :last-child doesn't apply given a .dropdown-menu immediately after it
69
66
  .btn-group > .btn:last-child,
70
67
  .btn-group > .dropdown-toggle {
71
- -webkit-border-top-right-radius: 4px;
72
- -moz-border-radius-topright: 4px;
73
- border-top-right-radius: 4px;
74
- -webkit-border-bottom-right-radius: 4px;
75
- -moz-border-radius-bottomright: 4px;
76
- border-bottom-right-radius: 4px;
68
+ .border-top-right-radius(@baseBorderRadius);
69
+ .border-bottom-right-radius(@baseBorderRadius);
77
70
  }
78
71
  // Reset corners for large buttons
79
72
  .btn-group > .btn.large:first-child {
80
73
  margin-left: 0;
81
- -webkit-border-top-left-radius: 6px;
82
- -moz-border-radius-topleft: 6px;
83
- border-top-left-radius: 6px;
84
- -webkit-border-bottom-left-radius: 6px;
85
- -moz-border-radius-bottomleft: 6px;
86
- border-bottom-left-radius: 6px;
74
+ .border-top-left-radius(@borderRadiusLarge);
75
+ .border-bottom-left-radius(@borderRadiusLarge);
87
76
  }
88
77
  .btn-group > .btn.large:last-child,
89
78
  .btn-group > .large.dropdown-toggle {
90
- -webkit-border-top-right-radius: 6px;
91
- -moz-border-radius-topright: 6px;
92
- border-top-right-radius: 6px;
93
- -webkit-border-bottom-right-radius: 6px;
94
- -moz-border-radius-bottomright: 6px;
95
- border-bottom-right-radius: 6px;
79
+ .border-top-right-radius(@borderRadiusLarge);
80
+ .border-bottom-right-radius(@borderRadiusLarge);
96
81
  }
97
82
 
98
83
  // On hover/focus/active, bring the proper btn to front
@@ -179,8 +164,6 @@
179
164
  margin-left: 0;
180
165
  }
181
166
  // Carets in other button sizes
182
- .btn-mini .caret,
183
- .btn-small .caret,
184
167
  .btn-large .caret {
185
168
  margin-top: 6px;
186
169
  }
@@ -189,6 +172,10 @@
189
172
  border-right-width: 5px;
190
173
  border-top-width: 5px;
191
174
  }
175
+ .btn-mini .caret,
176
+ .btn-small .caret {
177
+ margin-top: 8px;
178
+ }
192
179
  // Upside down carets for .dropup
193
180
  .dropup .btn-large .caret {
194
181
  border-bottom-width: 5px;
@@ -218,25 +205,25 @@
218
205
  display: inline-block; // makes buttons only take up the width they need
219
206
  .ie7-inline-block();
220
207
  }
221
- .btn-group-vertical .btn {
208
+ .btn-group-vertical > .btn {
222
209
  display: block;
223
210
  float: none;
224
- width: 100%;
211
+ max-width: 100%;
225
212
  .border-radius(0);
226
213
  }
227
- .btn-group-vertical .btn + .btn {
214
+ .btn-group-vertical > .btn + .btn {
228
215
  margin-left: 0;
229
216
  margin-top: -1px;
230
217
  }
231
- .btn-group-vertical .btn:first-child {
232
- .border-radius(4px 4px 0 0);
218
+ .btn-group-vertical > .btn:first-child {
219
+ .border-radius(@baseBorderRadius @baseBorderRadius 0 0);
233
220
  }
234
- .btn-group-vertical .btn:last-child {
235
- .border-radius(0 0 4px 4px);
221
+ .btn-group-vertical > .btn:last-child {
222
+ .border-radius(0 0 @baseBorderRadius @baseBorderRadius);
236
223
  }
237
- .btn-group-vertical .btn-large:first-child {
238
- .border-radius(6px 6px 0 0);
224
+ .btn-group-vertical > .btn-large:first-child {
225
+ .border-radius(@borderRadiusLarge @borderRadiusLarge 0 0);
239
226
  }
240
- .btn-group-vertical .btn-large:last-child {
241
- .border-radius(0 0 6px 6px);
227
+ .btn-group-vertical > .btn-large:last-child {
228
+ .border-radius(0 0 @borderRadiusLarge @borderRadiusLarge);
242
229
  }
@@ -14,7 +14,6 @@
14
14
  margin-bottom: 0; // For input.btn
15
15
  font-size: @baseFontSize;
16
16
  line-height: @baseLineHeight;
17
- *line-height: @baseLineHeight;
18
17
  text-align: center;
19
18
  vertical-align: middle;
20
19
  cursor: pointer;
@@ -26,15 +25,14 @@
26
25
  .ie7-restore-left-whitespace(); // Give IE7 some love
27
26
  .box-shadow(~"inset 0 1px 0 rgba(255,255,255,.2), 0 1px 2px rgba(0,0,0,.05)");
28
27
 
29
- // Hover state
30
- &:hover {
28
+ // Hover/focus state
29
+ &:hover,
30
+ &:focus {
31
31
  color: @grayDark;
32
32
  text-decoration: none;
33
- background-color: darken(@white, 10%);
34
- *background-color: darken(@white, 15%); /* Buttons in IE7 don't get borders, so darken on hover */
35
33
  background-position: 0 -15px;
36
34
 
37
- // transition is only when going to hover, otherwise the background
35
+ // transition is only when going to hover/focus, otherwise the background
38
36
  // behind the gradient (there for IE<=9 fallback) gets mismatched
39
37
  .transition(background-position .1s linear);
40
38
  }
@@ -47,8 +45,6 @@
47
45
  // Active state
48
46
  &.active,
49
47
  &:active {
50
- background-color: darken(@white, 10%);
51
- background-color: darken(@white, 15%) e("\9");
52
48
  background-image: none;
53
49
  outline: 0;
54
50
  .box-shadow(~"inset 0 2px 4px rgba(0,0,0,.15), 0 1px 2px rgba(0,0,0,.05)");
@@ -58,7 +54,6 @@
58
54
  &.disabled,
59
55
  &[disabled] {
60
56
  cursor: default;
61
- background-color: darken(@white, 10%);
62
57
  background-image: none;
63
58
  .opacity(65);
64
59
  .box-shadow(none);
@@ -79,7 +74,7 @@
79
74
  }
80
75
  .btn-large [class^="icon-"],
81
76
  .btn-large [class*=" icon-"] {
82
- margin-top: 2px;
77
+ margin-top: 4px;
83
78
  }
84
79
 
85
80
  // Small
@@ -92,6 +87,10 @@
92
87
  .btn-small [class*=" icon-"] {
93
88
  margin-top: 0;
94
89
  }
90
+ .btn-mini [class^="icon-"],
91
+ .btn-mini [class*=" icon-"] {
92
+ margin-top: -1px;
93
+ }
95
94
 
96
95
  // Mini
97
96
  .btn-mini {
@@ -143,11 +142,6 @@ input[type="button"] {
143
142
 
144
143
  // Set the backgrounds
145
144
  // -------------------------
146
- .btn {
147
- // reset here as of 2.0.3 due to Recess property order
148
- border-color: #c5c5c5;
149
- border-color: rgba(0,0,0,.15) rgba(0,0,0,.15) rgba(0,0,0,.25);
150
- }
151
145
  .btn-primary {
152
146
  .buttonBackground(@btnPrimaryBackground, @btnPrimaryBackgroundHighlight);
153
147
  }
@@ -221,12 +215,14 @@ input[type="submit"].btn {
221
215
  color: @linkColor;
222
216
  .border-radius(0);
223
217
  }
224
- .btn-link:hover {
218
+ .btn-link:hover,
219
+ .btn-link:focus {
225
220
  color: @linkColorHover;
226
221
  text-decoration: underline;
227
222
  background-color: transparent;
228
223
  }
229
- .btn-link[disabled]:hover {
224
+ .btn-link[disabled]:hover,
225
+ .btn-link[disabled]:focus {
230
226
  color: @grayDark;
231
227
  text-decoration: none;
232
228
  }
@@ -15,50 +15,51 @@
15
15
  position: relative;
16
16
  }
17
17
 
18
- .carousel {
18
+ .carousel-inner {
19
19
 
20
- .item {
20
+ > .item {
21
21
  display: none;
22
22
  position: relative;
23
23
  .transition(.6s ease-in-out left);
24
- }
25
24
 
26
- // Account for jankitude on images
27
- .item > img {
28
- display: block;
29
- line-height: 1;
25
+ // Account for jankitude on images
26
+ > img,
27
+ > a > img {
28
+ display: block;
29
+ line-height: 1;
30
+ }
30
31
  }
31
32
 
32
- .active,
33
- .next,
34
- .prev { display: block; }
33
+ > .active,
34
+ > .next,
35
+ > .prev { display: block; }
35
36
 
36
- .active {
37
+ > .active {
37
38
  left: 0;
38
39
  }
39
40
 
40
- .next,
41
- .prev {
41
+ > .next,
42
+ > .prev {
42
43
  position: absolute;
43
44
  top: 0;
44
45
  width: 100%;
45
46
  }
46
47
 
47
- .next {
48
+ > .next {
48
49
  left: 100%;
49
50
  }
50
- .prev {
51
+ > .prev {
51
52
  left: -100%;
52
53
  }
53
- .next.left,
54
- .prev.right {
54
+ > .next.left,
55
+ > .prev.right {
55
56
  left: 0;
56
57
  }
57
58
 
58
- .active.left {
59
+ > .active.left {
59
60
  left: -100%;
60
61
  }
61
- .active.right {
62
+ > .active.right {
62
63
  left: 100%;
63
64
  }
64
65
 
@@ -97,14 +98,40 @@
97
98
  right: 15px;
98
99
  }
99
100
 
100
- // Hover state
101
- &:hover {
101
+ // Hover/focus state
102
+ &:hover,
103
+ &:focus {
102
104
  color: @white;
103
105
  text-decoration: none;
104
106
  .opacity(90);
105
107
  }
106
108
  }
107
109
 
110
+ // Carousel indicator pips
111
+ // -----------------------------
112
+ .carousel-indicators {
113
+ position: absolute;
114
+ top: 15px;
115
+ right: 15px;
116
+ z-index: 5;
117
+ margin: 0;
118
+ list-style: none;
119
+
120
+ li {
121
+ display: block;
122
+ float: left;
123
+ width: 10px;
124
+ height: 10px;
125
+ margin-left: 5px;
126
+ text-indent: -999px;
127
+ background-color: #ccc;
128
+ background-color: rgba(255,255,255,.25);
129
+ border-radius: 5px;
130
+ }
131
+ .active {
132
+ background-color: #fff;
133
+ }
134
+ }
108
135
 
109
136
  // Caption for text below images
110
137
  // -----------------------------
@@ -11,7 +11,8 @@
11
11
  color: @black;
12
12
  text-shadow: 0 1px 0 rgba(255,255,255,1);
13
13
  .opacity(20);
14
- &:hover {
14
+ &:hover,
15
+ &:focus {
15
16
  color: @black;
16
17
  text-decoration: none;
17
18
  cursor: pointer;
@@ -19,6 +19,7 @@ code {
19
19
  color: #d14;
20
20
  background-color: #f7f7f9;
21
21
  border: 1px solid #e1e1e8;
22
+ white-space: nowrap;
22
23
  }
23
24
 
24
25
  // Blocks of code
@@ -46,6 +47,8 @@ pre {
46
47
  code {
47
48
  padding: 0;
48
49
  color: inherit;
50
+ white-space: pre;
51
+ white-space: pre-wrap;
49
52
  background-color: transparent;
50
53
  border: 0;
51
54
  }
@@ -72,7 +72,7 @@
72
72
  }
73
73
 
74
74
  // Links within the dropdown menu
75
- li > a {
75
+ > li > a {
76
76
  display: block;
77
77
  padding: 3px 20px;
78
78
  clear: both;
@@ -83,11 +83,12 @@
83
83
  }
84
84
  }
85
85
 
86
- // Hover state
86
+ // Hover/Focus state
87
87
  // -----------
88
- .dropdown-menu li > a:hover,
89
- .dropdown-menu li > a:focus,
90
- .dropdown-submenu:hover > a {
88
+ .dropdown-menu > li > a:hover,
89
+ .dropdown-menu > li > a:focus,
90
+ .dropdown-submenu:hover > a,
91
+ .dropdown-submenu:focus > a {
91
92
  text-decoration: none;
92
93
  color: @dropdownLinkColorHover;
93
94
  #gradient > .vertical(@dropdownLinkBackgroundHover, darken(@dropdownLinkBackgroundHover, 5%));
@@ -95,8 +96,9 @@
95
96
 
96
97
  // Active state
97
98
  // ------------
98
- .dropdown-menu .active > a,
99
- .dropdown-menu .active > a:hover {
99
+ .dropdown-menu > .active > a,
100
+ .dropdown-menu > .active > a:hover,
101
+ .dropdown-menu > .active > a:focus {
100
102
  color: @dropdownLinkColorActive;
101
103
  text-decoration: none;
102
104
  outline: 0;
@@ -105,16 +107,19 @@
105
107
 
106
108
  // Disabled state
107
109
  // --------------
108
- // Gray out text and ensure the hover state remains gray
109
- .dropdown-menu .disabled > a,
110
- .dropdown-menu .disabled > a:hover {
110
+ // Gray out text and ensure the hover/focus state remains gray
111
+ .dropdown-menu > .disabled > a,
112
+ .dropdown-menu > .disabled > a:hover,
113
+ .dropdown-menu > .disabled > a:focus {
111
114
  color: @grayLight;
112
115
  }
113
- // Nuke hover effects
114
- .dropdown-menu .disabled > a:hover {
116
+ // Nuke hover/focus effects
117
+ .dropdown-menu > .disabled > a:hover,
118
+ .dropdown-menu > .disabled > a:focus {
115
119
  text-decoration: none;
116
120
  background-color: transparent;
117
121
  background-image: none; // Remove CSS gradient
122
+ .reset-filter();
118
123
  cursor: default;
119
124
  }
120
125
 
@@ -130,6 +135,17 @@
130
135
  }
131
136
  }
132
137
 
138
+ // Backdrop to catch body clicks on mobile, etc.
139
+ // ---------------------------
140
+ .dropdown-backdrop {
141
+ position: fixed;
142
+ left: 0;
143
+ right: 0;
144
+ bottom: 0;
145
+ top: 0;
146
+ z-index: @zindexDropdown - 10;
147
+ }
148
+
133
149
  // Right aligned dropdowns
134
150
  // ---------------------------
135
151
  .pull-right > .dropdown-menu {
@@ -168,9 +184,7 @@
168
184
  left: 100%;
169
185
  margin-top: -6px;
170
186
  margin-left: -1px;
171
- -webkit-border-radius: 0 6px 6px 6px;
172
- -moz-border-radius: 0 6px 6px 6px;
173
- border-radius: 0 6px 6px 6px;
187
+ .border-radius(0 6px 6px 6px);
174
188
  }
175
189
  .dropdown-submenu:hover > .dropdown-menu {
176
190
  display: block;
@@ -182,9 +196,7 @@
182
196
  bottom: 0;
183
197
  margin-top: 0;
184
198
  margin-bottom: -2px;
185
- -webkit-border-radius: 5px 5px 5px 0;
186
- -moz-border-radius: 5px 5px 5px 0;
187
- border-radius: 5px 5px 5px 0;
199
+ .border-radius(5px 5px 5px 0);
188
200
  }
189
201
 
190
202
  // Caret to indicate there is a submenu
@@ -215,9 +227,7 @@
215
227
  > .dropdown-menu {
216
228
  left: -100%;
217
229
  margin-left: 10px;
218
- -webkit-border-radius: 6px 0 6px 6px;
219
- -moz-border-radius: 6px 0 6px 6px;
220
- border-radius: 6px 0 6px 6px;
230
+ .border-radius(6px 0 6px 6px);
221
231
  }
222
232
  }
223
233
 
@@ -232,6 +242,7 @@
232
242
  // Typeahead
233
243
  // ---------
234
244
  .typeahead {
245
+ z-index: 1051;
235
246
  margin-top: 2px; // give it some space to breathe
236
247
  .border-radius(@baseBorderRadius);
237
248
  }
@@ -138,7 +138,6 @@ input[type="checkbox"] {
138
138
  *margin-top: 0; /* IE7 */
139
139
  margin-top: 1px \9; /* IE8-9 */
140
140
  line-height: normal;
141
- cursor: pointer;
142
141
  }
143
142
 
144
143
  // Reset width of input images, buttons, radios, checkboxes
@@ -367,9 +366,9 @@ input[type="checkbox"][readonly] {
367
366
 
368
367
  // HTML5 invalid states
369
368
  // Shares styles with the .control-group.error above
370
- input:focus:required:invalid,
371
- textarea:focus:required:invalid,
372
- select:focus:required:invalid {
369
+ input:focus:invalid,
370
+ textarea:focus:invalid,
371
+ select:focus:invalid {
373
372
  color: #b94a48;
374
373
  border-color: #ee5f5b;
375
374
  &:focus {
@@ -423,7 +422,9 @@ select:focus:required:invalid {
423
422
  // Allow us to put symbols and text within the input field for a cleaner look
424
423
  .input-append,
425
424
  .input-prepend {
426
- margin-bottom: 5px;
425
+ display: inline-block;
426
+ margin-bottom: @baseLineHeight / 2;
427
+ vertical-align: middle;
427
428
  font-size: 0; // white space collapse hack
428
429
  white-space: nowrap; // Prevent span and input from separating
429
430
 
@@ -431,7 +432,8 @@ select:focus:required:invalid {
431
432
  input,
432
433
  select,
433
434
  .uneditable-input,
434
- .dropdown-menu {
435
+ .dropdown-menu,
436
+ .popover {
435
437
  font-size: @baseFontSize;
436
438
  }
437
439
 
@@ -463,7 +465,8 @@ select:focus:required:invalid {
463
465
  border: 1px solid #ccc;
464
466
  }
465
467
  .add-on,
466
- .btn {
468
+ .btn,
469
+ .btn-group > .dropdown-toggle {
467
470
  vertical-align: top;
468
471
  .border-radius(0);
469
472
  }
@@ -490,7 +493,7 @@ select:focus:required:invalid {
490
493
  select,
491
494
  .uneditable-input {
492
495
  .border-radius(@inputBorderRadius 0 0 @inputBorderRadius);
493
- + .btn-group .btn {
496
+ + .btn-group .btn:last-child {
494
497
  .border-radius(0 @inputBorderRadius @inputBorderRadius 0);
495
498
  }
496
499
  }
@@ -500,7 +503,8 @@ select:focus:required:invalid {
500
503
  margin-left: -1px;
501
504
  }
502
505
  .add-on:last-child,
503
- .btn:last-child {
506
+ .btn:last-child,
507
+ .btn-group:last-child > .dropdown-toggle {
504
508
  .border-radius(0 @inputBorderRadius @inputBorderRadius 0);
505
509
  }
506
510
  }
@@ -671,7 +675,10 @@ legend + .control-group {
671
675
  // And apply it only to .help-block instances that follow a form control
672
676
  input,
673
677
  select,
674
- textarea {
678
+ textarea,
679
+ .uneditable-input,
680
+ .input-prepend,
681
+ .input-append {
675
682
  + .help-block {
676
683
  margin-top: @baseLineHeight / 2;
677
684
  }
@@ -27,10 +27,20 @@
27
27
  .border-radius(9px);
28
28
  }
29
29
 
30
- // Hover state, but only for links
30
+ // Empty labels/badges collapse
31
+ .label,
32
+ .badge {
33
+ &:empty {
34
+ display: none;
35
+ }
36
+ }
37
+
38
+ // Hover/focus state, but only for links
31
39
  a {
32
40
  &.label:hover,
33
- &.badge:hover {
41
+ &.label:focus,
42
+ &.badge:hover,
43
+ &.badge:focus {
34
44
  color: @white;
35
45
  text-decoration: none;
36
46
  cursor: pointer;
@@ -37,10 +37,10 @@
37
37
  // Media image alignment
38
38
  // -------------------------
39
39
 
40
- .media .pull-left {
40
+ .media > .pull-left {
41
41
  margin-right: 10px;
42
42
  }
43
- .media .pull-right {
43
+ .media > .pull-right {
44
44
  margin-left: 10px;
45
45
  }
46
46