Skip to content
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] EuiDataGrid cellActions not working in Explore pages. #177410

Closed
semd opened this issue Feb 21, 2024 · 6 comments
Closed

[Security Solution] EuiDataGrid cellActions not working in Explore pages. #177410

semd opened this issue Feb 21, 2024 · 6 comments
Assignees
Labels
bug Fixes for quality problems that affect the customer experience EUI impact:critical This issue should be addressed immediately due to a critical level of impact on the product. Team: SecuritySolution Security Solutions Team working on SIEM, Endpoint, Timeline, Resolver, etc. Team:Threat Hunting:Explore triage_needed

Comments

@semd
Copy link
Contributor

semd commented Feb 21, 2024

Describe the bug:
Cell actions are not displayed in the Events tables of Explore pages.

Kibana/Elasticsearch Stack version:
8.13

Functional Area (e.g. Endpoint management, timelines, resolver, etc.):
Explore pages

Steps to reproduce:

  1. Open Security
  2. Navigate to any Explore page (Hosts, Network, Users)
  3. Show results in the Events table
  4. Hover any cell in the table

Current behavior:
Cell actions do not appear

cell_action_not_appear

Expected behavior:
Cell actions appear

cell_action_appear

Screenshots (if relevant):

Cell actions are displayed in Alerts table but not in Events table

cell_actions_explore_not_showing.mov

Any additional context (logs, chat logs, magical formulas, etc.):

Removing/commenting all the setCellProps calls (or the entire useEffect) in the renderCellValue function prop of EuiDataGrid component, fixes the problem and all cell actions appear correctly.

useEffect(() => {
const defaultStyles = { overflow: 'hidden' };
setCellProps({ style: { ...defaultStyles } });
if (ecs && rowData) {
addBuildingBlockStyle(ecs, theme, setCellProps, defaultStyles);
} else {
// disable the cell when it has no data
setCellProps({ style: { display: 'none' } });
}
}, [rowIndex, setCellProps, ecs, rowData]);

@semd semd added bug Fixes for quality problems that affect the customer experience triage_needed Team: SecuritySolution Security Solutions Team working on SIEM, Endpoint, Timeline, Resolver, etc. labels Feb 21, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/security-solution (Team: SecuritySolution)

@MadameSheema MadameSheema added the impact:critical This issue should be addressed immediately due to a critical level of impact on the product. label Feb 21, 2024
@semd
Copy link
Contributor Author

semd commented Feb 21, 2024

These tables have not received any change recently, and considering the problem is fixed by removing a piece of code that has existed for the last 15 months, it is very likely the bug has been introduced by some change in EUI (EUI PRs)

@elasticmachine
Copy link
Contributor

Pinging @elastic/eui-team (EUI)

@elasticmachine
Copy link
Contributor

Pinging @elastic/security-threat-hunting-explore (Team:Threat Hunting:Explore)

@semd
Copy link
Contributor Author

semd commented Feb 21, 2024

I tested different commits and I confirmed the bug was introduced in 7357af5 by EUI update to v91.3.1

@cee-chen
Copy link
Contributor

cee-chen commented Feb 21, 2024

Hey Sergi - line 413 (const defaultStyles = { overflow: 'hidden' };) is the problem here - please remove it from your plugin! EuiDataGrid redesigned its cell actions in v91.3.1 to sit outside the cell instead of inside, and overflow: hidden prevents that.

.euiDataGridRowCell__content already sets overflow: hidden CSS by default, so this custom style shouldn't be needed.

semd added a commit that referenced this issue Feb 21, 2024
## Summary

issue: #177410

Adding `overflow: hidden` style was causing the cell actions to
disappear after the upgrade to [EUI upgrade to
v91.3.1](#173569)

The `overflow: hidden` style is no longer needed, it has been removed.
So cell actions are displayed
kibanamachine pushed a commit to kibanamachine/kibana that referenced this issue Feb 21, 2024
## Summary

issue: elastic#177410

Adding `overflow: hidden` style was causing the cell actions to
disappear after the upgrade to [EUI upgrade to
v91.3.1](elastic#173569)

The `overflow: hidden` style is no longer needed, it has been removed.
So cell actions are displayed

(cherry picked from commit ab864b4)
kibanamachine referenced this issue Feb 21, 2024
#177501)

# Backport

This will backport the following commits from `main` to `8.13`:
- [[Security Solution] Fix cell actions in Explore pages
(#177478)](#177478)

<!--- Backport version: 9.4.3 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"Sergi
Massaneda","email":"sergi.massaneda@elastic.co"},"sourceCommit":{"committedDate":"2024-02-21T17:52:45Z","message":"[Security
Solution] Fix cell actions in Explore pages (#177478)\n\n##
Summary\r\n\r\nissue:
https://github.com/elastic/kibana/issues/177410\r\n\r\nAdding `overflow:
hidden` style was causing the cell actions to\r\ndisappear after the
upgrade to [EUI upgrade
to\r\nv91.3.1](https://github.com/elastic/kibana/pull/173569)\r\n\r\nThe
`overflow: hidden` style is no longer needed, it has been removed.\r\nSo
cell actions are
displayed","sha":"ab864b4ccc699cc1a986bf099460ad877a42333d","branchLabelMapping":{"^v8.14.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["bug","release_note:skip","Team:Threat
Hunting","Team:Threat
Hunting:Explore","v8.13.0","v8.14.0"],"title":"[Security Solution] Fix
cell actions in Explore
pages","number":177478,"url":"https://github.com/elastic/kibana/pull/177478","mergeCommit":{"message":"[Security
Solution] Fix cell actions in Explore pages (#177478)\n\n##
Summary\r\n\r\nissue:
https://github.com/elastic/kibana/issues/177410\r\n\r\nAdding `overflow:
hidden` style was causing the cell actions to\r\ndisappear after the
upgrade to [EUI upgrade
to\r\nv91.3.1](https://github.com/elastic/kibana/pull/173569)\r\n\r\nThe
`overflow: hidden` style is no longer needed, it has been removed.\r\nSo
cell actions are
displayed","sha":"ab864b4ccc699cc1a986bf099460ad877a42333d"}},"sourceBranch":"main","suggestedTargetBranches":["8.13"],"targetPullRequestStates":[{"branch":"8.13","label":"v8.13.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.14.0","branchLabelMappingKey":"^v8.14.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/177478","number":177478,"mergeCommit":{"message":"[Security
Solution] Fix cell actions in Explore pages (#177478)\n\n##
Summary\r\n\r\nissue:
https://github.com/elastic/kibana/issues/177410\r\n\r\nAdding `overflow:
hidden` style was causing the cell actions to\r\ndisappear after the
upgrade to [EUI upgrade
to\r\nv91.3.1](https://github.com/elastic/kibana/pull/173569)\r\n\r\nThe
`overflow: hidden` style is no longer needed, it has been removed.\r\nSo
cell actions are
displayed","sha":"ab864b4ccc699cc1a986bf099460ad877a42333d"}}]}]
BACKPORT-->

Co-authored-by: Sergi Massaneda <sergi.massaneda@elastic.co>
@semd semd self-assigned this Feb 22, 2024
@semd semd closed this as completed Feb 22, 2024
fkanout pushed a commit to fkanout/kibana that referenced this issue Mar 4, 2024
## Summary

issue: elastic#177410

Adding `overflow: hidden` style was causing the cell actions to
disappear after the upgrade to [EUI upgrade to
v91.3.1](elastic#173569)

The `overflow: hidden` style is no longer needed, it has been removed.
So cell actions are displayed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Fixes for quality problems that affect the customer experience EUI impact:critical This issue should be addressed immediately due to a critical level of impact on the product. Team: SecuritySolution Security Solutions Team working on SIEM, Endpoint, Timeline, Resolver, etc. Team:Threat Hunting:Explore triage_needed
Projects
None yet
Development

No branches or pull requests

4 participants