-
Notifications
You must be signed in to change notification settings - Fork 8.6k
[SIEM] - Fix Jest test errors and warnings #41712
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
c8339ca
d008475
c223192
8b41433
365c4e6
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -4,15 +4,21 @@ | |
| * you may not use this file except in compliance with the Elastic License. | ||
| */ | ||
|
|
||
| import { EuiButtonIcon, EuiToolTip } from '@elastic/eui'; | ||
| import { EuiButtonIcon, EuiToolTip, EuiIcon } from '@elastic/eui'; | ||
| import * as React from 'react'; | ||
| import styled from 'styled-components'; | ||
|
|
||
| import { ACTION_COLUMN_WIDTH, PositionedIcon } from './common_styles'; | ||
| import { DeleteTimelines, OnOpenTimeline, OpenTimelineResult } from '../types'; | ||
| import { DeleteTimelineModalButton } from '../delete_timeline_modal'; | ||
|
|
||
| import * as i18n from '../translations'; | ||
|
|
||
| const HeaderIcon = styled(EuiIcon)` | ||
| position: relative; | ||
| left: 9px; | ||
| `; | ||
|
|
||
| /** | ||
| * Returns the action columns (e.g. delete, open duplicate timeline) | ||
| */ | ||
|
|
@@ -26,7 +32,12 @@ export const getActionsColumns = ({ | |
| showDeleteAction: boolean; | ||
| }) => { | ||
| const deleteTimelineColumn = { | ||
| align: 'center', | ||
| align: 'right', | ||
| name: ( | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @andrew-goldstein does this look ok to you? it adds a header icon to these columns
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Would you be willing to check with @MichaelMarcialis to see how feels about this change, since it's a departure from the wireframe shown in the screenshot below?
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ah, missed my window to respond. I'll have a look at the change when I pull in |
||
| <EuiToolTip content={i18n.DELETE}> | ||
| <HeaderIcon data-test-subj="delete-header-icon" size="s" color="subdued" type="trash" /> | ||
| </EuiToolTip> | ||
| ), | ||
| field: 'savedObjectId', | ||
| render: (savedObjectId: string, { title }: OpenTimelineResult) => ( | ||
| <PositionedIcon> | ||
|
|
@@ -42,7 +53,12 @@ export const getActionsColumns = ({ | |
| }; | ||
|
|
||
| const openAsDuplicateColumn = { | ||
| align: 'center', | ||
| align: 'right', | ||
| name: ( | ||
| <EuiToolTip content={i18n.OPEN_AS_DUPLICATE}> | ||
| <HeaderIcon data-test-subj="duplicate-header-icon" size="s" color="subdued" type="copy" /> | ||
| </EuiToolTip> | ||
| ), | ||
| field: 'savedObjectId', | ||
| render: (savedObjectId: string, timelineResult: OpenTimelineResult) => ( | ||
| <PositionedIcon> | ||
|
|
||

There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andrew-goldstein does this look ok to you? i think this is a hidden (
1px) column, so I just put a blanknameas it is a required propThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes this looks good. The contents of this field are not rendered. It exists to allow filtering on multiple values like IP addresses, when those values are encoded as an array instead of a string. I ran this branch locally and verified that filtering continues to work for hosts that have multiple IP addresses, i.e.
siem-es.