Skip to content

Commit

Permalink
Fix User page tabs Events and External alerts should have the new vis…
Browse files Browse the repository at this point in the history
…ualisation action itens (#129721)
  • Loading branch information
machadoum authored Apr 7, 2022
1 parent 2736f9e commit 08fc776
Showing 1 changed file with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -181,8 +181,10 @@ export const MatrixHistogramComponent: React.FC<MatrixHistogramComponentProps> =
useMatrixHistogramCombined(matrixHistogramRequest);
const [{ pageName }] = useRouteSpy();

const onHostOrNetworkPage =
pageName === SecurityPageName.hosts || pageName === SecurityPageName.network;
const onHostOrNetworkOrUserPage =
pageName === SecurityPageName.hosts ||
pageName === SecurityPageName.network ||
pageName === SecurityPageName.users;

const titleWithStackByField = useMemo(
() => (title != null && typeof title === 'function' ? title(selectedStackByOption) : title),
Expand Down Expand Up @@ -259,11 +261,11 @@ export const MatrixHistogramComponent: React.FC<MatrixHistogramComponentProps> =
toggleQuery={toggleQuery}
subtitle={subtitleWithCounts}
inspectMultiple
showInspectButton={showInspectButton || !onHostOrNetworkPage}
showInspectButton={showInspectButton || !onHostOrNetworkOrUserPage}
isInspectDisabled={filterQuery === undefined}
>
<EuiFlexGroup alignItems="center" gutterSize="none">
{onHostOrNetworkPage && (getLensAttributes || lensAttributes) && timerange && (
{onHostOrNetworkOrUserPage && (getLensAttributes || lensAttributes) && timerange && (
<EuiFlexItem grow={false}>
<CasesContext owner={[APP_ID]} userCanCrud={userCanCrud ?? false}>
<VisualizationActions
Expand Down

0 comments on commit 08fc776

Please sign in to comment.