Commit 2a3780d
[One Workflow] Fix Actions menu row layout after EUI 116 upgrade (#271409)
Closes elastic/security-team#17599
## Summary
EUI 116 ([#260949](#260949))
routes `EuiSelectableListItem` through the shared `EuiListItemLayout`
(EUI [#9532](elastic/eui#9532)). The new layout
(a) adds `padding-block: 6px` on `.euiSelectableListItem__text` and
`gap: 8px` on `.euiSelectableListItem__content`, (b) drops the
between-row `border-bottom` that EUI 114/115 set on every non-last item,
and (c) shrinks the `.euiSelectableList__groupLabel` horizontal padding
from `12px` to `4px`.
`renderActionOption` in the workflows Actions menu builds a custom icon
+ title + subtitle layout and owns its own spacing, so the new
padding/gap stacked on top — rows grew from ~64 px to 76 px and the
subtitle shifted. The dropped row border also broke the divider lines
the design relies on, and the group label / header no longer sat on the
same left edge as the items.
The fix scopes a few CSS overrides to the menu's `EuiSelectable`:
- `__content { gap: 0 }`
- `__text { padding-block: 0 }`
- `.euiSelectableListItem:not(:last-of-type) { border-bottom: thin }` —
restores the row divider
- `.euiSelectableList__groupLabel { padding-inline: 16px }` — aligns
"Add step" with the icon column
- `header { padding-inline: 16px }` (was `padding: 12px`) — aligns the
popover title and search with the items
Also gated the "Add step" group label on having at least one matching
action, so searches with no step matches no longer leave an orphan label
(matching the existing behavior of the Commands and Jump-to-a-step
groups, per designer feedback).
After the fix, "Actions menu" title, search input, "Add step" label, and
item icons all sit at the same `x = 16` from the popover edge — matching
the [Figma
design](https://www.figma.com/design/bVapoDOKB46hm0pSQXp9nA/One-Workflow--2?node-id=9838-34071).
Item height settles at 65 px with 1 px row borders.
## Before / after
| Current main (bug) | With fix |
|---|---|
|

|

|
### Empty search state
When a search has no matching steps, EuiSelectable's "doesn't match any
options" message shows instead of an orphan "Add step" label:

## Test plan
- [ ] Open the workflows YAML editor, press `⌘K`, confirm rows are tight
(~65 px), divider lines visible between items, subtitle sits directly
under the title next to the icon
- [ ] Confirm title, search input, "Add step" label, and item icons all
sit at the same left edge
- [ ] Click into a connector group (e.g. Triggers) — nested view renders
the same way with dividers
- [ ] Type `Steps: ` to enter the virtualized full-catalog mode — items
render correctly without overlapping
- [ ] Type a query that doesn't match any step — confirm no orphan "Add
step" label
- [ ] No regression in the existing `ActionsMenu` Jest tests
---------
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent a067907 commit 2a3780d
3 files changed
Lines changed: 59 additions & 25 deletions
File tree
Lines changed: 17 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
43 | 43 | | |
44 | 44 | | |
45 | 45 | | |
46 | | - | |
| 46 | + | |
47 | 47 | | |
48 | | - | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
49 | 64 | | |
50 | 65 | | |
51 | 66 | | |
| |||
Lines changed: 26 additions & 22 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
91 | 91 | | |
92 | 92 | | |
93 | 93 | | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
94 | 110 | | |
95 | 111 | | |
96 | 112 | | |
97 | 113 | | |
98 | 114 | | |
99 | 115 | | |
100 | | - | |
| 116 | + | |
101 | 117 | | |
102 | 118 | | |
103 | | - | |
104 | | - | |
105 | | - | |
106 | | - | |
107 | | - | |
108 | | - | |
109 | | - | |
110 | | - | |
111 | | - | |
112 | | - | |
113 | | - | |
114 | | - | |
115 | | - | |
116 | 119 | | |
117 | | - | |
118 | | - | |
119 | | - | |
120 | | - | |
121 | | - | |
122 | | - | |
123 | | - | |
124 | | - | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
125 | 129 | | |
126 | 130 | | |
127 | 131 | | |
| |||
Lines changed: 16 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
417 | 417 | | |
418 | 418 | | |
419 | 419 | | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
420 | 433 | | |
421 | 434 | | |
422 | 435 | | |
423 | 436 | | |
424 | 437 | | |
425 | 438 | | |
| 439 | + | |
426 | 440 | | |
427 | 441 | | |
428 | 442 | | |
| |||
435 | 449 | | |
436 | 450 | | |
437 | 451 | | |
438 | | - | |
| 452 | + | |
| 453 | + | |
439 | 454 | | |
440 | 455 | | |
441 | 456 | | |
| |||
0 commit comments