From 17d01330083fdd3c252e5a65117af2a1d341f4dc Mon Sep 17 00:00:00 2001
From: kay delaney <45561153+kaydelaney@users.noreply.github.com>
Date: Mon, 30 May 2022 10:31:42 +0100
Subject: [PATCH] Search: Fix overflow issue with folder view (#49723)
---
public/app/features/search/components/DashboardSearch.tsx | 7 +++++--
public/app/features/search/page/components/FolderView.tsx | 5 ++++-
2 files changed, 9 insertions(+), 3 deletions(-)
diff --git a/public/app/features/search/components/DashboardSearch.tsx b/public/app/features/search/components/DashboardSearch.tsx
index 28405ea031d..813f4329f63 100644
--- a/public/app/features/search/components/DashboardSearch.tsx
+++ b/public/app/features/search/components/DashboardSearch.tsx
@@ -22,12 +22,12 @@ export interface Props {
export default function DashboardSearch({ onCloseSearch }: Props) {
if (config.featureToggles.panelTitleSearch) {
// TODO: "folder:current" ????
- return ;
+ return ;
}
return ;
}
-function DashbaordSearchNEW({ onCloseSearch }: Props) {
+function DashboardSearchNew({ onCloseSearch }: Props) {
const styles = useStyles2(getStyles);
const { query, onQueryChange } = useSearchQuery({});
@@ -137,6 +137,8 @@ const getStyles = stylesFactory((theme: GrafanaTheme2) => {
}
`,
container: css`
+ display: flex;
+ flex-direction: column;
max-width: 1400px;
margin: 0 auto;
padding: ${theme.spacing(2)};
@@ -162,6 +164,7 @@ const getStyles = stylesFactory((theme: GrafanaTheme2) => {
search: css`
display: flex;
flex-direction: column;
+ overflow: hidden;
height: 100%;
padding: ${theme.spacing(2, 0, 3, 0)};
`,
diff --git a/public/app/features/search/page/components/FolderView.tsx b/public/app/features/search/page/components/FolderView.tsx
index 32d2efc458e..ee5c4a53a4b 100644
--- a/public/app/features/search/page/components/FolderView.tsx
+++ b/public/app/features/search/page/components/FolderView.tsx
@@ -108,7 +108,10 @@ const getStyles = (theme: GrafanaTheme2) => {
display: flex;
flex-direction: column;
background: ${theme.v1.colors.panelBg};
- border-bottom: solid 1px ${theme.v1.colors.border2};
+
+ &:not(:last-child) {
+ border-bottom: solid 1px ${theme.v1.colors.border2};
+ }
`,
sectionItems: css`
margin: 0 24px 0 32px;