From f940538d377b3113c617a45590cd759f01def786 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Raimund=20Schl=C3=BC=C3=9Fler?= Date: Wed, 22 Dec 2021 21:58:27 +0100 Subject: [PATCH] Move crumb Actions into hover background area MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Raimund Schlüßler --- src/components/Breadcrumb/Breadcrumb.vue | 83 ++++++++++++++---------- 1 file changed, 48 insertions(+), 35 deletions(-) diff --git a/src/components/Breadcrumb/Breadcrumb.vue b/src/components/Breadcrumb/Breadcrumb.vue index f016a83b06..297ea35640 100644 --- a/src/components/Breadcrumb/Breadcrumb.vue +++ b/src/components/Breadcrumb/Breadcrumb.vue @@ -31,7 +31,11 @@ This component is meant to be used inside a Breadcrumbs component. @@ -239,10 +246,8 @@ export default { &:last-child { max-width: 210px; + font-weight: bold; - a { - flex-shrink: 1; - } // Don't show breadcrumb separator for last crumb .vue-crumb__separator { display: none; @@ -253,37 +258,45 @@ export default { display: none; } - &--with-action a { - padding-right: 2px; + &#{&}--with-action > div { + padding-right: 0; } - &__separator { + &#{&}--only-action > div { padding: 0; - opacity: .7; } - &#{&}--hovered > a { + &#{&}--hovered > div { background-color: var(--color-background-dark); opacity: .7; } - > a { + &__separator { + padding: 0; + opacity: .7; + } + + > div { &:hover, - &:focus { + &:focus-within { background-color: var(--color-background-dark); } - &:focus{ + &:focus-within { opacity: 1; } &:hover { opacity: .7; } + > a { + overflow: hidden; + } opacity: .5; padding: 12px; max-width: 100%; border-radius: var(--border-radius-pill); } + > div, a { align-items: center; display: inline-flex;