Skip to content

Commit fcead4f

Browse files
[Security Solution][Resolver] Replace Selectable popover with badges (#76997)
* replace selectable/popover with badges Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
1 parent e3c71a7 commit fcead4f

File tree

3 files changed

+146
-128
lines changed

3 files changed

+146
-128
lines changed

x-pack/plugins/security_solution/public/resolver/view/assets.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@ type ResolverColorNames =
2424
| 'resolverBackground'
2525
| 'resolverEdge'
2626
| 'resolverEdgeText'
27-
| 'resolverBreadcrumbBackground';
27+
| 'resolverBreadcrumbBackground'
28+
| 'pillStroke';
2829

2930
type ColorMap = Record<ResolverColorNames, string>;
3031
interface NodeStyleConfig {
@@ -438,6 +439,7 @@ export const useResolverTheme = (): {
438439
resolverBreadcrumbBackground: theme.euiColorLightestShade,
439440
resolverEdgeText: getThemedOption(theme.euiColorDarkShade, theme.euiColorFullShade),
440441
triggerBackingFill: `${theme.euiColorDanger}${getThemedOption('0F', '1F')}`,
442+
pillStroke: theme.euiColorLightShade,
441443
};
442444

443445
const nodeAssets: NodeStyleMap = {

x-pack/plugins/security_solution/public/resolver/view/process_event_dot.tsx

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ const StyledActionsContainer = styled.div<StyledActionsContainer>`
3838
position: absolute;
3939
top: ${(props) => `${props.topPct}%`};
4040
width: auto;
41+
pointer-events: all;
4142
`;
4243

4344
interface StyledDescriptionText {
@@ -61,6 +62,11 @@ const StyledDescriptionText = styled.div<StyledDescriptionText>`
6162
width: fit-content;
6263
`;
6364

65+
const StyledOuterGroup = styled.g`
66+
fill: none;
67+
pointer-events: visiblePainted;
68+
`;
69+
6470
/**
6571
* An artifact that represents a process node and the things associated with it in the Resolver
6672
*/
@@ -329,6 +335,7 @@ const UnstyledProcessEventDot = React.memo(
329335
}
330336
role="img"
331337
aria-labelledby={labelHTMLID}
338+
fill="none"
332339
style={{
333340
display: 'block',
334341
width: '100%',
@@ -338,9 +345,10 @@ const UnstyledProcessEventDot = React.memo(
338345
left: '0',
339346
outline: 'transparent',
340347
border: 'none',
348+
pointerEvents: 'none',
341349
}}
342350
>
343-
<g>
351+
<StyledOuterGroup>
344352
<use
345353
xlinkHref={`#${SymbolIds.processCubeActiveBacking}`}
346354
fill={backingFill} // Only visible on hover
@@ -372,7 +380,7 @@ const UnstyledProcessEventDot = React.memo(
372380
ref={animationTarget}
373381
/>
374382
</use>
375-
</g>
383+
</StyledOuterGroup>
376384
</svg>
377385
<StyledActionsContainer
378386
color={colorMap.full}
@@ -464,6 +472,7 @@ export const ProcessEventDot = styled(UnstyledProcessEventDot)`
464472
min-width: 280px;
465473
min-height: 90px;
466474
overflow-y: visible;
475+
pointer-events: none;
467476
468477
//dasharray & dashoffset should be equal to "pull" the stroke back
469478
//when it is transitioned.

0 commit comments

Comments
 (0)