From 3736f84c12edc4bbe07e49a3ca67c0ddfa45e098 Mon Sep 17 00:00:00 2001 From: David Hudson Date: Fri, 2 Sep 2016 19:36:39 +0900 Subject: [PATCH] [Frontend] Set plot export buttons to show/hide on hover It's worth noting that I changed the .gl-plot position from relative to absolute in an attempt to match the results to a similar requirement in MCT Table. Setting to absolute caused no regressions as far as I could tell, but I have not attempted browsers outside of Chrome. --- .../general/res/sass/plots/_plots-main.scss | 23 ++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/platform/commonUI/general/res/sass/plots/_plots-main.scss b/platform/commonUI/general/res/sass/plots/_plots-main.scss index 572b5429e3..12f148c0d9 100644 --- a/platform/commonUI/general/res/sass/plots/_plots-main.scss +++ b/platform/commonUI/general/res/sass/plots/_plots-main.scss @@ -20,14 +20,35 @@ * at runtime from the About dialog for additional information. *****************************************************************************/ .abs.holder-plot { + $btnExportH: $btnFrameH; + // Fend off the scrollbar when less than min-height; right: $interiorMargin; + + .s-button.t-export { + @include trans-prop-nice(opacity, $dur: 50ms); + opacity: 0; + } + .gl-plot { + @include trans-prop-nice(top, $dur: 150ms, $delay: 50ms); + top: 0; + } + &:hover { + .s-button.t-export { + @include trans-prop-nice(opacity, 150ms, 100ms); + opacity: 1; + } + .gl-plot { + @include trans-prop-nice(top, $dur: 150ms); + top: $btnExportH + $interiorMargin; + } + } } .gl-plot { color: $colorPlotFg; font-size: 0.7rem; - position: relative; + position: absolute; width: 100%; height: 100%; min-height: $plotMinH;