From d7b9fa01065a1c87e1a3e5070647035845dcccd1 Mon Sep 17 00:00:00 2001 From: Ramon Wenger Date: Thu, 11 Apr 2019 17:03:06 +0200 Subject: [PATCH] Make tooltip wrappable --- client/src/components/HelpfulTooltip.vue | 26 +++++++++++------- .../portfolio/NewProjectEntryWizard.vue | 27 ++++++++++--------- 2 files changed, 32 insertions(+), 21 deletions(-) diff --git a/client/src/components/HelpfulTooltip.vue b/client/src/components/HelpfulTooltip.vue index c8329d4d..b3a9e9d1 100644 --- a/client/src/components/HelpfulTooltip.vue +++ b/client/src/components/HelpfulTooltip.vue @@ -1,8 +1,10 @@ @@ -32,25 +34,30 @@ fill: $color-grey; } - &__text { - display: none; + &__tooltip { + visibility: hidden; position: absolute; left: 30px; top: 0px; - white-space: nowrap; + width: 400px; + } + + &__text { + display: inline-table; + width: auto; + background-color: $color-white; border: 1px solid $color-grey; border-radius: 5px; padding: $small-spacing; @include small-text; - &::before { content: ''; position: absolute; left: 0; - top: 16px; - margin-left: -2px; + top: 18px; + margin-left: -1px; border-left: 1px solid $color-grey; border-top: 1px solid $color-grey; background-color: $color-white; @@ -58,10 +65,11 @@ height: 10px; transform: rotate(-45deg) translateY(-50%); } + } - &:hover &__text { - display: grid; + &:hover &__tooltip { + visibility: visible; } } diff --git a/client/src/components/portfolio/NewProjectEntryWizard.vue b/client/src/components/portfolio/NewProjectEntryWizard.vue index e4d60ad8..dfc2da79 100644 --- a/client/src/components/portfolio/NewProjectEntryWizard.vue +++ b/client/src/components/portfolio/NewProjectEntryWizard.vue @@ -1,11 +1,14 @@