From eb4c2a4b9df93ee35404cd7143cc88b3d44f9d59 Mon Sep 17 00:00:00 2001 From: Dominik Pschenitschni Date: Sat, 12 Nov 2022 10:46:39 +0000 Subject: [PATCH] feat: reduce dropdown-item selector specificity (#2680) Co-authored-by: Dominik Pschenitschni Reviewed-on: https://kolaente.dev/vikunja/frontend/pulls/2680 Co-authored-by: Dominik Pschenitschni Co-committed-by: Dominik Pschenitschni --- src/components/misc/dropdown-item.vue | 36 +++++++++++---------------- 1 file changed, 14 insertions(+), 22 deletions(-) diff --git a/src/components/misc/dropdown-item.vue b/src/components/misc/dropdown-item.vue index 7577e59703..b58548af3c 100644 --- a/src/components/misc/dropdown-item.vue +++ b/src/components/misc/dropdown-item.vue @@ -29,10 +29,6 @@ defineProps() line-height: 1.5; padding: $item-padding; position: relative; -} - -a.dropdown-item, -button.dropdown-item { text-align: inherit; white-space: nowrap; width: 100%; @@ -40,33 +36,29 @@ button.dropdown-item { align-items: center; justify-content: left !important; - &:hover { - background-color: var(--grey-100) !important; - } - &.is-active { background-color: var(--link); color: var(--link-invert); } - .icon { - padding-right: .5rem; - } - - .icon:not(.has-text-success) { - color: var(--grey-300) !important; - } - - &.has-text-danger .icon { - color: var(--danger) !important; + &:hover:not(.is-disabled) { + background-color: var(--grey-100); } &.is-disabled { cursor: not-allowed; - - &:hover { - background-color: transparent; - } } } + +.icon { + padding-right: .5rem; + + &:not(.has-text-success) { + color: var(--grey-300) !important; + } +} + +.has-text-danger .icon { + color: var(--danger) !important; +}