bootstrap 4.0.0.alpha2 → 4.0.0.alpha3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


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

Files changed (46) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +1 -1
  3. data/assets/javascripts/bootstrap.js +23 -23
  4. data/assets/javascripts/bootstrap.min.js +3 -3
  5. data/assets/javascripts/bootstrap/alert.js +2 -2
  6. data/assets/javascripts/bootstrap/button.js +2 -2
  7. data/assets/javascripts/bootstrap/carousel.js +2 -2
  8. data/assets/javascripts/bootstrap/collapse.js +2 -2
  9. data/assets/javascripts/bootstrap/dropdown.js +2 -2
  10. data/assets/javascripts/bootstrap/modal.js +2 -2
  11. data/assets/javascripts/bootstrap/popover.js +2 -2
  12. data/assets/javascripts/bootstrap/scrollspy.js +2 -2
  13. data/assets/javascripts/bootstrap/tab.js +2 -2
  14. data/assets/javascripts/bootstrap/tooltip.js +2 -2
  15. data/assets/javascripts/bootstrap/util.js +2 -2
  16. data/assets/stylesheets/_bootstrap.scss +1 -1
  17. data/assets/stylesheets/bootstrap/_button-group.scss +2 -2
  18. data/assets/stylesheets/bootstrap/_buttons.scss +1 -1
  19. data/assets/stylesheets/bootstrap/_card.scss +25 -31
  20. data/assets/stylesheets/bootstrap/_code.scss +1 -1
  21. data/assets/stylesheets/bootstrap/_custom-forms.scss +4 -3
  22. data/assets/stylesheets/bootstrap/_dropdown.scss +5 -5
  23. data/assets/stylesheets/bootstrap/_forms.scss +2 -4
  24. data/assets/stylesheets/bootstrap/_images.scss +1 -1
  25. data/assets/stylesheets/bootstrap/_input-group.scss +14 -6
  26. data/assets/stylesheets/bootstrap/_jumbotron.scss +4 -6
  27. data/assets/stylesheets/bootstrap/_labels.scss +1 -1
  28. data/assets/stylesheets/bootstrap/_list-group.scss +15 -3
  29. data/assets/stylesheets/bootstrap/_mixins.scss +1 -0
  30. data/assets/stylesheets/bootstrap/_nav.scss +6 -1
  31. data/assets/stylesheets/bootstrap/_pager.scss +1 -1
  32. data/assets/stylesheets/bootstrap/_pagination.scss +35 -44
  33. data/assets/stylesheets/bootstrap/_popover.scss +2 -2
  34. data/assets/stylesheets/bootstrap/_print.scss +2 -2
  35. data/assets/stylesheets/bootstrap/_reboot.scss +25 -5
  36. data/assets/stylesheets/bootstrap/_responsive-embed.scss +4 -0
  37. data/assets/stylesheets/bootstrap/_tables.scss +12 -12
  38. data/assets/stylesheets/bootstrap/_type.scss +20 -27
  39. data/assets/stylesheets/bootstrap/_utilities-spacing.scss +27 -66
  40. data/assets/stylesheets/bootstrap/_utilities.scss +21 -12
  41. data/assets/stylesheets/bootstrap/_variables.scss +47 -15
  42. data/assets/stylesheets/bootstrap/mixins/_cards.scss +38 -0
  43. data/assets/stylesheets/bootstrap/mixins/_pagination.scss +9 -11
  44. data/lib/bootstrap/version.rb +2 -2
  45. data/templates/project/_bootstrap-variables.scss +45 -13
  46. metadata +3 -2
@@ -10,7 +10,7 @@
10
10
  vertical-align: middle;
11
11
  cursor: pointer;
12
12
  user-select: none;
13
- border: $border-width solid transparent;
13
+ border: $input-btn-border-width solid transparent;
14
14
  @include button-size($btn-padding-y, $btn-padding-x, $font-size-base, $line-height, $btn-border-radius);
15
15
  @include transition(all .2s ease-in-out);
16
16
 
@@ -93,55 +93,49 @@
93
93
  //
94
94
 
95
95
  .card-primary {
96
- background-color: $brand-primary;
97
- border-color: $brand-primary;
96
+ @include card-variant($brand-primary, $brand-primary);
98
97
  }
99
98
  .card-success {
100
- background-color: $brand-success;
101
- border-color: $brand-success;
99
+ @include card-variant($brand-success, $brand-success);
102
100
  }
103
101
  .card-info {
104
- background-color: $brand-info;
105
- border-color: $brand-info;
102
+ @include card-variant($brand-info, $brand-info);
106
103
  }
107
104
  .card-warning {
108
- background-color: $brand-warning;
109
- border-color: $brand-warning;
105
+ @include card-variant($brand-warning, $brand-warning);
110
106
  }
111
107
  .card-danger {
112
- background-color: $brand-danger;
113
- border-color: $brand-danger;
108
+ @include card-variant($brand-danger, $brand-danger);
114
109
  }
115
110
 
111
+ // Remove all backgrounds
112
+ .card-primary-outline {
113
+ @include card-outline-variant($btn-primary-bg);
114
+ }
115
+ .card-secondary-outline {
116
+ @include card-outline-variant($btn-secondary-border);
117
+ }
118
+ .card-info-outline {
119
+ @include card-outline-variant($btn-info-bg);
120
+ }
121
+ .card-success-outline {
122
+ @include card-outline-variant($btn-success-bg);
123
+ }
124
+ .card-warning-outline {
125
+ @include card-outline-variant($btn-warning-bg);
126
+ }
127
+ .card-danger-outline {
128
+ @include card-outline-variant($btn-danger-bg);
129
+ }
116
130
 
117
131
  //
118
132
  // Inverse text within a card for use with dark backgrounds
119
133
  //
120
134
 
121
135
  .card-inverse {
122
- .card-header,
123
- .card-footer {
124
- border-bottom: .075rem solid rgba(255,255,255,.2);
125
- }
126
- .card-header,
127
- .card-footer,
128
- .card-title,
129
- .card-blockquote {
130
- color: #fff;
131
- }
132
- .card-link,
133
- .card-text,
134
- .card-blockquote > footer {
135
- color: rgba(255,255,255,.65);
136
- }
137
- .card-link {
138
- @include hover-focus {
139
- color: $card-link-hover-color;
140
- }
141
- }
136
+ @include card-inverse;
142
137
  }
143
138
 
144
-
145
139
  //
146
140
  // Blockquote
147
141
  //
@@ -27,7 +27,7 @@ kbd {
27
27
  kbd {
28
28
  padding: 0;
29
29
  font-size: 100%;
30
- font-weight: bold;
30
+ font-weight: $nested-kbd-font-weight;
31
31
  @include box-shadow(none);
32
32
  }
33
33
  }
@@ -134,11 +134,12 @@
134
134
  max-width: 100%;
135
135
  padding: .375rem 1.75rem .375rem .75rem;
136
136
  padding-right: .75rem \9;
137
+ color: $input-color;
137
138
  vertical-align: middle;
138
139
  background: #fff url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAUCAMAAACzvE1FAAAADFBMVEUzMzMzMzMzMzMzMzMKAG/3AAAAA3RSTlMAf4C/aSLHAAAAPElEQVR42q3NMQ4AIAgEQTn//2cLdRKppSGzBYwzVXvznNWs8C58CiussPJj8h6NwgorrKRdTvuV9v16Afn0AYFOB7aYAAAAAElFTkSuQmCC) no-repeat right .75rem center;
139
140
  background-image: none \9;
140
141
  background-size: 8px 10px;
141
- border: 1px solid $input-border;
142
+ border: $input-btn-border-width solid $input-border-color;
142
143
  // Use vendor prefixes as `appearance` isn't part of the CSS spec.
143
144
  -moz-appearance: none;
144
145
  -webkit-appearance: none;
@@ -195,7 +196,7 @@
195
196
  color: #555;
196
197
  user-select: none;
197
198
  background-color: #fff;
198
- border: .075rem solid #ddd;
199
+ border: $input-btn-border-width solid #ddd;
199
200
  border-radius: .25rem;
200
201
  @include box-shadow(inset 0 .2rem .4rem rgba(0,0,0,.05));
201
202
  }
@@ -215,7 +216,7 @@
215
216
  color: #555;
216
217
  content: "Browse";
217
218
  background-color: #eee;
218
- border: .075rem solid #ddd;
219
+ border: $input-btn-border-width solid #ddd;
219
220
  border-radius: 0 .25rem .25rem 0;
220
221
  }
221
222
 
@@ -1,4 +1,4 @@
1
- // The dropdown wrapper (div)
1
+ // The dropdown wrapper (`<div>`)
2
2
  .dropup,
3
3
  .dropdown {
4
4
  position: relative;
@@ -34,7 +34,7 @@
34
34
  }
35
35
  }
36
36
 
37
- // The dropdown menu (ul)
37
+ // The dropdown menu
38
38
  .dropdown-menu {
39
39
  position: absolute;
40
40
  top: 100%;
@@ -51,19 +51,19 @@
51
51
  list-style: none;
52
52
  background-color: $dropdown-bg;
53
53
  background-clip: padding-box;
54
- border: 1px solid $dropdown-border;
54
+ border: $dropdown-border-width solid $dropdown-border-color;
55
55
  @include border-radius($border-radius);
56
56
  @include box-shadow(0 6px 12px rgba(0,0,0,.175));
57
57
  }
58
58
 
59
- // Dividers (basically an hr) within the dropdown
59
+ // Dividers (basically an `<hr>`) within the dropdown
60
60
  .dropdown-divider {
61
61
  @include nav-divider($dropdown-divider-bg);
62
62
  }
63
63
 
64
64
  // Links, buttons, and more within the dropdown menu
65
65
  //
66
- // `<button>`-specific styles are denoted with `// for <button>s`
66
+ // `<button>`-specific styles are denoted with `// For <button>s`
67
67
  .dropdown-item {
68
68
  display: block;
69
69
  width: 100%; // For `<button>`s
@@ -14,7 +14,7 @@
14
14
  background-color: $input-bg;
15
15
  // Reset unusual Firefox-on-Android default style; see https://github.com/necolas/normalize.css/issues/214.
16
16
  background-image: none;
17
- border: $border-width solid $input-border;
17
+ border: $input-btn-border-width solid $input-border-color;
18
18
  // Note: This has no effect on <select>s in some browsers, due to the limited stylability of `<select>`s in CSS.
19
19
  @include border-radius($input-border-radius);
20
20
  @include box-shadow($input-box-shadow);
@@ -380,8 +380,6 @@ input[type="checkbox"] {
380
380
  //
381
381
  // Requires wrapping inputs and labels with `.form-group` for proper display of
382
382
  // default HTML form controls and our custom form controls (e.g., input groups).
383
- //
384
- // Heads up! This is mixin-ed into `.navbar-form` in _navbar.scss.
385
383
 
386
384
  .form-inline {
387
385
 
@@ -394,7 +392,7 @@ input[type="checkbox"] {
394
392
  vertical-align: middle;
395
393
  }
396
394
 
397
- // In navbar-form, allow folks to *not* use `.form-group`
395
+ // Allow folks to *not* use `.form-group`
398
396
  .form-control {
399
397
  display: inline-block;
400
398
  width: auto; // Prevent labels from stacking above inputs in `.form-group`
@@ -19,7 +19,7 @@
19
19
  padding: $thumbnail-padding;
20
20
  line-height: $line-height;
21
21
  background-color: $thumbnail-bg;
22
- border: 1px solid $thumbnail-border;
22
+ border: $thumbnail-border-width solid $thumbnail-border-color;
23
23
  border-radius: $thumbnail-border-radius;
24
24
  transition: all .2s ease-in-out;
25
25
  @include box-shadow(0 1px 2px rgba(0,0,0,.075));
@@ -19,6 +19,10 @@
19
19
  // proper border colors.
20
20
  position: relative;
21
21
  z-index: 2;
22
+ // Bring the "active" form control to the front
23
+ @include hover-focus-active {
24
+ z-index: 3;
25
+ }
22
26
  @if $enable-flex {
23
27
  flex: 1;
24
28
  } @else {
@@ -87,7 +91,7 @@
87
91
  color: $input-color;
88
92
  text-align: center;
89
93
  background-color: $input-group-addon-bg;
90
- border: 1px solid $input-group-addon-border-color;
94
+ border: $input-btn-border-width solid $input-group-addon-border-color;
91
95
  @include border-radius($border-radius);
92
96
 
93
97
  // Sizing
@@ -156,26 +160,30 @@
156
160
  > .btn {
157
161
  position: relative;
158
162
  + .btn {
159
- margin-left: -1px;
163
+ margin-left: (-$input-btn-border-width);
160
164
  }
161
165
  // Bring the "active" button to the front
162
166
  @include hover-focus-active {
163
- z-index: 2;
167
+ z-index: 3;
164
168
  }
165
169
  }
166
170
 
167
- // Negative margin to only have a 1px border between the two
171
+ // Negative margin to only have a single, shared border between the two
168
172
  &:first-child {
169
173
  > .btn,
170
174
  > .btn-group {
171
- margin-right: -1px;
175
+ margin-right: (-$input-btn-border-width);
172
176
  }
173
177
  }
174
178
  &:last-child {
175
179
  > .btn,
176
180
  > .btn-group {
177
181
  z-index: 2;
178
- margin-left: -1px;
182
+ margin-left: (-$input-btn-border-width);
183
+ // Because specificity
184
+ @include hover-focus-active {
185
+ z-index: 3;
186
+ }
179
187
  }
180
188
  }
181
189
  }
@@ -3,18 +3,16 @@
3
3
  margin-bottom: $jumbotron-padding;
4
4
  background-color: $jumbotron-bg;
5
5
  @include border-radius($border-radius-lg);
6
+
7
+ @include media-breakpoint-up(sm) {
8
+ padding: ($jumbotron-padding * 2) $jumbotron-padding;
9
+ }
6
10
  }
7
11
 
8
12
  .jumbotron-hr {
9
13
  border-top-color: darken($jumbotron-bg, 10%);
10
14
  }
11
15
 
12
- @include media-breakpoint-up(sm) {
13
- .jumbotron {
14
- padding: ($jumbotron-padding * 2) $jumbotron-padding;
15
- }
16
- }
17
-
18
16
  .jumbotron-fluid {
19
17
  padding-right: 0;
20
18
  padding-left: 0;
@@ -7,7 +7,7 @@
7
7
  display: inline-block;
8
8
  padding: .25em .4em;
9
9
  font-size: 75%;
10
- font-weight: bold;
10
+ font-weight: $label-font-weight;
11
11
  line-height: 1;
12
12
  color: $label-color;
13
13
  text-align: center;
@@ -18,9 +18,9 @@
18
18
  display: block;
19
19
  padding: .75rem 1.25rem;
20
20
  // Place the border on the list items and negative margin up for better styling
21
- margin-bottom: -$border-width;
21
+ margin-bottom: -$list-group-border-width;
22
22
  background-color: $list-group-bg;
23
- border: $border-width solid $list-group-border;
23
+ border: $list-group-border-width solid $list-group-border-color;
24
24
 
25
25
  // Round the first and last items
26
26
  &:first-child {
@@ -34,9 +34,21 @@
34
34
 
35
35
  .list-group-flush {
36
36
  .list-group-item {
37
- border-width: $border-width 0;
37
+ border-width: $list-group-border-width 0;
38
38
  border-radius: 0;
39
39
  }
40
+
41
+ &:first-child {
42
+ .list-group-item:first-child {
43
+ border-top: 0;
44
+ }
45
+ }
46
+
47
+ &:last-child {
48
+ .list-group-item:last-child {
49
+ border-bottom: 0;
50
+ }
51
+ }
40
52
  }
41
53
 
42
54
 
@@ -32,6 +32,7 @@
32
32
  // // Components
33
33
  @import "mixins/alert";
34
34
  @import "mixins/buttons";
35
+ @import "mixins/cards";
35
36
  @import "mixins/pagination";
36
37
  @import "mixins/lists";
37
38
  @import "mixins/list-group";
@@ -32,6 +32,11 @@
32
32
  // Nav inline
33
33
 
34
34
  .nav-inline {
35
+ .nav-item {
36
+ display: inline-block;
37
+ }
38
+
39
+ .nav-item + .nav-item,
35
40
  .nav-link + .nav-link {
36
41
  margin-left: 1rem;
37
42
  }
@@ -59,7 +64,7 @@
59
64
  .nav-link {
60
65
  display: block;
61
66
  padding: $nav-link-padding;
62
- border: 1px solid transparent;
67
+ border: $nav-tabs-link-border-width solid transparent;
63
68
  @include border-radius($border-radius $border-radius 0 0);
64
69
 
65
70
  @include hover-focus {
@@ -14,7 +14,7 @@
14
14
  display: inline-block;
15
15
  padding: 5px 14px;
16
16
  background-color: $pager-bg;
17
- border: 1px solid $pager-border;
17
+ border: $pager-border-width solid $pager-border-color;
18
18
  border-radius: $pager-border-radius;
19
19
  }
20
20
 
@@ -4,48 +4,24 @@
4
4
  margin-top: $spacer-y;
5
5
  margin-bottom: $spacer-y;
6
6
  @include border-radius();
7
+ }
7
8
 
8
- > li {
9
- display: inline; // Remove list-style and block-level defaults
9
+ .page-item {
10
+ display: inline; // Remove list-style and block-level defaults
10
11
 
11
- > a,
12
- > span {
13
- position: relative;
14
- float: left; // Collapse white-space
15
- padding: $pagination-padding-y $pagination-padding-x;
16
- margin-left: -1px;
17
- line-height: $line-height;
18
- color: $pagination-color;
19
- text-decoration: none;
20
- background-color: $pagination-bg;
21
- border: 1px solid $pagination-border;
22
- }
23
- &:first-child {
24
- > a,
25
- > span {
26
- margin-left: 0;
27
- @include border-left-radius($border-radius);
28
- }
29
- }
30
- &:last-child {
31
- > a,
32
- > span {
33
- @include border-right-radius($border-radius);
34
- }
12
+ &:first-child {
13
+ .page-link {
14
+ margin-left: 0;
15
+ @include border-left-radius($border-radius);
35
16
  }
36
17
  }
37
-
38
- > li > a,
39
- > li > span {
40
- @include hover-focus {
41
- color: $pagination-hover-color;
42
- background-color: $pagination-hover-bg;
43
- border-color: $pagination-hover-border;
18
+ &:last-child {
19
+ .page-link {
20
+ @include border-right-radius($border-radius);
44
21
  }
45
22
  }
46
23
 
47
- > .active > a,
48
- > .active > span {
24
+ &.active .page-link {
49
25
  @include plain-hover-focus {
50
26
  z-index: 2;
51
27
  color: $pagination-active-color;
@@ -55,19 +31,34 @@
55
31
  }
56
32
  }
57
33
 
58
- > .disabled {
59
- > span,
60
- > a {
61
- @include plain-hover-focus {
62
- color: $pagination-disabled-color;
63
- cursor: $cursor-disabled;
64
- background-color: $pagination-disabled-bg;
65
- border-color: $pagination-disabled-border;
66
- }
34
+ &.disabled .page-link {
35
+ @include plain-hover-focus {
36
+ color: $pagination-disabled-color;
37
+ cursor: $cursor-disabled;
38
+ background-color: $pagination-disabled-bg;
39
+ border-color: $pagination-disabled-border;
67
40
  }
68
41
  }
69
42
  }
70
43
 
44
+ .page-link {
45
+ position: relative;
46
+ float: left; // Collapse white-space
47
+ padding: $pagination-padding-y $pagination-padding-x;
48
+ margin-left: -1px;
49
+ line-height: $line-height;
50
+ color: $pagination-color;
51
+ text-decoration: none;
52
+ background-color: $pagination-bg;
53
+ border: $pagination-border-width solid $pagination-border-color;
54
+
55
+ @include hover-focus {
56
+ color: $pagination-hover-color;
57
+ background-color: $pagination-hover-bg;
58
+ border-color: $pagination-hover-border;
59
+ }
60
+ }
61
+
71
62
 
72
63
  //
73
64
  // Sizing