Skip to content
Snippets Groups Projects
Commit 7fe2fb35 authored by Piotr Gawron's avatar Piotr Gawron
Browse files

overlays tool tip (with description) is not hidden after few seconds

parent f7cc264c
No related branches found
No related tags found
1 merge request!298Resolve "Duration of text notification (mouseover) in overlay tab"
Pipeline #
...@@ -677,14 +677,14 @@ a.adminLink:hover { ...@@ -677,14 +677,14 @@ a.adminLink:hover {
.minerva-login-form { .minerva-login-form {
height: 100%; height: 100%;
background-color:#FFFFFF; background-color: #FFFFFF;
box-shadow:0 3px 30px #B9B9B9; box-shadow: 0 3px 30px #B9B9B9;
width:320px; width: 320px;
padding:20px; padding: 20px;
margin:20px auto; margin: 20px auto;
color:#666666; color: #666666;
font-size:13px; font-size: 13px;
font-weight:900; font-weight: 900;
} }
.minerva-login-form-title { .minerva-login-form-title {
...@@ -705,21 +705,51 @@ a.adminLink:hover { ...@@ -705,21 +705,51 @@ a.adminLink:hover {
font-weight: 900 font-weight: 900
} }
.minerva-ol-bottom-left{ .minerva-ol-bottom-left {
bottom: .5em; bottom: .5em;
left: .5em; left: .5em;
} }
.minerva-ol-bottom-right{ .minerva-ol-bottom-right {
bottom: .5em; bottom: .5em;
right: .5em; right: .5em;
} }
.minerva-ol-top-right{ .minerva-ol-top-right {
top: .5em; top: .5em;
right: .5em; right: .5em;
} }
.popover { .popover {
max-width: 600px; max-width: 600px;
}
/*
https://www.w3schools.com/css/tryit.asp?filename=trycss_tooltip
*/
.minerva-tooltip {
position: relative;
display: inline-block;
}
.minerva-tooltip .minerva-tooltip-text {
visibility: hidden;
width: 120px;
background-color: black;
color: #fff;
text-align: center;
border-radius: 6px;
padding: 5px 0;
/* Position the tooltip */
position: absolute;
z-index: 1;
}
.minerva-tooltip:hover .minerva-tooltip-text {
visibility: visible;
}
.minerva-overlay-panel {
overflow-x: hidden;
} }
\ No newline at end of file
...@@ -32,6 +32,10 @@ function OverlayPanel(params) { ...@@ -32,6 +32,10 @@ function OverlayPanel(params) {
+ "<p>Custom overlays are user-provided overlays, this menu becomes available upon login (see below).</p>"; + "<p>Custom overlays are user-provided overlays, this menu becomes available upon login (see below).</p>";
Panel.call(this, params); Panel.call(this, params);
//overflow is defined in minerva-overlay-panel, so remove the one that is already there
$(params.element).css("overflow", "");
$(params.element).addClass("minerva-overlay-panel");
var self = this; var self = this;
self._createOverlayPanelGui(); self._createOverlayPanelGui();
...@@ -279,11 +283,6 @@ OverlayPanel.prototype.createOverlayRow = function (overlay, checked) { ...@@ -279,11 +283,6 @@ OverlayPanel.prototype.createOverlayRow = function (overlay, checked) {
* @returns {Array} * @returns {Array}
*/ */
OverlayPanel.prototype.overlayToDataRow = function (overlay, checked) { OverlayPanel.prototype.overlayToDataRow = function (overlay, checked) {
// if (checked && !overlay.getInputDataAvailable()) {
// result.className = "active";
// }
// result.title = overlay.getDescription();
var result = []; var result = [];
result[0] = overlay.getOrder(); result[0] = overlay.getOrder();
result[1] = overlay.getName(); result[1] = overlay.getName();
...@@ -305,6 +304,14 @@ OverlayPanel.prototype.overlayToDataRow = function (overlay, checked) { ...@@ -305,6 +304,14 @@ OverlayPanel.prototype.overlayToDataRow = function (overlay, checked) {
} else { } else {
result[4] = ""; result[4] = "";
} }
if (overlay.getDescription() !== "") {
for (var i = 0; i < result.length; i++) {
result[i] = "<div class=\"minerva-tooltip\">" + result[i] +
"<span class=\"minerva-tooltip-text\">" + overlay.getDescription() + "</span>" +
"</div>";
}
}
return result; return result;
}; };
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment