Skip to content

Commit

Permalink
[SIEM][CASE] Change configuration button (elastic#60229)
Browse files Browse the repository at this point in the history
* Change button

* Make URLs constants
  • Loading branch information
cnasikas committed Mar 16, 2020
1 parent 2ddbb89 commit a652039
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import React, { useCallback, useEffect, useMemo, useState } from 'react';
import {
EuiBasicTable,
EuiButton,
EuiButtonIcon,
EuiContextMenuPanel,
EuiEmptyPrompt,
EuiFlexGroup,
Expand Down Expand Up @@ -45,6 +44,9 @@ import { OpenClosedStats } from '../open_closed_stats';
import { getActions } from './actions';
import { CasesTableFilters } from './table_filters';

const CONFIGURE_CASES_URL = getConfigureCasesUrl();
const CREATE_CASE_URL = getCreateCaseUrl();

const Div = styled.div`
margin-top: ${({ theme }) => theme.eui.paddingSizes.m};
`;
Expand Down Expand Up @@ -259,16 +261,14 @@ export const AllCases = React.memo(() => {
/>
</FlexItemDivider>
<EuiFlexItem grow={false}>
<EuiButton fill href={getCreateCaseUrl()} iconType="plusInCircle">
{i18n.CREATE_TITLE}
<EuiButton href={CONFIGURE_CASES_URL} iconType="controlsHorizontal">
{i18n.CONFIGURE_CASES_BUTTON}
</EuiButton>
</EuiFlexItem>
<EuiFlexItem grow={false}>
<EuiButtonIcon
aria-label={i18n.CONFIGURE_CASES_BUTTON}
href={getConfigureCasesUrl()}
iconType="gear"
/>
<EuiButton fill href={CREATE_CASE_URL} iconType="plusInCircle">
{i18n.CREATE_TITLE}
</EuiButton>
</EuiFlexItem>
</EuiFlexGroup>
</CaseHeaderPage>
Expand Down Expand Up @@ -325,7 +325,7 @@ export const AllCases = React.memo(() => {
titleSize="xs"
body={i18n.NO_CASES_BODY}
actions={
<EuiButton fill size="s" href={getCreateCaseUrl()} iconType="plusInCircle">
<EuiButton fill size="s" href={CREATE_CASE_URL} iconType="plusInCircle">
{i18n.ADD_NEW_CASE}
</EuiButton>
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ export const CONFIGURE_CASES_PAGE_TITLE = i18n.translate(
);

export const CONFIGURE_CASES_BUTTON = i18n.translate('xpack.siem.case.configureCasesButton', {
defaultMessage: 'Configure cases',
defaultMessage: 'Edit third-party connection',
});

export const ADD_COMMENT = i18n.translate('xpack.siem.case.caseView.comment.addComment', {
Expand Down

0 comments on commit a652039

Please sign in to comment.