increase highlight time and random colours for event monitoring

Summary:
1. makes it easier to tellwhen a parent and child hightlight together
2. Longer times means you have more time to click it and see

changelog: UIDebugger event debugger - increased highlight time. Nodes get random highlight color

Reviewed By: lblasa

Differential Revision: D49501954

fbshipit-source-id: 9456c00e0df77c40934eb95b4b48b566c7715181
This commit is contained in:
Luke De Feo
2023-09-21 08:50:36 -07:00
committed by Facebook GitHub Bot
parent 796fb161dc
commit 2ff91170e0
4 changed files with 27 additions and 20 deletions

View File

@@ -324,7 +324,7 @@ function Visualization2DNode({
/>
));
const isHighlighted = useValue(instance.uiState.highlightedNodes).has(
const highLightColor = useValue(instance.uiState.highlightedNodes).get(
node.id,
);
@@ -346,8 +346,8 @@ function Visualization2DNode({
top: toPx(node.bounds.y),
width: toPx(node.bounds.width),
height: toPx(node.bounds.height),
opacity: isHighlighted ? 0.3 : 1,
backgroundColor: isHighlighted ? 'red' : 'transparent',
opacity: highLightColor != null ? 0.7 : 1,
backgroundColor: highLightColor,
}}>
{showBorder && <NodeBorder />}