Center delete icon without padding/margin

This commit is contained in:
Henrik Giesel 2021-07-01 21:59:57 +02:00
parent 201773e7c6
commit f2cd23ff22

View file

@ -63,7 +63,7 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
> >
<span>{name}</span> <span>{name}</span>
<Badge <Badge
class="delete-icon rounded ms-1 mt-1" class="delete-icon rounded d-flex align-items-center"
on:click={() => { on:click={() => {
if (!selectMode) { if (!selectMode) {
deleteTag(); deleteTag();
@ -102,19 +102,18 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
&.select-mode { &.select-mode {
cursor: crosshair; cursor: crosshair;
}
}
.selected { &:hover :global(.delete-icon) {
box-shadow: 0 0 0 0.25rem transparentize(button.$focus-color, 0.5) !important;
}
:global(.delete-icon) {
.select-mode:hover & {
opacity: 0; opacity: 0;
} }
}
> :global(svg:hover) { &.selected {
box-shadow: 0 0 0 0.25rem transparentize(button.$focus-color, 0.5) !important;
}
}
:global(.delete-icon > svg:hover) {
$white-translucent: rgba(255 255 255 / 0.5); $white-translucent: rgba(255 255 255 / 0.5);
$dark-translucent: rgba(0 0 0 / 0.2); $dark-translucent: rgba(0 0 0 / 0.2);
@ -126,7 +125,6 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
background-color: $white-translucent; background-color: $white-translucent;
} }
} }
}
@include button.btn-day( @include button.btn-day(
$with-active: false, $with-active: false,