From e1a527a87aed5392dbbbef41f8e9a18fbab197a9 Mon Sep 17 00:00:00 2001 From: Johannes Schill Date: Tue, 19 Dec 2017 12:58:55 +0100 Subject: [PATCH] ux: Fix color picker positioning when scrolled down to the bottom of a page (#10258) (#10271) --- public/app/core/services/popover_srv.ts | 3 ++- public/app/plugins/panel/graph/legend.ts | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/public/app/core/services/popover_srv.ts b/public/app/core/services/popover_srv.ts index bf0dae2c631..08d5c2bedd0 100644 --- a/public/app/core/services/popover_srv.ts +++ b/public/app/core/services/popover_srv.ts @@ -57,7 +57,7 @@ function popoverSrv($compile, $rootScope, $timeout) { openOn: options.openOn, hoverCloseDelay: 200, tetherOptions: { - constraints: [{to: 'scrollParent', attachment: "none both"}] + constraints: [{to: 'scrollParent', attachment: 'together'}] } }); @@ -79,3 +79,4 @@ function popoverSrv($compile, $rootScope, $timeout) { } coreModule.service('popoverSrv', popoverSrv); + diff --git a/public/app/plugins/panel/graph/legend.ts b/public/app/plugins/panel/graph/legend.ts index 791ebf761ae..bb96f1565c4 100644 --- a/public/app/plugins/panel/graph/legend.ts +++ b/public/app/plugins/panel/graph/legend.ts @@ -53,7 +53,8 @@ module.directive('graphLegend', function(popoverSrv, $timeout) { $timeout(function() { popoverSrv.show({ element: el[0], - position: 'bottom center', + position: 'bottom left', + targetAttachment: 'top left', template: '' + '', openOn: 'hover',