diff --git a/x-pack/legacy/plugins/lens/public/editor_frame_plugin/editor_frame/suggestion_panel.scss b/x-pack/legacy/plugins/lens/public/editor_frame_plugin/editor_frame/suggestion_panel.scss
index 3c455ef2aca42..d7bc2cbee8d90 100644
--- a/x-pack/legacy/plugins/lens/public/editor_frame_plugin/editor_frame/suggestion_panel.scss
+++ b/x-pack/legacy/plugins/lens/public/editor_frame_plugin/editor_frame/suggestion_panel.scss
@@ -10,25 +10,20 @@
}
.lnsSuggestionsPanel__title {
- margin: $euiSizeS 0 $euiSizeXS;
+ margin-left: $euiSizeXS / 2;
}
.lnsSuggestionsPanel__suggestions {
@include euiScrollBar;
@include lnsOverflowShadowHorizontal;
padding-top: $euiSizeXS;
- overflow-x: auto;
+ overflow-x: scroll;
overflow-y: hidden;
display: flex;
// Padding / negative margins to make room for overflow shadow
padding-left: $euiSizeXS;
margin-left: -$euiSizeXS;
-
- // Add margin to the next of the same type
- > * + * {
- margin-left: $euiSizeS;
- }
}
// These sizes also match canvas' page thumbnails for consistency
@@ -39,12 +34,13 @@ $lnsSuggestionWidth: 150px;
flex: 0 0 auto;
width: $lnsSuggestionWidth !important;
height: $lnsSuggestionHeight;
- // Allows the scrollbar to stay flush to window
- margin-bottom: $euiSize;
+ margin-right: $euiSizeS;
+ margin-left: $euiSizeXS / 2;
+ margin-bottom: $euiSizeXS / 2;
}
-.lnsSuggestionPanel__button--selected {
- background-color: gray;
+.lnsSuggestionPanel__button-isSelected {
+ @include euiFocusRing;
}
.lnsSidebar__suggestionIcon {
@@ -61,3 +57,21 @@ $lnsSuggestionWidth: 150px;
height: $lnsSuggestionHeight - $euiSize;
pointer-events: none;
}
+
+.lnsSuggestionChartWrapper--withLabel {
+ height: $lnsSuggestionHeight - $euiSizeL;
+}
+
+.lnsSuggestionPanel__buttonLabel {
+ @include euiFontSizeXS;
+ display: block;
+ font-weight: $euiFontWeightBold;
+ text-align: center;
+ flex-grow: 0;
+}
+
+/* TYPES */
+.lnsSuggestionChartWrapper--visMetric {
+ padding-left: $euiSizeS;
+ padding-right: $euiSizeS;
+}
diff --git a/x-pack/legacy/plugins/lens/public/editor_frame_plugin/editor_frame/suggestion_panel.tsx b/x-pack/legacy/plugins/lens/public/editor_frame_plugin/editor_frame/suggestion_panel.tsx
index e2ac4ee5895e8..17ef410aca2bb 100644
--- a/x-pack/legacy/plugins/lens/public/editor_frame_plugin/editor_frame/suggestion_panel.tsx
+++ b/x-pack/legacy/plugins/lens/public/editor_frame_plugin/editor_frame/suggestion_panel.tsx
@@ -7,7 +7,16 @@
import _ from 'lodash';
import React, { useState, useEffect, useMemo } from 'react';
import { FormattedMessage } from '@kbn/i18n/react';
-import { EuiIcon, EuiTitle, EuiPanel, EuiIconTip, EuiToolTip, EuiButton } from '@elastic/eui';
+import {
+ EuiIcon,
+ EuiTitle,
+ EuiPanel,
+ EuiIconTip,
+ EuiToolTip,
+ EuiFlexGroup,
+ EuiFlexItem,
+ EuiButtonEmpty,
+} from '@elastic/eui';
import { toExpression, Ast } from '@kbn/interpreter/common';
import { i18n } from '@kbn/i18n';
import classNames from 'classnames';
@@ -62,7 +71,7 @@ const SuggestionPreview = ({
+