@gitlab/ui 94.3.0 → 94.4.1

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.
Files changed (95) hide show
  1. package/CHANGELOG.md +14 -0
  2. package/dist/components/base/form/form_input/form_input.js +4 -1
  3. package/package.json +2 -1
  4. package/src/components/base/form/form_input/form_input.vue +4 -1
  5. package/src/vendor/bootstrap/LICENSE +22 -0
  6. package/src/vendor/bootstrap/scss/_alert.scss +52 -0
  7. package/src/vendor/bootstrap/scss/_badge.scss +54 -0
  8. package/src/vendor/bootstrap/scss/_breadcrumb.scss +42 -0
  9. package/src/vendor/bootstrap/scss/_button-group.scss +163 -0
  10. package/src/vendor/bootstrap/scss/_buttons.scss +142 -0
  11. package/src/vendor/bootstrap/scss/_card.scss +286 -0
  12. package/src/vendor/bootstrap/scss/_carousel.scss +200 -0
  13. package/src/vendor/bootstrap/scss/_close.scss +40 -0
  14. package/src/vendor/bootstrap/scss/_code.scss +48 -0
  15. package/src/vendor/bootstrap/scss/_custom-forms.scss +526 -0
  16. package/src/vendor/bootstrap/scss/_dropdown.scss +192 -0
  17. package/src/vendor/bootstrap/scss/_forms.scss +347 -0
  18. package/src/vendor/bootstrap/scss/_functions.scss +190 -0
  19. package/src/vendor/bootstrap/scss/_grid.scss +73 -0
  20. package/src/vendor/bootstrap/scss/_images.scss +42 -0
  21. package/src/vendor/bootstrap/scss/_input-group.scss +211 -0
  22. package/src/vendor/bootstrap/scss/_jumbotron.scss +17 -0
  23. package/src/vendor/bootstrap/scss/_list-group.scss +154 -0
  24. package/src/vendor/bootstrap/scss/_media.scss +8 -0
  25. package/src/vendor/bootstrap/scss/_mixins.scss +47 -0
  26. package/src/vendor/bootstrap/scss/_modal.scss +240 -0
  27. package/src/vendor/bootstrap/scss/_nav.scss +125 -0
  28. package/src/vendor/bootstrap/scss/_navbar.scss +332 -0
  29. package/src/vendor/bootstrap/scss/_pagination.scss +74 -0
  30. package/src/vendor/bootstrap/scss/_popover.scss +170 -0
  31. package/src/vendor/bootstrap/scss/_print.scss +132 -0
  32. package/src/vendor/bootstrap/scss/_progress.scss +47 -0
  33. package/src/vendor/bootstrap/scss/_reboot.scss +484 -0
  34. package/src/vendor/bootstrap/scss/_root.scss +19 -0
  35. package/src/vendor/bootstrap/scss/_spinners.scss +65 -0
  36. package/src/vendor/bootstrap/scss/_tables.scss +185 -0
  37. package/src/vendor/bootstrap/scss/_toasts.scss +46 -0
  38. package/src/vendor/bootstrap/scss/_tooltip.scss +115 -0
  39. package/src/vendor/bootstrap/scss/_transitions.scss +26 -0
  40. package/src/vendor/bootstrap/scss/_type.scss +125 -0
  41. package/src/vendor/bootstrap/scss/_utilities.scss +18 -0
  42. package/src/vendor/bootstrap/scss/_variables.scss +1149 -0
  43. package/src/vendor/bootstrap/scss/bootstrap-grid.scss +30 -0
  44. package/src/vendor/bootstrap/scss/bootstrap-reboot.scss +12 -0
  45. package/src/vendor/bootstrap/scss/bootstrap.scss +44 -0
  46. package/src/vendor/bootstrap/scss/mixins/_alert.scss +13 -0
  47. package/src/vendor/bootstrap/scss/mixins/_background-variant.scss +23 -0
  48. package/src/vendor/bootstrap/scss/mixins/_badge.scss +17 -0
  49. package/src/vendor/bootstrap/scss/mixins/_border-radius.scss +76 -0
  50. package/src/vendor/bootstrap/scss/mixins/_box-shadow.scss +20 -0
  51. package/src/vendor/bootstrap/scss/mixins/_breakpoints.scss +123 -0
  52. package/src/vendor/bootstrap/scss/mixins/_buttons.scss +110 -0
  53. package/src/vendor/bootstrap/scss/mixins/_caret.scss +62 -0
  54. package/src/vendor/bootstrap/scss/mixins/_clearfix.scss +7 -0
  55. package/src/vendor/bootstrap/scss/mixins/_deprecate.scss +10 -0
  56. package/src/vendor/bootstrap/scss/mixins/_float.scss +14 -0
  57. package/src/vendor/bootstrap/scss/mixins/_forms.scss +195 -0
  58. package/src/vendor/bootstrap/scss/mixins/_gradients.scss +45 -0
  59. package/src/vendor/bootstrap/scss/mixins/_grid-framework.scss +80 -0
  60. package/src/vendor/bootstrap/scss/mixins/_grid.scss +69 -0
  61. package/src/vendor/bootstrap/scss/mixins/_hover.scss +37 -0
  62. package/src/vendor/bootstrap/scss/mixins/_image.scss +36 -0
  63. package/src/vendor/bootstrap/scss/mixins/_list-group.scss +21 -0
  64. package/src/vendor/bootstrap/scss/mixins/_lists.scss +7 -0
  65. package/src/vendor/bootstrap/scss/mixins/_nav-divider.scss +11 -0
  66. package/src/vendor/bootstrap/scss/mixins/_pagination.scss +22 -0
  67. package/src/vendor/bootstrap/scss/mixins/_reset-text.scss +17 -0
  68. package/src/vendor/bootstrap/scss/mixins/_resize.scss +6 -0
  69. package/src/vendor/bootstrap/scss/mixins/_screen-reader.scss +34 -0
  70. package/src/vendor/bootstrap/scss/mixins/_size.scss +7 -0
  71. package/src/vendor/bootstrap/scss/mixins/_table-row.scss +39 -0
  72. package/src/vendor/bootstrap/scss/mixins/_text-emphasis.scss +17 -0
  73. package/src/vendor/bootstrap/scss/mixins/_text-hide.scss +11 -0
  74. package/src/vendor/bootstrap/scss/mixins/_text-truncate.scss +8 -0
  75. package/src/vendor/bootstrap/scss/mixins/_transition.scss +26 -0
  76. package/src/vendor/bootstrap/scss/mixins/_visibility.scss +8 -0
  77. package/src/vendor/bootstrap/scss/utilities/_align.scss +8 -0
  78. package/src/vendor/bootstrap/scss/utilities/_background.scss +19 -0
  79. package/src/vendor/bootstrap/scss/utilities/_borders.scss +75 -0
  80. package/src/vendor/bootstrap/scss/utilities/_clearfix.scss +3 -0
  81. package/src/vendor/bootstrap/scss/utilities/_display.scss +26 -0
  82. package/src/vendor/bootstrap/scss/utilities/_embed.scss +39 -0
  83. package/src/vendor/bootstrap/scss/utilities/_flex.scss +51 -0
  84. package/src/vendor/bootstrap/scss/utilities/_float.scss +11 -0
  85. package/src/vendor/bootstrap/scss/utilities/_interactions.scss +5 -0
  86. package/src/vendor/bootstrap/scss/utilities/_overflow.scss +5 -0
  87. package/src/vendor/bootstrap/scss/utilities/_position.scss +32 -0
  88. package/src/vendor/bootstrap/scss/utilities/_screenreaders.scss +11 -0
  89. package/src/vendor/bootstrap/scss/utilities/_shadows.scss +6 -0
  90. package/src/vendor/bootstrap/scss/utilities/_sizing.scss +20 -0
  91. package/src/vendor/bootstrap/scss/utilities/_spacing.scss +73 -0
  92. package/src/vendor/bootstrap/scss/utilities/_stretched-link.scss +19 -0
  93. package/src/vendor/bootstrap/scss/utilities/_text.scss +72 -0
  94. package/src/vendor/bootstrap/scss/utilities/_visibility.scss +13 -0
  95. package/src/vendor/bootstrap/scss/vendor/_rfs.scss +228 -0
package/CHANGELOG.md CHANGED
@@ -1,3 +1,17 @@
1
+ ## [94.4.1](https://gitlab.com/gitlab-org/gitlab-ui/compare/v94.4.0...v94.4.1) (2024-09-26)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * **GlFormInput:** Set `noWheel` to `true` for number inputs ([a218651](https://gitlab.com/gitlab-org/gitlab-ui/commit/a218651603df75f4568fb1ffdee9d1729ff50450))
7
+
8
+ # [94.4.0](https://gitlab.com/gitlab-org/gitlab-ui/compare/v94.3.0...v94.4.0) (2024-09-26)
9
+
10
+
11
+ ### Features
12
+
13
+ * Add vendored bootstrap@4.6.2 SCSS ([d0181d5](https://gitlab.com/gitlab-org/gitlab-ui/commit/d0181d582f881a9756e9ba35c10942c0d1df495e))
14
+
1
15
  # [94.3.0](https://gitlab.com/gitlab-org/gitlab-ui/compare/v94.2.0...v94.3.0) (2024-09-25)
2
16
 
3
17
 
@@ -84,6 +84,9 @@ var script = {
84
84
  _this.$emit(MODEL_EVENT, ...args);
85
85
  }
86
86
  };
87
+ },
88
+ noWheel() {
89
+ return this.$attrs.type === 'number';
87
90
  }
88
91
  }
89
92
  };
@@ -92,7 +95,7 @@ var script = {
92
95
  const __vue_script__ = script;
93
96
 
94
97
  /* template */
95
- var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('b-form-input',_vm._g(_vm._b({staticClass:"gl-form-input",class:_vm.cssClasses,attrs:{"no-wheel":""}},'b-form-input',_vm.$attrs,false),_vm.listeners))};
98
+ var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('b-form-input',_vm._g(_vm._b({staticClass:"gl-form-input",class:_vm.cssClasses,attrs:{"no-wheel":_vm.noWheel}},'b-form-input',_vm.$attrs,false),_vm.listeners))};
96
99
  var __vue_staticRenderFns__ = [];
97
100
 
98
101
  /* style */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gitlab/ui",
3
- "version": "94.3.0",
3
+ "version": "94.4.1",
4
4
  "description": "GitLab UI Components",
5
5
  "license": "MIT",
6
6
  "main": "dist/index.js",
@@ -22,6 +22,7 @@
22
22
  "tailwind.defaults.js",
23
23
  "!src/vendor",
24
24
  "src/vendor/bootstrap-vue/src/**/*.{js,scss}",
25
+ "src/vendor/bootstrap/scss/**/*.scss",
25
26
  "!*.stories.js",
26
27
  "!*.snap",
27
28
  "!*.spec.{js,scss}"
@@ -80,6 +80,9 @@ export default {
80
80
  },
81
81
  };
82
82
  },
83
+ noWheel() {
84
+ return this.$attrs.type === 'number';
85
+ },
83
86
  },
84
87
  };
85
88
  </script>
@@ -88,7 +91,7 @@ export default {
88
91
  <b-form-input
89
92
  class="gl-form-input"
90
93
  :class="cssClasses"
91
- no-wheel
94
+ :no-wheel="noWheel"
92
95
  v-bind="$attrs"
93
96
  v-on="listeners"
94
97
  />
@@ -0,0 +1,22 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2011-2022 Twitter, Inc.
4
+ Copyright (c) 2011-2022 The Bootstrap Authors
5
+
6
+ Permission is hereby granted, free of charge, to any person obtaining a copy
7
+ of this software and associated documentation files (the "Software"), to deal
8
+ in the Software without restriction, including without limitation the rights
9
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
+ copies of the Software, and to permit persons to whom the Software is
11
+ furnished to do so, subject to the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be included in
14
+ all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
22
+ THE SOFTWARE.
@@ -0,0 +1,52 @@
1
+ //
2
+ // Base styles
3
+ //
4
+
5
+ .alert {
6
+ position: relative;
7
+ padding: $alert-padding-y $alert-padding-x;
8
+ margin-bottom: $alert-margin-bottom;
9
+ border: $alert-border-width solid transparent;
10
+ @include border-radius($alert-border-radius);
11
+ }
12
+
13
+ // Headings for larger alerts
14
+ .alert-heading {
15
+ // Specified to prevent conflicts of changing $headings-color
16
+ color: inherit;
17
+ }
18
+
19
+ // Provide class for links that match alerts
20
+ .alert-link {
21
+ font-weight: $alert-link-font-weight;
22
+ }
23
+
24
+
25
+ // Dismissible alerts
26
+ //
27
+ // Expand the right padding and account for the close button's positioning.
28
+
29
+ .alert-dismissible {
30
+ padding-right: $close-font-size + $alert-padding-x * 2;
31
+
32
+ // Adjust close link position
33
+ .close {
34
+ position: absolute;
35
+ top: 0;
36
+ right: 0;
37
+ z-index: 2;
38
+ padding: $alert-padding-y $alert-padding-x;
39
+ color: inherit;
40
+ }
41
+ }
42
+
43
+
44
+ // Alternate styles
45
+ //
46
+ // Generate contextual modifier classes for colorizing the alert.
47
+
48
+ @each $color, $value in $theme-colors {
49
+ .alert-#{$color} {
50
+ @include alert-variant(theme-color-level($color, $alert-bg-level), theme-color-level($color, $alert-border-level), theme-color-level($color, $alert-color-level));
51
+ }
52
+ }
@@ -0,0 +1,54 @@
1
+ // Base class
2
+ //
3
+ // Requires one of the contextual, color modifier classes for `color` and
4
+ // `background-color`.
5
+
6
+ .badge {
7
+ display: inline-block;
8
+ padding: $badge-padding-y $badge-padding-x;
9
+ @include font-size($badge-font-size);
10
+ font-weight: $badge-font-weight;
11
+ line-height: 1;
12
+ text-align: center;
13
+ white-space: nowrap;
14
+ vertical-align: baseline;
15
+ @include border-radius($badge-border-radius);
16
+ @include transition($badge-transition);
17
+
18
+ @at-root a#{&} {
19
+ @include hover-focus() {
20
+ text-decoration: none;
21
+ }
22
+ }
23
+
24
+ // Empty badges collapse automatically
25
+ &:empty {
26
+ display: none;
27
+ }
28
+ }
29
+
30
+ // Quick fix for badges in buttons
31
+ .btn .badge {
32
+ position: relative;
33
+ top: -1px;
34
+ }
35
+
36
+ // Pill badges
37
+ //
38
+ // Make them extra rounded with a modifier to replace v3's badges.
39
+
40
+ .badge-pill {
41
+ padding-right: $badge-pill-padding-x;
42
+ padding-left: $badge-pill-padding-x;
43
+ @include border-radius($badge-pill-border-radius);
44
+ }
45
+
46
+ // Colors
47
+ //
48
+ // Contextual variations (linked badges get darker on :hover).
49
+
50
+ @each $color, $value in $theme-colors {
51
+ .badge-#{$color} {
52
+ @include badge-variant($value);
53
+ }
54
+ }
@@ -0,0 +1,42 @@
1
+ .breadcrumb {
2
+ display: flex;
3
+ flex-wrap: wrap;
4
+ padding: $breadcrumb-padding-y $breadcrumb-padding-x;
5
+ margin-bottom: $breadcrumb-margin-bottom;
6
+ @include font-size($breadcrumb-font-size);
7
+ list-style: none;
8
+ background-color: $breadcrumb-bg;
9
+ @include border-radius($breadcrumb-border-radius);
10
+ }
11
+
12
+ .breadcrumb-item {
13
+ // The separator between breadcrumbs (by default, a forward-slash: "/")
14
+ + .breadcrumb-item {
15
+ padding-left: $breadcrumb-item-padding;
16
+
17
+ &::before {
18
+ float: left; // Suppress inline spacings and underlining of the separator
19
+ padding-right: $breadcrumb-item-padding;
20
+ color: $breadcrumb-divider-color;
21
+ content: escape-svg($breadcrumb-divider);
22
+ }
23
+ }
24
+
25
+ // IE9-11 hack to properly handle hyperlink underlines for breadcrumbs built
26
+ // without `<ul>`s. The `::before` pseudo-element generates an element
27
+ // *within* the .breadcrumb-item and thereby inherits the `text-decoration`.
28
+ //
29
+ // To trick IE into suppressing the underline, we give the pseudo-element an
30
+ // underline and then immediately remove it.
31
+ + .breadcrumb-item:hover::before {
32
+ text-decoration: underline;
33
+ }
34
+ // stylelint-disable-next-line no-duplicate-selectors
35
+ + .breadcrumb-item:hover::before {
36
+ text-decoration: none;
37
+ }
38
+
39
+ &.active {
40
+ color: $breadcrumb-active-color;
41
+ }
42
+ }
@@ -0,0 +1,163 @@
1
+ // stylelint-disable selector-no-qualifying-type
2
+
3
+ // Make the div behave like a button
4
+ .btn-group,
5
+ .btn-group-vertical {
6
+ position: relative;
7
+ display: inline-flex;
8
+ vertical-align: middle; // match .btn alignment given font-size hack above
9
+
10
+ > .btn {
11
+ position: relative;
12
+ flex: 1 1 auto;
13
+
14
+ // Bring the hover, focused, and "active" buttons to the front to overlay
15
+ // the borders properly
16
+ @include hover() {
17
+ z-index: 1;
18
+ }
19
+ &:focus,
20
+ &:active,
21
+ &.active {
22
+ z-index: 1;
23
+ }
24
+ }
25
+ }
26
+
27
+ // Optional: Group multiple button groups together for a toolbar
28
+ .btn-toolbar {
29
+ display: flex;
30
+ flex-wrap: wrap;
31
+ justify-content: flex-start;
32
+
33
+ .input-group {
34
+ width: auto;
35
+ }
36
+ }
37
+
38
+ .btn-group {
39
+ // Prevent double borders when buttons are next to each other
40
+ > .btn:not(:first-child),
41
+ > .btn-group:not(:first-child) {
42
+ margin-left: -$btn-border-width;
43
+ }
44
+
45
+ // Reset rounded corners
46
+ > .btn:not(:last-child):not(.dropdown-toggle),
47
+ > .btn-group:not(:last-child) > .btn {
48
+ @include border-right-radius(0);
49
+ }
50
+
51
+ > .btn:not(:first-child),
52
+ > .btn-group:not(:first-child) > .btn {
53
+ @include border-left-radius(0);
54
+ }
55
+ }
56
+
57
+ // Sizing
58
+ //
59
+ // Remix the default button sizing classes into new ones for easier manipulation.
60
+
61
+ .btn-group-sm > .btn { @extend .btn-sm; }
62
+ .btn-group-lg > .btn { @extend .btn-lg; }
63
+
64
+
65
+ //
66
+ // Split button dropdowns
67
+ //
68
+
69
+ .dropdown-toggle-split {
70
+ padding-right: $btn-padding-x * .75;
71
+ padding-left: $btn-padding-x * .75;
72
+
73
+ &::after,
74
+ .dropup &::after,
75
+ .dropright &::after {
76
+ margin-left: 0;
77
+ }
78
+
79
+ .dropleft &::before {
80
+ margin-right: 0;
81
+ }
82
+ }
83
+
84
+ .btn-sm + .dropdown-toggle-split {
85
+ padding-right: $btn-padding-x-sm * .75;
86
+ padding-left: $btn-padding-x-sm * .75;
87
+ }
88
+
89
+ .btn-lg + .dropdown-toggle-split {
90
+ padding-right: $btn-padding-x-lg * .75;
91
+ padding-left: $btn-padding-x-lg * .75;
92
+ }
93
+
94
+
95
+ // The clickable button for toggling the menu
96
+ // Set the same inset shadow as the :active state
97
+ .btn-group.show .dropdown-toggle {
98
+ @include box-shadow($btn-active-box-shadow);
99
+
100
+ // Show no shadow for `.btn-link` since it has no other button styles.
101
+ &.btn-link {
102
+ @include box-shadow(none);
103
+ }
104
+ }
105
+
106
+
107
+ //
108
+ // Vertical button groups
109
+ //
110
+
111
+ .btn-group-vertical {
112
+ flex-direction: column;
113
+ align-items: flex-start;
114
+ justify-content: center;
115
+
116
+ > .btn,
117
+ > .btn-group {
118
+ width: 100%;
119
+ }
120
+
121
+ > .btn:not(:first-child),
122
+ > .btn-group:not(:first-child) {
123
+ margin-top: -$btn-border-width;
124
+ }
125
+
126
+ // Reset rounded corners
127
+ > .btn:not(:last-child):not(.dropdown-toggle),
128
+ > .btn-group:not(:last-child) > .btn {
129
+ @include border-bottom-radius(0);
130
+ }
131
+
132
+ > .btn:not(:first-child),
133
+ > .btn-group:not(:first-child) > .btn {
134
+ @include border-top-radius(0);
135
+ }
136
+ }
137
+
138
+
139
+ // Checkbox and radio options
140
+ //
141
+ // In order to support the browser's form validation feedback, powered by the
142
+ // `required` attribute, we have to "hide" the inputs via `clip`. We cannot use
143
+ // `display: none;` or `visibility: hidden;` as that also hides the popover.
144
+ // Simply visually hiding the inputs via `opacity` would leave them clickable in
145
+ // certain cases which is prevented by using `clip` and `pointer-events`.
146
+ // This way, we ensure a DOM element is visible to position the popover from.
147
+ //
148
+ // See https://github.com/twbs/bootstrap/pull/12794 and
149
+ // https://github.com/twbs/bootstrap/pull/14559 for more information.
150
+
151
+ .btn-group-toggle {
152
+ > .btn,
153
+ > .btn-group > .btn {
154
+ margin-bottom: 0; // Override default `<label>` value
155
+
156
+ input[type="radio"],
157
+ input[type="checkbox"] {
158
+ position: absolute;
159
+ clip: rect(0, 0, 0, 0);
160
+ pointer-events: none;
161
+ }
162
+ }
163
+ }
@@ -0,0 +1,142 @@
1
+ // stylelint-disable selector-no-qualifying-type
2
+
3
+ //
4
+ // Base styles
5
+ //
6
+
7
+ .btn {
8
+ display: inline-block;
9
+ font-family: $btn-font-family;
10
+ font-weight: $btn-font-weight;
11
+ color: $body-color;
12
+ text-align: center;
13
+ text-decoration: if($link-decoration == none, null, none);
14
+ white-space: $btn-white-space;
15
+ vertical-align: middle;
16
+ user-select: none;
17
+ background-color: transparent;
18
+ border: $btn-border-width solid transparent;
19
+ @include button-size($btn-padding-y, $btn-padding-x, $btn-font-size, $btn-line-height, $btn-border-radius);
20
+ @include transition($btn-transition);
21
+
22
+ @include hover() {
23
+ color: $body-color;
24
+ text-decoration: none;
25
+ }
26
+
27
+ &:focus,
28
+ &.focus {
29
+ outline: 0;
30
+ box-shadow: $btn-focus-box-shadow;
31
+ }
32
+
33
+ // Disabled comes first so active can properly restyle
34
+ &.disabled,
35
+ &:disabled {
36
+ opacity: $btn-disabled-opacity;
37
+ @include box-shadow(none);
38
+ }
39
+
40
+ &:not(:disabled):not(.disabled) {
41
+ cursor: if($enable-pointer-cursor-for-buttons, pointer, null);
42
+
43
+ &:active,
44
+ &.active {
45
+ @include box-shadow($btn-active-box-shadow);
46
+
47
+ &:focus {
48
+ @include box-shadow($btn-focus-box-shadow, $btn-active-box-shadow);
49
+ }
50
+ }
51
+ }
52
+ }
53
+
54
+ // Future-proof disabling of clicks on `<a>` elements
55
+ a.btn.disabled,
56
+ fieldset:disabled a.btn {
57
+ pointer-events: none;
58
+ }
59
+
60
+
61
+ //
62
+ // Alternate buttons
63
+ //
64
+
65
+ @each $color, $value in $theme-colors {
66
+ .btn-#{$color} {
67
+ @include button-variant($value, $value);
68
+ }
69
+ }
70
+
71
+ @each $color, $value in $theme-colors {
72
+ .btn-outline-#{$color} {
73
+ @include button-outline-variant($value);
74
+ }
75
+ }
76
+
77
+
78
+ //
79
+ // Link buttons
80
+ //
81
+
82
+ // Make a button look and behave like a link
83
+ .btn-link {
84
+ font-weight: $font-weight-normal;
85
+ color: $link-color;
86
+ text-decoration: $link-decoration;
87
+
88
+ @include hover() {
89
+ color: $link-hover-color;
90
+ text-decoration: $link-hover-decoration;
91
+ }
92
+
93
+ &:focus,
94
+ &.focus {
95
+ text-decoration: $link-hover-decoration;
96
+ }
97
+
98
+ &:disabled,
99
+ &.disabled {
100
+ color: $btn-link-disabled-color;
101
+ pointer-events: none;
102
+ }
103
+
104
+ // No need for an active state here
105
+ }
106
+
107
+
108
+ //
109
+ // Button Sizes
110
+ //
111
+
112
+ .btn-lg {
113
+ @include button-size($btn-padding-y-lg, $btn-padding-x-lg, $btn-font-size-lg, $btn-line-height-lg, $btn-border-radius-lg);
114
+ }
115
+
116
+ .btn-sm {
117
+ @include button-size($btn-padding-y-sm, $btn-padding-x-sm, $btn-font-size-sm, $btn-line-height-sm, $btn-border-radius-sm);
118
+ }
119
+
120
+
121
+ //
122
+ // Block button
123
+ //
124
+
125
+ .btn-block {
126
+ display: block;
127
+ width: 100%;
128
+
129
+ // Vertically space out multiple block buttons
130
+ + .btn-block {
131
+ margin-top: $btn-block-spacing-y;
132
+ }
133
+ }
134
+
135
+ // Specificity overrides
136
+ input[type="submit"],
137
+ input[type="reset"],
138
+ input[type="button"] {
139
+ &.btn-block {
140
+ width: 100%;
141
+ }
142
+ }