From ab0fb195dada2dc3c07d4828a27eb9965ba9d3ec Mon Sep 17 00:00:00 2001 From: Mark Veidemanis Date: Fri, 26 Aug 2022 18:53:49 +0100 Subject: [PATCH] Add tooltips to disabled elements --- core/templates/base.html | 20 ++++++++++++++------ core/templates/ui/drilldown/drilldown.html | 19 +++++++++++++++---- 2 files changed, 29 insertions(+), 10 deletions(-) diff --git a/core/templates/base.html b/core/templates/base.html index 1982d22..cfdddc7 100644 --- a/core/templates/base.html +++ b/core/templates/base.html @@ -95,12 +95,20 @@ border-bottom: 3px solid grey; } - /* @media screen and (min-width: 500px) { - .datetimepicker-wrapper { - position: absolute; - z-index: 100; - } - } */ + .tooltiptext { + visibility: hidden; + background-color: black; + color: #fff; + text-align: center; + padding: 5px 0; + border-radius: 6px; + position: absolute; + z-index: 1; + } + + .rounded-tooltip:hover .tooltiptext { + visibility: visible; + } diff --git a/core/templates/ui/drilldown/drilldown.html b/core/templates/ui/drilldown/drilldown.html index eb2a3ea..676d58b 100644 --- a/core/templates/ui/drilldown/drilldown.html +++ b/core/templates/ui/drilldown/drilldown.html @@ -136,16 +136,23 @@

-
+
+ for="full_query"> + Full query + + {% if not perms.core.query_search %} + No access + {% endif %}
@@ -295,6 +302,7 @@ +
@@ -379,7 +387,7 @@
-
+
@@ -416,6 +424,9 @@

+ {% if not user.is_superuser %} + No access + {% endif %}