-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[Security Solution] flyout UI adjustment #108192
Conversation
Pinging @elastic/security-threat-hunting (Team:Threat Hunting) |
@elasticmachine merge upstream |
x-pack/plugins/security_solution/public/common/components/hover_actions/index.tsx
Outdated
Show resolved
Hide resolved
const { browserFields } = useSourcererScope(activeScope); | ||
|
||
const showFilters = | ||
values != null && (enableOverflowButton || (!showTopN && !enableOverflowButton)); |
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.
Can you put a comment here explaining the relationship between showTopN and enableOverflowButton
? Just finding it hard to follow exactly why topN
is chosen over the other actions. It would be helpful too for the overflowBtn
component.. Thanks!
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.
Good point! Here is the comment I put, please let me know if there's better way to put it:
- In the case of
DisableOverflowButton
, we show filters only when topN is NOT opened. As after topN button is clicked, the chart panel replace current hover actions in the hover actions' popover, so we have to hide all the actions. - in the case of
EnableOverflowButton
, we only need to hide all the items in the overflow popover as the chart's panel opens in the overflow popover, so non-overflowed actions are not affected.
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.
Awesome, thank you! The wording is great 😄
@@ -154,7 +154,7 @@ const EventDetailsPanelComponent: React.FC<EventDetailsPanelProps> = ({ | |||
|
|||
return isFlyoutView ? ( | |||
<> | |||
<EuiFlyoutHeader hasBorder> | |||
<EuiFlyoutHeader hasBorder={isHostIsolationPanelOpen ? true : false}> |
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.
you can just pass hasBorder={isHostIsolationPanelOpen}
assuming isHostIsolationPanelOpen
is a boolean? Otherwise you can !!isHostIsolationPanelOpen
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.
yeah, I can just put isHostIsolationPanelOpen 👍
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.
Sweet, thanks!
LGTM 👏 |
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.
LGTM! 🚀
💚 Build SucceededMetrics [docs]Module Count
Async chunks
Page load bundle
History
To update your PR or re-run it, just comment with: |
* styling * fix hover actions * init overflow button for flyout * init overflow button * topN btn * remove popover from topN * fix tests * fix unit test * add use hover action items hook * fix for code review Co-authored-by: Kibana Machine <[email protected]>
💚 Backport successful
This backport PR will be merged automatically after passing CI. |
* styling * fix hover actions * init overflow button for flyout * init overflow button * topN btn * remove popover from topN * fix tests * fix unit test * add use hover action items hook * fix for code review Co-authored-by: Kibana Machine <[email protected]> Co-authored-by: Angela Chuang <[email protected]>
Summary