mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-30 06:05:30 -05:00
4c2425fe25
* migrating premium badge to BS5 and changing the unit test * fixing unit test * using badge badge-prepend classes for the premium badge * fixing unit test * adding font-weight variable * removing unused CSS * adding aria-hidden GitOrigin-RevId: a1ab2eeedd95ee500c21607abd09a0a8a07289f0
95 lines
1.7 KiB
SCSS
95 lines
1.7 KiB
SCSS
$max-width: 160px;
|
|
|
|
.badge {
|
|
display: inline-flex;
|
|
align-items: stretch;
|
|
max-width: 100%;
|
|
line-height: var(--line-height-01);
|
|
padding: 0 var(--bs-badge-padding-x);
|
|
|
|
&:not(.badge-tag) {
|
|
max-width: $max-width;
|
|
}
|
|
}
|
|
|
|
.badge-prepend {
|
|
margin-right: var(--spacing-02);
|
|
display: flex;
|
|
align-items: center;
|
|
}
|
|
|
|
.badge-close {
|
|
@include reset-button;
|
|
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
flex-shrink: 0;
|
|
padding: 0 var(--spacing-02);
|
|
border-top-right-radius: inherit;
|
|
border-bottom-right-radius: inherit;
|
|
color: inherit;
|
|
user-select: none;
|
|
|
|
.badge-close-icon {
|
|
font-size: $font-size-base;
|
|
}
|
|
}
|
|
|
|
.badge-close,
|
|
.badge-tag-content-btn {
|
|
&:hover {
|
|
background-color: var(--neutral-40);
|
|
}
|
|
}
|
|
|
|
.badge-content {
|
|
@include text-truncate;
|
|
|
|
padding: var(--bs-badge-padding-y) 0;
|
|
}
|
|
|
|
.badge-tag {
|
|
@include body-sm;
|
|
|
|
padding: 0;
|
|
color: $dark;
|
|
|
|
&:hover {
|
|
background-color: var(--neutral-30) !important;
|
|
}
|
|
}
|
|
|
|
.badge-tag-content {
|
|
display: flex;
|
|
align-items: center;
|
|
overflow: hidden;
|
|
max-width: $max-width;
|
|
padding-left: var(--bs-badge-padding-x);
|
|
padding-right: var(--bs-badge-padding-x);
|
|
border-top-left-radius: inherit;
|
|
border-bottom-left-radius: inherit;
|
|
}
|
|
|
|
.badge-tag-content-btn {
|
|
@include reset-button;
|
|
|
|
padding-left: var(--bs-badge-padding-x);
|
|
padding-right: var(--bs-badge-padding-x);
|
|
}
|
|
|
|
.badge-tag-circle {
|
|
display: block;
|
|
margin: var(--spacing-02);
|
|
width: var(--spacing-04);
|
|
height: var(--spacing-04);
|
|
border-radius: 50%;
|
|
}
|
|
|
|
.badge-premium {
|
|
background-color: var(--neutral-20);
|
|
color: var(--neutral-90);
|
|
vertical-align: middle;
|
|
margin-left: 5px;
|
|
font-weight: var(--badge-font-weight);
|
|
}
|