Skip to content

Commit e0de687

Browse files
Hiwsjacobmllr95
andauthored
fix(b-tags): replace spacing utility with static CSS (fixes bootstrap-vue#5523) (bootstrap-vue#5544)
* remove spacing utility * use mt-auto for better centering * update * add new class to avoid issues with custom rendering Co-authored-by: Jacob Müller <jacob.mueller.elz@gmail.com>
1 parent 72a1363 commit e0de687

File tree

3 files changed

+13
-4
lines changed

3 files changed

+13
-4
lines changed

src/components/form-tags/_form-tags.scss

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,12 @@
11
.b-form-tags {
2+
.b-form-tags-list {
3+
margin-top: -0.25rem;
4+
5+
.b-form-tag {
6+
margin-top: 0.25rem;
7+
}
8+
}
9+
210
&.focus {
311
color: $input-focus-color;
412
background-color: $input-focus-bg;
@@ -32,6 +40,7 @@
3240
font-size: 75%;
3341
font-weight: normal;
3442
line-height: $input-line-height;
43+
margin-right: 0.25rem;
3544

3645
&.disabled {
3746
opacity: 0.75;
@@ -43,6 +52,7 @@
4352
font-size: 125%;
4453
line-height: 1;
4554
float: none;
55+
margin-left: 0.25rem;
4656
}
4757
}
4858

src/components/form-tags/form-tag.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ export const BFormTag = /*#__PURE__*/ Vue.extend({
5454
let $remove = h()
5555
if (!this.disabled) {
5656
$remove = h(BButtonClose, {
57-
staticClass: 'b-form-tag-remove ml-1',
57+
staticClass: 'b-form-tag-remove',
5858
props: { ariaLabel: this.removeLabel },
5959
attrs: {
6060
'aria-controls': tagId,

src/components/form-tags/form-tags.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -557,7 +557,6 @@ export const BFormTags = /*#__PURE__*/ Vue.extend({
557557
BFormTag,
558558
{
559559
key: `li-tag__${tag}`,
560-
staticClass: 'mt-1 mr-1',
561560
class: tagClass,
562561
props: {
563562
// `BFormTag` will auto generate an ID
@@ -639,7 +638,7 @@ export const BFormTags = /*#__PURE__*/ Vue.extend({
639638
'li',
640639
{
641640
key: '__li-input__',
642-
staticClass: 'flex-grow-1 mt-1',
641+
staticClass: 'flex-grow-1',
643642
attrs: {
644643
role: 'none',
645644
'aria-live': 'off',
@@ -654,7 +653,7 @@ export const BFormTags = /*#__PURE__*/ Vue.extend({
654653
'ul',
655654
{
656655
key: '_tags_list_',
657-
staticClass: 'list-unstyled mt-n1 mb-0 d-flex flex-wrap align-items-center',
656+
staticClass: 'b-form-tags-list list-unstyled mb-0 d-flex flex-wrap align-items-center',
658657
attrs: { id: tagListId }
659658
},
660659
[$tags, $field]

0 commit comments

Comments
 (0)